47 XFileMesh(CoordinateSystem cs = CS_yup_left);
102 class SkinWeightsData {
104 LMatrix4d _matrix_offset;
105 std::string _joint_name;
108 typedef epvector<SkinWeightsData> SkinWeights;
109 SkinWeights _skin_weights;
A base class for any of a number of kinds of geometry primitives: polygons, point lights,...
void clear()
Empties all data from the mesh.
XFileDataNode * make_x_colors(XFileNode *x_mesh, const std::string &suffix)
Creates a MeshVertexColors table for the mesh.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
bool fill_mesh(XFileDataNode *obj)
Fills the structure based on the raw data from the X file's Mesh object.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
This is a collection of polygons; i.e.
bool has_normals() const
Returns true if any of the vertices or faces added to this mesh used a normal, false otherwise.
A base class for nodes in the hierarchy that are not leaf nodes.
This represents a single normal associated with an XFileFace.
bool has_uvs() const
Returns true if any of the vertices added to this mesh used a texture coordinate, false otherwise.
bool fill_normals(XFileDataNode *obj)
Fills the structure based on the raw data from the MeshNormals template.
int add_vertex(EggVertex *egg_vertex, EggPrimitive *egg_prim)
Creates a new XFileVertex, if one does not already exist for the indicated vertex,...
int add_material(EggPrimitive *egg_prim)
Creates a new XFileMaterial, if one does not already exist for the indicated material,...
XFileDataNode * make_x_material_list(XFileNode *x_mesh, const std::string &suffix)
Creates a MeshMaterialList table for the mesh.
bool fill_material_list(XFileDataNode *obj)
Fills the structure based on the raw data from the MeshMaterialList template.
bool fill_skin_weights(XFileDataNode *obj)
Fills the structure based on the raw data from the SkinWeights template.
int add_normal(EggVertex *egg_vertex, EggPrimitive *egg_prim)
Creates a new XFileNormal, if one does not already exist for the indicated normal,...
void add_polygon(EggPolygon *egg_poly)
Adds the indicated polygon to the mesh.
XFileMaterial * get_material(int n) const
Returns a pointer to the nth materials associated with the mesh.
A single node of an X file.
A base class for all things which can have a name.
bool fill_colors(XFileDataNode *obj)
Fills the structure based on the raw data from the MeshVertexColors template.
void set_egg_parent(EggGroupNode *egg_parent)
Specifies the egg node that will eventually be the parent of this mesh, when create_polygons() is lat...
Any one-, two-, three-, or four-component vertex, possibly with attributes such as a normal.
bool fill_uvs(XFileDataNode *obj)
Fills the structure based on the raw data from the MeshTextureCoords template.
bool fill_mesh_child(XFileDataNode *obj)
Fills the structure based on one of the children of the Mesh object.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
XFileDataNode * make_x_uvs(XFileNode *x_mesh, const std::string &suffix)
Creates a MeshTextureCoords table for the mesh.
This represents a single vertex associated with an XFileFace.
XFileDataNode * make_x_mesh(XFileNode *x_parent, const std::string &suffix)
Creates an X structure corresponding to the mesh.
This represents a single face of an XFileMesh.
bool create_polygons(XFileToEggConverter *converter)
Creates a slew of EggPolygons according to the faces in the mesh, and adds them to the previously-ind...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
This represents an X file "material", which consists of a color, lighting, and/or texture specificati...
This is an abstract base class for an XFileNode which is also an XFileDataObject.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
bool has_colors() const
Returns true if any of the vertices or faces added to this mesh used a color, false otherwise.
bool has_materials() const
Returns true if any of the faces added to this mesh used a real material, false otherwise.
An ordered list of data elements, formatted in memory for transmission over a socket or writing to a ...
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
int get_num_materials() const
Returns the number of distinct materials associated with the mesh.
XFileDataNode * make_x_normals(XFileNode *x_mesh, const std::string &suffix)
Creates a MeshNormals table for the mesh.