Allegro.cc - Online Community

Allegro.cc Forums » Allegro Development » Allegro 4.9.20 released

This thread is locked; no one can reply to it. rss feed Print
Allegro 4.9.20 released
Peter Wang
Member #23
April 2000

aka. Allegro 5.0 beta 1

Probably what that means is "we'll try harder not to break your stuff from now on".

http://sourceforge.net/projects/alleg/files/allegro-unstable/4.9.20/

Quote:

Changes from 4.9.19 to 4.9.20 (May 2010)
========================================

The developers this time were: Thomas Fjellstrom, Evert Glebbeek,
Matthew Leverton, Milan Mimica, Paul Suntsov, Trent Gamblin, Elias Pschernig,
Peter Wang. With significant contributions from Michał Cichoń.

Core:

- Add al_malloc, al_free, et al. These are now used consistently throughout
Allegro and its addons.

- Replace al_set_memory_management_functions by a simpler function,
al_set_memory_interface.

- Renamed some D3D/Windows specific functions to follow the al_{verb}_{stuff}
convention.

Graphics:

- Move image I/O framework to core, i.e. al_load_bitmap, al_save_bitmap and
bitmap file type registration. Image codecs remain in allegro_image.

- Added a simple display capabilities querying capability to
al_get_display_option: ALLEGRO_MAX_BITMAP_SIZE, ALLEGRO_SUPPORT_NPOT_BITMAP,
ALLEGRO_CAN_DRAW_INTO_BITMAP, ALLEGRO_SUPPORT_SEPARATE_ALPHA.
(OpenGL only for now)

- Fix in OpenGL 3.0 context creation.

- Make the extensions mechanism compatible with OpenGL version >= 3.
Declared symbols needed by OpenGL 3.2 and 3.3 and brought OpenGL extensions
up to date.

- Fix an assertion in _al_draw_bitmap_region_memory so it does not trigger
when source and destination are the same bitmap.

- Fix some locking issues by setting GL_PACK_ALIGNMENT and GL_UNPACK_ALIGNMENT
before reading/writing pixels.

- Partial implementation of ALLEGRO_FULLSCREEN_WINDOW on OS X (Snow Leopard,
probably Leopard).

- Started X11 fullscreen support (resolution switching).

- Fix handling of X11 size hints.

- Fixed a deadlock related to fullscreen windows under X11 caused by using a
nested lock for a condition variable.

- Use _NET_WM_ICON to set icon on X11 instead of XSetWMHints.

- Get the iPhone OpenGL version more properly. Only use separate blending on
iPhone with OpenGL ES 2.0+.

- Release the splash view and windows on iPhone, which makes backgrounding
Allegro apps on OS 4.0 work.

- Updated iphone port for IPad (only tested in the simulator).

Input:

- Disabled Raw Input code in Windows. Mouse events now reflect system cursor
movements even in fullscreen mode.

- Prevent late WM_MOUSELEAVE notifications from overriding mouse state display
field (Windows).

- Update pollable mouse state with axes events as well as button events on
iPhone.

Filesystem:

- Made the filesystem entry functions work under Windows even if the name
passed to al_create_fs_entry has a trailing slash or backslash.

Config routines:

- Add al_{load,save}_config_file_f.

- Reorder al_save_config_file* arguments to match al_save_bitmap and
al_save_sample.

- Optimise config routines to work well for thousands of keys/sections.

Image addon:

- Added a GDI+ implementation of the image codecs, which will be used in
favour of libjpeg/libpng if Allegro is compiled with MSVC. Then
allegro_image will not require JPEG/PNG DLLs at runtime.

- Removed format specific image functions.

- Fixed bug in native png loader on iphone: was using the source color space
instead of the target color space which made it fail whenever they differed
(alpha-less paletted pictures).

- Add an autorelease pool around iphone native image loading to stop memory
leaks.

Font addons:

- Sever the tie between allegro_font and allegro_image.
The user needs to initialise the image addon separately now.

- Rename al_load_ttf_font_entry to al_load_ttf_font_f.

