Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. 3rd Party Software
  4. Qt ffmpeg wrapper example not working out of the box (solved)
Forum Updated to NodeBB v4.3 + New Features

Qt ffmpeg wrapper example not working out of the box (solved)

Scheduled Pinned Locked Moved 3rd Party Software
12 Posts 2 Posters 6.7k Views 1 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.
  • SGaistS Offline
    SGaistS Offline
    SGaist
    Lifetime Qt Champion
    wrote on last edited by
    #2

    Hi and welcome to devnet,

    AFAIR you need to install the development package of ffmpeg, it's really just a wrapper.

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

    1 Reply Last reply
    0
    • J Offline
      J Offline
      jimhi
      wrote on last edited by
      #3

      Ok, I did apt-get install ffmpeg, but it still has the same error

      1 Reply Last reply
      0
      • SGaistS Offline
        SGaistS Offline
        SGaist
        Lifetime Qt Champion
        wrote on last edited by
        #4

        That's normal, you just installed ffmpeg, not the development package

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

        1 Reply Last reply
        0
        • J Offline
          J Offline
          jimhi
          wrote on last edited by
          #5

          Thanks!

          apt-get install libavutil-dev libavformat-dev libswscale-dev libavcodec-dev

          did the trick for those errors, now I have about 71 errors involving the function calls to those libraries.

          output:
          undefined reference to 'avcodec_init'
          undefined reference to 'avformat_version'
          etc..
          etc

          What's going on here?

          1 Reply Last reply
          0
          • SGaistS Offline
            SGaistS Offline
            SGaist
            Lifetime Qt Champion
            wrote on last edited by
            #6

            Wild guess: the wrapper was written for an old version of ffmpeg. You'll have to update the code a bit

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

            1 Reply Last reply
            0
            • J Offline
              J Offline
              jimhi
              wrote on last edited by
              #7

              (to anyone else watching in the future) I changed all

              uint_8 to ffmpeg::uint_8

              so it will recognize their types

              1 Reply Last reply
              0
              • J Offline
                J Offline
                jimhi
                wrote on last edited by
                #8

                Downloading the latest build of qt ffmpeg wrapper fixed all the errors, but left about 70 warnings about deprecated functions and comparing unsigned and signed ints. After fixing all those, there are no errors left and QT builds and exits without any problems.

                However, I can't find a file to run after building. The example is called simpleencdec and I can't run

                ./simpleencdec

                in the build directory. Any suggestions?

                1 Reply Last reply
                0
                • SGaistS Offline
                  SGaistS Offline
                  SGaist
                  Lifetime Qt Champion
                  wrote on last edited by
                  #9

                  Did you open and build the example project ?

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

                  1 Reply Last reply
                  0
                  • J Offline
                    J Offline
                    jimhi
                    wrote on last edited by
                    #10

                    Yes, as I said, I built the project and it had 0 errors and warnings. (ctrl + B)

                    On a second look, I do get one strange error when I build the project

                    Project MESSAGE: Warning: unknown QT: widgets

                    1 Reply Last reply
                    0
                    • J Offline
                      J Offline
                      jimhi
                      wrote on last edited by
                      #11

                      I have fixed it.

                      I have been running it from my SD Card which was causing problems. When I moved it onto my raspberry pi, it created the file properly. I Chmod 777 the sd card, but it still didn't work.

                      Thanks for everything

                      1 Reply Last reply
                      0
                      • SGaistS Offline
                        SGaistS Offline
                        SGaist
                        Lifetime Qt Champion
                        wrote on last edited by
                        #12

                        If you are building with Qt 4 you don't have the widgets module

                        You're welcome !

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

                        1 Reply Last reply
                        0

                        • Login

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