Commit cf9867fb authored by Albert Astals Cid's avatar Albert Astals Cid

Various fixes from Frank Meerkötter to enable fixedpoint arithmetic

parent f04e2c4f
2006-02-06 Albert Astals Cid <aacid@kde.org>
* configure.ac:
* goo/FixedPoint.h:
* splash/Splash.cc:
* splash/SplashTypes.h: Various fixes from Frank Meerkötter to enable
fixedpoint arithmetic
2006-02-06 Albert Astals Cid <aacid@kde.org>
* poppler/Annot.cc: Fix small leaks
......
......@@ -31,7 +31,7 @@ AM_CONDITIONAL(ENABLE_XPDF_HEADERS, test x$enable_xpdf_headers = xyes)
AC_ARG_ENABLE(fixedpoint,
[ --enable-fixedpoint use fixed point (instead of floating point) arithmetic],
AC_DEFINE(USE_FIXEDPOINT, [], [Use fixed point arithmetic]))
AC_DEFINE(USE_FIXEDPOINT, [1], [Use fixed point arithmetic]))
dnl ##### Path to xpdfrc.
dnl This ugly kludge to get the sysconfdir path is needed because
......
......@@ -11,7 +11,7 @@
#ifndef FIXEDPOINT_H
#define FIXEDPOINT_H
#include <aconf.h>
#include <config.h>
#if USE_FIXEDPOINT
......
......@@ -2020,10 +2020,10 @@ SplashError Splash::fillGlyph(SplashCoord x, SplashCoord y,
for (xx = 0, x1 = x0 - glyph->x; xx < glyph->w; ++xx, ++x1) {
alpha = *p++;
if (softMask) {
alpha = (int)(alpha * state->fillAlpha *
alpha = (int)(alpha * (float)state->fillAlpha *
softMask->data[y1 * softMask->rowSize + x1]);
} else {
alpha = (int)(alpha * state->fillAlpha);
alpha = (int)(alpha * (float)state->fillAlpha);
}
if (alpha > 0) {
if (noClip || state->clip->test(x1, y1)) {
......
......@@ -14,7 +14,7 @@
//------------------------------------------------------------------------
#if USE_FIXEDPOINT
#include "FixedPoint.h"
#include "goo/FixedPoint.h"
typedef FixedPoint SplashCoord;
#else
typedef double SplashCoord;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment