[poppler] 2 commits - poppler/Catalog.cc splash/SplashMath.h
Albert Astals Cid
aacid at kemper.freedesktop.org
Wed Nov 18 13:27:34 PST 2009
poppler/Catalog.cc | 1 -
splash/SplashMath.h | 19 +++++++++++++++++--
2 files changed, 17 insertions(+), 3 deletions(-)
New commits:
commit 55261a2dc86241c8d132e590e76e7398b3ca5090
Author: Albert Astals Cid <aacid at kde.org>
Date: Wed Nov 18 22:26:01 2009 +0100
replace floor with a cast to int for numbers > 0
bug-poppler13487.pdf gets a 15% faster rendering
diff --git a/splash/SplashMath.h b/splash/SplashMath.h
index 7a8c8e3..cb6dee9 100644
--- a/splash/SplashMath.h
+++ b/splash/SplashMath.h
@@ -4,6 +4,20 @@
//
//========================================================================
+//========================================================================
+//
+// Modified under the Poppler project - http://poppler.freedesktop.org
+//
+// All changes made under the Poppler project to this file are licensed
+// under GPL version 2 or later
+//
+// Copyright (C) 2009 Albert Astals Cid <aacid at kde.org>
+//
+// To see a description of the changes please see the Changelog file that
+// came with your tarball or type make ChangeLog if you are building from git
+//
+//========================================================================
+
#ifndef SPLASHMATH_H
#define SPLASHMATH_H
@@ -26,7 +40,8 @@ static inline int splashFloor(SplashCoord x) {
#if USE_FIXEDPOINT
return FixedPoint::floor(x);
#else
- return (int)floor(x);
+ if (x > 0) return (int)x;
+ else return (int)floor(x);
#endif
}
@@ -42,7 +57,7 @@ static inline int splashRound(SplashCoord x) {
#if USE_FIXEDPOINT
return FixedPoint::round(x);
#else
- return (int)floor(x + 0.5);
+ return (int)splashFloor(x + 0.5);
#endif
}
commit 28df9fb323f14dc632c9502655abf69984b7d67e
Author: Albert Astals Cid <aacid at kde.org>
Date: Wed Nov 18 21:57:02 2009 +0100
Remove unused label
diff --git a/poppler/Catalog.cc b/poppler/Catalog.cc
index 37a1062..b659180 100644
--- a/poppler/Catalog.cc
+++ b/poppler/Catalog.cc
@@ -352,7 +352,6 @@ int Catalog::readPageTree(Dict *pagesDict, PageAttrs *attrs, int start,
err2:
kid.free();
kidRef.free();
- err1:
kids.free();
delete attrs1;
ok = gFalse;
More information about the poppler
mailing list