From: <ai...@us...> - 2011-01-02 01:22:49
|
Revision: 11423 http://plplot.svn.sourceforge.net/plplot/?rev=11423&view=rev Author: airwin Date: 2011-01-02 01:22:42 +0000 (Sun, 02 Jan 2011) Log Message: ----------- Implement plot3d-related wrappings. Allows example 11 to work and give consistent results with its C counterpart. Modified Paths: -------------- trunk/bindings/octave/plplot_octave.i trunk/plplot_test/test_octave.sh.in Modified: trunk/bindings/octave/plplot_octave.i =================================================================== --- trunk/bindings/octave/plplot_octave.i 2011-01-02 01:05:57 UTC (rev 11422) +++ trunk/bindings/octave/plplot_octave.i 2011-01-02 01:22:42 UTC (rev 11423) @@ -735,11 +735,43 @@ void my_plmeshc( PLFLT *ArrayX, PLFLT *ArrayY, PLFLT *MatrixCk, PLINT nx, PLINT ny, PLINT opt, PLFLT *Array, PLINT n ); -// Deal with these later. -%ignore pllegend; +// plot3d-related wrappers. + %ignore plot3d; +%rename(plot3d) my_plot3d; %ignore plot3dc; +%rename(plot3dc) my_plot3dc; %ignore plot3dcl; +//unimplemented: %rename(plot3dcl) my_plot3dcl; + +%{ +// Plots a 3-d representation of the function z[x][y]. +void my_plot3d( PLFLT *x, PLFLT *y, PLFLT *z, + PLINT nx, PLINT ny, PLINT opt, PLINT side ) +{ + f2c( z, zz, nx, ny ) + c_plot3d( x, y, zz, nx, ny, opt, side ); +} + +// Plots a 3-d representation of the function z[x][y] with contour +void my_plot3dc( PLFLT *x, PLFLT *y, PLFLT *z, + PLINT nx, PLINT ny, PLINT opt, + PLFLT *clevel, PLINT nlevel ) +{ + f2c( z, zz, nx, ny ) + c_plot3dc( x, y, zz, nx, ny, opt, clevel, nlevel ); +} +%} + +void my_plot3d( PLFLT *ArrayX, PLFLT *ArrayY, PLFLT *MatrixCk, + PLINT nx, PLINT ny, PLINT opt, PLBOOL side ); + +void my_plot3dc( PLFLT *ArrayX, PLFLT *ArrayY, PLFLT *MatrixCk, + PLINT nx, PLINT ny, PLINT opt, PLFLT *Array, PLINT n ); + + +// Deal with these later. +%ignore pllegend; %ignore plsurf3d; %ignore plsurf3dl; %ignore plshade; Modified: trunk/plplot_test/test_octave.sh.in =================================================================== --- trunk/plplot_test/test_octave.sh.in 2011-01-02 01:05:57 UTC (rev 11422) +++ trunk/plplot_test/test_octave.sh.in 2011-01-02 01:22:42 UTC (rev 11423) @@ -72,12 +72,13 @@ #Example 19 is not yet implemented failed = [] ; # Temporarily drop everything that involves 2D arrays and/or callbacks. -# 8, 11, 21: 3D mesh plots, -# 9, 14: 22 contours, callbacks, +# 8, 11: 3D meash-related plots, # 15, 16: shade plots, callbacks, # 20: plimage +# 21: plgriddata and 3D plots +# 22: plvector related wrappers. # until typemaps for swig-generated interface are done. -@swig_octave_comment@for i=[1:7 9 10 12 13 14 17 18 23:31] ; +@swig_octave_comment@for i=[1:7 9:14 17 18 23:31] ; @matwrap_octave_comment@for i=[1:18 20:31 ] ; ofile = sprintf("${OUTPUT_DIR}/x%.2d${lang}_${dsuffix}.txt",i); strm = fopen(ofile,"w"); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |