[Paraview] OpenGL Backend Identification

Shawn Waldon shawn.waldon at kitware.com
Wed Dec 9 12:00:26 EST 2015


There *is* a global VTK configuration header.  vtkConfigure.h has many of
these definitions and is included in vtkObjectBase.h (so pretty much
everywhere).  But you may be right that this should go somewhere in the
rendering code rather than in there.  I am not sure that vtkRenderWindow is
the best location for it, but I am not as familiar with the code that uses
the compiler definition.  Does everywhere that #ifdefs VTK_OPENGL2 include
vtkRenderWindow.h?  Or would we have to pull in that header just for that
macro?

Shawn

On Wed, Dec 9, 2015 at 11:54 AM, Tim Thirion <tim.thirion at kitware.com>
wrote:

> Yes, that was my original question. :) Is the vtkRenderWindow the best
> place for this? I'm happy to add it.
>
> On Wed, Dec 9, 2015 at 11:12 AM, Joachim Pouderoux <
> joachim.pouderoux at kitware.com> wrote:
>
>> BTW, I took a look but I do not see any way for a third party VTK or PV
>> application that would not use CMake machinery (and use VTK_OPENGL_BACKEND)
>> to know if the VTK it uses is based on OpenGL backend 1 or 2.
>> VTK_OPENGL2 is a compiler definition provided to build VTK or PV but, as
>> there is no global VTK configuration header, shouldn't we add a function in
>> vtkRenderWindow to return the version of the backend it is based on?
>>
>> *Joachim Pouderoux*
>>
>> *PhD, Technical Expert*
>> *Kitware SAS <http://www.kitware.fr>*
>>
>>
>> 2015-12-08 19:58 GMT+01:00 Ben Boeckel <ben.boeckel at kitware.com>:
>>
>>> On Mon, Dec 07, 2015 at 14:49:51 -0500, Tim Thirion wrote:
>>> > I'm looking to provide run-time identification of the current OpenGL
>>> > backend in use. Some questions:
>>> >
>>> > 1. VTK #defines VTK_OPENGL2, but ParaView #defines VTKGL2. Is there a
>>> > particular reason we have both?
>>>
>>> VTK used to have both. VTKGL2 should be migrated to VTK_OPENGL2 (as VTK
>>> did).
>>>
>>> > 2. Is there an ideal place to define such a constant? Perhaps on the
>>> render
>>> > window?
>>>
>>> The About dialog has a list of information already (versions of Python,
>>> matplotlib, numpy, Qt, etc.).
>>>
>>> --Ben
>>> _______________________________________________
>>> 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 ParaView Wiki at:
>>> http://paraview.org/Wiki/ParaView
>>>
>>> Search the list archives at: http://markmail.org/search/?q=ParaView
>>>
>>> Follow this link to subscribe/unsubscribe:
>>> http://public.kitware.com/mailman/listinfo/paraview
>>>
>>
>>
>
> _______________________________________________
> 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 ParaView Wiki at:
> http://paraview.org/Wiki/ParaView
>
> Search the list archives at: http://markmail.org/search/?q=ParaView
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/paraview
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/paraview/attachments/20151209/3c680560/attachment.html>


More information about the ParaView mailing list