Questions tagged [ffmpeg]

Only questions about programmatic use of the FFmpeg libraries, API, or tools are on topic. Questions about interactive use of the command line tool should be asked on Super User or Video Production. FFmpeg is a free, open source project that produces libraries and programs for handling multimedia data.

1
vote
0answers
13 views

How to split streaming video into pieces FFMPEG

I have a bat script (Windows) for the library Livestreamer to record the broadcast in the video :loop set day=%DATE:~0,2% set month=%DATE:~3,2% set year=%DATE:~6,4% set hour=%TIME:~0,2% set minute=%...
-1
votes
1answer
16 views

Affectiva drops every second frame

I am running Affectiva SDK 4.0 on a GoPro video recording. I'm using a C++ program on Ubuntu 16.04. The GoPro video was recorded with 60 fps. The problem is that Affectiva only provides results for ...
0
votes
0answers
18 views

FFmpeg adds its own metadata - encoder: Lavf58.20.100

I've tried to apply the following advice on the flac files: for x in *.flac; do ffmpeg -i "$x" -map 0:a -codec:a copy -map_metadata -1 clean_"$x"; done But it seems, that ffmpeg though removes ...
0
votes
1answer
23 views

How to retrieve width and height from video

How can i put to variables 'width' and 'height' video properties? I have found something: streaminfo=`mktemp` ffprobe -v quiet -show_streams -select_streams v:0 input.mkv >$streaminfo width=`grep ...
0
votes
0answers
7 views

if - Command Prompt

I want to make a command that if ch==yes then etc else end this what I came with, it encode directly without questioning! echo off echo. SET "ch=yes" IF "%ch%" == "yes" ( for %%a in ("*...
0
votes
0answers
11 views

Initializing an output file for muxing mkv with FFmpeg

I'm a first time user of ffmpeg and I'm having trouble with initializing an output file for mkv muxing. I followed the description on the middle of this page but it doesn't work. When I call the ...
0
votes
0answers
17 views

ffmpeg resize large image and high resolution

I tried to resize a very big image (457 MB and 21600x21600) with the following command -i test.png -vf scale=320:-1 out.png but it throws exception saying "Picture size 21600x21600 is invalid". How ...
0
votes
1answer
25 views

My Video Filesize Does Not Equal Bitrate x Time

I'm trying to use ffmpeg to encode some videos with h264. I'm trying to hit a target filesize. My code is: D:\SOFTWARE\ffmpeg\bin\test\ffmpeg.exe -i "%~1" -c:v libx264 -preset veryslow -b:v 200k -an ...
0
votes
0answers
15 views

Can't synchronize frame from two webcam streams side by side using ffmpeg

i'm trying to stream two webcam in sbs mode using ffmpeg websocket. It works but there is a delay of some second between the two scene. Here is what I do : ffmpeg -f v4l2 -framerate 30 -...
0
votes
0answers
18 views

av_seek_frame() Can't seek to the place I want

I want to intercept a frame of my video file, so I used the av_seek_frame function, the timestamp value I tried using timestamp*AV_TIME_BASE and timestamp/(av_q2d(videostream->time_base)*...
1
vote
0answers
32 views

Text To animated mp4 video

i need a big help, i would like to send in Text from Web which needs to get converted into an animated MP4, please help if anyone has tried this this is wgat i tried so far: ffmpeg -y -i bg-video....
0
votes
1answer
40 views

Make an Alpha Mask video from PNG files

For RenPy it uses the notion of an Alpha Mask video https://www.renpy.org/doc/html/movie.html#movie-displayables-and-movie-sprites I can convert the a bunch of PNGs with alpha channel to http://wiki....
0
votes
0answers
24 views

Is it possible for me to put a mask over a transparent image with ffmpeg?

I'm trying to make an overlay with a mask over a transparent image with ffmpeg, but the background of the image that gets the mask turns black, is there any way to make this background remain ...
0
votes
0answers
8 views

Slow seek in MKV videos with FFmpeg C/C++

Seeking in any large MKV H.264 video works very slow. Call of av_seek_frame() in my code using FFmpeg LibAV takes about 3-10 seconds to jump to a middle position in 1-2 hours video. I tried all ...
0
votes
2answers
44 views

ffmpeg to calculate audio/visual difference between compressed and non-compressed video

I'm trying to calculate the audio + visual difference between a harshly compressed video file and one that hasn't been. I'm using pipes because ultimately I wish this to take src from a camera stream. ...
0
votes
1answer
28 views

How to record/download m3u steam video from url using FFMPEG

I am trying to download video from m3u live stream but there is some part of video download in this m3u8 url return segments and this segments merge and give video but video length is like one ...
0
votes
0answers
34 views

HTML5 CSS animation to video slideshow

I want to create dynamic slideshow using HTML5 animations and later export it to make a video using ffmpeg. Is this idea feasible? What stack is Animoto using?
0
votes
0answers
21 views

Run Command/Process in Background but return the return code

I am Looking to run ffmpeg via subprocess, start the command in the background but return a return code so that further steps can be taken based on that return code. (stdout, stderr) = metadata....
3
votes
1answer
32 views

FFmpeg/OpenCV force ignore input frame duration with rtsp?

I was experiencing a ~5 sec delay when playing a rtsp stream from an IP camera. After a bunch of googling (especially this question), I reduced the delay to ~1 sec using the following command: ffplay ...
0
votes
1answer
32 views

how to assign the video level to struct AVCodecContext in ffmpeg?

I am writting a C++ video encode API with ffmpeg.The video level is one important param, but I don't known how to assign it to AVCodecContext. I read the ffmpeg document and find out that "level" is ...
0
votes
0answers
21 views

VoiceClient.play() doesn't play any audio

I am trying to make a music bot in discord.py, but whenever I tried to play audio using VoiceClient.play(), it never played anything, just stayed in the voice channel. async def play(ctx): for ...
0
votes
0answers
23 views

How do I write a batch file that opens a msys shell and then run commands in the shell?

I'm trying to automate the process of building ffmpeg on Windows 10. I'm following the guide here: https://trac.ffmpeg.org/wiki/CompilationGuide/MSVC Everything works fine when I do it manually, ...
0
votes
0answers
19 views

How to not add AdaptationSet for audio in cmd file if audio stream is not present in input video file

I am using ffmpeg-dash to create mpd files. I am using following command to generate the same: ffmpeg -i input/video.mov \ -map 0:v:0 -map 0:v:0 -map 0:v:0 -map 0:a\?:0 \ -b:v:0 350k -...
0
votes
1answer
30 views

How to merge two audio files with FFmpeg

I've been trying to merge two audio tracks together. I want the shorter audio "track.mp3" to come first, then the longer audio Wizkid should come immediately after the track.mp3 Here is my code: ...
0
votes
1answer
55 views

How to write silent audio data to an audio stream?

I am writing some images to an AVStream and after that I am reading an mp3 file and writing it to an diffrent AVStream. The propblem is that the audio stream is a bit shorter then the video stream, so ...
2
votes
0answers
62 views

I want to know what is in unknown [WARNING: Unknown codec unknown]

I want to new music_bot in my discord.ch so I found google cloud platform and Just-some-bot in git hub (https://github.com/Just-Some-Bots/MusicBot) I did just fallow to step ubuntu 16.04 in this site (...
0
votes
0answers
12 views

GLtransition not working properly with 480p

I have a problem with GL Transition while rendering video at 480p, GL EFFECT applies but not as it was but it works fine for 1080P and 720P, here is my command: ffmpeg -y -loop 1 -t 5 -i /srv/sample/...
0
votes
0answers
6 views

FFmpeg : Reading data from 2 FIFO

I am working with FFmpeg 4.1.3. I am trying to read video from one named pipe and audio from another named pipe and creating a new output file. There are 2 RTP processes reading data over the network ...
0
votes
0answers
8 views

FFmpeg similar command get difference result about the video duration

when I use this cmd ffmpeg -i video.mp4 -i music.mp3 -c:v copy -shortest outg.mp4 ffmpeg -i outg.mp4 2>&1 | grep Duration I get Duration: 00:00:23.13, start: 0.000000, bitrate: 805 kb/s ...
0
votes
0answers
20 views

FFmpeg IP camera hls video not playing in IOS

We have create the node code which is create the IP camera HLS video from ffmpeg. Now its working in desktop browsers and Android devices using React-hls player based on videojs It is not working on ...
0
votes
0answers
18 views

ffmpeg with two input rtmp streams with overlay causing 5 sec delay

I'm using ffmpeg on merging two videos, using overlay taking input from two rtmp streams getting lag of 5 seconds in one of the videos in stream3 . Below is the command I've tried ffmpeg -i rtmp://...
0
votes
1answer
77 views

HLS encoded video (ffmpeg) breaks in Safari when segmented via byte-range

Some of my HLS encoded videos via ffmpeg drop the audio when seeking past the buffer. The only way to sync the audio and video up again is to restart the video. What would be causing this? Example ...
0
votes
1answer
16 views

ffmpeg take snapshot from webcam in windows 10

Attempting to use ffmpeg to grab a snapshot from my USB webcam in windows 10. ffmpeg -f mjpeg "video=HD Pro Webcam C920" "C:\projects\webcam\" -vframes 1 -s 1920x1080 -ss 10 test.jpg Returns: Output ...
0
votes
1answer
28 views

ffmpeg: record/capture stream and do scene detection at the same time

Is it possible to both capture (record) an RTSP stream and capture scene change events using a single ffmpeg command? I can almost do what I want with: ffmpeg -i 'rtsp://mystream' \ -map 0:v -map 0:a ...
1
vote
1answer
21 views

FFmpeg - Merge two images (.png) to video (.mp4) doesn't work

I want to merge two images (names are not numbered in a sequence) to a video, but the result includes only a video of the first image. I would appreciate any kind of help! ffmpeg.exe -r 1/5 -i ...
1
vote
1answer
58 views

FFmpeg C++ decoding in a separate thread

I'm trying to decode a video with FFmpeg and convert it to an openGL texture and display it inside a cocos2dx engine. I've managed to do that and it displays the video as i wanted to, now the problem ...
-1
votes
1answer
34 views

what is ffmpeg exit code 2? and also output error array is empty and not working in php

I use ffmpeg to convert bitrate to 128 but not working in php exec("ffmpeg -i input.mp3 -codec:a libmp3lame -b:a 128k output().mp3 2>&1", $output, $exit_code); if ($exit_code!= 0) { $...
0
votes
0answers
20 views

Direct3d Color space conversion in GPU

Creating direct3d surface inYV12 format and rendering video frames in yuv420 format causes a blur video. Seems like there is a smog on video. I think this is because yuv 420 color space format's data ...
0
votes
0answers
18 views

How to draw text in center in center with ffmpeg [duplicate]

I am creating video with ffmpeg. How to center text? Also, my text have new lines. Here is my code: $json = json_decode($array[$j][$i]->text, true); $remove_BSN = str_replace('\\', ...
0
votes
1answer
21 views

How to set proper bitrate for ffmpeg with hevc_nvenc?

When I transcode video to H265 with following command, I get a bitrate about 600K and the quality is almost the same as the original. ffmpeg -i data2.mp4 -c:v libx265 -c:a copy d2.mp4 However when I ...
1
vote
0answers
14 views

How to Install ffmpeg xampp php 7.1

How i can install ffmpeg on xampp with php 7.1 2019 I read some posts and i saw some videos but i cant find the correct installation to make it work the ffmpeg on xampp with php 7.1 Some one can ...
0
votes
0answers
21 views

How to take video thumbnail when uploading using FFMPEG and PHP on localhost

I'm trying to use FFMPEG on my website on localhost to take a thumbnail of a video that is being uploaded and save it to a folder on the server but it is not working. I've tested if this code works ...
2
votes
1answer
32 views

How to pipe output and log files to S3 using FFMPEG

I'm saving my FFMPEG output directly from my EC2 to S3 using: ffmpeg -i ${input} -f mp4 -movflags frag_keyframe+faststart -hide_banner -y pipe:1 | aws s3 cp - s3://my-bucket/video/output.mp4 - which ...
0
votes
1answer
54 views

How to use system command in php?

I am working on a PHP code as shown below in which conversion of mp4 into mp3 is happening at Line B. I have added if block after system command to print Conversion Completed on the webpage once ...
-1
votes
0answers
18 views

FFMPEG rotate and concat

I need to rotate 180 an h265 video and then concat with another one. If I concat a video rotated only with metatada, it is merged with the original orientation and not the one in the metadata. Any ...
-1
votes
0answers
19 views

Make IIS to call CLI program on the fly

Convert gsm coded file to aac format 'on the fly' with IIS. Hi, is there a Way I can map a program on a certain file calls. EX: I call <a href=mysite.com/wavs/file1.wav> downloads</a> ...
0
votes
0answers
15 views

FFMpeg - move overlay from point a to b

FFMpeg - move overlay gif from a point a to b. I used somebody posted here FFMpeg - move overlay from point a to b to c to d. I modified it like this: -i input.mp4 -ignore_loop 0 i example.gif \ ...
0
votes
0answers
23 views

Problems in making Video from Lottie JSON File and Overlay it with original video using FFMPEG

there is some unique concept about processing Lottie Animations using FFMPEG video processing library and MediaCodec. In that, I wants to make video from Lottie animation and overlay that video on ...
0
votes
0answers
35 views

Recorded & uploaded video from iphone device won't play in iphone

I am facing an issue regarding : Recording video from iphone and uploading that video on my application(Develop in Wordpress Framework) then the video uploaded won't play in iphone devices. This ...
0
votes
0answers
34 views

Record and preview webcamera stream at the same time

I'm using ffmpeg and Windows 7/10 OS and going to save webcamera stream to file and preview it at the same time (from time to time, not constantly). I can solve each of these tasks separately: Saving ...