VLC not rendering avc1/AAC audio

VLC could not decode the format "mp4a" (MPEG AAC Audio) Does not fully address my inquiries.

FIrst: Flatpak vlc installs at nearly 2GB and renders avc1 and aac audio, so this is not the issue… I want to eliminate flatpack and add codecs to use Clear Linux vlc.

Vlc installed with bundle-add, and apparently codecs are not supported for avc1 and aac audio due to patent issues, got that.

Additionally ffmpeg was installed from source.

Went to 3rd party site Clear Fraction and installed codec pack but Clear Linux version of vlc crashes when attempting to play .mp4 with avc1 and aac audio.

Clear Fraction install added following PATH info:

sudo swupd 3rd-party add clearfraction https://clearfraction.vercel.app/update
sudo mkdir -p /etc/environment.d /etc/profile.d
sudo tee -a /etc/environment.d/10-cf.conf << EOF
PATH=/usr/bin/haswell:/usr/bin:/usr/local/bin:/opt/3rd-party/bundles/clearfraction/bin:/opt/3rd-party/bundles/clearfraction/usr/bin:/opt/3rd-party/bundles/clearfraction/usr/local/bin
LD_LIBRARY_PATH=/usr/lib64:/opt/3rd-party/bundles/clearfraction/usr/lib64:/opt/3rd-party/bundles/clearfraction/usr/local/lib64
XDG_DATA_DIRS=/usr/share:/usr/local/share:/opt/3rd-party/bundles/clearfraction/usr/share:/opt/3rd-party/bundles/clearfraction/usr/local/share:/home/$USER/.local/share/flatpak/exports/share:/home/$USER/.local/share/flatpak/exports/share
XDG_CONFIG_DIRS=/usr/share/xdg:/etc/xdg:/opt/3rd-party/bundles/clearfraction/usr/share/xdg:/opt/3rd-party/bundles/clearfraction/etc/xdg
FONTCONFIG_PATH=/usr/share/defaults/fonts
GST_PLUGIN_PATH_1_0=/usr/lib64/gstreamer-1.0:/opt/3rd-party/bundles/clearfraction/usr/lib64/gstreamer-1.0
EOF

sudo tee -a /etc/profile.d/10-cf.sh << ‘EOF’
[[ ! ${PATH} =~ “/opt/3rd-party/bundles/clearfraction/bin” ]] &&
PATH=$PATH:/opt/3rd-party/bundles/clearfraction/bin:/opt/3rd-party/bundles/clearfraction/usr/bin:/opt/3rd-party/bundles/clearfraction/usr/local/bin

[[ ! ${LD_LIBRARY_PATH} =~ “/opt/3rd-party/bundles/clearfraction/usr/lib64” ]] &&
LD_LIBRARY_PATH=/usr/lib64:/opt/3rd-party/bundles/clearfraction/usr/lib64:/opt/3rd-party/bundles/clearfraction/usr/local/lib64${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}

[[ ! ${XDG_DATA_DIRS} =~ “/opt/3rd-party/bundles/clearfraction/usr/share” ]] &&
XDG_DATA_DIRS=${XDG_DATA_DIRS:-/usr/local/share/:/usr/share/}:/opt/3rd-party/bundles/clearfraction/usr/share/:/opt/3rd-party/bundles/clearfraction/usr/local/share/

[[ ! ${XDG_CONFIG_DIRS} =~ “/opt/3rd-party/bundles/clearfraction/usr/share/xdg” ]] &&
XDG_CONFIG_DIRS=${XDG_CONFIG_DIRS:-/usr/share/xdg:/etc/xdg}:/opt/3rd-party/bundles/clearfraction/usr/share/xdg:/opt/3rd-party/bundles/clearfraction/etc/xdg

[[ ! ${FONTCONFIG_PATH} =~ “/usr/share/defaults/fonts” ]] &&
FONTCONFIG_PATH=/usr/share/defaults/fonts${FONTCONFIG_PATH:+:$FONTCONFIG_PATH}

[[ ! ${GST_PLUGIN_PATH_1_0} =~ “/opt/3rd-party/bundles/clearfraction/usr/lib64/gstreamer-1.0” ]] &&
GST_PLUGIN_PATH_1_0=${GST_PLUGIN_PATH_1_0:-/usr/lib64/gstreamer-1.0}:/opt/3rd-party/bundles/clearfraction/usr/lib64/gstreamer-1.0
EOF

Am I missing something?

Can the stock Clear Linux vlc install be made to render .mp4 avc1 video and aac audio?

Am I missing configuration changes necessary?

Any help appreciated.

Thank you.

Add Clear Fraction repository and install codecs bundle, then you will be able to play .mp4 & .m4a and other files using Mpv player.

Here is what happend with codecs package installed and mpv:

