Download the PHP package iakumai/php-ffmpeg without Composer

On this page you can find all versions of the php package iakumai/php-ffmpeg. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package php-ffmpeg

PHP FFmpeg (Fork)

An Object Oriented library to convert video/audio files with FFmpeg / AVConv.

Check another amazing repo: PHP FFMpeg extras, you will find lots of Audio/Video formats there.

Installation

The recommended way to install PHP-FFMpeg is through Composer.

Basic Usage

Documentation

This documentation is an introduction to discover the API. It's recommended to browse the source code as it is self-documented.

Qt-Faststart

FFMpeg\QtFaststart can make MP4 files progressive. This helps the video to playback as early as possible.

If you want to give binary paths explicitely, you can pass an array as configuration.

FFMpeg

FFMpeg\FFMpeg is the main object to use to manipulate medias. To build it, use the static FFMpeg\FFMpeg::create :

FFMpeg will autodetect ffmpeg and ffprobe binaries. If you want to give binary paths explicitely, you can pass an array as configuration. A Psr\Logger\LoggerInterface can also be passed to log binary executions.

Manipulate media

FFMpeg\FFMpeg creates media based on file paths. To open a file path, use the FFMpeg\FFMpeg::open method.

Two types of media can be resolved : FFMpeg\Media\Audio and FFMpeg\Media\Video. A third type, FFMpeg\Media\Frame, is available through videos.

Video

FFMpeg\Media\Video can be transcoded, ie : change codec, isolate audio or video. Frames can be extracted.

Transcoding

You can transcode videos using the FFMpeg\Media\Video:save method. You will pass a FFMpeg\Format\FormatInterface for that.

Transcoding progress can be monitored in realtime, see Format documentation below for more informations.

You can use an extra parameters in save() method.

Extracting image

You can extract a frame at any timecode using the FFMpeg\Media\Video::frame method.

This code return a FFMpeg\Media\Frame instance corresponding to the second 42. You can pass any FFMpeg\Coordinate\TimeCode as argument, see dedicated documentation below for more information.

Filters

You can apply filters on FFMpeg\Media\Video with the FFMpeg\Media\Video::addFilter method. Video accepts Audio and Video filters.

You can build your own filters and some are bundled in PHP-FFMpeg - they are accessible through the FFMpeg\Media\Video::filters method.

Filters are chainable

Resize

Resizes a video to a given size.

The resize filter takes three parameters :

Framerate

Changes the frame rate of the video.

The framerate filter takes two parameters :

Synchronize

Synchronizes audio and video.

Some containers may use a delay that results in desynchronized outputs. This filters solves this issue.

Audio

FFMpeg\Media\Audio can be transcoded, ie : change codec, isolate audio or video. Frames can be extracted.

Transcoding

You can transcode audios using the FFMpeg\Media\Audio:save method. You will pass a FFMpeg\Format\FormatInterface for that.

Transcoding progress can be monitored in realtime, see Format documentation below for more informations.

Filters

You can apply filters on FFMpeg\Media\Audio with the FFMpeg\Media\Audio::addFilter method. It only accepts audio filters.

You can build your own filters and some are bundled in PHP-FFMpeg - they are accessible through the FFMpeg\Media\Audio::filters method.

Resample

Resamples an audio file.

The resample filter takes two parameters :

Frame

A frame is a image at a timecode of a video ; see documentation above about frame extraction.

You can save frames using the FFMpeg\Media\Frame::save method.

This method has a second optional boolean parameter. Set it to true to get accurate images ; it takes more time to execute.

Formats

A format implements FFMpeg\Format\FormatInterface. To save to a video file, use FFMpeg\Format\VideoInterface, and FFMpeg\Format\AudioInterface for audio files.

Format can also extends FFMpeg\Format\ProgressableInterface to get realtime informations about the transcoding.

Predefined formats already provide progress informations as events.

The callback provided for the event can be any callable.

Create your own format

The easiest way to create a format is to extend the abstract FFMpeg\Format\Video\DefaultVideo and FFMpeg\Format\Audio\DefaultAudio. and implement the following methods.

Coordinates

FFMpeg use many units for time and space coordinates.

FFProbe

FFMpeg\FFProbe is used internally by FFMpeg\FFMpeg to probe medias. You can also use it to extract media metadata.

Using with Silex Microframework

Service provider is easy to set up :

Available options are as follow :

API Browser

Browse the API

License

This project is licensed under the MIT license.


All versions of php-ffmpeg with dependencies

PHP Build Version
Package Version
Requires php Version >=5.3.3
alchemy/binary-driver Version ~1.5
doctrine/cache Version ~1.0
evenement/evenement Version ~1.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package iakumai/php-ffmpeg contains the following files

Loading the files please wait ....