pmldude/Portable-Middle-Link-

PML (Portable Middle Link) is a lossy raster image compression format created as a compromise between the perfectly accurate PNG and traditional JPEG.

0

3 commits

updated Sep 20, 2026

See the code

See what people are saying (1)

SourceMessageScoreDate

Made my own image format. (r/programming)

Yes, it may sound strange: it makes no sense! BUT, my goal was more of a joke, although it may well be suitable as an alternative to other formats in extreme cases. This format contains only 100\~ lines of code, but it is quite efficient in itself (compared to PNG lol, although I think everything…

0

Sep 20, 2026

README

Portable-Middle-Link-

PML (Portable Middle Link) is a lossy raster image compression format created as a compromise between the perfectly accurate PNG and traditional JPEG.

The compression pipeline consists of five steps: YCbCr Color Space: Separating the signal into luma (Y) and chroma (Cb, Cr) components. Chroma Subsampling (4:2:0): Reducing the resolution of the chroma channels by a factor of 2. Linear Quantization: Truncating noise with step=4 for Y and step=8 for Cb/Cr. Sub-filtering: Calculating horizontal differences between adjacent pixels to transform the raster into an array of zeros. DEFLATE Compression: Independent channel packaging via the zlib algorithm with a 20-byte header.

Contributors

pmldude

3 commits

pmldude/Portable-Middle-Link-

PML (Portable Middle Link) is a lossy raster image compression format created as a compromise between the perfectly accurate PNG and traditional JPEG.

0

3 commits

updated Sep 20, 2026

See the code

See what people are saying (1)

SourceMessageScoreDate

Made my own image format. (r/programming)

Yes, it may sound strange: it makes no sense! BUT, my goal was more of a joke, although it may well be suitable as an alternative to other formats in extreme cases. This format contains only 100\~ lines of code, but it is quite efficient in itself (compared to PNG lol, although I think everything…

0

Sep 20, 2026

README

Portable-Middle-Link-

PML (Portable Middle Link) is a lossy raster image compression format created as a compromise between the perfectly accurate PNG and traditional JPEG.

The compression pipeline consists of five steps: YCbCr Color Space: Separating the signal into luma (Y) and chroma (Cb, Cr) components. Chroma Subsampling (4:2:0): Reducing the resolution of the chroma channels by a factor of 2. Linear Quantization: Truncating noise with step=4 for Y and step=8 for Cb/Cr. Sub-filtering: Calculating horizontal differences between adjacent pixels to transform the raster into an array of zeros. DEFLATE Compression: Independent channel packaging via the zlib algorithm with a 20-byte header.

Contributors

pmldude

3 commits