Recherche avancée

Médias (91)

Autres articles (42)

  • Websites made ​​with MediaSPIP

    2 mai 2011, par

    This page lists some websites based on MediaSPIP.

  • Creating farms of unique websites

    13 avril 2011, par

    MediaSPIP platforms can be installed as a farm, with a single "core" hosted on a dedicated server and used by multiple websites.
    This allows (among other things) : implementation costs to be shared between several different projects / individuals rapid deployment of multiple unique sites creation of groups of like-minded sites, making it possible to browse media in a more controlled and selective environment than the major "open" (...)

  • Personnaliser les catégories

    21 juin 2013, par

    Formulaire de création d’une catégorie
    Pour ceux qui connaissent bien SPIP, une catégorie peut être assimilée à une rubrique.
    Dans le cas d’un document de type catégorie, les champs proposés par défaut sont : Texte
    On peut modifier ce formulaire dans la partie :
    Administration > Configuration des masques de formulaire.
    Dans le cas d’un document de type média, les champs non affichés par défaut sont : Descriptif rapide
    Par ailleurs, c’est dans cette partie configuration qu’on peut indiquer le (...)

Sur d’autres sites (9916)

  • Piping output of youtube-dl to a script using ffmpeg looks ok using echo but returns an error when executing

    22 février 2016, par user556068

    I am trying to use youtube-dl to get the urls of some videos and then pipe the resulting urls into the input of my script. So in my terminal I do

    youtube-dl --ignore-config -iga ~/Desktop/youtube/videolist.txt | myscript.sh

    In my script I define things as

    command='ffmpeg'        
    inputArgs='-i'              
    outputArgs='-c:v libx264 -preset ultrafast -qp 0'      
    directory="${HOME}/Desktop/Videos/"
    output="video${count}"      
    extension='mp4'        

    I test it with echo to make sure everything appears in the correct order.

    echo "${command}" "${inputArgs}" "${input}" "${outputArgs}" \
    "${directory}""${output}${count}"."${extension}"

    And the output from that looks correct. But when I try to run the same thing without the preceding echo command, i.e.,

    "${command}" "${inputArgs}" "${input}" "${outputArgs}" \
    "${directory}""${output}${count}"."${extension}"

    I get an error message that says

    At least one output file must be specified.

    So it seems pretty obvious to me that I’m doing something wrong when attempting to execute it.

    I have tried :

    • quoting the entire line as a whole
    • quoting different sections together
    • using the exec command in front of everything

    No matter what I do, an error occurs at some point in the process. I know it’s something simple I’m doing wrong. Would someone please enlighten me as to what that might be ?

    I feel very strongly that the . shouldn’t just be in the middle of everything like that, but I really don’t know.

    Again, everything looks as it should when I run echo before the string of shell parameters.

    If more of the script I’m using is needed to understand what I’m talking about, that is not a problem.

  • Problems when make ffmpeg with ios5.1

    20 octobre 2012, par why

    I am using https://github.com/lajos/iFrameExtractor and there is ffmpeg directory.

    I can configure and make successful, but there some errors when run ./build_universal

    libavformat/metadata_compat.c: In function ‘ff_metadata_mux_compat’:
    libavformat/metadata_compat.c:129: warning: the address of ‘number’ will always evaluate as ‘true’
    libavformat/metadata_compat.c:130: warning: the address of ‘number’ will always evaluate as ‘true’
    /applications/xcode.app/contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc -DHAVE_AV_CONFIG_H -I. -I"/Users/why/work/iFrameExtractor/ffmpeg" -D_ISOC99_SOURCE -D_POSIX_C_SOURCE=200112 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DPIC -std=c99 -fomit-frame-pointer -fPIC -g -Wdeclaration-after-statement -Wall -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual -Wwrite-strings -Wundef -O3 -fno-math-errno -fno-tree-vectorize       -MMD -MF libavformat/options.d -MT libavformat/options.o -c -o libavformat/options.o libavformat/options.c
    /applications/xcode.app/contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc -DHAVE_AV_CONFIG_H -I. -I"/Users/why/work/iFrameExtractor/ffmpeg" -D_ISOC99_SOURCE -D_POSIX_C_SOURCE=200112 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DPIC -std=c99 -fomit-frame-pointer -fPIC -g -Wdeclaration-after-statement -Wall -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual -Wwrite-strings -Wundef -O3 -fno-math-errno -fno-tree-vectorize       -MMD -MF libavformat/os_support.d -MT libavformat/os_support.o -c -o libavformat/os_support.o libavformat/os_support.c
    libavformat/os_support.c: In function ‘resolve_host’:
    libavformat/os_support.c:68: warning: implicit declaration of function ‘inet_aton’
    /applications/xcode.app/contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc -DHAVE_AV_CONFIG_H -I. -I"/Users/why/work/iFrameExtractor/ffmpeg" -D_ISOC99_SOURCE -D_POSIX_C_SOURCE=200112 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DPIC -std=c99 -fomit-frame-pointer -fPIC -g -Wdeclaration-after-statement -Wall -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual -Wwrite-strings -Wundef -O3 -fno-math-errno -fno-tree-vectorize       -MMD -MF libavformat/sdp.d -MT libavformat/sdp.o -c -o libavformat/sdp.o libavformat/sdp.c
    /applications/xcode.app/contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc -DHAVE_AV_CONFIG_H -I. -I"/Users/why/work/iFrameExtractor/ffmpeg" -D_ISOC99_SOURCE -D_POSIX_C_SOURCE=200112 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DPIC -std=c99 -fomit-frame-pointer -fPIC -g -Wdeclaration-after-statement -Wall -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual -Wwrite-strings -Wundef -O3 -fno-math-errno -fno-tree-vectorize       -MMD -MF libavformat/seek.d -MT libavformat/seek.o -c -o libavformat/seek.o libavformat/seek.c
    /applications/xcode.app/contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc -DHAVE_AV_CONFIG_H -I. -I"/Users/why/work/iFrameExtractor/ffmpeg" -D_ISOC99_SOURCE -D_POSIX_C_SOURCE=200112 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DPIC -std=c99 -fomit-frame-pointer -fPIC -g -Wdeclaration-after-statement -Wall -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual -Wwrite-strings -Wundef -O3 -fno-math-errno -fno-tree-vectorize       -MMD -MF libavformat/utils.d -MT libavformat/utils.o -c -o libavformat/utils.o libavformat/utils.c
    libavformat/utils.c: In function ‘parse_date’:
    libavformat/utils.c:3100: warning: cast discards qualifiers from pointer target type
    /applications/xcode.app/contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc -DHAVE_AV_CONFIG_H -I. -I"/Users/why/work/iFrameExtractor/ffmpeg" -D_ISOC99_SOURCE -D_POSIX_C_SOURCE=200112 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DPIC -std=c99 -fomit-frame-pointer -fPIC -g -Wdeclaration-after-statement -Wall -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual -Wwrite-strings -Wundef -O3 -fno-math-errno -fno-tree-vectorize       -MMD -MF libavformat/avio.d -MT libavformat/avio.o -c -o libavformat/avio.o libavformat/avio.c
    /applications/xcode.app/contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc -DHAVE_AV_CONFIG_H -I. -I"/Users/why/work/iFrameExtractor/ffmpeg" -D_ISOC99_SOURCE -D_POSIX_C_SOURCE=200112 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -DPIC -std=c99 -fomit-frame-pointer -fPIC -g -Wdeclaration-after-statement -Wall -Wno-switch -Wdisabled-optimization -Wpointer-arith -Wredundant-decls -Wno-pointer-sign -Wcast-qual -Wwrite-strings -Wundef -O3 -fno-math-errno -fno-tree-vectorize       -MMD -MF libavformat/aviobuf.d -MT libavformat/aviobuf.o -c -o libavformat/aviobuf.o libavformat/aviobuf.c
    libavformat/aviobuf.c: In function ‘url_fdopen’:
    libavformat/aviobuf.c:560: warning: passing argument 6 of ‘init_put_byte’ from incompatible pointer type
    libavformat/aviobuf.c:560: warning: passing argument 7 of ‘init_put_byte’ from incompatible pointer type
    libavformat/aviobuf.c:560: warning: passing argument 8 of ‘init_put_byte’ from incompatible pointer type
    /var/folders/59/7srh1dk537s3hr4b2_4k1nxr0000gn/T//cc7qLhBK.s:2662:no such instruction: `eor %ecx, %eax,%eax,ror'
    /var/folders/59/7srh1dk537s3hr4b2_4k1nxr0000gn/T//cc7qLhBK.s:2663:no such instruction: `bic %ecx, %ecx,'
    /var/folders/59/7srh1dk537s3hr4b2_4k1nxr0000gn/T//cc7qLhBK.s:2664:suffix or operands invalid for `mov'
    /var/folders/59/7srh1dk537s3hr4b2_4k1nxr0000gn/T//cc7qLhBK.s:2665:no such instruction: `eor %eax, %eax,%ecx,lsr'
       make: *** [libavformat/aviobuf.o] Error 1
       mv: rename libavcodec/libavcodec.a to armv7/libavcodec.a: No such file or directory
       mv: rename libavformat/libavformat.a to armv7/libavformat.a: No such file or directory
       mv: rename libavutil/libavutil.a to armv7/libavutil.a: No such file or directory
       mv: rename libswscale/libswscale.a to armv7/libswscale.a: No such file or directory
       rm: No match.
       rm: No match.
       lipo: can't open input file: armv7/libavcodec.a (No such file or directory)
       lipo: specifed architecture type (armv7) for file (armv7/libavdevice.a) does not match its cputype (16777223) and cpusubtype (3) (should be cputype (12) and cpusubtype (9))
       lipo: can't open input file: armv7/libavformat.a (No such file or directory)
       lipo: can't open input file: armv7/libavutil.a (No such file or directory)
       lipo: can't open input file: armv7/libswscale.a (No such file or directory)
       cp: No match.
  • ffmpeg problems with streaming mp4 over udp in local network

    28 novembre 2019, par AJ Cole

    I’m streaming mp4 video files (some of them are avi converted to mp4 with ffmpeg earlier) over udp://232.255.23.23:1234 from linux (embedded) with ffmpeg v3.4.2 to multiple linux (antix) machines that play the stream with MPV, all of this happens in local network so I expected it to work flawlessly, but unfortunately it doesn’t.

    Here are the original commands I tried to use :

    ffmpeg

    ffmpeg -re -i PATH_TO_FILE.mp4 -c copy -f mpegts udp://232.255.23.23:1234

    mpv

    mpv --no-config --geometry=[geo settings] --no-border udp://232.255.23.23:1234

    This seemed to woork good, however a problem appeared that on the displaying end, the stream is actually much longer than the streamed content itself. The mp4 files in total have 5 minutes 36 seconds, and mpv plays the entire stream loop in >= 6 minutes. I think it’s happening because of dropped frames, that mpv waits to recover or something and therefore extends the length of the actual content. This cannot work in my case, as I have a precise time gap for displaying the stream and it cannot be longer than the streamed content.
    All the content is made in 1680x800 resolution and is displayed on a screen with 1680x1050 resoltion (positioned with mpv geometry)

    It appears that using this command for mpv :

    mpv --no-config --framedrop=no --geometry=[geo settings] --no-border udp://232.255.23.23:1234

    made the duration correct, however this introduces huge artifacts in the videos sometimes.

    I read that using -re for streaming can cause these frame drops, so I tried putting a static number of fps for both file input and output stream, for example :

    ffmpeg -re -i PATH_TO_FILE.mp4 -c copy -r 25 -f mpegts udp://232.255.23.23:1234

    This reads the file at native framerate and outputs the stream at 25fps, and it appears to have the timing duration correct, but it also causes occasional articats and I think has worse qualit overall. Output from mpv when one of the artifacts happened :

    [ffmpeg/video] h264: cabac decode of qscale diff failed at 85 19
    [ffmpeg/video] h264: error while decoding MB 85 19, bytestream 85515

    I also tried using --untimed or --no-cache in mpv, but this causes stutters in the video

    I’m also getting requent Invalid video timestamp warnings in MPV, for example : Invalid video timestamp: 1.208333 -> -8.711667

    Playing in mpv without --no-config and with --untimed added also causes frequent artifacts :

    V: -00:00:00 / 00:00:00 Cache:  0s+266KB
    [ffmpeg/video] h264: Invalid NAL unit 8, skipping.
    V: -00:00:00 / 00:00:00 Cache:  0s+274KB
    [ffmpeg/video] h264: Reference 4 >= 4
    [ffmpeg/video] h264: error while decoding MB 6 0, bytestream 31474
    [ffmpeg/video] h264: error while decoding MB 78 49, bytestream -12
    V: 00:00:06 / 00:00:00 Cache:  5s+11KB
    Invalid video timestamp: 6.288333 -> -8.724933
    V: -00:00:05 / 00:00:00 Cache:  3s+0KB
    [ffmpeg/video] h264: Invalid NAL unit 8, skipping.
    [ffmpeg/video] h264: error while decoding MB 59 24, bytestream -27
    V: -00:00:04 / 00:00:00 Cache:  3s+0KB
    [ffmpeg/video] h264: Reference 4 >= 3
    [ffmpeg/video] h264: error while decoding MB 5 2, bytestream 13402
    V: -00:00:03 / 00:00:00 Cache:  2s+0KB
    [ffmpeg/video] h264: Reference 5 >= 4
    [ffmpeg/video] h264: error while decoding MB 51 21, bytestream 9415

    I tried playing the stream with ffplay and it also caused the videos to be "played" 20 seconds longer.
    Is there any way to keep the streaming duration intact and prevent those huge artifacts ? These aren’t any huge video files, they are few MB each, everything happens in local network so the latencies are minimal.

    Output from ffmpeg when streaming one of the files :

    libavutil      55. 78.100 / 55. 78.100
     libavcodec     57.107.100 / 57.107.100
     libavformat    57. 83.100 / 57. 83.100
     libavdevice    57. 10.100 / 57. 10.100
     libavfilter     6.107.100 /  6.107.100
     libswscale      4.  8.100 /  4.  8.100
     libswresample   2.  9.100 /  2.  9.100
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'SDM.mp4':
     Metadata:
       major_brand     : isom
       minor_version   : 512
       compatible_brands: isomiso2avc1mp41
       encoder         : Lavf57.48.100
     Duration: 00:00:20.00, start: 0.000000, bitrate: 1883 kb/s
       Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1680x800 [SAR 1:1 DAR 21:10], 1880 kb/s, 24 fps, 24 tbr, 12288 tbn, 48 tbc (default)
       Metadata:
         handler_name    : VideoHandler
    Output #0, mpegts, to 'udp://232.255.23.23:1234':
     Metadata:
       major_brand     : isom
       minor_version   : 512
       compatible_brands: isomiso2avc1mp41
       encoder         : Lavf57.83.100
       Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1680x800 [SAR 1:1 DAR 21:10], q=2-31, 1880 kb/s, 24 fps, 24 tbr, 90k tbn, 25 tbc (default)
       Metadata:
         handler_name    : VideoHandler
    Stream mapping:
     Stream #0:0 -> #0:0 (copy)
    Press [q] to stop, [?] for help
    frame=  480 fps= 24 q=-1.0 Lsize=    5009kB time=00:00:19.87 bitrate=2064.7kbits/s speed=   1x
    video:4592kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 9.082929%

    Edit : all the files don’t contain any audio, so it should be even less traffic on the network