Separated rle code from coder.