<div dir="ltr">Hmmm, no, there isn't. I was just looking at vtkOpenGLHelper, I'm not sure if that class could be wrapped or if it has to be a subclass of vtkObject. If it could be wrapped then we can just do that. You can try it by removing it from the WRAP_EXCLUDE_PYTHON section of Rendering/OpenGL2/CMakeLists.txt<div><br></div><div>I also noticed the class exposes the vtkVertexArrayObject, with that you might actually be able to provide your own attributes. I have not tried that but I it might work. </div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Mar 8, 2016 at 1:42 PM, Brad Hollister <span dir="ltr"><<a href="mailto:behollis@sci.utah.edu" target="_blank">behollis@sci.utah.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Thanks, Ken. I'm using the VTK Python bindings. It looks like vtkOpenGLHelper isn't wrapped.<br>
<br>
Is there another way to set the uniforms besides of the method given in the C++ test program?<br>
<br>
Regards,<br>
Brad<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Date: Sat, 5 Mar 2016 08:05:40 -0500<br>
From: Ken Martin <<a href="mailto:ken.martin@kitware.com" target="_blank">ken.martin@kitware.com</a>><br>
To: Brad Hollister <<a href="mailto:behollis@sci.utah.edu" target="_blank">behollis@sci.utah.edu</a>><br>
Cc: VTK Developers <<a href="mailto:vtk-developers@vtk.org" target="_blank">vtk-developers@vtk.org</a>><br>
Subject: Re: [vtk-developers] passing vertex attributes to custom<br>
shader<br>
Message-ID:<br>
<CANXz0SY+P=YuTQFcWg+5=<a href="mailto:9pd9RiCxPNYQjrrMKERLPhm2ooFsg@mail.gmail.com" target="_blank">9pd9RiCxPNYQjrrMKERLPhm2ooFsg@mail.gmail.com</a>><br>
Content-Type: text/plain; charset="utf-8"<br>
<br>
Currently you can pass uniforms (see<br>
<a href="https://gitlab.kitware.com/vtk/vtk/blob/v7.0.0.rc2/Rendering/OpenGL2/Testing/Cxx/TestUserShader2.cxx" rel="noreferrer" target="_blank">https://gitlab.kitware.com/vtk/vtk/blob/v7.0.0.rc2/Rendering/OpenGL2/Testing/Cxx/TestUserShader2.cxx</a><br>
for an example). You currently cannot pass your own attributes without<br>
subclassing, only work with the default ones that are passed<br>
(position/scalars/normals/tcoords)<br>
<br>
Thanks<br>
Ken<br>
<br>
On Fri, Mar 4, 2016 at 7:47 PM, Brad Hollister <<a href="mailto:behollis@sci.utah.edu" target="_blank">behollis@sci.utah.edu</a>><br>
wrote:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Hi,<br>
<br>
I've been using vtkOpenGLPolyDataMapper() to set custom vertex / fragment<br>
shaders. I'd also like to provide user-defined vertex attributes accessible<br>
in the shader code. I assumed from the documentation that<br>
MapDataArrayToVertexAttributes() is the proper way to do this.<br>
<br>
However, I get the ERROR: vtkOpenGLPolyDataMapper (0x2872160): Not<br>
implemented at this level...<br>
<br>
There doesn't appear to be a derived class of vtkOpenGLPolyDataMapper<br>
available for my needs (which is that I'm specifying polygons via a<br>
vtkPolyData object).<br>
<br>
Is it possible to pass vertex attributes and custom uniforms using<br>
vtkOpenGLPolyDataMapper? Is there a different way from the one I've been<br>
trying that makes this possible?<br>
<br>
Regards,<br>
Brad<br>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at<br>
<a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtk-developers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtk-developers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/vtk-developers" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/vtk-developers</a><br>
<br>
<br>
</blockquote></blockquote>
_______________________________________________<br>
Powered by <a href="http://www.kitware.com" rel="noreferrer" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" rel="noreferrer" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Search the list archives at: <a href="http://markmail.org/search/?q=vtk-developers" rel="noreferrer" target="_blank">http://markmail.org/search/?q=vtk-developers</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://public.kitware.com/mailman/listinfo/vtk-developers" rel="noreferrer" target="_blank">http://public.kitware.com/mailman/listinfo/vtk-developers</a><br>
<br>
</blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature">Ken Martin PhD<div>Chairman & CFO<br>Kitware Inc.<br>28 Corporate Drive<br>Clifton Park NY 12065<br>518 371 3971<div><br></div><div><span style="font-size:10pt;font-family:Tahoma,sans-serif">This communication,
including all attachments, contains confidential and legally privileged
information, and it is intended only for the use of the addressee. Access to this email by anyone else is
unauthorized. If you are not the intended recipient, any disclosure, copying,
distribution or any action taken in reliance on it is prohibited and may be
unlawful. If you received this communication in error please notify us
immediately and destroy the original message.
Thank you.</span></div></div></div>
</div>