[vtkusers] Is there a way to tell if a video card supports depth peeling?
Aashish Chaudhary
aashish.chaudhary at kitware.com
Mon Dec 2 09:46:57 EST 2013
Please have a look here:
http://www.vtk.org/Wiki/VTK/Depth_Peeling
Specially this section:
Required OpenGL extensions
- GL_ARB_depth_texture or OpenGL>=1.4
- GL_ARB_shadow or OpenGL>=1.4
- GL_EXT_shadow_funcs or OpenGL>=1.5
- GL_ARB_vertex_shader or OpenGL>=2.0
- GL_ARB_fragment_shader or OpenGL>=2.0
- GL_ARB_shader_objects or OpenGL>=2.0
- GL_ARB_occlusion_query or OpenGL>=1.5
- GL_ARB_multitexture or OpenGL>=1.3
- GL_ARB_texture_rectangle
- GL_SGIS_texture_edge_clamp or GL_EXT_texture_edge_clamp or OpenGL>=1.2
On Mon, Dec 2, 2013 at 8:37 AM, Doug Hoppes <dhoppes at mbfbioscience.com>wrote:
> Hi all,
>
>
>
> I’m still playing with making my transparent objects look
> good. It was suggested that I look at the depth peeling versus
> vtkdepthsortpolydata (since the depth sort isn’t all that fast). Of
> course, I read that the depth peeling isn’t fast, either.
>
>
>
> From the documentation, I have implemented (where the
> actor is a set ofspheres)
>
> -------
>
> m_pRenderWindow->SetAlphaBitPlanes(1);
>
> m_pRenderWindow->SetMultiSamples(0);
>
> m_pRenderer->GetActorRenderer()->UseDepthPeelingOn();
>
> m_pRenderer->GetActorRenderer()->SetMaximumNumberOfPeels(100);
>
> m_pRenderer->GetActorRenderer()->SetOcclusionRatio(0.1);
>
>
>
> vtkSmartPointer<vtkPolyDataMapper> mapper = vtkSmartPointer<
> vtkPolyDataMapper>::New();
>
> mapper->SetInputConnection(appendData->GetOutputPort());
>
> vtkSmartPointer<vtkActor> actor = vtkSmartPointer<vtkActor>::
> New();
>
> actor->SetMapper(mapper);
>
> actor->GetProperty()->SetOpacity(0.5);
>
> actor->GetProperty()->SetColor(1, 0, 0);
>
> actor->RotateX(-72); //put the object in a position where it
> is easy
>
> m_pRenderer->AddActor(actor);
>
>
>
> int depthPeelingWasUsed = m_pRenderer->GetActorRenderer()->
> GetLastRenderingUsedDepthPeeling();
>
> -------
>
>
>
> The depthPeelingWasUsed always returns false (0). From
> the documentation, it says that, for depth peeling, you really need OpenGL
> > 1.3. I’m using the amd radeon 7900.
>
>
>
> Doug
>
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the VTK FAQ at:
> http://www.vtk.org/Wiki/VTK_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.vtk.org/mailman/listinfo/vtkusers
>
>
--
| Aashish Chaudhary
| R&D Engineer
| Kitware Inc.
| www.kitware.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20131202/7c289805/attachment.htm>
More information about the vtkusers
mailing list