|
|
| Allegro 4 game - Steam overlay |
|
Andrew Gillett
Member #15,868
January 2015
|
My Allegro 4 game is getting closer to completion, and I just started integrating the Steam SDK, but came across a problem. The Steam overlay does not work with games which use software rasterization. I'm writing a local multiplayer game, which would benefit enormously from Steam's Remote Play Together (a feature which didn't exist until a few months ago), but the overlay is required to use this. My first thought was that I would have to upgrade the whole game to Allegro 5, or perhaps SDL or Unreal Engine (I'm not that familiar with any of them). But I've just had the idea of using AllegroGL in Allegro 4 - I could create an OpenGL window, but use OpenGL only to copy the back buffer to the window – presumably that way, nothing else would need to change. Can anyone see any potential problems with this? One thing that just occurred to me is that the size of the back buffer would mean I would be displaying a non-power-of-two texture. I don't know how well this is supported by older graphics cards. |
|
Edgar Reynaldo
Major Reynaldo
May 2007
|
AllegroGL easily could be a solution, given Steam's requirement for 'hardware rasterization' on the Overlay. My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
|
Andrew Gillett
Member #15,868
January 2015
|
Have started working on using AllegroGL - first problem, when building with MSVC, no alleggl.lib is produced, only a PDB and DLL. This is the case even if I tell MSVC to build a static library. |
|
Edgar Reynaldo
Major Reynaldo
May 2007
|
Use Allegro 4.4.3+ GIT and CMake to build allegro 4. I have a build guide for MinGW here : My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
|
Peter Hull
Member #1,136
March 2001
|
It's been a while but - isn't AllegroGL part of Allegro 4 now? i.e. there isn't a separate lib to link to. Also, what does "games which use software rasterization" mean? Doesn't A4 use either DirectX or OpenGL to access the screen anyway?
|
|
Chris Katko
Member #1,881
January 2002
|
Peter Hull said: Also, what does "games which use software rasterization" mean? Doesn't A4 use either DirectX or OpenGL to access the screen anyway? I'm pretty sure Allegro4 requires DirectX headers... http://web.eng.fiu.edu/watsonh/EEL2880/Project/Exercise1.pdf You can get the window handle here, which is probably all Steam needs: https://liballeg.org/stabledocs/en/alleg037.html Quote:
win_get_dc — Retrieves a handle to the device context.
-----sig: |
|
Edgar Reynaldo
Major Reynaldo
May 2007
|
AllegroGL is part of Allegro, but it is still a separate addon library. Allegro 4 uses software rendering, except for the screen, which is always video memory. Normally, A4 uses DX, but the AllegroGL driver allows hardware accelerated drawing of video bitmaps which are normally memory. My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
|
Andrew Gillett
Member #15,868
January 2015
|
I previously built the version from Git using CMake and MSVC, which is when the issue with the missing lib file occurred. I tried following your instructions to build with MinGW, but when I try to build I get errors with the DirectX headers, e.g. "error: unknown type name '__deref_out'; did you mean 'SAL__deref_out'?". It's using the wrong DirectX headers. I added DSOUND_INCLUDE_DIR etc in CMake-GUI but these are removed when I click Generate. I'm curious as to why MSVC is not producing a lib file for AllegroGL. The build settings in the property pages are identical for allegro and allegrogl. |
|
Edgar Reynaldo
Major Reynaldo
May 2007
|
Andrew Gillett, this is why I hate MSVC. Which dependencies did you build before hand? Can you upload your CMakeCache.txt file after hitting 'generate' please? I will try to build from CMake GIT Allegro 443 and MSVS2017 and report back. EDIT My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
|
Andrew Gillett
Member #15,868
January 2015
|
CMakeCache.txt can be found here: You'll notice lines like this: DDRAW_INCLUDE_DIR:PATH=C:/Program Files (x86)/Microsoft DirectX SDK (February 2010)/Include These DirectX variables do not show up in the GUI. I did not build any of the other libraries as I don't need them. |
|
Edgar Reynaldo
Major Reynaldo
May 2007
|
When you run CMake, check the boxes for Advanced and Grouping. It should make those DX vars visible. As for building it, I get 4000 errors. And I haven't the faintest idea where to start. It's probably due to a SDK version error but I have no idea. As for linking, I can make *.lib files from *.dlls, and so can you. If I provide the .dll I made for Allegro 44X and the script I used, you should be able to create .lib files for each of them. My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
|
Andrew Gillett
Member #15,868
January 2015
|
I found the reason MSVC wasn't building a lib file for AllegroGL: ALLEGRO_GL_DYNAMIC was not set, hence it wasn't exporting anything. |
|
Edgar Reynaldo
Major Reynaldo
May 2007
|
You can reply now. My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
|
|