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

Home » Public Forums » archive » Re: Displaying a plot and a true color image on the same window
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: Displaying a plot and a true color image on the same window [message #24888] Mon, 30 April 2001 07:09 Go to next message
Liam E. Gumley is currently offline  Liam E. Gumley
Messages: 378
Registered: January 2000
Senior Member
Alok Nagdev wrote:
> I'm displaying some bytescaled elevation data using color table (in my
> case its RAINBOW with top WHITE) below this I'm trying to display true
> color jpeg images on the same window. As soon as the color table is
> loaded the color images are displayed according to the color table
> being used, and loose their true color.
>
> I found that this is due to the color table as if I dont load the
> color table, images are displayed perfectly fine.

Alok,

See the 8-bit example shown at the top of the IMDISP page:
http://cimss.ssec.wisc.edu/~gumley/imdisp.html

Cheers,
Liam.
http://cimss.ssec.wisc.edu/~gumley/
Re: Displaying a plot and a true color image on the same window [message #24889 is a reply to message #24888] Sun, 29 April 2001 18:29 Go to previous messageGo to next message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
David Fanning (davidf@dfanning.com) writes:

>> I'm displaying some bytescaled elevation data using color table (in my case
>> its RAINBOW with top WHITE) below this I'm trying to display true color jpeg
>> images on the same window. As soon as the color table is loaded the color
>> images are displayed according to the color table being used, and loose their
>> true color.

Here is something else to try. Use my program TVIMAGE to
display the image data, rather than TV. That way, you
won't have to worry about all the decomposed stuff.
Does that help?

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
Re: Displaying a plot and a true color image on the same window [message #24891 is a reply to message #24889] Sun, 29 April 2001 18:21 Go to previous messageGo to next message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Alok Nagdev (nagdev@csee.usf.edu) writes:

> Thanks David, but I'm still having the same problem...probably I couldnt
> phrase the problem properly. Here it is again:
>
> I'm displaying some bytescaled elevation data using color table (in my case
> its RAINBOW with top WHITE) below this I'm trying to display true color jpeg
> images on the same window. As soon as the color table is loaded the color
> images are displayed according to the color table being used, and loose their
> true color.
>
> I found that this is due to the color table as if I dont load the color
> table, images are displayed perfectly fine.
>
> Hope this time I phrased it correctly!!

Well, I think you are phrasing it correctly.
But you still haven't told me what kind of
visual display depth you are using or what kind
of machine you are running IDL on, so I am
still shooting in the dark. But I stand by my
advice:

24-bit color: Device, Decomposed=1
8-bit color: Color_Quan with CUBE=6.

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
Re: Displaying a plot and a true color image on the same window [message #24892 is a reply to message #24891] Sun, 29 April 2001 17:09 Go to previous messageGo to next message
Alok Nagdev is currently offline  Alok Nagdev
Messages: 11
Registered: April 2001
Junior Member
<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
<html>
<font color="#3333FF">Thanks David, but I'm still having the same problem...probably
I couldnt phrase the problem properly. Here it is again:</font><font color="#3333FF"></font>
<p><font color="#3333FF">I'm displaying some bytescaled elevation data
using color table (in my case its RAINBOW with top WHITE) below this I'm
trying to display true color jpeg images on the same window. As soon as
the color table is loaded the color images are displayed according to the
color table being used, and loose their true color.</font><font color="#3333FF"></font>
<p><font color="#3333FF">I found that this is due to the color table as
if I dont load the color table, images are displayed perfectly fine.</font><font color="#3333FF"></font>
<p><font color="#3333FF">Hope this time I phrased it correctly!!</font><font color="#3333FF"></font>
<p><font color="#3333FF">Thanks,</font>
<br><font color="#3333FF">-Alok</font>
<br>&nbsp;
<p>David Fanning wrote:
<blockquote TYPE=CITE>&nbsp;
<br>Well, now that I read this a little more closely,
<br>I think the problem is that you are trying to
<br>display these images on an 8-bit display. This
<br>makes the problem more difficult, but not
<br>impossible.
<p>What you need to do is make all your images and your
<br>color bar share the same color space. I think the
<br>sensible way to do this is to use COLOR_QUAN with
<br>the CUBE keyword set to 6 on all your image. This
<br>will quantitize your colors to 216 values that
<br>can faithfully (more or less) represent both the
<br>images and (I presume) color bar.
<p>Cheers,
<p>David
<br>--
<br>David Fanning, Ph.D.
<br>Fanning Software Consulting
<br>Phone: 970-221-0438 E-Mail: davidf@dfanning.com
<br>Coyote's Guide to IDL Programming: <a href="http://www.dfanning.com/">http://www.dfanning.com/</a>
<br>Toll-Free IDL Book Orders: 1-888-461-0155</blockquote>
</html>
Re: Displaying a plot and a true color image on the same window [message #24895 is a reply to message #24892] Sat, 28 April 2001 18:22 Go to previous messageGo to next message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Alok Nagdev (nagdev@csee.usf.edu) writes:

> I'm trying to display a plot using color bar and a few true color image
> on the same window but as soon as the color table is loaded, the true
> color image is displayed according to color bar being used. Is there any
> other way this could be done?? Images I'm displaying are jpeg images.

Well, now that I read this a little more closely,
I think the problem is that you are trying to
display these images on an 8-bit display. This
makes the problem more difficult, but not
impossible.

What you need to do is make all your images and your
color bar share the same color space. I think the
sensible way to do this is to use COLOR_QUAN with
the CUBE keyword set to 6 on all your image. This
will quantitize your colors to 216 values that
can faithfully (more or less) represent both the
images and (I presume) color bar.

Cheers,

David
--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
Re: Displaying a plot and a true color image on the same window [message #24896 is a reply to message #24895] Sat, 28 April 2001 18:06 Go to previous messageGo to next message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Alok Nagdev (nagdev@csee.usf.edu) writes:

> I'm trying to display a plot using color bar and a few true color image
> on the same window but as soon as the color table is loaded, the true
> color image is displayed according to color bar being used. Is there any
> other way this could be done??

This opens up a whole new line of business for me!

Device, Decomposed=1

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
Re: Displaying a plot and a true color image on the same window [message #24941 is a reply to message #24889] Thu, 03 May 2001 07:25 Go to previous message
Martin Schultz is currently offline  Martin Schultz
Messages: 515
Registered: August 1997
Senior Member
davidf@dfanning.com (David Fanning) writes:

> David Fanning (davidf@dfanning.com) writes:
>
>>> I'm displaying some bytescaled elevation data using color table (in my case
>>> its RAINBOW with top WHITE) below this I'm trying to display true color jpeg
>>> images on the same window. As soon as the color table is loaded the color
>>> images are displayed according to the color table being used, and loose their
>>> true color.
>
> Here is something else to try. Use my program TVIMAGE to
> display the image data, rather than TV. That way, you
> won't have to worry about all the decomposed stuff.
> Does that help?
>
> Cheers,
>
> David

... or read David's article on loading two color tables together
(provided you are using 8 bit colors),

Martin

--
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[ [[[[[[[
[[ Dr. Martin Schultz Max-Planck-Institut fuer Meteorologie [[
[[ Bundesstr. 55, 20146 Hamburg [[
[[ phone: +49 40 41173-308 [[
[[ fax: +49 40 41173-298 [[
[[ martin.schultz@dkrz.de [[
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[ [[[[[[[
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Hough Transform
Next Topic: write_ppm (newbie)

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

Current Time: Wed Oct 08 13:39:34 PDT 2025

Total time taken to generate the page: 0.00577 seconds