The Allegro Wiki is migrating to github at https://github.com/liballeg/allegro_wiki/wiki

Difference between revisions of "AllegroGL"

From Allegro Wiki
Jump to: navigation, search
m (drop introduction heading (short article))
 
(One intermediate revision by one other user not shown)
Line 1: Line 1:
 +
{{merge|Hardware Accelerated Allegro (AllegroGL)}}
 
[http://allegrogl.sourceforge.net AllegroGL] is an Allegro add-on that allows you to use OpenGL alongside Allegro -- you use OpenGL for your rendering to the screen, and Allegro for miscellaneous tasks like gathering input, doing timers, getting cross-platform portability, loading data, and drawing your textures. So this library fills the same hole that things like glut do.
 
[http://allegrogl.sourceforge.net AllegroGL] is an Allegro add-on that allows you to use OpenGL alongside Allegro -- you use OpenGL for your rendering to the screen, and Allegro for miscellaneous tasks like gathering input, doing timers, getting cross-platform portability, loading data, and drawing your textures. So this library fills the same hole that things like glut do.
  
Line 21: Line 22:
 
With Allegro 4.2.x you have to download and build AllegroGL separately. In Allegro 4.4.x this process is simplified: AllegroGL is bundled in the package and the build system is integrated.
 
With Allegro 4.2.x you have to download and build AllegroGL separately. In Allegro 4.4.x this process is simplified: AllegroGL is bundled in the package and the build system is integrated.
  
It is planed that most of the AllegroGL code will find its place in Allegro 4.9 branch, thus making AllegroGL project obsolete.
+
It is planned that most of the AllegroGL code will find its place in Allegro 4.9 branch, thus making AllegroGL project obsolete.

Latest revision as of 20:28, August 10, 2011

Merge-arrows.gif
It has been suggested that this article or section be merged with Hardware Accelerated Allegro (AllegroGL). (Discuss)

AllegroGL is an Allegro add-on that allows you to use OpenGL alongside Allegro -- you use OpenGL for your rendering to the screen, and Allegro for miscellaneous tasks like gathering input, doing timers, getting cross-platform portability, loading data, and drawing your textures. So this library fills the same hole that things like glut do.

AllegroGL also automatically exposes most, if not all, OpenGL extensions available to user programs. This means you no longer have to manually load them; extension management is already done for you.


Usage

AllegroGL is a addon for Allegro 4.2.x and 4.4.x. It losses its purpose for Allegro 4.9.x since it has OpenGL support integrated.

To use AllegroGL the one has to put #include <alleggl.h>, call install_allegro_gl() and set a OpenGL graphics mode, like a minimal example shows in this document.

Once the graphics mode has been set, the one can use OpenGL commands to draw to the screen. With a good OpenGL knowledge this makes possible to implement good-looking 3D games. You can also code games in 2D using OpenGL.

For easier usage and porting of existing Allegro games, AllegroGL offers a so called Allegro GFX Driver Interface which implements Allegro graphics API using OpenGL commands, enabling Hardware Accelerated Allegro (AllegroGL).

AllegroGL also offers you a dozen of handy function to manage fonts, extensions, textures, etc. More info can be found in on-line docs.

Future

Ever since the beginning of its development, AllegroGL has always been intended to be merged into Allegro once. With Allegro 4.2.x you have to download and build AllegroGL separately. In Allegro 4.4.x this process is simplified: AllegroGL is bundled in the package and the build system is integrated.

It is planned that most of the AllegroGL code will find its place in Allegro 4.9 branch, thus making AllegroGL project obsolete.