tags:

views:

49

answers:

1

For an installer I'm building, I need to be able to warn the user if they don't have an h264 codec installed. At this point in the process I don't have any such video to play or anything, I just need to detect the ability to do so. Is this possible?

Unfortunately I can't rely on the computer having anything much already installed, such as .Net or DirectX (other than whatever comes with plain Windows XP or later). The installer is written in C++.

A: 

According to this page, you can do this by either querying the registry (\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Drivers32\vidc*), or with DirectShow (probably better). The post by Toff on the page I linked to shows the DirectShow version.

Brendan Long
You really don't want to do the drivers32 thingy. That enumerates ACM codecs and I seriously doubt that anyone's going to write an ACM codec for h.264. Use DShow to enumerate the codecs, and use MediaFoundation to enumerate them (for Vista and beyond).
Larry Osterman