I try to make my Parrot AR Drone 2.0 work with a windows machine.
I have a simple C# application to control it - but now i want the video stream inside of my application.
If i execute ffplay tcp://192.168.1.1:5555
it connects to the videostream and shows a window with the video.
How can i get this video iside of my application? Like, a simple 'frame' or 'image' that gets filled with that content?
I have never worked that much with C# so any help would be awesome.
You can launch the
ffplay
process and then PInvokeSetParent
to place the player window inside your form andMoveWindow
to position it.To do this you would need to define the following.
Then you can use the two native methods like so.
The standard output of the
ffplay
process, the text you usually see in the command window is handled viaErrorDataReceived
. Setting the-loglevel
to something likefatal
in the arguments passed to ffplay allows you to reduce the amount of events raised and allows you to handle only real failures.My Code is this, How ever it is loading ffplay but don't move in to panel or don't position it to given
Have you tried streaming with media player? Just add the control from the toolbox on the form and then add the following code to your form.cs
Details in the following link