Problems with GMT movie in GMT 6.1-FFmpeg error: Unknown encoder Libvpx


I am new on GMT, and I recently installed GMT 6.1 (and its dependencies) in my Ubuntu 20.04 machine using the conda package manager. When testing the installation using the script below:

> #!/usr/bin/env bash
> # Test script 2: Test that ffmpeg is present and able to make a MP4 or WEBM movie
> cat << EOF >
> gmt begin
> 	echo \${MOVIE_FRAME} | gmt text -R0/1/0/1 -JX10c -F+f200p+cCM -B0 -X0 -Y0
> gmt end
> gmt movie -Ncount -T25 -C10cx10cx30 -Fmp4 -Fwebm -Gpink -D4 -Z
> rm -f
> echo "Open either count.mp4 or count.webm in an application that can view movies"

I get the error: nknown encoder ‘libvpx’
movie [ERROR]: Running FFmpeg conversion to webM returned error 256 - exiting

The result is that the frames have been generated, but the MP4 movie is not playable, and the WEBM file is not generated.Trying to update ffmpeg manually does not change anything, and installing manually libvpx does not help either. When exploring the encoders currently present in ffmpeg, libvpx is not one of them. Any ideas on how to solve this issue?

Thank you in advance!

**Edit: the MP4 movie is playable and works with VLC video player, but it just shows a black screen with other video players. Regarding the conversion to WEBM: Apparently the issue is that ffmpeg from conda does not support libvpx, while Ubuntu’s ffmpeg does support libvpx. Thereferore, is there any way to modify the path to ffmpeg so that it uses Ubuntu’s version rather than Conda’s?

I think you just need to uninstall the ffmpeg via conda and then install it via ubuntu.

1 Like

You can check your ffmpeg configuration in your environment with just typing:


And check out if --enable-libvpx option exists

Then your will know why your have to install A’s version not B’s