Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Qt and ffmpeg in Linux

Qt and ffmpeg in Linux

Scheduled Pinned Locked Moved Solved General and Desktop
8 Posts 3 Posters 1.8k 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.
  • M Offline
    M Offline
    Mikeeeeee
    wrote on 15 Apr 2020, 06:15 last edited by
    #1

    Hi!
    I put Debian 10, it already has ffmpeg.
    Please tell me how to connect ffmpeg to the Qt project.
    Here's what the terminal gives you about the library

    dpkg -L ffmpeg
    /.
    /usr
    /usr/bin
    /usr/bin/ffmpeg
    /usr/bin/ffplay
    /usr/bin/ffprobe
    /usr/bin/qt-faststart
    /usr/share
    /usr/share/doc
    /usr/share/doc/ffmpeg
    /usr/share/doc/ffmpeg/RELEASE_NOTES
    /usr/share/doc/ffmpeg/changelog.Debian.gz
    /usr/share/doc/ffmpeg/changelog.gz
    /usr/share/doc/ffmpeg/copyright
    /usr/share/ffmpeg
    /usr/share/ffmpeg/ffprobe.xsd
    /usr/share/ffmpeg/libvpx-1080p.ffpreset
    /usr/share/ffmpeg/libvpx-1080p50_60.ffpreset
    /usr/share/ffmpeg/libvpx-360p.ffpreset
    /usr/share/ffmpeg/libvpx-720p.ffpreset
    /usr/share/ffmpeg/libvpx-720p50_60.ffpreset
    /usr/share/lintian
    /usr/share/lintian/overrides
    /usr/share/lintian/overrides/ffmpeg
    /usr/share/man
    /usr/share/man/man1
    /usr/share/man/man1/ffmpeg-all.1.gz
    /usr/share/man/man1/ffmpeg-bitstream-filters.1.gz
    /usr/share/man/man1/ffmpeg-codecs.1.gz
    /usr/share/man/man1/ffmpeg-devices.1.gz
    /usr/share/man/man1/ffmpeg-filters.1.gz
    /usr/share/man/man1/ffmpeg-formats.1.gz
    /usr/share/man/man1/ffmpeg-protocols.1.gz
    /usr/share/man/man1/ffmpeg-resampler.1.gz
    /usr/share/man/man1/ffmpeg-scaler.1.gz
    /usr/share/man/man1/ffmpeg-utils.1.gz
    /usr/share/man/man1/ffmpeg.1.gz
    /usr/share/man/man1/ffplay-all.1.gz
    /usr/share/man/man1/ffplay.1.gz
    /usr/share/man/man1/ffprobe-all.1.gz
    /usr/share/man/man1/ffprobe.1.gz
    /usr/share/man/man1/qt-faststart.1.gz
    
    1 Reply Last reply
    0
    • M Offline
      M Offline
      mrjj
      Lifetime Qt Champion
      wrote on 15 Apr 2020, 06:20 last edited by mrjj
      #2

      Hi
      In what way "connect" ?

      This is just the executable and seems to have no libs to link to your app.

      You can run it with QProcess if you wish.

      Please give more details on what you try to do.

      https://www.salatino.org/wp/using-ffmpeg-in-c-with-qt-creator/

      1 Reply Last reply
      1
      • M Offline
        M Offline
        Mikeeeeee
        wrote on 15 Apr 2020, 07:06 last edited by
        #3

        I want to process images and sound, and work with videos. I looked at an example. But I haven't:

        #include <libavutil/opt.h>
        #include <libavcodec/avcodec.h>
        
        J M 2 Replies Last reply 15 Apr 2020, 07:19
        0
        • M Mikeeeeee
          15 Apr 2020, 07:06

          I want to process images and sound, and work with videos. I looked at an example. But I haven't:

          #include <libavutil/opt.h>
          #include <libavcodec/avcodec.h>
          
          J Online
          J Online
          jsulm
          Lifetime Qt Champion
          wrote on 15 Apr 2020, 07:19 last edited by
          #4

          @Mikeeeeee said in Qt and ffmpeg in Linux:

          But I haven't

          I guess you did not install the ffmpeg dev packages?

          https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          2
          • M Mikeeeeee
            15 Apr 2020, 07:06

            I want to process images and sound, and work with videos. I looked at an example. But I haven't:

            #include <libavutil/opt.h>
            #include <libavcodec/avcodec.h>
            
            M Offline
            M Offline
            mrjj
            Lifetime Qt Champion
            wrote on 15 Apr 2020, 07:19 last edited by
            #5

            @Mikeeeeee
            Hi
            So you want to link it toyour own app ?

            I think you need to do
            sudo apt-get install libavcodec-dev
            or similar to get the headers.

            1 Reply Last reply
            4
            • M Offline
              M Offline
              Mikeeeeee
              wrote on 15 Apr 2020, 07:23 last edited by
              #6
              This post is deleted!
              1 Reply Last reply
              0
              • M Offline
                M Offline
                Mikeeeeee
                wrote on 15 Apr 2020, 07:25 last edited by
                #7
                This post is deleted!
                1 Reply Last reply
                0
                • M Offline
                  M Offline
                  Mikeeeeee
                  wrote on 15 Apr 2020, 07:31 last edited by Mikeeeeee
                  #8

                  I install the library installed:

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

                  and in .pro:

                  
                  INCLUDEPATH += /usr/include/x86_64-linux-gnu/libavcodec
                  
                  LIBS += -lavformat  -lavcodec -lavutil -lz  -lswscale -lavutil -lm -llzma -lswresample
                  

                  and now work

                  1 Reply Last reply
                  1

                  1/8

                  15 Apr 2020, 06:15

                  • Login

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