Recherche avancée

Médias (91)

Autres articles (111)

  • Les formats acceptés

    28 janvier 2010, par

    Les commandes suivantes permettent d’avoir des informations sur les formats et codecs gérés par l’installation local de ffmpeg :
    ffmpeg -codecs ffmpeg -formats
    Les format videos acceptés en entrée
    Cette liste est non exhaustive, elle met en exergue les principaux formats utilisés : h264 : H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10 m4v : raw MPEG-4 video format flv : Flash Video (FLV) / Sorenson Spark / Sorenson H.263 Theora wmv :
    Les formats vidéos de sortie possibles
    Dans un premier temps on (...)

  • Ajouter notes et légendes aux images

    7 février 2011, par

    Pour pouvoir ajouter notes et légendes aux images, la première étape est d’installer le plugin "Légendes".
    Une fois le plugin activé, vous pouvez le configurer dans l’espace de configuration afin de modifier les droits de création / modification et de suppression des notes. Par défaut seuls les administrateurs du site peuvent ajouter des notes aux images.
    Modification lors de l’ajout d’un média
    Lors de l’ajout d’un média de type "image" un nouveau bouton apparait au dessus de la prévisualisation (...)

  • Script d’installation automatique de MediaSPIP

    25 avril 2011, par

    Afin de palier aux difficultés d’installation dues principalement aux dépendances logicielles coté serveur, un script d’installation "tout en un" en bash a été créé afin de faciliter cette étape sur un serveur doté d’une distribution Linux compatible.
    Vous devez bénéficier d’un accès SSH à votre serveur et d’un compte "root" afin de l’utiliser, ce qui permettra d’installer les dépendances. Contactez votre hébergeur si vous ne disposez pas de cela.
    La documentation de l’utilisation du script d’installation (...)

Sur d’autres sites (7843)

  • Anomalie #3100 (Nouveau) : Bug - Base PostgreSQL

    20 novembre 2013, par _ CasP

    Bonjour,
    Je viens de créer un site mutualisé sur mon site. Mon ancien site à une base MYSQL et n’a pas de souci.
    En revanche le nouveau site à lui une base PostgreSQL.

    L’hébergement est chez OVH.

    je constate 2 chose étrange la première : lors de l’instalation du site après avoir renseigné le serveur et l’utilisateur, je me retrouve à avoir le choix parmi une multitude de base de donnée. Là ou habituellement je n’ai que le nom de celle que j’ai crée.
    Mais peux être ceci est un souci lié à OVH, je leur ai écrit pour demander.

    Le deuxième Bug a lieu lors de la création de RUBRIQUES dans l’espace privée.
    Cela fonctionne, cependant après la création je me retrouve avec une

    3 Erreur(s) dans le squeletteNuméro Message squelette boucle Ligne
    1 Array / /
    2 Array / /
    3 Array / /

    Warning : pg_query() [function.pg-query] : Query failed : ERREUR : la référence à la colonne « id_rubrique » est ambigu LINE 4 : GROUP BY id_rubrique,lang ^ in /homez.64/casp/www/ecrire/req/pg.php on line 168

    Warning : pg_query() [function.pg-query] : Query failed : ERREUR : la référence à la colonne « lang » est ambigu LINE 4 : GROUP BY id_article,lang ^ in /homez.64/casp/www/ecrire/req/pg.php on line 168

    Warning : pg_query() [function.pg-query] : Query failed : ERREUR : la référence à la colonne « lang » est ambigu LINE 4 : GROUP BY id_breve,lang ^ in /homez.64/casp/www/ecrire/req/pg.php on line 168

    Et je reste sur la page de crétion sans être redirigé. J’ai alors l’option :
    Votre modification a été enregistrée
    Si votre navigateur n’est pas redirigé, cliquez ici pour continuer.
    Tout fonctionne ce n’est donc pas dramatique. Mais c’est un peu gènant.

  • Find video resolution and video duration of remote mediafile

    22 février 2012, par osgx

    I want to write an program which can find some metainformation of mediafile. I'm interested in popular video formats, such as avi, mkv, mp4, mov (may be other popular too). I want basically to get :

    • Video size (720, 1080, 360 etc)
    • Total runtime of video (may be not very exact)
    • Number of audio streams
    • Name of video codec
    • Name of audio codec

    There is already the mediainfo, but in my program I want to get information about remote file, which may be accessed via ftp, http, samba ; or even torrent (there are some torrent solutions, which allows to read not-yet downloaded file).

    MediaInfo library have no support of samba (smb ://) and mkv format (for runtime).

    Also, I want to know, how much data should be downloaded to get this information. I want not to download full videofile because I have no enough disk space.

    Is this information in the first 1 or 10 or 100 KiloBytes of the file ? Is it at predictable offset if I know the container name and total file size ?

    PS : Platform is Linux, Language is C/C++

  • How to convert a Stream on the fly with FFMpegCore ?

    18 octobre 2023, par Adrian

    For a school project, I need to stream videos that I get from torrents while they are downloading on the server.
When the video is a .mp4 file, there's no problem, but I must also be able to stream .mkv files, and for that I need to convert them into .mp4 before sending them to the client, and I can't find a way to convert my Stream that I get from MonoTorrents with FFMpegCore into a Stream that I can send to my client.

    


    Here is the code I wrote to simply download and stream my torrent :

    


    var cEngine = new ClientEngine();

var manager = await cEngine.AddStreamingAsync(GenerateMagnet(torrent), ) ?? throw new Exception("An error occurred while creating the torrent manager");

await manager.StartAsync();
await manager.WaitForMetadataAsync();

var videoFile = manager.Files.OrderByDescending(f => f.Length).FirstOrDefault();
if (videoFile == null)
    return Results.NotFound();

var stream = await manager.StreamProvider!.CreateStreamAsync(videoFile, true);
return Results.File(stream, contentType: "video/mp4", fileDownloadName: manager.Name, enableRangeProcessing: true);


    


    I saw that the most common way to convert videos is by using ffmpeg. .NET has a package called FFMpefCore that is a wrapper for ffmpeg.

    


    To my previous code, I would add right before the return :

    


    if (!videoFile.Path.EndsWith(".mp4"))
{
    var outputStream = new MemoryStream();
    FFMpegArguments
        .FromPipeInput(new StreamPipeSource(stream), options =>
        {
            options.ForceFormat("mp4");
        })
        .OutputToPipe(new StreamPipeSink(outputStream))
        .ProcessAsynchronously();
    return Results.File(outputStream, contentType: "video/mp4", fileDownloadName: manager.Name, enableRangeProcessing: true);
}


    


    I unfortunately can't get a "live" Stream to send to my client.