SketchUp C API
|
SUMaterialInput contains information that is needed to apply a material to a face. More...
#include <SketchUpAPI/model/geometry_input.h>
Data Fields | |
size_t | num_uv_coords |
struct SUPoint2D | uv_coords [4] |
Texture coordinates. | |
size_t | vertex_indices [4] |
SUMaterialRef | material |
Material to be applied. | |
SUMaterialInput contains information that is needed to apply a material to a face.
The conventional method for applying a material to a face is to use 1 to 4 UV coordinates, which are Cartesian textures coordinates and corresponding vertex indices on the face. The vertices are referenced by index into the top level SUGeometryInputRef's vertex array. Once the material
input is used (e.g. with SUEntitiesFill()), the material object must not be released since it will be associated with a parent object.
size_t SUMaterialInput::num_uv_coords |
Number of texture coordinates. 0 if the material
should be applied using default UV coordinates. 1 to 4 otherwise.
size_t SUMaterialInput::vertex_indices[4] |
Vertex indices corresponding to the texture coordinates. Should reference the vertex array of the parent SUGeometryInputRef.