I am following offscreen image example <a href="http://gdcm.git.sourceforge.net/git/gitweb.cgi?p=gdcm/gdcm;a=blob;f=Utilities/VTK/Examples/Cxx/offscreenimage.cxx;h=4545ee890ad6d6e95d4a2406f0ce3aed7db8f870;hb=HEAD">http://gdcm.git.sourceforge.net/git/gitweb.cgi?p=gdcm/gdcm;a=blob;f=Utilities/VTK/Examples/Cxx/offscreenimage.cxx;h=4545ee890ad6d6e95d4a2406f0ce3aed7db8f870;hb=HEAD</a><br>
<br>I tried play around with the code. I have successfully extract the image from DICOM, however, I notice several things and want to ask the following:<br><br>1. The output image always have black unused area with the center of the image being the DICOM image. Is there a way to tell VTK to crop the image automatically? (remove the black area)<br>
<br>2. I set the vtkRenderWindow's size with renWin->SetSize(2048,2048); On lower resolution, it works fine, but when I request for higher resolution such as 2048 x 2048, why the output image is always 1284 x 1001? Is this the max resolution possible?<br>
<br>Thank you.<br>