ObjFileParser / Mesh
The Obj File Parser's Mesh class does not bring any new functionality to the table. It's just a container for the three objects that can make up a mesh by PHP OpenGLs definition.
- Vertices (FloatBuffer) storing the vertex data, like position, normal, texture coordinates, etc.
- indices (UIntBuffer) storing the indices of the vertices that make up the triangles. optional
- Material the material of the mesh. optional
Properties¶
$material¶
The material of the mesh (can be null)
$vertices¶
A float buffer containing vertex data of the mesh. The layout of the data is not fixed but rather requested by the user. Read more about the layout here.
$indices¶
A unsigned int buffer containing indices of the mesh. (optional)