[vtkusers] Please Help
Lisa Avila
lisa.avila at kitware.com
Mon Feb 2 10:35:48 EST 2004
Hello,
Look for glDepthFunc( GL_LEQUAL ) - this is what sets up the function that
the depth buffer uses. There is no standard function that will do what you
want since that would require a more complex depth buffer.
Lisa
At 11:32 AM 2/1/2004, Mayuresh Dalal wrote:
>Hi Lisa,
>
>Thank you for your response. Things are a little clearer now because of
>your input about harware renderering.
>
>I have gone over all the vtkOpenGL* .cxx files, and especially
>vtkOpenGLRenderWindow.cxx . But I still cannot see the snippet of code
>where z-values of pixels are compared. I have been looking for the <=
>function, like you said, but could not find it. Can you please be a little
>more specific?
>
>Thank You.
>
>
>>From: Lisa Avila <lisa.avila at kitware.com>
>>To: "Mayuresh Dalal" <mayur_vtk at hotmail.com>, vtkusers at vtk.org
>>Subject: Re: [vtkusers] Please Help
>>Date: Sun, 01 Feb 2004 01:48:25 -0500
>>
>>Hello,
>>
>>VTK does use OpenGL (or Mesa) for the hardware rendering. You can find
>>all the code in the Rendering directory in the vtkOpenGL* files. The
>>hardware z buffer is used and you can see in vtkOpenGLRenderWindow.cxx
>>that a less than or equal function is used (a pixel will be overwritten
>>if the new z value is less than or equal to the one currently stored in
>>the z buffer).
>>
>>What you are trying to do does not sound straight-forward. The frame
>>buffer only stores one result per pixel - you want more than one. You
>>could consult the z buffer after every polygon is drawn and save the
>>results (adding any changes into your own modified z buffer that can
>>store multiple results per pixel) but that would be very very slow. There
>>are some specialized OpenGL extensions supported by some graphics cards
>>that can help you do this - but again this is not a simple change to the
>>VTK code base.
>>
>>Lisa
>>
>>
>>
>>
>>
>>
>>At 12:52 AM 2/1/2004, Mayuresh Dalal wrote:
>>>Hi People,
>>>
>>>Please help me......Can someone please tell me which is the method where
>>>Z-buffering is actually
>>>performed for each pixel?
>>>
>>>I need to modify the way z buffering is performed and also the way Z
>>>buffer is used for displaying objects/props
>>>
>>>Does vtk rely on OpenGL z-buffering or does it have its own explicit
>>>z-buffering ? If, can someone point out the C++ method where
>>>z-buffering is performed in VTK ?
>>>
>>>Ok, in the terminology that I am used to(might differ with some of you),
>>>frame buffer is the array in which all pixel info( R,G,B,A,Z) is stored
>>>and is used to plot indivisual pixels on the screen.
>>>
>>>I want to render 2 objects. Areas of object 2 are occluded behind object
>>>1.I want to preserve the data corresponding to the OCCLUDED areas, which
>>>are traditionally eliminated / overwritten in the frame buffer. I want
>>>to preserve the data so that I can use it when looking at the same 2 objects
>>>from a different camera position.
>>>
>>>how should I go about backing up that info before it is lost/overwritten
>>>in the framebuffer?
>>>
>>>I need to stop the removal of FRONT FACING , but HIDDEN surfaces.
>>>
>>>Is there a way of doing this?
>>>
>>>Please help me.
>>>
>>>_________________________________________________________________
>>>Let the new MSN Premium Internet Software make the most of your
>>>high-speed experience. http://join.msn.com/?pgmarket=en-us&page=byoa/prem&ST=1
>>>
>>>_______________________________________________
>>>This is the private VTK discussion list. Please keep messages on-topic.
>>>Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
>>>Follow this link to subscribe/unsubscribe:
>>>http://www.vtk.org/mailman/listinfo/vtkusers
>>
>
>_________________________________________________________________
>High-speed usersbe more efficient online with the new MSN Premium
>Internet Software. http://join.msn.com/?pgmarket=en-us&page=byoa/prem&ST=1
>
>_______________________________________________
>This is the private VTK discussion list. Please keep messages on-topic.
>Check the FAQ at: <http://public.kitware.com/cgi-bin/vtkfaq>
>Follow this link to subscribe/unsubscribe:
>http://www.vtk.org/mailman/listinfo/vtkusers
More information about the vtkusers
mailing list