- Fixed problem with glyph precision after applying transformations in the ttf
addon.

Primitives addon:

- Added al_init_primitives addon function. This is now required.

- Removed ALLEGRO_PRIM_COLOR; ALLEGRO_COLOR can now be used where it was
required.

- v textures coordinates were off for OpenGL non-power-of-two textures.

- Free the vertex cache in al_destroy_display on X11.

- Added the dummy vertex shader support to D3D driver of the primitives addon.
Without this, custom vertices either resulted in warnings or outright
crashes on some systems.

- Bring D3D driver up to speed a little bit: transformations now work properly
with sub-bitmap targets; the half-pixel offset now properly interacts with
transformations; al_set_target_bitmap does not clear the transformation; the
proper transformation is set at display creation.

- Cull the primitives that are completely outside the clipping region.

- Scale the numbers of vertices for the curvy primitives with the scale of the
current transformation.

Audio addon:

- Remove driver parameter from al_install_audio.

- Rename al_get_depth_size to al_get_audio_depth_size.

- Rename al_get_audio_stream_buffer to al_get_audio_stream_fragment.

- Many improvements to AQueue driver.

Audio codecs:

- Add MOD/S3M/XM/IT file support, using the DUMB library.

- Revert to a monolithic allegro_acodec addon, i.e. remove separate
allegro_flac, allegro_vorbis addons. WAV file support is in allegro_acodec.

- Implement DLL loading for FLAC/Vorbis/DUMB on Windows. allegro_acodec will
load the DLL at runtime to enable support for that format. If your program
does not require said format, you don't need to distribute the DLL.

- Remove format-specific loader/saver audio codec functions.

- Make acodec loaders have consistent file closing behaviour.

- Optimised wave file loading.

Examples:

- Make SPEED port run acceptably on graphics drivers without FBOs.

Documentation:

- Added documentation for the public Direct3D specific functions.

- Documented ALLEGRO_OPENGL_3_0 and ALLEGRO_OPENGL_FORWARD_COMPATIBLE.

Other:

- Many bug and documentation fixes.

Neil Walker
Member #210
April 2000
avatar

That's a lot of stuff. Good show.

Quote:

- Added a GDI+ implementation of the image codecs, which will be used in
favour of libjpeg/libpng if Allegro is compiled with MSVC. Then
allegro_image will not require JPEG/PNG DLLs at runtime.

Is this not a backward step in terms of performance and reliance on Windows GDI+ being the same across different platforms?

Neil.
MAME Cabinet Blog / AXL LIBRARY (a games framework) / AXL Documentation and Tutorial

wii:0356-1384-6687-2022, kart:3308-4806-6002. XBOX:chucklepie

Peter Wang
Member #23
April 2000

Is there reason to think that's a problem?

Matthew Leverton
Supreme Loser
January 1999
avatar

Is this not a backward step in terms of performance and reliance on Windows GDI+ being the same across different platforms?

GDI+ is used to load and save images. It has nothing to do with run time drawing performance.

And yes, there's the possibility that a JPEG image will work on GDI+ and not libjpeg (or vice versa), but that's not likely to be an issue, especially as you control your media files.

AMCerasoli
Member #11,955
May 2010
avatar

It would be good more information about the iPhone library...

kenmasters1976
Member #8,794
July 2007

Great!. Downloading.

[EDIT:] Got some warnings building on Windows with MinGW, gcc 3.4.5. No big deal. Just in case the devs want to fix it.

