Finding a filter's DirectShow category

試著忘記壹切 提交于 2021-01-28 10:29:23

问题


Given a filter or a hardware device or its moniker, how can I find out what DirectShow category that filter or hardware device belongs to? Is there some kind of a "Category" property somewhere in the PropertyBag?


回答1:


DirectShow categories contain filter registration information in terms that it is possible to create a monitor out of registration entry. Once moniker is created you don't yet have a filter but category information is already gone at this point. Creating an instance of filter from moniker obviously does not get you category back.

Also it is possible to have one filter regisered in multiple categories, and it is also possible to register a [third party] filter into a category without filter being aware of it at all.

So, no, you cannot find out filter's category when you have a filter. Sometimes you can get CLSID from instance and match it back by enumerating a categories, but even this would not work for every filter.



来源:https://stackoverflow.com/questions/65255237/finding-a-filters-directshow-category

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!