Search found 18 matches

by Géant Vert
Thu, 2007-05-17, 13:00
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

I can give my image if you want test because I don't understand why it don't load correctly.
by Géant Vert
Wed, 2007-05-16, 12:55
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

Thanks for your help. But I 've got the same problem to read my image with your code.

This image are:

-16bits
-grayscale not rgb
-Hight bits:15
-Monochrome2
-Pixel representation 0

if you are other idea,i listen you :idea: .
by Géant Vert
Tue, 2007-05-15, 09:50
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

ok I want view this image. Here the dump of the image: Photometric interpretaion:MONOCHROME2 Bits Allocated: 16 Bits Stored:16 Hight Bit:15 Pixel Representation:0 So I create a DicomImage like this: E_TransferSyntax xfer = fileformat->getDataset()->getOriginalXfer(); DicomImage *imageDic=new DicomIm...
by Géant Vert
Tue, 2007-05-15, 07:49
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

i try it. But it don't run with my image 16bits in graylevel. Uint16 *imgData = new Uint16[(imageDic->getOutputDataSize (16))]; if (buffer != NULL) { // copy header to buffer OFBitmanipTemplate<Uint8>::copyMem((const Uint8 *)header, buffer, offset); //on copie l'entéte du header dasn le buffer bool ...
by Géant Vert
Mon, 2007-05-14, 10:19
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

If I understand GetOutputdata copy the pixel data to an pointer.

But ,does this function copy an other information?

I ask this because when i allocate my pointer with the size of the image, this function don't run. But when i allocate with greater than the size it run :? .
by Géant Vert
Thu, 2007-05-10, 12:32
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

When I use DicomWorks to read the image, it displays. But my program don't displays this image correctly
.
by Géant Vert
Wed, 2007-05-09, 14:37
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

Before the conversion: when i use the dcmtk function getMinMax, I find 0 and 65536 so after conversion i have find 0 and 255.

After the convert.
I did this but when I search the maximum and the minimum the both is equalizing to 0.
by Géant Vert
Wed, 2007-05-09, 07:06
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

I must convert the image 16bits to 8bits because I work only on the 256 level's gray.

If i search the max and the min,it aims to doing an dynamic expansion of the image.
by Géant Vert
Fri, 2007-05-04, 14:42
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

Thanks. But now I 've got problem with 16bits images. int lenght=width*height; int min=256,max=-1; Ushort *tab=new Ushort (lenght); Uint8 *tab8b=new Uint8 (length); imageDic->getOutputData((void *)(tab), length, 16); for(int i=0;i<lenght;i++) { if(min>tab )min=tab ; if(max<tab )max=tab ; } for(int i...
by Géant Vert
Wed, 2007-04-25, 09:44
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

Roger! I resolve my problem with using decode codec before the creation of PPM or PGM.

Thank a lot for your help
by Géant Vert
Wed, 2007-04-25, 07:30
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

thank again. It 's easy to read coloured image. Here the code: sprintf(header, "P6\n%i %i\n255\n", width, height); //entéte du PPM format image non compressé const int offset = strlen(header); //on prend la longueur de l'entéte const unsigned int length = width * height*3 + offset; //on multiplie pa...
by Géant Vert
Tue, 2007-04-24, 13:42
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

I do it and it 's good. But I can't read dicom image colour. is there a solution to display colour image?
by Géant Vert
Tue, 2007-04-24, 12:58
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

Thanks since I create the variable environement, It runs. ;)

Next step read the pixeldata in memory without to create a external file.
by Géant Vert
Tue, 2007-04-24, 08:43
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

DicomImage *imageDic=NULL; imageDic = new DicomImage (&fileformat,xfer,CIF_MayDetachPixelData ); if(imageDic->getStatus()==EIS_Normal) When i use getStatus, it equalize to EIS_NoDataDictionnary. Must I load a .dic before to display an image? Must I find the format of image to use writeBMP function?...
by Géant Vert
Mon, 2007-04-23, 14:54
Forum: DCMTK - General
Topic: dcmtk with QT
Replies: 34
Views: 33464

I succeed to display a bmp. But this code doesn't run. DicomImage *image=NULL; image = new DicomImage(nameFile); image->writeBMP("te.bmp",8,0); // i create a bmp QPixmap pixmap("te.bmp"); labeldisplay->setPixmap(pixmap) ; "nameFile" is the adress of the file ("D:/image/test.dcm") if you can help me,...