Recherche avancée

Médias (3)

Mot : - Tags -/image

Autres articles (25)

  • Emballe médias : à quoi cela sert ?

    4 février 2011, par

    Ce plugin vise à gérer des sites de mise en ligne de documents de tous types.
    Il crée des "médias", à savoir : un "média" est un article au sens SPIP créé automatiquement lors du téléversement d’un document qu’il soit audio, vidéo, image ou textuel ; un seul document ne peut être lié à un article dit "média" ;

  • 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

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

Sur d’autres sites (5588)

  • cant find out how to make auto exit with ffmpeg in visual studio

    27 juillet 2017, par Beni Blinches

    I have a process which is a song that is playing audio from youtube using ffmpeg, and I want the song to stop when its done. I have this function

    private Process CreateStream(string path)
    {
       Program.current_s = new Process();
       Program.current_s.Exited += new EventHandler(WhenSongEnds);
       Program.current_s.StartInfo = new ProcessStartInfo
       {
           FileName = "cmd.exe",
           Arguments = $"/C youtube-dl.exe -o - {path} | ffmpeg -i pipe:0 -ac 2 -f s16le -ar 48000 pipe:1",
           UseShellExecute = false,
           RedirectStandardOutput = true,
           CreateNoWindow = true

       };
       Console.WriteLine("                     ffmpeg is ready");
       Program.current_s.Start();
       return Program.current_s;
    }

    I tried to use autoexit and ffplay. But, I cant get it right, because I’m quite unfamiliar with the software

  • Process won't stop

    14 mai 2018, par Srdjan M.

    The process goes in infinite loop or it’s waiting something and I don’t know what. It won’t pass WaitForExit methode.

    FFmpeg :

    -ss 0 -i output.mp4 -t 10 -an -y test.mp4

    C# Code :

    using (Process process = new Process())
    {
        process.StartInfo.UseShellExecute = false;
        process.StartInfo.RedirectStandardOutput = true;
        process.StartInfo.RedirectStandardError = true;
        process.StartInfo.FileName = FileName; // ffmpeg.exe
        process.StartInfo.Arguments = Arguments; //-ss 0 -i output.mp4 -t 10 -an -y test.mp4
        process.Start();
        process.WaitForExit(); // stops here and waits

        return process.StandardOutput.ReadToEnd();
    }

    Edit :

    Adding -loglevel quiet to my ffmpeg query made my problem disappear. Why ?

  • Trying to find a way to limit the number of List that can run at one time

    14 mars 2024, par Jake

    My application has a List of Tasks. Each Task launches a FFMPEG process that requires a lot of resources on my machine. At times, this list can contain 200+ processes to FFMPEG. While processing, my memory is at 99% and everything freezes up.

    


    I need to limit the amount of processes that can run at one time. I have read a little about SemaphoreSlim ; however, I cannot wrap my mind around it's implementation.

    


    Is this a solution for this particular problem and if so, any ideas on how to implement it in my code ?

    


    Below is my code :

    


    public async System.Threading.Tasks.Task GetVideoFiles()&#xA;{            &#xA;    OpenFileDialog openFileDialog = new OpenFileDialog();&#xA;    openFileDialog.Multiselect = true;&#xA;    &#xA;    if (openFileDialog.ShowDialog() == true)&#xA;    {&#xA;        AllSplices.Clear();&#xA;        AllSplices = new ObservableCollection<splicemodel>();&#xA;        IsBusy = true;&#xA;        IsBusyMessage = "Extracting Metadata";&#xA;        IsBusyBackgroundVisible = "Visible";&#xA;        NotifyPropertyChanged(nameof(IsBusy));&#xA;        NotifyPropertyChanged(nameof(IsBusyMessage));&#xA;        NotifyPropertyChanged(nameof(IsBusyBackgroundVisible));&#xA;        metaTasks = new List>();                &#xA;        extractFramesTask = new List();&#xA;        &#xA;        foreach (string file in openFileDialog.FileNames)&#xA;        {&#xA;            FileInfo fileInfo = new FileInfo(file);&#xA;            bool canAdd = true;&#xA;            var tempFileName = fileInfo.Name;&#xA;            &#xA;            foreach (var video in AllVideos)&#xA;            {&#xA;                if (file == video.VideoPath)&#xA;                {&#xA;                    canAdd = false;&#xA;                    break;&#xA;                }&#xA;&#xA;                if (video.VideoName.Contains(tempFileName))&#xA;                {&#xA;                    video.VideoName = "_" &#x2B; video.VideoName;                            &#xA;                }                        &#xA;            }&#xA;            if (canAdd)&#xA;            {                        &#xA;                metaTasks.Add(System.Threading.Tasks.Task.Run(() => ProcessMetaData(file)));                        &#xA;            }                       &#xA;        }&#xA;        var metaDataResults = await System.Threading.Tasks.Task.WhenAll(metaTasks);              &#xA;        &#xA;        foreach (var vid in metaDataResults)&#xA;        {                    &#xA;            if(vid == null)&#xA;            {&#xA;                continue;&#xA;            }&#xA;            &#xA;            vid.IsNewVideo = true;                    &#xA;            AllVideos.Add(vid);&#xA;            &#xA;            // This list of task launches up to 200 video processing processes to FFMPEG&#xA;            extractFramesTask.Add(System.Threading.Tasks.Task.Run(() => ExtractFrames(vid)));&#xA;            &#xA;            vid.IsProgressVisible = "Visible";&#xA;            TotalDuration &#x2B;= vid.VideoDuration;&#xA;            vid.NumberOfFrames = Convert.ToInt32(vid.VideoDuration.TotalSeconds * 30);&#xA;            _ = ReportProgress(vid);&#xA;        }&#xA;       &#xA;        IsBusyMessage = "Importing Frames";&#xA;        NotifyPropertyChanged(nameof(IsBusyMessage));                              &#xA;        await System.Threading.Tasks.Task.WhenAll(extractFramesTask);              &#xA;    }&#xA;</splicemodel>

    &#xA;