VTK  9.3.20240328
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
vtkZSpaceCoreSDKManager Class Reference

zSpace Core SDK manager class. More...

#include <vtkZSpaceCoreSDKManager.h>

Inheritance diagram for vtkZSpaceCoreSDKManager:
[legend]
Collaboration diagram for vtkZSpaceCoreSDKManager:
[legend]

Public Types

typedef vtkZSpaceSDKManager Superclass
 
- Public Types inherited from vtkZSpaceSDKManager
enum  StereoDisplayMode { QUAD_BUFFER_STEREO = 0 , STEREO_DISPLAY_API = 1 }
 
enum  ButtonIds { MiddleButton = 0 , RightButton = 1 , LeftButton = 2 , NumberOfButtons = 3 }
 
enum  ButtonState {
  Down = 0 , Pressed = 1 , Up = 2 , None = 3 ,
  NumberOfStates = 4
}
 
typedef vtkObject Superclass
 

Public Member Functions

virtual vtkTypeBool IsA (const char *type)
 Return 1 if this class is the same type of (or a subclass of) the named class. More...
 
vtkZSpaceCoreSDKManagerNewInstance () const
 
void PrintSelf (ostream &os, vtkIndent indent) override
 Methods invoked by print to print information about the object including superclasses. More...
 
void InitializeZSpace () override
 Initialize the zSpace SDK and check for zSpace devices : the display, the stylus and the head trackers. More...
 
void UpdateViewport () override
 Update the zSpace viewport position and size based on the position and size of the application window. More...
 
void UpdateTrackers () override
 Update the position of the stylus and head trackers. More...
 
void UpdateViewAndProjectionMatrix () override
 Update the zSpace view and projection matrix for each eye. More...
 
void UpdateButtonState () override
 Update the stylus buttons state. More...
 
void CalculateFrustumFit (const double bounds[6], double position[3], double viewUp[3]) override
 Let zSpace compute the viewer scale, camera position and camera view up from the input bounds. More...
 
void BeginFrame () override
 Notify the zSpace SDK for the beginning of a frame. More...
 
void EndFrame () override
 Notify the zSpace SDK for the beginning of a frame. More...
 
- Public Member Functions inherited from vtkZSpaceSDKManager
vtkZSpaceSDKManagerNewInstance () const
 
void PrintSelf (ostream &os, vtkIndent indent) override
 Methods invoked by print to print information about the object including superclasses. More...
 
virtual void ShutDown ()
 Shutdown the zSpace SDK (clean its internal state). More...
 
virtual StereoDisplayMode GetStereoDisplayMode ()
 
void Update ()
 Update the viewport, the trackers and the camera matrix by calling the zSpace SDK. More...
 
virtual int GetWindowX ()
 Get the x position of the upper left corner of the zSpace display in the virtual desktop. More...
 
virtual int GetWindowY ()
 Get the y position of the upper left corner of the zSpace display in the virtual desktop. More...
 
virtual int GetWindowWidth ()
 Get the x resolution in pixels of the zSpace display. More...
 
virtual int GetWindowHeight ()
 Get the y resolution in pixels of the zSpace display. More...
 
virtual int GetStylusTargets ()
 Get the number of stylus connected to the zSpace device. More...
 
virtual int GetHeadTargets ()
 Get the number of glasses connected to the zSpace device. More...
 
virtual int GetSecondaryTargets ()
 Get the number of secondary targets connected to the zSpace device. More...
 
void SetClippingRange (const float nearPlane, const float farPlane)
 Set the near and far plane. More...
 
virtual float GetViewerScale ()
 Get the viewer scale. More...
 
virtual float GetNearPlane ()
 Get the near plane. More...
 
virtual float GetFarPlane ()
 Get the far plane. More...
 
virtual vtkMatrix4x4GetCenterEyeViewMatrix ()
 Get the zSpace view matrix without stereo (eye set as EYE_CENTER) in row major format (VTK format) More...
 
