开发者

How to access and display DICOM files on iPhone

I would like to develop iPhone application about image processing,access and display DICOM files on screen like OsiriX.But i don't 开发者_如何学编程know what libraries to do that.

I don't know OsiriX have library or plugin for developer.Do you know ?? (Sorry foe my bad english.)

Advice me,Please

Thank you.


DCMTK works fine on IOS


If you are willing to consider Monotouch, a possibility would be DICOM# - http://sourceforge.net/projects/dicom-cs/


idoimaging.com lists a number of DICOM-compatible libraries. I'd start with that list and see if one or more of those could easily be ported to iOS.


the easier ways would be to locate c/c++ dicom library (since you only need the lib to extract the tag-value pairs and the pixel data). And, link your development(i assume that'd be a viewer) to that c/c++ library. Note that, for j2k compression, you probably need a more advanced dicom library if not another img lib that supports j2k.

FYR (DICOM in C/C++) [1] http://sourceforge.net/projects/gdcm/ [2] http://imebra.com/


Imebra is written in C++ but it includes Objective-C helpers that allow to build directly UIImage or NSImage objects from loaded datasets.

You have to rename your source file with a .mm extension (instead of .m) so they can use C++ features.

Here is a small sample that load a Dicom file then get the image as UIImage (without applying the presentation VOI/LUT for simplicity):

using namespace puntoexe;

// Open the file test.dcm for reading
ptr<stream> readStream(new stream);
readStream->openFile(NSStringToStringW(@"test.dcm"), std::ios::in);
ptr<streamReader> reader(new streamReader(readStream));

// Parse the file into a dataSet structure
ptr<imebra::dataSet> testDataSet = 
        imebra::codecs::codecFactory::getCodecFactory()->load(reader);

// Get the patient name
NSString* patientNameCharacter = StringWToNSString(testDataSet->getString(0x0010, 0, 0x0010, 0));

// Get the first image
ptr<imebra::image> firstImage = testDataSet->getModalityImage(0);
UIImage* myUIImage = getImage(firstImage, 0);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