• 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: NSReadPixel
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSReadPixel


  • Subject: Re: NSReadPixel
  • From: koko <email@hidden>
  • Date: Mon, 13 Feb 2012 09:48:52 -0700

Hello Kyle -

What I am trying to accomplish is my own 'eye-droper' color picker (for reasons I cannot get into).

Can you point me to the best method as I have done things other than a plain read pixel to no avail.

Thanks!

-koko



On Feb 11, 2012, at 10:09 AM, Kyle Sluder wrote:

> On Fri, Feb 10, 2012 at 4:44 PM, koko <email@hidden> 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@hidden)

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:

This email sent to email@hidden


  • Follow-Ups:
    • Re: NSReadPixel
      • From: Kyle Sluder <email@hidden>
References: 
 >Re: NSReadPixel (From: Kyle Sluder <email@hidden>)

  • Prev by Date: Re: Playing Music in Objective C
  • Next by Date: Odd display of percent character
  • Previous by thread: Re: NSReadPixel
  • Next by thread: Re: NSReadPixel
  • Index(es):
    • Date
    • Thread