Package Data | |
---|---|
Maintainer Username: | Folour |
Maintainer Contact: | folour@gmail.com (Vadim Bova) |
Package Create Date: | 2016-03-13 |
Package Last Update: | 2018-04-27 |
Language: | PHP |
License: | GPLv3 |
Last Refreshed: | 2024-12-14 15:11:45 |
Package Statistics | |
---|---|
Total Downloads: | 9,473 |
Monthly Downloads: | 3 |
Daily Downloads: | 0 |
Total Stars: | 28 |
Total Watchers: | 10 |
Total Forks: | 7 |
Total Open Issues: | 7 |
FFmpeg layer for Laravel 5.2-5.4, this is a fork of rafasamp/sonus package.
Simple API for convert audio/video files, get thumbnails from video, information of files
composer require folour/flavy
Folour\Flavy\Provider\FlavyServiceProvider::class,
'Flavy' => Folour\Flavy\FlavyFacade::class,
php artisan vendor:publish
Flavy::from('path/to/file.ogg')
->to('path/to/converted/file.mp3')
->aBitrate(128)
->aCodec('libmp3lame')
->overwrite()
->run();
Flavy::from('path/to/file.mp3')
->to('paths/to/new_file.mp3')
->aBitrate(64)
->channels(1)
->run();
Flavy::info('path/to/file.mp3'); //returns array with file info
Flavy::info('path/to/file.mp3', 'xml'); //returns xml string with file info
Flavy::info('path/to/file.mp3', 'csv'); //returns csv string with file info
Flavy::info('path/to/file.mp3', 'json', false); //returns json string with file info
Flavy::thumbnail('path/to/video.mov', 'path/to/images/thumb_%d.jpg', 10); //Make 10 thumbnail and calculate time interval $duration/$count
Flavy::thumbnail('path/to/video.mov', 'path/to/images/thumb_%d.jpg', 10, 30); //Make 10 thumbnail with specified interval
Flavy::encoders(); //return a nested array with audio and video encoders
Flavy::decoders(); //return a nested array with audio and video decoders
Flavy::formats(); //return array with supported formats
Flavy::canEncode('encoder'); //Check encoder support
Flavy::canDecode('decoder'); //Check decoder support