## "Fossies" - the Fresh Open Source Software Archive

### Source code changes of the file "Graphics/TriD/TriD.pm" betweenPDL-2.078.tar.gz and PDL-2.079.tar.gz

About: PDL (Perl Data Language) aims to turn perl into an efficient numerical language for scientific computing (similar to IDL and MatLab).

TriD.pm  (PDL-2.078):TriD.pm  (PDL-2.079)
skipping to change at line 167 skipping to change at line 167
imag3d([\$zcoords]); imag3d([\$zcoords]);
you don't need to start thinking about where to plot the points: you don't need to start thinking about where to plot the points:
points3d([SURF2D,\$zcoords]); points3d([SURF2D,\$zcoords]);
will do exactly the same. will do exactly the same.
Let's begin by thnking about how you might make a 2d data plot. Let's begin by thinking about how you might make a 2d data plot.
If you sampled your data at regular intervals, you would have If you sampled your data at regular intervals, you would have
a time serires y(t) = (y0, y1, y2, ...). You could plot y vs t a time serires y(t) = (y0, y1, y2, ...). You could plot y vs t
by computing t0 = 0, t1 = dt, t2 = 2 * dt, and then plotting by computing t0 = 0, t1 = dt, t2 = 2 * dt, and then plotting
(t0, y0), (t1, y1), etc. (t0, y0), (t1, y1), etc.
Next suppose that you measured x(t) and y(t). You can still Next suppose that you measured x(t) and y(t). You can still
plot y vs t, but you can also plot y vs x by plotting (x0, y0), plot y vs t, but you can also plot y vs x by plotting (x0, y0),
(x1, y1), etc. The x-values don't have to increase monotonically: (x1, y1), etc. The x-values don't have to increase monotonically:
they could back-track on each other, for example, like the they could back-track on each other, for example, like the
latitude and longitude of a boat on a lake. If you use plplot, latitude and longitude of a boat on a lake. If you use plplot,
skipping to change at line 358 skipping to change at line 358
contexts and options contexts and options
=for ref =for ref
alias for mesh3d alias for mesh3d
=item trigrid3d
Show a triangular mesh, giving C<\$vertices> and C<\$faceidx> which is
a series of triplets of indices into the vertices, each describing
one triangle. The order of points matters for the shading - the normal
vector points towards the clockface if the points go clockwise.
Options: C<Smooth> (on by default), C<Lines> (off by default),
C<ShowNormals> (off by default, useful for debugging).
Implemented by C<PDL::Graphics::TriD::STrigrid_S>.
=item trigrid3d_ns
Like L</trigrid3d>, but without shading or normals.
Implemented by C<PDL::Graphics::TriD::STrigrid>.
=for ref =for ref
3D points plot, defined by a variety of contexts 3D points plot, defined by a variety of contexts
Implemented by C<PDL::Graphics::TriD::Points>. Implemented by C<PDL::Graphics::TriD::Points>.
=for usage =for usage
skipping to change at line 553 skipping to change at line 571
These functions are not exported, partly because they are not fully These functions are not exported, partly because they are not fully
implemented. implemented.
=over =over
=item contour3d =item contour3d
Implemented by C<PDL::Graphics::TriD::Contours>. Implemented by C<PDL::Graphics::TriD::Contours>.
=back =back
The key concepts (object types) of TriD are explained in the following: The key concepts (object types) of TriD are explained in the following:
In this 3D abstraction, everything that you can "draw" In this 3D abstraction, everything that you can "draw"
without using indices is an Object. That is, if you have a surface, without using indices is an Object. That is, if you have a surface,
skipping to change at line 684 skipping to change at line 694
# ' # '
package PDL::Graphics::TriD; package PDL::Graphics::TriD;
use strict; use strict;
use warnings; use warnings;
use PDL::Exporter; use PDL::Exporter;
use PDL::Core ''; # barf use PDL::Core ''; # barf
our @ISA = qw/PDL::Exporter/; our @ISA = qw/PDL::Exporter/;
our @EXPORT_OK = qw/imag3d_ns imag3d line3d mesh3d lattice3d points3d our @EXPORT_OK = qw/imag3d_ns imag3d line3d mesh3d lattice3d points3d
trigrid3d trigrid3d_ns
spheres3d describe3d imagrgb imagrgb3d hold3d release3d spheres3d describe3d imagrgb imagrgb3d hold3d release3d
keeptwiddling3d nokeeptwiddling3d close3d keeptwiddling3d nokeeptwiddling3d close3d
twiddle3d grabpic3d tridsettings/; twiddle3d grabpic3d tridsettings/;
our %EXPORT_TAGS = (Func=>\@EXPORT_OK); our %EXPORT_TAGS = (Func=>\@EXPORT_OK);
our \$verbose; our \$verbose;
use PDL::Graphics::TriD::Object; use PDL::Graphics::TriD::Object;
use PDL::Graphics::TriD::Window; use PDL::Graphics::TriD::Window;
use PDL::Graphics::TriD::ViewPort; use PDL::Graphics::TriD::ViewPort;
use PDL::Graphics::TriD::Graph; use PDL::Graphics::TriD::Graph;
skipping to change at line 883 skipping to change at line 894
*imag3d_ns=*imag3d_ns=\&PDL::imag3d_ns; *imag3d_ns=*imag3d_ns=\&PDL::imag3d_ns;
sub PDL::imag3d_ns { &checkargs; sub PDL::imag3d_ns { &checkargs;
graph_object(PDL::Graphics::TriD::SLattice->new(@_)); graph_object(PDL::Graphics::TriD::SLattice->new(@_));
} }
*imag3d=*imag3d=\&PDL::imag3d; *imag3d=*imag3d=\&PDL::imag3d;
sub PDL::imag3d { &checkargs; sub PDL::imag3d { &checkargs;
graph_object(PDL::Graphics::TriD::SLattice_S->new(@_)); graph_object(PDL::Graphics::TriD::SLattice_S->new(@_));
} }
*trigrid3d=*trigrid3d=\&PDL::trigrid3d;
sub PDL::trigrid3d { &checkargs;
sub { &checkargs;
graph_object(PDL::Graphics::TriD::STrigrid_S->new(@_)); } graph_object(PDL::Graphics::TriD::STrigrid_S->new(@_)); }
*trigrid3d_ns=*trigrid3d_ns=\&PDL::trigrid3d_ns;
sub { &checkargs; sub PDL::trigrid3d_ns { &checkargs;
graph_object(PDL::Graphics::TriD::STrigrid->new(@_)); } graph_object(PDL::Graphics::TriD::STrigrid->new(@_)); }
*mesh3d=*mesh3d=\&PDL::mesh3d; *mesh3d=*mesh3d=\&PDL::mesh3d;
*lattice3d=*lattice3d=\&PDL::mesh3d; *lattice3d=*lattice3d=\&PDL::mesh3d;
*PDL::lattice3d=*PDL::lattice3d=\&PDL::mesh3d; *PDL::lattice3d=*PDL::lattice3d=\&PDL::mesh3d;
sub PDL::mesh3d { &checkargs; sub PDL::mesh3d { &checkargs;
graph_object(PDL::Graphics::TriD::Lattice->new(@_)); graph_object(PDL::Graphics::TriD::Lattice->new(@_));
} }
*points3d=*points3d=\&PDL::points3d; *points3d=*points3d=\&PDL::points3d;
sub PDL::points3d { &checkargs; sub PDL::points3d { &checkargs;
End of changes. 7 change blocks.
17 lines changed or deleted 24 lines changed or added