Today Peter Speck wrote: > Hi Tobi et.al., > > Here's the patch for evenly-spaced y-axis gridlines. > > I had to split horizontal_grid() into calc_horizontal_grid and > draw_horizontal_grid as the calculated info is needed in the adjustment > code. My previous patch had the problem that it adjusted the y-axis too > late, e.g. after the data lines was drawn. > The result of the calc is stored in struct ygrid_scale_t which > image_desc_t has as a member. > > --no-gridfit is implemented. > > The round-to-integer coordinates for png is moved to the libart code in > rrd_gfx. The 'close path' code is cleaned up so the node list is left > unchanged if you want to save the same graph in multiple formats in one > run. The rounding is done on the scaled coordinates (zoom). > > I have made a simple version for logarithmic y scales as such a scale > might have 5 gridlines with 4 difference spacings. This version only > uses y = 10^x values for modifying the scale. > > My old patch often reduced the scale. That bug is fixed, and I have > added alignment of first gridline if im->minval happended to place that > on non-integer y pixel pos. > > http://www.vitality.dk/rrdtool/patches/2002-04-15-gridfit.diff >
Peter, thanks for the patch, it is in. Please also send an update for the doc/rrd_...src files cheers tobi > -- ______ __ _ /_ __/_ / / (_) Oetiker, ETZ J97, ETH, 8092 Zurich, Switzerland / // _ \/ _ \/ / phoneto:+41(0)1-632-5286 faxto:+41(0)1-632-1517 /_/ \.__/_.__/_/ [EMAIL PROTECTED] http://google.com/search?q=tobi -- Unsubscribe mailto:[EMAIL PROTECTED] Help mailto:[EMAIL PROTECTED] Archive http://www.ee.ethz.ch/~slist/rrd-developers WebAdmin http://www.ee.ethz.ch/~slist/lsg2.cgi
