/** * Constructs a media object. * * @access public * @author Oliver Lillie * @param string $media_file_path The file path of a media file. * @param Config $config A PHPVideoToolkit Config object * @param Format $input_format An input Format object */ public function __construct($media_file_path, Config $config = null, Format $input_format = null) { parent::__construct($config, 'ffmpeg'); if ($media_file_path !== null) { $this->setMediaPath($media_file_path); } $this->setInputFormat($input_format); $this->last_error_message = null; $this->error_messages = array(); $this->_extract_segment = array(); $this->_split_options = array(); $this->_metadata = array(); $this->_output_path = null; $this->_processing_path = null; $this->_blocking = null; $this->_require_d_in_output = false; // @see http://multimedia.cx/eggs/supplying-ffmpeg-with-metadata/ // @see http://wiki.multimedia.cx/index.php?title=FFmpeg_Metadata $this->_supported_meta_data = array('title', 'date', 'author', 'album_artist', 'album', 'grouping', 'composer', 'year', 'track', 'comment', 'genre', 'copyright', 'description', 'synopsis', 'show', 'episode_id', 'network', 'lyrics'); $this->_post_process_callbacks = array(); $this->_process = new FfmpegProcessProgressable('ffmpeg', $this->_config); }