Tone Mapping
HDR Tone Mapping
Converting high dynamic range image data to a displayable range while preserving visual detail and contrast.
Техническая деталь
Tone Mapping achieves size reduction through reversible algorithms — typically DEFLATE (used in PNG), LZ77, or arithmetic coding. These algorithms identify and encode repeated patterns without discarding any information. Typical compression ratios range from 2:1 to 10:1 depending on image content; images with large uniform areas compress better than detailed photographs. Lossless formats are essential for medical imaging, scientific data, and any workflow where pixel-perfect fidelity is required.
Пример
```javascript
// Tone Mapping: processing with Canvas API
const canvas = document.createElement('canvas');
const ctx = canvas.getContext('2d');
ctx.drawImage(sourceImage, 0, 0);
const imageData = ctx.getImageData(0, 0, canvas.width, canvas.height);
// Process pixels in imageData.data (RGBA array)
```