From: Martin Guy <martinwguy@gmail.com>
To: sox-devel@lists.sourceforge.net
Subject: A sox pipe mystery
Date: Sun, 3 Nov 2024 07:52:56 +0100 [thread overview]
Message-ID: <ff3d815e-a604-4428-a683-0dc14451189e@gmail.com> (raw)
Hi all
I'm looking at launching external programs to decode a million other
formats automatically and have run into a mystery I cannot fathom.
sox "|ffmpeg -loglevel quiet -i 'Candy Toy.wma' -f ircam -" 'Candy
Toy.wav'
works but
sox "|ffmpeg -loglevel quiet -i 'Candy Toy.wma' -f sox -" 'Candy
Toy.wav'
fails saying
sox FAIL formats: can't open input `-': can't find sox file format
identifier
as do
-f wav sox FAIL formats: can't open input `-': WAVE: RIFF header
not found
-f aiff sox FAIL formats: can't open input `-': AIFF header does
not begin with magic word `FORM'
though
ffmpeg -loglevel quiet -i 'Candy Toy.wma' -f sox -" > 'Candy Toy.sox'
sox 'Candy Toy.sox' 'Candy Toy.wav'
works.
Is it because ffmpeg is seeking back in the file and rewriting the
header once it's decoded? Nope:
ffmpeg -loglevel quiet -i 'Candy Toy.wma' -f sox - | cat > 'Candy
Toy.sox'
cat 'Candy Toy.sox' | sox - 'Candy Toy.wav'
works too.
What's the difference for sox between that last command pair that works and
ffmpeg -loglevel quiet -i 'Candy Toy.wma' -f sox - | sox - 'Candy
Toy.wav'
or
ffmpeg -loglevel quiet -i 'Candy Toy.wma' -f sox - | cat | sox -
'Candy Toy.wav'
that don't?
And how come -f ircam works in the simple pipeline invocations but -t
{wav,aiff,sox} don't?
(Not that I'm complaining - at least one intermediate format works.
Finally, a use for ircam format!)
M
_______________________________________________
SoX-devel mailing list
SoX-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sox-devel
next reply other threads:[~2024-11-03 6:53 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-03 6:52 Martin Guy [this message]
2024-11-07 9:19 ` A sox pipe mystery Eric Wong
2024-11-07 14:07 ` Martin Guy
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-list from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://lists.sourceforge.net/lists/listinfo/sox-devel
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ff3d815e-a604-4428-a683-0dc14451189e@gmail.com \
--to=sox-devel@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/sox.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).