Recherche avancée

Médias (1)

Mot : - Tags -/belgique

Autres articles (77)

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

  • Configurer la prise en compte des langues

    15 novembre 2010, par

    Accéder à la configuration et ajouter des langues prises en compte
    Afin de configurer la prise en compte de nouvelles langues, il est nécessaire de se rendre dans la partie "Administrer" du site.
    De là, dans le menu de navigation, vous pouvez accéder à une partie "Gestion des langues" permettant d’activer la prise en compte de nouvelles langues.
    Chaque nouvelle langue ajoutée reste désactivable tant qu’aucun objet n’est créé dans cette langue. Dans ce cas, elle devient grisée dans la configuration et (...)

  • Sélection de projets utilisant MediaSPIP

    29 avril 2011, par

    Les exemples cités ci-dessous sont des éléments représentatifs d’usages spécifiques de MediaSPIP pour certains projets.
    Vous pensez avoir un site "remarquable" réalisé avec MediaSPIP ? Faites le nous savoir ici.
    Ferme MediaSPIP @ Infini
    L’Association Infini développe des activités d’accueil, de point d’accès internet, de formation, de conduite de projets innovants dans le domaine des Technologies de l’Information et de la Communication, et l’hébergement de sites. Elle joue en la matière un rôle unique (...)

Sur d’autres sites (8144)

  • How to configure FFmpeg in windows ? [closed]

    2 août 2021, par GrassWarlock

    Hey there i'm not very tech savvy.

    


    when i invoke this command :

    


    ffmpeg -i input.mp4 -i subtitles.srt -map 0 -map 1 -c copy -c:v libx264 -crf 23 -preset veryfast output.mp4


    


    ( which is supposed to overlay 'input.mp4' with subtitles from 'subtitle.srt' )

    


    i get the following output :

    


    ffmpeg version 2021-07-27-git-0068b3d0f0-full_build-www.gyan.dev Copyright (c) 2000-2021 the FFmpeg developers
  built with gcc 10.3.0 (Rev5, Built by MSYS2 project)
  configuration: --enable-gpl --enable-version3 --enable-static --disable-w32threads --disable-autodetect --enable-fontconfig --enable-iconv --enable-gnutls --enable-libxml2 --enable-gmp --enable-lzma --enable-libsnappy --enable-zlib --enable-librist --enable-libsrt --enable-libssh --enable-libzmq --enable-avisynth --enable-libbluray --enable-libcaca --enable-sdl2 --enable-libdav1d --enable-libzvbi --enable-librav1e --enable-libsvtav1 --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxvid --enable-libaom --enable-libopenjpeg --enable-libvpx --enable-libass --enable-frei0r --enable-libfreetype --enable-libfribidi --enable-libvidstab --enable-libvmaf --enable-libzimg --enable-amf --enable-cuda-llvm --enable-cuvid --enable-ffnvcodec --enable-nvdec --enable-nvenc --enable-d3d11va --enable-dxva2 --enable-libmfx --enable-libglslang --enable-vulkan --enable-opencl --enable-libcdio --enable-libgme --enable-libmodplug --enable-libopenmpt --enable-libopencore-amrwb --enable-libmp3lame --enable-libshine --enable-libtheora --enable-libtwolame --enable-libvo-amrwbenc --enable-libilbc --enable-libgsm --enable-libopencore-amrnb --enable-libopus --enable-libspeex --enable-libvorbis --enable-ladspa --enable-libbs2b --enable-libflite --enable-libmysofa --enable-librubberband --enable-libsoxr --enable-chromaprint
  libavutil      57.  2.100 / 57.  2.100
  libavcodec     59.  3.102 / 59.  3.102
  libavformat    59.  4.101 / 59.  4.101
  libavdevice    59.  0.100 / 59.  0.100
  libavfilter     8.  1.103 /  8.  1.103
  libswscale      6.  0.100 /  6.  0.100
  libswresample   4.  0.100 /  4.  0.100
  libpostproc    56.  0.100 / 56.  0.100
Input #0, matroska,webm, from 'video.mkv':
  Metadata:
    ENCODER         : Lavf59.4.101
  Duration: 00:05:39.94, start: 0.000000, bitrate: 665 kb/s
  Stream #0:0(eng): Video: vp9 (Profile 0), yuv420p(tv), 720x480, SAR 1:1 DAR 3:2, 29.97 fps, 29.97 tbr, 1k tbn (default)
    Metadata:
      DURATION        : 00:05:39.839000000
  Stream #0:1: Audio: aac (LC), 44100 Hz, stereo, fltp (default)
    Metadata:
      HANDLER_NAME    : SoundHandler
      VENDOR_ID       : [0][0][0][0]
      DURATION        : 00:05:39.940000000
