How to create a QSGTexture (Metal and d3d) with new rhi backend (Qt 5.15)
Unsolved
General and Desktop
-
The title is quite self explanatory, I need to create a QSGTexture for the two different api (Metal and d3d).
For opengl I used to call:
auto qsgtexture = qwindow.createTextureFromImage(....)
This seems returning a nullptr if the scenegraph is initialized with a different backend from opengl.
What is the best new way to create such a texture with the new Rhi?
The follow up question would be, can I give the returned
QSGTexture
to aQSGSimpleTextureNode
usingnode.setTexture(qsgtexture);
?I am currently working with the latest Qt 5.15
Thanks
L