|
From: Daniel J S. <dan...@ie...> - 2006-01-01 02:35:38
|
Here's a resulting patch for I've added a demo. A new animation that spins the globe around. So there is an "animate2.dem" combining the concepts of animate.dem and world2.dem. I've also rewritten "animate.dem" and "gnuplot.rot" slightly. So that I could reuse gnuplot.rot, I've made it generic as follows: zrot=(zrot+zrot_delta)%360 xrot=(xrot+xrot_delta)%360 set view xview(xrot),zview(zrot) replot iteration_count=iteration_count+1 if ((!limit_iterations) || (iteration_count<=limit_iterations)) reread You can imagine how this works. Just define all the variables and away we go. Some comments: 1) It would be nice if looping could be done without requiring two files. What might enable that is a special test or function saying how deep the "reread" is. For example, say I wanted to have the above example in a single file, it might be if (!load_depth()) <all the initial definitions> else zrot= xrot= set view replot iteration_count= if () reread end where load_depth() is just some pseudo function or variable that gnuplot makes available. 2) Modulo (%) doesn't seem to work with negative numbers. Shouldn't it? 3) We've got to combine the layout and border behavior for 2D and 3D plots. In the demo I created, I had to make the GIF output resolution very large simply because otherwise all the image is used up by the borders and only a few pixels are left for the plot. I tried to kludge this by making the view scaling large, but then got: gnuplot: hidden3d.c:776: store_polygon: Assertion `p->ymax <= surface_scale' failed. Dan |