Johan
Johan

Reputation: 19062

Get width and height of quicktime clip (.mov) with php?

I need to get the width and height of a .mov-file with php. How do I do that?

Upvotes: 2

Views: 1870

Answers (1)

houmam
houmam

Reputation: 464

I have used getid3 in the past to achieve this you can grab it from http://www.getid3.org/ I am not sure how well maintained it is anymore

You could knock up some code to look similar to this

<?php
include_once('getid3.php');

$getID3 = new getID3;

$file = './file.mov';

$file_analysis = $getID3->analyze($file);

echo 'Video Resolution = '.$file_analysis['video']['resolution_x'].' X '.$file_analysis['video']['resolution_y'];
?>

Upvotes: 6

Related Questions