Skip to content
Snippets Groups Projects
Commit 39ed5e7b authored by Antoine Lorence's avatar Antoine Lorence
Browse files

[MICD] Apply quantification on generated error image

parent b2724043
No related branches found
No related tags found
No related merge requests found
......@@ -128,14 +128,15 @@ string MICD::execute( const GrayscaleImage *im, Prediction prediction_alg, image
}
depth_default_t thePixel = reconstructed_image->getPixelAt(j, i);
ier = (int) thePixel - pred;
ier = thePixel - pred;
ier = quantdef->valueOf(ier);
codec(0,ier,&icode,&ireco);
codec(0, ier, &icode, &ireco);
pi[ier+255]++; /* proba associe a l'erreur de prdiction */
nbpt++;
error_prediction_image->setPixelAt(j, i, ier + 128);
error_prediction_image->setPixelAt(j, i, ier);
int tempvalue = pred + ireco;
// Crop the value in [0,255]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment