It is currently prototyping a Windows.NET application that should play high definition WMV and H264 videos. My test files are full 1080p.
The target hardware has weak Atom processors, but a high NVidia 9400 graphics card. I know the graphics are integrated, but I understand that they are good for video playback.
Testing in Windows 7, if I play my test files in WPF using the MediaElement control, my CPU usage is 0.
However, the target OS is Windows XP, and we may not have .NET 3.0. Therefore, the application must run in WinForms. For various reasons, Windows Media Player ActiveX is not an option. So, we are looking at DirectShow.
I compiled a player using DirectShow.NET by playing the video in full screen using VMR9. Using this approach, my WMV files consume somewhere between 20-30% of the CPU. I had to install muxer / demuxer mp4 to even get H264 files, and then they consumed 40-50% of the CPU.
- I know that Windows 7 supports H264 out of the box. However, it seems this is not a DirectShow filter?
- Why is my video accelerated using WPF, but not when using DirectShow? I understand that DirectShow supports DXvA.
TL; DR: how can I achieve hardware acceleration of video playback in WMV and H264 in WinForms?
Thanks!
Thenextman
source share