Count all polys + triangles in 3D scene?

Blitz3D Forums/Blitz3D Programming/Count all polys + triangles in 3D scene?

Guy Fawkes(Posted 2012) [#1]
Does anyone know of a function that can do this WITHOUT needing a "mesh%" parameter?

Any help is greatly appreciated!

Thank You! :)


Yasha(Posted 2012) [#2]
You can get all of the triangles (triangles = polygons, they are the same) rendered in the last call to RenderWorld - i.e. all of the triangles that actually matter - with TrisRendered. This is more useful than a total, because it lets you identify where polygon counts are causing rendering hotspots.

There is no general-purpose way to get all of the triangles in the whole scene, with or without a mesh parameter. The necessary information is not exposed by the engine. Besides, you shouldn't need to ask this: it's your job as a designer to know what resources you're putting into a scene, so you should be able to work this figure out yourself.

Last edited 2012


Rroff(Posted 2012) [#3]
You could walk through every surface and count every tris on every mesh that was in the scene but it would be massively slow and a bit pointless. TrisRendered works well enough for most practical uses.


Leon Drake(Posted 2012) [#4]
COUNT ALL THE POLYGONS



Last edited 2012


Captain Wicker (crazy hillbilly)(Posted 2012) [#5]
or just wire frame the object and count the polys/triangles yourself. Be sure to have pen and paper ready. ;)