Recherche avancée

Médias (1)

Mot : - Tags -/stallman

Autres articles (73)

  • Publier sur MédiaSpip

    13 juin 2013

    Puis-je poster des contenus à partir d’une tablette Ipad ?
    Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir

  • XMP PHP

    13 mai 2011, par

    Dixit Wikipedia, XMP signifie :
    Extensible Metadata Platform ou XMP est un format de métadonnées basé sur XML utilisé dans les applications PDF, de photographie et de graphisme. Il a été lancé par Adobe Systems en avril 2001 en étant intégré à la version 5.0 d’Adobe Acrobat.
    Étant basé sur XML, il gère un ensemble de tags dynamiques pour l’utilisation dans le cadre du Web sémantique.
    XMP permet d’enregistrer sous forme d’un document XML des informations relatives à un fichier : titre, auteur, historique (...)

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

  • Send 2 different feeds to ffserver from ffmpeg

    30 avril 2015, par Niklas Tampier Holmgren

    I’m currently working in a project where I have to stream 2 webcams streams from a computer to another through a TCP connection, I can stream 1 without problem :

    using

    ffserver.conf :

               HTTPPort 8090
               HTTPBindAddress 0.0.0.0
               MaxClients 40
               MaxBandwidth 30000

               CustomLog -
               NoDaemon

               <stream>
               Format status
               ACL allow localhost
               ACL allow 192.168.0.0 192.168.255.255
               </stream>

              #feed for camera 1
              <feed>
              File /tmp/webcam1.ffm
              FileMaxSize 100M
              </feed>

              #feed for camera 2
              <feed>
              File /tmp/webcam2.ffm
              FileMaxSize 100M
              </feed>

             #stream for feed 1
             <stream>
             Feed webcam1.ffm
             Format mjpeg
             VideoSize 1280x720
             VideoFrameRate 30
             Preroll 0
             NoAudio
             Strict -1
             </stream>

             #stream for feed2
             <stream>
             Feed webcam2.ffm
             Format mjpeg
             VideoSize 1280x720
             VideoFrameRate 30
             Preroll 0
             NoAudio
             Strict -1
             </stream>

    command to run ffserver :

             ffserver /etc/ffserver.conf

    command to feed ffserver :

            ffmpeg -v 2 -r 20 -f video4linux2 -i /dev/video0 http://localhost/webcam1.ffm

    and it works perfect, but when I try to run the other feed :

            ffmpeg -v 2 -r 20 -f video4linux2 -i /dev/video1 http://localhost/webcam2.ffm

    I can see just the second stream and the first one do not work anymore.
    some idea ?

  • FFMPEG make adjustment on first frame

    30 avril 2022, par iDeveloper

    I am using FFMPEG library to convert images to video file in my software program.

    &#xA;

    Here frameRate is 1 or 5. So, I need a dynamic image based on time for first 5 seconds. So, in the images folder if there is more than 10 images then I set frameRate as 5 for else frame rate is 1

    &#xA;

    Algorithm :

    &#xA;

    let startNumber: Int&#xA;let blackFrame  = self.sourceURL.appendingPathComponent("TIME_STAMP.jpg", isDirectory: false)&#xA;    &#xA;    if FileManager.default.fileExists(atPath: blackFrame.path){&#xA;       &#xA;        let data = try! Data(contentsOf: blackFrame)&#xA;        &#xA;        try? FileManager.default.removeItem(at: blackFrame)&#xA;&#xA;        if frameRate == "1"{&#xA;            &#xA;            startNumber = 20&#xA;            &#xA;            for i in 20...24{&#xA;                &#xA;                let url = sourceURL.appendingPathComponent("img\(i).jpg", isDirectory: false)&#xA;                try? data.write(to: url)&#xA;            }&#xA;            &#xA;        }else{&#xA;            &#xA;            startNumber = 0&#xA;            for i in 0...24{&#xA;                &#xA;                let url = sourceURL.appendingPathComponent("img\(i).jpg", isDirectory: false)&#xA;                try? data.write(to: url)&#xA;            }&#xA;        }&#xA;        &#xA;    }else{&#xA;        &#xA;        startNumber = 25&#xA;    }&#xA; &#xA;    let arguments: [String] = [&#xA;        "-y",&#xA;        "-framerate", frameRate,&#xA;        "-start_number",  "\(startNumber)",&#xA;        "-i", "\(sourceURL.path)/img%0d.jpg",&#xA;        "-c:v", "libx264",&#xA;        "-crf", "28",&#xA;        outputURL.path&#xA;    ]&#xA;

    &#xA;

    This is how I am constructing the arguments. It's working perfect on fast systems. but for slow systems the creation of custom time image takes time than the FFMPEG execution. So, the output video file is mixed of various frames instead of 1....N ;

    &#xA;

    So, I don't want to create the 5 or 25 images each time. Instead can am I able to set frame rate for first image only ? or is there any alternative ?

    &#xA;

    Thank you !

    &#xA;

  • How can I automate the subtitle adding process in FFMPEG ?

    23 septembre 2022, par Phoeniqz

    The situation is, that I have 10 MP4 videos and a folder for each of them that has the same name as its video. In each of folders there are around 30 SRT files I need to add. I would like to automate this. I mean a script that would add each SRT file to the video and add the correct handler for the subtitles, so that the subtitle would appear as "English" instead of "Subtitle #12" in a movie player. I made a python script ; it's far from perfect and it does not add the handlers correctly.

    &#xA;

    The name of each SRT file is something like "20_Hebrew.srt"

    &#xA;

    &#xA;&#xA;import os&#xA;file_dir = r"Path/to/my/files"&#xA;sub_dir = file_dir &#x2B; "/Subs"&#xA;&#xA;&#xA;def add_sub(file, file_name):&#xA;    cmd = f"ffmpeg -i &#x27;{file}&#x27; "&#xA;    sub_list = []&#xA;&#xA;    no_extension = file_name.replace(".mp4", "")&#xA;&#xA;    for sub_name in os.listdir(sub_dir &#x2B; f"/{no_extension}"):&#xA;        s = os.path.join(sub_dir &#x2B; f"/{no_extension}", sub_name)&#xA;&#xA;        if os.path.isfile(s):&#xA;            cmd &#x2B;= f"-i &#x27;{s}&#x27; "&#xA;            sub_list.append(s)&#xA;    &#xA;    cmd &#x2B;= "-map 0:v -map 0:a "&#xA;&#xA;    for i, v in enumerate(sub_list):&#xA;        cmd &#x2B;= f"-map {i&#x2B;1} "&#xA;    &#xA;    cmd &#x2B;= "-c:v copy -c:a copy "&#xA;&#xA;    for i, v in enumerate(sub_list):&#xA;        sub_lang = v.replace(".srt", "")&#xA;        index = sub_lang.index(f"/Subs/")&#xA;        sub_lang = sub_lang[index:]&#xA;        index = sub_lang.index("_")&#xA;        sub_lang = sub_lang[index&#x2B;1:]&#xA;&#xA;        cmd &#x2B;= f"-c:s:{i} mov_text -metadata:s:s:{i} language=&#x27;{sub_lang}&#x27; -metadata:s:s:{i} handler=&#x27;{sub_lang}&#x27; "&#xA;&#xA;    cmd &#x2B;= f"&#x27;{file}_OUTP.mp4&#x27;"&#xA;&#xA;    os.system(cmd)&#xA;&#xA;for file_name in os.listdir(file_dir):&#xA;    f = os.path.join(file_dir, file_name)&#xA;&#xA;    if os.path.isfile(f):&#xA;        add_sub(f, file_name) 

    &#xA;