Recherche avancée

Médias (1)

Mot : - Tags -/musée

Autres articles (71)

  • La sauvegarde automatique de canaux SPIP

    1er avril 2010, par

    Dans le cadre de la mise en place d’une plateforme ouverte, il est important pour les hébergeurs de pouvoir disposer de sauvegardes assez régulières pour parer à tout problème éventuel.
    Pour réaliser cette tâche on se base sur deux plugins SPIP : Saveauto qui permet une sauvegarde régulière de la base de donnée sous la forme d’un dump mysql (utilisable dans phpmyadmin) mes_fichiers_2 qui permet de réaliser une archive au format zip des données importantes du site (les documents, les éléments (...)

  • 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

  • Des sites réalisés avec MediaSPIP

    2 mai 2011, par

    Cette page présente quelques-uns des sites fonctionnant sous MediaSPIP.
    Vous pouvez bien entendu ajouter le votre grâce au formulaire en bas de page.

Sur d’autres sites (11052)

  • ffmpeg node js s3 stream screenshots qestion

    20 octobre 2015, par user3564443

    On my Node js server I need get video from s3, generate thumbnail for it, set thumbnail to s3, without saving video or thumbnail on my server. So I need to use streams for this. For thumbnail generation I use fluent-ffmpeg.

    Is it possible to get screenshots from streams using fluent-ffmpeg ?

    Is the correct way to intercept s3 getObject stream, that there was no need to download full video ?

    var config = require('../config');
    var AWS = require('aws-sdk');
    AWS.config.update({
     accessKeyId: config.AWS_accessKeyId,
     secretAccessKey: config.AWS_secretAccessKey,
     region: 'eu-west-1'
    });
    var s3 = new AWS.S3();
    var fs = require('fs');
    var ffmpeg = require('fluent-ffmpeg');

    exports.generateVideoThumbnail = function(fileId, url, done) {
     var params = {
       Bucket: config.AWS_bucket,
       Key: url
     };
     var input = s3.getObject(params);
     var stream = fs.createWriteStream('./screenshot.png');
     return ffmpeg(input).screenshots({
       timestamps: ['0.1', '0.2'],
       size: '200x200'
     }).output('./screenshot.png').output(stream).on('error', function(err) {
       return done(err);
     }).on('end', function() {
       input.close();
       var _key = "files/" + fileId + "/thumbnail.png";
       return s3.putObject({
         Bucket: config.AWS_bucket,
         Key: _key,
         Body: stream,
         ContentType: 'image/jpeg'
       }, function(err) {
         return done(err);
       });
     });
    };
  • How to upload dynamically generated video thumbnails as a BLOB into MySQL database in PHP

    26 octobre 2018, par Parthapratim Neog

    Here is the code that has been used to create a thumbnail of a uploaded video. The thumbnail is automatically generated successfully, but now, I want to store that thumbnail as a BLOB in the Database.
    I know how to upload an image as a BLOB using form posts, but there is no form posts involved in this.

    Could someone guide me through this ?




    <form action="index.php" method="POST" enctype="multipart/form-data">
     <input type="file" />
     <input type="submit" value="Upload" />
    </form>
    &lt;?php
    if(isset($_POST['submit'])){
     /*
     -i input file name
     -an Disabled audio
     -ss Get image from x seconds in the video
     -s  size of the image
     */
     //Get one thumbnail from the video
     $ffmpeg = "C:\\ffmpeg\\bin\\ffmpeg";
     //echo $ffmpeg;
     $videoFile = $_FILES["file"]["tmp_name"];
     $imageFile = "1.jpg";
     $size = "120x90";
     $getFromSecond = 5;

     //echo "<pre>"; print_r($_FILES); die;
     //echo "video location: ",$videoFile,"<br />";
     echo $cmd = "$ffmpeg -i $videoFile -an -ss $getFromSecond -s $size $imageFile";

     echo "<br />";
     if(!shell_exec($cmd)){
      echo "Thumbnail Created!";
     }else{
      echo "Error creating Thumbnail";
     }

     /*// Get multiple thumbnails from one video
     $ffmpeg = "C:\\ffmpeg\\bin\\ffmpeg";
     $videoFile = $_FILES["file"]["tmp_name"];
     $size = "120x90";
     for($num =1; $num&lt;=3; $num++){
      $interval = $num * 3;
      shell_exec("$ffmpeg -i $videoFile -an -ss $interval -s $size $num.jpg");
      echo "Thumbnail Created!- $num.jpg<br />";
     }
     echo "<br />$num thumbnails Created!";
     */
    }
    ?>


    </pre>
  • How to upload dynamically generated video thumbnails as a BLOB into MySQL database in PHP

    26 novembre 2015, par Parthapratim Neog

    Here is the code that has been used to create a thumbnail of a uploaded video. The thumbnail is automatically generated successfully, but now, I want to store that thumbnail as a BLOB in the Database.
    I know how to upload an image as a BLOB using form posts, but there is no form posts involved in this.

    Could someone guide me through this ?




    <form action="index.php" method="POST" enctype="multipart/form-data">
     <input type="file" />
     <input type="submit" value="Upload" />
    </form>
    &lt;?php
    if(isset($_POST['submit'])){
     /*
     -i input file name
     -an Disabled audio
     -ss Get image from x seconds in the video
     -s  size of the image
     */
     //Get one thumbnail from the video
     $ffmpeg = "C:\\ffmpeg\\bin\\ffmpeg";
     //echo $ffmpeg;
     $videoFile = $_FILES["file"]["tmp_name"];
     $imageFile = "1.jpg";
     $size = "120x90";
     $getFromSecond = 5;

     //echo "<pre>"; print_r($_FILES); die;
     //echo "video location: ",$videoFile,"<br />";
     echo $cmd = "$ffmpeg -i $videoFile -an -ss $getFromSecond -s $size $imageFile";

     echo "<br />";
     if(!shell_exec($cmd)){
      echo "Thumbnail Created!";
     }else{
      echo "Error creating Thumbnail";
     }

     /*// Get multiple thumbnails from one video
     $ffmpeg = "C:\\ffmpeg\\bin\\ffmpeg";
     $videoFile = $_FILES["file"]["tmp_name"];
     $size = "120x90";
     for($num =1; $num&lt;=3; $num++){
      $interval = $num * 3;
      shell_exec("$ffmpeg -i $videoFile -an -ss $interval -s $size $num.jpg");
      echo "Thumbnail Created!- $num.jpg<br />";
     }
     echo "<br />$num thumbnails Created!";
     */
    }
    ?>


    </pre>