Xpressengine\Media\Handlers\VideoHandler::extractInformation PHP Method

extractInformation() protected method

Extract file meta data
protected extractInformation ( Video $video ) : array
$video Xpressengine\Media\Models\Video video file instance
return array
    protected function extractInformation(Video $video)
    {
        $tmpFile = $this->temp->create($video->getContent());
        $info = $this->reader->analyze($tmpFile->getPathname());
        $tmpFile->destroy();
        if (isset($info['audio']['streams'])) {
            unset($info['audio']['streams']);
        }
        return [$info['audio'], $info['video'], $info['playtime_seconds'], $info['bitrate']];
    }