![]() |
ImFusion SDK 4.3
|
#include <ImFusion/GUI/RadiologyViewOverlays.h>
Helper class to create and manage ViewOverlays commonly shown in radiology workstations. More...
Inheritance diagram for RadiologyViewOverlays:Helper class to create and manage ViewOverlays commonly shown in radiology workstations.
Public Types | |
| enum | OverlayType { NoOverlays = 0 , FullscreenButton = 1 << 0 , ViewOrderButton = 1 << 1 , DataSelectionButton = 1 << 2 , ViewOptionsButton = 1 << 3 , DisplayOptionsButton = 1 << 4 , PatientInfo = 1 << 5 , HorizontalScale = 1 << 6 , VerticalScale = 1 << 7 , OrientationMesh = 1 << 8 , Histogram = 1 << 9 , PixelInfo = 1 << 10 , FpsCounter = 1 << 11 , OffscreenIndicator = 1 << 12 , AllOverlays = 0xFFFF } |
| Enumeration to select default overlays to add to a view. More... | |
| enum class | OrientationMeshType { Cube , Head , Body , CubeQuadruped } |
| Enumeration of available meshes to show in the OrientationOverlay. More... | |
| using | PatientInfoFormatter = std::function<std::string(const ImageInfoDataComponent&)> |
| Alias for a formatting function to be used with the PatientInfo overlay. | |
Public Member Functions | |
| RadiologyViewOverlays (DisplayBase *display, DisplayAutoLayouter *autoLayouter, DataModel *dataModel) | |
| Creates a new RadiologyViewOverlays instance. | |
| void | addOverlays (View &view, Flags< OverlayType > overlayTypes) |
| Create and add the given overlayTypes the the given view. | |
| void | addOverlays (std::vector< View * > views, Flags< OverlayType > overlayTypes) |
| Create and add the given overlayTypes the the given set of views. | |
| bool | removeOverlay (View &view, OverlayType type) |
| Removes a ViewOverlay that was previously created through addOverlays(). | |
| bool | isOverlayVisible (const View &view, OverlayType type) const |
| Returns if the given overlay is visible in the given view. | |
| void | setOverlayVisibility (const View &view, OverlayType type, bool isVisible) |
| Sets the visibility of the given overlay in the given view. | |
| void | setOverlayVisibility (OverlayType type, bool isVisible) |
| Sets the visibility of the given overlay in all known views. | |
| void | setPatientInfoFormatter (PatientInfoFormatter formatter) |
| Defines the content of the PatientInfo overlay based on a formatting function. | |
| void | setPatientInfoFormatString (const std::string &formatString) |
| Defines the content of the PatientInfo overlay based on a format string. | |
| OrientationMeshType | orientationMeshType () const |
| Returns the mesh to be used in the OrientationMesh overlay. | |
| void | setOrientationMeshType (OrientationMeshType value) |
| Sets the mesh to be used in the OrientationMesh overlay. | |
| ViewOverlay * | getOverlay (const View &view, OverlayType type) |
| const ViewOverlay * | getOverlay (const View &view, OverlayType type) const |
| ButtonOverlay * | getFullscreenButtonOverlay (const View &view) |
| Convenience function to access the ButtonOverlay for toggling fullscreen mode of the given view if present. | |
| ButtonOverlay * | getViewOrderButtonOverlay (const View &view) |
| Convenience function to access the ButtonOverlay for rearranging the view order of the given view if present. | |
| ButtonOverlay * | getDataSelectionButtonOverlay (const View &view) |
| Convenience function to access the ButtonOverlay for rearranging the view order of the given view if present. | |
| InteractiveViewOptionsOverlay * | getViewOptionsButtonOverlay (const View &view) |
| Convenience function to access the ButtonOverlay for rearranging the view order of the given view if present. | |
| InteractiveViewOptionsOverlay * | getDisplayOptionsButtonOverlay (const View &view) |
| Convenience function to access the ButtonOverlay for rearranging the view order of the given view if present. | |
| OrientationMeshOverlay * | getOrientationMeshOverlay (const View &view) |
| Convenience function to access the OrientationMeshOverlay of the given view if present. | |
| ViewOverlay * | getPatientInfoOverlay (const View &view) |
| Convenience function to access the horizontal ScaleOverlay of the given view if present. | |
| ScaleOverlay * | getHorizontalScaleOverlay (const View &view) |
| Convenience function to access the horizontal ScaleOverlay of the given view if present. | |
| ScaleOverlay * | getVerticalScaleOverlay (const View &view) |
| Convenience function to access the vertical ScaleOverlay of the given view if present. | |
| OffscreenIndicatorsOverlay * | getOffscreenIndicatorsOverlay (const View &view) |
| Convenience function to access the OffscreenIndicatorsOverlay of the given view if present. | |
| HistogramOverlay * | getHistogramOverlay (const View &view) |
| Convenience function to access the HistogramOverlay of the given view if present. | |
| PixelInfoOverlay * | getPixelInfoOverlay (const View &view) |
| Convenience function to access the PixelInfoOverlay of the given view if present. | |
| ViewOverlay * | getFpsCounterOverlay (const View &view) |
| Convenience function to access the FpsCounter overlay of the given view if present. | |
Public Member Functions inherited from SignalReceiver | |
| SignalReceiver ()=default | |
| Default constructor. | |
| SignalReceiver (const SignalReceiver &other) | |
| Copy constructor, does not copy any existing signal connections from other. | |
| SignalReceiver & | operator= (SignalReceiver rhs) |
| Assignment operator, disconnects all existing connections, does not copy any existing signal connections from rhs. | |
| virtual | ~SignalReceiver () |
| Virtual destructor disconnects from all connected signals. | |
Additional Inherited Members | |
Protected Member Functions inherited from SignalReceiver | |
| void | disconnectAll () |
| Disconnects all existing connections. | |
| enum OverlayType |
Enumeration to select default overlays to add to a view.
| Enumerator | |
|---|---|
| FullscreenButton | Button to maximize/minimize the view; requires DisplayAutoLayouter. |
| ViewOrderButton | Button to move the view to a different position in the view layout; requires DisplayAutoLayouter. |
| DataSelectionButton | Button to select the visible data from the DataModel. |
| ViewOptionsButton | Button to show a popup for configuring view options. |
| DisplayOptionsButton | Button to show a popup for configuring display options. |
| PatientInfo | Text overlay showing patient information. |
| HorizontalScale | Horizontal ruler overlay showing the image scale; only applicable to SliceViews. |
| VerticalScale | Vertical ruler overlay showing the image scale; only applicable to SliceViews. |
| OrientationMesh | Overlay showing the orientation of the shown data (e.g. in form of a cube) |
| Histogram | Shows the intensity distribution of the shown image as histogram; only applicable to SliceViews. |
| PixelInfo | Shows image pixel information underneath the mouse pointer; only applicable to SliceViews. |
| FpsCounter | Shows an estimate of the frames per second of the renderer. |
| OffscreenIndicator | Dynamic overlay showing data that is outside of the current view area; only applicable to SliceViews. |
|
strong |
| RadiologyViewOverlays | ( | DisplayBase * | display, |
| DisplayAutoLayouter * | autoLayouter, | ||
| DataModel * | dataModel ) |
Creates a new RadiologyViewOverlays instance.
All parameters are optional for this class in general but required for certain overlay types.
| display | Pointer to the parent display, required for the ViewOptionsButton and DisplayOptionsButton to be available. |
| autoLayouter | Pointer to the DisplayAutoLayouter of the parent display, required for the FullscreenButton and ViewOrderButton to be available. |
| dataModel | Pointer to an DataModel used by the parent application, required for the DataSelectionButton to be available. |
| void addOverlays | ( | View & | view, |
| Flags< OverlayType > | overlayTypes ) |
Create and add the given overlayTypes the the given view.
| std::runtime_error | in case:
|
| void addOverlays | ( | std::vector< View * > | views, |
| Flags< OverlayType > | overlayTypes ) |
Create and add the given overlayTypes the the given set of views.
| std::runtime_error | in case:
|
| bool removeOverlay | ( | View & | view, |
| OverlayType | type ) |
Removes a ViewOverlay that was previously created through addOverlays().
Returns true if successful or false if an overlay of the given type was not found for the given view.
| void setPatientInfoFormatString | ( | const std::string & | formatString | ) |
Defines the content of the PatientInfo overlay based on a format string.
The format string can contain placeholders using the syntax {placeholder}, where "placeholder" is one of the following: patient_name, birthdate, study_date, study_time, modality, patient_sex.
Example (also the default formatting string after construction):