v2.0.0
Loading...
Searching...
No Matches
DISP3DLIB::DipoleObject Class Reference

Renderable dipole arrow set with instanced GPU rendering. More...

#include <dipoleobject.h>

Public Member Functions

 DipoleObject ()
 ~DipoleObject ()
void load (const INVLIB::InvEcdSet &ecdSet)
void applyTransform (const QMatrix4x4 &trans)
InstancedStreams streams () const
const RenderKey & renderKey () const
int indexCount () const
int instanceCount () const
bool isVisible () const
void setVisible (bool visible)
bool boundingBox (QVector3D &min, QVector3D &max) const
void setSelected (int index, bool selected)
int intersect (const QVector3D &rayOrigin, const QVector3D &rayDir, float &dist) const

Detailed Description

Renderable dipole arrow set with instanced GPU rendering.

Renderable dipole object that builds instanced arrow geometry from an InvEcdSet and provides its CPU streams for instanced rendering.

Definition at line 55 of file dipoleobject.h.

Constructor & Destructor Documentation

◆ DipoleObject()

DISP3DLIB::DipoleObject::DipoleObject ( )
default

◆ ~DipoleObject()

DISP3DLIB::DipoleObject::~DipoleObject ( )
default

Member Function Documentation

◆ applyTransform()

void DISP3DLIB::DipoleObject::applyTransform ( const QMatrix4x4 & trans)

Definition at line 105 of file dipoleobject.cpp.

◆ boundingBox()

bool DISP3DLIB::DipoleObject::boundingBox ( QVector3D & min,
QVector3D & max ) const

Axis-aligned bounds of the (transformed) dipole positions.

Parameters
[out]minMinimum corner.
[out]maxMaximum corner.
Returns
False if no dipoles are loaded.

Definition at line 123 of file dipoleobject.cpp.

◆ indexCount()

int DISP3DLIB::DipoleObject::indexCount ( ) const
inline

Definition at line 75 of file dipoleobject.h.

◆ instanceCount()

int DISP3DLIB::DipoleObject::instanceCount ( ) const
inline

Definition at line 79 of file dipoleobject.h.

◆ intersect()

int DISP3DLIB::DipoleObject::intersect ( const QVector3D & rayOrigin,
const QVector3D & rayDir,
float & dist ) const

Test ray intersection with dipoles.

Parameters
[in]rayOriginRay origin in world space.
[in]rayDirRay direction (normalized).
[out]distDistance to intersection.
Returns
Index of intersected dipole, or -1 if none.

Definition at line 248 of file dipoleobject.cpp.

◆ isVisible()

bool DISP3DLIB::DipoleObject::isVisible ( ) const
inline

Definition at line 84 of file dipoleobject.h.

◆ load()

void DISP3DLIB::DipoleObject::load ( const INVLIB::InvEcdSet & ecdSet)

Definition at line 43 of file dipoleobject.cpp.

◆ renderKey()

const RenderKey & DISP3DLIB::DipoleObject::renderKey ( ) const
inline
Returns
Identity of this object in the renderer's GPU cache.

Definition at line 70 of file dipoleobject.h.

◆ setSelected()

void DISP3DLIB::DipoleObject::setSelected ( int index,
bool selected )

Definition at line 307 of file dipoleobject.cpp.

◆ setVisible()

void DISP3DLIB::DipoleObject::setVisible ( bool visible)
inline

Definition at line 88 of file dipoleobject.h.

◆ streams()

InstancedStreams DISP3DLIB::DipoleObject::streams ( ) const
Returns
CPU streams of the arrow shape and of one instance per dipole.

Definition at line 34 of file dipoleobject.cpp.


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