Panda3D

- Main Page
- Packages
- Classes

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Static Public Member Functions

# TexMatrixAttrib Class Reference

Applies a transform matrix to UV's before they are rendered. More...

Inheritance diagram for TexMatrixAttrib:

List of all members.

## Public Member Functions
RenderAttrib const | addStage (TextureStage stage, TransformState const transform, int override)
| Returns a new TexMatrixAttrib just like this one, with the indicated transform for the given stage.
RenderAttrib const | addStage (TextureStage stage, TransformState const transform)
| Returns a new TexMatrixAttrib just like this one, with the indicated transform for the given stage.
int | getGeomRendering (int geom_rendering)
| Returns the union of the Geom.GeomRendering bits that will be required once this TexMatrixAttrib is applied to a geom which includes the indicated geom_rendering bits.
Mat4 const | getMat ()
| Returns the transformation matrix associated with the default texture stage.
Mat4 const | getMat (TextureStage stage)
| Returns the transformation matrix associated with the indicated texture stage, or identity matrix if nothing is associated with the indicated stage.
int | getNumStages ()
| Returns the number of stages that are represented by this attrib.
int | getOverride (TextureStage stage)
| Returns the override value associated with the indicated stage.
TextureStage | getStage (int n)
| Returns the nth stage that is represented by this attrib.
list | getStages ()
TransformState const | getTransform (TextureStage stage)
| Returns the transformation associated with the indicated texture stage, or identity matrix if nothing is associated with the indicated stage.
bool | hasStage (TextureStage stage)
| Returns true if there is a transform associated with the indicated stage, or false otherwise (in which case get_transform(stage) will return the identity transform).
bool | isEmpty ()
| Returns true if no stages are defined in the TexMatrixAttrib, false if at least one is.
RenderAttrib const | removeStage (TextureStage stage)
| Returns a new TexMatrixAttrib just like this one, with the indicated stage removed.
## Static Public Member Functions
static int | getClassSlot ()
static TypeHandle | getClassType ()
static RenderAttrib const | make (Mat4 const mat)
| Constructs a TexMatrixAttrib that applies the indicated matrix to the default texture stage.
static RenderAttrib const | make ()
| Constructs a TexMatrixAttrib that applies no stages at all.
static RenderAttrib const | make (TextureStage stage, TransformState const transform)
| Constructs a TexMatrixAttrib that applies the indicated transform to the named texture stage.
static RenderAttrib const | makeDefault ()
| Returns a RenderAttrib that corresponds to whatever the standard default properties for render attributes of this type ought to be.

## Detailed Description

Applies a transform matrix to UV's before they are rendered.

## Member Function Documentation

RenderAttrib const addStage | ( | TextureStage | stage,
|  | TransformState const | transform,
|  | int | override
| ) |  |

Returns a new TexMatrixAttrib just like this one, with the indicated transform for the given stage.

If this stage already exists, its transform is replaced.

RenderAttrib const addStage | ( | TextureStage | stage,
|  | TransformState const | transform
| ) |  |

Returns a new TexMatrixAttrib just like this one, with the indicated transform for the given stage.

If this stage already exists, its transform is replaced.

static int getClassSlot | ( |  | ) | `[static]`

static TypeHandle getClassType | ( |  | ) | `[static]`

Reimplemented from RenderAttrib.

int getGeomRendering | ( | int | geom_rendering | ) |

Returns the union of the Geom.GeomRendering bits that will be required once this TexMatrixAttrib is applied to a geom which includes the indicated geom_rendering bits.

Mat4 const getMat | ( |  | ) |

Returns the transformation matrix associated with the default texture stage.

Mat4 const getMat | ( | TextureStage | stage | ) |

Returns the transformation matrix associated with the indicated texture stage, or identity matrix if nothing is associated with the indicated stage.

int getNumStages | ( |  | ) |

Returns the number of stages that are represented by this attrib.

int getOverride | ( | TextureStage | stage | ) |

Returns the override value associated with the indicated stage.

TextureStage getStage | ( | int | n | ) |

Returns the nth stage that is represented by this attrib.

The TextureStages are in no particular order.

list getStages | ( |  | ) |

TransformState const getTransform | ( | TextureStage | stage | ) |

Returns the transformation associated with the indicated texture stage, or identity matrix if nothing is associated with the indicated stage.

bool hasStage | ( | TextureStage | stage | ) |

Returns true if there is a transform associated with the indicated stage, or false otherwise (in which case get_transform(stage) will return the identity transform).

bool isEmpty | ( |  | ) |

Returns true if no stages are defined in the TexMatrixAttrib, false if at least one is.

static RenderAttrib const make | ( | TextureStage | stage,
|  | TransformState const | transform
| ) |  | `[static]`

Constructs a TexMatrixAttrib that applies the indicated transform to the named texture stage.

static RenderAttrib const make | ( |  | ) | `[static]`

Constructs a TexMatrixAttrib that applies no stages at all.

static RenderAttrib const make | ( | Mat4 const | mat | ) | `[static]`

Constructs a TexMatrixAttrib that applies the indicated matrix to the default texture stage.

This interface is deprecated.

static RenderAttrib const makeDefault | ( |  | ) | `[static]`

Returns a RenderAttrib that corresponds to whatever the standard default properties for render attributes of this type ought to be.

RenderAttrib const removeStage | ( | TextureStage | stage | ) |

Returns a new TexMatrixAttrib just like this one, with the indicated stage removed.

All Classes Namespaces Functions Variables Enumerations Enumerator Properties