Questions tagged [ffmpeg-php]

Refers to a few similarly named PHP extensions that add functions for accessing and retrieving information about multimedia files. Questions about generally using ffmpeg cli tool through exec() or similar or other libraries should not use this tag!

ffmpeg-php refers to a few similarly named PHP extensions that add functions for accessing and retrieving information about multimedia files:

  • FFmpegPHP: a pure OO PHP port of the legacy ffmpeg-php writer in C.

  • PHP-FFMpeg An Object-Oriented library to convert video/audio files with FFmpeg.

  • ffmpeg-php: The classic, legacy version. This is a very old, long dead project that will not work with any ffmpeg versions officially supported by the FFmpeg project.

Note that these extensions are not part of the FFmpeg project.

You may not need a wrapper/extension/library if you simply want to invoke the ffmpeg binary from your PHP script. Refer to FFmpeg Wiki: PHP for more info.

276 questions
0
votes
1 answer

How to transform all the images from type .jpg & .png from the current directory to a video in FFmpeg?

How to transform all the images from type .jpg & .png from the current directory to a video in FFmpeg? i have tried the following code and not working ffmpeg -r 1/5 -start_number 1 -i images/%*.png -i ".$_FILES['files']['name']." -c:v libx264 -c:a…
0
votes
0 answers

problem with brackets in video name ffmpeg php

I'm using ffmpeg to put a watermark on video but when my video has a name that contains brackets it's not doing anything $a = "10 (1).mp4"; $cmd = "$ffmpeg -i $a -i $logo -filter_complex…
Hadi Ahmadi
  • 129
  • 12
0
votes
1 answer

Can we set size of image frame in save function?

Unable to set the size of image frame so I am unable to use thumbnail size. $video = $ffmpeg->open($videoFile); $video ->filters() ->resize(new FFMpeg\Coordinate\Dimension(320, 240)) ->synchronize(); $frame =…
Tester
  • 35
  • 7
0
votes
1 answer

How to put text watermark on video using PHP in shared hosting

I am making video uploading site in shared hosting using PHP and I want users to upload their videos, and I want to put logo watermark to appear automatically on every video uploaded to site. I don't want to use any API for this, please help I have…
Sandeep Pal
  • 31
  • 1
  • 4
0
votes
1 answer

FFmpeg commands work for root only(centos 6.10)

I have dedicated server. I have installed FFmpeg on my root. All commands related to FFmpeg works if I logged in as root but no command is working if I logged in as user. I have tried adding one user to sudoers also. Also I want to use FFmpeg…
0
votes
1 answer

FFMPEG map multiple audio input files to 1 single image file in order to create multiple video output files

I am attempting to have multiple output files in ffmpeg map to multiple inputs however instead of each input mapping to a unique output I get the first input mapping to the first video and then the next videos never get created at all, I will…
Edmund Rojas
  • 6,376
  • 16
  • 61
  • 92
0
votes
1 answer

ffmpeg concat video and image issue

I have a video it's 190 seconds long. I want to show a part of the video with audio and a watermark (from 28th second to 154th second) and then the video fades out, and then show an image for 5 seconds at the end of the video. everything was…
Dion Russell
  • 93
  • 1
  • 9
0
votes
0 answers

Generate thumbnail image from video in codeigniter

i want to generate the thumbnail image from the uploaded video but the problem is that the thumbnail image is not generating. The uploaded video goes to the uploads folder but at this place the image is not generating..Please look at the code, and…
0
votes
0 answers

How to add Text with transition effect to video with ffmpeg?

I want to add text in video like subtitles, i know how to add text to video, now i want to add text with transition effects like presentation. How can i do that with using FFMPEG PHP. Is there any other possibilities to achieve that? Thanks in…
rathodbhavikk
  • 416
  • 7
  • 20
0
votes
1 answer

Filter text disappearing after concat, why?

I'm trying to concatenate 2 videos, while at the same time adding some text to the second one. I'm using php-ffmpeg to do this, with the Sharapov extension, but I have the actual ffmpeg commands. To do this it seems to encode the first video, then…
GemmaB89
  • 165
  • 2
  • 16
0
votes
2 answers

Detect scene change with no audio together using FFMPEG

I want to detect scene change with no audio using ffmpeg in window. I want a single command to detect at which point scene changed as well as no audio is there.
0
votes
1 answer

Passing negative values for dimensions with PHP FFMpeg

I'm working on a legacy project that uses FFMpeg to process videos on upload. The code I inherited uses escapeshellarg() to run FFMpeg from the command line, which is problematic because it doesn't provide any means of keeping track of progress, so…
Matthew Daly
  • 9,212
  • 2
  • 42
  • 83
0
votes
1 answer

FFMPEG zoompan only applies and shows 3 images out of the many

I am trying to generate a video from images using FFMPEG 4.0 windows built on AWS windows instance using PHP. $command2="ffmpeg -r 1/5 -i https:///$images%d.jpg -c:v libx264 -r 5 -t $total_video_time -y ".trim($video_name)." -i…
Sanjyot Shah
  • 225
  • 1
  • 5
  • 17
0
votes
1 answer

Transcode video and upload on amazon s3

I want to transcode video in 360p, 480p, 720p and then upload to amazon s3. Currently we are using php library FFMPEG I have successfully transcode video on my server. But I did not get that how to achieve same on amazon s3. Do I need to first…
dev
  • 67
  • 7
0
votes
0 answers

FFMPEG-PHP converted videos don't work on mobiles

I'm working on a upload script where users can upload videos however I'm having an issue with FFMPEG-PHP : The converted videos don't work on mobiles while they are working fine on desktop. //FFMPEG Instance require_once…
casusbelli
  • 463
  • 1
  • 5
  • 22