Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(86)

Unified Diff: third_party/qcms/src/transform_util.c

Issue 2796893002: [qcms] Fix overflow when reading parametric gamma curves (Closed)
Patch Set: Sync up, fix QCMS tab vs. spaces per usual. Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/qcms/README.chromium ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/qcms/src/transform_util.c
diff --git a/third_party/qcms/src/transform_util.c b/third_party/qcms/src/transform_util.c
index c27a152d8abc6de4371a93db969abd174268cc43..7db8c7533f474e5efc716a4092858d06c4c00d6d 100644
--- a/third_party/qcms/src/transform_util.c
+++ b/third_party/qcms/src/transform_util.c
@@ -196,7 +196,7 @@ void compute_curve_gamma_table_type_parametric(float gamma_table[256], float par
// XXX The equations are not exactly as definied in the spec but are
// algebraic equivilent.
// TODO Should division by 255 be for the whole expression.
- gamma_table[X] = clamp_float(pow(a * x + b, y) + c + e);
+ gamma_table[X] = clamp_float(powf(a * x + b, y) + (c + e));
} else {
gamma_table[X] = clamp_float(c * x + f);
}
« no previous file with comments | « third_party/qcms/README.chromium ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698