Hello,
So in short, I’d like to do this:
In depth, we are developping a QtQuick application on a Toradex Apalis iMX8
with boot2qt and we’d like it to be usable on an HDMI display (already
working) as well as remotely via a web navigator (at the same time). I watched
the webinar here: - YouTube
LQPk0A&feature=emb_logo
But it doesn’t help me much and I can’t find some code examples anywhere on
how to implement it.
Qt told me to simply use “-platform webgl” but this does not run my app in mirror mode between my hdmi display and a web navigator.
I hope you can help me.
Do not hesitate to ask me questions, I know my problem is poorly explained.
Regards
Hi @Romain.Donze
What “-platform webgl” does it starts a new instance of the application but then uses webgl for rendering. This means it is not exactly a mirroring but a second instance running with a different display device. What you can do is use Qt remote objects to synchronize the states between two applications which allows you to then “mirror” the screen. However, it needs some modification to the source code. You can check this repository:
There you find the demo code we used for the video above (it’s not in a clean state). We used a replica definition:
However, I think there is also a way to generate the bindings on the fly. See this article from Qt:
https://doc.qt.io/qt-5/qtremoteobjects-gettingstarted.html
I hope this helps.
Regards,
Stefan