Class mesh_object¶
- class o2sclpy.mesh_object(name: str, faces, mat: str = '', obj_type: str = 'triangles')¶
A mesh object for a GLTF file.
- faces = []¶
The list of faces
- mat: str = ''¶
The name of the material (blank for none, or for different material for each face)
Note that this string might be nonempty even when some of the faces explicitly specify a material. In this case, this string specifies the default material to be used for those faces which do not specify their own material.
If this string is non-empty, but all of the faces specify a material, then the
sort_by_mat()
function will
- name: str = ''¶
The name of the mesh object
- obj_type: str = 'triangles'¶
Either ‘triangles’, ‘lines’, or ‘points’
- sort_by_mat(verbose: int = 0)¶
Sort the faces by material name, ensuring that the group and material commands do not have to be issued for each face.
- vert_list = []¶
List of vertices
- vn_list = []¶
List of vertex normals
- vt_list = []¶
List of texture coordinates