counts

Hello, i’ve made some moving objects with OpenGL. Its really basic but i was wondering how to recognise the moving objects.
I’ve read that there are several ways, but i want to start with the following.
(Correct me if im wrong i just picked this information up form the web)
You can check the polycount of an object. Each object has a different polycount value, right?
I want to make a logging program that writes the values of an object to a textfiles.
So for example when i hold my mouse cursor on the cube, and the polycounts of the cube are 1344 or 1466 or 1532, that it writes those values for me to a textfile.
So basicly what i want to do is find out the values of an object, each object must contain a specific value or something.
I hope i made this a little clear, i can imagine that it sounds kinda vague.
Anyway, i hope someone can help me out.
Thanks for any help.

I’m not sure that a polygon count is going to guarantee uniqueness of objects in the general case. What happens when you render 2 cubes? But then again, I’m not sure that I understand your question. :slight_smile:

AFAIK, there’s no way (as of yet) to query the rendered triangle count, unless an extension has been released recently, if that’s what you mean.

Sorry if I misunderstood :slight_smile:

Ill try to explain a little better :slight_smile:
The subject for the level (of the game im playing) is:


Level14: Count And Texture Finder.
counts must be red and textures must be blue

So thats my goal. I have to tell the difference between the counts and textures. I have to color the counts red and the textures must be red.
I hope you can tell me how to color objects, what functions i need etc.