Recherche avancée

Médias (1)

Mot : - Tags -/blender

Autres articles (76)

  • (Dés)Activation de fonctionnalités (plugins)

    18 février 2011, par

    Pour gérer l’ajout et la suppression de fonctionnalités supplémentaires (ou plugins), MediaSPIP utilise à partir de la version 0.2 SVP.
    SVP permet l’activation facile de plugins depuis l’espace de configuration de MediaSPIP.
    Pour y accéder, il suffit de se rendre dans l’espace de configuration puis de se rendre sur la page "Gestion des plugins".
    MediaSPIP est fourni par défaut avec l’ensemble des plugins dits "compatibles", ils ont été testés et intégrés afin de fonctionner parfaitement avec chaque (...)

  • Les tâches Cron régulières de la ferme

    1er décembre 2010, par

    La gestion de la ferme passe par l’exécution à intervalle régulier de plusieurs tâches répétitives dites Cron.
    Le super Cron (gestion_mutu_super_cron)
    Cette tâche, planifiée chaque minute, a pour simple effet d’appeler le Cron de l’ensemble des instances de la mutualisation régulièrement. Couplée avec un Cron système sur le site central de la mutualisation, cela permet de simplement générer des visites régulières sur les différents sites et éviter que les tâches des sites peu visités soient trop (...)

  • Participer à sa documentation

    10 avril 2011

    La documentation est un des travaux les plus importants et les plus contraignants lors de la réalisation d’un outil technique.
    Tout apport extérieur à ce sujet est primordial : la critique de l’existant ; la participation à la rédaction d’articles orientés : utilisateur (administrateur de MediaSPIP ou simplement producteur de contenu) ; développeur ; la création de screencasts d’explication ; la traduction de la documentation dans une nouvelle langue ;
    Pour ce faire, vous pouvez vous inscrire sur (...)

Sur d’autres sites (11263)

  • FFMPEG not saving logs when converting to audio format

    2 février, par PUXIII

    The command does not save or even create a file :

    


    ffmpeg -i "video.mp4" -f mp3 "audio.mp3" -vstats_file "log_file.log"


    


    And if you convert to a video file, everything normally creates and writes :

    


    ffmpeg -i "video.mp4" -f mp3 "video.avi" -vstats_file "log_file.log"


    


    Goal : to pull out the time from the log file and bind it to the process bar.

    


    There are no problems with video, everything works. But with the sound does not work.

    


    I tried the command :

    


    ffmpeg -i "video.mp4" -f mp3 "video.avi" >2 "log_file.txt"


    


    But there are other problems popping out. Since I run it all from the Python using the subprocess module.

    


    ffmpegProc = subprocess.Popen(ffmpegCommand, startupinfo=startupinfo, shell=True)


    


    , I can not kill the running process, because it is started with the attribute shell=True, and only the shell is killed.

    


  • Kill child process only after readFile() Node js Electron

    14 mai 2021, par Radespy

    I'm using an imported ffmpeg binary ffmpeg-static-electronin an Electron-React app (on Windows Pro 10) and want to delete a saved cropped video and then kill the child process afterwards from my Main process.

    


    The overall aim is to crop a video of the whole screen following capture and then send the cropped video to a renderer.

    


    const fsPromises = require('fs').promises
const ffmpeg = require('ffmpeg-static-electron')
const { execFile } = require("child_process")


ipcMain.on("windoze_capture_screen:video_buffer", async (event, buffer) => {
    const temp_directory =  await fsPromises.mkdtemp(await fsPromises.realpath(os.tmpdir()) + path.sep)
    const capture_screen_video_path = path.join(temp_directory, "screen_capture_video.mp4")

    child_object = execFile(`${ffmpeg.path}`, 

            ['-i', `${capture_screen_video_path}`, '-vf', `crop=${width}:${height}:${x_pos}:${y_pos}`, `${path.join(temp_directory,'cropped_video.mp4')}`])
            
    child_object.on("exit", async () => {

        // child_object.kill()
        console.log("?Killed -1", child_object.killed)
        
        try { 
            databasePayload.video_buffer = await fsPromises.readFile(path.join(temp_directory, "cropped_video.mp4"), {encoding: 'base64'})
            mainWindow.webContents.send("main_process:video_buffer", databasePayload.video_buffer)
        } catch (error) {
            console.log(error)
        } finally {

            // child_object.kill()
            console.log("?Killed - 2", child_object.killed)
            
            // noASAR required to be set to 'true' in order to remove temp directory in build
            process.noAsar = true 
            fs.rmdir(temp_directory, {recursive: true}, (error) => {if (error) {log(error)}})
            process.noASAR = false
            }

            // 3rd scenario
            // child_object.kill()
            console.log("?Killed -3", child_object.killed)   
        })

        // 4th scenario
        console.log("?Killed-4", child_object.killed)   
    })



    


    When running each of these scenarios, I get the following outputs.

    


    Scenario's 1, 2 and 3 - Successfully sends cropped video to renderer but doesn't kill process.

    


    Output :

    


    ?Killed-4 false
