From: <ai...@us...> - 2011-01-05 08:16:32
|
Revision: 11440 http://plplot.svn.sourceforge.net/plplot/?rev=11440&view=rev Author: airwin Date: 2011-01-05 08:16:26 +0000 (Wed, 05 Jan 2011) Log Message: ----------- Make octave examples 18 (plstring3 replaces plpoin3) and 27 (additional plfill pages) give results that are equivalent to those from C. Modified Paths: -------------- trunk/examples/octave/x18c.m trunk/examples/octave/x27c.m Modified: trunk/examples/octave/x18c.m =================================================================== --- trunk/examples/octave/x18c.m 2011-01-05 08:14:16 UTC (rev 11439) +++ trunk/examples/octave/x18c.m 2011-01-05 08:16:26 UTC (rev 11440) @@ -68,7 +68,8 @@ if (opt(k+1)) plline3( x', y', z' ); else - plpoin3( x', y', z', 1 ); + ## U+22C5 DOT OPERATOR. + plstring3( x', y', z', "⋅" ); endif plcol0(3); Modified: trunk/examples/octave/x27c.m =================================================================== --- trunk/examples/octave/x27c.m 2011-01-05 08:14:16 UTC (rev 11439) +++ trunk/examples/octave/x27c.m 2011-01-05 08:16:26 UTC (rev 11440) @@ -65,7 +65,7 @@ for i = 1:9 pladv(0); plvpor( 0.0, 1.0, 0.0, 1.0 ); - spiro( params(i,:) ); + spiro( params(i,:), 0 ); endfor pladv(0); @@ -74,9 +74,18 @@ for i=1:9 pladv(0); plvpor( 0.0, 1.0, 0.0, 1.0 ); - spiro( params(i,:) ); + spiro( params(i,:), 0 ); endfor + ## Fill the curves. + pladv( 0 ); + plssub( 1, 1 ); ## One window per curve + for i=1:9 + pladv(0); + plvpor( 0.0, 1.0, 0.0, 1.0 ); + spiro( params(i,:), 1 ); + endfor + ## Don't forget to call plend() to finish off! plend1(); @@ -90,7 +99,7 @@ ## =============================================================== -function spiro(params) + function spiro(params, fill) NPNT=20000; @@ -125,7 +134,11 @@ plwind( xmin, xmax, ymin, ymax ); plcol0(1); - plline( xcoord, ycoord ); + if ( fill ) + plfill( xcoord, ycoord ); + else + plline( xcoord, ycoord ); + endif endfunction ## Log-linear plot. This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |