Typo with - sign in constant. Causing constants to not be loaded correctly
[sdlgit/SDL_perl.git] / lib / SDL / Music.pm
CommitLineData
8fde61e3 1# Music.pm
2#
3# a SDL_mixer data module
4#
5# Copyright (C) 2000,2002 David J. Goehrig
6
7package SDL::Music;
8use strict;
9use SDL;
10
11sub new {
12 my $proto = shift;
13 my $class = ref($proto) || $proto;
14 my $filename = shift;
15 my $self = \SDL::MixLoadMusic($filename);
16 bless $self,$class;
17 return $self;
18}
19
20sub DESTROY {
21 my $self = shift;
22 SDL::MixFreeMusic($$self);
23}
24
251;
26
27__END__;
28
29=pod
30
31=head1 NAME
32
33SDL::Music - a perl extension
34
35=head1 DESCRIPTION
36
37L<SDL::Music> is used to load music files for use with L<SDL::Mixer>.
38To load a music file one simply creates a new object passing the filename
39to the constructor:
40
41 my $music = new SDL::Music 'my_song.ogg';
42
43
44=head1 AUTHOR
45
46David J. Goehrig
47
48=head1 SEE ALSO
49
50L<perl> L<SDL::Mixer>
51
52=cut