Recherche avancée

Médias (33)

Mot : - Tags -/creative commons

Autres articles (29)

  • Les autorisations surchargées par les plugins

    27 avril 2010, par

    Mediaspip core
    autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs

  • Librairies et binaires spécifiques au traitement vidéo et sonore

    31 janvier 2010, par

    Les logiciels et librairies suivantes sont utilisées par SPIPmotion d’une manière ou d’une autre.
    Binaires obligatoires FFMpeg : encodeur principal, permet de transcoder presque tous les types de fichiers vidéo et sonores dans les formats lisibles sur Internet. CF ce tutoriel pour son installation ; Oggz-tools : outils d’inspection de fichiers ogg ; Mediainfo : récupération d’informations depuis la plupart des formats vidéos et sonores ;
    Binaires complémentaires et facultatifs flvtool2 : (...)

  • Support audio et vidéo HTML5

    10 avril 2011

    MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
    Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
    Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
    Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...)

Sur d’autres sites (2015)

  • How to watermark with overlay fadeout with ffmpeg [closed]

    19 février, par Kevin Waterson

    I wish to put a watermark on my video, and a text overlay.
The text overlay should fade out after the first three seconds.
The watermark is permanent.

    


    This is what I have come up with, however, the watermark seems to push the overlay down.

    


    ffmpeg -y -i in.mp4 -i images/watermark.png -filter_complex "[0:v][1:v]overlay=10:10[bg] ;[bg]drawtext=fontfile=fonts/SAMAN___.ttf:text='Testing':box=1:boxborderw=800|800:boxcolor=black:fontsize=40:fontcolor=white:alpha='if(lt(t,2),0,if(lt(t,3),(t-2)/1,if(lt(t,6),1,if(lt(t,7),(1-(t-6))/1,0))))':x=(w-text_w)/2:y=(h-text_h)/2:y=h-th-10[out]" -map "[out]" -map 0:a out.mp4

    


  • How to add ffmpeg watermark text and trim videos to 60 seconds on this PHP video upload ?

    6 novembre 2017, par Brains Akd

    Below is the code for my video upload

    if (isset($_POST) and $_SERVER['REQUEST_METHOD'] == "POST") {


        if (isset($_GET['id']) && $_GET['id'] != "") {
            $id = $_GET['id'];
       }/* else {
           $id = $_SESSION['user_id'];
       }*/
      extract($_POST) ;

       $path = "video/answer_video/"; //set your folder path
       //set the valid file extensions
      // $valid_formats = array("mp4", "jpg", "png", "gif", "bmp", "jpeg", "GIF", "JPG", "PNG", "doc", "txt", "docx", "pdf", "xls", "xlsx"); //add the formats you want to upload
    $valid_formats = array("mp4"); //add the formats you want to upload

       $name = $_FILES['answer_video']['name']; //get the name of the file

       $size = $_FILES['answer_video']['size']; //get the size of the file

       if (strlen($name)) { //check if the file is selected or cancelled after pressing the browse button.
           list($txt, $ext) = explode(".", $name); //extract the name and extension of the file
           if (in_array($ext, $valid_formats)) { //if the file is valid go on.
               if ($size ) { // check if the file size is more than 2 mb
                   $file_name = $_POST['filename']; //get the file name
                   $question_id = $_POST['question_id'];  
                   // $title = $_POST['title'];
                   $title = strip_tags(trim($_POST['title']));
                   //get hashtag from message
                   $hashtag = gethashtags($title);

                   //$tags = $_POST['tags'];
                   $category = $_POST['category'];

                   $tmp = $_FILES['answer_video']['tmp_name'];


                   if (move_uploaded_file($tmp, $path . $name)) { //check if it the file move successfully.
                        $answer_video = $name;
                          $answer_type = "uploaded";

                       $video = $path . $name;
                       $length = 5;

    $randomletter = substr(str_shuffle("abcdefghijklmnopqrstuvwxyz"), 0, $length);
                      $rand = rand(1,10000000);
    $uniqueName = uniqid($rand);
    $thumbnail = "images/thumbnail_{$uniqueName}_{$randomletter}.jpg";

    // shell command [highly simplified, please don't run it plain on your script!]
    shell_exec("ffmpeg -i $video -deinterlace -an -ss 1 -t 00:00:01 -r 1 -y -vcodec mjpeg -f mjpeg $thumbnail 2>&1");







                       $msg = "Uploaded Successfully!";  

                        echo json_encode(array('msg'=>$msg,'res'=>$question_id));
                         $userid = $_SESSION['user_id'];

    How do I add top right watermark and trim the uploading videos to 30 seconds.? please do help

    I tried many times but it didn’t work..
    Your help is appreciated..
    Ffmpeg is working fine on the server and but didnt know how to do the above required

  • How to add ffmpeg watermark text on this PHP video upload ?

    6 novembre 2017, par Brains Akd

    Below is the code for my video upload

    if (isset($_POST) and $_SERVER['REQUEST_METHOD'] == "POST") {


        if (isset($_GET['id']) && $_GET['id'] != "") {
            $id = $_GET['id'];
       }/* else {
           $id = $_SESSION['user_id'];
       }*/
      extract($_POST) ;

       $path = "video/answer_video/"; //set your folder path
       //set the valid file extensions
      // $valid_formats = array("mp4", "jpg", "png", "gif", "bmp", "jpeg", "GIF", "JPG", "PNG", "doc", "txt", "docx", "pdf", "xls", "xlsx"); //add the formats you want to upload
    $valid_formats = array("mp4"); //add the formats you want to upload

       $name = $_FILES['answer_video']['name']; //get the name of the file

       $size = $_FILES['answer_video']['size']; //get the size of the file

       if (strlen($name)) { //check if the file is selected or cancelled after pressing the browse button.
           list($txt, $ext) = explode(".", $name); //extract the name and extension of the file
           if (in_array($ext, $valid_formats)) { //if the file is valid go on.
               if ($size ) { // check if the file size is more than 2 mb
                   $file_name = $_POST['filename']; //get the file name
                   $question_id = $_POST['question_id'];  
                   // $title = $_POST['title'];
                   $title = strip_tags(trim($_POST['title']));
                   //get hashtag from message
                   $hashtag = gethashtags($title);

                   //$tags = $_POST['tags'];
                   $category = $_POST['category'];

                   $tmp = $_FILES['answer_video']['tmp_name'];


                   if (move_uploaded_file($tmp, $path . $name)) { //check if it the file move successfully.
                        $answer_video = $name;
                          $answer_type = "uploaded";

                       $video = $path . $name;
                       $length = 5;

    $randomletter = substr(str_shuffle("abcdefghijklmnopqrstuvwxyz"), 0, $length);
                      $rand = rand(1,10000000);
    $uniqueName = uniqid($rand);
    $thumbnail = "images/thumbnail_{$uniqueName}_{$randomletter}.jpg";

    // shell command [highly simplified, please don't run it plain on your script!]
    shell_exec("ffmpeg -i $video -deinterlace -an -ss 1 -t 00:00:01 -r 1 -y -vcodec mjpeg -f mjpeg $thumbnail 2>&1");







                       $msg = "Uploaded Successfully!";  

                        echo json_encode(array('msg'=>$msg,'res'=>$question_id));
                         $userid = $_SESSION['user_id'];

    How do I add top right watermark . please do help

    I tried many times but it didn’t work..
    Your help is appreciated..
    Ffmpeg is working fine on the server and but didnt know how to do the above required .
    I dont know how to implement the ffmpeg scripting on this.
    I need to watermark before saving the video to folder.