ImFusion SDK 4.3
GlGeometryView Class Reference

#include <ImFusion/CT/Legacy/GlGeometryView.h>

Legacy OpenGL geometry visualization. More...

+ Inheritance diagram for GlGeometryView:

Detailed Description

Legacy OpenGL geometry visualization.

Provides backward compatibility for displaying recovered scene geometry.

Public Member Functions

bool render () override
 Render geometry.
 
void clear ()
 Clear all view contents.
 
void setGeometry (const mat3 &K, const std::vector< mat3 > &R, const std::vector< vec3 > &t, int detResX, int detResY)
 Set camera positions and orientations.
 
void setPoints (const std::vector< vec3 > &points)
 Set scene points (end result of optimization).
 
void setPoints0 (const std::vector< vec3 > &points0)
 Set reference points (ground truth).
 
void setInitialPoints (const std::vector< vec3 > &pointsInit)
 Set initial points (starting estimate for optimization).
 
void setHighlightedCamera (int camera)
 Set camera which is to be highlighted.
 
Type type () const override
 Return the type of this view.
 
virtual std::string typeName () const
 
- Public Member Functions inherited from GlView
virtual void setMatrix (const mat4 &mat)
 Sets the view matrix (view coordinates to world coordinates).
 
virtual const mat4 & matrix () const
 Returns the current view matrix (view coordinates to world coordinates).
 
virtual void resize (int width, int height)
 Set a new viewport size for this view.
 
virtual const GL::OrderIndependentTransparencyorderIndependentTransparency () const
 Returns the optional OIT manager instance of the view if the feature is supported and enabled.
 
int height () const
 Current viewport height of the view.
 
int width () const
 Current viewport width of the view.
 
void addObject (GlObject *object)
 Add a reference to a GlObject to be drawn by this view.
 
void removeObject (GlObject *object)
 Remove a reference to a GlObject drawn by this view.
 
const std::vector< GlObject * > & objects () const
 Return the set of GlObjects that are drawn by this view.
 
const GL::ViewStatestate () const
 Return the view state that was set during the last render() call.
 

Additional Inherited Members

- Public Types inherited from GlView
enum  Type { SLICE2D = 0 , SLICE3D = 1 , SPACE3D = 2 , OTHER = 3 }
 Type of the view. More...
 
- Protected Member Functions inherited from GlView
GL::OrderIndependentTransparencysharedOitInstance () const
 Offers support for GlViews sharing GL::OrderIndependentTransparency instances to reduce GPU memory consumption.
 
- Protected Attributes inherited from GlView
std::vector< GlObject * > m_objects
 Other objects to consider during rendering.
 
mat4 m_matrix = mat4::Identity()
 Matrix converting view coordinates to world coords (inverse of a traditional OpenGL view matrix)
 
GL::ViewState m_state
 OpenGL state describing viewport, projection and model-view matrix of last render call.
 
int m_width = 0
 
int m_height = 0
 

Member Function Documentation

◆ render()

bool render ( )
overridevirtual

Render geometry.

Implements GlView.

◆ setGeometry()

void setGeometry ( const mat3 & K,
const std::vector< mat3 > & R,
const std::vector< vec3 > & t,
int detResX,
int detResY )

Set camera positions and orientations.

Parameters
Kinternal camera parameters
Rrotation matrix for all cameras
ttranslation vector for all cameras
detResXwidth of detector/images in pixels
detResYheight of detector/images in pixels

◆ setPoints()

void setPoints ( const std::vector< vec3 > & points)

Set scene points (end result of optimization).

Drawn in white.

Parameters
pointsscene points

◆ setPoints0()

void setPoints0 ( const std::vector< vec3 > & points0)

Set reference points (ground truth).

Drawn in yellow.

Parameters
points0points

◆ setInitialPoints()

void setInitialPoints ( const std::vector< vec3 > & pointsInit)

Set initial points (starting estimate for optimization).

Drawn in magenta.

Parameters
pointsInitpoint

◆ type()

Type type ( ) const
inlineoverridevirtual

Return the type of this view.

Implements GlView.


The documentation for this class was generated from the following file:
Search Tab / S to search, Esc to close