Short term

Long term

Once basic function works, Then we can focus on driver side, and USB, there are lots of work challenge, also lots of fun.

Windows WDDM Driver

We can’t port virtualbox’s WDDM guest addition driver to host directly, just like what i did for XPDM driver. Based on MSND If multiple graphics adapters are present in a system, all of them must use the same WDDM driver. So WDDM driver is not easy.

1. WDDM Hook
We can do a WDDM Hook, if request for real hardware, then just pass it to under line real driver. otherwise handle by our virtual driver. Anshul Makkar did some research on this approach. But didn’t handle any GPU command. VirtualBox Guest addition WDDM driver is using chromium to handle GPU command. and probably can use WDDM Hook + chromium to implement this.

2. Virtual output connector
usually a real GPU has multipule output connector. e.g. for my thinkpad T430, there are following connector avalible:

if you connect a external monitor to VGA1, then it will generate an interrupt, and GPU’s interrupt handler will be called, and it will read EDID through IIC bus, then driver will get enough information. e.g. the verdon of the connected monitor, and the supported resolution. probally, we can simulate this process. Then GPU driver handle all Command, and We just dump out the frame buffer.

Linux Driver

1. Re use VirtualBox Guest addition driver, and it support lot’s of Linux version, e.g. Fedora/Ubuntu.

2. Using the ihadzic’s Virtual CRTC approach. his code are here And his proposal are here He implement this for AMD/ATI Radeon GPU. For different GPU, it requires different implementation.
A better way is implement a uniform interface on DRM, DRM query under layer GPU driver if it is support Virtual CRTC feature. if it is, then the driver need regist some callback to drm layer during driver initialization.

USB support

The goal of VirtualMonitor is make any Mobile device or compute can be used as a monitor. So USB support is important. we can use libusb. but for USB, we can’t use web browser any more. we need a program run on device side.