20             VisRTX::Context* rtx = VisRTX_GetContext();
 
   22             if (
type == 
"perspective")
 
   23                 this->camera = rtx->CreatePerspectiveCamera();
 
   24             else if (
type == 
"orthographic")
 
   25                 this->camera = rtx->CreateOrthographicCamera();
 
   32             this->camera->Release();
 
   38             if (this->
Get3f({ 
"pos" }, &pos))
 
   39                 this->camera->SetPosition(pos);
 
   43                 this->camera->SetDirection(
dir);
 
   46             if (this->
Get3f({ 
"up" }, &up))
 
   47                 this->camera->SetUp(up);
 
   49             VisRTX::Vec2f imageBegin, imageEnd;
 
   50             if (this->
Get2f({ 
"imageStart" }, &imageBegin) && this->
Get2f({ 
"imageEnd" }, &imageEnd))
 
   51                 this->camera->SetImageRegion(imageBegin, imageEnd);
 
   53             if (this->camera->GetType() == VisRTX::CameraType::PERSPECTIVE)
 
   55                 VisRTX::PerspectiveCamera* pc = 
dynamic_cast<VisRTX::PerspectiveCamera*
>(this->camera);
 
   58                 if (this->
Get1f({ 
"fovy" }, &fovy))
 
   62                 if (this->
Get1f({ 
"aspect" }, &aspect))
 
   63                     pc->SetAspect(aspect);
 
   66                 if (this->
Get1f({ 
"focusDistance" }, &focalDistance))
 
   67                     pc->SetFocalDistance(focalDistance);
 
   70                 if (this->
Get1f({ 
"apertureRadius" }, &apertureRadius))
 
   71                     pc->SetApertureRadius(apertureRadius);
 
   74             else if (this->camera->GetType() == VisRTX::CameraType::ORTHOGRAPHIC)
 
   76                 VisRTX::OrthographicCamera* oc = 
dynamic_cast<VisRTX::OrthographicCamera*
>(this->camera);
 
   83                 if (this->
Get1f({ 
"aspect" }, &aspect))
 
   84                     oc->SetAspect(aspect);
 
   94         VisRTX::Camera* camera = 
nullptr;