Re: [Pyobjc-dev] VTK bindings
Brought to you by:
ronaldoussoren
From: Ronald O. <ous...@ci...> - 2003-12-02 17:38:04
|
On 2 dec 2003, at 16:23, b.bum wrote: > On Dec 2, 2003, at 1:12 AM, Carlos Phillips wrote: >> 2003-12-02 03:30:46.165 Simple1[1541] PyObjCPointer created: at >> 0x6d16080 of type >> {vtkRenderer={?={?={?=^^?i}C{vtkTimeStamp=^^? >> L}^{vtkSubjectHelper}}^{vtkAssemblyPath}^{vtkPropCollection}iIff^{vtkP >> ropCollection}^{vtkActor2DCollection}^{vtkWindow}[3f][4f][2f][2f][2f][ >> 2i][2i][3f][3f][4f]}^{vtkCamera}^{vtkLight}^{vtkLightCollection}^{vtkC >> ullerCollection}^{vtkActorCollection}^{vtkVolumeCollection}[3f]^{vtkRe >> nderWindow}ffiii*{vtkTimeStamp=^^? >> L}fii^^{vtkProp}i^^{vtkAssemblyPath}iii[6f]f}8@0:4 > > Like Bob said, once a PyObjCPointer is created, you are generally out > of luck. PyObjC transparently bridged Objective-C. In this case, you > are asking it to transparently bridge a relatively complex C data > type. The problem is that PyObjCPointer is a not really a wrapped pointer, when the PyObjCPointer object is created the value pointed-to is copied into an internal buffer. Most of the time that doesn't work, vtkRenderer is probably a C++ class and the copied value is invalid. I'll put creation of a real pointer wrapper on my todo-list, a generic version of the types used to wrapped some other pointer types (see pointer-support.m). Is VTK itself wrapped? If so, you could use the functions in pointer-support.m to convert vtkRenderer* to the Python wrapper from the VTK wrapper. Ronald |