Allegro 5.0.8 released!
Peter Wang


Changes from 5.0.7 to 5.0.8 (November 2012)

The main developers this time were: Dennis Busch, Trent Gamblin,
Elias Pschernig, Paul Suntsov, Peter Wang.


- Added alternate spelling: ALLEGRO_ALIGN_CENTER.


- Rewrite D3D display format listing code, which was broken. This should
re-enable multi-sampling and fix ex_depth_mask being slow with D3D.

- Fixed a case where changing fullscreen mode in D3D via al_resize_display
caused a crash and loss of loaded bitmaps information.

- Fixed a case where changing fullscreen mode in OpenGL (on Windows) via
al_resize_display cause nothing to be rendered after the mode change.

- Fix crashes when resizing a WGL fullscreen window.

- Fixed missing/incorrect resize events under Windows.

- Fix al_set_new_display_adapter on OS X.

- Fix use of invalidated pointers in D3D driver when the first format fails.

- Fix bug where setting the mouse cursor had no effect when
the mouse was captured (mouse button held down).

- Fix windows not having a minimise button when set to
windowed state from fullscreen window state.

- Respect ALLEGRO_FRAMELESS flag properly when toggling from
fullscreen window state to windowed state (Windows).

- Don't generate DISPLAY_LOST events when resizing a fullscreen display.

- Scale window icon to sizes returned by GetSystemMetrics (Windows).


- Added al_osx_get_window function (Dennis Gooden).


- al_draw_pixel was crashing when drawn on sub-bitmaps on OpenGL.

- Fix a potential crash when drawing the screen to a bitmap with D3D.

- Avoid null pointer dereference when setting a target bitmap after
its video_texture has already been released (D3D).

- Lock bitmap to prevent slowness when creating a cursor from a non-memory
bitmap on Windows.

- Conditionally lock bitmap when creating cursor on X11 (previously it did
so even if already locked).

- Don't use NSOpenGLPFAAccelerated unnecessarily (OS X).


- Fix incorrect keyboard modifier flags after leaving and re-entering a window

- Fixed a bug with mouse enter/leave events for resized windows under OSX
(Dennis Gooden).

- Temporary fix for delay after mouse warp on OS X.

File I/O:

- Fix al_fputc on big-endian. Reported by Andreas Rönnquist and
Tobias Hansen.

- Make al_fputc return value like fputc when out of range.

- Fix al_read_directory crash on 64-bit Windows (simast).

Image addon:

- Don't include native image loader source files in builds with the native
image loaders disabled (OSX, iOS).

- Added a missing autorelease-pool to the OSX bitmap saving function

- Fix OSX native image loader for loading not-premultiplied RGB data.
Previously the data was "de-multiplied", with possibly all information lost.

- Fix OSX native image loader for loading bitmaps without an alpha channel.
They appeared completely black previously.

Font addons:

- Add builtin font creation function.

- Added ALLEGRO_ALIGN_INTEGER text drawing flag (Todd Cope).

- Made TTF addon include padding on the top and left edges of pages
(Todd Cope).

Audio addon:

- Use programmatically generated interpolators. They cover an additional
case which was missed and should be slightly more efficient.

- Support linear interpolation for 16-bit mixers.

- Add cubic interpolation for mixers (off by default).

- Fix potential deadlock in stop_voice for OpenAL.

- Fix potential deadlock in stop_voice for DirectSound.

- Improve buffer filling behaviour for DirectSound, reducing pops and
crackles significantly on slower machines.

- Increase default buffer size for DirectSound to 8192 samples.

- Fix setting the speed of an audio stream after it was attached to the mixer.

Native dialogs addon:

- Do not unload of rich edit module when closing one text log window while
another exists. Reported by URB753.

- Use default colours for Windows text log implementation, avoiding problems
when the previous custom colours failed, leading to black text on a
nearly black background.

Build system:

- Install pkg-config files when cross-compiling on Unix.


- ex_synth: Add button to save waveform to a file.

- ex_multisample: Demonstrate using moving bitmaps.

- speed: Avoid poor performance due to needless redraws.

- Renamed a5teroids to Cosmic Protector


- Many minor bug fixes.

