Merge branch '0.3'
Conflicts: CHANGELOG.md
This commit is contained in:
commit
afbbf13695
4 changed files with 64 additions and 0 deletions
|
|
@ -3,6 +3,10 @@ CHANGELOG
|
||||||
|
|
||||||
* 0.4.0 (xx-xx-xxxx)
|
* 0.4.0 (xx-xx-xxxx)
|
||||||
|
|
||||||
|
* 0.3.5 (xx-xx-2013)
|
||||||
|
|
||||||
|
* Add vorbis audio format (@jacobbudin).
|
||||||
|
|
||||||
* 0.3.4 (05-09-2013)
|
* 0.3.4 (05-09-2013)
|
||||||
|
|
||||||
* Fix Invalid ratio computing.
|
* Fix Invalid ratio computing.
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,14 @@ An Object Oriented library to convert video/audio files with FFmpeg / AVConv.
|
||||||
|
|
||||||
Check another amazing repo : [PHP FFMpeg extras](https://github.com/alchemy-fr/PHP-FFMpeg-Extras), you will find lots of Audio/Video formats there.
|
Check another amazing repo : [PHP FFMpeg extras](https://github.com/alchemy-fr/PHP-FFMpeg-Extras), you will find lots of Audio/Video formats there.
|
||||||
|
|
||||||
|
## Your attention please
|
||||||
|
|
||||||
|
This library requires a working FFMpeg install. You will need both FFMpeg and FFProbe binaries to use it.
|
||||||
|
Be sure that these binaries can be located with system PATH to get the benefit of the binary detection,
|
||||||
|
otherwise you should have to explicitely give the binaries path on load.
|
||||||
|
|
||||||
|
For Windows users : Please find the binaries at http://ffmpeg.zeranoe.com/builds/.
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
The recommended way to install PHP-FFMpeg is through [Composer](https://getcomposer.org).
|
The recommended way to install PHP-FFMpeg is through [Composer](https://getcomposer.org).
|
||||||
|
|
|
||||||
39
src/FFMpeg/Format/Audio/Vorbis.php
Normal file
39
src/FFMpeg/Format/Audio/Vorbis.php
Normal file
|
|
@ -0,0 +1,39 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/*
|
||||||
|
* This file is part of PHP-FFmpeg.
|
||||||
|
*
|
||||||
|
* (c) Alchemy <info@alchemy.fr>
|
||||||
|
*
|
||||||
|
* For the full copyright and license information, please view the LICENSE
|
||||||
|
* file that was distributed with this source code.
|
||||||
|
*/
|
||||||
|
|
||||||
|
namespace FFMpeg\Format\Audio;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The Vorbis audio format
|
||||||
|
*/
|
||||||
|
class Vorbis extends DefaultAudio
|
||||||
|
{
|
||||||
|
public function __construct()
|
||||||
|
{
|
||||||
|
$this->audioCodec = 'vorbis';
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritdoc}
|
||||||
|
*/
|
||||||
|
public function getExtraParams()
|
||||||
|
{
|
||||||
|
return array('-strict', '-2');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* {@inheritDoc}
|
||||||
|
*/
|
||||||
|
public function getAvailableAudioCodecs()
|
||||||
|
{
|
||||||
|
return array('vorbis');
|
||||||
|
}
|
||||||
|
}
|
||||||
13
tests/FFMpeg/Tests/Format/Audio/VorbisTest.php
Normal file
13
tests/FFMpeg/Tests/Format/Audio/VorbisTest.php
Normal file
|
|
@ -0,0 +1,13 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
namespace FFMpeg\Tests\Format\Audio;
|
||||||
|
|
||||||
|
use FFMpeg\Format\Audio\Vorbis;
|
||||||
|
|
||||||
|
class VorbisTest extends AudioTestCase
|
||||||
|
{
|
||||||
|
public function getFormat()
|
||||||
|
{
|
||||||
|
return new Vorbis();
|
||||||
|
}
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue