b2dMeshFaceCount

Number of faces in a loaded mesh.

2D Overlay

Parameters & Returns

Parameters

handle Int

Returns

Int

Quick Summary

Number of faces in a loaded mesh.

Technical Exegesis...

Returns the face count of a mesh loaded with b2dLoadMesh (0 for an invalid handle). Each face has 3 or 4 corners (see b2dMeshFaceCorners); triangles are drawn as a degenerate quad. Loop 0..count-1, read each face's vertex indices + UVs once, then draw with b2dDrawImageQuadDepthUV.

Example

Example.bam
Local nf:Int = b2dMeshFaceCount(mesh)