
I need to implement an external glow on a UILabel (or CATextLayer) as above. I know, to create a glow effect on the text, I need a shadow with an offset (0,0). I got to the quartz2D level, the following code I use:
_backgroundDownLabel.layer.shadowColor = self.glowColor.CGColor;
_backgroundDownLabel.layer.shadowOffset = CGSizeMake(0, 0);
_backgroundDownLabel.layer.shadowOpacity = 1;
_backgroundDownLabel.layer.shadowRadius = self.glowAmount;
_backgroundDownLabel.layer.masksToBounds = NO;
Problem: when I use the RGB color (1,0,0) as the shadow color to create a red glow, the result is too thin, which means that the red glow is not strong enough. On the other hand, the designer client sent me a PSD file in which a bright and strong glow color. I think this is not just a glow, but a Photoshop filter, perhaps an external glow or some combination.
So, is there a code way that I can do something like this?
source
share