public double ComputeCompressionRatio()
{
if (CurrentChunkGroup < ChunksList.CHUNK_GROUP_6_END)
throw new PngjException("must be called after End()");
double compressed = (double)datStream.GetCountFlushed();
double raw = (ImgInfo.BytesPerRow + 1) * ImgInfo.Rows;
return compressed / raw;
}