Re: ION script - true colour [message #48298] |
Mon, 10 April 2006 10:46  |
Haje Korth
Messages: 651 Registered: May 1997
|
Senior Member |
|
|
Greg,
from the manual:
"Direct Graphics
Images created using the IDL Direct Graphics commands are drawn to the IDL
Z-Buffer. The Z-Buffer is an 8-bit device that stores intensity values for
each pixel. These values are combined with the current color map to produce
the final output image. If you change the device in any IDL code that is
executed in an <ION_IMAGE> tag, you must make sure to change the device back
to the Z-Buffer and TV the final image to it."
I use object graphics to avoid this limitation. For the record: I learned
object graphics specifically for this one task and it is probably the only
time it ever shoes up in my codes! :-)
Haje
"greg michael" <greg.michael@gmail.com> wrote in message
news:1144689324.286686.231020@u72g2000cwu.googlegroups.com.. .
> Is it possible to use true colour with ION script? My program make an
> RGB output which ION handles like this...
>
> IDL> set_plot, 'Z'
> IDL> device, SET_RESOLUTION=[320,256]
>
> ...code...
>
> IDL> ion__img = tvrd()
> IDL> tvlct, ion__r, ion__g, ion__b, /GET
> IDL> ion__tmp = bytarr(3, 320, 256)
> IDL> ion__tmp[0, *, *] = ion__r[ion__img]
> IDL> ion__tmp[1, *, *] = ion__g[ion__img]
> IDL> ion__tmp[2, *, *] = ion__b[ion__img]
> IDL> ion__img = ion__tmp
> IDL> !QUIET = 1
> IDL> write_jpeg, 'C:\DOCUME~1\ADMINI~1\LOCALS~1\Temp\ion1452.jpg',
> ion__img, TRUE=1
>
> which is assuming that I'm using a colour table. Comes out b/w. You can
> choose between png8, png24 and jpeg24, but they all do the same. Don't
> seem to be any true options for the ION_IMAGE tag.
>
> regards,
> Greg
>
|
|
|