jacobbo / WebEye

WebEye is a collection of .NET controls.
190 stars 132 forks source link

Other WPF controls are unable to overlay StreamPlayerControl #41

Closed vzhadeyev closed 6 years ago

vzhadeyev commented 6 years ago

Is there a way to place other controls over StreamPlayerControl? No matter which ZIndex property is set, stream overwrites them (is that a problem of using hWnd pointer of a parent window to draw frames?).

jacobbo commented 6 years ago

No, sorry, the current implementation doesn't support this. The reason you mentioned is correct.

vzhadeyev commented 6 years ago

Found a general solution to add elements over hwnd hosted by an HwndHost. For now, checked only TextBlock image

jacobbo commented 6 years ago

Cool! Do you have to change the control to achieve this behavior?

vzhadeyev commented 6 years ago

Only a little bit. VideoWindow should be packed into HwndHostPresenter (helper class from mentioned solution). HwndHostPresenter can be used as control which Adornment property is your overalaying UI elements. I had no time to dive deep into solution, may be its author can provide more information.

Your project is very lightweight solution which helped to drop memory usage per single stream from 30Mb with VLC to 3-5Mb with WebEye. Thank you for that, waiting for improvements!