Recherche avancée

Médias (91)

Autres articles (28)

  • Création définitive du canal

    12 mars 2010, par

    Lorsque votre demande est validée, vous pouvez alors procéder à la création proprement dite du canal. Chaque canal est un site à part entière placé sous votre responsabilité. Les administrateurs de la plateforme n’y ont aucun accès.
    A la validation, vous recevez un email vous invitant donc à créer votre canal.
    Pour ce faire il vous suffit de vous rendre à son adresse, dans notre exemple "http://votre_sous_domaine.mediaspip.net".
    A ce moment là un mot de passe vous est demandé, il vous suffit d’y (...)

  • Les tâches Cron régulières de la ferme

    1er décembre 2010, par

    La gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
    Le super Cron (gestion_mutu_super_cron)
    Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...)

  • Taille des images et des logos définissables

    9 février 2011, par

    Dans beaucoup d’endroits du site, logos et images sont redimensionnées pour correspondre aux emplacements définis par les thèmes. L’ensemble des ces tailles pouvant changer d’un thème à un autre peuvent être définies directement dans le thème et éviter ainsi à l’utilisateur de devoir les configurer manuellement après avoir changé l’apparence de son site.
    Ces tailles d’images sont également disponibles dans la configuration spécifique de MediaSPIP Core. La taille maximale du logo du site en pixels, on permet (...)

