成功解决:Could not initialize SDL - No available video device (Did you set the DISPLAY variable?)

简介: 成功解决:Could not initialize SDL - No available video device (Did you set the DISPLAY variable?)

收集了以下方法,都试过,最终播放成功。


1、修改ffbuild目录下的config.mak

无效。


2、安装依赖库

apt-get install ia32-libs lib32stdc++6

无效。


3、安装依赖库

apt-get install grub-pc-bin

可能无效。


4、安装依赖库

apt-get install libsdl2-dev

因为吾是自己编译SDL,不确定是否有用。

如果没用,还是建议下载编译。具体参考:

https://blog.csdn.net/quantum7/article/details/104173159


5,配置DISPLAY

export DISPLAY=:0

这个不影响出错。配置成其他看不到画面(输出到别的地方了)。


**


有效解决办法(组合):

**

安装依赖库

sudo apt install xorg-dev

sudo apt build-dep xscreensaver totem vlc

sudo apt source xscreensaver totem -b


#is this OK?

#apt -y install xscreensaver totem vlc


重新编译SDL

绝对必要!

以下配置参数并无必要。

./configure --enable-video-x11 --enable-x11-shared --enable-video-x11-vm


配置PATH/LD_LIBRARY_PATH

这个不用多说。


重新运行ffplay

做完以上事情,再运行ffplay。怎么样?终于看到画面了吧。

目录
相关文章
|
1月前
|
JavaScript 前端开发 Python
成功解决:Can‘t find Python executable “python“, you can set the PYTHON env variable.
这篇文章分享了作者在运行前端Vue项目时遇到的关于Python执行环境的问题和解决方法。问题是由于找不到Python可执行文件导致的编译错误,解决方法包括安装编译环境、卸载并重新安装出现问题的`node-sass`包,并重新执行`npm install`和`npm run dev`。
成功解决:Can‘t find Python executable “python“, you can set the PYTHON env variable.
|
4月前
|
关系型数据库 MySQL
mysqldump unknown variable ‘set-gtid-purged=off‘ workbench
mysqldump unknown variable ‘set-gtid-purged=off‘ workbench
151 1
|
4月前
|
Python
gyp ERR! stack Error: Can‘t find Python executable “python“, you can set the PYTHON env variable.
gyp ERR! stack Error: Can‘t find Python executable “python“, you can set the PYTHON env variable.
133 1
|
Java Nacos 开发者
Nacos无法启动详解:Please set the JAVA_HOME variable in your environment, We need java(x64) jdk8 or later
Nacos无法启动详解:Please set the JAVA_HOME variable in your environment, We need java(x64) jdk8 or later
2582 1
关于 CMake编译出出现错误“Could not find compiler set in environment variable RC:” 的解决方法
关于 CMake编译出出现错误“Could not find compiler set in environment variable RC:” 的解决方法
关于 CMake编译出出现错误“Could not find compiler set in environment variable RC:” 的解决方法
|
开发工具 Android开发
Appium问题解决方案(7)- Could not find 'adb.exe' in PATH. Please set the ANDROID_HOME environment variable with the Android SDK root directory path
Appium问题解决方案(7)- Could not find 'adb.exe' in PATH. Please set the ANDROID_HOME environment variable with the Android SDK root directory path
519 0
Appium问题解决方案(7)- Could not find 'adb.exe' in PATH. Please set the ANDROID_HOME environment variable with the Android SDK root directory path
|
SQL 关系型数据库 MySQL
MySQL运行SQL:[ERR] 1231 - Variable ‘time_zone‘ can‘t be set to the value of ‘NULL‘
MySQL运行SQL:[ERR] 1231 - Variable ‘time_zone‘ can‘t be set to the value of ‘NULL‘
2188 0
|
关系型数据库 MySQL 数据库
MySQL 数据库mysqlbinlog使用问题:unknown variable ‘default-character-set=utf8‘.解决方法
MySQL 数据库mysqlbinlog使用问题:unknown variable ‘default-character-set=utf8‘.解决方法
339 0
|
人工智能 安全 Java
create PDF in console with no environment variable set
create PDF in console with no environment variable set
124 0