force vlc to load ui on raspberry booted to cli

柔情痞子 提交于 2019-12-12 05:38:07

问题


I've been googling for this all week, struggling to find a good solution.

I have a training video kiosk script that I've set up for my company, running on an intel NUC. to me, that feels like overkill, so I'm trying to get the script to run on a pi 3 model b to save a little on costs to deploy this thing.

my script works great from desktop, I've been able to get it to run on startup from the cli, & I can even load the videos with the dummy UI - the problem is that there's no sound, and when the video loads in the cli, it fills the screen with errors, then plays as text, like the picture below.

If I run it from desktop, it's fine (just really jittery)

is there a way to force vlc to load its interface without loading the desktop of raspian?

right now, when I call a video, the terminal line inputs like:

vlc-wrapper <file path> --play-and-exit --fullscreen -Idummy

video image


回答1:


got it to load the video

from command line:

X & vlc <filepath>

also got it to run from python

import os.subprocess
subprocess.call(['xinit', '--', '/usr/bin/vlc-wrapper, '<filepath>'])


来源:https://stackoverflow.com/questions/44185081/force-vlc-to-load-ui-on-raspberry-booted-to-cli

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!