Closed dreirund closed 2 years ago
This is not a bug, the correct format would be --desttype=WEBM+MP3
or --desttype=MP4+MP3
, the video format must be specified first.
For example, with --desttype=WEBM+MP3
all MP3/WAV files are converted to MP3, and MP4 to WebM, as expected.
I'll add a check, if an audio only format is specified first, the command line will be rejected with an error message.
This is not a bug, the correct format would be
--desttype=WEBM+MP3
or--desttype=MP4+MP3
, the video format must be specified first.
Thanks, that explains things and now it works as expected.
OGG files get converted to videos, maybe because it is a container that might contain video at all.
(file sounds/letter_in_mailbox.ogg
says
sounds/letter_in_mailbox.ogg: Ogg data, Vorbis audio, mono, 11025 Hz, ~29000 bps, created by: Xiph.Org libVorbis I (1.0.1)
though, so it looks like that already at that point can be determined that there is only audio, but I think this will be tackled by issue #86.)
Thanks for the clarification, and
I'll add a check, if an audio only format is specified first, the command line will be rejected with an error message.
thanks for the wrong-input handling!
-- Machen ist wie wollen, nur krasser.
OGG files get converted to videos, maybe because it is a container that might contain video at all.
Yep. OGG is video capable. FFmpegfs handles the formats quit dumb. For example, using using --desttype=WEBM+MP3
: MP3, AIFF, WAV - make MP3s. WebM, AVI, MP4, OGG - make WebM.
I'll enhance that as with issue #86.
Thanks for the clarification, and thanks for the wrong-input handling!
You're welcome!
This is a follow up from → here (issue #86):
What I do:
I mount a directory containing music files with
ffmpegfs
as follows:In that directory I have audio files in the formats OGG/Vorbis, mp3, AAC (without container), and some others.
Problem:
I observe that all the audio files get converted to WebM, and not MP3; even preexisting MP3 get converted to WebM.
Expected behaviour:
Convert at least file formats which are known to be audio only (
.mp3
,.wav
,.flac
) to MP3.Examples:
Original files:
sounds/letter_in_mailbox.ogg
sounds/water.mp3
sounds/silence/flac/silence-010s.flac
sounds/silence/flac/silence-060s.wav
Hannes_Wader/Der_Rattenfaenger/01_-_Der_Rattenfaenger.aac
Klassik/Bedrich_Smetana/Smetana_-_Vltava.mp4
Files in
ffmpegfs
mount:sounds/letter_in_mailbox.ogg.webm
sounds/water.mp3.webm
sounds/silence/flac/silence-010s.flac.webm
sounds/silence/flac/silence-060s.wav.webm
Hannes_Wader/Der_Rattenfaenger/01_-_Der_Rattenfaenger.aac.webm
Klassik/Bedrich_Smetana/Smetana_-_Vltava.mp4.webm
More detailed investigation for 1.
sounds/letter_in_mailbox.ogg
:Original file:
mediainfo sounds/letter_in_mailbox.ogg
:ffprobe sounds/letter_in_mailbox.ogg
:File in
ffmpegfs
mount:[→ Here] I have attached the terminal output of a run of
ffmpegfs -o allow_other,ro --max_threads=1 --desttype=MP3+WEBM --autocopy=MATCH --profile=FF --level=STANDARD --hwaccel_enc=VAAPI --hwaccel_dec=VAAPI -f -d /home/music /mnt/ffmpegfs/music/
after complete deletion offfmpegfs
's cache with a read ofsounds/letter_in_mailbox.ogg.webm
(dd if=sounds/letter_in_mailbox.ogg.webm of=/dev/zero
).mediainfo sounds/letter_in_mailbox.ogg.webm
:ffprobe sounds/letter_in_mailbox.ogg.webm
:Further remarks:
WEBM
toMP4
in the destination format specification: Then it converts all toMP4
..flac.webm
and.wav.webm
files could not be played back at all (while the original files work). They do work if I change target formatWEBM
toMP4
and remove the--autocopy
.--autocopy
does still convert the audio files to WebM or MP4.Software version:
ffmpegfs --version
: