Recherche avancée

Médias (1)

Mot : - Tags -/pirate bay

Autres articles (64)

  • Mise à jour de la version 0.1 vers 0.2

    24 juin 2013, par

    Explications des différents changements notables lors du passage de la version 0.1 de MediaSPIP à la version 0.3. Quelles sont les nouveautés
    Au niveau des dépendances logicielles Utilisation des dernières versions de FFMpeg (>= v1.2.1) ; Installation des dépendances pour Smush ; Installation de MediaInfo et FFprobe pour la récupération des métadonnées ; On n’utilise plus ffmpeg2theora ; On n’installe plus flvtool2 au profit de flvtool++ ; On n’installe plus ffmpeg-php qui n’est plus maintenu au (...)

  • Personnaliser en ajoutant son logo, sa bannière ou son image de fond

    5 septembre 2013, par

    Certains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;

  • Ecrire une actualité

    21 juin 2013, par

    Présentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
    Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
    Vous pouvez personnaliser le formulaire de création d’une actualité.
    Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...)

Sur d’autres sites (12312)

  • python ffmpeg moov atom not found Invalid data when processing input

    11 mai 2018, par Isocrates

    I have a progress that records the screen, and audio from a microphone, and then combines the video and audio recording (.mp4 and .wav) into one mkv file.

    I am using python 3.6 and ffmpeg to achieve this aim. For short videos (<20 sec.) it works, but for longer recordings it presents the following error message :

    [mov,mp4,m4a,3gp,3g2,mj2 @ 0x55abb3a52540] moov atom not found
    tmp/tmp_0.mp4: Invalid data found when processing input

    Full output :

    ffmpeg version 3.3.7 Copyright (c) 2000-2018 the FFmpeg developers
    built with gcc 7 (GCC)
    configuration: --prefix=/usr --bindir=/usr/bin --
    datadir=/usr/share/ffmpeg --docdir=/usr/share/doc/ffmpeg --
    incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --
    arch=x86_64 --optflags='-O2 -g -pipe -Wall -Werror=format-security -Wp,
    -D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-
    buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-
    hardened-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables' --extra-
    ldflags='-Wl,-z,relro -specs=/usr/lib/rpm/redhat/redhat-hardened-ld ' --
    extra-cflags='-I/usr/include/nvenc ' --enable-libopencore-amrnb --
    enable-
    libopencore-amrwb --enable-libvo-amrwbenc --enable-version3 --enable-bzlib
    --disable-crystalhd --enable-fontconfig --enable-frei0r --enable-gcrypt --
    enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-
    libcdio --enable-indev=jack --enable-libfreetype --enable-libfribidi --
    enable-libgsm --enable-libmp3lame --enable-nvenc --enable-openal --enable-
    opencl --enable-opengl --enable-libopenjpeg --enable-libopus --enable-
    libpulse --enable-libschroedinger --enable-libsoxr --enable-libspeex --
    enable-libtheora --enable-libvorbis --enable-libv4l2 --enable- libvidstab -
    -enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid --
    enable-avfilter --enable-avresample --enable-postproc --enable-pthreads --
    disable-static --enable-shared --enable-gpl --disable-debug --disable-
    stripping --shlibdir=/usr/lib64 --enable-libmfx --enable-runtime-cpudetect
     libavutil      55. 58.100 / 55. 58.100
     libavcodec     57. 89.100 / 57. 89.100
     libavformat    57. 71.100 / 57. 71.100
     libavdevice    57.  6.100 / 57.  6.100
     libavfilter     6. 82.100 /  6. 82.100
     libavresample   3.  5.  0 /  3.  5.  0
     libswscale      4.  6.100 /  4.  6.100
     libswresample   2.  7.100 /  2.  7.100
     libpostproc    54.  5.100 / 54.  5.100
    [wav @ 0x55abb3a0b880] Ignoring maximum wav data size, file may be invalid
    [wav @ 0x55abb3a0b880] Estimating duration from bitrate, this may be
    inaccurate
    Guessed Channel Layout for Input Stream #0.0 : stereo
    Input #0, wav, from 'tmp/tmp_0.wav':
     Metadata:
       encoder         : Lavf57.71.100
     Duration: 00:00:21.97, bitrate: 768 kb/s
    Stream #0:0: Audio: pcm_mulaw ([7][0][0][0] / 0x0007), 48000 Hz,
    stereo, s16, 768 kb/s
    [mov,mp4,m4a,3gp,3g2,mj2 @ 0x55abb3a52540] moov atom not found
    tmp/tmp_0.mp4: Invalid data found when processing input

    The python file (ffmpeg.py) is as follows. The class, AV_COMPILE, is not yet complete, held up by the aforementioned error, and therefore still uses the initial test files as defaults. But otherwise it ought to work :

    import os, time, glob

    TMP_DIR = "tmp"
    DISPLAY = os.environ['DISPLAY']
    EXT = {
       'Video':'mp4',
       'Audio':'wav',
       'AV':'mkv',
    }

    class ffmpegVideo:

       FFMPEG_BIN = "ffmpeg"
       AUDIO = False

       def __init__(self, fps = 30, audio = True):
       global TMP_DIR, DISPLAY, EXT

       self.fps = fps

       if audio:
           self.AUDIO = True

       self.video_filename = self.unique_filename()

       self.command = [ self.FFMPEG_BIN,
           '-video_size', '1920x1080',
           '-framerate', str(fps),
           '-f', 'x11grab',
           '-i', DISPLAY,
           '-vcodec', 'libx264',
           '-qp', '0',
           '-preset', 'ultrafast',
           '-y', TMP_DIR + '/' + self.video_filename
       ]

    def start(self):
       import threading as th

       thread = th.Thread(target=self.record)
       thread.start()

    def record(self):
       import subprocess as sp

       self.pipe = sp.Popen(self.command, stderr=sp.PIPE)

       if self.AUDIO:
           ffmpegAudio().start()

    def stop(self):
       self.pipe.terminate()

    def unique_filename(self):
       global TMP_DIR, EXT

       i = 0

       while os.path.exists((TMP_DIR + '/' + 'tmp_%s.%s') % (i, EXT['Video'])):
           i += 1

       return ('tmp_%s.%s') % (i, EXT['Video'])

    class ffmpegAudio:

       FFMPEG_BIN = "ffmpeg"

       def __init__(self):

           self.audio_filename = self.unique_filename()

           self.command = [ self.FFMPEG_BIN,
               '-f', 'pulse',
               '-ac', '2',
               '-ar', '48000',
               '-i', 'default',
              '-acodec', 'pcm_mulaw',
              '-y', TMP_DIR + '/' + self.audio_filename
           ]

       def start(self):
           import threading as th

           au_thread = th.Thread(target=self.record)
           au_thread.start()

       def record(self):
            import subprocess as sp

           self.pipe = sp.Popen(self.command, stderr=sp.PIPE)

       def stop(self):
           self.pipe.terminate()

       def unique_filename(self):
           global TMP_DIR, EXT

           i = 0

           while os.path.exists((TMP_DIR + '/' + 'tmp_%s.%s') % (i, EXT['Audio'])):
           i += 1

           return ('tmp_%s.%s') % (i, EXT['Audio'])

    class AV_COMPILE:

       def __init__(self, au_in = TMP_DIR + '/' + 'out1.wav', vd_in =
    TMP_DIR + '/' + 'test4.mp4', out = TMP_DIR + '/' + 'av.mkv'):
           import subprocess as sp

           au_in = min(glob.iglob(TMP_DIR + '/*.wav'), key=os.path.getctime)
           vd_in = min(glob.iglob(TMP_DIR + '/*.mp4'), key=os.path.getctime)

           self.command = ('ffmpeg -i %s  -r 30 -i %s -shortest -c:a aac -c:v copy %s') % (au_in, vd_in, out)
           sp.call(self.command, shell=True)

    I would be grateful for any assistance you could provide in understanding why this happens and how to solve the error. Also, I am happy to receive any other tips on how to improve this code, or any other problems anyone might notice.

    EDIT :
    I now believe that the reason for this error in longer videos, and occasionally shorter, is that the program is proceeding to attempt to compile the av output whether or not it has finished compiling the original video file. I tested a time.sleep(10) function to delay AV_COMPILE, and this seems to work.

    However, as video files get larger, obviously the delay needs to be adjusted. So I should like to know how I can separately check the integrity of the video file and determine that it is safe to proceed to the next step.

  • Error : mingw32/bin/ld.exe : cannot find -lbcrypt when compiling goav

    18 avril 2018, par nevernew

    I’m trying to compile goav on Windows and I’ve got quite far I’ve compiled the ffmpeg libraries in MSYS2 and linked the packages with :

    set CGO_CFLAGS=-IC:\path\to\FFmpeg\
    set PKG_CONFIG_PATH=%~dp0FFmpeg\libavformat;%~dp0FFmpeg\libavcodec;%~dp0FFmpeg\libavutil;%~dp0FFmpeg\libswresample;

    which has worked !

    However, I’m now getting the error could not determine kind of name for ...

    Here’s the whole error list :

    # github.com/giorgisio/goav/avcodec
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:57:52: could not determine kind of name for C.AV_CODEC_ID_ADPCM_VIMA_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:93:52: could not determine kind of name for C.AV_CODEC_ID_BRENDER_PIX_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:131:52: could not determine kind of name for C.AV_CODEC_ID_ESCAPE130_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:134:52: could not determine kind of name for C.AV_CODEC_ID_EXR_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:151:52: could not determine kind of name for C.AV_CODEC_ID_G2M_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:164:52: could not determine kind of name for C.AV_CODEC_ID_HEVC_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:211:52: could not determine kind of name for C.AV_CODEC_ID_MPEG2VIDEO_XVMC
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:228:52: could not determine kind of name for C.AV_CODEC_ID_MVC1_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:230:52: could not determine kind of name for C.AV_CODEC_ID_MVC2_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:237:52: could not determine kind of name for C.AV_CODEC_ID_OPUS_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:240:52: could not determine kind of name for C.AV_CODEC_ID_PAF_AUDIO_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:242:52: could not determine kind of name for C.AV_CODEC_ID_PAF_VIDEO_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:262:52: could not determine kind of name for C.AV_CODEC_ID_PCM_S24LE_PLANAR_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:266:52: could not determine kind of name for C.AV_CODEC_ID_PCM_S32LE_PLANAR_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:311:52: could not determine kind of name for C.AV_CODEC_ID_SANM_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:314:52: could not determine kind of name for C.AV_CODEC_ID_SGIRLE_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:338:52: could not determine kind of name for C.AV_CODEC_ID_TAK_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:373:52: could not determine kind of name for C.AV_CODEC_ID_VIMA
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:379:52: could not determine kind of name for C.AV_CODEC_ID_VOXWARE
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:386:52: could not determine kind of name for C.AV_CODEC_ID_VP7_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:392:52: could not determine kind of name for C.AV_CODEC_ID_WEBP_DEPRECATED
    compilation failed.
    exit code 2

    How can I fix this so it can finish compiling ?

    More Errors :

    I commented out those lines in the source file to see if I could continue, but now I’m getting all these errors, Obviously I’m missing some step, does anyone have any insight ?

    # github.com/giorgisio/goav/avcodec
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lavformat
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lbz2
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lavcodec
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lz
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lswresample
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lavutil
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lbcrypt
    collect2.exe: error: ld returned 1 exit status
    ....

    A Fix

    I added the sub folders of FFmpeg to LDFLAGS and it’s not getting errors for those libraries anymore.

    @set CGO_LDFLAGS=-L%~dp0FFmpeg\ -L%~dp0FFmpeg\libavformat -L%~dp0FFmpeg\libavcodec -L%~dp0FFmpeg\libavutil -L%~dp0FFmpeg\libswresample

    I also found GNUWindows ports for zlib and bzip2, so their errors have disappeared.

    But I’m still getting errors for -lbcrypt. anyone know where/how to go about getting this lib ?

  • Error : mingw32/bin/ld.exe : cannot find -lavformat when compiling goav

    18 avril 2018, par nevernew

    I’m trying to compile goav on Windows and I’ve got quite far I’ve compiled the ffmpeg libraries in MSYS2 and linked the packages with :

    set CGO_CFLAGS=-IC:\path\to\FFmpeg\
    set PKG_CONFIG_PATH=%~dp0FFmpeg\libavformat;%~dp0FFmpeg\libavcodec;%~dp0FFmpeg\libavutil;%~dp0FFmpeg\libswresample;

    which has worked !

    However, I’m now getting the error could not determine kind of name for ...

    Here’s the whole error list :

    # github.com/giorgisio/goav/avcodec
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:57:52: could not determine kind of name for C.AV_CODEC_ID_ADPCM_VIMA_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:93:52: could not determine kind of name for C.AV_CODEC_ID_BRENDER_PIX_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:131:52: could not determine kind of name for C.AV_CODEC_ID_ESCAPE130_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:134:52: could not determine kind of name for C.AV_CODEC_ID_EXR_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:151:52: could not determine kind of name for C.AV_CODEC_ID_G2M_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:164:52: could not determine kind of name for C.AV_CODEC_ID_HEVC_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:211:52: could not determine kind of name for C.AV_CODEC_ID_MPEG2VIDEO_XVMC
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:228:52: could not determine kind of name for C.AV_CODEC_ID_MVC1_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:230:52: could not determine kind of name for C.AV_CODEC_ID_MVC2_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:237:52: could not determine kind of name for C.AV_CODEC_ID_OPUS_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:240:52: could not determine kind of name for C.AV_CODEC_ID_PAF_AUDIO_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:242:52: could not determine kind of name for C.AV_CODEC_ID_PAF_VIDEO_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:262:52: could not determine kind of name for C.AV_CODEC_ID_PCM_S24LE_PLANAR_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:266:52: could not determine kind of name for C.AV_CODEC_ID_PCM_S32LE_PLANAR_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:311:52: could not determine kind of name for C.AV_CODEC_ID_SANM_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:314:52: could not determine kind of name for C.AV_CODEC_ID_SGIRLE_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:338:52: could not determine kind of name for C.AV_CODEC_ID_TAK_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:373:52: could not determine kind of name for C.AV_CODEC_ID_VIMA
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:379:52: could not determine kind of name for C.AV_CODEC_ID_VOXWARE
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:386:52: could not determine kind of name for C.AV_CODEC_ID_VP7_DEPRECATED
    source\src\github.com\giorgisio\goav\avcodec\codecs.go:392:52: could not determine kind of name for C.AV_CODEC_ID_WEBP_DEPRECATED
    compilation failed.
    exit code 2

    How can I fix this so it can finish compiling ?

    More Errors :

    I commented out those lines in the source file to see if I could continue, but now I’m getting all these errors, Obviously I’m missing some step, does anyone have any insight ?

    # github.com/giorgisio/goav/avcodec
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lavformat
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lbz2
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lavcodec
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lz
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lswresample
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lavutil
    c:/mingw/bin/../lib/gcc/mingw32/6.3.0/../../../../mingw32/bin/ld.exe: cannot find -lbcrypt
    collect2.exe: error: ld returned 1 exit status
    # github.com/giorgisio/goav/avcodec
    cgo-gcc-prolog: In function '_cgo_3a37b7d41a30_Cfunc_av_codec_get_max_lowres':
    cgo-gcc-prolog:40:2: warning: 'av_codec_get_max_lowres' is deprecated [-Wdeprecated-declarations]
    In file included from C:\Users\chris\Documents\videoplayer\FFmpeg/libavformat/avformat.h:319:0,
                    from source\src\github.com\giorgisio\goav\avcodec\avcodec.go:14:
    C:\Users\chris\Documents\videoplayer\FFmpeg/libavcodec/avcodec.h:3554:5: note: declared here
    int av_codec_get_max_lowres(const AVCodec *codec);
        ^~~~~~~~~~~~~~~~~~~~~~~
    cgo-gcc-prolog: In function '_cgo_3a37b7d41a30_Cfunc_av_codec_next':
    cgo-gcc-prolog:91:2: warning: 'av_codec_next' is deprecated [-Wdeprecated-declarations]
    In file included from C:\Users\chris\Documents\videoplayer\FFmpeg/libavformat/avformat.h:319:0,
                    from source\src\github.com\giorgisio\goav\avcodec\avcodec.go:14:
    C:\Users\chris\Documents\videoplayer\FFmpeg/libavcodec/avcodec.h:4045:10: note: declared here
    AVCodec *av_codec_next(const AVCodec *c);
    ....