Skip to content

Commit

Permalink
-json_export: Fix slice encoding direction sign
Browse files Browse the repository at this point in the history
  • Loading branch information
Lestropie committed May 13, 2024
1 parent fb4dd43 commit ca55d14
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/file/json_utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ namespace MR
const Eigen::Vector3d orig_dir (Axes::id2dir (slice_encoding_it->second));
Eigen::Vector3d new_dir;
for (size_t axis = 0; axis != 3; ++axis)
new_dir[axis] = flip[axis] ? orig_dir[order[axis]] : -orig_dir[order[axis]];
new_dir[axis] = flip[axis] ? -orig_dir[order[axis]] : orig_dir[order[axis]];
slice_encoding_it->second = Axes::dir2id (new_dir);
INFO ("Slice encoding direction written to JSON file modified according to expected output NIfTI header transform realignment");
}
Expand Down

0 comments on commit ca55d14

Please sign in to comment.