Mercurial > hg > octave-lyh
changeset 7226:a3ad66fea44a
[project @ 2007-11-30 07:53:24 by jwe]
author | jwe |
---|---|
date | Fri, 30 Nov 2007 07:53:24 +0000 |
parents | 1f3e360c1bba |
children | bf7235434a2a |
files | scripts/plot/__go_draw_axes__.m |
diffstat | 1 files changed, 4 insertions(+), 14 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/plot/__go_draw_axes__.m +++ b/scripts/plot/__go_draw_axes__.m @@ -502,13 +502,8 @@ if (numel(ccol) == 3) color = ccol; else - if (cautoscale) - r = 1 + round ((size (cmap, 1) - 1) - * (ccol - cmin)/(cmax - cmin)); - else - r = 1 + round ((size (cmap, 1) - 1) - * (ccol - clim(1))/(clim(2) - clim(1))); - endif + r = 1 + round ((size (cmap, 1) - 1) + * (ccol - clim(1))/(clim(2) - clim(1))); r = max (1, min (r, size (cmap, 1))); color = cmap(r, :); endif @@ -600,13 +595,8 @@ if (numel(ccol) == 3) color = ccol; else - if (cautoscale) - r = 1 + round ((size (cmap, 1) - 1) - * (ccol - cmin)/(cmax - cmin)); - else - r = 1 + round ((size (cmap, 1) - 1) - * (ccol - clim(1))/(clim(2) - clim(1))); - endif + r = 1 + round ((size (cmap, 1) - 1) + * (ccol - clim(1))/(clim(2) - clim(1))); r = max (1, min (r, size (cmap, 1))); color = cmap(r, :); endif