CrystalSpace

Public API Reference

Main Page   Modules   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

csPolyTextureMapping Struct Reference

This structure holds mapping information to map the texture on a polygon. More...

#include <polygon.h>

List of all members.

Public Methods

int GetShiftU () const
 Get the power of the lowest power of 2 that is not smaller than the texture bounding box' width. More...

int GetIMinU () const
 Get the rounded u-value of the textures bounding box' lower left corner. More...

int GetIMinV () const
 Get the rounded v-value of the textures bounding box' lower left corner. More...

void GetTextureBox (float &fMinU, float &fMinV, float &fMaxU, float &fMaxV) const
 Get texture box. More...

float GetFDU () const
 Get the u-value of the textures bounding box' lower left corner. More...

float GetFDV () const
 Get the v-value of the textures bounding box' lower left corner. More...


Public Attributes

csMatrix3 m_obj2tex
 Transformation from object to texture space. More...

csVector3 v_obj2tex
 Translation from object to texture space. More...

int Imin_u
 Bounding box of corresponding polygon in 2D texture space. More...

int Imin_v
 Bounding box of corresponding polygon in 2D texture space. More...

float Fmin_u
 fp bounding box (0..1 texture space). More...

float Fmin_v
 fp bounding box (0..1 texture space). More...

float Fmax_u
 fp bounding box (0..1 texture space). More...

float Fmax_v
 fp bounding box (0..1 texture space). More...


Detailed Description

This structure holds mapping information to map the texture on a polygon.

You can get it from the iPolygonTexture below.

Definition at line 311 of file polygon.h.


Member Function Documentation

float csPolyTextureMapping::GetFDU   const [inline]
 

Get the u-value of the textures bounding box' lower left corner.

Definition at line 356 of file polygon.h.

float csPolyTextureMapping::GetFDV   const [inline]
 

Get the v-value of the textures bounding box' lower left corner.

Definition at line 358 of file polygon.h.

int csPolyTextureMapping::GetIMinU   const [inline]
 

Get the rounded u-value of the textures bounding box' lower left corner.

Definition at line 342 of file polygon.h.

References Imin_u.

int csPolyTextureMapping::GetIMinV   const [inline]
 

Get the rounded v-value of the textures bounding box' lower left corner.

Definition at line 344 of file polygon.h.

References Imin_v.

int csPolyTextureMapping::GetShiftU   const [inline]
 

Get the power of the lowest power of 2 that is not smaller than the texture bounding box' width.

that is: 2^shift_u >= texbbox-width > 2^(shift_u-1)

Definition at line 339 of file polygon.h.

void csPolyTextureMapping::GetTextureBox float &    fMinU,
float &    fMinV,
float &    fMaxU,
float &    fMaxV
const [inline]
 

Get texture box.

Definition at line 346 of file polygon.h.

References Fmax_u, Fmax_v, Fmin_u, and Fmin_v.


Member Data Documentation

float csPolyTextureMapping::Fmax_u
 

fp bounding box (0..1 texture space).

Definition at line 329 of file polygon.h.

Referenced by GetTextureBox.

float csPolyTextureMapping::Fmax_v
 

fp bounding box (0..1 texture space).

Definition at line 329 of file polygon.h.

Referenced by GetTextureBox.

float csPolyTextureMapping::Fmin_u
 

fp bounding box (0..1 texture space).

Definition at line 329 of file polygon.h.

Referenced by GetTextureBox.

float csPolyTextureMapping::Fmin_v
 

fp bounding box (0..1 texture space).

Definition at line 329 of file polygon.h.

Referenced by GetTextureBox.

int csPolyTextureMapping::Imin_u
 

Bounding box of corresponding polygon in 2D texture space.

Note that the u-axis of this bounding box is made a power of 2 for efficiency reasons.

Definition at line 326 of file polygon.h.

Referenced by GetIMinU.

int csPolyTextureMapping::Imin_v
 

Bounding box of corresponding polygon in 2D texture space.

Note that the u-axis of this bounding box is made a power of 2 for efficiency reasons.

Definition at line 326 of file polygon.h.

Referenced by GetIMinV.

csMatrix3 csPolyTextureMapping::m_obj2tex
 

Transformation from object to texture space.

Definition at line 314 of file polygon.h.

csVector3 csPolyTextureMapping::v_obj2tex
 

Translation from object to texture space.

Definition at line 316 of file polygon.h.


The documentation for this struct was generated from the following file:
Generated for Crystal Space by doxygen 1.2.14