On Fri, Feb 10, 2012 at 4:44 PM, koko <[email protected]> wrote:
> I have two monitors connected.
>
> When I call NSreadPixel with a point that is on the main screen, origin 0,0 
> it returns the appropriate NSColor;
>
> When I call NSreadPixel with a point that is on the 2nd screen, origin 
> -1280,0 it returns nil as the NSColor;
>
> So, how do I get the NSColor for a pixel whose x coordinate is <0?

1. Are you sure you're actually passing the correct point? NSReadPixel
operates in the coordinate system of the currently-focused view. You
might be getting the right color by sheer luck.
2. Why are you using NSReadPixel at all? There might be better ways of
accomplishing your goal.

--Kyle Sluder
_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to