Video distortion/corruption on Raspberry Pi 3
Posted: Mon Feb 18, 2019 5:22 pm
I've created a game for a video art installation that is going to be displayed in a few days. And I'm running into the situation in which eventually the video always gets corrupted. I've attached a screen grab for illustration.
I've compiled love from the love-xxx-linux-src.tar.gz files in the bitbucket repo with configure and make. 11.0, 11,1 and 11.2 all show the same behavior.
Sometimes it will take a few hours but eventually it corrupts. Under high cpu load it can occur even after a few seconds.
This is the most basic code I can reproduce it with
The video is transcoded with
I can't attach it but I've uploaded it here: https://nofile.io/f/zxXuUQNAhJX/effort_7_ff.ogv
If anyone is able to help me solve this or work around it that would be really appreciated.
I've compiled love from the love-xxx-linux-src.tar.gz files in the bitbucket repo with configure and make. 11.0, 11,1 and 11.2 all show the same behavior.
Sometimes it will take a few hours but eventually it corrupts. Under high cpu load it can occur even after a few seconds.
This is the most basic code I can reproduce it with
Code: Select all
local love = love
local r = {}
function love.load(args)
love.window.setMode(1280, 720, {
vsync = false,
fullscreen = true,
fullscreentype = "exclusive",
})
r.intro_video = love.graphics.newVideo("video/effort_7_ff.ogv", { audio = true })
r.intro_video:play()
end
function love.update(dt)
if not r.intro_video:isPlaying() then
r.intro_video:rewind()
r.intro_video:play()
end
end
function love.draw()
local sw, sh = love.graphics.getDimensions()
if r.intro_video:isPlaying() then
local vw, vh = r.intro_video:getDimensions()
love.graphics.setColor(1, 1, 1)
love.graphics.draw(r.intro_video, 0, 0, 0, sw/vw, sh/vh)
end
end
Code: Select all
ffmpeg -i effort.mp4 -codec:v libtheora -qscale:v 7 -codec:a libvorbis -qscale:a 7 effort_7_ff.ogv
If anyone is able to help me solve this or work around it that would be really appreciated.