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

Home » Public Forums » archive » Re: Display two images on one position
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: Display two images on one position [message #28659 is a reply to message #28658] Sun, 23 December 2001 18:27 Go to previous messageGo to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
David Fanning (david@dfanning.com) writes:

> At the very least, you can speed this code up
> tremendously by doing this:
>
> TV, image
> LoadCT, 5
> TV, highlight * (highlight NE 0)

Well, that's probably not right, come to think
of it. Let's see..

How about this:

LoadCT, 0, NColors=100
s = Size(image, /Dimensions)
composite = BytArr(s[0], s[1])
imageIndex = Where(highlight EQ 0, Complement=hltIndex)
composite[imageIndex] = BytScl(image[imageIndex], Top=99)
composite[hltIndex] = BytScl(highlight[hltIndex], Top=99) + 100B
LoadCT, 5, NColors=100, Bottom=100
TV, composite

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
Previous Topic: Write_Image
Next Topic: Re: Display two images on one position : or even three!

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

Current Time: Sat Oct 11 08:40:00 PDT 2025

Total time taken to generate the page: 1.44203 seconds