1

I'm trying to understand what Class means inside a File element and I can't find anything using google. The reason that I need to understand this is that I'm converting a WiX installer to InstallShield. According the the WiX docs Classes are COM components but I don't think that applies here (and if it does then I have a whole other question about how to use COM components in InstallShield, but I'll skip that question for now. Here's the code. Can someone please tell me what this is doing?

<File Id="pg_audio_sink.ax" KeyPath="yes" Source="$(var.DirectShow)\pg_audio_sink\Release\pg_audio_sink.ax">
      <Class Id="{7E4D071A-50B7-42D8-ADFE-B0C3715422B9}" Context="InprocServer32" Description="AAC Encoder" ThreadingModel="both" />
      <Class Id="{2A67EDA3-7AE8-494E-808C-60C1E2C992C1}" Context="InprocServer32" Description="Settings" ThreadingModel="both" />
      <Class Id="{AF94923E-31C7-483A-A2EA-57D86BF26AD7}" Context="InprocServer32" Description="Settings" ThreadingModel="both" />
</File>
Stein Åsmul
  • 39,960
  • 25
  • 91
  • 164
Ben_G
  • 770
  • 2
  • 8
  • 30
  • When looking at the file with dependency walker or some other tool to view exported functions, do you see `DllRegisterServer`? Installshield should be able to extract COM registration data for COM files by setting the component flag "[COM Extract at Build...](https://stackoverflow.com/a/52571564/129130)", but I am not sure this type of file can be registered in the normal way. – Stein Åsmul Nov 21 '18 at 04:23

1 Answers1

1

Can someone please tell me what this is doing?

This File element is to register pg_audio_sink.ax, which is DirectShow Filter.
See also:
How to Register DirectShow Filters
How to Implement IUnknown

Your code will create 3 registry key, and register pg_audio_sink.ax as COM server.

HKEY_CLASSES_ROOT\CLSID\{7E4D071A-50B7-42D8-ADFE-B0C3715422B9}
HKEY_CLASSES_ROOT\CLSID\{2A67EDA3-7AE8-494E-808C-60C1E2C992C1}
HKEY_CLASSES_ROOT\CLSID\{AF94923E-31C7-483A-A2EA-57D86BF26AD7}

DirectShow is based on COM.
So I think Class element in your code is for COM component.

chg
  • 205
  • 1
  • 5
  • 10