Hi guys,

On 3/7/09 12:48 AM, Jeremy Warren wrote:
--------------------------------------------------
From: "Robert Osfield" <[email protected]>
Sent: Wednesday, July 01, 2009 3:18 AM
To: "OpenSceneGraph Users" <[email protected]>
Subject: Re: [osg-users] Read number of Pixels an object takes up

Hi Jeremy,

The OSG now has support of OpenGL occlusion query that can provide the
number of pixels covered when rendering. See osgocclusionquery
example.

Robert.

On Wed, Jul 1, 2009 at 12:35 AM, Jeremy Warren<[email protected]> wrote:
I have a simple scene. Colored background and an object, say a box. I
want to figure out how many pixels the box is taking up in the scene. It
seems like a simple request, but haven't come up with any solution. Any
takers?

While we're on the subject: for simple objects, say a sphere or an AABB, shouldn't it be possible to do this calculation quicker on the CPU without going to the GPU? Isn't something like this done for small feature culling?

I'm thinking of projecting the object's dimensions (radius or width/height) into pixel space and working from there.

Cheers,
/ulrich
_______________________________________________
osg-users mailing list
[email protected]
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to