Re: questions regarding using cgWindow, cgLoadCT, and something else [message #78112 is a reply to message #78111] |
Thu, 27 October 2011 10:24   |
Jeremy Bailin
Messages: 618 Registered: April 2008
|
Senior Member |
|
|
On 10/27/11 12:32 PM, Bill Murong wrote:
> Hi,
>
> I'm a beginner of using David's cgWindow. I'm wondering how to
> display two images using two different color tables in a cgWindow?
> I've tried a few things, but all failed.
>
> A second quesiton I'm having is when I issue the command: "cgloadct,
> 13, /addcmd". It will pop up two resizable windows: one with black
> background and one with white background.
>
> My final question is regarding using postscript font in IDL 7.0. When
> I generate a postscript file with ps font, the "multiple" sign cannot
> be displayed correctly (displayed as a "dot"); e.g., 6x10^5 will be
> displayed as 6*10^5. I have tried this on various computers with both
> Win and Mac. All give the same results.
>
> I'm wondering whether someone can help me with these IDL questions.
> Many thanks in advance.
>
> Bill
The easiest way is using the RGB_TABLE keyword to cglaodct to get the
table out, and the PALETTE keyword in cgimage to display it:
image = cgdemodata(18)
cgwindow
cgloadct, 4, rgb_table=table1
cgloadct, 13, rgb_table=table2
cgimage, image, palette=table1, /window, layout=[2,1,1]
cgimage, image, palette=table2, /addcmd, layout=[2,1,2]
-Jeremy.
|
|
|