Recherche avancée

Médias (91)

Autres articles (97)

  • Encoding and processing into web-friendly formats

    13 avril 2011, par

    MediaSPIP automatically converts uploaded files to internet-compatible formats.
    Video files are encoded in MP4, Ogv and WebM (supported by HTML5) and MP4 (supported by Flash).
    Audio files are encoded in MP3 and Ogg (supported by HTML5) and MP3 (supported by Flash).
    Where possible, text is analyzed in order to retrieve the data needed for search engine detection, and then exported as a series of image files.
    All uploaded files are stored online in their original format, so you can (...)

  • Installation en mode ferme

    4 février 2011, par

    Le mode ferme permet d’héberger plusieurs sites de type MediaSPIP en n’installant qu’une seule fois son noyau fonctionnel.
    C’est la méthode que nous utilisons sur cette même plateforme.
    L’utilisation en mode ferme nécessite de connaïtre un peu le mécanisme de SPIP contrairement à la version standalone qui ne nécessite pas réellement de connaissances spécifique puisque l’espace privé habituel de SPIP n’est plus utilisé.
    Dans un premier temps, vous devez avoir installé les mêmes fichiers que l’installation (...)

  • Installation en mode standalone

    4 février 2011, par

    L’installation de la distribution MediaSPIP se fait en plusieurs étapes : la récupération des fichiers nécessaires. À ce moment là deux méthodes sont possibles : en installant l’archive ZIP contenant l’ensemble de la distribution ; via SVN en récupérant les sources de chaque modules séparément ; la préconfiguration ; l’installation définitive ;
    [mediaspip_zip]Installation de l’archive ZIP de MediaSPIP
    Ce mode d’installation est la méthode la plus simple afin d’installer l’ensemble de la distribution (...)

