Fred, your latest changes broke win32 compilation:
display/nr-arena-item.cpp: In function `unsigned int nr_arena_item_invoke_render(NRArenaItem*, NRRectL*, NRPixBlock*, unsigned int)': display/nr-arena-item.cpp:383: error: `gettimeofday' undeclared (first use this function) display/nr-arena-item.cpp:383: error: (Each undeclared identifier is reported only once for each function it appears in.)
I noticed you added a new option, arenatilescachesize. Can you elaborate on what effect it has, and what are the recommended values? If it's supposed to be user-editable, please add it to
http://inkscape.org/cgi-bin/wiki.pl?PreferencesDialog
with a label, acceptable range of values, and a tooltip which explains what this option does and how. When we finally create a preferences dialog that page will be used as the base.
Also, there are quite a bunch of new bugs in the tracker that you may be interested in (dashed strokes, offsets, miters, etc.)
_________________________________________________________________ MSN Premium helps eliminate e-mail viruses. Get 2 months FREE* http://join.msn.com/?pgmarket=en-ca&page=byoa/prem&xAPID=1994&DI...
display/nr-arena-item.cpp:383: error: `gettimeofday' undeclared (first use this function)
damn... i checked on a mandrake and it compiled fine; what system are you using? gettimeofday is standard or am i missing something?
I noticed you added a new option, arenatilescachesize. Can you elaborate on what effect it has, and what are the recommended values? If it's supposed to be user-editable, please add it to
it's a dumb caching of the graphics elements on the canvas (nr-arena stuff). it's not really meant to be user-editable, and currently only #define'd; if you want to limit its use, rather change the options.arenatilescachesize preference: it's the number of tiles the code is allowed to cache (64Ko for each tile).
to understand the caching, a note on the renderer: the "dirty" area that needs redrawing is accumulated in sp-canvas, and flushed when possible (usually throught the idle_handler). that area is tiled in rects such that the pixel block for that rect doesn't exceed 64Ko, the size of the block in the pixblock pool. tiles are then sent for drawing down the SPCanvasItem hierarchy, and next to the nr-arena hierarchy. canvas-arena also reworks the tile's dimension, because it allocates another pixblock. so the caching occurs when an object is asked to redraw itself in nr_arena_invoke_render(). first it looks in the item->px cache (all objects smaller than 64*64 pixel are cached; that's not my caching, btw), then in the tile cache to see if the current request is not in it, and if not rasters it. if the bounding box of the item has sufficient intersection with the tile (1/4 of the surface), the code tries to cache the item. the cache is a dumb hash table, where the policy is to keep the tiles whose rendering is the most time-expensive (hence gettimeofday).
to provide the cache algo more tiles aligned to the 128*128 grid, the sp-canvas mechanism for accumulating redraw area was changed in a 32*32 tiling. it then tries to align on 128*128 boundaries when starting redraws. that's controlled by the #define canvas_tiled_redraw
anyway, it gave an little speed boost on my PPC box, i haven't checked on anything else.
Yahoo! Mail : votre e-mail personnel et gratuit qui vous suit partout ! Créez votre Yahoo! Mail sur http://fr.benefits.yahoo.com/
Dialoguez en direct avec vos amis grâce à Yahoo! Messenger !Téléchargez Yahoo! Messenger sur http://fr.messenger.yahoo.com
fred wrote:
display/nr-arena-item.cpp:383: error: `gettimeofday' undeclared (first use this function)
damn... i checked on a mandrake and it compiled fine; what system are you using? gettimeofday is standard or am i missing something?
Fred,
Glib has a portable time function. Here is an example from libnr/testnr.cpp:
static double get_time (void) { GTimeVal tv; g_get_current_time (&tv); return tv.tv_sec + 1e-6 * tv.tv_usec; }
Bob
On Sat, 2004-04-10 at 10:52, Bob Jamison wrote:
Glib has a portable time function. Here is an example from libnr/testnr.cpp:
static double get_time (void) { GTimeVal tv; g_get_current_time (&tv); return tv.tv_sec + 1e-6 * tv.tv_usec; }
For computing elapsed times, GTimer is much preferable.
-mental
participants (4)
-
Bob Jamison
-
bulia byak
-
fred
-
MenTaLguY