vtkMatrix4x4GetStereoViewMatrix (bool leftEye)
 Get the zSpace view matrix for the right or left eye in row major format (VTK format) More...
 
virtual vtkMatrix4x4GetCenterEyeProjectionMatrix ()
 Get the zSpace projection matrix without stereo (eye set as EYE_CENTER) in row major format (VTK format) More...
 
vtkMatrix4x4GetStereoProjectionMatrix (bool leftEye)
 Get the zSpace projection matrix for the right or left eye in row major format (VTK format) More...
 
virtual vtkMatrix4x4GetStylusMatrixColMajor ()
 Get the zSpace stylus matrix in world space. More...
 
virtual vtkMatrix4x4GetStylusMatrixRowMajor ()
 Get the zSpace stylus matrix in world space. More...
 
virtual vtkTransformGetStylusTransformRowMajor ()
 Get the zSpace stylus transform in world space. More...
 
virtual void EnableGraphicsBinding ()
 These functions are overriden by vtkZSpaceCoreCompatibility (specific to zSpace Inspire). More...
 
virtual void SubmitFrame (unsigned int vtkNotUsed(leftText), unsigned int vtkNotUsed(rightText))
 These functions are overriden by vtkZSpaceCoreCompatibility (specific to zSpace Inspire). More...
 
virtual void GetPerEyeImageResolution (int *vtkNotUsed(width), int *vtkNotUsed(height))
 These functions are overriden by vtkZSpaceCoreCompatibility (specific to zSpace Inspire). More...
 
virtual void SetStereoDisplayEnabled (bool vtkNotUsed(enabled))
 These functions are overriden by vtkZSpaceCoreCompatibility (specific to zSpace Inspire). More...
 
virtual bool GetStereoDisplayEnabled ()
 These functions are overriden by vtkZSpaceCoreCompatibility (specific to zSpace Inspire). More...
 
virtual void SetRenderWindow (vtkRenderWindow *renderWindow)
 Set the render windwow the manager makes viewport computations from. More...
 
virtual float GetInterPupillaryDistance ()
 Get/Set the distance between the eyes in meters. More...
 
virtual void SetInterPupillaryDistance (float)
 Get/Set the distance between the eyes in meters. More...
 
virtual int GetLeftButtonState ()
 Get/Set the state of the left button of the stylus. More...
 
 vtkSetEnumMacro (LeftButtonState, ButtonState)
 Get/Set the state of the left button of the stylus. More...
 
virtual int GetMiddleButtonState ()
 Get/Set the state of the middle button of the stylus. More...
 
 vtkSetEnumMacro (MiddleButtonState, ButtonState)
 Get/Set the state of the middle button of the stylus. More...
 
virtual int GetRightButtonState ()
 Get/Set the state of the right button of the stylus. More...
 
 vtkSetEnumMacro (RightButtonState, ButtonState)
 Get/Set the state of the right button of the stylus. More...
 
- Public Member Functions inherited from vtkObject
 vtkBaseTypeMacro (vtkObject, vtkObjectBase)
 
virtual void DebugOn ()
 Turn debugging output on. More...
 
virtual void DebugOff ()
 Turn debugging output off. More...
 
bool GetDebug ()
 Get the value of the debug flag. More...
 
void SetDebug (bool debugFlag)
 Set the value of the debug flag. More...
 
virtual void Modified ()
 Update the modification time for this object. More...
 
virtual vtkMTimeType GetMTime ()
 Return this object's modified time. More...
 
void RemoveObserver (unsigned long tag)
 
void RemoveObservers (unsigned long event)
 
void RemoveObservers (const char *event)
 
void RemoveAllObservers ()
 
vtkTypeBool HasObserver (unsigned long event)
 
vtkTypeBool HasObserver (const char *event)
 
vtkTypeBool InvokeEvent (unsigned long event)
 
