CVSROOT: /cvsroot/gnash Module name: gnash Changes by: Udo Giacomozzi <udog> 07/02/22 10:43:04
Modified files: . : ChangeLog backend : render_handler_agg.cpp Log message: Avoid re-initialisation of AGG path class inside for-loop CVSWeb URLs: http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.2430&r2=1.2431 http://cvs.savannah.gnu.org/viewcvs/gnash/backend/render_handler_agg.cpp?cvsroot=gnash&r1=1.59&r2=1.60 Patches: Index: ChangeLog =================================================================== RCS file: /cvsroot/gnash/gnash/ChangeLog,v retrieving revision 1.2430 retrieving revision 1.2431 diff -u -b -r1.2430 -r1.2431 --- ChangeLog 22 Feb 2007 10:21:02 -0000 1.2430 +++ ChangeLog 22 Feb 2007 10:43:04 -0000 1.2431 @@ -3,6 +3,8 @@ * backend/render_handler_agg.cpp, backend/render_handler_agg_style.h: Switched to pre-multiplied pixel values. Fixes some anti-aliasing issues and improves rendering performance, especially for gradients. + * backend/render_handler_agg.cpp: Avoid re-initialisation of AGG path class + inside for-loop. 2007-02-21 Sandro Santilli <[EMAIL PROTECTED]> Index: backend/render_handler_agg.cpp =================================================================== RCS file: /cvsroot/gnash/gnash/backend/render_handler_agg.cpp,v retrieving revision 1.59 retrieving revision 1.60 diff -u -b -r1.59 -r1.60 --- backend/render_handler_agg.cpp 22 Feb 2007 10:36:37 -0000 1.59 +++ backend/render_handler_agg.cpp 22 Feb 2007 10:43:04 -0000 1.60 @@ -16,7 +16,7 @@ -/* $Id: render_handler_agg.cpp,v 1.59 2007/02/22 10:36:37 udog Exp $ */ +/* $Id: render_handler_agg.cpp,v 1.60 2007/02/22 10:43:04 udog Exp $ */ // Original version by Udo Giacomozzi and Hannes Mayr, // INDUNET GmbH (www.indunet.it) @@ -1034,12 +1034,13 @@ // push paths to AGG pcount = paths.size(); int current_subshape = 0; + agg::path_storage path; + agg::conv_curve< agg::path_storage > curve(path); for (pno=0; pno<pcount; pno++) { - const path &this_path = paths[pno]; - agg::path_storage path; - agg::conv_curve< agg::path_storage > curve(path); + const gnash::path &this_path = paths[pno]; + path.remove_all(); if (this_path.m_new_shape) current_subshape++; @@ -1165,12 +1166,14 @@ // push paths to AGG unsigned int pcount = paths.size(); - for (unsigned int pno=0; pno < pcount; pno++) { - - const path& this_path = paths[pno]; agg::path_storage path; agg::conv_curve< agg::path_storage > curve(path); + for (unsigned int pno=0; pno < pcount; pno++) { + + const gnash::path& this_path = paths[pno]; + path.remove_all(); + // reduce everything to just one fill style! rasc.styles(this_path.m_fill0==0 ? -1 : 0, this_path.m_fill1==0 ? -1 : 0); _______________________________________________ Gnash-commit mailing list Gnash-commit@gnu.org http://lists.gnu.org/mailman/listinfo/gnash-commit