title: Selecting a Capture Device Using the System Device Enumerator
body: <p>I was tring to use this link: <a href="http://msdn.microsoft.com/en-us/library/dd377566%28v=VS.85%29.aspx" rel="nofollow">http://msdn.microsoft.com/en-us/library/dd377566%28v=VS.85%29.aspx</a>, to select a capturing device.</p>
  
  <p>Works perfectly on Visual Studio, but throws the following error QT:</p>
  
  <pre><code> test.obj : error LNK2005: _main already defined in main.obj
    test.obj : error LNK2019: unresolved external symbol __imp__CoCreateInstance@20   referenced in function "long __cdecl EnumerateDevices(struct _GUID const &amp;,struct IEnumMoniker * *)" (?EnumerateDevices@@YAJABU_GUID@@PAPAUIEnumMoniker@@@Z)
    test.obj : error LNK2019: unresolved external symbol __imp__VariantClear@4 referenced in function "void __cdecl DisplayDeviceInformation(struct IEnumMoniker *)" (?DisplayDeviceInformation@@YAXPAUIEnumMoniker@@@Z)
    test.obj : error LNK2019: unresolved external symbol __imp__VariantInit@4 referenced in function "void __cdecl DisplayDeviceInformation(struct IEnumMoniker *)" (?DisplayDeviceInformation@@YAXPAUIEnumMoniker@@@Z)
   test.obj : error LNK2019: unresolved external symbol __imp__CoUninitialize@0 referenced in function _main
  test.obj : error LNK2019: unresolved external symbol __imp__CoInitializeEx@8 referenced in function _main
  </code></pre>
  
  <p>I'm using windows 7 &amp; QT 5.0.2.</p>
  
  <p>Any help will be appreciated thanks.</p>