Hi All,
I want to calculate the pixel count from PixelData element tag.
i am using following code :
E_TransferSyntax xfer = dataset->getOriginalXfer();
DicomImage * dcmImage = new DicomImage(dataset,xfer);
const DiPixel * dmp = dcmImage->getInterData();
unsigned long pixelCount = dmp->getCount();
unsigned long pixelDataCount = dmp->getInputCount();
Its working fine for uncompressed dicom images. But for compressed dicom images, getCount() API is crashing. I understand that this problem is because of compressed images.
I don't want to uncompress these images before using getCount() API because that will be overhead.
Can anyone please help me out to use getCount() and getInputCount() API for compressed images without un compressing those images.
Thanks,
Angad Nath
getCount() API crashing for compressed dicom images
Moderator: Moderator Team
-
- ICSMED DICOM Services
- Posts: 2217
- Joined: Fri, 2004-10-29, 21:38
- Location: Oldenburg, Germany
-
- ICSMED DICOM Services
- Posts: 2217
- Joined: Fri, 2004-10-29, 21:38
- Location: Oldenburg, Germany
There is no version 3.4 - do you man 3.5.4? The current version is 3.6.0, btw.
I can only repeat:i want to use getCount() and getInputCount() API. These API's are working fine for un compressed images but crashing for compressed images.
- Have you checked that the image could be processed at all (using DicomImage::getStatus())?
- Have you checked that "dmp" is not NULL?
Who is online
Users browsing this forum: Baidu [Spider] and 1 guest