SCIRun
5.0
|
Basic camera class for spire, mimicking SCIRun v4. More...
#include <SRCamera.h>
Public Member Functions | |
SRCamera (SRInterface &iface, std::shared_ptr< spire::Interface > spire) | |
virtual | ~SRCamera () |
const spire::M44 & | getWorldToProjection () const |
const spire::M44 & | getWorldToView () const |
const spire::M44 & | getViewToWorld () const |
const spire::M44 & | getViewToProjection () const |
void | setAsPerspective () |
Sets this camera to use a perspective projection transformation. More... | |
void | setAsOrthographic (float halfWidth, float halfHeight) |
Sets this camera to use an orthographic projection transformation. More... | |
void | applyTransform () |
void | mouseDownEvent (const glm::ivec2 &pos, SRInterface::MouseButton btn) |
Handle mouse down. More... | |
void | mouseMoveEvent (const glm::ivec2 &pos, SRInterface::MouseButton btn) |
Handle mouse movement. More... | |
void | mouseWheelEvent (int32_t delta) |
Handle mouse wheel event. More... | |
void | doAutoView (const Core::Geometry::BBox &bbox) |
Perform autoview. More... | |
Static Public Member Functions | |
static float | getDefaultFOVY () |
static float | getDefaultZNear () |
static float | getDefaultZFar () |
Basic camera class for spire, mimicking SCIRun v4.
SRCamera | ( | SRInterface & | iface, |
std::shared_ptr< spire::Interface > | spire | ||
) |
|
virtual |
void applyTransform | ( | ) |
Sets the current view transform (view to world space). This should be removed.
void doAutoView | ( | const Core::Geometry::BBox & | bbox | ) |
Perform autoview.
|
inlinestatic |
Default camera settings
|
inlinestatic |
|
inlinestatic |
|
inline |
|
inline |
|
inline |
|
inline |
void mouseDownEvent | ( | const glm::ivec2 & | pos, |
SRInterface::MouseButton | btn | ||
) |
Handle mouse down.
void mouseMoveEvent | ( | const glm::ivec2 & | pos, |
SRInterface::MouseButton | btn | ||
) |
Handle mouse movement.
void mouseWheelEvent | ( | int32_t | delta | ) |
Handle mouse wheel event.
void setAsOrthographic | ( | float | halfWidth, |
float | halfHeight | ||
) |
Sets this camera to use an orthographic projection transformation.
void setAsPerspective | ( | ) |
Sets this camera to use a perspective projection transformation.