G:\allegro-4.9.20\src\win\d3d_bmp.cpp: In function `void d3d_blit_real(ALLEGRO_BITMAP*, float, float, float, float, float, float, float, float, float, float, float, int, bool)':
G:\allegro-4.9.20\src\win\d3d_bmp.cpp:731: warning: passing `float' for converting 1 of `virtual HRESULT IDirect3DDevice9::CreateOffscreenPlainSurface(UINT, UINT, D3DFORMAT, D3DPOOL, IDirect3DSurface9**, void**)'
G:\allegro-4.9.20\src\win\d3d_bmp.cpp:731: warning: passing `float' for converting 2 of `virtual HRESULT IDirect3DDevice9::CreateOffscreenPlainSurface(UINT, UINT, D3DFORMAT, D3DPOOL, IDirect3DSurface9**, void**)'
G:\allegro-4.9.20\src\win\d3d_bmp.cpp:738: warning: converting to `LONG' from `float'
G:\allegro-4.9.20\src\win\d3d_bmp.cpp:739: warning: converting to `LONG' from `float'
G:\allegro-4.9.20\src\win\d3d_bmp.cpp:740: warning: converting to `LONG' from `float'
G:\allegro-4.9.20\src\win\d3d_bmp.cpp:741: warning: converting to `LONG' from `float'
G:\allegro-4.9.20\src\win\d3d_bmp.cpp:749: warning: converting to `LONG' from `float'
G:\allegro-4.9.20\src\win\d3d_bmp.cpp:750: warning: converting to `LONG' from `float'
G:\allegro-4.9.20\src\win\d3d_bmp.cpp:751: warning: converting to `LONG' from `float'
G:\allegro-4.9.20\src\win\d3d_bmp.cpp:752: warning: converting to `LONG' from `float'

[EDIT 2:] Looks like we have this bug again:

{"name":"601415","src":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/b\/a\/ba54058c02bcc34089a5cea2b4f4ee6f.png","w":648,"h":672,"tn":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/b\/a\/ba54058c02bcc34089a5cea2b4f4ee6f"}601415

It seems to be present only when using D3D. Can someone confirm it?. As before, drawing thick primitives works fine; it only appears when thickness is 0.

al_init_primitives_addon() is new, right?. Either that or I've been skipping it all this time.

SiegeLord
Member #7,827
October 2006
avatar

Quote:

- Added al_init_primitives addon function. This is now required.

Yes, it's new.

And I'll look into this bug this evening. Does ex_prim work for you by the way? I changed some things that may have broken the addon for older Intel cards again...

EDIT:
But of course, how could I forget... it's the same problem as before, I just forgot exactly how much Intel cards suck...

