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

Display .tga files in QML



  • Hi,

    i need to display .tga file in QML.
    TGA is not supported by default by QT, but it seems to be possible using "Qt Add-Ons" and "Qt Image Formats":
    https://doc.qt.io/qt-5/qtmodules.html

    But how to do that ?

    i have also found "qtga.dll" in:
    C:\Qt\Qt5.8.0\5.8\msvc2013_64\plugins\imageformats

    So it seems to be possible to load .tga file in QT without coding my own loader... ? How ?


  • Moderators

    @Greg13 said in Display .tga files in QML:

    i have also found "qtga.dll" in:
    C:\Qt\Qt5.8.0\5.8\msvc2013_64\plugins\imageformats

    yes, so it should be possible to load .tga images.

    May be a stupid question but have you already tried to load a .tga image?

    Do you test from within QtCreator or with a deployed application?

    You can also try to set the QT_DEBUG_PLUGINS environment variable to any value and post all lines of console output related to qtga.dll when loading the image.



  • i have tried to display a .tga image in QML with:

    Image
    {
    width : 128
    height: 128
    source: "file:///C:/tamp/image.tga"
    }

    i have this error message:
    qrc:/QML/main.qml:285:13: QML Image: Error decoding: file:///C:/temp/image.tga: Unable to read image data

    i use QT 5.8 for Visual studio but using QTCreator. i launch my application using QTCreator 4.2.1.

    You can also try to set the QT_DEBUG_PLUGINS environment variable to any value and post all lines of console output related to qtga.dll when loading the image.
    i don't know how to load/use plugins in my project. i have added QT_DEBUG_PLUGINS in buid and i have this message:

    Démarrage de C:\dev\MyApp\Output\release\MyApp.exe...
    QFactoryLoader::QFactoryLoader() checking directory path "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms" ...
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qdirect2d.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qdirect2d.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
    "Keys": [
    "direct2d"
    ]
    },
    "className": "QWindowsDirect2DIntegrationPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("direct2d")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qdirect2dd.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qdirect2dd.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
    "Keys": [
    "direct2d"
    ]
    },
    "className": "QWindowsDirect2DIntegrationPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qdirect2dd.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qminimal.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qminimal.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
    "Keys": [
    "minimal"
    ]
    },
    "className": "QMinimalIntegrationPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("minimal")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qminimald.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qminimald.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
    "Keys": [
    "minimal"
    ]
    },
    "className": "QMinimalIntegrationPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qminimald.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qoffscreen.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qoffscreen.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
    "Keys": [
    "offscreen"
    ]
    },
    "className": "QOffscreenIntegrationPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("offscreen")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qoffscreend.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qoffscreend.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
    "Keys": [
    "offscreen"
    ]
    },
    "className": "QOffscreenIntegrationPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qoffscreend.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qwindows.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qwindows.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
    "Keys": [
    "windows"
    ]
    },
    "className": "QWindowsIntegrationPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("windows")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qwindowsd.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qwindowsd.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
    "MetaData": {
    "Keys": [
    "windows"
    ]
    },
    "className": "QWindowsIntegrationPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qwindowsd.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() checking directory path "C:/dev/MyApp/Output/release/platforms" ...
    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platforms/qwindows.dll"
    QFactoryLoader::QFactoryLoader() checking directory path "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/platformthemes" ...
    QFactoryLoader::QFactoryLoader() checking directory path "C:/dev/MyApp/Output/release/platformthemes" ...
    QFactoryLoader::QFactoryLoader() checking directory path "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/styles" ...
    QFactoryLoader::QFactoryLoader() checking directory path "C:/dev/MyApp/Output/release/styles" ...
    QFactoryLoader::QFactoryLoader() checking directory path "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats" ...
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qgif.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qgif.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "gif"
    ],
    "MimeTypes": [
    "image/gif"
    ]
    },
    "className": "QGifPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("gif")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qgifd.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qgifd.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "gif"
    ],
    "MimeTypes": [
    "image/gif"
    ]
    },
    "className": "QGifPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qgifd.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qicns.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qicns.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "icns"
    ],
    "MimeTypes": [
    "image/x-icns"
    ]
    },
    "className": "QICNSPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("icns")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qicnsd.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qicnsd.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "icns"
    ],
    "MimeTypes": [
    "image/x-icns"
    ]
    },
    "className": "QICNSPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qicnsd.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qico.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qico.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "ico",
    "cur"
    ],
    "MimeTypes": [
    "image/vnd.microsoft.icon"
    ]
    },
    "className": "QICOPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("ico", "cur")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qicod.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qicod.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "ico",
    "cur"
    ],
    "MimeTypes": [
    "image/vnd.microsoft.icon"
    ]
    },
    "className": "QICOPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qicod.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qjpeg.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qjpeg.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "jpg",
    "jpeg"
    ],
    "MimeTypes": [
    "image/jpeg",
    "image/jpeg"
    ]
    },
    "className": "QJpegPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("jpg", "jpeg")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qjpegd.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qjpegd.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "jpg",
    "jpeg"
    ],
    "MimeTypes": [
    "image/jpeg",
    "image/jpeg"
    ]
    },
    "className": "QJpegPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qjpegd.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qsvg.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qsvg.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "svg",
    "svgz"
    ],
    "MimeTypes": [
    "image/svg+xml",
    "image/svg+xml-compressed"
    ]
    },
    "className": "QSvgPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("svg", "svgz")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qsvgd.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qsvgd.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "svg",
    "svgz"
    ],
    "MimeTypes": [
    "image/svg+xml",
    "image/svg+xml-compressed"
    ]
    },
    "className": "QSvgPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qsvgd.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtga.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtga.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "tga"
    ],
    "MimeTypes": [
    "image/x-tga"
    ]
    },
    "className": "QTgaPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("tga")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtgad.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtgad.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "tga"
    ],
    "MimeTypes": [
    "image/x-tga"
    ]
    },
    "className": "QTgaPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtgad.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtiff.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtiff.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "tiff",
    "tif"
    ],
    "MimeTypes": [
    "image/tiff",
    "image/tiff"
    ]
    },
    "className": "QTiffPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("tiff", "tif")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtiffd.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtiffd.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "tiff",
    "tif"
    ],
    "MimeTypes": [
    "image/tiff",
    "image/tiff"
    ]
    },
    "className": "QTiffPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtiffd.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwbmp.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwbmp.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "wbmp"
    ],
    "MimeTypes": [
    "image/vnd.wap.wbmp"
    ]
    },
    "className": "QWbmpPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("wbmp")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwbmpd.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwbmpd.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "wbmp"
    ],
    "MimeTypes": [
    "image/vnd.wap.wbmp"
    ]
    },
    "className": "QWbmpPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwbmpd.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwebp.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwebp.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "webp"
    ],
    "MimeTypes": [
    "image/webp"
    ]
    },
    "className": "QWebpPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("webp")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwebpd.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwebpd.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QImageIOHandlerFactoryInterface",
    "MetaData": {
    "Keys": [
    "webp"
    ],
    "MimeTypes": [
    "image/webp"
    ]
    },
    "className": "QWebpPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwebpd.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() checking directory path "C:/dev/MyApp/Output/release/imageformats" ...
    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qgif.dll"
    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qicns.dll"
    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qico.dll"
    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qjpeg.dll"
    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qsvg.dll"
    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtga.dll"
    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qtiff.dll"
    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwbmp.dll"
    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/imageformats/qwebp.dll"
    QFactoryLoader::QFactoryLoader() checking directory path "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/accessible" ...
    QFactoryLoader::QFactoryLoader() checking directory path "C:/dev/MyApp/Output/release/accessible" ...
    QFactoryLoader::QFactoryLoader() checking directory path "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/iconengines" ...
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/iconengines/qsvgicon.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/iconengines/qsvgicon.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QIconEngineFactoryInterface",
    "MetaData": {
    "Keys": [
    "svg",
    "svgz",
    "svg.gz"
    ]
    },
    "className": "QSvgIconPlugin",
    "debug": false,
    "version": 329728
    }

    Got keys from plugin meta data ("svg", "svgz", "svg.gz")
    QFactoryLoader::QFactoryLoader() looking at "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/iconengines/qsvgicond.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/iconengines/qsvgicond.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QIconEngineFactoryInterface",
    "MetaData": {
    "Keys": [
    "svg",
    "svgz",
    "svg.gz"
    ]
    },
    "className": "QSvgIconPlugin",
    "debug": true,
    "version": 329728
    }

    "The plugin 'C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/iconengines/qsvgicond.dll' uses incompatible Qt library. (Cannot mix debug and release libraries.)"
    not a plugin
    QFactoryLoader::QFactoryLoader() checking directory path "C:/dev/MyApp/Output/release/iconengines" ...
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick.2/qtquick2plugin.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QQmlExtensionInterface/1.0",
    "MetaData": {
    },
    "className": "QtQuick2Plugin",
    "debug": false,
    "uri": [
    "QtQuick.2"
    ],
    "version": 329728
    }

    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick.2/qtquick2plugin.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Controls.2/qtquickcontrols2plugin.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QQmlExtensionInterface/1.0",
    "MetaData": {
    },
    "className": "QtQuickControls2Plugin",
    "debug": false,
    "uri": [
    "QtQuick.Controls.2"
    ],
    "version": 329728
    }

    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Controls.2/qtquickcontrols2plugin.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Window.2/windowplugin.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QQmlExtensionInterface/1.0",
    "MetaData": {
    },
    "className": "QtQuick2WindowPlugin",
    "debug": false,
    "uri": [
    "QtQuick.Window.2"
    ],
    "version": 329728
    }

    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Window.2/windowplugin.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Dialogs/dialogplugin.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QQmlExtensionInterface/1.0",
    "MetaData": {
    },
    "className": "QtQuick2DialogsPlugin",
    "debug": false,
    "uri": [
    "QtQuick.Dialogs"
    ],
    "version": 329728
    }

    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Dialogs/dialogplugin.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Controls/qtquickcontrolsplugin.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QQmlExtensionInterface/1.0",
    "MetaData": {
    },
    "className": "QtQuickControls1Plugin",
    "debug": false,
    "uri": [
    "QtQuick.Controls"
    ],
    "version": 329728
    }

    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Controls/qtquickcontrolsplugin.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Templates.2/qtquicktemplates2plugin.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QQmlExtensionInterface/1.0",
    "MetaData": {
    },
    "className": "QtQuickTemplates2Plugin",
    "debug": false,
    "uri": [
    "QtQuick.Templates.2"
    ],
    "version": 329728
    }

    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Templates.2/qtquicktemplates2plugin.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Dialogs/Private/dialogsprivateplugin.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QQmlExtensionInterface/1.0",
    "MetaData": {
    },
    "className": "QtQuick2DialogsPrivatePlugin",
    "debug": false,
    "uri": [
    "QtQuick.Dialogs.Private"
    ],
    "version": 329728
    }

    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Dialogs/Private/dialogsprivateplugin.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Layouts/qquicklayoutsplugin.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QQmlExtensionInterface/1.0",
    "MetaData": {
    },
    "className": "QtQuickLayoutsPlugin",
    "debug": false,
    "uri": [
    "QtQuick.Layouts"
    ],
    "version": 329728
    }

    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/Layouts/qquicklayoutsplugin.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/Qt/labs/folderlistmodel/qmlfolderlistmodelplugin.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QQmlExtensionInterface/1.0",
    "MetaData": {
    },
    "className": "QmlFolderListModelPlugin",
    "debug": false,
    "uri": [
    "Qt.labs.folderlistmodel"
    ],
    "version": 329728
    }

    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/Qt/labs/folderlistmodel/qmlfolderlistmodelplugin.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/Qt/labs/settings/qmlsettingsplugin.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QQmlExtensionInterface/1.0",
    "MetaData": {
    },
    "className": "QmlSettingsPlugin",
    "debug": false,
    "uri": [
    "Qt.labs.settings"
    ],
    "version": 329728
    }

    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/Qt/labs/settings/qmlsettingsplugin.dll"
    Found metadata in lib C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/PrivateWidgets/widgetsplugin.dll, metadata=
    {
    "IID": "org.qt-project.Qt.QQmlExtensionInterface/1.0",
    "MetaData": {
    },
    "className": "QtQuick2PrivateWidgetsPlugin",
    "debug": false,
    "uri": [
    "QtQuick.PrivateWidgets"
    ],
    "version": 329728
    }

    loaded library "C:/Qt/Qt5.8.0/5.8/msvc2013_64/qml/QtQuick/PrivateWidgets/widgetsplugin.dll"
    QFactoryLoader::QFactoryLoader() checking directory path "C:/Qt/Qt5.8.0/5.8/msvc2013_64/plugins/accessiblebridge" ...
    QFactoryLoader::QFactoryLoader() checking directory path "C:/dev/MyApp/Output/release/accessiblebridge" ...


  • Moderators

    @Greg13 said in Display .tga files in QML:

    file:///C:/temp/image.tga: Unable to read image data

    so your tga plugin can be loaded, but the plugin can't load the image file.
    Are you sure the image data isn't corrupted and the file is accessible for reading?



  • i have used images saved from irfanview and Paint.Net in 24 and 32 bits, with and without RLE compression.



  • To solve the problem i use QQuickImageProvider and QPixmap::fromImage() and i load .tga by myselft.

    But i am interested if someone can load .tga using QT libraries.


Log in to reply