• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Bug in [path containsPoint]?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bug in [path containsPoint]?


  • Subject: Re: Bug in [path containsPoint]?
  • From: "John C. Randolph" <email@hidden>
  • Date: Fri, 3 Jun 2005 16:38:18 -0700

Are you sending -closePath, or just adding a path segment back to the first point?

-jcr


On Jun 2, 2005, at 1:05 PM, Brian O'Brien wrote:

I think I've found a but in NSBezierPath, but not sure.
I've written an application that draws a polygon on top of an image (using mouse clicks)
After the polygon (a simple triangle) is defined and the mouse enters the polygon the image is filled with a particular pixel color.


I get the bounding box of the polygon then check each pixel in the bounding box (using containsPoint) to determine
if the image's pixel should be changed.


Depending on the order that the polygon was defined (ie left hand rule vs right hand rule) I get different values
for contiansPoint and in fact some of the values are not even in the polygon boundary. (the bug)


Can someone verify that this happens one their system as well?

I'm on 10.3.9

<Picture 1.pdf>


Notice the bottom polygon has a white horizontal line outside the polygon, where as the other doesn't?
This is reproducible in my application.


John C. Randolph <email@hidden> (408) 974-8819
Lame Duck Cocoa Engineer,
Apple Worldwide Developer Relations
http://developer.apple.com/cocoa/index.html



_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: Bug in [path containsPoint]?
      • From: "Brian O'Brien" <email@hidden>
References: 
 >Bug in [path containsPoint]? (From: "Brian O'Brien" <email@hidden>)

  • Prev by Date: Re: QTMovieView or QTMovie
  • Next by Date: HFS promise drag operation in Tiger
  • Previous by thread: Bug in [path containsPoint]?
  • Next by thread: Re: Bug in [path containsPoint]?
  • Index(es):
    • Date
    • Thread