Reusable Code

In general, the source files with the same names as the executable files contain throwaway wrapper code, and the others have functions you may be able to use "as is." Even if you cannot just reuse them, they are what you'll have to read in order to write your own. Here is a quick list of the most interesting functions. All return S_OK if successful, and a fatal HRESULT otherwise; there are no warnings.