{# canonical_base is the OWNING tenant's origin: all 16 Peasy domains serve the same catalogue, so a page rendered by a non-owner points its canonical at the owner instead of competing with it. Falls back to this site for static/self-owned pages. #}
🍋
Menu
Image

Alpha Channel

Alpha Channel (Transparency Mask)

An alpha channel stores transparency information for each pixel in an image, with values ranging from fully transparent to fully opaque. It is the fourth channel in RGBA color, enabling smooth blending of images over backgrounds.

Teknik Detay

Alpha values are typically stored as 8-bit (0-255) or floating point (0.0-1.0) per pixel. Pre-multiplied alpha multiplies color values by opacity for faster compositing, while straight alpha stores them independently.

Ornek

```javascript
// Convert RGB to HSL
function rgbToHsl(r, g, b) {
  r /= 255; g /= 255; b /= 255;
  const max = Math.max(r, g, b), min = Math.min(r, g, b);
  const l = (max + min) / 2;
  let h = 0, s = 0;
  if (max !== min) {
    const d = max - min;
    s = l > 0.5 ? d/(2-max-min) : d/(max+min);
  }
  return [h, s, l];
}
```

Ilgili Araclar

Ilgili Terimler