Viewer Controller
ViewerController is a class representing the 2D image rendering viewer of OsiriX. It is used to obtain display information such as window settings and window title, and control contents (DCMPix and ROIs).
Type
All types only contain a single parameter, the UUID of the underlying OsiriX object.
Methods
By convention, any method defined with syntax
is called in Python (for example) using syntaxresponse
is aViewerControllerXyzResponse
class, andrequest
aViewerControllerXyzRequest
class.
osirix.proto (lines 99-125)
rpc ViewerControllerCloseViewer (ViewerController) returns (Response) {}
rpc ViewerControllerPixList (ViewerControllerPixListRequest) returns (ViewerControllerPixListResponse) {}
rpc ViewerControllerNeedsDisplayUpdate (ViewerController) returns (Response) {}
rpc ViewerControllerROIList (ViewerControllerROIListRequest) returns (ViewerControllerROIListResponse) {}
rpc ViewerControllerNewROI (ViewerControllerNewROIRequest) returns (ViewerControllerNewROIResponse) {}
rpc ViewerControllerCurDCM (ViewerController) returns (ViewerControllerCurDCMResponse) {}
rpc ViewerControllerROIsWithName (ViewerControllerROIsWithNameRequest) returns (ViewerControllerROIsWithNameResponse) {}
rpc ViewerControllerSelectedROIs (ViewerController) returns (ViewerControllerSelectedROIsResponse) {}
rpc ViewerControllerIsDataVolumic (ViewerControllerIsDataVolumicRequest) returns (ViewerControllerIsDataVolumicResponse) {}
rpc ViewerControllerCopyViewerWindow (ViewerController) returns (ViewerControllerCopyViewerWindowResponse) {}
rpc ViewerControllerResampleViewerController (ViewerControllerResampleViewerControllerRequest) returns (ViewerControllerResampleViewerControllerResponse) {}
rpc ViewerControllerBlendingController (ViewerController) returns (ViewerControllerBlendingControllerResponse) {}
rpc ViewerControllerVRControllers (ViewerController) returns (ViewerControllerVRControllersResponse) {}
rpc ViewerControllerTitle (ViewerController) returns (ViewerControllerTitleResponse) {}
rpc ViewerControllerModality (ViewerController) returns (ViewerControllerModalityResponse) {}
rpc ViewerControllerMovieIdx (ViewerController) returns (ViewerControllerMovieIdxResponse) {}
rpc ViewerControllerSetMovieIdx (ViewerControllerSetMovieIdxRequest) returns (Response) {}
rpc ViewerControllerMaxMovieIdx (ViewerController) returns (ViewerControllerMaxMovieIdxResponse) {}
rpc ViewerControllerIdx (ViewerController) returns (ViewerControllerIdxResponse) {}
rpc ViewerControllerSetIdx (ViewerControllerSetIdxRequest) returns (Response) {}
rpc ViewerControllerDisplayedIdx (ViewerController) returns (ViewerControllerDisplayedIdxResponse) {}
rpc ViewerControllerSetDisplayedIdx (ViewerControllerSetDisplayedIdxRequest) returns (Response) {}
rpc ViewerControllerFlippedData (ViewerController) returns (ViewerControllerFlippedDataResponse) {}
rpc ViewerControllerWLWW (ViewerController) returns (ViewerControllerWLWWResponse) {}
rpc ViewerControllerSetWLWW (ViewerControllerSetWLWWRequest) returns (Response) {}
rpc ViewerControllerOpenVRViewerForMode (ViewerControllerOpenVRViewerForModeRequest) returns (ViewerControllerOpenVRViewerForModeResponse) {}
rpc ViewerControllerFuseWithViewer (ViewerControllerFuseWithViewerRequest) returns (Response) {}
Responses
By convention, any response defined with syntax
- The numbers on the RHS should be ignored. They are necessary only for protobuf file definitions.
has attributes accessed in Python (for example) using syntax
viewercontroller.proto (lines 9-111)
message ViewerControllerPixListResponse{
Status status = 1;
repeated DCMPix pix = 2;
}
message ViewerControllerROIListResponse{
message ROISlice{
repeated ROI rois = 1;
}
Status status = 1;
repeated ROISlice roi_slices = 2;
}
message ViewerControllerNewROIResponse{
Status status = 1;
ROI roi = 2;
}
message ViewerControllerCurDCMResponse{
Status status = 1;
DCMPix pix = 2;
}
message ViewerControllerROIsWithNameResponse{
Status status = 1;
repeated ROI rois = 2;
}
message ViewerControllerSelectedROIsResponse{
Status status = 1;
repeated ROI rois = 2;
}
message ViewerControllerIsDataVolumicResponse{
Status status = 1;
bool is_volumic = 2;
}
message ViewerControllerBlendingControllerResponse{
Status status = 1;
ViewerController blending_viewer = 2;
}
message ViewerControllerVRControllersResponse{
Status status = 1;
repeated VRController vr_controllers = 2;
}
message ViewerControllerTitleResponse{
Status status = 1;
string title = 2;
}
message ViewerControllerModalityResponse{
Status status = 1;
string modality = 2;
}
message ViewerControllerMovieIdxResponse{
Status status = 1;
int32 movie_idx = 2;
}
message ViewerControllerMaxMovieIdxResponse{
Status status = 1;
int32 max_movie_idx = 2;
}
message ViewerControllerIdxResponse{
Status status = 1;
int32 idx = 2;
}
message ViewerControllerDisplayedIdxResponse{
Status status = 1;
int32 displayed_idx = 2;
}
message ViewerControllerWLWWResponse{
Status status = 1;
float wl = 2;
float ww = 3;
}
Requests
By convention, any request defined with syntax
- The numbers on the RHS should be ignored. They are necessary only for protobuf file definitions.
is created in Python (for example) using syntax
from osirixgrpc import viewercontroller_pb2
request = viewercontroller_pb2.ViewerControllerXyzRequest(arg1 = x1, arg2 = x2, ...)
viewercontroller.proto (lines 115-)
message ViewerControllerPixListRequest{
ViewerController viewer_controller = 1;
int32 movie_idx = 2;
}
message ViewerControllerROIListRequest{
ViewerController viewer_controller = 1;
int32 movie_idx = 2;
}
message ViewerControllerNewROIRequest{
message Buffer{
repeated bool buffer = 1;
int32 rows = 2;
int32 columns = 3;
}
message Point2D{
float x = 1;
float y = 2;
}
message Color{
int32 r = 1;
int32 g = 2;
int32 b = 3;
}
message Rect{
float origin_x = 1;
float origin_y = 2;
float height = 3;
float width = 4;
}
ViewerController viewer_controller = 1;
int32 itype = 2;
string name = 3;
int32 idx = 4;
int32 movie_idx = 5;
int32 buffer_position_x = 6;
int32 buffer_position_y = 7;
Color color = 8;
float thickness = 9;
float opacity = 10;
Buffer buffer = 11;
repeated Point2D points = 12;
Rect rectangle = 13;
}
message ViewerControllerROIsWithNameRequest{
ViewerController viewer_controller = 1;
string name = 2;
int32 movie_idx = 3;
bool in_4d = 4;
}
message ViewerControllerResampleViewerControllerRequest{
ViewerController viewer_controller = 1;
ViewerController fixed_viewer_controller = 2;
}
message ViewerControllerSetMovieIdxRequest{
ViewerController viewer_controller = 1;
int32 movie_idx = 2;
}
message ViewerControllerIsDataVolumicRequest{
ViewerController viewer_controller = 1;
bool in_4d = 2;
}
message ViewerControllerSetIdxRequest{
ViewerController viewer_controller = 1;
int32 idx = 2;
}
message ViewerControllerSetDisplayedIdxRequest{
ViewerController viewer_controller = 1;
int32 displayed_idx = 2;
}
message ViewerControllerSetWLWWRequest{
ViewerController viewer_controller = 1;
float wl = 2;
float ww = 3;
}
message ViewerControllerOpenVRViewerForModeRequest{
ViewerController viewer_controller = 1;
string mode = 2;
}
message ViewerControllerFuseWithViewerRequest{
ViewerController viewer_controller = 1;
ViewerController fusion_viewer_controller = 2;
}