- Various documentation updates.

9c45d1b60bfe3d6fe4192efdc188dbe5  allegro-
899a7d576afd18442a68063e56b06bd9  allegro-5.0.8.tar.gz


Well done, and many thanks to you all for your time and effort in improving Allegro.

Arthur Kalliokoski

So as an even-numbered library, this is not a WIP, and should be used at a minimum for all new development, right?

Peter Wang

Yes, it's the stable branch.

Btw, I just thought of a problem with this change:


- Don't generate DISPLAY_LOST events when resizing a fullscreen display.

(This is d3d-specific; should have mentioned it.) Without a DISPLAY_LOST event the user may not know to recreate non-preserved textures. Perhaps the correct change is actually to generate the LOST event, then synthesize a FOUND event, which otherwise doesn't exist.

Arthur Kalliokoski

I got around to playing with it, and when I tried the ex_multiwin example, I tried resizing one of the windows, and it was altering the images in the other window. Resizing the other window had no effect on the first window. Is it supposed to do that?

Michał Cichoń

Michał: Do you also have updated dependencies? (Specifically, the ones I have include no mingw 4.7... which seems to not matter, but in case your scripts auto-generate the dependencies .zip anyway...).

André Silva

Thanks for the Windows builds, Michał. Unfortunately, the VS10 one doesn't have the bin folder...

Anyway, regarding the update itself, if I read correctly, it corrected a problem I had: my audio streams started suddenly freezing when I tried changing their playing speed, something that didn't use to happen circa A5.0.5.

Congrats to everyone involved. Keep up the excellent work! ;D

EDIT: Yeah, Allegro 5.0.8 fixed the al_set_audio_stream_speed issue.

Michał Cichoń

What? I will re-do. Done.
Elias: Dependencies are available too. See post above.


Thanks! Really useful when I want to test git under Windows :)

Peter Wang

I tried resizing one of the windows, and it was altering the images in the other window. Resizing the other window had no effect on the first window. Is it supposed to do that?

Nope. OS and other details, please?

Arthur Kalliokoski

Slackware 14.0 64 bit
gcc 4.7.1
Gforce 8400 GS
4 gigs ram


It seems that the resizing is limited to a clipping rectangle of the size of the other window.


Added the CMakeCache.txt I'd used.

Peter Wang

Huh. How did no one notice it for that long. git bisect says:


e389dd0b5d2f493c978c398d630a46bf29712087 is the first bad commit
commit e389dd0b5d2f493c978c398d630a46bf29712087
Author: Paul Suntsov <>
Date: Sun Nov 6 00:43:09 2011 +0000

Don't re-bind the FBO in al_set_target_bitmap if the new target bitmap shares the parent bitmap with the new target bitmap. Results in 5x speedup of the function in that case, which might help sub-standard drivers


The bug doesn't manifest itself (any more) on the 5.1 branch, so it should be easy enough to fix.


Thank you! :)


There are some warnings of deprecated function calls for OSX (10.8). See attached.


Thanks. I've been away from coding for a while but I hope to get back to Allegro soon.


I am using 4.7.1 TDM MinGW32 compiler (windows 7 64bit, code::blocks IDE). Will the prebuilt 4.7 MinGW work for this compiler? Thanks in advance, I am a rookie with this sort of thing. Been meaning to build the previous release, but just havent had time with my schooling to dedicate to learning how to get that done.

Thanks in advance.


Seems to work for me, and I am running gcc 4.7.2

Joachim Arting

Kinda funny, since I just now had a problem with al_map_rgb causing my program to crash. I could not see anything in the code that would indicate why.
Updated to 5.0.8 and now it's all good.
Must have been an incompatibility with GCC 4.7.2 and Allegro 5.0.7
Great update, keep it up! :)

Sebastian Steinhauer

Hey guys!

Thanks for all you work you've done. I really love Allegro 5 and it's a pleasure to use it for making some (never releasing *g) games.

Keep coding!!

Mark Oates

Sweet. 8-)



Alright, who caved!? >:(


Must have been an incompatibility with GCC 4.7.2 and Allegro 5.0.7

I'm having problems too.




Thread #611458. Printed from