Using GStreamer with Direct3D11/Direct3D9 interop layer in .Net
There is no direct support in WPF to display UI elements over a D3D component due to the airspace issue. This project will tackle this issue by implementing a Direct3D11/Direct3D9 interop layer and by using the D3DImageEx class.
The D3DImageEx class will create a D3D11Texture which is created with the D3D11_RESOURCE_MISC_SHARED
. This texture will be used for the SetBackBuffer method and later used for the d3d11videosink element in the gstreamer code.
Sample project
GStreamer is a framework used for creating streaming media applications. In the sample project included in this repository we are creating a player which can play RTSP streams in WPF with a textbox overlay.
Download the NuGet package from https://www.nuget.org/packages/gstreamer-d3d11-overlay/
What You Need
The Direct3D11/Direct3D9 interop layer is based on the project http://jmorrill.hjtcentral.com/Home/tabid/428/EntryId/437/Direct3D-10-11-Direct2D-in-WPF.aspx by Jeremiah Morrill.