vtkTypeBool InvokeEvent (const char *event)
 
std::string GetObjectDescription () const override
 The object description printed in messages and PrintSelf output. More...
 
unsigned long AddObserver (unsigned long event, vtkCommand *, float priority=0.0f)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
unsigned long AddObserver (const char *event, vtkCommand *, float priority=0.0f)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
vtkCommandGetCommand (unsigned long tag)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
void RemoveObserver (vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
void RemoveObservers (unsigned long event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
void RemoveObservers (const char *event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
vtkTypeBool HasObserver (unsigned long event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
vtkTypeBool HasObserver (const char *event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, void(T::*callback)(), float priority=0.0f)
 Overloads to AddObserver that allow developers to add class member functions as callbacks for events. More...
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, void(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f)
 Overloads to AddObserver that allow developers to add class member functions as callbacks for events. More...
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, bool(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f)
 Allow user to set the AbortFlagOn() with the return value of the callback method. More...
 
vtkTypeBool InvokeEvent (unsigned long event, void *callData)
 This method invokes an event and return whether the event was aborted or not. More...
 
vtkTypeBool InvokeEvent (const char *event, void *callData)
 This method invokes an event and return whether the event was aborted or not. More...
 
virtual void SetObjectName (const std::string &objectName)
 Set/get the name of this object for reporting purposes. More...
 
virtual std::string GetObjectName () const
 Set/get the name of this object for reporting purposes. More...
 
- Public Member Functions inherited from vtkObjectBase
const char * GetClassName () const
 Return the class name as a string. More...
 
virtual vtkIdType GetNumberOfGenerationsFromBase (const char *name)
 Given the name of a base class of this class type, return the distance of inheritance between this class type and the named class (how many generations of inheritance are there between this class and the named class). More...
 
virtual void Delete ()
 Delete a VTK object. More...
 
virtual void FastDelete ()
 Delete a reference to this object. More...
 
void InitializeObjectBase ()
 
void Print (ostream &os)
 Print an object to an ostream. More...
 
void Register (vtkObjectBase *o)
 Increase the reference count (mark as used by another object). More...
 
virtual void UnRegister (vtkObjectBase *o)
 Decrease the reference count (release by another object). More...
 
int GetReferenceCount ()
 Return the current reference count of this object. More...
 
void SetReferenceCount (int)
 Sets the reference count. More...
 
bool GetIsInMemkind () const
 A local state flag that remembers whether this object lives in the normal or extended memory space. More...
 
virtual void PrintHeader (ostream &os, vtkIndent indent)
 Methods invoked by print to print information about the object including superclasses. More...
 
virtual void PrintTrailer (ostream &os, vtkIndent indent)
 Methods invoked by print to print information about the object including superclasses. More...
 
virtual bool UsesGarbageCollector () const
 Indicate whether the class uses vtkGarbageCollector or not. More...
 

Static Public Member Functions

static vtkZSpaceCoreSDKManagerNew ()
 
static vtkTypeBool IsTypeOf (const char *type)
 
static vtkZSpaceCoreSDKManagerSafeDownCast (vtkObjectBase *o)
 
- Static Public Member Functions inherited from vtkZSpaceSDKManager
static vtkTypeBool IsTypeOf (const char *type)
 
static vtkZSpaceSDKManagerSafeDownCast (vtkObjectBase *o)
 
static vtkZSpaceSDKManagerGetInstance ()
 Return the singleton instance (with no reference counting) of a vtkZSpaceCoreSDKManager or vtkZSpaceCoreCompatibilitySDKManager depending on the current zSpaceSDK in use. More...
 
- Static Public Member Functions inherited from vtkObject
static vtkObjectNew ()
 Create an object with Debug turned off, modified time initialized to zero, and reference counting on. More...
 
static void BreakOnError ()
 This method is called when vtkErrorMacro executes. More...
 
static void SetGlobalWarningDisplay (vtkTypeBool val)
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
static void GlobalWarningDisplayOn ()
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
static void GlobalWarningDisplayOff ()
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
static vtkTypeBool GetGlobalWarningDisplay ()
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
- Static Public Member Functions inherited from vtkObjectBase
static vtkTypeBool IsTypeOf (const char *name)
 Return 1 if this class type is the same type of (or a subclass of) the named class. More...
 
static vtkIdType GetNumberOfGenerationsFromBaseType (const char *name)
 Given a the name of a base class of this class type, return the distance of inheritance between this class type and the named class (how many generations of inheritance are there between this class and the named class). More...
 
static vtkObjectBaseNew ()
 Create an object with Debug turned off, modified time initialized to zero, and reference counting on. More...
 
static void SetMemkindDirectory (const char *directoryname)
 The name of a directory, ideally mounted -o dax, to memory map an extended memory space within. More...
 
static bool GetUsingMemkind ()
 A global state flag that controls whether vtkObjects are constructed in the usual way (the default) or within the extended memory space. More...
 

Protected Member Functions

virtual vtkObjectBaseNewInstanceInternal () const
 
 vtkZSpaceCoreSDKManager ()
 
 ~vtkZSpaceCoreSDKManager () override
 
void ConvertAndTransposeZSpaceMatrixToVTKMatrix (ZSMatrix4 zSpaceMatrix, vtkMatrix4x4 *vtkMatrix)
 zSpace stores matrix in column-major format (as OpenGL). More...
 
void ConvertZSpaceMatrixToVTKMatrix (ZSMatrix4 zSpaceMatrix, vtkMatrix4x4 *vtkMatrix)
 zSpace stores matrix in column-major format (as OpenGL). More...
 
- Protected Member Functions inherited from vtkZSpaceSDKManager
 vtkZSpaceSDKManager ()
 
 ~vtkZSpaceSDKManager () override
 
- Protected Member Functions inherited from vtkObject
 vtkObject ()
 
 ~vtkObject () override
 
void RegisterInternal (vtkObjectBase *, vtkTypeBool check) override
 
void UnRegisterInternal (vtkObjectBase *, vtkTypeBool check) override
 
void InternalGrabFocus (vtkCommand *mouseEvents, vtkCommand *keypressEvents=nullptr)
 These methods allow a command to exclusively grab all events. More...
 
void InternalReleaseFocus ()
 These methods allow a command to exclusively grab all events. More...
 
- Protected Member Functions inherited from vtkObjectBase
 vtkObjectBase ()
 
virtual ~vtkObjectBase ()
 
virtual void ReportReferences (vtkGarbageCollector *)
 
 vtkObjectBase (const vtkObjectBase &)
 
void operator= (const vtkObjectBase &)
 

Protected Attributes

ZCContext ZSpaceContext = nullptr
 
ZCHandle DisplayHandle = nullptr
 
ZCHandle BufferHandle = nullptr
 
ZCHandle ViewportHandle = nullptr
 
ZCHandle FrustumHandle = nullptr
 
ZCHandle StylusHandle = nullptr
 
- Protected Attributes inherited from vtkZSpaceSDKManager
vtkRenderWindowRenderWindow = nullptr
 
vtkNew< vtkMatrix4x4CenterEyeViewMatrix
 
vtkNew< vtkMatrix4x4LeftEyeViewMatrix
 
vtkNew< vtkMatrix4x4RightEyeViewMatrix
 
vtkNew< vtkMatrix4x4CenterEyeProjectionMatrix
 
vtkNew< vtkMatrix4x4LeftEyeProjectionMatrix
 
vtkNew< vtkMatrix4x4RightEyeProjectionMatrix
 
vtkNew< vtkMatrix4x4StylusMatrixColMajor
 
vtkNew< vtkMatrix4x4StylusMatrixRowMajor
 
vtkNew< vtkTransformStylusTransformRowMajor
 
int WindowX = 0
 
int WindowY = 0
 
int WindowWidth = 0
 
int WindowHeight = 0
 
std::vector< std::string > Displays
 
int StylusTargets = 0
 
int HeadTargets = 0
 
int SecondaryTargets = 0
 
float InterPupillaryDistance = 0.056f
 
float ViewerScale = 1.f
 
float NearPlane = 0.0001f
 
float FarPlane = 1000.f
 
ButtonState LeftButtonState = None
 
ButtonState MiddleButtonState = None
 
ButtonState RightButtonState = None
 
ButtonStateButtonsState [NumberOfButtons]
 
- Protected Attributes inherited from vtkObject
bool Debug
 
vtkTimeStamp MTime
 
vtkSubjectHelper * SubjectHelper
 
std::string ObjectName
 
- Protected Attributes inherited from vtkObjectBase
std::atomic< int32_t > ReferenceCount
 
vtkWeakPointerBase ** WeakPointers
 

Additional Inherited Members

- Static Protected Member Functions inherited from vtkObjectBase
static vtkMallocingFunction GetCurrentMallocFunction ()
 
static vtkReallocingFunction GetCurrentReallocFunction ()
 
static vtkFreeingFunction GetCurrentFreeFunction ()
 
static vtkFreeingFunction GetAlternateFreeFunction ()
 

Detailed Description

zSpace Core SDK manager class.

Class handling the interactions between the zSpace plugin and the zSpace Core SDK. This class is private and should not be used directly. Please use vtkZSpaceSDKManager instead.

See also
vtkZSpaceSDKManager

Definition at line 28 of file vtkZSpaceCoreSDKManager.h.

Member Typedef Documentation

◆ Superclass

Definition at line 32 of file vtkZSpaceCoreSDKManager.h.

Constructor & Destructor Documentation

◆ vtkZSpaceCoreSDKManager()

vtkZSpaceCoreSDKManager::vtkZSpaceCoreSDKManager ( )
protected

◆ ~vtkZSpaceCoreSDKManager()

vtkZSpaceCoreSDKManager::~vtkZSpaceCoreSDKManager ( )
overrideprotected

Member Function Documentation

◆ New()

static vtkZSpaceCoreSDKManager* vtkZSpaceCoreSDKManager::New ( )
static

◆ IsTypeOf()

static vtkTypeBool vtkZSpaceCoreSDKManager::IsTypeOf ( const char *  type)
static

◆ IsA()

virtual vtkTypeBool vtkZSpaceCoreSDKManager::IsA ( const char *  name)
virtual

Return 1 if this class is the same type of (or a subclass of) the named class.

Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.

Reimplemented from vtkZSpaceSDKManager.

◆ SafeDownCast()

static vtkZSpaceCoreSDKManager* vtkZSpaceCoreSDKManager::SafeDownCast ( vtkObjectBase o)
static

◆ NewInstanceInternal()

virtual vtkObjectBase* vtkZSpaceCoreSDKManager::NewInstanceInternal ( ) const
protectedvirtual

Reimplemented from vtkZSpaceSDKManager.

◆ NewInstance()

vtkZSpaceCoreSDKManager* vtkZSpaceCoreSDKManager::NewInstance ( ) const

◆ PrintSelf()

void vtkZSpaceCoreSDKManager::PrintSelf ( ostream &  os,
vtkIndent  indent 
)
overridevirtual

Methods invoked by print to print information about the object including superclasses.

Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.

Reimplemented from vtkObject.

◆ InitializeZSpace()

void vtkZSpaceCoreSDKManager::InitializeZSpace ( )
overridevirtual

Initialize the zSpace SDK and check for zSpace devices : the display, the stylus and the head trackers.

Implements vtkZSpaceSDKManager.

◆ UpdateViewport()

void vtkZSpaceCoreSDKManager::UpdateViewport ( )
overridevirtual

Update the zSpace viewport position and size based on the position and size of the application window.

Implements vtkZSpaceSDKManager.

◆ UpdateTrackers()

void vtkZSpaceCoreSDKManager::UpdateTrackers ( )
overridevirtual

Update the position of the stylus and head trackers.

Implements vtkZSpaceSDKManager.

◆ UpdateViewAndProjectionMatrix()

void vtkZSpaceCoreSDKManager::UpdateViewAndProjectionMatrix ( )
overridevirtual

Update the zSpace view and projection matrix for each eye.

Implements vtkZSpaceSDKManager.

◆ UpdateButtonState()

void vtkZSpaceCoreSDKManager::UpdateButtonState ( )
overridevirtual

Update the stylus buttons state.

Implements vtkZSpaceSDKManager.

◆ CalculateFrustumFit()

void vtkZSpaceCoreSDKManager::CalculateFrustumFit ( const double  bounds[6],
double  position[3],
double  viewUp[3] 
)
overridevirtual

Let zSpace compute the viewer scale, camera position and camera view up from the input bounds.

Implements vtkZSpaceSDKManager.

◆ BeginFrame()

void vtkZSpaceCoreSDKManager::BeginFrame ( )
overridevirtual

Notify the zSpace SDK for the beginning of a frame.

There is no "end frame" notification to make in the case of the zSpace Core SDK.

Implements vtkZSpaceSDKManager.

◆ EndFrame()

void vtkZSpaceCoreSDKManager::EndFrame ( )
inlineoverridevirtual

Notify the zSpace SDK for the beginning of a frame.

There is no "end frame" notification to make in the case of the zSpace Core SDK.

Implements vtkZSpaceSDKManager.

Definition at line 75 of file vtkZSpaceCoreSDKManager.h.

◆ ConvertAndTransposeZSpaceMatrixToVTKMatrix()

void vtkZSpaceCoreSDKManager::ConvertAndTransposeZSpaceMatrixToVTKMatrix ( ZSMatrix4  zSpaceMatrix,
vtkMatrix4x4 vtkMatrix 
)
protected

zSpace stores matrix in column-major format (as OpenGL).

The matrix needs to be transposed to be used by VTK.

◆ ConvertZSpaceMatrixToVTKMatrix()

void vtkZSpaceCoreSDKManager::ConvertZSpaceMatrixToVTKMatrix ( ZSMatrix4  zSpaceMatrix,
vtkMatrix4x4 vtkMatrix 
)
protected

zSpace stores matrix in column-major format (as OpenGL).

The matrix needs to be transposed to be used by VTK.

Member Data Documentation

◆ ZSpaceContext

ZCContext vtkZSpaceCoreSDKManager::ZSpaceContext = nullptr
protected

Definition at line 82 of file vtkZSpaceCoreSDKManager.h.

◆ DisplayHandle

ZCHandle vtkZSpaceCoreSDKManager::DisplayHandle = nullptr
protected

Definition at line 83 of file vtkZSpaceCoreSDKManager.h.

◆ BufferHandle

ZCHandle vtkZSpaceCoreSDKManager::BufferHandle = nullptr
protected

Definition at line 84 of file vtkZSpaceCoreSDKManager.h.

◆ ViewportHandle

ZCHandle vtkZSpaceCoreSDKManager::ViewportHandle = nullptr
protected

Definition at line 85 of file vtkZSpaceCoreSDKManager.h.

◆ FrustumHandle

ZCHandle vtkZSpaceCoreSDKManager::FrustumHandle = nullptr
protected

Definition at line 86 of file vtkZSpaceCoreSDKManager.h.

◆ StylusHandle

ZCHandle vtkZSpaceCoreSDKManager::StylusHandle = nullptr
protected

Definition at line 87 of file vtkZSpaceCoreSDKManager.h.


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