Re: IDL Colorbar generation question [message #49144] |
Mon, 03 July 2006 21:23 |
Michael Galloy
Messages: 1114 Registered: April 2006
|
Senior Member |
|
|
britneys@ucla.edu wrote:
> Hi All,
>
> I am attempting to add colorbars to my data plots. I have a set of
> self-defined colors that are used in my routine, saved to the standard
> R_CURR, G_CURR and B_CURR arrays. I had been trying to use either the
> IDLgrColorbar_define program or David Fanning's colorbar_define.
(Unrelated, but IDLgrColorbar__define has two underscores in and IDL
*will* be particular about it if you accidently name a class definition
routine with only one.)
> Using IDLgrColorbar_define as prescribed:
>
> oColorbar =OBJ_NEW("IDLgrColorbar", [R_CURR, G_CURR, B_CURR],
> SHOW_AXIS=1, Title='values', HIDE=0)
I think you want:
oColorbar = OBJ_NEW("IDLgrColorbar", R_CURR, G_CURR, B_CURR,
SHOW_AXIS=1, Title='values', HIDE=0)
i.e. color table values as three separate parameters instead of one long
3 * 256 element array.
Mike
--
www.michaelgalloy.com
|
|
|