Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. General talk
  3. Qt 6
  4. DDS image format plugin

DDS image format plugin

Scheduled Pinned Locked Moved Unsolved Qt 6
13 Posts 3 Posters 1.4k Views
  • 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.
  • Q Offline
    Q Offline
    QMLEngine
    wrote on 22 Dec 2023, 07:01 last edited by
    #1

    Hello,
    I want to use DDS raw data or DDS images in my application, but QT doesn't support DDS image format after 5.8 and it has DDS plugin in qtimageformats folder but I couldn't find how to use it in my application. Is there anyone who can help me?

    C 1 Reply Last reply 22 Dec 2023, 07:03
    0
    • Q QMLEngine
      22 Dec 2023, 07:01

      Hello,
      I want to use DDS raw data or DDS images in my application, but QT doesn't support DDS image format after 5.8 and it has DDS plugin in qtimageformats folder but I couldn't find how to use it in my application. Is there anyone who can help me?

      C Online
      C Online
      Christian Ehrlicher
      Lifetime Qt Champion
      wrote on 22 Dec 2023, 07:03 last edited by
      #2

      The dds plugin is no longer supported with Qt6 but the code is still in the QtImageFormats git repo so you have to make it compile with Qt6 and build it by yourself.

      Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
      Visit the Qt Academy at https://academy.qt.io/catalog

      1 Reply Last reply
      1
      • Q Offline
        Q Offline
        QMLEngine
        wrote on 25 Dec 2023, 12:23 last edited by
        #3

        Can you give the link and explain how to use ?

        C S 2 Replies Last reply 25 Dec 2023, 15:12
        0
        • Q QMLEngine
          25 Dec 2023, 12:23

          Can you give the link and explain how to use ?

          C Online
          C Online
          Christian Ehrlicher
          Lifetime Qt Champion
          wrote on 25 Dec 2023, 15:12 last edited by
          #4

          Not really. Checkout the QtImageFormats repo and try to make the dds plugin compile.

          Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
          Visit the Qt Academy at https://academy.qt.io/catalog

          1 Reply Last reply
          0
          • Q QMLEngine
            25 Dec 2023, 12:23

            Can you give the link and explain how to use ?

            S Offline
            S Offline
            SGaist
            Lifetime Qt Champion
            wrote on 25 Dec 2023, 19:30 last edited by
            #5

            @QMLEngine Hi,

            How to use the plugin ? The same way any of the other plugins is used: load a .dds file.

            As for the building the plugin:

            • Clone the qtimageformats repository
            • Add the necessary CMake bits and CMakeLists.txt so the dds subfolder content is built.
            • Fix code issues in the plugin.

            For the cmake bits, simply look at the other plugins around the dds. Note that the dds plugin has no external dependencies.

            Interested in AI ? www.idiap.ch
            Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

            Q 1 Reply Last reply 26 Dec 2023, 12:25
            1
            • S SGaist
              25 Dec 2023, 19:30

              @QMLEngine Hi,

              How to use the plugin ? The same way any of the other plugins is used: load a .dds file.

              As for the building the plugin:

              • Clone the qtimageformats repository
              • Add the necessary CMake bits and CMakeLists.txt so the dds subfolder content is built.
              • Fix code issues in the plugin.

              For the cmake bits, simply look at the other plugins around the dds. Note that the dds plugin has no external dependencies.

              Q Offline
              Q Offline
              QMLEngine
              wrote on 26 Dec 2023, 12:25 last edited by QMLEngine
              #6

              @SGaist it is okey but when I go to qtimageformats/src/plugins/imageformats/dds, dds folder is only one which has not any cmake.txt to compile and I do not know why. So, I got struggled for creating a new cmake.txt by looking others.

              C 1 Reply Last reply 26 Dec 2023, 12:27
              0
              • Q QMLEngine
                26 Dec 2023, 12:25

                @SGaist it is okey but when I go to qtimageformats/src/plugins/imageformats/dds, dds folder is only one which has not any cmake.txt to compile and I do not know why. So, I got struggled for creating a new cmake.txt by looking others.

                C Online
                C Online
                Christian Ehrlicher
                Lifetime Qt Champion
                wrote on 26 Dec 2023, 12:27 last edited by
                #7

                @QMLEngine said in DDS image format plugin:

                which has not any cmake.txt for compile and I do not know why

                Because of

                The dds plugin is no longer supported with Qt6 but the code is still in the QtImageFormats git repo so you have to make it compile with Qt6 and build it by yourself.

                @SGaist told you what to do:

                As for the building the plugin:

                Clone the qtimageformats repository
                Add the necessary CMake bits and CMakeLists.txt so the dds subfolder content is built.
                Fix code issues in the plugin.

                Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
                Visit the Qt Academy at https://academy.qt.io/catalog

                Q 1 Reply Last reply 26 Dec 2023, 12:36
                0
                • C Christian Ehrlicher
                  26 Dec 2023, 12:27

                  @QMLEngine said in DDS image format plugin:

                  which has not any cmake.txt for compile and I do not know why

                  Because of

                  The dds plugin is no longer supported with Qt6 but the code is still in the QtImageFormats git repo so you have to make it compile with Qt6 and build it by yourself.

                  @SGaist told you what to do:

                  As for the building the plugin:

                  Clone the qtimageformats repository
                  Add the necessary CMake bits and CMakeLists.txt so the dds subfolder content is built.
                  Fix code issues in the plugin.

                  Q Offline
                  Q Offline
                  QMLEngine
                  wrote on 26 Dec 2023, 12:36 last edited by
                  #8

                  @Christian-Ehrlicher This is the problem, I couldn't understand how to add necessary CMake bits and CMakeLists.txt. I just want to learn how to do it ? This is the main problem of my question; I couldn't create a cmake for dds. (Thank you for your in advance help)

                  C 1 Reply Last reply 26 Dec 2023, 12:38
                  0
                  • Q QMLEngine
                    26 Dec 2023, 12:36

                    @Christian-Ehrlicher This is the problem, I couldn't understand how to add necessary CMake bits and CMakeLists.txt. I just want to learn how to do it ? This is the main problem of my question; I couldn't create a cmake for dds. (Thank you for your in advance help)

                    C Online
                    C Online
                    Christian Ehrlicher
                    Lifetime Qt Champion
                    wrote on 26 Dec 2023, 12:38 last edited by
                    #9

                    As @SGaist already said - take a look at the other plugins for an example on how to build a proper CMakeLists.txt. they all follow the same schema.

                    Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
                    Visit the Qt Academy at https://academy.qt.io/catalog

                    Q 1 Reply Last reply 26 Dec 2023, 12:58
                    0
                    • C Christian Ehrlicher
                      26 Dec 2023, 12:38

                      As @SGaist already said - take a look at the other plugins for an example on how to build a proper CMakeLists.txt. they all follow the same schema.

                      Q Offline
                      Q Offline
                      QMLEngine
                      wrote on 26 Dec 2023, 12:58 last edited by
                      #10

                      @Christian-Ehrlicher I don't want to be rude, but I already looked and couldn't do it, so I'm asking for your help and asking the same thing over and over again, I looked at the others, I tried but I couldn't do it. Thats why I am writing same question over and over again for an hour.

                      C 1 Reply Last reply 26 Dec 2023, 13:01
                      0
                      • Q QMLEngine
                        26 Dec 2023, 12:58

                        @Christian-Ehrlicher I don't want to be rude, but I already looked and couldn't do it, so I'm asking for your help and asking the same thing over and over again, I looked at the others, I tried but I couldn't do it. Thats why I am writing same question over and over again for an hour.

                        C Online
                        C Online
                        Christian Ehrlicher
                        Lifetime Qt Champion
                        wrote on 26 Dec 2023, 13:01 last edited by Christian Ehrlicher
                        #11

                        So you want to tell me that you can't adapt e.g the tga CMakeLists.txt which consists of 8 lines of real code to be used for the dds image plugin?

                        qt_internal_add_plugin(QTgaPlugin
                            OUTPUT_NAME qtga
                            PLUGIN_TYPE imageformats
                            SOURCES
                                main.cpp
                                qtgafile.cpp qtgafile.h
                                qtgahandler.cpp qtgahandler.h
                            LIBRARIES
                                Qt::Core
                                Qt::Gui
                        )
                        

                        ?

                        Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
                        Visit the Qt Academy at https://academy.qt.io/catalog

                        Q 1 Reply Last reply 26 Dec 2023, 13:37
                        0
                        • C Christian Ehrlicher
                          26 Dec 2023, 13:01

                          So you want to tell me that you can't adapt e.g the tga CMakeLists.txt which consists of 8 lines of real code to be used for the dds image plugin?

                          qt_internal_add_plugin(QTgaPlugin
                              OUTPUT_NAME qtga
                              PLUGIN_TYPE imageformats
                              SOURCES
                                  main.cpp
                                  qtgafile.cpp qtgafile.h
                                  qtgahandler.cpp qtgahandler.h
                              LIBRARIES
                                  Qt::Core
                                  Qt::Gui
                          )
                          

                          ?

                          Q Offline
                          Q Offline
                          QMLEngine
                          wrote on 26 Dec 2023, 13:37 last edited by QMLEngine
                          #12

                          @Christian-Ehrlicher No, I just want to say that I changed and adapt this code according to dds and create a CMake.txt file in the folder of dds but still I couldn't see dds in QImageReader::supportedImageFormats() supported image format. Also, still I can not use .dds file to show an image in qt creator.

                          Since I couldn't find the problem myself, I wanted to ask if there was anyone who knew exactly how to do it. Instead of constantly saying look other files and create a smilar, you can just write full answer if you know how to write. If you do not know how to do it, I would welcome you to leave it to someone who knows, because the answers you give are always the same. Also, if I ask someone who doesn't know QT at all, he also will say look at same CMake files and create a smilar one. I'm waiting for a real answer and if you don't know, I think you need to stop saying look at similars all the time so that someone who knows can answer. Because approaching to a question with such an attitude is not a pleasant attitude. Thank you in advance.

                          C 1 Reply Last reply 26 Dec 2023, 17:27
                          0
                          • Q QMLEngine
                            26 Dec 2023, 13:37

                            @Christian-Ehrlicher No, I just want to say that I changed and adapt this code according to dds and create a CMake.txt file in the folder of dds but still I couldn't see dds in QImageReader::supportedImageFormats() supported image format. Also, still I can not use .dds file to show an image in qt creator.

                            Since I couldn't find the problem myself, I wanted to ask if there was anyone who knew exactly how to do it. Instead of constantly saying look other files and create a smilar, you can just write full answer if you know how to write. If you do not know how to do it, I would welcome you to leave it to someone who knows, because the answers you give are always the same. Also, if I ask someone who doesn't know QT at all, he also will say look at same CMake files and create a smilar one. I'm waiting for a real answer and if you don't know, I think you need to stop saying look at similars all the time so that someone who knows can answer. Because approaching to a question with such an attitude is not a pleasant attitude. Thank you in advance.

                            C Online
                            C Online
                            Christian Ehrlicher
                            Lifetime Qt Champion
                            wrote on 26 Dec 2023, 17:27 last edited by
                            #13

                            @QMLEngine said in DDS image format plugin:

                            CMake.txt file in the folder of dds but still I couldn't see dds in QImageReader::supportedImageFormats() supported image format.

                            And did you acutally compile and install the dds plugin afterwards?

                            Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
                            Visit the Qt Academy at https://academy.qt.io/catalog

                            1 Reply Last reply
                            0

                            3/13

                            25 Dec 2023, 12:23

                            topic:navigator.unread, 10
                            • Login

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