Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix method 2 and 3 responsibilities #35

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 1 addition & 5 deletions src/NIfTI.jl
Original file line number Diff line number Diff line change
Expand Up @@ -340,10 +340,6 @@ function NIVolume(
qoffset_y != 0 || qoffset_z != 0
method3 = orientation != nothing

if method2 && method3
error("Orientation parameters for Method 2 and Method 3 are mutually exclusive")
end

if method3
if size(orientation) != (3, 4)
error("Orientation matrix must be of dimensions (3, 4)")
Expand All @@ -363,7 +359,7 @@ function NIVolume(
slice_start, (qfac, voxel_size..., time_step, 0, 0, 0), 352,
scl_slope, scl_inter, slice_end, slice_code,
xyzt_units, cal_max, cal_min, slice_duration,
toffset, glmax, glmin, string_tuple(descrip, 80), string_tuple(aux_file, 24), (method2 || method3),
toffset, glmax, glmin, string_tuple(descrip, 80), string_tuple(aux_file, 24), method2,
method3, quatern_b, quatern_c, quatern_d,
qoffset_x, qoffset_y, qoffset_z, (orientation[1, :]...,),
(orientation[2, :]...,), (orientation[3, :]...,), string_tuple(intent_name, 16), NP1_MAGIC), extensions, raw)
Expand Down