sciGraphics::CameraBridge Class Reference

#include </home/scilab/compilation_chain/sci_checkOut/scilab/modules/renderer/src/cpp/subwinDrawing/CameraBridge.h>

Inheritance diagram for sciGraphics::CameraBridge:

Inheritance graph
[legend]
Collaboration diagram for sciGraphics::CameraBridge:

Collaboration graph
[legend]

Public Member Functions

 CameraBridge (void)
virtual ~CameraBridge (void)
void setViewingArea (double translation[2], double scale[2])
void setAxesFittingScale (double scale[3])
void setAxesTranslation (double translation[3])
void setAxesRotation (double alpha, double theta)
void setAxesCenter (double center[3])
void setAxesNormalizationScale (double scale[3])
virtual void getPixelCoordinates (const double userCoord[3], int pixCoord[2])=0
virtual void getPixelCoordinates (const double userCoords[3], double pixCoords[3])=0
virtual void getPixelCoordinatesRaw (const double userCoords[3], double pixCoords[3])=0
virtual void getSceneCoordinates (const double pixCoords[3], double userCoords[3])=0
virtual void getSceneCoordinatesRaw (const double pixCoords[3], double userCoords[3])=0
virtual void get2dViewPixelCoordinates (const double userCoord[3], int pixCoord[2])=0
virtual void get2dViewPixelCoordinates (const double userCoord[3], double pixCoord[3])=0
virtual void get2dViewCoordinates (const int pixCoords[2], double userCoord2D[2])=0
virtual void renderPosition (void)=0
virtual void replaceCamera (void)=0
virtual void redraw (void)=0
virtual void getViewingArea (int *xPos, int *yPos, int *width, int *height)=0
virtual void getViewport (int viewport[4])=0
void setAxesReverse (bool axisReverseX, bool axisReverseY, bool axisReverseZ)

Protected Attributes

double m_aViewingTranslation [2]
double m_aViewingScale [2]
double m_aAxesFittingScale [3]
double m_aAxesTranslation [3]
double m_aAxesNormalizationScale [3]
double m_dAlpha
double m_dTheta
double m_aBoxCenter [3]
bool m_aAxesReverse [3]

Detailed Description

Definition at line 24 of file CameraBridge.h.


Constructor & Destructor Documentation

sciGraphics::CameraBridge::CameraBridge ( void   ) 

Default constructor

Definition at line 22 of file CameraBridge.cpp.

00023 {
00024   
00025 }

sciGraphics::CameraBridge::~CameraBridge ( void   )  [virtual]

Definition at line 27 of file CameraBridge.cpp.

00028 {
00029   
00030 }


Member Function Documentation

void sciGraphics::CameraBridge::setViewingArea ( double  translation[2],
double  scale[2] 
)

Set the viewing position o

Definition at line 32 of file CameraBridge.cpp.

References m_aViewingScale, and m_aViewingTranslation.

Referenced by sciGraphics::Camera::setViewingArea().

00033 {
00034   m_aViewingTranslation[0] = translation[0];
00035   m_aViewingTranslation[1] = translation[1];
00036 
00037   m_aViewingScale[0] = scale[0];
00038   m_aViewingScale[1] = scale[1];
00039 }

Here is the caller graph for this function:

void sciGraphics::CameraBridge::setAxesFittingScale ( double  scale[3]  ) 

Set the scale to fit with the subwin data bounds

Definition at line 41 of file CameraBridge.cpp.

References m_aAxesFittingScale.

Referenced by sciGraphics::Camera::setSubwinBox().

00042 {
00043   m_aAxesFittingScale[0] = scale[0] ;
00044   m_aAxesFittingScale[1] = scale[1] ;
00045   m_aAxesFittingScale[2] = scale[2] ;
00046 }

Here is the caller graph for this function:

void sciGraphics::CameraBridge::setAxesTranslation ( double  translation[3]  ) 

Set the translation to put the axes into view

Definition at line 48 of file CameraBridge.cpp.

References m_aAxesTranslation.

Referenced by sciGraphics::Camera::setSubwinBox().

00049 {
00050   m_aAxesTranslation[0] = translation[0] ;
00051   m_aAxesTranslation[1] = translation[1] ;
00052   m_aAxesTranslation[2] = translation[2] ;
00053 }

