Poly count

Blitz3D Forums/Blitz3D Beginners Area/Poly count

Almo(Posted 2004) [#1]
Can you load a mesh and get Blitz to tell you how many polys it has?


Perturbatio(Posted 2004) [#2]
take a look at the mediaview program (C:\Program Files\Blitz3D\mediaview)


GfK(Posted 2004) [#3]
Yeah, you can use CountSurfaces and CountTriangles. Iterate through the whole mesh (each child in hierarchy if its an 'animMesh'), iterate through all surfaces and perform CountTriangles on each, then add them all together.

[edit]What perturbatio said - the code in there probably does something like this already


Almo(Posted 2004) [#4]
thanks dude

GfK: the mediaview fits the mesh into the screen, renders it, then outputs TrisRendered().

I assume this includes tris that are behind others...


Ross C(Posted 2004) [#5]
Yeah, it does. Even i f a small part of the mesh is onscreen, TrisRendered will return all the tri's on that mesh.