|
From: Maxim S. <mc...@an...> - 2006-07-03 16:06:08
|
Sorry for the delay, I suppose the problem is in the conceptual difference between your interpolations. You have a chart y=f(x) and then smooth it with a spline (the points). Then you want to draw it with agg::conv_bspline, right? But it works differently. It's not y=f(x), it is: x=fx(n) y=fy(n) Where n is the number of the point. It's how a 2D spline works. The suggestion is to use only agg::bspline. You just store your calculated points in the agg::path_storage and draw them through the agg::conv_stroke. McSeem "Gus Grubba" <gu...@gr...> wrote in message news:B6E...@gr...... > Hi all, > > Sorry for posting this again but I did not see this in the archives > so I'm assuming it didn't make it (even though I did receive my own > post back)... > > I have a data set that is loaded and the user should be able to tweak > the points. The problem I'm having is that the curve smoothing on the > data plot does not match the results of the spline code. If I use > agg::bspline for the interpolation, I see the same problem. In the > this screen grab (http://www.grubba.com/agg.png), I've plotted the > data using both agg::conv_bspline and data poked directly to memory > out of the spline (both AGG and my plot are using the same data set). > In this application, there is no "correct" way to handle the data. > > Whichever way works fine. I just need consistency. The solution is to > either find a way for me to have the same data AGG is interpolating > or a way for AGG to use my interpolations. My math is not good enough > to understand all of this. > > TIA > > gus > > > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 |