albfan / miracast-windows-sink

App implementing miracast protocol to act as a sink running under windows 10
0 stars 0 forks source link

Researching basic projects #1

Open albfan opened 5 years ago

albfan commented 5 years ago

hmm, as I think, Windows should provide samples for his features: Let's start from here:

albfan commented 5 years ago

more examples (for wifi direct):

https://docs.microsoft.com/en-us/uwp/api/windows.devices.wifidirect

albfan commented 5 years ago

https://github.com/Microsoft/Windows-universal-samples/tree/master/Samples/WiFiDirect discover other wifi direct devices (connector) or answer to others trying to pair (advertiser). It exposes a service that allows both devices two send messages to each other.

Devices:

This is the app finding my phone:

image

Or the app answering to a request from my phone to connect

screenshot_20180924-230333

image

Since service is a custom implementation I cannot make it work as my phone is not a windows 10 (so I should implement it on android) But anyone using both windows 10 phones should make it work out of the box

albfan commented 5 years ago

Second project https://github.com/Microsoft/Windows-universal-samples/tree/master/Samples/Projection

shows how to launch content to a know secondary display

https://docs.microsoft.com/en-us/uwp/api/windows.ui.viewmanagement.projectionmanager

image

Here the configuration of existing projects like https://github.com/albfan/miraclecast or https://github.com/intel/wds can help to configure the first example to expose a device by wifi direct that will be recognized as a secondary display (that is: implement miracast protocol)

About interaction with source, UIBC protocol allows sink device to send keyboard and mouse events to source

fcgll520 commented 5 years ago

hi, do you have some progress about the windows implementation?

albfan commented 5 years ago

I need a Windows machine to do further test. No sure if my dual boot windows 10 is still valid. Will do a quick check soon.

fcgll520 commented 5 years ago

i saw some softwares installed on windows, they use "WiFiDisplay.dll" to implement the miracast, do you have any idea about this library?

albfan commented 5 years ago

Windows come with support out of the box for Miracast (or WiFi display) so I think that's what that library is. Not sure why you ask here for a Windows DLL library, it it is for coding, Miracast is a protocol over WiFi direct, so you should be able to code it using this WiFi direct example https://docs.microsoft.com/en-us/windows/iot-core/connect-your-device/setupwifidirect. Maybe there's any other Miracast example.

fcgll520 commented 5 years ago

yes, it's a right direction, if i want to mirror an android's screen & audio to a PC by miracast protocol, not only windows devices. do you have any idea?

albfan commented 5 years ago

A PC can mean anything (linux, BSD, windows) I guess you refer to windows. That should work out of the box on windows 10.

fcgll520 commented 5 years ago

yes, the APIs of windows are not opened to the public, so it's hard to use. I just know "WFDDisplaySinkStartEx", but i don't know what its params are.