<html><head><style data-externalstyle="true"><!--
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph {
margin-top:0in;
margin-right:0in;
margin-bottom:0in;
margin-left:.5in;
margin-bottom:.0001pt;
}
p.MsoListParagraphCxSpFirst, li.MsoListParagraphCxSpFirst, div.MsoListParagraphCxSpFirst, p.MsoListParagraphCxSpMiddle, li.MsoListParagraphCxSpMiddle, div.MsoListParagraphCxSpMiddle, p.MsoListParagraphCxSpLast, li.MsoListParagraphCxSpLast, div.MsoListParagraphCxSpLast {
margin-top:0in;
margin-right:0in;
margin-bottom:0in;
margin-left:.5in;
margin-bottom:.0001pt;
line-height:115%;
}
--></style></head><body><div data-externalstyle="false" dir="ltr" style="font-family:Calibri,'Segoe UI',Meiryo,'Microsoft YaHei UI','Microsoft JhengHei UI','Malgun Gothic','Khmer UI','Nirmala UI',Tunga,'Lao UI',Ebrima,sans-serif;font-size:12pt;"><div>> I have some visualization code that are using vtk, written in C++. I <br>> have created a C wrapper to this code, and 'it' works. This C API, <br>> allow me to hand externally created renderwindows, <br>> renderwindowinteractors and renderers handles, i.e. void* pointers to <br>> concrete objects, allowing my underlying vtkobjects, that are created <br>> through the C API, to be rendered.<br>> <br>> My question is, if I use activiz, together with my code (that I would <br>> need to give a C# wrapper), will I be able to hand my library those <br>> handles from activiz, so my code can use activiz to render?<br></div><div> </div><div>If you have objects that you have created in ActiViz in a C# program, you should be able to call “GetCppThis()” on any of them and use the “.Handle” property on that to get the “void *” pointer values you would need to pass to your C layer.</div><div> </div><div>The method is implemented in Kitware.mummy.Runtime.WrappedObject, the parent class of all ActiViz vtkObject-derived classes. [ code here: <a title="http://public.kitware.com/gitweb?p=mummy.git;a=blob;f=Runtime/WrappedObject.cs;h=6060cad5;#l69" href="http://public.kitware.com/gitweb?p=mummy.git;a=blob;f=Runtime/WrappedObject.cs;h=6060cad5;#l69" target="_parent">http://public.kitware.com/gitweb?p=mummy.git;a=blob;f=Runtime/WrappedObject.cs;h=6060cad5;#l69</a> ]</div><div> </div><div>You will have to be mindful/careful about lifetime management and reference counting issues using this from a plain C implementation, but I’m sure you’re already aware of that.</div><div> </div><div> </div><div>HTH,</div><div>David C.</div><div> </div></div></body></html>