Fraxinus  2023.01.05-dev+develop.0da12
An IGT application
cx::ViewportListener Class Reference

Listens to changes in viewport and camera matrix. More...

#include <cxViewportListener.h>

Inheritance diagram for cx::ViewportListener:
cx::ViewportListenerBase

Public Member Functions

 ViewportListener ()
 
virtual ~ViewportListener ()
 
void setModified ()
 
- Public Member Functions inherited from cx::ViewportListenerBase
 ViewportListenerBase ()
 
virtual ~ViewportListenerBase ()
 
void startListen (vtkRendererPtr renderer)
 
void stopListen ()
 
bool isListening () const
 
void setCallback (boost::function< void()> func)
 
virtual void callback ()
 
double getVpnZoom ()
 
double getVpnZoom (Vector3D focalPoint)
 ViewportListenerBase::getVpnZoom Calculate the size of a 1mm line at the focal point projected into the normalized viewport space. This method uses a given point as the focal point. More...
 

Protected Member Functions

virtual void addObservers ()
 
virtual void removeObservers ()
 

Additional Inherited Members

- Protected Types inherited from cx::ViewportListenerBase
typedef vtkSmartPointer< class ViewportObserverPrivateViewportObserverPrivatePtr
 
- Protected Attributes inherited from cx::ViewportListenerBase
ViewportObserverPrivatePtr mObserver
 
vtkRendererPtr mRenderer
 

Detailed Description

Listens to changes in viewport and camera matrix.

Class that listens to changes in the viewport size and camera matrix. A callback function is called when a change is detected.

This can be used to update reps with respect to viewport size, for example keep a 3D object in constant observed size.

Definition at line 67 of file cxViewportListener.h.

Constructor & Destructor Documentation

cx::ViewportListener::ViewportListener ( )
inline

Definition at line 70 of file cxViewportListener.h.

cx::ViewportListener::~ViewportListener ( )
virtual

Definition at line 166 of file cxViewportListener.cpp.

Member Function Documentation

void cx::ViewportListener::addObservers ( )
protectedvirtual

Implements cx::ViewportListenerBase.

Definition at line 153 of file cxViewportListener.cpp.

void cx::ViewportListener::removeObservers ( )
protectedvirtual

Implements cx::ViewportListenerBase.

Definition at line 160 of file cxViewportListener.cpp.

void cx::ViewportListener::setModified ( )

The documentation for this class was generated from the following files: