Stupid question: Flood Fill
Stupid question: Flood Fill
- Subject: Stupid question: Flood Fill
- From: Jens Bauer <email@hidden>
- Date: Tue, 25 Nov 2003 03:36:37 +0100
Hi all,
How do I [path floodfill] ?
:)
-In other words: Is there a flood fill in Cocoa, which can magically
fill a shape, without knowing what the shape looks like ?
I believe the answer is no, and I believe that I need to use something
that turns off antialiasing or so..
What I want, is to be able to make a nice drawing in a window, using
antialiased lines, then some of the shapes should be filled.
Now... When the user is satisfied with the look of the drawing, he
might want to save it as a PDF or print it out, and *there* I'd like a
[NSBezierPath floodfill].
I know it's possible to make a huge work-around, where you have
sharp-pixel-image, a smooth-pixel-image, a bunch of drawing commands
and a whistle, one could actually from the sharp-pixel-image generate a
path for a filled shape, but.. If this is going to be done on every
redraw, I feel it's wrong.
In fact, I already feel bad about what I've done so far.
I remember each drawing command, so that I can reproduce the drawing
correctly, when it's going to be printed. Even worse, I've just
refreshed the display using these vector commands, rather than saving
them in an image, and I tell you, it's slow.
I'd like having the possiblity for zooming by just scaling the
coordinates, but what on earth should I do? NSBezierPath is way too
slow here.
Would OpenGL render smoothly when printing ?
Love,
Jens
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.