[vtkusers] DICOM files volume rendering
Import EV
info at import-ev.com
Mon May 9 20:52:09 EDT 2016
Hello Elvis,
Thank you for your response.
You may be right. I will check color/opacity transfer function.
Thanks!
—
Ted Shigetomi
Import EV Corp.
info at import-ev.com
---
2016/05/10 2:16、Elvis Stansvik <elvis.stansvik at orexplore.com>
I haven't looked at the example since I'm on my phone, but I would assume that you need a color/opacity transfer function that fits your data.
Elvis
Den 7 maj 2016 2:05 em skrev "Import EV" <info at import-ev.com <mailto:info at import-ev.com>>:
I could finally make vtk.framework for iOS.
Now, I would like to implement volume rendering using 300 DICOM files.
I use the sample Xcode project "VolumeRender" provided here
(https://github.com/Kitware/VTK/tree/master/Examples/iOS <https://github.com/Kitware/VTK/tree/master/Examples/iOS>).
In "MyGLKViewController.mm" of this sample project, I changed the codes like
below;
"->" shows the codes I changed.
===
#else
NSArray *paths =
NSSearchPathForDirectoriesInDomains(NSDocumentDirectory, NSUserDomainMask,
YES);
NSString *basePath = paths.firstObject;
std::string fname([basePath UTF8String]);
-> //fname += "/CT-chest-quantized.nrrd";
-> //vtkNew<vtkNrrdReader> mi;
-> //mi->SetFileName(fname.c_str());
-> vtkNew<vtkDICOMImageReader> mi;
-> mi->SetDirectoryName(fname.c_str());
mi->Update();
double range[2];
mi->GetOutput()->GetPointData()->GetScalars()->GetRange(range);
volumeMapper->SetInputConnection(mi->GetOutputPort());
#endif
===
Then I copied 300 DICOM files to "Documents" directory of the app via
iTunes.
The app runs without error but only black color cubic shown on the iPhone5S
display and does not show correct volume rendering image.
Do I need to do something else to show correct volume rendering image?
Please advise me.
-----
Import EV Corp.
-----
_______________________________________________
Powered by www.kitware.com <http://www.kitware.com/>
Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html <http://www.kitware.com/opensource/opensource.html>
Please keep messages on-topic and check the VTK FAQ at: http://www.vtk.org/Wiki/VTK_FAQ <http://www.vtk.org/Wiki/VTK_FAQ>
Search the list archives at: http://markmail.org/search/?q=vtkusers <http://markmail.org/search/?q=vtkusers>
Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/vtkusers <http://public.kitware.com/mailman/listinfo/vtkusers>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtkusers/attachments/20160510/199370b6/attachment.html>
More information about the vtkusers
mailing list