What codecs do I need?
September 1, 2009 12:05 AM   Subscribe

What tool can I use on Vista to look at a decrypted M2TS file and to find out what audio and video codecs it uses? (M2TS is the file format used on Blu-Ray disks.)
posted by Chocolate Pickle to Computers & Internet (16 answers total) 1 user marked this as a favorite
Both VLC and MPlayer have Windows ports... I'm pretty sure they'd at least be able to tell you what format the contained streams are in, even if they can't play them.
posted by hattifattener at 12:20 AM on September 1, 2009

Well, if the only possibilities are mpeg-2, mpeg-4 and vc-1, both VLC and SMPlayer will have the codecs you need out-of-box, but in the event that you really want to find out what codec a given m2ts container file requires, you can use the magic numbers to find out, although it's not always easy to check them. The first few digits in the file are supposed to be an indicator of the filetype (and since they tell the type, they'll see past the m2ts, which is only an indicator.) Here's a good table. mpeg-4 files will start with

00 00 00 18 66 74 79 70


33 67 70 35

while mpeg-2 files will start with

00 00 01 Bx

... the list doesn't have vc-1 files on it, so I don't know what those magic numbers are, but those should be enough to get you started. The only trouble you might have lies in the fact that these are hexadecimal numbers; I use Notepad++ to convert strings back and forth, personally. When you open the file, the program will automatically put the hex number in text, so you'll have to copy and paste the above, select it, and use Notepad++'s TextFX Convert>Convert Hex to text function to see what those hex figures above look like as text; then compare that text to the text at the very beginning of the video file in question.

A little complex, but it works.
posted by koeselitz at 1:41 AM on September 1, 2009

Geez, that's complicated enough. Sorry; should've just mentioned TrID; it's a command-line magic numbers reader that should identify in an instant what codec's inside your container.
posted by koeselitz at 1:48 AM on September 1, 2009 [1 favorite]

MediaInfo has a GUI and is updated frequently.
posted by Inspector.Gadget at 6:08 AM on September 1, 2009

MediaInfo doesn't seem to have M2TS listed as a supported container format. I can't tell if GSpot supports it, and I haven't any M2TS files handy to check, but it might. It's pretty similar to MediaInfo on the whole.
posted by Dysk at 6:37 AM on September 1, 2009

... yeah, I don't know if there's a checker available; looking at TrID, it appears that the only of the three formats in its library is mpeg-4. But, again, m2ts is a container format that can only contain either mpeg-2, mpeg-4 and vc codec files; and you can verify here that VLC player (which has working versions not only in Vista but in pretty much every operating system known to man, including Solaris and BeOS) can open these files (and in fact started supporting the m2ts container format in version 1.0 a few months ago). Therefore, even if you intend to open the file with another program or need this information for some other purpose, really the best thing to do would probably be to open the file in VLC player, go to Tools->Codec Information, and read the data there.

Of course, the VLC vs. MPlayer Classic battle online is like unto the editor wars of old, so I'm certain that SMPlayer (the frontend you'd probably use with Vista) would play these files as well.
posted by koeselitz at 7:34 AM on September 1, 2009

I'm not really interested in recommendations for a player program; I already have one that works. It's just that one of the M2TS files I've tried to play, I get video but no sound. I assume it's because it uses a strange audio codec, and I want to know what it is so that I can find it and install it.
posted by Chocolate Pickle at 7:38 AM on September 1, 2009

TrID says, "Unknown!"
posted by Chocolate Pickle at 7:43 AM on September 1, 2009

GSpot says, "Yup, that's MPEG2 Video" but it doesn't say what the audio is.
posted by Chocolate Pickle at 7:50 AM on September 1, 2009

MediaInfo says, "video is AVC, audio is PCM". Christ only knows why they used PCM, but now I know what the problem is and can work on it.
posted by Chocolate Pickle at 7:55 AM on September 1, 2009 [1 favorite]

Chocolate Pickle: I'm not really interested in recommendations for a player program; I already have one that works.

I know; but like I said, VLC Player is probably the only program that'll actually give you detailed information about the codecs. You don't have to use it, necessarily, but it will give you the rundown on the codeccs.
posted by koeselitz at 8:01 AM on September 1, 2009

Ah. What player are you using, if I may ask? I'm always on the lookout for new ones.
posted by koeselitz at 8:03 AM on September 1, 2009

I use Zoom Player.

And MediaInfo gave me a very detailed answer. Video: BDAV: 7.93 GiB, 26mn 52s. 1 video stream: 37.5 Mbps, 1920*1080 (16:9), at 23.976 fps, AVC (High@L4.1)(CBAC/4 ref Frames)
Audio: 1536 Kbps, 48.0 KHz, 2 channels, PCM (Blu-ray) (Big / Signed)

(Three different hate-filled rants about VLC deleted because this shouldn't be a chat-filter thread about player programs. Given that I had already posted that MediaInfo worked, your "probably the only program" is a bit strange.)
posted by Chocolate Pickle at 9:07 AM on September 1, 2009

Sorry, Chocolate Pickle; sincerely, I don't mean to be annoying and vexing. I was being an idiot, and had only read up to your first comment; I was taking Brother Dysk's comment above where he said that MediaInfo probably wouldn't work for this stuff. I'm not trying to evangelize about a media player; there's too much of that around already, and I never suggested you should give up what you're using and go with what I think you should use. I don't even use VLC myself much unless I want to look at codec info, it's just the next thing that popped into my head for checking the media info is all. Again, hope I didn't offend.
posted by koeselitz at 9:28 AM on September 1, 2009

Sorry if I overreacted.

Any time there's a question about Windows, there's sure to be someone who pops in and says, "Why not try Linux?"

Any time there's a question about Photoshop, you'll see someone say, "The GIMP is just as good, and it's free!"

Any time there's a question about IE, someone is bound to say, "You should be using FireFox."

And any time there's a question about playing media files, then sure as shooting somebody is going to mention VLC.

It gets to me, but I really shouldn't let it. So I do apologize in return if I was snippy.
posted by Chocolate Pickle at 1:33 PM on September 1, 2009

Just a note: for Blu-ray PCM to anything, eac3to is your friend because of m2ts container / bd playlist / seamless branching support built-in. My usual workflow is using eac3to to do PCM->FLAC and from there I can use whatever tool I want if I need to do lossy transcoding.
posted by Inspector.Gadget at 9:02 PM on September 1, 2009

« Older Back off Mrs. Kravitz   |   Croquet & Bocce Newer »
This thread is closed to new comments.