Stopped working on subsampling since this is an encoding problem rather than decoding