Newest 'ffmpeg' Questions - Stack Overflow

http://stackoverflow.com/questions/tagged/ffmpeg

Les articles publiés sur le site

  • mov atom not found when merging images on debian 9

    27 avril, par robert tamunoemi

    Am extracting images from videos which I use in creating slideshows. Creating slideshows from the extracted images only works fine.However, when I add an image from my computer to the sets of extracted images, I get this error

    ffmpeg version 3.2.10-1~deb9u1 Copyright (c) 2000-2018 the FFmpeg developers
      built with gcc 6.3.0 (Debian 6.3.0-18) 20170516
      configuration: --prefix=/usr --extra-version='1~deb9u1' --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --enable-gpl --disable-stripping --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libebur128 --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmp3lame --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-omx --enable-openal --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libopencv --enable-libx264 --enable-shared
      libavutil      55. 34.101 / 55. 34.101
      libavcodec     57. 64.101 / 57. 64.101
      libavformat    57. 56.101 / 57. 56.101
      libavdevice    57.  1.100 / 57.  1.100
      libavfilter     6. 65.100 /  6. 65.100
      libavresample   3.  1.  0 /  3.  1.  0
      libswscale      4.  2.100 /  4.  2.100
      libswresample   2.  3.100 /  2.  3.100
      libpostproc    54.  1.100 / 54.  1.100
    [mov,mp4,m4a,3gp,3g2,mj2 @ 0x5605bcf0cee0] Format mov,mp4,m4a,3gp,3g2,mj2 detected only with low score of 1, misdetection possible!
    [mov,mp4,m4a,3gp,3g2,mj2 @ 0x5605bcf0cee0] moov atom not found
    videos/152415280818.mp4: Invalid data found when processing input
    
  • How to make ffmpeg available inside my Docker container ?

    27 avril, par vcamargo

    I'm currently trying to run a ffmpeg Docker image inside my own container with docker-compose using the depends_on clause. But when I try to reach ffmpeg inside my code, it seems like it's not available system-wide and I get an error. I believe I'm misconfiguring Docker.

    My current Dockerfile is as follows:

    FROM node:9
    
    WORKDIR /usr/app
    
    COPY package*.json ./
    
    RUN npm install --quiet
    
    COPY . .
    

    And my docker-compose.yml:

    version: '3'
    services:
      app:
        build: .
        command: npm run dev
        volumes:
        - .:/usr/app/
        - /usr/app/node_modules
        ports:
          - "3000:3000"
        depends_on:
          - ffmpeg
      ffmpeg:
        image: jrottenberg/ffmpeg:3.3
    

    When I run docker-compose up I can see that the ffmpeg is actually working, but then my application proceeds to start and it seems that ffmpeg ceases to work.

  • RTSP Frame Grabbing creates smeared , pixeled and corrupted images

    27 avril, par Robob

    I am trying to capture a single frame per second from a RTSP stream with following command ffmpeg -i rtsp://XXX -q:v 1 -vf fps=fps=1 -strftime 1 ZZZZ\%H_%M_%S.jpg

    But some of the frames are smeared ,pixeled and corrupted - this effect is drastically increases if rtsp resolution is increased Example 1 Example 2(if the resolution is decreased for example to 720P most of the frames are OK)

    I have to say that playing same rtsp stream in VLC or FFPLAY is flowless.

    How I can fix it to grab better quality

    Thanks in advance.

  • Adding GIF as Watermark and Loop FFMPEG

    27 avril, par Muhammad Sanaullah

    I try to add GIF over a video and continuously loop, but it animate once and stop on the video

    ffmpeg.exe -i "video.mp4" -i "ani.gif" -filter_complex "[1:v]format=yuva444p,setsar=1,scale=80:80,rotate=PI/6:c=black@0:ow=rotw(PI/6):oh=roth(PI/6) [rotate];[0:v][rotate] overlay=(main_w-overlay_w)/2:(main_h-overlay_h)/2" -codec:a copy -y output.mp4

    What is the solution?

    Thanks,

  • not able to open image generated by ffmpeg

    26 avril, par user3745870

    I am trying to get images from the video stream using ffmpeg in python and I need the raw bytes to do further things. I am trying to store the raw bytes in image file so if my file opens then I can confirm that the raw bytes I have got are correct.

    import subprocess as sp
    
    def getImages(self):
      cmd = ['ffmpeg',
               '-ss', 2,
               '-i', url,
               '-t', 2,
               '-f', 'image2pipe',
               '-s', '420x360',
               '-pix_fmt', 'rgb24',
               '-vcodec', 'rawvideo',
               '-vf', 'fps=fps=1', '-']
      pipe = sp.Popen(cmd, stdout = sp.PIPE, bufsize=10**8)
      raw = pipe.stdout.read(420*360)
      file = open('image.jpg','wb')
      file.write(raw)
    

    I see a file image.jpg but I cannot open it. Is there anything wrong I am doing here? I am sizing the image to be 420*360 bytes so I am assuming that the first 420*360 bytes are belong to the first frame.

    Thanks in advance!