Re: NSBezierPath to NSImage with subpixel rendering
Re: NSBezierPath to NSImage with subpixel rendering
- Subject: Re: NSBezierPath to NSImage with subpixel rendering
- From: Jean-Daniel Dupas <email@hidden>
- Date: Wed, 9 Jan 2008 13:49:19 +0100
Le 9 janv. 08 à 13:01, Jonathon Mah a écrit :
Hi Gregory,
On 2008-01-09, at 22:10, Gregory 'guardian' Pakosz wrote:
so, what's the proper way to achieve offscreen antialising +
subpixel precision in an NSImage that has a background
Is antialiasing turned on in your graphics context?
[[NSGraphicsContext currentContext] setShouldAntialias:YES]
<http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/Classes/NSGraphicsContext_Class/Reference/Reference.html#//apple_ref/occ/instm/NSGraphicsContext/setShouldAntialias:
>
http://michelf.com/weblog/2006/subpixel-antialiasing-achilles-heel/
This only seems to relate to LCD antialiasing of text, which is not
what you're wanting.
To get a good image scaling quality, you have to change your graphic
context settings.
[image lockFocus];
[[NSGraphicsContext currentContext]
setImageInterpolation:NSImageInterpolationHigh];
....
_______________________________________________
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