|
Jan
15
Written by:
Jeremiah Morrill
1/15/2009 1:42 AM
I have been spending my free time, looking on how to support MediaFoundation and the EVR in the WPF MediaKit. MediaFoundation in Vista is pretty incomplete, used mostly for protected media path stuff like Blu-Ray. MediaFoundation will finally play a big part in multimedia in Windows 7. It will be able to play most popular media formats right out of the box. Step one (the most important step) is to make an EVR custom presenter. Of course I want to be done in all C# and this is where all my problems began. I've been using the MediaFoundation.NET PIA library, but unfortunately all the EVR custom presenter IDL conversions are untested. . . and for sure didn't work. After a lot of many, many long nights of hacking, I ended up stuck on a problem. But after more and more hacking it has been solved. The rest of the EVR custom presenter should be relatively easy. If I have time this weekend, I may be able to get a beta out soon. Any of you excited for MF/EVR support? Or do most of ya'll not give a crap? -Jer
Tags:
13 comment(s) so far...
Re: EVR and MediaFoundation Support Coming to WPF MediaKit
Great news, I am thinking of completely abandoning mediaelement. Just one problem I have been facing in wpfmediakit is that I am unable to include the audio in the VideoCapturePlayer. I have tried modifying the SetupGraph but in vain. Is there something I am missing?
By Jaspreet on
1/15/2009 5:13 AM
|
Re: EVR and MediaFoundation Support Coming to WPF MediaKit
If MF makes it easier, then im excited. However if its like everything else that microsoft release, its going to be several versions off being a good product.
They kinda hint that bluray is doable in MF. this would get me interested.
Anton
PS, mediakit is working a treat for me
By Anton on
1/15/2009 8:18 AM
|
Re: EVR and MediaFoundation Support Coming to WPF MediaKit
Jer,
I'm definitely interested in EVR support ... how do you think the performance will compare with your VMR9 work?
-Eric
By Eric Meyer on
1/22/2009 10:22 AM
|
Re: EVR and MediaFoundation Support Coming to WPF MediaKit
EVR support would be really great! Not only does it provide better framerate stability but it also uses DXVA2 acceleration to achieve better deinterlacing through the GPU (if supported). Rendering performance is slightly lower for me, but only few percent (which are good invested I think for more stable frame rate).
It is too bad that most of my users still have Windows XP, so I am stuck with leaving the WinForms approach in for backwards compatibility (WPF has no VSync on XP so you get tearing on the video). If most had Vista then I'd completely drop the messy WinForms interop layer and could make use of the cool possibilities that direct rendering to WPF provides.
Media Foundation is not really useable right now. As long as they do not provide better native support and something like a "BluRayNavigator" similar to the DVDNavigator to do the hard bits, I do not intend to use it (except for the EVR part which I am using right now but only through WinForms layer :-/ ). It is great to hear what you said about MF and Windows 7, I will perhaps start taking a look at the beta if I find the time!
Lukas
By Lukas on
1/25/2009 10:06 AM
|
Re: EVR and MediaFoundation Support Coming to WPF MediaKit
Hey Jer, good to see I'm not the only crazy bastard. I too started an EVR presenter for WPF. Turned out to be a waste of time though after talking to some guys at Microsoft. As it turns out MediaElement uses an internal "rapid update" call in their EVR presenter implementation -- so we're never ever going to achieve MediaElement's frame rate via D3DImage et al. I'm betting EVR will yield the exact same results you're getting with VMR9.
On an unrelated note... you might be interested in writing your MediaElement hack filter in C# to avoid the COM rego thing... Thats is what I do for sichbopvr (custom TS recording sink, and then source filter/mpeg 2 & 4 demux, all in C# etc -- no COM register required.) I've uploaded an example here for ya (and anyone else i guess); www.sichbo.ca/Free_Code/100_C_Sharp_directshow_filters
In the meantime I've given up on MediaElement and embedded WPF video in my project. The ME's playback behaviour is unpredictable when the video source is not necessarily present (say a satellite feed for instance with delayed tuning, no frames ready to push during the "Play()" call.)
Good luck with the EVR presenter anyway! it'll be a good reference if nothing else. Maybe some day MS will find a business reason to expose their private rapid update function.
By Sichbo on
1/27/2009 6:24 PM
|
Re: EVR and MediaFoundation Support Coming to WPF MediaKit
Sichbo, your code for the C# filter looks great. I can't wait to give it a shot!!
I'm not really writing an EVR presenter for better performance, but more of a compatibility piece for MediaFoundation (DShow is going the way of Winforms)...And because the VMR9 seems to scale the color for HD TV (ie 16-235)...With no way to configure it. EVR does something similar depending on the driver, but it seems most new video drivers have support for turning this off.
I agree and I do expect general performance to be near VMR9 as they both eventually use WPF to render via D3DImage. On my rig, D3DImage is incredibly fast, showing little CPU with just updates of the surface, even with 1080p surfaces. I do expect better performance in certain situations though, such as DXVA2 and other special duties of the EVR (ie deinterlacing).
I'm not sure what rapid update function MS is referring to, but I suspect its more related to the EVR presenter updates being synced to the render thread of WPF, not the UI thread like D3DImage is.
Thanks again for sharing that code!
By Jeremiah Morrill on
1/27/2009 6:48 PM
|
Re: EVR and MediaFoundation Support Coming to WPF MediaKit
I'm definitely interested in EVR support ... how do you think the performance will compare with your VMR9 work?
By replica Dior-Handbag on
1/5/2010 11:16 PM
|
Re: EVR and MediaFoundation Support Coming to WPF MediaKit
buy LV bags online www.bag-brand.net
By ルイ?ヴィトン on
1/18/2010 2:08 AM
|
Re: EVR and MediaFoundation Support Coming to WPF MediaKit
jordan shoes, gucci shoes, cheap jordan shoes Thank you for sharing out gucci handbags, air jordans, gucci shoes for men
By jordan shoes on
3/5/2010 6:29 PM
|
Re: EVR and MediaFoundation Support Coming to WPF MediaKit
thank you for your great post, and I did want to share this. I hope you will also like it, if you think it is spamming, please kindly delete it. thank you!abercrombie see what is this? abercrombie and fitch uk abercrombie and fitch abercrombie fitch uk abercrombie mens abercrombie london
By abercrombie clothing on
3/11/2010 6:19 AM
|
|
ed hardy
ED Hardy Hoodies ED Hardy Hoodies Ed Hardy Swimwear Ed Hardy Swimwear ed hardy tops ed hardy tops ed hardy shoes ed hardy shoes ed hardy t shirt ed hardy t shirt ed hardy shirts ed hardy shirts christian audigier christian audigier ed hardy kids ed hardy kids Ed Hardy Sunglasses Ed Hardy Sunglasses ED Hardy belts ED Hardy belts ed hardy Bags ed hardy Bags ed hardy purse ed hardy purse ed hardy mens ed hardy mens ed hardy womens d hardy womens ed hardy mens shirts ed hardy mens shirts ed hardy mens tops ed hardy mens tops ed hardy mens hoodies d hardy mens hoodies ed hardy mens swim trunks ed hardy mens swim trunks ed hardy mens shoes ed hardy mens shoes ed hardy womens swimwear ed hardy womens swimwear ed hardy womens t shirt ed hardy womens t shirt ed hardy womens tops ed hardy womens tops ed hardy womens pants ed hardy womens pants ed hardy womens hoodies ed hardy womens hoodies ed hardy womens shoes ed hardy womens shoes ed hardy womens clothing ed hardy womens clothing
By ed hardy on
3/15/2010 9:30 PM
|
cheap nike shox
There are wide variety of Nike Shox for both men and women's selection.The Nike Shox Sale are best selling nowadays.Get your own Cheap Nike Shox now.It's definitely time for you to buy womens nike shox and wens nike shox, Wearing them will keep you in a perfect condition.
By nike shox on
3/16/2010 10:31 PM
|
|
|
|