how to change OutPut Pin Size & ColorSpace/Compression in DirectShow

痞子三分冷 提交于 2019-12-09 03:51:27

问题


how to change OutPut Pin Size & ColorSpace/Compression of a Video Source Filter in DirectShow

I want to Know whre the Output Pin PropertyPage Datas are stored and how can I Change those Datas By My Code


回答1:


You can use IPin::EnumMediaTypes on your filter's output pin to get a list of supported media types / video formats.

Afterwards, call IAMStreamConfig::GetFormat to get the current format in an AM_MEDIA_TYPE structure. Modify this structure as you wish (make sure your format is supported by the device), and call IAMStreamConfig::SetFormat with the same structure.




回答2:


You would have to write your own transformation filter. Or you can use a filter like FFDShow that supports image resizing among other video modifications and enhancements.



来源:https://stackoverflow.com/questions/708862/how-to-change-output-pin-size-colorspace-compression-in-directshow

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