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

Home » Public Forums » archive » Re: hieghlighting pixel
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: hieghlighting pixel [message #71098 is a reply to message #71097] Thu, 27 May 2010 00:20 Go to previous message
rogass is currently offline  rogass
Messages: 200
Registered: April 2008
Senior Member
On 27 Mai, 06:56, afzal <afzal....@gmail.com> wrote:
> in my work  i need  to highlight some points(pixels) of binary image
> with some color(eg:-red). cud anybody help me to do this
> thanking you
> afzal

This will be difficult, because a binary image only has 0's and 1's.
You have to transform the image, e.g.:

tv,[[[255b*((ff=dist(256) gt 100.))]],[[255b*(ff eq 0b)]],
[[255b*(temporary(ff) eq 0)]]] ,true=3

or maybe in your case:

showresultonly=1; or 0 to keep the new result
condition = image eq 1; or 0 if you want to highlight the 0's
red=255b
green=0b; 255b if you want to show 0's in green you must also set blue
to 0b
blue=255b
; to show only the condition in red you have to set green and blue to
0b
result=[[[red*condition]],[[green*(~condition)]],
[[blue*(~temporary(condition))]]]
tvscl, showresultonly? temporary(result) : result,true=3 ; shows 1's
in red and 0's in blue according your condition

Hope it helps

CR
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: IDLDE can not start in Ubuntu10.04
Next Topic: Re: Integrator taking vectors as input?

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

Current Time: Wed Oct 08 19:55:30 PDT 2025

Total time taken to generate the page: 0.00213 seconds