{
'Test::Simple' => '0.47',
'Module::Build' => '0.22',
- 'YAML' => '0.68',
- 'Alien::SDL' => '0.05',
+ 'YAML' => '0.68'
+ },
+ configure_requires =>
+ {
+ 'Alien::SDL' => '0.07',
'ExtUtils::CBuilder' => '0.260301'
},
build_recommends =>
SDL::App - a SDL perl extension
=head1 SYNOPSIS
-
- my $app = new SDL::App (
- -title => 'Application Title',
- -width => 640,
- -height => 480,
- -depth => 32 );
+
+ use SDL;
+ use SDL::Event;
+ use SDL::App;
+
+ my $app = new SDL::App (
+ -title => 'Application Title',
+ -width => 640,
+ -height => 480,
+ -depth => 32 );
+
+This is the manual way of doing things
+
+ my $event = new SDL::Event; # create a new event
+
+ $event->pump();
+ $event->poll();
+
+ while ($event->wait()) {
+ my $type = $event->type(); # get event type
+ print $type;
+ exit if $type == SDL_QUIT;
+ }
+An alternative to the manual Event processing is the L<SDL::App::loop> .
=head1 DESCRIPTION
L<SDL::App> controls the root window of the of your SDL based application.
-It extends the L<SDL_Surface> class, and provides an interface to the window
+It extends the L<SDL::Surface> class, and provides an interface to the window
manager oriented functions.
=head1 METHODS