Stores the current 3D texture coordinates. More...
#include <Inventor/elements/SoTextureCoordinate3Element.h>
Classes | |
struct | SoTexCoord3Data |
Public Types | |
enum | CoordType { EXPLICIT = 1, FUNCTION = 2 } |
Public Member Functions | |
virtual CoordType | getType (int unit=0) const |
const SbVec4f & | get (const SbVec3f &point, const SbVec3f &normal, int unit=0) const |
int32_t | getNum (int unit=0) const |
SbBool | is3D (int unit=0) const |
SbBool | isForceSending (int unit=0) const |
const SbVec3f & | get3 (int index, int unit=0) const |
const SbVec4f & | get4 (int index, int unit=0) const |
virtual void | print (FILE *fp) const |
virtual void | push (SoState *) |
Static Public Member Functions | |
static SoType | getClassTypeId () |
static int | getClassStackIndex () |
static void | setDefault (SoState *state, SoNode *node) |
static void | setFunction (SoState *state, SoNode *node, SoTextureCoordinate3FunctionCB *func, void *userData, SbBool frcSend=FALSE) |
static void | set3 (SoState *state, SoNode *node, int32_t numCoords, const SbVec3f *coords, SbBool frcSend=FALSE) |
static void | set4 (SoState *state, SoNode *node, int32_t numCoords, const SbVec4f *coords, SbBool frcSend=FALSE) |
static CoordType | getType (SoState *state, int unit=0) |
static const SoTextureCoordinate3Element * | getInstance (SoState *state) |
This element stores the current 3D texture coordinates.
SoTextureCoordinate3, SoVertexProperty
const SbVec4f& SoTextureCoordinate3Element::get | ( | const SbVec3f & | point, | |
const SbVec3f & | normal, | |||
int | unit = 0 | |||
) | const |
Given point and normal, returns texture coordinate.
(The r coordinate will be 0.0 and the q will be 1.0 until we get 3D texture coordinate functions.)
const SbVec3f& SoTextureCoordinate3Element::get3 | ( | int | index, | |
int | unit = 0 | |||
) | const |
Returns the indexed coordinate from an element as a 3- or 4-vector, converting if necessary.
const SbVec4f& SoTextureCoordinate3Element::get4 | ( | int | index, | |
int | unit = 0 | |||
) | const |
static int SoTextureCoordinate3Element::getClassStackIndex | ( | ) | [static] |
Returns the stack id for this element.
Reimplemented from SoReplacedTextureElement.
Reimplemented in SoGLTextureCoordinate3Element.
static SoType SoTextureCoordinate3Element::getClassTypeId | ( | ) | [static] |
Returns the type identifier for this class.
Reimplemented from SoReplacedTextureElement.
Reimplemented in SoGLTextureCoordinate3Element.
static const SoTextureCoordinate3Element* SoTextureCoordinate3Element::getInstance | ( | SoState * | state | ) | [static] |
Returns the top (current) instance of the element in the state.
The get routines are called on an instance because it is more efficient than calling a static method that looks up the element in the state for every coordinate.
Reimplemented in SoGLTextureCoordinate3Element.
int32_t SoTextureCoordinate3Element::getNum | ( | int | unit = 0 |
) | const |
Returns the number of coordinate points in an instance.
virtual CoordType SoTextureCoordinate3Element::getType | ( | int | unit = 0 |
) | const [virtual] |
Reimplemented in SoGLTextureCoordinate3Element.
Returns code indicating what has been set in state/element.
SbBool SoTextureCoordinate3Element::is3D | ( | int | unit = 0 |
) | const |
SbBool SoTextureCoordinate3Element::isForceSending | ( | int | unit = 0 |
) | const |
virtual void SoTextureCoordinate3Element::print | ( | FILE * | fp | ) | const [virtual] |
Prints element (for debugging).
Reimplemented from SoReplacedTextureElement.
virtual void SoTextureCoordinate3Element::push | ( | SoState * | ) | [virtual] |
Overrides push() method to copy values from next instance in the stack.
Reimplemented from SoReplacedTextureElement.
Reimplemented in SoGLTextureCoordinate3Element.
static void SoTextureCoordinate3Element::set3 | ( | SoState * | state, | |
SoNode * | node, | |||
int32_t | numCoords, | |||
const SbVec3f * | coords, | |||
SbBool | frcSend = FALSE | |||
) | [static] |
static void SoTextureCoordinate3Element::set4 | ( | SoState * | state, | |
SoNode * | node, | |||
int32_t | numCoords, | |||
const SbVec4f * | coords, | |||
SbBool | frcSend = FALSE | |||
) | [static] |
Sets the current texture coordinates, in any of several ways: EXPLICIT, no coordinates (shapes will generate):.
static void SoTextureCoordinate3Element::setFunction | ( | SoState * | state, | |
SoNode * | node, | |||
SoTextureCoordinate3FunctionCB * | func, | |||
void * | userData, | |||
SbBool | frcSend = FALSE | |||
) | [static] |