mpv ‘/video/Steel Truss Calculations_formulas.mp4’
(+) Video --vid=1 () (h264 426x240 30.000fps)
(+) Audio --aid=1 (
) (aac 2ch 44100Hz)
File tags:
Title: Steel Truss Calculation - The easy formulas you need to use
[vo/gpu/drm] VT_GETMODE failed: Inappropriate ioctl for device
[vo/gpu/drm] Failed to set up VT switcher. Terminal switching will be unavailable.
[vo/gpu/drm] Failed to acquire DRM master: Permission denied
[vo/gpu/drm] Failed to commit ModeSetting atomic request: Permission denied
[vo/gpu/opengl] Failed to set CRTC for connector 95: Permission denied
[vo/gpu] Failed to commit atomic request: Permission denied
[vo/gpu/drm] Failed to commit ModeSetting atomic request: Permission denied
[vo/gpu/drm] Failed to restore previous mode
[vo/gpu/drm] Failed to drop DRM master: Permission denied
[vo/gpu-next/drm] Can’t handle VT release - signal already used
[vo/gpu-next/drm] Failed to set up VT switcher. Terminal switching will be unavailable.
[vo/gpu-next/drm] Failed to acquire DRM master: Permission denied
[vo/gpu-next/drm] Failed to commit ModeSetting atomic request: Permission denied
[vo/gpu-next/opengl] Failed to set CRTC for connector 95: Permission denied
[vo/gpu-next] Failed to commit atomic request: Permission denied
[vo/gpu-next/drm] Failed to commit ModeSetting atomic request: Permission denied
[vo/gpu-next/drm] Failed to restore previous mode
[vo/gpu-next/drm] Failed to drop DRM master: Permission denied
Error opening/initializing the selected video_out (–vo) device.
Video: no video

Exiting… (Errors when loading file)

and:

sudo mpv ‘/video/Minivan Takes A Bad Turn.mp4’
(+) Video --vid=1 () (h264 426x240 29.970fps)
(+) Audio --aid=1 (
) (aac 2ch 44100Hz)
File tags:
Title: Minivan Takes A Bad Turn
error: XDG_RUNTIME_DIR is invalid or not set in the environment.
[vo/gpu/drm] VT_GETMODE failed: Inappropriate ioctl for device
[vo/gpu/drm] Failed to set up VT switcher. Terminal switching will be unavailable.
[vo/gpu/drm] Failed to acquire DRM master: Device or resource busy
[vo/gpu/drm] Failed to commit ModeSetting atomic request: Permission denied
[vo/gpu/opengl] Failed to set CRTC for connector 95: Permission denied
[vo/gpu] Failed to commit atomic request: Permission denied
[vo/gpu/drm] Failed to commit ModeSetting atomic request: Permission denied
[vo/gpu/drm] Failed to restore previous mode
[vo/gpu/drm] Failed to drop DRM master: Invalid argument
error: XDG_RUNTIME_DIR is invalid or not set in the environment.
error: XDG_RUNTIME_DIR is invalid or not set in the environment.
[vo/gpu-next/drm] Can’t handle VT release - signal already used
[vo/gpu-next/drm] Failed to set up VT switcher. Terminal switching will be unavailable.
[vo/gpu-next/drm] Failed to acquire DRM master: Device or resource busy
[vo/gpu-next/drm] Failed to commit ModeSetting atomic request: Permission denied
[vo/gpu-next/opengl] Failed to set CRTC for connector 95: Permission denied
[vo/gpu-next] Failed to commit atomic request: Permission denied
[vo/gpu-next/drm] Failed to commit ModeSetting atomic request: Permission denied
[vo/gpu-next/drm] Failed to restore previous mode
[vo/gpu-next/drm] Failed to drop DRM master: Invalid argument
error: XDG_RUNTIME_DIR is invalid or not set in the environment.
error: XDG_RUNTIME_DIR is invalid or not set in the environment.
error: XDG_RUNTIME_DIR is invalid or not set in the environment.
Error opening/initializing the selected video_out (–vo) device.
Video: no video

Exiting… (Errors when loading file)

What is going on?

Very weird. Which GPU is it, desktop environment? Is this X11 or Wayland? Does ffplay /path/to/your.mp4 works?

If you also have mpv from Clear installed, remove it.

[vo/gpu/drm] VT_GETMODE failed: Inappropriate ioctl for device
error: XDG_RUNTIME_DIR is invalid or not set in the environment.

Very weird. Which GPU is it, desktop environment? Is this X11 or Wayland? Does ffplay /path/to/your.mp4 works?

If you also have mpv from Clear installed, remove it.

Laptop, intel 520 graphics, x11

ffplay video but no audio
SDL_OpenAudio (2 channels, 44100 Hz): ALSA: Couldn’t open audio device: No such device or address

sudo swupd bundle-remove mpv

If there is an mpv available from clearfraction what is the specific cli syntax to install it and is any subsequent configuration necessary?

is any subsequent configuration necessary?

Nope, it should work out the box. I got similar issue:

  • no video, sound ok:
mpv --no-config  --hwdec=vaapi 'https://dn720305.ca.archive.org/0/items/bugs-bunny-classics/Unnumbered%20Daffy%20Duck%20and%20the%20Dinosaur%20%281939%29.ia.mp4'
  • video & sound are OK:
mpv --no-config -vo=gpu-next --hwdec=vaapi 'https://dn720305.ca.archive.org/0/items/bugs-bunny-classics/Unnumbered%20Daffy%20Duck%20and%20the%20Dinosaur%20%281939%29.ia.mp4'

Thank you paulcarroty.

MPV is rendering aac audio and avc1 video.

1 Like