Commit 9eccb156f5dfee724b8835b44c5e86efd8d63471
1 parent
8e34d14a
Exists in
master
and in
68 other branches
FIX: DICOM (to be attached) reconstruction is flattened. FIX #167
Showing
1 changed file
with
9 additions
and
3 deletions
Show diff stats
invesalius/control.py
... | ... | @@ -423,13 +423,19 @@ class Controller(): |
423 | 423 | debug("Not used the IPPSorter") |
424 | 424 | filelist = [i.image.file for i in dicom_group.GetHandSortedList()[::interval]] |
425 | 425 | |
426 | - | |
427 | - | |
428 | 426 | zspacing = dicom_group.zspacing * interval |
429 | 427 | size = dicom.image.size |
430 | 428 | bits = dicom.image.bits_allocad |
429 | + sop_class_uid = dicom.acquisition.sop_class_uid | |
430 | + xyspacing = dicom.image.spacing | |
431 | + | |
432 | + if sop_class_uid == '1.2.840.10008.5.1.4.1.1.7': #Secondary Capture Image Storage | |
433 | + use_dcmspacing = 1 | |
434 | + else: | |
435 | + use_dcmspacing = 0 | |
431 | 436 | |
432 | - imagedata = utils.CreateImageData(filelist, zspacing, size, bits) | |
437 | + imagedata = utils.CreateImageData(filelist, zspacing, xyspacing,size, | |
438 | + bits, use_dcmspacing) | |
433 | 439 | |
434 | 440 | # 1(a): Fix gantry tilt, if any |
435 | 441 | tilt_value = dicom.acquisition.tilt | ... | ... |