Input #1, srt, from 'subtitles.srt':
  Duration: N/A, bitrate: N/A
  Stream #1:0: Subtitle: subrip
[mp4 @ 000001aa596242c0] Could not find tag for codec subrip in stream #2, codec not currently supported in container
Could not write header for output file #0 (incorrect codec parameters ?): Invalid argument
Error initializing output stream 0:2 --
Stream mapping:
  Stream #0:0 -> #0:0 (copy)
  Stream #0:1 -> #0:1 (copy)
  Stream #1:0 -> #0:2 (copy)
    Last message repeated 1 times


    


    i searched the internet and the official documentation mentions that libass should be enabled in the configuration in order for subtitling to work

    


    


    11.218 subtitles

    


    Draw subtitles on top of input video using the libass library.

    


    To enable compilation of this filter you need to configure FFmpeg with
—enable-libass. This filter also requires a build with libavcodec and libavformat to convert the passed subtitles file to ASS (Advanced
Substation Alpha) subtitles format

    


    


    how do i enable libass in configuration on windows ? my FFmpeg directory doesn't contain a configuration file nor a command that configures it from cmd

    


    Thanks alot in advance

    


  • What do I need in order to save animation videos from matplotlib in mp3 format ?

    27 juin 2022, par DarthMalloc

    I am using python3.8 on Linux Mint 19.3, and I am trying to save an animation created by a cellular automata model in matplotlib. My actual code for the model is private, but it uses the same code for saving the animation as the code shown below, which is a slight modification of one of the examples shown in the official matplotlib documentation :

    


    import numpy as np
import matplotlib.pyplot as plt
import matplotlib.animation as animation

fig, ax = plt.subplots()


def f(x, y):
    return np.sin(x) + np.cos(y)

x = np.linspace(0, 2 * np.pi, 120)
y = np.linspace(0, 2 * np.pi, 100).reshape(-1, 1)

fig, ax = plt.subplots()


    
ims = []
for i in range(60):
    x += np.pi / 15.
    y += np.pi / 20.
    im = ax.imshow(f(x, y), animated=True)
    if i == 0:
        ax.imshow(f(x, y))  # show an initial one first
    ims.append([im])

ani = animation.ArtistAnimation(fig, ims, interval=50, blit=True,
                                    repeat_delay=1000)

    # To save the animation, use e.g.
    #
    # ani.save("movie.mp4")
    #
    # or
    #
