PDA

View Full Version : Total number of triangles rendered by opengl



hapcafe
04-04-2002, 05:20 PM
How to get it with opengl API,thanks.

zeckensack
04-04-2002, 05:26 PM
You don't.
You're welcome.

zeckensack
04-04-2002, 05:56 PM
Originally posted by dorbie:
zeckensack,

this schoolboy rubbish is not funny.
I'm not trying to be funny!
Question: How do I get the number of triangles rendered with OpenGL?
Answer: You don't!

I don't see my wrong doing. The gist is, you have to do that in your own code if you want to know it. Is that so wrong?

/edit
Ok, let's put it this way:
OpenGL is a low level interface. It will certainly not spend any time counting triangels. If you need that information, just add some kind of ++triangle_count; to your own code. The rationale behind this is to make the common case fast and the common case doesn't include counting triangles.

Some may think my initial response was rude but I'd say my initial response was straight to the point.

No hard feelings towards either of you hapcafe and dorbie.

[This message has been edited by zeckensack (edited 04-04-2002).]

dorbie
04-04-2002, 09:01 PM
Sorry, I missed the question in the title. My response was based on the text of the message.

I still prefered your second post :-).

Reading your second reply was surreal for a moment.

mphanke
04-05-2002, 06:35 AM
You don't.
You're welcome.

Hi zeckensack,

very exact and polite answer! http://www.opengl.org/discussion_boards/ubb/biggrin.gif

Martin

Devulon
04-05-2002, 08:16 AM
I have been considering writing a vertex program that will count verts/tris and the like. of course this is a little problematic since I am still using a tnt 2 ultra. I intend on getting something new, just not sure if I want a geforce 4 right now or if I will hold off for 6 more months for the next release. Hey the fact that I use a tnt 2 ultra still is just a fact that nvidia has the best cards and perhaps more importantly the best drivers. Period. The only real problem I have with my current setup is the fact that using hi-res nurbs in 3d studio max is quite slow (but I am gonna blame my processor and ram on that one).

I really need a new development system, I'm just really undecided on what to get.

davepermen
04-05-2002, 09:08 AM
vertex programs don't help there. first. they would only count vertices, not triangles.
second. vertexprogram is a simple function with one vertex in and one vertex out. no static variables in wich you can manipulate. only constant stuff and registers. no way to count

knackered
04-05-2002, 11:19 AM
You can't do this in d3d either - the reason being that it's a ridiculous thing to ask for, you've sent it the triangles (or specified the nurb, or whatever), so you already know the answer.

zed
04-06-2002, 12:30 PM
just because u sent them doesnt mean they got rendered,
i suppose u could render each trianlge in a different colour + then do a redaback of the screen + count the number of different colours (dont expect major speed).
good luck http://www.opengl.org/discussion_boards/ubb/smile.gif

knackered
04-06-2002, 03:47 PM
Aye, you're right of course.
Why do you want this information, hapcafe?

zed
04-06-2002, 07:59 PM
actually i wasnt 100% correct cause that doesnt take account of how many tris get rendered + then overdraw by other triangles. perhaps this is possible to do with stencil?

knackered
04-07-2002, 05:47 AM
Who cares?
hapcafe obviously doesn't.

hapcafe
04-08-2002, 06:12 AM
Sorry for my late coming again.I am not very sure about what happened here,but i believe everybody hopes this is the very place for everyone to study, to exchange ideas, no matter you are either a professional or amateur. Just be easy!



[This message has been edited by hapcafe (edited 04-08-2002).]

knackered
04-08-2002, 07:06 AM
What are you talking about, hapcafe?
Why do you want to know how many triangles have been rendered?

hapcafe
04-08-2002, 05:57 PM
Originally posted by knackered:
What are you talking about, hapcafe?
Why do you want to know how many triangles have been rendered?
Maybe you didn't notice what they talked about above.I don't wanna make people uneasy because of me.

Theodoros
04-09-2002, 10:56 AM
You can do this and several other things (type of primitives submitted, texture use etc) using Intel's Graphics Performance Toolkit.Basically it is a profiler specific for 3d applications.
An evaluation version is available at developer.intel.com (under software).

hapcafe
04-09-2002, 05:17 PM
Originally posted by Theodoros:
You can do this and several other things (type of primitives submitted, texture use etc) using Intel's Graphics Performance Toolkit.Basically it is a profiler specific for 3d applications.
An evaluation version is available at developer.intel.com (under software).

Thanks, Theodoros. I'll try it.