Test for "within graphic"?

Ken Ray kray at sonsothunder.com
Wed Mar 24 10:35:58 EST 2004


Yes - use the within() function:

  if within(grc "Polygon","100,125") then
    -- etc.
  end if

HTH,

Ken Ray
Sons of Thunder Software
Email: kray at sonsothunder.com
Web Site: http://www.sonsothunder.com/


> -----Original Message-----
> From: use-revolution-bounces at lists.runrev.com 
> [mailto:use-revolution-bounces at lists.runrev.com] On Behalf Of 
> Springer, Paul
> Sent: Wednesday, March 24, 2004 9:05 AM
> To: How to use Revolution
> Subject: Test for "within graphic"?
> 
> 
> Hi all,
> 
>  
> 
> I am trying to figure out how to test to see if a given point 
> is within the sides of an irregular polygon (e.g. a 
> triangle). The rectangle of the graphic covers too much area 
> - I just want to test within the area which would be colored 
> if you set the backgroundColor of the graphic. Does anyone 
> have any suggestions? Thanks.
> 
>  
> 
> -Paul
> 
>  
> 
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com 
> http://lists.runrev.com/mailman/listinfo/use-revolution
> 




More information about the use-livecode mailing list