I'm using love2d v 11.4 (built on windows using megasource) and have some weird issue with play() method of a video.
The code is so simple, IDK whether I'm dumb or blind:
Code: Select all
if not video:isPlaying() then
video:seek(0)
video:play()
end
isPlaying reports things just fine, seek(0) works as well, but the video doesn't start to play.
Now, if you're wondering, I'm trying to loop a short video.
The one in the demo is less than 2 seconds in length, so it's doubtful it somehow hogs the memory or is too big to be manipulated quickly.
I've attached a demo project to illustrate the issue.
Does anyone have any ideas?
Edit
I tried different ways to encode the OGV file and it's gotten even weirder.
FFmpeg 4.2 produces a bigger file and corrupts it with artifacts (colored squares all over the video).
FFmpeg 4.4 produces smaller file and the video is just fine.
But the "corrupted" file *does* loop, whereas the "clean" one doesn't.
The command I've used to encode the video looks like this:
Code: Select all
./ffmpeg -i bgv1.mp4 -c:v libtheora -q:v 10 -c:a libvorbis -q:a 5 bgv1.ogv
According to ffprobe, the only difference is "Lavc58.54.100 libvorbis" in 4.2 VS "Lavc58.134.100 libvorbis" in 4.4 (well, and the bitrate)