Recherche avancée

Médias (91)

Autres articles (23)

  • 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 (...)

  • Supporting all media types

    13 avril 2011, par

    Unlike most software and media-sharing platforms, MediaSPIP aims to manage as many different media types as possible. The following are just a few examples from an ever-expanding list of supported formats : images : png, gif, jpg, bmp and more audio : MP3, Ogg, Wav and more video : AVI, MP4, OGV, mpg, mov, wmv and more text, code and other data : OpenOffice, Microsoft Office (Word, PowerPoint, Excel), web (html, CSS), LaTeX, Google Earth and (...)

  • 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 (...)

Sur d’autres sites (8267)

  • FFMPEG Process not ending when encoding libx264

    17 janvier 2015, par Jamie Hartnoll

    Well, I’m very new and inexperienced with using Process and using FFMPEG, and command line processes in ASP.NET in general... but, have something working, nearly !

    I’m trying to convert AVI files to MP4 files which can be streamed to an HTML5 player.

    After a lot of messing around, I have found that for this to work it has to be encoded with X264, but, for some reason, when I do this the FFMPEG process does not close/end.

    The code I am using is below and works perfectly if I use -vcodec mpeg4, but when I use -vcodec libx264, whilst it works and produces the file I need to Process never ends.

    To get round this, I am temporarily adding 5 second time out to WaitForExit in the Process, but this is definitely a hack and whilst is OK with what I am doing at the moment is not a robust solution.

    Can anyone point me in the direction of why this is happening ?!

    Public Shared Sub AviToMP4(VideoFileName As String, Optional DeleteSource As Boolean = True)

       Dim SourceFile As String = VideoFileName.Replace(".avi", "")
       Dim DestinationFile As String = SourceFile

       Dim FFMPEG_EXE_PATH As String = """" & System.AppDomain.CurrentDomain.BaseDirectory() & "ffMPEG.exe"""
       Dim Codec = "libx264" ' libx264 || mpeg4
       Dim cdml = " -i """ & SourceFile & ".avi"" -acodec aac -strict -2 -b:a 128k -vcodec " & Codec & " -b:v 1200k -flags +aic+mv4 """ & DestinationFile & ".mp4"""

       Dim ProcessorLocation As String = FFMPEG_EXE_PATH
       Dim CommandLines As String = cdml

       Try
           Dim ProcessingResponse As String = ""
           Using myProcess As New Process()
               myProcess.StartInfo.UseShellExecute = False
               myProcess.StartInfo.RedirectStandardInput = True
               myProcess.StartInfo.RedirectStandardOutput = True
               myProcess.StartInfo.RedirectStandardError = True
               myProcess.StartInfo.CreateNoWindow = True
               myProcess.StartInfo.WindowStyle = ProcessWindowStyle.Hidden
               myProcess.StartInfo.FileName = ProcessorLocation
               myProcess.StartInfo.Arguments = CommandLines
               myProcess.Start()
               ProcessingResponse = myProcess.StandardError.ReadToEnd()
               myProcess.WaitForExit(5000) ' <<< Have to put a timeout here for libx264 or it will never end!!
           End Using
           HttpContext.Current.Response.Write("<pre>" &amp; ProcessingResponse &amp; "</pre><hr />")
           If File.Exists(SourceFile) AndAlso DeleteSource Then
               File.Delete(SourceFile)
           End If
       Catch ex As Exception
           HttpContext.Current.Response.Write(ex.ToString &amp; "<p>")
       End Try

    End Sub
    </p>
  • Using video from raw folder in ffmpeg

    5 août 2018, par varmashrivastava

    How can i use video from raw folder of android studio as an input source in ffmpeg command ?Like in below command i want to use from raw folder video as an input-

    { "-y", "-i", input,"-ss", "5000", "-t", "10000", "-c","copy", output};
  • Change the framerate of a video including audio without re-encoding using ffmpeg

    12 août 2018, par Trojaner_

    I have a 30.02 FPS .mp4-video and I’m trying to convert it to 30 FPS. I found this question but if I try the method like described in the first answer the audio gets lost because the video is getting converted in a .h264-file which can’t contain audio as I read here.

    (I’m sorry if i’ve got issues with the english language, it isn’t my mother language)

    EDIT : Here goes the content I enter in the terminal and the output that returns

    Input : ffmpeg -y -i 01.mp4 -f h264 -c copy temp1.h264

    Output : (I replaced the real paths with path\to\...)

    ffmpeg version N-91589-ge0539f0349 Copyright (c) 2000-2018 the FFmpeg developers
    built with gcc 8.2.1 (GCC) 20180808
    configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-bzlib --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx --enable-amf --enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth
    libavutil      56. 18.102 / 56. 18.102
    libavcodec     58. 22.101 / 58. 22.101
    libavformat    58. 17.101 / 58. 17.101
    libavdevice    58.  4.101 / 58.  4.101
    libavfilter     7. 26.100 /  7. 26.100
    libswscale      5.  2.100 /  5.  2.100
    libswresample   3.  2.100 /  3.  2.100
    libpostproc    55.  2.100 / 55.  2.100
    Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'path\to\01.mp4':
    Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.17.101
    Duration: 00:02:42.01, start: 0.000000, bitrate: 5168 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1280x720, 5000 kb/s, 30.02 fps, 30 tbr, 16k tbn, 60 tbc (default)
    Metadata:
    handler_name    : VideoHandler
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 159 kb/s (default)
    Metadata:
    handler_name    : SoundHandler
    Output #0, h264, to 'path\to\temp1.h264':
    Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.17.101
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 1280x720, q=2-31, 5000 kb/s, 30.02 fps, 30 tbr, 30 tbn, 30 tbc (default)
    Metadata:
    handler_name    : VideoHandler
    Stream mapping:
    Stream #0:0 -> #0:0 (copy)
    Press [q] to stop, [?] for help
    frame= 4862 fps=0.0 q=-1.0 Lsize=   98859kB time=00:02:42.00 bitrate=4999.1kbits/s speed= 351x
    video:98860kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown

    Input : ffmpeg -y -r 30 -i "temp1.h264" -c copy "temp1.mp4"

    Output : (I replaced the real paths with path\to\...)

    ffmpeg version N-91589-ge0539f0349 Copyright (c) 2000-2018 the FFmpeg developers
    built with gcc 8.2.1 (GCC) 20180808
    configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-bzlib --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx --enable-amf --enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth
    libavutil      56. 18.102 / 56. 18.102
    libavcodec     58. 22.101 / 58. 22.101
    libavformat    58. 17.101 / 58. 17.101
    libavdevice    58.  4.101 / 58.  4.101
    libavfilter     7. 26.100 /  7. 26.100
    libswscale      5.  2.100 /  5.  2.100
    libswresample   3.  2.100 /  3.  2.100
    libpostproc    55.  2.100 / 55.  2.100
    Input #0, h264, from 'path\to\temp1.h264':
    Duration: N/A, bitrate: N/A
    Stream #0:0: Video: h264 (High), yuv420p(progressive), 1280x720, 30 fps, 30 tbr, 1200k tbn, 60 tbc
    Output #0, mp4, to 'path\to\temp1.mp4':
    Metadata:
    encoder         : Lavf58.17.101
    Stream #0:0: Video: h264 (High) (avc1 / 0x31637661), yuv420p(progressive), 1280x720, q=2-31, 30 fps, 30 tbr, 15360 tbn, 30 tbc
    Stream mapping:
    Stream #0:0 -> #0:0 (copy)
    Press [q] to stop, [?] for help
    [mp4 @ 0000018e11422ec0] Timestamps are unset in a packet for stream 0. This is deprecated and will stop working in the future. Fix your code to set the timestamps properly
    [mp4 @ 0000018e11422ec0] pts has no value
    Last message repeated 156 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:00:05.13 bitrate=5719.5kbits/s speed=10.2x
    Last message repeated 153 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:00:10.26 bitrate=4902.4kbits/s speed=10.2x
    Last message repeated 150 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:00:15.30 bitrate=4934.5kbits/s speed=10.2x
    Last message repeated 137 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:00:19.90 bitrate=4953.1kbits/s speed=9.91x
    Last message repeated 152 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:00:25.00 bitrate=4949.3kbits/s speed=9.97x
    Last message repeated 152 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:00:30.10 bitrate=4946.8kbits/s speed=  10x
    Last message repeated 152 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:00:35.20 bitrate=4945.0kbits/s speed=  10x
    Last message repeated 146 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:00:40.10 bitrate=4968.3kbits/s speed=9.99x
    Last message repeated 153 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:00:45.23 bitrate=4960.8kbits/s speed=  10x
    Last message repeated 147 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:00:50.16 bitrate=5016.4kbits/s speed=  10x
    Last message repeated 152 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:00:55.26 bitrate=4970.9kbits/s speed=  10x
    Last message repeated 151 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:00.33 bitrate=4970.6kbits/s speed=  10x
    Last message repeated 153 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:05.46 bitrate=4997.3kbits/s speed=  10x
    Last message repeated 149 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:10.46 bitrate=5029.6kbits/s speed=  10x
    Last message repeated 153 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:15.60 bitrate=5021.0kbits/s speed=  10x
    Last message repeated 151 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:20.66 bitrate=5017.6kbits/s speed=  10x
    Last message repeated 154 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:25.83 bitrate=4984.3kbits/s speed=10.1x
    Last message repeated 151 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:30.90 bitrate=4983.3kbits/s speed=10.1x
    Last message repeated 149 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:35.90 bitrate=4985.9kbits/s speed=10.1x
    Last message repeated 149 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:40.90 bitrate=4988.3kbits/s speed=  10x
    Last message repeated 151 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:45.96 bitrate=5007.0kbits/s speed=10.1x
    Last message repeated 150 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:51.00 bitrate=5006.7kbits/s speed=10.1x
    Last message repeated 150 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:01:56.03 bitrate=5006.4kbits/s speed=10.1x
    Last message repeated 147 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:02:00.96 bitrate=4992.9kbits/s speed=  10x
    Last message repeated 151 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:02:06.03 bitrate=4991.9kbits/s speed=  10x
    Last message repeated 149 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:02:11.03 bitrate=4993.5kbits/s speed=  10x
    Last message repeated 151 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:02:16.10 bitrate=4992.5kbits/s speed=  10x
    Last message repeated 153 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:02:21.23 bitrate=4989.2kbits/s speed=10.1x
    Last message repeated 152 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:02:26.33 bitrate=4987.3kbits/s speed=10.1x
    Last message repeated 149 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:02:31.33 bitrate=5016.5kbits/s speed=  10x
    Last message repeated 153 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:02:36.46 bitrate=5026.2kbits/s speed=10.1x
    Last message repeated 148 times
    [mp4 @ 0000018e11422ec0] pts has no valueB time=00:02:41.43 bitrate=4988.5kbits/s speed=  10x
    Last message repeated 15 times
    frame= 4862 fps=301 q=-1.0 Lsize=   98882kB time=00:02:41.96 bitrate=5001.3kbits/s speed=  10x
    video:98859kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.023950%