Recherche avancée

Médias (0)

Mot : - Tags -/latitude

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (51)

  • 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

  • Contribute to a better visual interface

    13 avril 2011

    MediaSPIP is based on a system of themes and templates. Templates define the placement of information on the page, and can be adapted to a wide range of uses. Themes define the overall graphic appearance of the site.
    Anyone can submit a new graphic theme or template and make it available to the MediaSPIP community.

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

Sur d’autres sites (6345)

  • Opencv cv2.VideoCapture('file.avi') shows first frame then throws exception

    3 novembre 2014, par holografix

    I’m trying to read a .avi included in the OpenCV original package, it’s called 768x576.avi and shows a few people walking around a street.

    The code below shows what seems to be the 1st frame and runs for a few seconds before returning an Exception.

    import cv2
    cap = cv2.VideoCapture('768x576.avi')
    cap.isOpened() # returns True
    cap.get(3); cap.get(4) # returns 768 and 576

    while (True):
       ret, frame = cap.read()
       cv2.imshow('frame', frame)

    Hands me this error after a few secs on the cv2.imshow line, I think it means the returned frame had no data associated it in.

    error: /tmp/opencv-7y6HHt/opencv-2.4.9/modules/highgui/src/window.cpp:261: error: (-215) size.width>0 && size.height>0 in function imshow

    I have no idea why this is happening, I’m running Yosemite, brew installed Python, OpenCv and Ffmpeg.

    opencv: stable 2.4.9, HEAD
    http://opencv.org/
    /usr/local/Cellar/opencv/2.4.9 (219 files, 38M) *

    ffmpeg: stable 2.4.2 (bottled), HEAD
    https://ffmpeg.org/
    /usr/local/Cellar/ffmpeg/2.4.2 (199 files, 40M) *
     Poured from bottle
    From: https://github.com/Homebrew/homebrew/blob/master/Library/Formula/ffmpeg.rb
    ==> Dependencies
    Build: pkg-config ✔, texi2html ✘, yasm ✘
    Recommended: x264 ✔, faac ✔, lame ✔, xvid ✔
  • failed to set frame number in opencv in cpp

    28 février 2018, par Madhu Nadendla

    I am trying to set frame position of opened videofile using OpenCV in C++ but it returns 0.

    solution 1

    bool success = capture.set(CV_CAP_PROP_POS_FRAMES, noFrame);

    double frameRate = capture.get(CV_CAP_PROP_FPS);
  • Ffmpeg output stream closed

    29 novembre 2023, par excalibur

    There is one problem in my code that uses ffmpeg to convert webm videos to mp4 and set duration to 10 seconds, it works well but, sometimes returns "output Stream closed" error. What can be a reason of this problem, and how can i solve it ?

    


    My code :

    


    async convertWebmVideoToMp4(buffer: any) {
    try {
        return new Promise((resolve, reject) => {
            const videoMp4Buffer = Buffer.from(buffer);

            const readable = Readable.from(videoMp4Buffer);

            const outputBuffer = [];

            const outputStream = new Writable({
                write(chunk, encoding, callback) {
                    outputBuffer.push(chunk);
                    callback();
                },
            });

            const ffmpegProcess = ffmpeg()
                .input(readable)
                .outputFormat('mp4')
                .videoCodec('libx264')
                .audioCodec('aac')
                .duration(10)
                .outputOptions([
                    '-movflags frag_keyframe+empty_moov',
                    '-preset ultrafast',
                    '-c:a aac',
                    '-r 30',
                    '-tune fastdecode',
                ])
                .on('end', () => {
                    outputStream.end();
                    const finalOutputBuffer = Buffer.concat(outputBuffer);
                    resolve(finalOutputBuffer);
                })
                .on('error', (err, stdout, stderr) => {
                    console.error(err);
                    reject(err);
                });

            outputStream.on('error', err => {
                this.logger.error(err);
            });

            ffmpegProcess.pipe(outputStream, { end: true });
        });
    } catch (error) {
        throw error;
    }
}


    


    My code should return the buffer of video that type is mp4 and length is 10 seconds, but it returns "output stream closed" error.