Sur d’autres sites (7104)

  • How to convert aac to ogg opus keeping bit rate and sample rate unchanged

    25 juin 2019, par Doovi

    I’m trying to convert a .aac file to .opus but after inspecting with ffprobe I get different bit and sample rates.

    While input file’s audio stream bit rate is 245995, the output file’s audio stream has no bit rate specified - "format" shows bit rate of 118788.

    While input file’s audio stream sample rate is 44100, the output’s is 48000.

    ffprobe  -v error -show_format -show_streams input.aac
    [STREAM]
    index=0
    codec_name=aac
    codec_long_name=AAC (Advanced Audio Coding)
    profile=LC
    codec_type=audio
    codec_time_base=1/44100
    codec_tag_string=[0][0][0][0]
    codec_tag=0x0000
    sample_fmt=fltp
    sample_rate=44100
    channels=2
    channel_layout=stereo
    bits_per_sample=0
    id=N/A
    r_frame_rate=0/0
    avg_frame_rate=0/0
    time_base=1/28224000
    start_pts=N/A
    start_time=N/A
    duration_ts=106533390807
    duration=3774.567418
    bit_rate=245995
    max_bit_rate=N/A
    bits_per_raw_sample=N/A
    nb_frames=N/A
    nb_read_frames=N/A
    nb_read_packets=N/A
    DISPOSITION:default=0
    DISPOSITION:dub=0
    DISPOSITION:original=0
    DISPOSITION:comment=0
    DISPOSITION:lyrics=0
    DISPOSITION:karaoke=0
    DISPOSITION:forced=0
    DISPOSITION:hearing_impaired=0
    DISPOSITION:visual_impaired=0
    DISPOSITION:clean_effects=0
    DISPOSITION:attached_pic=0
    DISPOSITION:timed_thumbnails=0
    [/STREAM]
    [FORMAT]
    filename=input.aac
    nb_streams=1
    nb_programs=0
    format_name=aac
    format_long_name=raw ADTS AAC (Advanced Audio Coding)
    start_time=N/A
    duration=3774.567418
    size=116065589
    bit_rate=245995
    probe_score=51
    [/FORMAT]
    ffmpeg -nostdin -i input.aac -c:a libopus output.opus
    ffmpeg version N-93449-g013f714 Copyright (c) 2000-2019 the FFmpeg developers
     built with gcc 7 (Ubuntu 7.3.0-27ubuntu1~18.04)
     configuration: --prefix=/home/vagrant/ffmpeg_build --pkg-config-flags=--static --extra-cflags=-I/home/vagrant/ffmpeg_build/include --extra-ldflags=-L/home/vagrant/ffmpeg_build/lib --extra-libs='-lpthread -lm' --bindir=/home/vagrant/bin --enable-gpl --enable-libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-nonfree
     libavutil      56. 26.100 / 56. 26.100
     libavcodec     58. 47.105 / 58. 47.105
     libavformat    58. 26.101 / 58. 26.101
     libavdevice    58.  7.100 / 58.  7.100
     libavfilter     7. 48.100 /  7. 48.100
     libswscale      5.  4.100 /  5.  4.100
     libswresample   3.  4.100 /  3.  4.100
     libpostproc    55.  4.100 / 55.  4.100
    [aac @ 0x55d4b7e21d80] Estimating duration from bitrate, this may be inaccurate
    Input #0, aac, from 'input.aac':
     Duration: 01:02:54.57, bitrate: 245 kb/s
       Stream #0:0: Audio: aac (LC), 44100 Hz, stereo, fltp, 245 kb/s
    Stream mapping:
     Stream #0:0 -> #0:0 (aac (native) -> opus (libopus))
    [libopus @ 0x55d4b7e3f8c0] No bit rate set. Defaulting to 96000 bps.
    Output #0, opus, to 'output.opus':
     Metadata:
       encoder         : Lavf58.26.101
       Stream #0:0: Audio: opus (libopus), 48000 Hz, stereo, flt, 96 kb/s
       Metadata:
         encoder         : Lavc58.47.105 libopus
    size=   52103kB time=00:59:53.21 bitrate= 118.8kbits/s speed=66.2x
    video:0kB audio:51733kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.715930%
    ffprobe -v error -show_format -show_streams output.opus
    [STREAM]
    index=0
    codec_name=opus
    codec_long_name=Opus (Opus Interactive Audio Codec)
    profile=unknown
    codec_type=audio
    codec_time_base=1/48000
    codec_tag_string=[0][0][0][0]
    codec_tag=0x0000
    sample_fmt=fltp
    sample_rate=48000
    channels=2
    channel_layout=stereo
    bits_per_sample=0
    id=N/A
    r_frame_rate=0/0
    avg_frame_rate=0/0
    time_base=1/48000
    start_pts=0
    start_time=0.000000
    duration_ts=172473677
    duration=3593.201604
    bit_rate=N/A
    max_bit_rate=N/A
    bits_per_raw_sample=N/A
    nb_frames=N/A
    nb_read_frames=N/A
    nb_read_packets=N/A
    DISPOSITION:default=0
    DISPOSITION:dub=0
    DISPOSITION:original=0
    DISPOSITION:comment=0
    DISPOSITION:lyrics=0
    DISPOSITION:karaoke=0
    DISPOSITION:forced=0
    DISPOSITION:hearing_impaired=0
    DISPOSITION:visual_impaired=0
    DISPOSITION:clean_effects=0
    DISPOSITION:attached_pic=0
    DISPOSITION:timed_thumbnails=0
    TAG:ENCODER=Lavc58.47.105 libopus
    [/STREAM]
    [FORMAT]
    filename=output.opus
    nb_streams=1
    nb_programs=0
    format_name=ogg
    format_long_name=Ogg
    start_time=0.000000
    duration=3593.201604
    size=53353867
    bit_rate=118788
    probe_score=100
    [/FORMAT]

    How can I preserve the quality of the input file ? Am I missing something in the ffmpeg cmd ?

  • how to make sure the ffmpeg generate correct duration ?

    26 juin 2019, par Wang

    for example, the follow command create a 3 second video.

    ffmpeg -f lavfi -i color=c=red:r=30:d=3:size=800x600 red.nut

    But the ffprobe show duration is N/A :

    [STREAM]
    index=0
    codec_name=mpeg4
    codec_long_name=MPEG-4 part 2
    profile=Simple Profile
    codec_type=video
    codec_time_base=0/1
    codec_tag_string=FMP4
    codec_tag=0x34504d46
    width=800
    height=600
    coded_width=800
    coded_height=600
    has_b_frames=0
    sample_aspect_ratio=1:1
    display_aspect_ratio=4:3
    pix_fmt=yuv420p
    level=1
    color_range=unknown
    color_space=unknown
    color_transfer=unknown
    color_primaries=unknown
    chroma_location=left
    field_order=unknown
    timecode=N/A
    refs=1
    quarter_sample=false
    divx_packed=false
    id=N/A
    r_frame_rate=30/1
    avg_frame_rate=0/0
    time_base=1/61440
    start_pts=0
    start_time=0.000000
    duration_ts=N/A
    duration=N/A
    bit_rate=N/A
    max_bit_rate=N/A
    bits_per_raw_sample=N/A
    nb_frames=N/A
    nb_read_frames=N/A
    nb_read_packets=N/A
    DISPOSITION:default=0
    DISPOSITION:dub=0
    DISPOSITION:original=0
    DISPOSITION:comment=0
    DISPOSITION:lyrics=0
    DISPOSITION:karaoke=0
    DISPOSITION:forced=0
    DISPOSITION:hearing_impaired=0
    DISPOSITION:visual_impaired=0
    DISPOSITION:clean_effects=0
    DISPOSITION:attached_pic=0
    DISPOSITION:timed_thumbnails=0
    TAG:encoder=Lavc57.107.100 mpeg4
    [/STREAM]

    Is there flag I can set to allow the ffmpeg generate correct duration_ts and duration ?

  • Can I add silent audio based on another video, to a video created from a PNG loop

    25 mars 2019, par GDP

    We have videos that we transcode to h.264, but COPY the original audio track (they all vary). We are now trying to prepend a 10 second disclaimer before the original video begins. Apparently the audio tracks of the two videos must be the same, so I’m trying to add a silent audio track to the generated video based on the audio track of the video it will be concatenated with.

    From other questions, I’ve learned to add -f lavfi -i anullsrc=channel_layout=stereo:sample_rate=44100, but this results in garbled audio when the concatenation occurs. So using ffprobe, I would like to get whatever audio properties are needed and use them in the prepending video.

    So the question is : How can I specify the specific audio track settings I want/need when creating the 10 second video ?

    FFMpeg to create 10 second disclaimer

    ffmpeg.exe -f lavfi -i anullsrc=channel_layout=stereo:sample_rate=44100 -loop 1 -i disclaimer.png -filter:v "fade=out:st=8:d=2" -c:v libx264 -t 10 -pix_fmt yuv420p -r 29.97 disclaimer.mp4

    FFProbe

    ffprobe -show_format -show_streams OriginalVideo.mp4
    ffprobe version N-73975-gda8b70b Copyright (c) 2007-2015 the FFmpeg developers
     built with gcc 4.9.2 (GCC)
     configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libdcadec --enable-libfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libschroedinger --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-aacenc --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-lzma --enable-decklink --enable-zlib
     libavutil      54. 28.100 / 54. 28.100
     libavcodec     56. 52.100 / 56. 52.100
     libavformat    56. 40.101 / 56. 40.101
     libavdevice    56.  4.100 / 56.  4.100
     libavfilter     5. 27.100 /  5. 27.100
     libswscale      3.  1.101 /  3.  1.101
     libswresample   1.  2.101 /  1.  2.101
     libpostproc    53.  3.100 / 53.  3.100
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'OriginalVideo.mp4':
     Metadata:
       major_brand     : isom
       minor_version   : 512
       compatible_brands: isomiso2avc1mp41
       title           : 343520959333629
       encoder         : Lavf56.40.101
     Duration: 00:00:24.56, start: 0.160998, bitrate: 245 kb/s
       Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 640x400 [SAR 1615:1616 DAR 323:202], 194 kb/s, 25 fps, 25 tbr, 90k tbn, 50 tbc (default)
       Metadata:
         handler_name    : VideoHandler
       Stream #0:1(und): Audio: aac (HE-AACv2) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 47 kb/s (default)
       Metadata:
         handler_name    : SoundHandler
    [STREAM]
    index=0
    codec_name=h264
    codec_long_name=H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
    profile=High
    codec_type=video
    codec_time_base=1/50
    codec_tag_string=avc1
    codec_tag=0x31637661
    width=640
    height=400
    coded_width=640
    coded_height=400
    has_b_frames=2
    sample_aspect_ratio=1615:1616
    display_aspect_ratio=323:202
    pix_fmt=yuv420p
    level=31
    color_range=N/A
    color_space=unknown
    color_transfer=unknown
    color_primaries=unknown
    chroma_location=left
    timecode=N/A
    refs=5
    is_avc=1
    nal_length_size=4
    id=N/A
    r_frame_rate=25/1
    avg_frame_rate=25/1
    time_base=1/90000
    start_pts=0
    start_time=0.000000
    duration_ts=2181600
    duration=24.240000
    bit_rate=194642
    max_bit_rate=N/A
    bits_per_raw_sample=8
    nb_frames=606
    nb_read_frames=N/A
    nb_read_packets=N/A
    DISPOSITION:default=1
    DISPOSITION:dub=0
    DISPOSITION:original=0
    DISPOSITION:comment=0
    DISPOSITION:lyrics=0
    DISPOSITION:karaoke=0
    DISPOSITION:forced=0
    DISPOSITION:hearing_impaired=0
    DISPOSITION:visual_impaired=0
    DISPOSITION:clean_effects=0
    DISPOSITION:attached_pic=0
    TAG:language=und
    TAG:handler_name=VideoHandler
    [/STREAM]
    [STREAM]
    index=1
    codec_name=aac
    codec_long_name=AAC (Advanced Audio Coding)
    profile=HE-AACv2
    codec_type=audio
    codec_time_base=1/44100
    codec_tag_string=mp4a
    codec_tag=0x6134706d
    sample_fmt=fltp
    sample_rate=44100
    channels=2
    channel_layout=stereo
    bits_per_sample=0
    id=N/A
    r_frame_rate=0/0
    avg_frame_rate=0/0
    time_base=1/44100
    start_pts=-7100
    start_time=-0.160998
    duration_ts=1083268
    duration=24.563900
    bit_rate=47738
    max_bit_rate=48053
    bits_per_raw_sample=N/A
    nb_frames=526
    nb_read_frames=N/A
    nb_read_packets=N/A
    DISPOSITION:default=1
    DISPOSITION:dub=0
    DISPOSITION:original=0
    DISPOSITION:comment=0
    DISPOSITION:lyrics=0
    DISPOSITION:karaoke=0
    DISPOSITION:forced=0
    DISPOSITION:hearing_impaired=0
    DISPOSITION:visual_impaired=0
    DISPOSITION:clean_effects=0
    DISPOSITION:attached_pic=0
    TAG:language=und
    TAG:handler_name=SoundHandler
    [/STREAM]
    [FORMAT]
    filename=OriginalVideo.mp4
    nb_streams=2
    nb_programs=0
    format_name=mov,mp4,m4a,3gp,3g2,mj2
    format_long_name=QuickTime / MOV
    start_time=-0.160998
    duration=24.564000
    size=753253
    bit_rate=245319
    probe_score=100
    TAG:major_brand=isom
    TAG:minor_version=512
    TAG:compatible_brands=isomiso2avc1mp41
    TAG:title=343520959333629
    TAG:encoder=Lavf56.40.101
    [/FORMAT]