PLAYMOVIE supported formats?

Previous topic - Next topic

tomrow

I am trying to make a program that sequentially plays movie files. These files are stored as MPG files with MPEG2 encoding. I was able to get a file to play, but only once. Playing any other files, even after closing and restarting the compiled EXE will result in a black screen, and no video being played back.
The only video I have successfully played back multiple times was a small 32x32 AVI animation ripped from a system file of Windows XP. I have not been able to determine the codec of this file. Does anyone have any better luck with another file format and codec, or a way to fix MPG playback?

dreamerman

hm.. don't get me wrong, as GLB is rather game programming language I would consider such feature like playing movies only for intro or something like this.
Not sure in what container (mpeg, mp4, avi, mkv, mov) and what codec (mpeg2, x264 and so on) should file use to be playable, tried few file that were on hand without a luck. If You want to know exactly what combination of container/codecs are used in some file get any advanced video player, best would be VLC and open that file, got to tools - info about codec. And pls share result's this may be helpfull ;-)
Check my source code editor for GLBasic - link Update: 20.04.2020

tomrow

I've opened up the successful AVI file in VLC which determined that the codec was "Microsoft RLE Video". This is not ideal since it only supports 256 colors for the video at once.

I don't know how I didn't notice, but there is a sample program demonstrating PLAYMOVIE, that plays back a video of someone tapping the screen of an unidentified handheld game system. This WMV 9 file seems to work every time, so I will try using WMV and see if it works.

tomrow

Sadly I've had no luck with the formats I've tried. I've tried MOV, MPG, AVI and WMV, with no luck. I'm quite disappointed with the results here as it seems like a very basic feature with little to go wrong. Perhaps the videos have to be a specific frame rate, sadly though I don't have the capabilities of testing this.

SnooPI

I confirm this bug.

As I see that you are new Tomrow, I take this opportunity to welcome you  :booze:


erico

Shouldn´t the likes of .mov with h264+acc video be standard on every >win7 box?
I haven´t tested such though.

tomrow

Thank you!



Quote from: erico on 2020-Apr-29
Shouldn´t the likes of .mov with h264+acc video be standard on every >win7 box?
I haven´t tested such though.
I would have thought so too, I tried a MOV with MPEG2 (like DVD) encoding and it played the sound portion of the video but with no picture.
MP4 files seem to be skipped entirely and the program is resumed without any user input, even when using LOOPMOVIE.

I have run some more tests and I have found that Uncompressed AVI files generated with the freeware preactivated version of HyperCam 2 (it became freeware in 2010) seem to work without issue when recording at 10 frames/second. I will test with different settings with this software and see what works.


dreamerman

Looks that PlayMovie is only Win32 and iOS? So not sure if that's best solution. On windows MCI command are used, maybe something needs to be updated, but there is a other solution, using c++ with ffmpeg libraries. Yet You would need to write a little inline code for that, not sure if You would be interested but here is a good example: https://github.com/bartjoyce/video-app
Check my source code editor for GLBasic - link Update: 20.04.2020

spacefractal

#8
the best case is property use a internal browser on a new Intent (similar way how ads works). its something im have newer looked into or used that.

Etc the PlayMovie might require a javacall to open the browse and then shown the internal url. Howover movies is big and dont want to copy the whole file to internal memory first. This can also been a issue with its self.

on Glbasic, we dont have direcly access to the media files, required to been extractly from the apk first.
Genius.Greedy Mouse - Karma Miwa - Spot Race - CatchOut - PowerUp Elevation - The beagle Jam - Cave Heroes 2023 - https://spacefractal.itch.io/