Mercurial > hg > octave-image
changeset 612:7c1df1b5f058
isgray: return true for int16 class
author | carandraug |
---|---|
date | Wed, 26 Sep 2012 06:51:51 +0000 |
parents | 9994e96e9ade |
children | c33c12769b71 |
files | NEWS inst/isgray.m |
diffstat | 2 files changed, 4 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/NEWS +++ b/NEWS @@ -78,6 +78,8 @@ used as input, `isbw' will still return true but a warning will be issued since this will deprecated later. + ** `isgray' now also returns true for matrices of the int16 class. + ** `isrgb' now returns false for logical matrix. ** `tiff_tag_read' had several bug fixes and can now check IFDs beyond
--- a/inst/isgray.m +++ b/inst/isgray.m @@ -22,7 +22,7 @@ ## non-sparse matrix, and: ## @itemize @bullet ## @item is of class double and all values are in the range [0, 1]; -## @item is of class uint8 or uint16. +## @item is of class uint8, uint16 or int16. ## @end itemize ## ## Note that grayscale time-series image have 4 dimensions (NxMx1xtime) but @@ -44,7 +44,7 @@ switch (class (img)) case "double" bool = ispart (@is_double_image, img); - case {"uint8", "uint16"} + case {"uint8", "uint16", "int16"} bool = true; endswitch endif