From 9227c83eddddee78aef794daa78cd71e6d43555e Mon Sep 17 00:00:00 2001 From: Eric Wait <eric@waitphoto.com> Date: Thu, 19 Jul 2018 23:05:28 -0400 Subject: [PATCH] Fixed how loadImage uses the new brighten image from utils repo --- src/matlab/+D3d/LoadImage.m | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/matlab/+D3d/LoadImage.m b/src/matlab/+D3d/LoadImage.m index d4befc0..78f8e19 100644 --- a/src/matlab/+D3d/LoadImage.m +++ b/src/matlab/+D3d/LoadImage.m @@ -1,6 +1,6 @@ %LOADIMAGE D3d.LoadImage( im, bufferNum, frameNumber, nonNormalized) -function im8 = LoadImage( im, bufferNum, frameNumber, dontNormalized ) +function im8 = LoadImage( im, bufferNum, frameNumber, normalize ) global D3dIsOpen if (isempty(D3dIsOpen) || ~D3dIsOpen) error('You need to open the viewer before you can load images! Call D3d.Open first.'); @@ -20,8 +20,8 @@ function im8 = LoadImage( im, bufferNum, frameNumber, dontNormalized ) error('You can only load one frame at a time!'); end - if (~exist('nonNormalized','var') || isempty(dontNormalized)) - dontNormalized = false; + if (~exist('nonNormalized','var') || isempty(normalize)) + normalize = true; end bufferType = 'original'; @@ -34,8 +34,8 @@ function im8 = LoadImage( im, bufferNum, frameNumber, dontNormalized ) im = permute(im,[1,2,5,4,3]); end - if (dontNormalized) - im8 = ImUtils.ConvertType(im,'uint8'); + if (~normalize) + im8 = ImUtils.ConvertType(im,'uint8',false); else im8 = ImUtils.BrightenImages(im,'uint8'); end -- GitLab