?Killed -1 false
[ffmpeg version 3.0.1 Copyright (c) 2000-2016 the FFmpeg developers built with gcc 5.3.0 (GCC).... etc. ]
?Killed-2 false
?Killed -3 false


    


    Scenario 4 - Doesn't crop video

    


    ?Killed-4 true
?Killed -1 true
Command failed: C:\Users\XXX\Desktop\windows-electron-forge\node_modules\ffmpeg-static-electron\bin\win\x64\ffmpeg.exe -i C:\Users\XXX\AppData\Local\Temp\4WgnUw\screen_capture_video.mp4 -vf crop=796:763:462:509 C:\Users\XXX\AppData\Local\Temp\4WgnUw\cropped_video.mp4

[Error: ENOENT: no such file or directory, open 'C:\Users\XXX\AppData\Local\Temp\4WgnUw\cropped_video.mp4'] {
errno: -4058,
code: 'ENOENT',
syscall: 'open',
path: 'C:\\Users\\XXX\\AppData\\Local\\Temp\\4WgnUw\\cropped_video.mp4'
}
?Killed - 2 true
?Killed -3 true


    


    The last scenario has been tried out of desperation.

    


    Question : Where am I going wrong with this ? I suspect it's something to do with ipc between child and parent process but not sure where to place the code.

    


    Any help will be much appreciated !!!

    


  • ffmpeg video conversion problems ?

    22 septembre 2018, par Surya sasidhar

    I am using ffmpeg for video conversion, it is working fine in local.
    But when I upload the site in online it is not converting the videos. It is showing operation failed should I install the ffmpeg in server also.

    public void convertFile()

    {

       lblStatus.Visible = false;
       try
       {

           int i = sFile.LastIndexOf(".");
           thumb = sFile.Remove(i);
           thumb = thumb + ".jpg";
           video = Page.MapPath("../VideoOut/" + sFile);
           Image = Page.MapPath("../VideoSnapShots/" + thumb);
           ffmpeg = new Process();
           ffmpeg.StartInfo.Arguments = " -i \"" + video + "\"    -vframes 1 -ss 00:00:10 -s 150x150 -f image2 -vcodec mjpeg \"" + Image + "\""; // arguments !
           ffmpeg.StartInfo.FileName = Page.MapPath("FFMPEG\\ffmpeg.exe");
           ffmpeg.Start();
           Session["image"] = thumb;
           string mpg;
           string VideoOut;
           int j = sFile.LastIndexOf(".");
           mpg = sFile.Remove(j);
           mpg = mpg + ".flv";
           video = Page.MapPath("../VideoOut/" + sFile);
           VideoOut = Page.MapPath("../Videos/" + mpg);
           ffmpeg.EnableRaisingEvents = true;

           ffmpeg.StartInfo.Arguments = " -i \"" + video + "\" -ar 22050 \"" + VideoOut + "\"";
           ffmpeg.StartInfo.FileName = Page.MapPath("FFMPEG\\ffmpeg.exe");
           ffmpeg.Start();
           ffmpeg.StartInfo.UseShellExecute = false;
           ffmpeg.StartInfo.CreateNoWindow = false;
           ffmpeg.StartInfo.RedirectStandardError = true;
           ffmpeg.StartInfo.RedirectStandardOutput = false;
           ffmpeg.WaitForExit();
           ffmpeg.Close();
           Session["videosrc"] = mpg;

           InsertVideo();
           File.Delete(video);

       }
       catch (Exception ex)
       {
           lblStatus.Visible = true;
           lblStatus.Text = ex.Message;
       }

    }