FirstHitBitmap Class Reference
A specialization of Bitmap for first hit positions. More...
#include <labelingmath.h>
Inheritance diagram for FirstHitBitmap:
Public Member Functions | |
| tgt::vec3 | getPixel3Ch (int x, int y) |
| Returns the first hit point at (x,y) in object! coordinates. | |
| tgt::vec3 | calcNormal (int x, int y) |
| Calculates the surface normal at (x,y) by using its neighbouring first hit points. | |
| tgt::vec3 | projectToViewport (tgt::vec3 point, bool round=true) |
| Transforms a point from object coordinates of the proxy geometry to viewport coordinates. | |
| tgt::vec3 | inverseProject (tgt::vec3 point) |
| Transforms a point from viewport coordinates to object coordinates. | |
| void | setVolumeSize (tgt::vec3 volumeSize) |
| Sets the dimension of the proxy geometry. | |
| void | calcTransformationMatrix (tgt::mat4 viewMatrix, tgt::mat4 projectionMatrix, tgt::ivec2 viewportSize) |
| Calculates the matrix that transforms from object coordinates to viewport coordinates and saves it internally. | |
Detailed Description
A specialization of Bitmap for first hit positions.
Modifies / adds some functions useful for first hit positions.
Definition at line 584 of file labelingmath.h.
Member Function Documentation
| tgt::vec3 calcNormal | ( | int | x, | |
| int | y | |||
| ) | [inline] |
Calculates the surface normal at (x,y) by using its neighbouring first hit points.
The normal is directed to the viewer and calculated in object coordinates.
Definition at line 596 of file labelingmath.h.
| void calcTransformationMatrix | ( | tgt::mat4 | viewMatrix, | |
| tgt::mat4 | projectionMatrix, | |||
| tgt::ivec2 | viewportSize | |||
| ) | [inline] |
Calculates the matrix that transforms from object coordinates to viewport coordinates and saves it internally.
Definition at line 633 of file labelingmath.h.
Transforms a point from object coordinates of the proxy geometry to viewport coordinates.
- Parameters:
-
round if set to true, the x and y components are rounded to the next integer
Definition at line 606 of file labelingmath.h.