Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

Ownership of QSGTextureProvider object and of the QSGTexture object it provides



  • I have code like this:

    QQuickItem* texSource = /*...*/;
    QSGTextureProvider* texProvider = texSource->textureProvider();
    QSGTexture* tex = texProvider->texture();
    

    Should I delete texProvider and tex when I no longer need them? (which, for texProvider, means "right after I take the texture from it")

    I'd like answers to be supported with references.


Log in to reply