![]() |
|
How to fix loading videos from zip that is in a path? |
tinyBigGAMES
Member #17,458
February 2020
![]() |
This still does not seem to be working. If the videos are located in the root of the archive, they will load and play just fine. However if they are located in a path such as this: "videos/myvideo.ogv", it will fail to load. I have all the resources organized in folders inside the archive. All other resources seem to not suffer from this problem. How/where can this be fixed? Jarrod Davis |
Edgar Reynaldo
Major Reynaldo
May 2007
![]() |
Show code and provide a minimal example that demonstrates this please. Please also update to latest allegro and physfs and zlib before testing. 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 |
tinyBigGAMES
Member #17,458
February 2020
![]() |
1procedure test03;
2var
3 display: PALLEGRO_DISPLAY;
4 video: PALLEGRO_VIDEO;
5begin
6 al_init;
7 al_init_video_addon;
8
9 PHYSFS_init(nil);
10 PHYSFS_mount('archive.zip', '', 1);
11
12 display := al_create_display(480, 600);
13 al_set_window_title(display, 'video test');
14 al_clear_to_color(al_map_rgba(32,32,32,255));
15
16 al_set_physfs_file_interface;
17
18 // if video is in root of archive, works
19 video := al_open_video('presents.ogv');
20
21 // if video is off a path, fails
22 video := al_open_video('arc/videos/presents.ogv');
23
24 al_close_video(video);
25 al_destroy_display(display);
26
27 PHYSFS_deinit;
28
29end;
Jarrod Davis |
Edgar Reynaldo
Major Reynaldo
May 2007
![]() |
And, what versions of allegro, physfs, and zlib are you using? 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 |
tinyBigGAMES
Member #17,458
February 2020
![]() |
The latest build of Allegro, 5.2.6.0. What ever versions that are inside that DLL. I'm using Delphi. For the record, this did not work with the prev version of Allegro either. I'm using the monolith dll from: allegro-i686-w64-mingw32-gcc-9.2.0-posix-dwarf-static-5.2.6.0.zip Jarrod Davis |
SiegeLord
Member #7,827
October 2006
![]() |
I tried it on Linux, and it seemed to work okay. I did: PHYSFS_init(argv[0]); PHYSFS_mount("/home/siege/src/A5/video_zip.zip", NULL, 1); al_set_physfs_file_interface(); al_open_video("video/test.ogv"); I'll try the Windows binaries tomorrow, maybe the packages are broken somehow. "For in much wisdom is much grief: and he that increases knowledge increases sorrow."-Ecclesiastes 1:18 |
tinyBigGAMES
Member #17,458
February 2020
![]() |
could it be this line in ogv.c: looking around the src, I see this: Then I found this: Could all it be is need to remove ALLEGRO_NATIVE_PATH_SEP? I don't currently have things setup to build allegro to test this. Last time I tried, phew, it was a task. UPDATE: Jarrod Davis |
SiegeLord
Member #7,827
October 2006
![]() |
Nice, that's exactly the issue, thanks for investigating. Sorry for your troubles compiling! I could reproduce this on Windows, but we'll do a different fix since this is a wider problem: https://github.com/liballeg/allegro5/pull/1118 "For in much wisdom is much grief: and he that increases knowledge increases sorrow."-Ecclesiastes 1:18 |
tinyBigGAMES
Member #17,458
February 2020
![]() |
NICE! Thanks for the fix. I've pulled it down, recompiled and can confirm all works as expected. Thanks again, to all that helped with this. Jarrod Davis |
|