Skip to content

Commit

Permalink
Do not normalize voxel intensity if f_high is <= 0.0 (#31)
Browse files Browse the repository at this point in the history
  • Loading branch information
neurolabusc committed Sep 11, 2024
1 parent 4cdd70e commit 9f3a301
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/conform.c
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,8 @@ int conform_core(nifti_image *nim, const int outDims[3], const float outPixDims[
if (nVol != 1)
return 1;
//normalize voxel brightness 0..255
voxelIntensityScale(nim, f_high);
if (f_high > 0.0)
voxelIntensityScale(nim, f_high);
//estimate spatial transform
const int inDims[3] = {(int)nim->nx, (int)nim->ny, (int)nim->nz};
mat44 in_affine = f642f32mat44(&nim->sto_xyz);
Expand Down
2 changes: 1 addition & 1 deletion src/niimath.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
#define kOS "Windows"
#endif

#define kMTHdate "v1.0.20240908"
#define kMTHdate "v1.0.20240911"
#define kMTHvers kMTHdate kOMPsuf kCCsuf

#ifdef NII2MESH
Expand Down

0 comments on commit 9f3a301

Please sign in to comment.