WIP QOI image format implemented in python. This is a python practice project for myself to learn qoi format and try to write an python library.
- qoi image format
- qoir format, an fast, simple, lossless image format inspired by qoi format.
- python bitwise operation tutorial.
- introduction video of png by Reduciable which explain the working mechanism of qoi format.
# make sure you have the dependencies installed
$python3 test_qoi.py
$tree --du -h ./output/
[ 13M] .
├── [374K] test.jpg
├── [5.9M] test.npy
├── [3.5M] test.png
└── [3.5M] test.qoi
13M used in 1 directory, 4 files
Test image from @video
conda install numpy matplotlib
todo:
- find a way to implement sign bit in python
- check
pack_qoi_op_diff
andpack_qoi_op_luma
function - check qoi end marker when reaching the last pixel
- support rgba images
- add error checking when pixel value overflows
- make it python library
- move
qoi_decode
andqoi_encode
into qoi.py