comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: How-to? color png
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: How-to? color png [message #27659 is a reply to message #27658] Mon, 29 October 2001 14:19 Go to previous messageGo to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Andrew Cool (andrew.cool@dsto.defence.gov.au) writes:

> You probably need to insert :-
>
> 6a) TVLCT,r,g,b,/GET ; get the current colour tables
>
> and then change 7 to be :-
>
> 7) write_png, 'image.png', data, r,g,b ; write out colour tables too!

On a super-duper Mac!? I doubt it.

More likely something like this (assuming he wants
a flat 2D PNG image):

6) data=tvrd() ; Whoops! Not on 24-bit display.
6a) data = Tvrd(True=1)
6b) image2D = Color_Quan(data, 1, r, g, b, Colors=colors, Dither=dither)
7) write_png, 'image.png', image2D, r, g, b

If he wants a 24-bit image, then:

6) data = TVRD(True=1)
7) write_png, 'image.png', data

Cheers,

David

--
David W. Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438, E-mail: david@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Resolution
Next Topic: Re: IDL .SAV cross-platform problem

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 17:33:32 PDT 2025

Total time taken to generate the page: 0.00368 seconds