Newest 'ffmpeg' Questions - Stack Overflow
Les articles publiés sur le site
-
pip installation failure of pyAV with exit status 1181
11 février 2020, par Kesar MurthyI am having trouble installing PyAV through pip. First it required me to download Microsoft Visual C++ Build Tools
building 'av.buffer' extension error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/
and when I did install this, I get the following error
LINK : fatal error LNK1181: cannot open input file 'avcodec.lib' error: command 'C:\\Users\\Kesar\\AppData\\Local\\Programs\\Common\\Microsoft\\Visual C++ for Python\\9.0\\VC\\Bin\\amd64\\link.exe' failed with exit status 1181
I even tried to build PyAV from source, but the same problem persists. How do I solve this?
-
FFmpeg + Dshow + filter_complex How do I identify the input ?
11 février 2020, par John DoeI have a command which will draw a waveform over a background image using the input audio from [1:a] however when I try to feed my microphone as the input the waveform no longer works. No error messages, the waveform simply doesn't get drawn. What am I missing? I basically wish to create a waveform for audio picked up via my microphone. Here's what I have so far:
ffmpeg -re -framerate 10 -loop 1 -i background.jpg -f dshow -i audio="Microphone (Realtek High Defini" -filter_complex "[1:a]showwaves=mode=cline:s=170x54:r=10:scale=sqrt:colors=0x222222,colorkey=0x000000:0.01:0.1,format=yuva420p[v];[0][v]overlay=555:416,scale=1280:720[outv]" -map "[outv]" -map 1:a -c:v libx264 -c:a aac -tune stillimage -pix_fmt yuv420p -shortest -maxrate 3000k -bufsize 4000k -r 10 -g 20 -f flv rtmp://a.rtmp.youtube.com/live2/XXXX-XXXX-XXXX-XXXX
UPDATE: I also tried piping the data but no luck:
ffmpeg -y -re -f dshow -i audio="Microphone (Realtek High Defini" -f mp3 - | ffmpeg -y -framerate 10 -loop 1 -i background.jpg -i - -filter_complex "[1:a]showwaves=mode=cline:s=170x54:r=10:scale=sqrt:colors=0x222222,colorkey=0x000000:0.01:0.1,format=yuva420p[v];[0][v]overlay=555:416,scale=1280:720[outv]" -map "[outv]" -map 1:a -c:v libx264 -c:a aac -tune stillimage -pix_fmt yuv420p -shortest -maxrate 3000k -bufsize 4000k -r 10 -g 20 test.mp4
-
ffmpeg. Artifacts after cut and concat of the same video file
10 février 2020, par user3841429I cut the video using the following commands:
ffmpeg -i 'example.mp4' -ss 0 -t 640.509 -c copy -y o1.mp4 ffmpeg -i 'example.mp4' -ss 645.342 -t 424.195 -c copy -y o2.mp4 ffmpeg -i 'example.mp4' -ss 1074.37 -t 463.202 -c copy -y o3.mp4 ffmpeg -i 'example.mp4' -ss 1542.405 -t 295.6 -c copy -y o4.mp4 ffmpeg -i 'example.mp4' -ss 1842.838 -t 368.54 -c copy -y o5.mp4 ffmpeg -i 'example.mp4' -ss 2216.211 -c copy -y o6.mp4
After that I concat them with:
ffmpeg -auto_convert 1 -f concat -i concat.txt -c copy -y result.mp4
my concat.txt file:
file o1.mp4 file o2.mp4 file o3.mp4 file o4.mp4 file o5.mp4 file o6.mp4
The issue is: I'm getting a short artifacts in the beginning of each fragment in the
result.mp4
file.During the concat I get the following:
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x7fb8db801400] Auto-inserting h264_mp4toannexb bitstream filter177x [mov,mp4,m4a,3gp,3g2,mj2 @ 0x7fb8db801400] Auto-inserting h264_mp4toannexb bitstream filter188x [mov,mp4,m4a,3gp,3g2,mj2 @ 0x7fb8e0000600] Auto-inserting h264_mp4toannexb bitstream filter188x [mov,mp4,m4a,3gp,3g2,mj2 @ 0x7fb8db801400] Auto-inserting h264_mp4toannexb bitstream filter189x [mov,mp4,m4a,3gp,3g2,mj2 @ 0x7fb8db801400] Auto-inserting h264_mp4toannexb bitstream filter186x
-
H264 ByteStream to Image Files
10 février 2020, par Tzah Mazuzfirst time here so be gentle.
I've been working for a few weeks on a given H.264 byte stream:
General notes:
- The Byte Stream is not from a file, it is being fed live to me from an external source.
- The Byte Stream is encoded with Android's Media Codec.
- When writing the stream into a file with a .H264 extension, VLC is able to play it properly.
What I'm trying to achieve? One of the following:
Converting the frames of the H264 stream to a saveable picture file (png/jpeg etc')
Converting the H264 raw bytes into a MP4 stream that can be played as source by a browser.
I tried already using JavaCV (FFmpegFrameGrabber) without any success, my main problem is that i have no idea how to parse the byte stream or what each "packet" means
So, I've attached a text file with some of the packets I'm getting from the stream H264 Packets
-
ffmpeg : Set "year" metadata equal to first 4 characters of another metadata variable (flac)
10 février 2020, par HelloThe flac files I am dealing with has an attributed named "Date released", whose value is in the format "YYYY-MM-DD".
Is it possible for me to take the "YYYY" from this and set the year variable equal to it?
ffmpeg -i input.flac -metadata year=??? -codec copy output.flac
Bonus question, is it possible to do this in place without creating a new file? Or would I have to create a new file and then delete the old one?