summaryrefslogtreecommitdiffstats
path: root/src/display/nr-gradient-gpl.cpp
diff options
context:
space:
mode:
authorAndrius Ramanauskas <knutux@gmail.com>2006-04-19 05:14:26 +0000
committerknutux <knutux@users.sourceforge.net>2006-04-19 05:14:26 +0000
commitcd3043cf07c274cd641b8483b55177e9a5cb1e10 (patch)
treef860995235a5dc981868ab4f3482e861322ffe01 /src/display/nr-gradient-gpl.cpp
parentfix name and size (diff)
downloadinkscape-cd3043cf07c274cd641b8483b55177e9a5cb1e10.tar.gz
inkscape-cd3043cf07c274cd641b8483b55177e9a5cb1e10.zip
Rendering optimisation, which gives best results for zoomed in drawings with complex (multi-node) paths. Optimisation focus - eliminating cubicTo and LineTo nodes outside of visible area, so no unneeded calculations is needed and less memory is consumed (this avoids crashes which were occurring previously if zooming into a complex drawing)
(bzr r541)
Diffstat (limited to 'src/display/nr-gradient-gpl.cpp')
-rw-r--r--src/display/nr-gradient-gpl.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/display/nr-gradient-gpl.cpp b/src/display/nr-gradient-gpl.cpp
index 54a33cfdb..536217649 100644
--- a/src/display/nr-gradient-gpl.cpp
+++ b/src/display/nr-gradient-gpl.cpp
@@ -271,6 +271,7 @@ nr_lgradient_render_generic (NRLGradientRenderer *lgr, NRPixBlock *pb)
(unsigned char *) lgr->vector,
4 * NR_GRADIENT_VECTOR_LENGTH,
0, 0);
+ spb.visible_area = pb->visible_area;
bpp = (pb->mode == NR_PIXBLOCK_MODE_A8) ? 1 : (pb->mode == NR_PIXBLOCK_MODE_R8G8B8) ? 3 : 4;
for (y = 0; y < height; y++) {