Algorithm::Line::Bresenham 0.11
Sponsored Links
Algorithm::Line::Bresenham 0.11 Ranking & Summary
File size:
0.003 MB
Platform:
Any Platform
License:
Perl Artistic License
Price:
Downloads:
5773
Date added:
2007-05-16
Publisher:
osfameron
Publisher URL:
http://search.cpan.org/~o
Algorithm::Line::Bresenham 0.11 description
Algorithm::Line::Bresenham is a Perl module that contains a simple pixellated line-drawing algorithm.
SYNOPSIS
use Algorithm::Line::Bresenham qw/line/;
my @points = line(3,3 => 5,0);
# returns the list: [3,3], [4,2], [4,1], [5,0]
line(3,3 => 5,0, &draw_line);
# calls draw_line on each point in turn
Bresenham is one of the canonical line drawing algorithms for pixellated grids. Given a start and an end-point, Bresenham calculates which points on the grid need to be filled to generate the line between them.
Googling for Bresenham, and line drawing algorithms gives some good overview. The code here takes its starting point from Mark Feldmans Pascal code in his article Bresenhams Line and Circle Algorithms at http://www.gamedev.net/reference/articles/article767.asp.
FUNCTIONS
line
line ($from_y, $from_x => $to_y, $to_x);
Generates a list of all the intermediate points. This is returned as a list of array references.
line ($from_y, $from_x => $to_y, $to_x, &callback);
Calls the referenced function on each point in turn. The callback could be used to actually draw the point. Returns the collated return values from the callback.
circle
my @points = circle ($y, $x, $radius)
Returns the points to draw a circle with
Download nowSYNOPSIS
use Algorithm::Line::Bresenham qw/line/;
my @points = line(3,3 => 5,0);
# returns the list: [3,3], [4,2], [4,1], [5,0]
line(3,3 => 5,0, &draw_line);
# calls draw_line on each point in turn
Bresenham is one of the canonical line drawing algorithms for pixellated grids. Given a start and an end-point, Bresenham calculates which points on the grid need to be filled to generate the line between them.
Googling for Bresenham, and line drawing algorithms gives some good overview. The code here takes its starting point from Mark Feldmans Pascal code in his article Bresenhams Line and Circle Algorithms at http://www.gamedev.net/reference/articles/article767.asp.
FUNCTIONS
line
line ($from_y, $from_x => $to_y, $to_x);
Generates a list of all the intermediate points. This is returned as a list of array references.
line ($from_y, $from_x => $to_y, $to_x, &callback);
Calls the referenced function on each point in turn. The callback could be used to actually draw the point. Returns the collated return values from the callback.
circle
my @points = circle ($y, $x, $radius)
Returns the points to draw a circle with
Algorithm::Line::Bresenham 0.11 Screenshot
Sponsored Links
Algorithm::Line::Bresenham 0.11 Keywords
>lineXypointspointpixellatedAlgorithmLineBresenhamAlgorithm::Line::Bresenham 0.11LibrariesProgramming
Bookmark Algorithm::Line::Bresenham 0.11
Algorithm::Line::Bresenham 0.11 Copyright
WareSeeker periodically updates pricing and software information of Algorithm::Line::Bresenham 0.11 full version from the publisher, so some information may be slightly out-of-date. You should confirm all information before relying on it. Software piracy is theft, Using crack, password, serial numbers, registration codes, key generators is illegal and prevent future development of Algorithm::Line::Bresenham 0.11 Edition. Download links are directly from our mirror sites or publisher sites, torrent files or links from rapidshare.com, yousendit.com or megaupload.com are not allowed
Algorithm::Line::Bresenham 0.11 Related Software
Algorithm::DiffOld is a Perl module to compute `intelligent differences between two files / lists but use the old interface.
Algorithm::Huffman is a Perl extension that implements the Huffman algorithm.
IDS::Algorithm::MM is a Perl module created to learn or test using a first-order Markov Model (MM).
Algorithm::ScheduledPath is a Perl module that helps you to find scheduled paths in a directed graph.
Algorithm::SISort is a Perl module that contains select and insert sorting algorithm.
Algorithm::Permute is a Perl module with handy and fast permutation with object oriented interface.
Algorithm::Knapsack is a brute-force algorithm for the knapsack problem.
Algorithm::C3 is a module for merging hierarchies using the C3 algorithm.
Fast Genetic Algorithm is a simple yet powerful implementation of a general genetic algorithm.
mcl-algorithm is a scalable cluster algorithm for graphs based on stochastic flow.
My Software
You have not saved any software. Click "Save" next to each software to save it to your software basket
Related Search
TOP POPULAR DOWNLOAD