Re: Drawing a single pixel
Re: Drawing a single pixel
- Subject: Re: Drawing a single pixel
- From: Vince DeMarco <email@hidden>
- Date: Sat, 26 May 2001 20:24:58 -0700
On Saturday, May 26, 2001, at 08:06 PM, email@hidden wrote:
I wrote a mset fractal program a while back for Mac OS <9 in C. And I
would like to write one in cocoa. Well, I was just wondering how to
draw a single pixel. I guess I could use NSBezier and just make a rect
that is 1 pixel large but I was wondering if there was a way to just do
a single pixel.
You could create a NSImage with a NSBitmapImageRep (you can get at the
bitmap data from BitmapImageRep) set the pixel you want then composite
this back into your View when appropriate.
vince