Download Shareware and Freeware Software for Windows, Linux, Macintosh, PDA

line Home  |  About Us  |  Link To Us  |  FAQ  |  Contact

Serving Software Downloads in 956 Categories, Downloaded 50.432.884 Times

Games::Irrlicht 0.04

  Date Added: November 11, 2010  |  Visits: 1.042

Games::Irrlicht

Report Broken Link
Printer Friendly Version


Product Homepage
Download (91 downloads)



Games::Irrlicht is a Perl module that use the Irrlicht 3D Engine in Perl. SYNOPSIS package MyGame; use strict; use base Games::Irrlicht; use Games::Irrlicht::Constants; get EDT_SOFTWARE etc # override methods: The Why When building a game or screensaver displaying some continously running animation, a couple of basics need to be done to get a smooth animation and to care of copying with varying speeds of the system. Ideally, the animation displayed should be always the same, no matter how fast the system is. This not only includes different systems (a PS/2 for instance would be slower than a 3 Ghz PC system), but also changes in the speed of the system over time, for instance when a background process uses some CPU time or the complexity of the scene changes. In many old (especial DOS) games, like the famous Wing Commander series, the animation would be drawn simple as fast as the system could, meaning that if you would try to play such a game on a modern machine it we end before you had the chance to click a button, simple because it wizzes a couple 10,000 frames per second past your screen. While it is quite simple to restrict the maximum framerate possible, care must be taken to not just "burn" surplus CPU cycles. Instead the application should free the CPU whenever possible and give other applications/thread a chance to run. This is especially important for low-priority applications like screensavers. Games::Irrlicht makes this possible for you without you needing to worry about how this is done. It will restrict the frame rate to a possible maximum and tries to achive the average framerate as close as possible to this maximum. Games::Irrlicht also monitors the average framerate and gives you access to this value, so that you can, for instance, adjust the scene complexity based on the current framerate. You can access the current framerate, averaged over the last second (1000 ms) by calling current_fps. Frame-rate Independend Clock Now that our application is drawing frames (via the method draw_frame, which you should override in a subclass), we need a method to decouple the animation speed from the framerate. If we would simple put put an animation step every frame, we would get some sort of Death of the Fast Machine" effect ala Wing Commander. E.g. if the system manages only 10 FPS, the animation would be slower than when we do 60 FPS. To achive this, SDL::App::FPS features a clock, which runs independed of the current frame rate (and actually, independend of the systems clock, but more on this in the next section). You can access it via a call to current_time, and it will return the ticks e.g. the number of milliseconds elapsed since the start of the application. To effectively decouple animation speed from FPS, get at each frame the current time, then move all objects (or animation sequences) according to their speed and display them at the location that matches the time at the start of the frame. See examples/ for an example on how to do this. Note that it is better to draw all objects according to the time at the start of the frame, and not according to the time when you draw a particular object. Or in other words, treat the time like it is standing still when drawing a complete frame. Thus each frame becomes a snapshot in time, and you dont get nasty sideeffects like one object beeing always "behind" the others just because it gets drawn earlier. Time Warp Now that we have a constant animation speed independend from framerate or system speed, lets have some fun. Since all our animation steps are coupled to the current time, we can play tricks with the current time. The function time_warp lets you access a time warp factor. The default is 1.0, but you can set it to any value you like. If you set it, for instance to 0.5, the time will pass only half as fast as it used to be. This means instant slow motion! And when you really based all your animation on the current time, as you should, then it will really slow down your entire game to a crawl. Likewise a time warp of 2 lets the time pass twice as fast. There are virtually no restrictions to the time warp. For instance, a time warp greater than one lets the player pass boring moments in a game, for instance when you need to wait for certain events in a strategy game, like your factory beeing completed. Try to press the left (fast forward), right (slow motion) and middle (normal) mousebuttons in the example application and watch the effect. If you are very bored, press the b key and see that even negative time warps are possible... Ramping Time Warp Now, setting the time war to factor of N is nice, but sometimes you want to make dramatic effects, like slowly freezing the time into ultra slow motion or speeding it up again. For this, ramp_time_warp can be used. You give it a time warp factor you want to reach, and a time (based on real time, not the warped, but you can of course change this). Over the course of the time you specified, the time warp factor will be adapted until it reaches the new value. This means it is possible to slowly speeding up or down. You can also check whether the time warp is constant or currently ramping by using time_is_ramping. When a ramp is in effect, call ramp_time_warp without arguments to get the current parameters. See below for details. The example application uses the ramping effect instead instant time warp. Event handlers This section describes events as external events that typically happen due to user intervention. Such events are keypresses, mouse movement, mouse button presses, or just the flipping of the power switch. Of course the last event cannot be handled in a sane way by our framework. All the events are checked and handled by Games::Irrlicht automatically. The event QUIT (which denotes that the application should shut down) is also carried out automatically. If you want to do some tidying up when this happens, override the method quit_handler. The event checking and handling is done at the start of each frame. This means no event will happen while you draw the current frame. Well, it will happen, but the action caused by that event will delayed until the next frame starts. This simplifies the frame drawing routine tremendously, since you know that your world will be static until the next frame..

Requirements: No special requirements
Platforms: Linux
Keyword: Animation Cpu Current Time For Instance Fps Frame Gamesirrlicht Perl Module Time Time Warp Warp You Want To
Users rating: 0/10

License: Freeware Size: 39.94 KB
USER REVIEWS
More Reviews or Write Review


