5.3. Blend functions

Blend functions are used to blend layers together given a certain formula.

An excellent read: http://dunnbypaul.net/blends

5.3.1. Normal

fontblend.blendnormal(base, blend)[source]

R = blend

Parameters:
  • base – The base image
  • blend – The blend image

5.3.2. Darken

fontblend.blenddarken(base, blend)[source]

R = min( base, blend )

Parameters:
  • base – The base image
  • blend – The blend image

5.3.3. Multiply

fontblend.blendmultiply(base, blend)[source]

R = base * blend

Parameters:
  • base – The base image
  • blend – The blend image

5.3.4. Color Burn

fontblend.blendcolorburn(base, blend)[source]

R = 1 - (1 - base) / blend

Parameters:
  • base – The base image
  • blend – The blend image

5.3.5. Linear Burn

fontblend.blendlinearburn(base, blend)[source]

R = base + blend - 1

Parameters:
  • base – The base image
  • blend – The blend image

5.3.6. Lighten

fontblend.blendlighten(base, blend)[source]

R = max( base, blend )

Parameters:
  • base – The base image
  • blend – The blend image

5.3.7. Screen

fontblend.blendscreen(base, blend)[source]

R = 1 - (1 - base) * (1 - blend)

Parameters:
  • base – The base image
  • blend – The blend image

5.3.8. Color Dodge

fontblend.blendcolordodge(base, blend)[source]

R = base / (1 - blend)

Parameters:
  • base – The base image
  • blend – The blend image

5.3.9. Linear Dodge

fontblend.blendlineardodge(base, blend)[source]

R = base + blend

Parameters:
  • base – The base image
  • blend – The blend image