Cool! Thank you :-)<br><br><div class="gmail_quote">On Wed, Aug 18, 2010 at 8:48 AM, David Gobbi <span dir="ltr"><<a href="mailto:david.gobbi@gmail.com">david.gobbi@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

The failures are because I added vtkCommand to the wrap list, but<br>
since vtkCommand didn't use vtkTypeMacro it didn't have SafeDownCast.<br>
I've updated ParaView's VTK and will keep an eye on the dashboard.<br>
<font color="#888888"><br>
   David<br>
</font><div><div></div><div class="h5"><br>
<br>
On Wed, Aug 18, 2010 at 6:30 AM, Dave Partyka <<a href="mailto:dave.partyka@kitware.com">dave.partyka@kitware.com</a>> wrote:<br>
> Hey David,<br>
> Can you look at the ParaView dashboard? I think some of these changes are<br>
> causing build errors with client server wrapping.<br>
> /home/kitware/dashboards/paraview-build-all-debug/Utilities/VTKClientServer/Common/vtkCommandClientServer.cxx:<br>
> In function ‘int vtkCommandCommand(vtkClientServerInterpreter*,<br>
> vtkObjectBase*, const char*, const vtkClientServerStream&,<br>
> vtkClientServerStream&)’:<br>
> /home/kitware/dashboards/paraview-build-all-debug/Utilities/VTKClientServer/Common/vtkCommandClientServer.cxx:14:20:<br>
> error: ‘SafeDownCast’ is not a member of ‘vtkCommand’<br>
> On Tue, Aug 17, 2010 at 2:52 PM, David Gobbi <<a href="mailto:david.gobbi@gmail.com">david.gobbi@gmail.com</a>> wrote:<br>
>><br>
>> I tried wrapping vtkCommand, and python can wrap it because it's<br>
>> already properly tagged as "abstract".  So it just can't be used the<br>
>> way that I would like.  But all the constants are there.<br>
>><br>
>> import vtk<br>
>> print vtk.vtkCommand.ModifiedEvent<br>
>> 33<br>
>><br>
>>  David<br>
>><br>
>><br>
>> On Tue, Aug 17, 2010 at 11:59 AM, David Gobbi <<a href="mailto:david.gobbi@gmail.com">david.gobbi@gmail.com</a>><br>
>> wrote:<br>
>> > Wrapping vtkCommand.h is difficult, but not because of the constants.<br>
>> > The vtkCommand class itself is internally handled in a very "special"<br>
>> > way by the wrappers.  So while I do want to wrap this class and its<br>
>> > constants, it won't happen immediately.<br>
>> ><br>
>> > For some things, you can substitute a string for the constants i.e.<br>
>> > AddObserver("ModifiedEvent", func).  But I know that this doesn't work<br>
>> > for everything.<br>
>> ><br>
>> >   David<br>
>> ><br>
>> ><br>
>> > On Tue, Aug 17, 2010 at 11:48 AM, Jean-Christophe Fillion-Robin<br>
>> > <<a href="mailto:jchris.fillionr@kitware.com">jchris.fillionr@kitware.com</a>> wrote:<br>
>> >> Hi David,<br>
>> >><br>
>> >> That's awesome :)<br>
>> >><br>
>> >> Question:<br>
>> >>   If we add vtkCommand.h to Kit_WRAP_HEADERS, would the eventid be<br>
>> >> wrapped ?<br>
>> >><br>
>> >> By eventid, i mean the enum regrouping ModifedEvent, ...<br>
>> >><br>
>> >> Thks<br>
>> >> Jc<br>
>> >><br>
>> >> On Tue, Aug 17, 2010 at 1:42 PM, David Gobbi <<a href="mailto:david.gobbi@gmail.com">david.gobbi@gmail.com</a>><br>
>> >> wrote:<br>
>> >>><br>
>> >>> For wrapping VTK constants, I've created an optional variable for the<br>
>> >>> kits, e.g. in Common/CMakeLists.txt:<br>
>> >>><br>
>> >>> SET(Kit_WRAP_HEADERS<br>
>> >>>  vtkSystemIncludes.h<br>
>> >>>  vtkType.h<br>
>> >>>  ${VTK_BINARY_DIR}/vtkConfigure.h<br>
>> >>>  )<br>
>> >>><br>
>> >>> This tells the python wrappers to wrap these headers<br>
>> >>> (Filtering/vtkCellType.h is also wrapped).  Since the constants are<br>
>> >>> wrapped directly into the kit python modules, vtkConstants.py is<br>
>> >>> obsolete.<br>
>> >>><br>
>> >>>  David<br>
>> >>><br>
>> >>><br>
>> >>> On Mon, Aug 16, 2010 at 11:45 AM, David Gobbi <<a href="mailto:david.gobbi@gmail.com">david.gobbi@gmail.com</a>><br>
>> >>> wrote:<br>
>> >>> > Hi All,<br>
>> >>> ><br>
>> >>> > I'm looking for the best way to modify the VTK cmake scripts so that<br>
>> >>> > I<br>
>> >>> > can automatically wrap constants like VTK_POLY_DATA.  Right now,<br>
>> >>> > some<br>
>> >>> > of these constants are hard-coded in e.g. vtkConstants.py but of the<br>
>> >>> > wrapper's "hard-coded" copies of the constants are never up to date.<br>
>> >>> > The only thing that is needed to python-wrap these constants is to<br>
>> >>> > pass the header files vtkConfigure.h, vtkType.h, etc. to<br>
>> >>> > vtkWrapPython. One way to do this is to add these headers to the<br>
>> >>> > source list:<br>
>> >>> ><br>
>> >>> > Set(Kit_SRCS vtkType.h ...)<br>
>> >>> > SET_SOURCE_FILES_PROPERTIES(vtkType.h HEADER_FILE_ONLY)<br>
>> >>> ><br>
>> >>> > However, I'm reluctant do to this because no other VTK header files<br>
>> >>> > are handled this way.  The alternative is to make a separate list<br>
>> >>> > for<br>
>> >>> > header files, one that will be used by<br>
>> >>> > KitCommonPythonWrapBlock.cmake:<br>
>> >>> ><br>
>> >>> > Set(Kit_HDRS vtkType.h ...)<br>
>> >>> ><br>
>> >>> > And then in KitCommonPythonWrapBlock.cmake:<br>
>> >>> > SET(FILES_TO_WRAP ${Kit_SRCS} ${Kit_HDRS})<br>
>> >>> > VTK_WRAP_PYTHON3(vtk${KIT}Python KitPython_SRCS "${FILES_TO_WRAP}")<br>
>> >>> ><br>
>> >>> > I'm leaning towards this latter method, because it seems to be the<br>
>> >>> > tidier of the two approaches.<br>
>> >>> ><br>
>> >>> >  David<br>
>> >>> ><br>
>> >>> _______________________________________________<br>
>> >>> Powered by <a href="http://www.kitware.com" 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" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
>> >>><br>
>> >>> Follow this link to subscribe/unsubscribe:<br>
>> >>> <a href="http://www.vtk.org/mailman/listinfo/vtk-developers" target="_blank">http://www.vtk.org/mailman/listinfo/vtk-developers</a><br>
>> >>><br>
>> >><br>
>> >><br>
>> >><br>
>> >> --<br>
>> >> Phone: 1-518-836-2174<br>
>> >> Ext: 304<br>
>> >><br>
>> ><br>
>> _______________________________________________<br>
>> Powered by <a href="http://www.kitware.com" 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" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
>><br>
>> Follow this link to subscribe/unsubscribe:<br>
>> <a href="http://www.vtk.org/mailman/listinfo/vtk-developers" target="_blank">http://www.vtk.org/mailman/listinfo/vtk-developers</a><br>
>><br>
><br>
><br>
</div></div></blockquote></div><br>