3 <h3 id="TOP">Index</h3>
5 <ul><li><a href="#NAME">NAME</a></li>
6 <li><a href="#VERSION">VERSION</a></li>
7 <li><a href="#SYNOPSIS">SYNOPSIS</a></li>
8 <li><a href="#DESCRIPTION">DESCRIPTION</a></li>
9 <li><a href="#METHODS">METHODS</a>
10 <ul><li><a href="#new">new</a></li>
11 <li><a href="#load">load</a></li>
12 <li><a href="#play">play</a></li>
13 <li><a href="#loud">loud</a></li>
14 <li><a href="#stop">stop</a></li>
17 <li><a href="#AUTHOR">AUTHOR</a></li>
18 <li><a href="#BUGS">BUGS</a></li>
19 <li><a href="#SUPPORT">SUPPORT</a></li>
20 <li><a href="#ACKNOWLEDGEMENTS">ACKNOWLEDGEMENTS</a></li>
21 <li><a href="#LICENSE_AND_COPYRIGHT">LICENSE AND COPYRIGHT</a>
26 <h1 id="NAME">NAME</h1><p><a href="#TOP" class="toplink">Top</a></p>
27 <div id="NAME_CONTENT">
31 <h1 id="VERSION">VERSION</h1><p><a href="#TOP" class="toplink">Top</a></p>
32 <div id="VERSION_CONTENT">
33 <p>Version 0.01_01</p>
40 <h1 id="SYNOPSIS">SYNOPSIS</h1><p><a href="#TOP" class="toplink">Top</a></p>
41 <div id="SYNOPSIS_CONTENT">
42 <pre> use SDLx::Sound;
44 my $snd = SDLx::Sound->new();
46 # loads and plays a single sound now
47 $snd->play('myfile.wav');
50 $snd->load('theSound.aif');
52 # plays it or all loaded files
57 chanell_01 => "/my_sound1.wav",
58 chanell_02 => "/my_sound2.ogg"
63 chanell_01 => 0, # start
64 chanell_01 => 1256, # miliseconds
68 # Load files in channels for realtime play
69 $snd->load(%files);
71 # sets sound channel_01 loudness
72 $snd->loud('channel_01', 80); # loud at 80%
73 $snd->play(%times); # play loaded files at times
74 $snd->play; # play again
76 # plays sound channel_01 at 578 miliseconds from now
77 $snd->play('channel_01', 578);
80 $snd->fade('channel_02', 2345, 3456, -20);
82 # in a single act do the wole Sound
83 my $snd = SDLx::Sound->new(
85 chanell_01 => "/my_sound1.wav",
86 chanell_02 => "/my_sound2.ogg"
94 chanell_01 => 0, # start
95 chanell_01 => 1256, # miliseconds
99 chanell_02 => [2345, 3456, -20]
106 <h1 id="DESCRIPTION">DESCRIPTION</h1><p><a href="#TOP" class="toplink">Top</a></p>
107 <div id="DESCRIPTION_CONTENT">
112 <p>You can think about the SDLx::Sound at 2 aproaches. </p>
114 <dt>* A simple sound or </dt>
115 <dt>* The sound of your game or app. </dt>
117 <p>Your application will say what the best aproach.</p>
118 <p>In a taste that resembles to perl and to SDL, our SDLx:Sound hooks at SDL::Audio and SDL::Mixer with a gracefull and simple interface that can offer to monks a modern perlish way to manage sounds.</p>
119 <p>An SDLx::Sound object can load sounds from filesystem, play it, adjust this loudness level or stops the sound. </p>
120 <p>Each sound will play in the next available channel, so it can be handled isolately.</p>
123 <h1 id="METHODS">METHODS</h1><p><a href="#TOP" class="toplink">Top</a></p>
124 <div id="METHODS_CONTENT">
127 <h2 id="new">new</h2>
128 <div id="new_CONTENT">
129 <p>Returns a new instance of SDLx::Sound</p>
132 <h2 id="load">load</h2>
133 <div id="load_CONTENT">
136 <h2 id="play">play</h2>
137 <div id="play_CONTENT">
140 <h2 id="loud">loud</h2>
141 <div id="loud_CONTENT">
144 <h2 id="stop">stop</h2>
145 <div id="stop_CONTENT">
148 <h1 id="AUTHOR">AUTHOR</h1><p><a href="#TOP" class="toplink">Top</a></p>
149 <div id="AUTHOR_CONTENT">
150 <p>Monsenhor, <code><ricardo.filipo at mitologica.com.br></code></p>
153 <h1 id="BUGS">BUGS</h1><p><a href="#TOP" class="toplink">Top</a></p>
154 <div id="BUGS_CONTENT">
155 <p>Please report any bugs or feature requests to <code>bug-sdlx-sound at rt.cpan.org</code>, or through
156 the web interface at <a href="http://rt.cpan.org/NoAuth/ReportBug.html?Queue=SDLx-Sound">http://rt.cpan.org/NoAuth/ReportBug.html?Queue=SDLx-Sound</a>. I will be notified, and then you'll
157 automatically be notified of progress on your bug as I make changes.</p>
170 <h1 id="SUPPORT">SUPPORT</h1><p><a href="#TOP" class="toplink">Top</a></p>
171 <div id="SUPPORT_CONTENT">
172 <p>You can find documentation for this module with the perldoc command.</p>
173 <pre> perldoc SDLx::Sound
179 <p>You can also look for information at:</p>
181 <dt>* RT: CPAN's request tracker</dt>
183 <p><a href="http://rt.cpan.org/NoAuth/Bugs.html?Dist=SDLx-Sound">http://rt.cpan.org/NoAuth/Bugs.html?Dist=SDLx-Sound</a></p>
185 <dt>* AnnoCPAN: Annotated CPAN documentation</dt>
187 <p><a href="http://annocpan.org/dist/SDLx-Sound">http://annocpan.org/dist/SDLx-Sound</a></p>
189 <dt>* CPAN Ratings</dt>
191 <p><a href="http://cpanratings.perl.org/d/SDLx-Sound">http://cpanratings.perl.org/d/SDLx-Sound</a></p>
193 <dt>* Search CPAN</dt>
195 <p><a href="http://search.cpan.org/dist/SDLx-Sound/">http://search.cpan.org/dist/SDLx-Sound/</a></p>
204 <h1 id="ACKNOWLEDGEMENTS">ACKNOWLEDGEMENTS</h1><p><a href="#TOP" class="toplink">Top</a></p>
205 <div id="ACKNOWLEDGEMENTS_CONTENT">
212 <h1 id="LICENSE_AND_COPYRIGHT">LICENSE AND COPYRIGHT</h1><p><a href="#TOP" class="toplink">Top</a></p>
213 <div id="LICENSE_AND_COPYRIGHT_CONTENT">
214 <p>Copyright 2010 Monsenhor.</p>
215 <p>This program is free software; you can redistribute it and/or modify it
216 under the terms of either: the GNU General Public License as published
217 by the Free Software Foundation; or the Artistic License.</p>
218 <p>See http://dev.perl.org/licenses/ for more information.</p>