# CUDARayCasting::Render Class Reference

Opengl Render tailored specifically for CUDARayCasting test. It can render these 2d geometry:

- Points
- Lines
- Curves It only supports a material being a configurable emissive color.

More...

`#include <Render.h>`

List of all members.

## Public Member Functions
| Render (int width, int height)
| Constructor.
| ~Render (void)
| Destructor.
void | Initialize (boost::shared_array< unsigned char > dataPtr, int texWidth, int texHeight, int texDepth, boost::shared_array< float > transferFunctionPtr, int transferFunctionWidth, float step, int stepNumber, const Matrix4x4 &viewMatrix, const Matrix4x4 &volumeMatrix, const Vector3 &bboxMin, const Vector3 &bboxMax)
| Loads a default opengl configuration.
void | Reshape (int width, int height)
| Reshapes opengl viewport and initialize states.
void | BeginFrame (void)
| Begins render frame.
void | EndFrame (void)
| Ends render frame.
void | DrawVolume (void)
void | UpdateTransferFunction (void)
void | SetStep (float step)
void | SetStepNumber (int stepNumber)
void | DrawString (const std::string &s, int x, int y, const Vector3 &color)
void | SetCamera (const Matrix4x4 &viewMatrix)
void | SetVolumeMatrix (const Matrix4x4 &volumeMatrix)

## Detailed Description

Opengl Render tailored specifically for CUDARayCasting test. It can render these 2d geometry:

- Points
- Lines
- Curves It only supports a material being a configurable emissive color.

## Member Function Documentation

void Render::Initialize | ( | boost::shared_array< unsigned char > | dataPtr,
|  | int | texWidth,
|  | int | texHeight,
|  | int | texDepth,
|  | boost::shared_array< float > | transferFunctionPtr,
|  | int | transferFunctionWidth,
|  | float | step,
|  | int | stepNumber,
|  | const Matrix4x4 & | viewMatrix,
|  | const Matrix4x4 & | volumeMatrix,
|  | const Vector3 & | bboxMin,
|  | const Vector3 & | bboxMax |
| ) |  |  |

Loads a default opengl configuration.

Parameters:

  | width | render window width
  | height | render window height

Note:
  It's very ugly to have a separete method for initialization and don't use the constructor.

glewGetErrorString(err)

TODO Check CUDA capabilities

void Render::Reshape | ( | int | width,
|  | int | height |
| ) |  |  |

Reshapes opengl viewport and initialize states.

Parameters:

  | width | render window width
  | height | render window height

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

- src/CUDARayCasting/Render.h
- src/CUDARayCasting/Render.cpp