Hi Aashish,<div><br></div><div>Sorry for not mentioning this, but I am indeed using a vtkGPUVolumeRayCastMapper.</div><div><br></div><div>Cheers,</div><div>Tijmen<br><br><div class="gmail_quote">On Wed, Oct 5, 2011 at 4:38 PM, Aashish Chaudhary <span dir="ltr"><<a href="mailto:aashish.chaudhary@kitware.com">aashish.chaudhary@kitware.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hi Tijmen,<br>
<div><div></div><div class="h5"><br>
On Wed, Oct 5, 2011 at 7:50 AM, Tijmen Klein <<a href="mailto:T.R.Klein@student.rug.nl">T.R.Klein@student.rug.nl</a>> wrote:<br>
> I recently updated VTK from 5.6 to the 5.9 version from Git. Now when I<br>
> close my application, I get this error repeated quite a few times: "a<br>
> vtkShader2 object is being deleted before ReleaseGraphicsResources() has<br>
> been called."<br>
> After a while I found the origin of the this problem. I have a vtkVolume,<br>
> and throughout the program the mapper of this vtkVolume is gets changed. So,<br>
> every now and then I do a call vtkVolume->setMapper(someMapper);<br>
> This used to work fine, and the (visual) results do still work. However,<br>
> when I comment out the setMapper() lines, the errors do not occur when<br>
> exiting. I was able to get rid of the errors by prepending the setMapper()<br>
> call with a ReleaseGraphicsResources() call. So my code now looks something<br>
> like this:<br>
> volume->ReleaseGraphicsResources(renWin);<br>
> volume->SetMapper(volumeMapper);<br>
> Is this intended and expected behavior, or is it a bug?<br>
<br>
</div></div>This seems like a bug. What particular mapper are you using? Is it<br>
vtkGPUVolumeRayCastMapper? I will have a look at it sometime today.<br>
<br>
Thanks,<br>
<br>
<br>
> Cheers,<br>
> Tijmen<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>
> Please keep messages on-topic and check the VTK FAQ at:<br>
> <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
><br>
> Follow this link to subscribe/unsubscribe:<br>
> <a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
><br>
><br>
<font color="#888888"><br>
<br>
<br>
--<br>
| Aashish Chaudhary<br>
| R&D Engineer<br>
| Kitware Inc.<br>
| <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
</font></blockquote></div><br></div>