Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Animated Gif Error
Qt 6.11 is out! See what's new in the release blog

Animated Gif Error

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
5 Posts 3 Posters 5.0k Views 3 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    Mr .Wu
    wrote on last edited by
    #1

    I have written a demo like this :

    import QtQuick 2.5
    import QtQuick.Controls 1.4
    
    ApplicationWindow {
        visible: true
        width: 240
        height: 240
        color: "black"
        flags: Qt.FramelessWindowHint // 无边框
    
        Rectangle {
            width: 240; height: 240
            AnimatedImage { id: animation; source: "qrc:/test.gif" }
        }
    }
    

    The application ran successfully on PC Linux . When I running on Embedded platform ,it caused an exception . "Qml AnimatedImage : Error Reading Animated Image File qrc:/test.gif"

    raven-worxR 1 Reply Last reply
    1
    • M Mr .Wu

      I have written a demo like this :

      import QtQuick 2.5
      import QtQuick.Controls 1.4
      
      ApplicationWindow {
          visible: true
          width: 240
          height: 240
          color: "black"
          flags: Qt.FramelessWindowHint // 无边框
      
          Rectangle {
              width: 240; height: 240
              AnimatedImage { id: animation; source: "qrc:/test.gif" }
          }
      }
      

      The application ran successfully on PC Linux . When I running on Embedded platform ,it caused an exception . "Qml AnimatedImage : Error Reading Animated Image File qrc:/test.gif"

      raven-worxR Offline
      raven-worxR Offline
      raven-worx
      Moderators
      wrote on last edited by raven-worx
      #2

      @Mr-.Wu
      did you maybe forget to deploy Qt's gif imageformat plugin?

      --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
      If you have a question please use the forum so others can benefit from the solution in the future

      M 1 Reply Last reply
      2
      • raven-worxR raven-worx

        @Mr-.Wu
        did you maybe forget to deploy Qt's gif imageformat plugin?

        M Offline
        M Offline
        Mr .Wu
        wrote on last edited by
        #3

        @raven-worx said in Animated Gif Error:

        imageformat

        how to deploy qt‘s git image format plugin ? can you give a demo or link ? Thansk

        raven-worxR 1 Reply Last reply
        0
        • M Mr .Wu

          @raven-worx said in Animated Gif Error:

          imageformat

          how to deploy qt‘s git image format plugin ? can you give a demo or link ? Thansk

          raven-worxR Offline
          raven-worxR Offline
          raven-worx
          Moderators
          wrote on last edited by
          #4

          @Mr-.Wu
          Qt Linux deployment

          --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
          If you have a question please use the forum so others can benefit from the solution in the future

          1 Reply Last reply
          1
          • Y Offline
            Y Offline
            Yannick_SI
            wrote on last edited by
            #5

            Just encountered the same issue. If it can help someone, here is the solution I used :
            Now the GIF support doesn't require a plugin anymore, it is in the "Core Qt GUI library" (http://doc.qt.io/qt-5/qtimageformats-index.html).
            If the Error message happens on Embedded platform, most likely your Qt base have been compiled without gif support.

            In my case (Yocto environment), the solution was simply to add a qtbase bbappend file, with this line :

            PACKAGECONFIG_append = "gif"
            
            1 Reply Last reply
            2

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved