Re: [css3-background] vastly different takes on "blur"

On Jun 11, 2010, at 3:44 PM, Simon Fraser <smfr@me.com> wrote:

> On Jun 11, 2010, at 3:18 PM, fantasai wrote:
>
>> On 06/11/2010 02:03 PM, Brad Kemper wrote:
>>> On Jun 11, 2010, at 11:13 AM, Simon Fraser <smfr@me.com> wrote:
>>>
>>>> I don't think the current definition, which describes the blur in
>>>> terms of a gradient, is good for shapes with concave portions.
>>>
>>> I don't know why not. It doesn't say it's a gradient, it just  
>>> defines
>>> the size of the region to blur within. I think that saying that a  
>>> 15px
>>> blur covers a perimeter that is 15px wide will be a whole lot more
>>> understandable and predictable and meaningful for authors than to  
>>> ask
>>> them to guess how much that will be based on the results of plugging
>>> that length into a guassian function.
>>
>> What Simon is trying to say is that it's not a straight-up transition
>> of 15px.
>>
>> If I'm understanding this correctly (I'm shooting in the dark here),
>> the Gaussian function, when applied to concave shapes like the inside
>> of a corner, will result in an effective "radius" that is much larger
>> at certain points. This is in fact what you want: otherwise the  
>> corner
>> doesn't look blurred, it looks gradient-ed.
>>
>> Imagine a sharp concave corner (i.e. the border with an inner  
>> shadow).
>> If you put a true Gaussian blur on that, the edge where the shadow
>> finally disappears will have a slight curve.
>>
>>    +--------------     [ I lack hixie's awesome ascii art skillz,
>>    |                     but I'm trying here... ]
>>    |         _____
>>    |      ,'
>>    |     :
>>    |     |
>>    |     |
>>
>> In the current definition, you'll get a sharp edge.
>>
>>    +--------------
>>    |
>>    |      ________
>>    |     |
>>    |     |
>>    |     |
>>    |     |
>>
>> If I'm understanding this correctly, applying a true Gaussian and
>> then thresholding it will probably fix those weird kinks you were
>> seeing on inner shadow spreads with the current definition.
>
> Yes, this is exactly the issue.
>
> Simon

OK, then we still need to tweak the language a bit. I see it does say  
"gradient"; I didn't remember that.

Can we say that the amount of blur should be just the amount needed  
such that if it were to occur along a long flat side, it would blend  
smoothly from a the full shadow color on the inside of the shadow to  
transparent on the outside, and that the resulting blurring of the  
corners may mean that the blur region is no longer centered on where  
the original corners would have been? Or something like that.

Received on Friday, 11 June 2010 23:08:28 UTC