From fe33ebe83c4b8b71328ed2a7c2c5efe3efe57e16 Mon Sep 17 00:00:00 2001 From: Antonin Descampe Date: Thu, 8 Dec 2005 11:01:59 +0000 Subject: [PATCH] fixed a bug in t1_getwmsedec (stepsize was divided by 8192) --- ChangeLog | 5 ++++- libopenjpeg/t1.c | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index ea48d5da..b067d470 100644 --- a/ChangeLog +++ b/ChangeLog @@ -5,4 +5,7 @@ What's New for OpenJPEG ! : changed + : added -December 5, 2005 - 1.0.0 +December 8, 2005 - 1.1.1 +* [Antonin Descampe] fixed a bug in t1_getwmsedec (stepsize was divided by 8192) + +December 5, 2005 - 1.1.0 diff --git a/libopenjpeg/t1.c b/libopenjpeg/t1.c index 6a7810aa..feb1f734 100644 --- a/libopenjpeg/t1.c +++ b/libopenjpeg/t1.c @@ -511,7 +511,7 @@ static double t1_getwmsedec(int nmsedec, int compno, int level, int orient, int w1 = (numcomps > 1) ? mct_getnorm_real(compno) : 1; w2 = dwt_getnorm_real(level, orient); } - wmsedec = w1 * w2 * (stepsize / 8192.0) * (1 << bpno); + wmsedec = w1 * w2 * stepsize * (1 << bpno); wmsedec *= wmsedec * nmsedec / 8192.0; return wmsedec;