Re: Sub-pixel font smoothing with CGBitmapContext

2009-01-29 Thread Timothy Wood
On Jan 28, 2009, at 5:15 PM, Slava Pestov wrote: Hi all, When I render text into a CGBitmapContext that has been filled with a solid color, sub-pixel font smoothing is not applied and text looks suboptimal compared to text rendered elsewhere. How can I enable font smoothing? Calling

Re: Sub-pixel font smoothing with CGBitmapContext

2009-01-29 Thread David Duncan
On Jan 28, 2009, at 5:15 PM, Slava Pestov wrote: When I render text into a CGBitmapContext that has been filled with a solid color, sub-pixel font smoothing is not applied and text looks suboptimal compared to text rendered elsewhere. How can I enable font smoothing? Calling

Re: Sub-pixel font smoothing with CGBitmapContext

2009-01-29 Thread Timothy Wood
On Jan 29, 2009, at 10:56 AM, David Duncan wrote: Its been a while since I last looked at this, but I think the context's format needs to be native endian (add the kCGBitmapByteOrder32Host flag). Heh; I totally would not have expected that from the name or docs. But, adding a case

Re: Sub-pixel font smoothing with CGBitmapContext

2009-01-29 Thread David Duncan
On Jan 29, 2009, at 12:34 PM, Timothy Wood wrote: On Jan 29, 2009, at 10:56 AM, David Duncan wrote: Its been a while since I last looked at this, but I think the context's format needs to be native endian (add the kCGBitmapByteOrder32Host flag). Heh; I totally would not have expected

Re: Sub-pixel font smoothing with CGBitmapContext

2009-01-29 Thread Timothy Wood
On Jan 29, 2009, at 12:41 PM, David Duncan wrote: Yea, its not documented, and its probably more of a quirk of the font rendering than anything else. It works today, and primarily I offer the solution because if it stops working in the future, the worst that will happen is you will get

Sub-pixel font smoothing with CGBitmapContext

2009-01-28 Thread Slava Pestov
Hi all, When I render text into a CGBitmapContext that has been filled with a solid color, sub-pixel font smoothing is not applied and text looks suboptimal compared to text rendered elsewhere. How can I enable font smoothing? Calling CGContextSetShouldSmoothFonts doesn't seem to help. Slava