Commit 71036c6f authored by ac 20's avatar ac 20

is3D take constants or image

parent 5404fcb5
function b3D=is3D(im)
% pass in either an image or a constants struct and we'll tell you if it's
% 3d or not
function b3D=is3D(imOrConstants)
if length(size(im))==3
b3D=false;
if isfield(imOrConstants,'imageData')
% imOrConstants is a CONSTANTS
if length(imOrConstants.imageData.Dimensions)==3 && imOrConstants.imageData.Dimensions(3)>1
b3D=true;
end
return;
end
% else imOrConstants is an image
if length(size(imOrConstants))==3
b3D=true;
else
b3D=false;
end
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment