Mercurial > hg > octave-avbm
changeset 6756:47dc81fefe8a
[project @ 2007-06-25 18:40:21 by jwe]
author | jwe |
---|---|
date | Mon, 25 Jun 2007 18:40:21 +0000 |
parents | 55411ecc8d8b |
children | c3cd7d14fc5e |
files | scripts/ChangeLog scripts/image/imshow.m |
diffstat | 2 files changed, 9 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/ChangeLog +++ b/scripts/ChangeLog @@ -1,8 +1,12 @@ +2007-06-25 Søren Hauberg <hauberg@gmail.com> + + * image/imshow.m: Fix check for colormap arguments. + 2007-06-25 Joel Keay <keay@nhn.ou.edu> * plot/drawnow.m: Handle GNUTERM=aqua if DISPLAY is not set. -2007-06-25 Søren Hauberg <hauberg@gmail.com> +2007-06-25 Søren Hauberg <hauberg@gmail.com> * statistics/base/median.m: Update help text to mention 'dim' argument, and note that the data should be sorted for the
--- a/scripts/image/imshow.m +++ b/scripts/image/imshow.m @@ -99,13 +99,13 @@ narg = 1; while (narg <= length (varargin)) arg = varargin{narg}; - if (ismatrix (arg) && ndims (arg) == 2) + if (ismatrix (arg) && size (arg, 2) == 3) + color_map = arg; + isindexed = true; + elseif (ismatrix (arg) && ndims (arg) == 2) display_range = arg; elseif (isempty (arg)) display_range = [min(im(:)), max(im(:))]; - elseif (ismatrix (arg) && size (arg, 2) == 3) - color_map = arg; - isindexed = true; elseif (ischar (arg) && strcmpi (arg, "displayrange")) narg++; display_range = varargin{narg};