Search found 15 matches

by mhavu
Mon, 2006-02-13, 20:09
Forum: DCMTK - General
Topic: Question to FAQ #24 (how to access original pixel data)
Replies: 3
Views: 5015

The data you get from getInterData() is always in your system's native byte order. If you want to know the original byte order of the DICOM file, you can use DcmDataset::getOriginalXfer().
by mhavu
Mon, 2006-02-13, 15:51
Forum: DCMTK - General
Topic: DiPixel::getData...() methods
Replies: 5
Views: 7957

I couldn't get the code to work, so I changed it so that getInterData() is only used for monochrome images, and color images are rendered with getOutputData(). This makes more sense anyway.
by mhavu
Wed, 2006-02-08, 14:00
Forum: DCMTK - General
Topic: DiPixel::getData...() methods
Replies: 5
Views: 7957

Of course, the size of the array returned by DiPixel::getData() and DicomImage::getOutputData() can differ. The latter is used to get rendered pixel data which might have a different depth than the internal representation. Doesn't that happen only in case of EPI_PaletteColor or when I explicitly de...
by mhavu
Wed, 2006-02-08, 13:17
Forum: DCMTK - General
Topic: DiPixel::getData...() methods
Replies: 5
Views: 7957

DiPixel::getData()

Thanks for shedding light on the DiPixel design issue. I do have a check for data != NULL , but I haven't taken any measures to make sure that the array I get from getData() is actually the size it should be (is it even possible?). What I'm doing with the data is passing it over to a library routine...
by mhavu
Wed, 2006-02-08, 00:18
Forum: DCMTK - General
Topic: DiPixel::getData...() methods
Replies: 5
Views: 7957

DiPixel::getData...() methods

Hi, I'm having a hard time trying to understand the difference between the DiPixel methods getData(), getDataArrayPtr() and getDataPtr(). I am trying to assign a value to const void *data with the following piece of code: const DiPixel *pixeldata = dimg->getInterData(); if (pixeldata != NULL) { data...
by mhavu
Sat, 2006-02-04, 19:59
Forum: DCMTK - General
Topic: Examples using getInterData()
Replies: 2
Views: 5360

Examples using getInterData()

Thanks! That did it. Here's a version that supports compressed and color images as well, in case someone is interested: // test program for DicomImage::getInterData() // -- requires DCMTK version 3.5.4 #include "dcmtk/config/osconfig.h" #include "dcmtk/dcmimgle/dcmimage.h" #inclu...
by mhavu
Fri, 2006-02-03, 11:21
Forum: DCMTK - General
Topic: Examples using getInterData()
Replies: 2
Views: 5360

Examples using getInterData()

I'm trying to construct a program that uses DicomImage::getInterData() to access the pixel data. However, the getCount() method of the DiPixel object I get from it always seems to return 0. Could someone point me to a working example of how to use the new getInterData() method, please?
by mhavu
Tue, 2005-12-06, 20:42
Forum: DCMTK - General
Topic: DiPluginFormat and pixel data
Replies: 4
Views: 5474

Indeed. Thanks. Will the new getInterData method apply the modality LUT or not?

- Marko
by mhavu
Sun, 2005-12-04, 13:55
Forum: DCMTK - General
Topic: DiPluginFormat and pixel data
Replies: 4
Views: 5474

Update

I forgot to post an update, but I found out later on that this has actually nothing to do with the DiPluginFormat. The mapping happens with both DicomImage::getOutputData() and DiImage::getOutputData() regardless of whether DiPluginFormat is used or not. I'd still like to know why.

- Marko
by mhavu
Sat, 2005-12-03, 11:21
Forum: DCMTK - General
Topic: Number of images in a DICOM file
Replies: 2
Views: 4161

What is the number of frames in this case? Single-frame images are not required to have this attribute. What does dcmdump say? Does the file have a Number of frames tag (0028,0008)?

- Marko
by mhavu
Mon, 2005-11-28, 22:00
Forum: DCMTK - General
Topic: Pixel Data
Replies: 8
Views: 15133

Apparently the pixelData doesn't retain its value after all, but changes to NULL even on successful calls. I was mistaken because of a structure like this: const Uint8 *pixeldata8 = NULL; const Uint16 *pixeldata16 = NULL; if (data->findAndGetUint8Array(DCM_PixelData, pixeldata8).bad()) if (data->fin...
by mhavu
Mon, 2005-11-28, 17:58
Forum: DCMTK - General
Topic: Pixel Data
Replies: 8
Views: 15133

No, these particular files use the Little Endian Explicit (1.2.840.10008.1.2.1) Transfer Syntax. I'm at a loss here.

- Marko
by mhavu
Mon, 2005-11-28, 17:33
Forum: DCMTK - General
Topic: Robust way to tell whether a file is a DICOM
Replies: 4
Views: 6518

DICOM 3.0 files begin with a 128-byte preamble and the ASCII characters 'D', 'I', 'C', 'M'. You might want to take a look at http://support.dcmtk.org/docs/dcmftest.html . If your files are not DICOM part 10 compliant, you might find some of the code at http://paine.wiau.man.ac.uk/pub/doc_vxl/core/vi...
by mhavu
Mon, 2005-11-28, 16:52
Forum: DCMTK - General
Topic: Pixel Data
Replies: 8
Views: 15133

I have the same problem under Mac OS X 10.2.8 and DCMTK 3.5.3: Successful calls to findAndGetUint16Array() or findAndGetUint8Array() don't change the value of pixelData. I have tried with both count == NULL and count == n , but the value of pixelData always remains the same it was before the call - ...
by mhavu
Thu, 2005-11-24, 00:43
Forum: DCMTK - General
Topic: DiPluginFormat and pixel data
Replies: 4
Views: 5474

DiPluginFormat and pixel data

Hi, I use a class derived from DiPluginFormat to act as a bridge between my application and DICOM images. I'm trying to read a bunch of 16-bit signed velocity-encoded MRI images, where the pixel values vary e.g. from -100 to 100. If I read these with DiImage::getOutputData() , the pixel values becom...