writer = animation.FFMpegWriter(fps=15, metadata=dict(artist='Me'), bitrate=1800)
ani.save("movie.mp3", writer=writer)


    


    When executed, the code produces this error :

    


        MovieWriter stderr:&#xA;    Output file #0 does not contain any stream&#xA;&#xA;    Traceback (most recent call last):&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/animation.py", line 234, in saving&#xA;        yield self&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/animation.py", line 1093, in save&#xA;        writer.grab_frame(**savefig_kwargs)&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/animation.py", line 351, in grab_frame&#xA;        self.fig.savefig(self._proc.stdin, format=self.frame_format,&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/figure.py", line 3046, in savefig&#xA;        self.canvas.print_figure(fname, **kwargs)&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/backend_bases.py", line 2319, in print_figure&#xA;        result = print_method(&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/backend_bases.py", line 1648, in wrapper&#xA;        return func(*args, **kwargs)&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/_api/deprecation.py", line 415, in wrapper&#xA;        return func(*inner_args, **inner_kwargs)&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/backends/backend_agg.py", line 486, in print_raw&#xA;        fh.write(renderer.buffer_rgba())&#xA;    BrokenPipeError: [Errno 32] Broken pipe&#xA;&#xA;    During handling of the above exception, another exception occurred:&#xA;&#xA;    Traceback (most recent call last):&#xA;      File "/home/justin/animation_test.py", line 36, in <module>&#xA;        ani.save("movie.mp3", writer=writer)&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/animation.py", line 1093, in save&#xA;        writer.grab_frame(**savefig_kwargs)&#xA;      File "/usr/lib/python3.8/contextlib.py", line 131, in __exit__&#xA;        self.gen.throw(type, value, traceback)&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/animation.py", line 236, in saving&#xA;        self.finish()&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/animation.py", line 342, in finish&#xA;        self._cleanup()  # Inline _cleanup() once cleanup() is removed.&#xA;      File "/usr/local/lib/python3.8/dist-packages/matplotlib/animation.py", line 373, in _cleanup&#xA;        raise subprocess.CalledProcessError(&#xA;    subprocess.CalledProcessError: Command &#x27;[&#x27;ffmpeg&#x27;, &#x27;-f&#x27;, &#x27;rawvideo&#x27;, &#x27;-vcodec&#x27;, &#x27;rawvideo&#x27;, &#x27;-s&#x27;, &#x27;640x480&#x27;, &#x27;-pix_fmt&#x27;, &#x27;rgba&#x27;, &#x27;-r&#x27;, &#x27;15&#x27;, &#x27;-loglevel&#x27;, &#x27;error&#x27;, &#x27;-i&#x27;, &#x27;pipe:&#x27;, &#x27;-vcodec&#x27;, &#x27;h264&#x27;, &#x27;-pix_fmt&#x27;, &#x27;yuv420p&#x27;, &#x27;-b&#x27;, &#x27;1800k&#x27;, &#x27;-metadata&#x27;, &#x27;artist=Me&#x27;, &#x27;-y&#x27;, &#x27;movie.mp3&#x27;]&#x27; returned non-zero exit status 1.&#xA;</module>

    &#xA;

    I have looked at posts on similar queries concerning matplotlib animations, but none have specifically included the error Output file #0 does not contain any stream. I have little experience with ffmpeg, so I am wondering what might be missing.

    &#xA;

  • How can a desktop node.js app play audio that may be controlled by the user like a media player ? [closed]

    19 février, par eedefeed

    I'm building a playlist manager that plays music. How can Node.JS play audio files quickly, reliably and with all the basic level features you would expect from a media player, namely :

    &#xA;

      &#xA;
    • play
    • &#xA;

    • pause
    • &#xA;

    • seek
    • &#xA;

    • stop
    • &#xA;

    • adjust volume
    • &#xA;

    &#xA;

    I'm targetting windows/linux, but a Windows-only solution but be okay (for now.)

    &#xA;

    I have tried a number of libraries and methods to play audio but it seems none of them are good enough :

    &#xA;

      &#xA;
    • Audic : it's reasonably good, but buggy. The play and pause functions sometimes get switched around. I also recall that there are some issues with uncaught exceptions somewhere in the dependencies that crash the entire app.
    • &#xA;

    • OBS : since the app is designed with broadcasting in mind, I've tried to use OBS's API to get it to play media. Unfortunately, it sometimes stops playback during some tracks, which is surprising since its underlying library, FFmpeg, plays them without issue.
    • &#xA;

    • node-groove : seems like its underlying library, libgroove, only supports linux. I can't find any builds to download, regardless.
    • &#xA;

    &#xA;

    Attempts to use Speaker (which seems pretty good) have also failed because all the decoders have big issues :

    &#xA;

      &#xA;
    • Anything using lame - I want support for all audio, not specific formats.
    • &#xA;

    • fluent-FFmpeg - this is a wrapper around FFmpeg's CLI interface. It has no play/pause function, but bonus library fluent-FFmpeg-util adds this feature. Unfortunately, its pause takes about 4 seconds to work, which I'm guessing is to do with a buffer being exhausted. This is just too latent. Seek would also work by stopping the CLI process and reloading the file, which seems massively inefficient.
    • &#xA;

    • Node Vlc - promising but ancient library that gives me reams of node-gyp errors on install. Poorly documented and no explanation of what the library to do
    • &#xA;

    • VLC Client - this library has uncaught exceptions that crash the app. Wrapping in try/catch doesn't help.
    • &#xA;

    • sound play - doesn't support play/pause
    • &#xA;

    &#xA;

    NPM's search function is filled with audio players designed to work in browsers, but I'm not building a web app. I guess it's an option but it seems inelegant to the point of rediculous.

    &#xA;

    So it seems the best option centres around FFmpeg. FFmpeg has libraries, and I'm aware that node has ways to hook into those libraries via some sort of C or C++ compatibility layer. Unfortunately, official documentation is rather dense. Different unofficial guides seem to be recommending conflicting approaches (and might be dated), and it's difficult to work out whether myriad technologies are working in tandem or are alternatives, renames or replacements : node-gyp, node-api, addons, windows-build-tools, nan, C vs C++, Visual Studio. It's difficult to make any decisions or know where to start.

    &#xA;

    Perhaps, also, another option is to use a Python library to interact with FFmpeg, since initial searches have indicated this might be possible. I wouldn't know whether this is a good option.

    &#xA;

    So my question is : what's my best option to play audio ? Is it another NPM module that I'm not aware of ? Is it a compatibility layer with FFmpeg libraries ?

    &#xA;