Parcourir la source

Fin de la première phase de debuggage

Rémi Synave il y a 2 ans
Parent
commit
b21930cd25
2 fichiers modifiés avec 7 ajouts et 8 suppressions
  1. 0 2
      HDRip/ImageHDR.cpp
  2. 7 6
      HDRip/all_processings.cpp

+ 0 - 2
HDRip/ImageHDR.cpp

@@ -358,8 +358,6 @@ void ImageHDR::ycurve_histogram_regularization(float* colorDataY, float* colorDa
 void ImageHDR::yCurve(float s, float b, float m, float w, float h)
 {
   
-  display_debug();
-  
   if (linear)
   {
     linear_to_non_linear();

+ 7 - 6
HDRip/all_processings.cpp

@@ -61,8 +61,6 @@ float* contrast(float* data, unsigned int width, unsigned int height, float cons
   
   float* ret = new float[width * height * 3];
   memcpy(ret, img.data, width * height * 3 * sizeof(float));
-
-  img.display_debug();
   
   return ret;
 }
@@ -74,16 +72,13 @@ float* yCurve(float* data, unsigned int width, unsigned int height, float yCs, f
   ImageHDR img(data, width, height);
 
   img.yCurve(yCs, yCb, yCm, yCw, yCh);
-
+  
   img.non_linear_to_linear();
-
   img.linear=true;
 
   float* ret = new float[width * height * 3];
   memcpy(ret, img.data, width * height * 3 * sizeof(float));
 
-  //img.display_debug();
-
   return ret;
 }
 
@@ -96,6 +91,7 @@ float* lightnessMask(float* data, unsigned int width, unsigned int height, bool
   img.lightnessMask(lms, lmb, lmm, lmw, lmh);
 
   img.non_linear_to_linear();
+  img.linear=true;
 
   float* ret = new float[width * height * 3];
   memcpy(ret, img.data, width * height * 3 * sizeof(float));
@@ -115,6 +111,11 @@ float* saturation(float* data, unsigned int width, unsigned int height, float sa
   free(img.data);
   img.data = dataRGB;
 
+  img.non_linear_to_linear();
+  img.linear=true;
+
+  //img.display_debug();
+
   float* ret = new float[width * height * 3];
   memcpy(ret, img.data, width * height * 3 * sizeof(float));