omegaweaponZ has asked for the wisdom of the Perl Monks concerning the following question:

UPDATE - Disregard this post please....file itself had issues. Other TS files work (although MP4 does give more info and several fields are null in TS files, for reference)

I'm currently looking for a way to determine length of a media file clip from a TS file. I am using the Media Info package and this works fine for an MP4 clip but for a TS clip I can only get the filesize. Is this a common problem for this filetype and if so, is there a way around this to somehow get the length of a clip? Using the Windows version of Media Info I seem to have no problem in determining the file length, but the linux/unix and perl package they don't seem to work. Here is my code for reference, although it doesn't differ much from the instructions:

use Mediainfo; my $foo_info = new Mediainfo("filename" => "/my/path/test.ts"); print $foo_info->{filename}, "\n"; #Works print $foo_info->{filesize}, "\n"; #Works print $foo_info->{container}, "\n"; #Doesn't Work print $foo_info->{length}, "\n"; #Doesn't Work #Etc...nothing else works