Re: Text rendered in NSImage is fuzzy

2011-08-26 Thread Rimas M.
On Fri, Aug 26, 2011 at 5:21 PM, Kyle Sluder wrote: > On Aug 26, 2011, at 7:13 AM, "Rimas M." wrote: > > > If I am using Core Text (CTLineDraw(line, bitmapDrawContext);) to draw my > > text into bitmap context, there is no way to get sub-pixels antialiasing > if > > resulting image has transpare

Re: Text rendered in NSImage is fuzzy

2011-08-26 Thread Kyle Sluder
On Aug 26, 2011, at 7:13 AM, "Rimas M." wrote: > If I am using Core Text (CTLineDraw(line, bitmapDrawContext);) to draw my > text into bitmap context, there is no way to get sub-pixels antialiasing if > resulting image has transparent background? Correct. Subpixel antialiasing algorithms require

Re: Text rendered in NSImage is fuzzy

2011-08-26 Thread Rimas M.
Sorry for touching this old thread. I just want to be sure. If I am using Core Text (CTLineDraw(line, bitmapDrawContext);) to draw my text into bitmap context, there is no way to get sub-pixels antialiasing if resulting image has transparent background? Currently it looks: http://db.tt/Rtiu7B1 Re

Re: Text rendered in NSImage is fuzzy

2010-06-27 Thread Dave Fernandes
Looks like (1) was the problem. Filling with white before drawing the text worked. Thanks! On 2010-06-27, at 4:47 PM, Ken Ferry wrote: > I don't think this is likely to be the problem in this case. Text looks good > no matter where you draw it. > > In this case, I think the problem is more li

Re: Text rendered in NSImage is fuzzy

2010-06-27 Thread David Duncan
On Jun 27, 2010, at 2:18 PM, Kyle Sluder wrote: > Be aware that this means CATextLayer will suffer the same problem. It even > does if you specify a background color for the layer. If you're using Core > Animation and want subpixel antialiasing, you have to do it yourself. Due to the way that

Re: Text rendered in NSImage is fuzzy

2010-06-27 Thread Kyle Sluder
On Jun 27, 2010, at 2:18 PM, Kyle Sluder wrote: > > It's only a latent bug if Apple ever gets serious about resolution > independence on the Mac. And Apple has shown no interest in ultra-high DPI at > all. They certainly didn't make it a tentpole feature of a new product or > anything like th

Re: Text rendered in NSImage is fuzzy

2010-06-27 Thread Kyle Sluder
On Jun 27, 2010, at 1:47 PM, Ken Ferry wrote: > I would guess (1) is more likely. Dave, if you were to read that wikipedia > article and think about it carefully, you would realize that doing full > featured transparency with font smoothing would require six channels (red, > red alpha, green, gre

Re: Text rendered in NSImage is fuzzy

2010-06-27 Thread Ken Ferry
I don't think this is likely to be the problem in this case. Text looks good no matter where you draw it. In this case, I think the problem is more likely either (1) A lack of what Quartz calls font smoothing, more popularly known as subpixel rendering

Re: Text rendered in NSImage is fuzzy

2010-06-27 Thread Uli Kusterer
On 27.06.2010, at 22:12, Dave Fernandes wrote: > I'm trying to render text in System font in an NSImage as shown below. The > NSImage is displayed *unscaled* in an NSImageView. However, the text does not > look as good as when rendered in an NSView. Is there any way to get crisp > clean text in

Text rendered in NSImage is fuzzy

2010-06-27 Thread Dave Fernandes
I'm trying to render text in System font in an NSImage as shown below. The NSImage is displayed *unscaled* in an NSImageView. However, the text does not look as good as when rendered in an NSView. Is there any way to get crisp clean text in an NSImage? Thanks, Dave // Render an image into a