GAMES::IRRLICHT RELATED
Libraries  -  Time::Warp 0.5
Time::Warp is a Perl module to control over the flow of time. SYNOPSIS use Time::Warp qw(scale to time); to(time + 5); # 5 seconds ahead scale(2); # make time flow twice normal Our external experience unfolds in 3 1/2 dimensions (time has...
3.07 KB  
Networking  -  AnyFont 2.2
AnyFont allows you to automatically set any TrueType or OpenType font for your post titles, menu items, widget titles or anywhere else you want to use a custom font on your WordPress site.Supports both PHP4 & GD or PHP5 & Imagick or GD.New...
430.08 KB  
Programming  -  jclasslib bytecode viewer 3.0
JProfiler is an award-winning all-in-one Java profiler. JProfilers intuitive GUI helps you find performance bottlenecks, pin down memory leaks and resolve threading issues. Even though JProfiler has a powerful feature set, its a Java profiler...
1.7 MB  
Communication Tools  -  Jelly SMS for Linux 4. 4. 2003
Jelly SMS lets you to send SMS text messages internationally, giving you the convenience of not having to log into your provider website each time you want to use your webtexts. All this while lowering your monthly phone bill! Jelly SMS looks...
5.8 MB  
Communication Tools  -  Jelly SMS for Mac OS X 1.0.8
Jelly SMS lets you to send SMS text messages internationally, giving you the convenience of not having to log into your provider website each time you want to use your webtexts. All this while lowering your monthly phone bill! Jelly SMS looks...
1024 KB  
Multimedia & Graphics  -  Snapshot for Mac OS 2.1.1
Have full control over the print size and how you want to crop and frame your picture. Add borders and speech bubbles for more interesting and personal prints. Multiple layout styles allow you to get just the prints you want - and full print...
7.6 MB  
Utilities  -  Intelligent Shutdown 2.1.6
Do you want to turn off your computer automatically at a specified time?Do you want the computer to launch your programs at a scheduled time?Do you want to listen the music while you are sleeping and shutdown computer after a while?Do you want the...
 
Mail Clients  -  Mail Merge for Microsoft Access 5.0.66
4TOPS Mail Merge for Microsoft Access is the ultimate solution if you want to create Microsoft Word documents or emails using data in your Microsoft Access database. Documents can be created easily with any level of complexity (e.g. contracts)....
 
Macintosh Software  -  Meditation 1.0
Meditation is a simple timer application for Mac OS X. Just set the time you want to meditate, and at the end of the time period a gong sound will play twice. Because it is really just a timer, you can also use it for other timer needs, but it was...
156.27 KB  
Libraries  -  Test::Version 0.02
Test::Version is a Perl module that has the role to check for VERSION information in modules. SYNOPSIS use Test::Version; plan tests => $num_tests; version_ok( $file ); FUNCTIONS version_ok( FILENAME, [EXPECTED, [NAME] ] ) version_ok...
5.12 KB  
NEW DOWNLOADS IN PROGRAMMING, LIBRARIES
Programming  -  Cedalion for Linux 0.2.6
Cedalion is a programming language that allows its users to add new abstractions and define (and use) internal DSLs. Its innovation is in the fact that it uses projectional editing to allow the new abstractions to have no syntactic limitations.
471.04 KB  
Programming  -  Math::GMPf 0.29
Math::GMPf - perl interface to the GMP library's floating point (mpf) functions.
30.72 KB  
Programming  -  Net::Wire10 1.08
Net::Wire10 is a Pure Perl connector that talks to Sphinx, MySQL and Drizzle servers. Net::Wire10 implements the low-level network protocol, alias the MySQL wire protocol version 10, necessary for talking to one of the aforementioned...
30.72 KB  
Programming  -  logilab-common 0.56.2
a bunch of modules providing low level functionnalities shared among some python projects devel Please note that some of the modules have some extra dependencies. For instance, logilab.common.db will require a db-api 2.0 compliant...
174.08 KB  
Programming  -  OpenSSL for linux 1.0.0a
The OpenSSL Project is a collaborative effort to develop a robust, commercial-grade, full-featured, and Open Source toolkit implementing the Secure Sockets Layer (SSL v2/v3) and Transport Layer Security (TLS v1) protocols as well as a...
3.83 MB  
Libraries  -  wolfSSL 4.0.0
The wolfSSL embedded SSL/TLS library is a lightweight SSL library written in ANSI standard C and targeted for embedded and RTOS environments - primarily because of its small size, speed, and feature set. It is commonly used in standard operating...
3.88 MB  
Libraries  -  EuGTK 4.8.9
Makes it easy to develop good- looking, fast, cross-platform programs that run on Linux, OS X, and Windows. Euphoria is a very fast interpreted/compiled language with straight-forward syntax. EuGTK allows programming in a clean, object-oriented...
10.68 MB  
Libraries  -  Linux User Group Library Manager 1.0
The LUG Library Manager is a project to help Linux User Groups start their own library. A LUG library is helpful to the community at large because it increases access to information, and gives everyone the opportunity to become more knowledgeable.
5.35 KB  
Libraries  -  Module::MakefilePL::Parse 0.12
Module::MakefilePL::Parse is a Perl module to parse required modules from Makefile.PL. SYNOPSIS use Module::MakefilePL::Parse; open $fh, Makefile.PL; $parser = Module::MakefilePL::Parse->new( join("", ) ); $info = $parser->required;...
8.19 KB  
Libraries  -  sqlpp 0.06
sqlpp Perl package is a SQL preprocessor. sqlpp is a conventional cpp-alike preprocessor taught to understand SQL ( PgSQL, in particular) syntax specificities. In addition to the standard #define/#ifdef/#else/#endif cohort, provides also...
10.24 KB