Here is the caller graph for this function:

void sciGraphics::CameraBridge::setAxesRotation ( double  alpha,
double  theta 
)

Set the rotation of axes in accordance with viewing angles

Parameters:
alpha rotation around Y axis
theta rotation around X axis

Definition at line 55 of file CameraBridge.cpp.

References m_dAlpha, and m_dTheta.

Referenced by sciGraphics::Camera::setRotationAngles().

00056 {
00057   m_dAlpha = alpha;
00058   m_dTheta = theta;
00059 }

Here is the caller graph for this function:

void sciGraphics::CameraBridge::setAxesCenter ( double  center[3]  ) 

Set the center of the axes around which the box turns.

Definition at line 61 of file CameraBridge.cpp.

References m_aBoxCenter.

Referenced by sciGraphics::Camera::setSubwinBox().

00062 {
00063   m_aBoxCenter[0] = center[0];
00064   m_aBoxCenter[1] = center[1];
00065   m_aBoxCenter[2] = center[2];
00066 }

Here is the caller graph for this function:

void sciGraphics::CameraBridge::setAxesNormalizationScale ( double  scale[3]  ) 

Set scale to mormalize values between 0 and 1.

Definition at line 68 of file CameraBridge.cpp.

References m_aAxesNormalizationScale.

Referenced by sciGraphics::Camera::setSubwinBox().

00069 {
00070   m_aAxesNormalizationScale[0] = scale[0];
00071   m_aAxesNormalizationScale[1] = scale[1];
00072   m_aAxesNormalizationScale[2] = scale[2];
00073 }

Here is the caller graph for this function:

virtual void sciGraphics::CameraBridge::getPixelCoordinates ( const double  userCoord[3],
int  pixCoord[2] 
) [pure virtual]

Convert user coordinates to pixel coordinates.

Implemented in sciGraphics::CameraJoGL.

Referenced by sciGraphics::Camera::getPixelCoordinates().

Here is the caller graph for this function:

virtual void sciGraphics::CameraBridge::getPixelCoordinates ( const double  userCoords[3],
double  pixCoords[3] 
) [pure virtual]

Convert user coordinates to pixel coordinates including depth value

Implemented in sciGraphics::CameraJoGL.

virtual void sciGraphics::CameraBridge::getPixelCoordinatesRaw ( const double  userCoords[3],
double  pixCoords[3] 
) [pure virtual]

Convert user coordinates to pixel coordinates including depth value. Does not take pixel coordinates into account.

Implemented in sciGraphics::CameraJoGL.

Referenced by sciGraphics::Camera::getPixelCoordinatesRaw().

Here is the caller graph for this function:

virtual void sciGraphics::CameraBridge::getSceneCoordinates ( const double  pixCoords[3],
double  userCoords[3] 
) [pure virtual]

Unproject a 3 position in pixels into the standard scene coordinates

Implemented in sciGraphics::CameraJoGL.

Referenced by sciGraphics::Camera::getSceneCoordinates().

Here is the caller graph for this function:

virtual void sciGraphics::CameraBridge::getSceneCoordinatesRaw ( const double  pixCoords[3],
double  userCoords[3] 
) [pure virtual]

Unproject a 3 position in pixels into the standard scene coordinates Does not take logarithmic sclae into account.

Implemented in sciGraphics::CameraJoGL.

Referenced by sciGraphics::Camera::getSceneCoordinatesRaw().

Here is the caller graph for this function:

virtual void sciGraphics::CameraBridge::get2dViewPixelCoordinates ( const double  userCoord[3],
int  pixCoord[2] 
) [pure virtual]

Convert user coordinates to pixel coordinated using the 2d view.

Implemented in sciGraphics::CameraJoGL.

Referenced by sciGraphics::Camera::get2dViewPixelCoordinates().

Here is the caller graph for this function:

virtual void sciGraphics::CameraBridge::get2dViewPixelCoordinates ( const double  userCoord[3],
double  pixCoord[3] 
) [pure virtual]

Convert user coordinates to pixel coordinated using the 2d view.

Implemented in sciGraphics::CameraJoGL.

virtual void sciGraphics::CameraBridge::get2dViewCoordinates ( const int  pixCoords[2],
double  userCoord2D[2] 
) [pure virtual]

Find coordinates in 2D view from pixel ones

Implemented in sciGraphics::CameraJoGL.

Referenced by sciGraphics::Camera::get2dViewCoordinates().

Here is the caller graph for this function:

virtual void sciGraphics::CameraBridge::renderPosition ( void   )  [pure virtual]

Position the view and view area accordingly to previous calls.

Implemented in sciGraphics::CameraJoGL.

Referenced by sciGraphics::Camera::draw(), and sciGraphics::Camera::renderPosition().

Here is the caller graph for this function:

virtual void sciGraphics::CameraBridge::replaceCamera ( void   )  [pure virtual]

Put back camera to default position.

Implemented in sciGraphics::CameraJoGL.

Referenced by sciGraphics::Camera::replaceCamera().

Here is the caller graph for this function:

virtual void sciGraphics::CameraBridge::redraw ( void   )  [pure virtual]

Display the camera using precomputed data

Implemented in sciGraphics::CameraJoGL.

Referenced by sciGraphics::Camera::redraw().

Here is the caller graph for this function:

virtual void sciGraphics::CameraBridge::getViewingArea ( int *  xPos,
int *  yPos,
int *  width,
int *  height 
) [pure virtual]

Get the position and size of the rectangle in which the axes box must fit

Implemented in sciGraphics::CameraJoGL.

Referenced by sciGraphics::Camera::getViewingArea().

Here is the caller graph for this function:

virtual void sciGraphics::CameraBridge::getViewport ( int  viewport[4]  )  [pure virtual]

Get viewport of the canvas

Implemented in sciGraphics::CameraJoGL.

Referenced by sciGraphics::Camera::getViewport().

Here is the caller graph for this function:

void sciGraphics::CameraBridge::setAxesReverse ( bool  axisReverseX,
bool  axisReverseY,
bool  axisReverseZ 
)

Add an axes reverse strategy.

Definition at line 75 of file CameraBridge.cpp.

References m_aAxesReverse.

Referenced by sciGraphics::Camera::setAxesReverse().

00076 {
00077   m_aAxesReverse[0] = axisReverseX;
00078   m_aAxesReverse[1] = axisReverseY;
00079   m_aAxesReverse[2] = axisReverseZ;
00080 }

Here is the caller graph for this function:


Field Documentation

Translation between the origin of rendering canvas and the current viewing area. Should be positive since the view is inside the canvas.

Definition at line 146 of file CameraBridge.h.

Referenced by sciGraphics::CameraJoGL::getViewingArea(), sciGraphics::CameraJoGL::renderPosition(), and setViewingArea().

Scaling between the rendering canvas and current viewing area. Should be lower than 1 since the viewing area is smaller than the canvas.

Definition at line 152 of file CameraBridge.h.

Referenced by sciGraphics::CameraJoGL::getViewingArea(), sciGraphics::CameraJoGL::renderPosition(), and setViewingArea().

Scale modification to fit axes coordinates

Definition at line 155 of file CameraBridge.h.

Referenced by sciGraphics::CameraJoGL::renderPosition(), and setAxesFittingScale().

Translation to put the axes in view

Definition at line 158 of file CameraBridge.h.

Referenced by sciGraphics::CameraJoGL::renderPosition(), and setAxesTranslation().

Scale modification to map data on the [0,1]x[0,1]x[0,1] cube.

Definition at line 161 of file CameraBridge.h.

Referenced by sciGraphics::CameraJoGL::renderPosition(), and setAxesNormalizationScale().

Rotation angles

Definition at line 164 of file CameraBridge.h.

Referenced by sciGraphics::CameraJoGL::renderPosition(), and setAxesRotation().

Definition at line 165 of file CameraBridge.h.

Referenced by sciGraphics::CameraJoGL::renderPosition(), and setAxesRotation().

Center of the axes box

Definition at line 168 of file CameraBridge.h.

Referenced by sciGraphics::CameraJoGL::renderPosition(), and setAxesCenter().

list of axes reverse strategies

Definition at line 171 of file CameraBridge.h.

Referenced by sciGraphics::CameraJoGL::renderPosition(), and setAxesReverse().


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

Generated on Tue Sep 9 18:35:28 2008 for Scilab [trunk] by  doxygen 1.5.5