RenderInfo Class Reference

RenderInfo Class Reference

#include <bitmap.h>

Class Description

See also
Class Ray, Class Point2, Class Point3.

Description:
This class provides information about the rendering environment. All methods of this class are implemented by the system.
Data Members:
ProjectionType projType;

The projection type: One of the following values:

ProjPerspective

ProjParallel

float kx,ky;

3D to 2D projection scale factor.

float xc,yc;

The screen origin.

BOOL fieldRender;

Indicates if the image is field rendered.

BOOL fieldOdd;

If TRUE, the first field is Odd lines.

TimeValue renderTime[2];

Render time for the 2 fields, if field rendering. If not, use renderTime[0].

Matrix3 worldToCam[2];

The world to camera transformation matrix; worldToCam[0] is for field 0, worldToCam[1] is for field 1. Use worldToCam[0] if not field rendering.

Matrix3 camToWorld[2];

The camera to world transformation matrix; camToWorld[0] is for field 0, camToWorld[1] is for field 1. Use camToWorld[0] if not field rendering.

Rect region;

This data member is available in release 4.0 and later only.

This rectangle holds the sub-region in the image that was rendered if the last render was a region render. If it was not a region render then the rectangle is empty.
+ Inheritance diagram for RenderInfo:

Public Member Functions

 RenderInfo ()
 
BMMExport Point2 MapWorldToScreen (Point3 p, int field=0)
 
BMMExport Point2 MapCamToScreen (Point3 p)
 
BMMExport Ray MapScreenToCamRay (Point2 p)
 
BMMExport Ray MapScreenToWorldRay (Point2 p, int field=0)
 

Public Attributes

ProjectionType projType
 
float kx
 
float ky
 
float xc
 
float yc
 
BOOL fieldRender
 
BOOL fieldOdd
 
TimeValue renderTime [2]
 
Matrix3 worldToCam [2]
 
Matrix3 camToWorld [2]
 
Rect region
 

Additional Inherited Members

- Static Public Member Functions inherited from MaxHeapOperators
static UtilExport voidoperator new (size_t size)
 Standard new operator used to allocate objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e)
 Standard new operator used to allocate objects if there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate objects that takes the type of memory, filename and line number where the new was called If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate objects that takes the filename and line number where the new was called If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new (size_t size, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate objects that takes extra flags to specify special operations If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, int block_type, const char *filename, int line)
 New operator used to allocate arrays of objects. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, const char *filename, int line)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport voidoperator new[] (size_t size, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, an exception will be thrown. More...
 
static UtilExport voidoperator new[] (size_t size, const std::nothrow_t &e, unsigned long flags)
 New operator used to allocate arrays of objects If there is insufficient memory, NULL will be returned. More...
 
static UtilExport void operator delete (void *ptr)
 Standard delete operator used to deallocate an object If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an object If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an object that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an object that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete (void *ptr, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an object that takes extra flags to specify special operations If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e)
 Standard delete operator used to deallocate an array of objects If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, int block_type, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the type of memory, filename and line number where the delete was called If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, const char *filename, int line)
 Delete operator used to deallocate an array of objects that takes the filename and line number where the delete was called If the pointer is invalid, nothing will happen. More...
 
static UtilExport void operator delete[] (void *ptr, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport void operator delete[] (void *ptr, const std::nothrow_t &e, unsigned long flags)
 Delete operator used to deallocate an array of objects that takes extra flags to specify special operations If the pointer is invalid, an exception will be thrown. More...
 
static UtilExport voidoperator new (size_t size, void *placement_ptr)
 Placement new operator. More...
 
static UtilExport void operator delete (void *ptr, void *placement_ptr)
 Placement delete operator. More...
 

Constructor & Destructor Documentation

Remarks
Constructor. The data members are initialized as follows:

renderTime[0] = renderTime[1] = 0;

worldToCam[0].IdentityMatrix();

worldToCam[1].IdentityMatrix();

camToWorld[0].IdentityMatrix();

camToWorld[1].IdentityMatrix();

fieldRender = fieldOdd = FALSE;

projType = ProjPerspective;

kx = ky = 1.0f;

xc = yc = 400.0f;

Member Function Documentation

BMMExport Point2 MapWorldToScreen ( Point3  p,
int  field = 0 
)
inline
Remarks
Maps the specified world point to a screen point.
Parameters:
Point3 p

The world point.

int field=0

The field order. This specifies which camToWorld matrix is used in the conversion.
Returns
The 2D screen point.
615 { return MapCamToScreen(worldToCam[field]*p);}
Matrix3 worldToCam[2]
Definition: bitmap.h:604
BMMExport Point2 MapCamToScreen(Point3 p)
BMMExport Point2 MapCamToScreen ( Point3  p)
Remarks
Maps the specified point in camera space to screen space and returns it.
Parameters:
Point3 p

The point to convert.
BMMExport Ray MapScreenToCamRay ( Point2  p)
Remarks
Returns the viewing ray through the screen point, in camera space.
Parameters:
Point2 p

The screen point.
BMMExport Ray MapScreenToWorldRay ( Point2  p,
int  field = 0 
)
Remarks
Returns the viewing ray through the specified screen point, in world space.
Parameters:
Point2 p

The screen space point.

int field=0

The field order - specifies which camToWorld matrix is used in the conversion.

Member Data Documentation

ProjectionType projType
float kx
float ky
float xc
float yc
BOOL fieldRender
BOOL fieldOdd
TimeValue renderTime[2]
Matrix3 worldToCam[2]
Matrix3 camToWorld[2]
Rect region