Recherche avancée

Médias (91)

Autres articles (38)

  • MediaSPIP Core : La Configuration

    9 novembre 2010, par

    MediaSPIP Core fournit par défaut trois pages différentes de configuration (ces pages utilisent le plugin de configuration CFG pour fonctionner) : une page spécifique à la configuration générale du squelettes ; une page spécifique à la configuration de la page d’accueil du site ; une page spécifique à la configuration des secteurs ;
    Il fournit également une page supplémentaire qui n’apparait que lorsque certains plugins sont activés permettant de contrôler l’affichage et les fonctionnalités spécifiques (...)

  • Encodage et transformation en formats lisibles sur Internet

    10 avril 2011

    MediaSPIP transforme et ré-encode les documents mis en ligne afin de les rendre lisibles sur Internet et automatiquement utilisables sans intervention du créateur de contenu.
    Les vidéos sont automatiquement encodées dans les formats supportés par HTML5 : MP4, Ogv et WebM. La version "MP4" est également utilisée pour le lecteur flash de secours nécessaire aux anciens navigateurs.
    Les documents audios sont également ré-encodés dans les deux formats utilisables par HTML5 :MP3 et Ogg. La version "MP3" (...)

  • Support de tous types de médias

    10 avril 2011

    Contrairement à beaucoup de logiciels et autres plate-formes modernes de partage de documents, MediaSPIP a l’ambition de gérer un maximum de formats de documents différents qu’ils soient de type : images (png, gif, jpg, bmp et autres...) ; audio (MP3, Ogg, Wav et autres...) ; vidéo (Avi, MP4, Ogv, mpg, mov, wmv et autres...) ; contenu textuel, code ou autres (open office, microsoft office (tableur, présentation), web (html, css), LaTeX, Google Earth) (...)

Sur d’autres sites (4972)

  • Cleaning AVFrame properly

    12 septembre 2022, par Vencat

    I'm creating AVFrame object using av_frame_alloc() function and clearing it using av_frame_free(&frame) which internally calls av_frame_unref(), but it's not cleaning the memory properly. Heap size of my app grows exponentially in run time.

    



    Not working :

    



    AVFrame* frame = av_frame_alloc();
av_frame_free(&frame);


    



    Working :

    



    AVFrame* frame = av_frame_alloc();
av_free(frame->data[0]);


    



    As far as I know, av_frame_free() calls av_freep() which calls av_free() to free the dynamic memory. Memory gets cleaned, If I use av_free(frame->data[0]) directly instead of av_frame_free(&frame)

    


  • How can I add a random watermark to a video during processing in Node.js and Express.js using FFmpeg ?

    3 avril 2023, par Ariful islam

    I want to add a watermark to a video that changes randomly during processing. I am using Node.js and Express.js with FFmpeg. Currently, I am able to add a static watermark to the video using the drawtext filter. However, I want to change the watermark text randomly every few seconds.

    


    How can I achieve this using FFmpeg in my Node.js and Express.js app ? Here's my current code :

    


    const email = 'name@gmail.com';
app.post('/addwatermark', upload.single('video'), (req, res) => {
const fileName = path.basename(req.file.path) + '.mp4';
const outputPath = `public/reduceSize/${fileName}`;
const outputPathWithWatermark = `public/reduceSize/${fileName}-wm.mp4`;
let watermarkPosition = { x: 10, y: 650 };

// Create the directory if it doesn't exist
const outputDir = path.dirname(outputPathWithWatermark);
if (!fs.existsSync(outputDir)) {
    fs.mkdirSync(outputDir, { recursive: true });
}

// Send a comment to keep the connection alive
res.write(': ping\n\n');

// Function to randomly generate watermark position
const changeWatermarkPosition = () => {
    watermarkPosition = { x: Math.floor(Math.random() * 100), y: Math.floor(Math.random() * 100) };
};

// Change watermark position every 5 seconds 
setInterval(changeWatermarkPosition, 5000);
const watermarkStyle = `-vf drawtext=text='${email}':x=(w-text_w-10):y=(h-text_h-10):fontcolor=white:fontsize=24:shadowcolor=black:shadowx=1:shadowy=1:box=1:y=${watermarkPosition.y}:fontcolor=red:fontsize=24:shadowcolor=black:shadowx=1:shadowy=1:box=1:boxcolor=black@0.5`

ffmpeg(req.file.path)
    .addOption(watermarkStyle)
    .output(outputPathWithWatermark)
    .videoCodec('libx264')
    .audioCodec('aac')
    .size('50%')
    .on('error', (err) => {
        console.error(`FFmpeg error: ${err.message}`);
        res.status(500).json({ message: err.message });
    })
    .on('progress', (progress) => {
        // Set the watermark position every 5 seconds randomly
        changeWatermarkPosition();

        const mb = progress.targetSize / 1024;
        const data = {
            message: `Processing: ${mb.toFixed(2)} MB converted`,
            watermark: `Adding watermark to video: ${progress.framesProcessed} frames processed`
        };
        console.log(data.message);
        res.write(`data: ${JSON.stringify(data)}\n\n`);

    })
    .on('end', () => {
        console.log(`Video successfully converted to ${outputPathWithWatermark}`);
        // Remove the temporary file
    })
    .run();
 });


    


    I want to secure my video from unauthorized person by using email in a video and the email will be move around the video randomly every 5 seconds.

    


    I have read this (Add dynamic watermark that randomly changes position over video React/Node) document but didn't get any solution.

    


  • Merge commit '2edaafe5b93832715781851dfe2663da228a05ad'

    11 septembre 2018, par James Almer
    Merge commit '2edaafe5b93832715781851dfe2663da228a05ad'
    

    * commit '2edaafe5b93832715781851dfe2663da228a05ad' :
    libfdk-aacdec : Allow setting the new dynamic range control effect setting

    Merged-by : James Almer <jamrial@gmail.com>

    • [DH] libavcodec/libfdk-aacdec.c