"For in much wisdom is much grief: and he that increases knowledge increases sorrow."-Ecclesiastes 1:18
[SiegeLord's Abode][Codes]:[DAllegro5]:[RustAllegro]

kenmasters1976
Member #8,794
July 2007

SiegeLord said:

Yes, it's new.

Should have read the changelog more carefully.

Quote:

Does ex_prim work for you by the way? I changed some things that may have broken the addon for older Intel cards again...

Yes, it works just as before. And by that I mean... the Indexed Primitives tests seem broken and framerate drops in the Custom Vertex Format test but it has always been like that and since these are advanced features, I wouldn't expect for them to be implemented for low end cards, seriously. That's why I never reported it as a bug or anything.

All other tests work fine. And seriously, just a note in the documentation indicating that Indexed Primitives aren't guaranteed to work on low end cards should be enough.

This is how the Indexed Primitives tests look:
{"name":"601418","src":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/a\/6\/a6543c74d5d0876f5b8c2e0510f834c2.png","w":811,"h":634,"tn":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/a\/6\/a6543c74d5d0876f5b8c2e0510f834c2"}601418

[EDIT:] Oh, also, I just checked with OpenGL (never did it before) and all tests work fine. The Indexed Primitives tests display correctly and framerate doesn't suffer as much in the Custom Vertex Format test.

SiegeLord
Member #7,827
October 2006
avatar

I'll add a fix making indexed primitives work for your card. It obviously won't be as fast as if they were supported natively, but the performance hit should be minimal.

The custom vertex one is slow because I made it fall back to software drawing for older cards.

"For in much wisdom is much grief: and he that increases knowledge increases sorrow."-Ecclesiastes 1:18
[SiegeLord's Abode][Codes]:[DAllegro5]:[RustAllegro]

kenmasters1976
Member #8,794
July 2007

Oh, OK. Everything's perfect then.

SiegeLord
Member #7,827
October 2006
avatar

Okay, should be fixed in Rev. 13356. Sorry that I keep breaking the addon on your card like every time I do something :-/

"For in much wisdom is much grief: and he that increases knowledge increases sorrow."-Ecclesiastes 1:18
[SiegeLord's Abode][Codes]:[DAllegro5]:[RustAllegro]

kenmasters1976
Member #8,794
July 2007

Fine, I'll check the latest revision.

SiegeLord said:

Sorry that I keep breaking the addon on your card like every time I do something :-/

Sorry for keeping you fixing the addon just for me... who else can be running on such ancient hardware?.

Dario ff
Member #10,065
August 2008
avatar

Actually, the primitives addon stopped showing textured primitives here as well, so I guess I'll update to the latest revision too.

TranslatorHack 2010, a human translation chain in a.cc.
My games: [GiftCraft] - [Blocky Rhythm[SH2011]] - [Elven Revolution] - [Dune Smasher!]

kenmasters1976
Member #8,794
July 2007

Dario ff said:

Actually, the primitives addon stopped showing textured primitives here as well...

Textured primitives work fine on my machine on 4.9.20. The problem is only with Indexed Primitives.

I haven't tried the latest SVN as my usual source for SVN revisions is Thomas Fjellstrom's SVN Snapshots page.

Thomas Fjellstrom
Member #476
June 2000
avatar

I haven't tried the latest SVN as my usual source for SVN revisions is Thomas Fjellstrom's SVN Snapshots page.

Sorry that it hasn't updated in a couple days, it seems the vm had a fit and the root fs remounted read-only. Fixing it now.

The fs actually seems to be quite badly corrupted. :o

append: Its back up, hopefully nothing is damaged :o

--
Thomas Fjellstrom - [website] - [email] - [Allegro Wiki] - [Allegro TODO]
"If you can't think of a better solution, don't try to make a better solution." -- weapon_S
"The less evidence we have for what we believe is certain, the more violently we defend beliefs against those who don't agree" -- https://twitter.com/neiltyson/status/592870205409353730

Dario ff
Member #10,065
August 2008
avatar

Upgraded to the latest SVN. The problems with some primitives were fixed... but the textured primitives don't work anymore. :-/
{"name":"601427","src":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/f\/e\/fe577a498c3eb97f1d2806f65fd13c42.jpg","w":801,"h":605,"tn":"\/\/djungxnpq2nug.cloudfront.net\/image\/cache\/f\/e\/fe577a498c3eb97f1d2806f65fd13c42"}601427

My specs have been always the same:

  • Windows XP SP3

  • AMD Athlon X2 2.7GHZ Black Edition

  • NVidia Geforce 8600 GT 512MB DDR2

TranslatorHack 2010, a human translation chain in a.cc.
My games: [GiftCraft] - [Blocky Rhythm[SH2011]] - [Elven Revolution] - [Dune Smasher!]

SiegeLord
Member #7,827
October 2006
avatar

You've posted the correct output of ex_prim... and are saying that they don't work anymore?

Try pressing 'S' in that (and any other) screen. If the output does not change appreciably, then all is well.

"For in much wisdom is much grief: and he that increases knowledge increases sorrow."-Ecclesiastes 1:18
[SiegeLord's Abode][Codes]:[DAllegro5]:[RustAllegro]

Dario ff
Member #10,065
August 2008
avatar

Oh, sorry. It seems I forgot how the example worked. :-/ I isolated the code and it worked fine, but for some reason, it isn't working anymore in my game? I'm sorry for the inconvenience. >_< I'll have to debug it a bit more.

EDIT: I don't really know what could be messing with it. Drawing without a texture doesn't work. If I isolate the example, it works alright... What could've changed lately to do this? ??? There's surely no memory overwriting at all, but something did change.

TranslatorHack 2010, a human translation chain in a.cc.
My games: [GiftCraft] - [Blocky Rhythm[SH2011]] - [Elven Revolution] - [Dune Smasher!]

SiegeLord
Member #7,827
October 2006
avatar

Are you using OpenGL or Direct3D? One big change that affected both was the changing of the color type. In 4.9.19 it was 4 bytes, while now it is 4 floats. Most other changes affected Direct3D only, however.

"For in much wisdom is much grief: and he that increases knowledge increases sorrow."-Ecclesiastes 1:18
[SiegeLord's Abode][Codes]:[DAllegro5]:[RustAllegro]

Dario ff
Member #10,065
August 2008
avatar

I'm using OpenGL.

Before doing anything, I've found some other strange problems. I must compare some things in both .9.19 and .9.20, testing both drivers and etc. I'm sorry for bringing a possible false alarm. :-/

TranslatorHack 2010, a human translation chain in a.cc.
My games: [GiftCraft] - [Blocky Rhythm[SH2011]] - [Elven Revolution] - [Dune Smasher!]

Evert
Member #794
November 2000
avatar

Dario ff said:

I'm sorry for bringing a possible false alarm.

Hey, don't worry about it.
It's better that we have a false bug report than that people don't test things before we release 5.0! :)

kenmasters1976
Member #8,794
July 2007

Thanks, Thomas Fjellstrom. I've updated to r13356 now and, SiegeLord, I can confirm that ex_prim is working perfectly now on my machine, Indexed Primitives and all.

Dario ff
Member #10,065
August 2008
avatar

Ok, I'm sorry, it seems I panicked because it turned out, the D3D driver wasn't being set really. (Again with an stupid problem of mine)

The problem was that a lot of weird behaviour appeared when using the D3D driver in Arkab. Luckily, the same thing occurs in both .9.19 and .9.20, so I guess it has nothing to do with a problem on this update, but rather an old problem of mine that I never seen because the D3D driver wasn't being used at all.

The problem turned out to be the following. I'm using cgD3D9BindProgram to apply the CG shader. For clearing the usage of any shaders, I use cgD3D9BindProgram(NULL). Calling the latter only doesn't have any effect whatsoever, but setting an own fragment shader program with the former, produces all kinds of weird behaviour on Allegro5. The most noticeable was ignoring Alpha channels completely, which kind of panicked me. Even calling cgD3D9BindProgram(NULL) after it won't fix the problem either. :-/

I don't really know what to do with this. :-/

TranslatorHack 2010, a human translation chain in a.cc.
My games: [GiftCraft] - [Blocky Rhythm[SH2011]] - [Elven Revolution] - [Dune Smasher!]

Karadoc ~~
Member #2,749
September 2002
avatar

I just got the latest version from svn. It compiled and installed without complaining.

I didn't test everything, but I have encountered a few problems.

The a5teroids demo doesn't work. It says "Error loading sample C:/Programming/allegro5/build/demos/a5teroids/data/sfx/big_explosion.ogg". big_explosion.ogg is where it says it is looking for it, and it plays ok in winamp.

The following example programs didn't seem to do anything at all: ex_audio_props, ex_audio_simple, ex_acodec, ex_acodec_multi.

ex_draw seems to have "circles" and "filled circles" the wrong way around; (and some of what is drawn is slightly different for hardware vs software, but this is probably to be expected).

ex_fs_resize goes into full screen mode with a picture, but then crashes when I press space or esc. (program has stopped working, inform microsoft etc.)

ex_draw_bitmap says that there is error loading data/mysha256x256.png.

ex_drawpixels seems to work alright, but it doesn't exit when I press the close button. It only exits when I press esc.

That's all I have to report for now. I hope that this information is useful.

-----------

Matthew Leverton
Supreme Loser
January 1999
avatar

The a5teroids demo doesn't work. It says "Error loading sample C:/Programming/allegro5/build/demos/a5teroids/data/sfx/big_explosion.ogg". big_explosion.ogg is where it says it is looking for it, and it plays ok in winamp.

Did you compile the Ogg Vorbis codec?

Quote:

The following example programs didn't seem to do anything at all: ex_audio_props, ex_audio_simple, ex_acodec, ex_acodec_multi.

Did you compile any audio codecs? (By the way, many of the console examples on Windows send their output to nowhere.)

Quote:

ex_draw_bitmap says that there is error loading data/mysha256x256.png.

Did you compile the PNG or GDI+ extension?



Go to: