fpv-wtf / dji-moonlight-shim

Stream games to your DJI FPV goggles!
GNU General Public License v3.0
50 stars 1 forks source link

[Feature Request] Generic HDMI input to DJI goggles #14

Open macrokernel opened 10 months ago

macrokernel commented 10 months ago

I wonder if a Raspberry Pi or a similar reasonably priced SBC can be used for connecting Walksnail or HDZero VRX HDMI output to DJI goggles USB input? Something like DigiView or Cosmostreamer but the other way round. It would be a really nice device, as DJI is never going to release a 1s lightweight/whoop digital VTX, and buying another set of HD goggles is rather expensive.

j005u commented 10 months ago

It's possible with a combination of moonlight (which enables streaming your desktop/screen to the goggles) and a HDMI capture card combined together.

In practice however the capture card adds anywhere between 20-50ms of latency, so this isn't practical for actual flying. Also to pull this off on a raspi one would need to write a custom dji-moonlight-embedded alternative that would take h264 provided by the capture card and pipe it directly to the goggles. A raspi will most likely not be able to keep up if it has to decode the video stream and then re-encode it for supplying to the goggles - this is how the naive moonlight setup would work.

So the tl;dr; is it would be possible to develop a raspi based solution, but it wouldn't be practical for flight purposes due to HDMI capture cards always having quite a bit of latency. As such the core team currently has no intent to invest time into this, however as always we welcome any community contributions.

An alternative would be to write a user-space driver for UVC h264 capture cards, this way the raspi could be skipped altogether. Latency concerns remain however and this is technically pretty hard:tm:.

macrokernel commented 10 months ago

Thanks for your detailed reply Joonas. I've seen someone on YouTube using Moonlight for this purpose, but using a PC is not very handy. Sad to hear that an SBC-based solution is not practically feasible.