Mercurial > octave-nkf
comparison scripts/image/gray.m @ 14640:b9c02ee24de1
new colormap options
* colormap.m: New options, list, register, and unregister.
* NEWS: Note new colormap options.
* autumn.m, bone.m, cool.m, copper.m, flag.m, gmap40.m, gray.m, hot.m,
hsv.m, jet.m, lines.m, ocean.m, pink.m, prism.m, rainbow.m,
spring.m, summer.m, winter: Always size and return 0x3 when size < 1.
Include PKD_ADD and PKG_DEL commands to register and unregister
colormap funtions.
author | Carnë Draug <carandraug+dev@gmail.com> |
---|---|
date | Wed, 16 May 2012 16:52:08 -0400 |
parents | f205d0074687 |
children | 5f1d4def40e1 |
comparison
equal
deleted
inserted
replaced
14639:87a50e7cec7a | 14640:b9c02ee24de1 |
---|---|
28 | 28 |
29 ## Author: Tony Richardson <arichard@stark.cc.oh.us> | 29 ## Author: Tony Richardson <arichard@stark.cc.oh.us> |
30 ## Created: July 1994 | 30 ## Created: July 1994 |
31 ## Adapted-By: jwe | 31 ## Adapted-By: jwe |
32 | 32 |
33 ## PKG_ADD: colormap ("register", "gray"); | |
34 ## PKG_DEL: colormap ("unregister", "gray"); | |
35 | |
33 function map = gray (n) | 36 function map = gray (n) |
34 | 37 |
35 if (nargin == 0) | 38 if (nargin == 0) |
36 n = rows (colormap); | 39 n = rows (colormap); |
37 elseif (nargin == 1) | 40 elseif (nargin == 1) |