Search code examples
cudaparallel-processinggpufractalsimage-compression

Compressing any image format using Fractal compression


I am a novice in Image compression or for that matter image processing. I am trying to learn fractal image compression from a famous book by Yuval Fsiher. At the end of the book he has given the entire compression-decompression code in C. I mostly work in CUDA. The present C code by Fisher only deals with raw images.

  1. My main focus is to understand the compression process and then modify the above code such that it also works with BMP (color & grayscale) images
  2. Subsequently, I want to speed-up the code by converting selected functions into CUDA kernels.I am planning to focus on the range-domain comparisons that is highly compute-intensive.

So I have the following issues:

Is it necessary to study BMP image format before proceeding to compress it or I can treat it just as a matrix and compress it using Fractal Image Compression. The fractal compression works on the concept of finding similarities in range-domain maps using IFS (Iterated Function System) which is basically a collection of Affine transformations.


Solution

  • Fractal Compression is completely independent of source file storage format. Once you've loaded the BMP into an image or buffer it will be raw pixels (same as if you read a PNG or JPEG). If your BMP is uncompressed it is very easy to read; it's raw pixels once you're past the header. But a flexible reader also supports different pixel depths and compression, so it's best to find a library that does this for you unless you only need to work with your own test images.