Crate blender_mesh[][src]

Blender files can have meshes such as circles, cubes, cylinders, a dragon or any other 3D shape.

A mesh can be represented as a group of vertices and data about those vertices, such as their normals or UV coordinates.

Meshes can also have metadata, such as the name of it's parent armature (useful for vertex skinning).

blender-mesh-to-json seeks to be a well tested, well documented exporter for blender mesh metadata.

You can write data to stdout or to a file. At the onset it will be geared towards @chinedufn's needs - but if you have needs that aren't met feel very free to open an issue.

@see https://docs.blender.org/manual/en/dev/modeling/meshes/introduction.html - Mesh Introduction @see https://github.com/chinedufn/blender-actions-to-json - Exporting blender armatures / actions

Structs

BlenderMesh

All of the data about a mesh

BoneInfluence

The index of a bone that influences the vertex along with the weighting of that influence

BoundingBox

The bounding box that encompasses a mesh. This will usually come from Blender as a z_up coordinate system bounding box that you'll later convert to be y_up.

CreateSingleIndexConfig

Configuration for combining multiple indices into a single index

MultiIndexedVertexAttributes

Vertex data with multiple indices - not suited for OpenGL and other single index rendering pipelines, but good for on disk storage as their is less data duplicated when there are multiple indices.

PrincipledBSDF

Material data for a mesh

SingleIndexedVertexAttributes

Most 3D model file formats export vertex data with multiple indices.

Vertex

A vertex within a mesh.

VertexAttribute

Data for an individual vertex attribute such as positions, normals or uvs.

Enums

BlenderError

Something went wrong in the Blender child process that was trying to parse your mesh data.

Channel

An individual channel within an image. Red, Green, or Blue.

FlattenMeshError

An error when trying to flatten your exported data across multiple files into one HashMap of mesh name to mesh data.

MaterialInput

An input to a material property.

Functions

flatten_exported_meshes

Convert MesheshByFilename into a HashMap<MeshName, &BlenderMesh> that flattens all of the meshes across all of the files into one HashMap.

flatten_exported_meshes_owned

Convert MesheshByFilename into a HashMap<MeshName, BlenderMesh> that flattens all of the meshes across all of the files into one HashMap.

parse_meshes_from_blender_stdout

Given a buffer of standard output from Blender we parse all of the mesh JSON that was written to stdout by blender-mesh-to-json.py.

Type Definitions

FlattenedExportedMeshes
MeshesByFilename
MeshesByMeshName