Sur d’autres sites (4285)

  • Replace Special Characters In Batch-File Variable Feeding ffmpeg program

    14 janvier 2019, par whereswaller

    I am attempting to write a batch-file that leverages ffmpeg.exe to convert all files in a folder structure to mp3 format (specifically 128 KBps).

    My batch-file is presently unable to process filenames (constructed by concatenating the %_SOURCE% and %%~F variables) containing certain special characters generating the following errors :

    No such file or directory

    • ellipsis sign
    • en dash
    • em dash
    • minus sign

    Invalid argument

    • and  curved single quotation marks
    • and  curved double quotation marks

    Invalid argument (yet sometimes passes depending on where symbol is in the filename, for example, seems to work if placed between the n and t of Dont in C:\Users\Test\Documents\Input\Peter Bjorn And John - I Know You Dont Love Me.mp3)

    • - hyphen
    • ! exclamation mark
    • ~ tilde
    • ' non-curved single quotation mark
    • = equals sign
    • + plus sign
    • % percentage sign
    • ( open bracket

    How can I modify my batch-file script so that the %%~F variable escapes these characters correctly ?

    Example current filename input : C:\Users\Test\Documents\Input\Peter Bjorn And John - I Know You Don't Love Me.mp3

    Example desired filename input : C:\Users\Test\Documents\Input\Peter Bjorn And John - I Know You Don"^'"t Love Me.mp3

    Script (see line beginning C:\ffmpeg\bin\ffmpeg.exe) :

    @echo off
    setlocal EnableExtensions DisableDelayedExpansion

    rem // Define constants here:
    set "_SOURCE=C:\Users\Test\Documents\Input" & rem // (absolute source path)
    set "_TARGET=C:\Users\Test\Documents\Output"  & rem // (absolute target path)
    set "_PATTERN=*.*" & rem // (pure file pattern for input files)
    set "_FILEEXT=.mp3"   & rem // (pure file extension of output files)

    pushd "%_TARGET%" || exit /B 1
    for /F "delims=" %%F in ('
       cd /D "%_SOURCE%" ^&^& ^(rem/ list but do not copy: ^
           ^& xcopy /L /S /Y /I ".\%_PATTERN%" "%_TARGET%" ^
           ^| find ".\" ^& rem/ remove summary line;
       ^)
    ') do (
       2> nul mkdir "%%~dpF."

       rem // Set up the correct `ffmpeg` command line here:
       set "FFREPORT=file=C\:\\Users\\Test\\Documents\\Output\\ffreport-%%~F.log:level=32"
       "C:\ffmpeg\bin\ffmpeg.exe" -report -n -i "%_SOURCE%\%%~F" -vn -c:a libmp3lame -b:a 128k "%%~dpnF%_FILEEXT%"
       if not errorlevel 1  if exist "%%~dpnF%_FILEEXT%" del /f /q "%_SOURCE%\%%~F"

    )
    popd

    endlocal
    pause
  • Ffmpeg converting to HLS - video extremely low quality

    7 janvier 2019, par John Kim

    I’m building a streaming webapp that uses FFMPEG. The client sends webcam video using FFMPEG (converting the webm stream into mpeg-ts in the process) over RTMP, and the media server receives the mpeg-ts stream, transcodes it into HLS with multiple quality levels for ABR (using a master playlist).

    So far, I’ve got all of this working, except that my transcoding command creates HLS segments that are extremely low quality ; the video is very pixellated, and the best quality level (1080p) just looks like 240p scaled up to 1080p. In order to test my FFMPEG command I remuxed a sample high quality 1080p movie into mpeg-ts (I checked the quality, it looks the same as the original), and I’m using this command to transcode this movie into HLS for the test :

    ffmpeg.exe -threads 4 -filter_complex_threads 4 -vsync 1 -i output.ts -filter_complex
    "[v:0]split=5[s0][s1][s2][s3][s4];
    [s0]scale=w=1920:h=1080:flags=lanczos,yadif[v0];
    [s1]scale=w=1280:h=720:flags=lanczos,yadif[v1];
    [s2]scale=w=854:h=480:flags=lanczos,yadif[v2];
    [s3]scale=w=480:h=360:flags=lanczos,yadif[v3];
    [s4]scale=w=426:h=240:flags=lanczos,yadif[v4]"
    -map "[v0]" -pix_fmt yuv420p -r 23.976 -vcodec libx264 -b:v 3400k -preset medium -profile:v baseline -keyint_min 24 -g 48 -x264opts no-scenecut -strict experimental -map_metadata -1
    -map "[v1]" -pix_fmt yuv420p -r 23.976 -vcodec libx264 -b:v 1725k -preset medium -profile:v baseline -keyint_min 24 -g 48 -x264opts no-scenecut -strict experimental -map_metadata -1
    -map "[v2]" -pix_fmt yuv420p -r 23.976 -vcodec libx264 -b:v 960k -preset medium -profile:v baseline -keyint_min 24 -g 48 -x264opts no-scenecut -strict experimental -map_metadata -1
    -map "[v3]" -pix_fmt yuv420p -r 23.976 -vcodec libx264 -b:v 510k -preset medium -profile:v baseline -keyint_min 24 -g 48 -x264opts no-scenecut -strict experimental -map_metadata -1  
    -map "[v4]" -pix_fmt yuv420p -r 23.976 -vcodec libx264 -b:v 320k -preset medium -profile:v baseline -keyint_min 24 -g 48 -x264opts no-scenecut -strict experimental -map_metadata -1
    -map a:0 -map a:0 -map a:0 -map a:0 -map a:0 -c:a aac -b:a 96k -af “aresample=async=1:min_hard_comp=0.100000:first_pts=0”
    -f hls -var_stream_map "v:0,a:0 v:1,a:1, v:2,a:2, v:3,a:3, v:4,a:4"
    -hls_wrap 24 -hls_time 10 -master_pl_name master.m3u8 "C:/Users/John/Desktop/ffmpeg-20181218-978c935-win64-static/bin/vs%v/manifest.m3u8"

    I’m very new to FFMPEG, I referred to this article for the video options, and modified it to create HLS instead of mp4. Needless to say I botched this up pretty bad, although the command itself works and does what I need it to (other than the crappy quality). Could anyone help me optimize this command to make it transcode much less lossy video ?

  • Is it possible to vertically rotate a showwaves (or showfreqs) overlay using ffmpeg ?

    5 février 2019, par Introspectre

    I wish to take a showwaves (or showfreqs) overlay and center it vertically using ffmpeg, e.g.

    ffmpeg -i input.mp3 -filter_complex "[0:a]showspectrum=color=fiery:saturation=2:slide=scroll:scale=log:win_func=gauss:overlap=1:s=960x1080,pad=1920:1080[vs]; [0:a]showspectrum=color=fiery:saturation=2:slide=rscroll:scale=log:win_func=gauss:overlap=1:s=960x1080[ss]; [0:a]showwaves=s=1920x540:colors=B80000|950000|690000:mode=p2p,inflate[sw]; [vs][ss]overlay=w[out]; [out][sw]overlay=0:(H-h)/2[out]" -map "[out]" -map 0:a -c:v libx264 -preset fast -crf 18 -c:a copy output.mkv

    enter image description here

    As shown above, the showwaves output is centered horizontally. But would it also be possible to have it centered vertically ? Specifically, using a single -filter_complex command argument ?

    I’ve looked through the ffmpeg manual and searched stackoverflow for an answer, but to no avail.