Recherche avancée

Médias (1)

Mot : - Tags -/école

Autres articles (84)

  • Le profil des utilisateurs

    12 avril 2011, par

    Chaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
    L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...)

  • Use, discuss, criticize

    13 avril 2011, par

    Talk to people directly involved in MediaSPIP’s development, or to people around you who could use MediaSPIP to share, enhance or develop their creative projects.
    The bigger the community, the more MediaSPIP’s potential will be explored and the faster the software will evolve.
    A discussion list is available for all exchanges between users.

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

  • ffmpeg webm encode for low powered devices

    21 février 2017, par Max Tkachenko

    I want to play transparent video into my app using built-in player over phone’s camera capture. I try to encode my video with alpha channel for android device :

    ffmpeg -i "Comp.avi" -c:v libvpx -pix_fmt yuva420p -metadata:s:v:0 alpha_mode="1" output.webm

    The result is pretty good, but I have lags (freezing video from time to time) while playing it on my android phone. Is it any options to improve decode performance ?

    Some console output :

    D:\SOFT\ffmpeg-20160207-git-9ee4c89-win64-static\bin>ffmpeg -i "d:\temp\cherti\Comp 1.avi" -c:v libvpx -pix_fmt yuva420p -metadata:s:v:0 alpha_mode="1" d:\temp\cherti\output.webm
    ffmpeg version N-80386-g5f5a97d Copyright (c) 2000-2016 the FFmpeg developers
     built with gcc 5.4.0 (GCC)
     configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-nvenc --enable-avisynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libfreetype --enable-libgme --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmfx --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libschroedinger --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-lzma --enable-decklink --enable-zlib
     libavutil      55. 24.100 / 55. 24.100
     libavcodec     57. 46.100 / 57. 46.100
     libavformat    57. 38.100 / 57. 38.100
     libavdevice    57.  0.101 / 57.  0.101
     libavfilter     6. 46.101 /  6. 46.101
     libswscale      4.  1.100 /  4.  1.100
     libswresample   2.  1.100 /  2.  1.100
     libpostproc    54.  0.100 / 54.  0.100
    Input #0, avi, from 'd:\temp\cherti\Comp 1.avi':
     Metadata:
       date            : 2017-02-18T14:10:42.00916
       encoder         : Adobe After Effects CC 2015 (Windows)
     Duration: 00:00:05.00, start: 0.000000, bitrate: 1592542 kb/s
       Stream #0:0: Video: rawvideo, bgra, 1080x1920, 1605907 kb/s, 24 fps, 24 tbr, 24 tbn, 24 tbc
    File 'd:\temp\cherti\output.webm' already exists. Overwrite ? [y/N] y
    [libvpx @ 0000000002593640] v1.5.0
    [webm @ 00000000025a54e0] Using AVStream.codec to pass codec parameters to muxers is deprecated, use AVStream.codecpar instead.
    Output #0, webm, to 'd:\temp\cherti\output.webm':
     Metadata:
       date            : 2017-02-18T14:10:42.00916
       encoder         : Lavf57.38.100
       Stream #0:0: Video: vp8 (libvpx), yuva420p, 1080x1920, q=-1--1, 200 kb/s, 24 fps, 1k tbn, 24 tbc
       Metadata:
         alpha_mode      : 1
         encoder         : Lavc57.46.100 libvpx
       Side data:
         cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
    Stream mapping:
     Stream #0:0 -> #0:0 (rawvideo (native) -> vp8 (libvpx))
  • Android : Recording audio in Android and then reading audio into python

    4 février 2017, par Hephaestus

    I need to record audio in an Android application that needs to be imported into Python (ndarray) for plotting and signal processing. It seemed like such a simple idea.
    I started with a simple bit of code for AAC/MPEG4 recording. Recording worked great. I can play it on the Android phone (Nexus 5X) and on a Mac (Quicktime). No problem ! Right ?!? But finding codec/formats that match between Android and Python seems to not be trivial. I’m wondering if the file/codec format written by Android is non-standard and FFMPEG can’t read it.
    If so, what is good audio format/codec that can be written simply in Android and read into an array in Python (2.7.x). Thanks.

    Details :
    Here is an abbreviated form of the android code :

    private final int AUDIO_SAMPLE_RATE = 16000;  
    private final String FILE_EXTENSION = "m4a";  // Audio file extension
    mAbsolutePathFile = workingDir + "/" + mFilename + FILE_EXTENSION;
    mMediaRecording = new MediaRecorder();
    mMediaRecording.setAudioSource (MediaRecorder.AudioSource.MIC);
    mMediaRecording.setOutputFormat(MediaRecorder.OutputFormat.MPEG_4);
    mMediaRecording.setAudioEncoder(MediaRecorder.AudioEncoder.AAC);
    mMediaRecording.setAudioSamplingRate(AUDIO_SAMPLE_RATE);
    mMediaRecording.setOutputFile(mAbsolutePathFile);
    mMediaRecording.prepare();
    mMediaRecording.start();

    As I mentioned, the result audio plays nicely in both Android and MacOS, so all seemed well. I did a bit of searching to find a python package for AAC audio and pydub looked like the simplest (I tried audiotools, but couldn’t find sample code). To install pydub, I followed the instructions :

    pip install pydub

    and

    brew install libav --with-libvorbis --with-sdl --with-theora

    and

    brew install ffmpeg --with-libvorbis --with-ffplay --with-theora

    Following the discussions (here), i tested ffmpeg and it does execute from the command line :

     $ffmpeg
     ffmpeg version 3.2.2 Copyright (c) 2000-2016 the FFmpeg developers
     built with Apple LLVM version 8.0.0 (clang-800.0.42.1)

    But when I try to read the file using Python :

    import pydub
    pydub.AudioSegment.from_file("sensorlog_2017-02-03_12-50-25-345_Dev26c5_Loc27_TypeAUDIO.m4a", "aac")

    I get :

    Traceback (most recent call last):
     File "...anaconda2/lib/python2.7/site-packages/IPython/core/interactiveshell.py", line 2881, in run_code
       exec(code_obj, self.user_global_ns, self.user_ns)
     File "", line 1, in <module>
    pydub.AudioSegment.from_file("sensorlog_2017-02-03_12-50-25-345_Dev26c5_Loc27_TypeAUDIO.m4a", "aac")
    File ".../anaconda2/lib/python2.7/site-packages/pydub/audio_segment.py", line 472, in from_file
       raise CouldntDecodeError("Decoding failed. ffmpeg returned error code: {0}\n\nOutput from ffmpeg/avlib:\n\n{1}".format(p.returncode, p_err))
    CouldntDecodeError: Decoding failed. ffmpeg returned error code: 1
    Output from ffmpeg/avlib:
    avconv version 11.4, Copyright (c) 2000-2014 the Libav developers
     built on Feb  3 2017 12:09:15 with Apple LLVM version 8.0.0 (clang-800.0.42.1)
    [aac @ 0x7ff30001cc00] get_buffer() failed
    [aac @ 0x7ff30001cc00] channel element 3.14 is not allocated
    [aac @ 0x7ff30001cc00] Sample rate index in program config element does not match the sample rate index configured by the container.
    [aac @ 0x7ff30001cc00] Input buffer exhausted before END element found
    [aac @ 0x7ff30001cc00] More than one AAC RDB per ADTS frame is not implemented. Update your Libav version to the newest one from Git. If the problem still occurs, it means that your file has a feature which has not been implemented.
    [aac @ 0x7ff30001cc00] Error decoding AAC frame header.
    [aac @ 0x7ff300001000] Could not find codec parameters (Audio: aac, 4.0, fltp, 213 kb/s)
    [aac @ 0x7ff300001000] Estimating duration from bitrate, this may be inaccurate
    /var/folders/cm/1r6x6rbj7hn_51qvfjzj7nx80000gn/T/tmps7b8Gf: could not find codec parameters
    </module>

    In summary, is this a conflict between Android and FFMPEG ? Should I use a different codec/format ? Should I use a different Python Audio library ?
    Thanks.

  • Correct recording time of the first frame of a video

    27 juillet 2017, par Vítor Cézar

    How do I get the correct time of the first frame recorded on a video ? I executed the command

    ffprobe -v error -show_streams [file_path]

    and got these values of timecode and creation time for the first stream :

    TAG:creation_time=2017-07-26T16:48:10.000000Z
    TAG:language=eng
    TAG:handler_name=   GoPro AVC
    TAG:encoder=GoPro AVC encoder
    TAG:timecode=17:21:54:28

    The problem is that the video started being recorded on 16:48:11:504 and neither timecode nor creation time shows this value. If possible I need the precision on milliseconds.