Skip to content

Commit

Permalink
fix: 🐛 When converting to multiframe, fix IPP issues (#152)
Browse files Browse the repository at this point in the history
If datasets aren't already in order, the datasets where getting sorted
then given the unsorted IPP. This if now fixed.
  • Loading branch information
JamesAPetts authored Oct 19, 2020
1 parent 7cf65b5 commit 250c1ca
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/normalizers.js
Original file line number Diff line number Diff line change
Expand Up @@ -262,12 +262,12 @@ class ImageNormalizer extends Normalizer {

// copy over each datasets window/level into the per-frame groups
// and set the referenced series uid
this.datasets.forEach(function(dataset, datasetIndex) {
distanceDatasetPairs.forEach(function(pair) {
const dataset = pair[1];

ds.PerFrameFunctionalGroupsSequence.push({
PlanePositionSequence: {
ImagePositionPatient:
distanceDatasetPairs[datasetIndex][1]
.ImagePositionPatient
ImagePositionPatient: dataset.ImagePositionPatient
},
FrameVOILUTSequence: {
WindowCenter: dataset.WindowCenter,
Expand Down

0 comments on commit 250c1ca

Please sign in to comment.