Recherche avancée

Médias (0)

Mot : - Tags -/configuration

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

Autres articles (85)

  • List of compatible distributions

    26 avril 2011, par

    The table below is the list of Linux distributions compatible with the automated installation script of MediaSPIP. Distribution nameVersion nameVersion number Debian Squeeze 6.x.x Debian Weezy 7.x.x Debian Jessie 8.x.x Ubuntu The Precise Pangolin 12.04 LTS Ubuntu The Trusty Tahr 14.04
    If you want to help us improve this list, you can provide us access to a machine whose distribution is not mentioned above or send the necessary fixes to add (...)

  • Encoding and processing into web-friendly formats

    13 avril 2011, par

    MediaSPIP automatically converts uploaded files to internet-compatible formats.
    Video files are encoded in MP4, Ogv and WebM (supported by HTML5) and MP4 (supported by Flash).
    Audio files are encoded in MP3 and Ogg (supported by HTML5) and MP3 (supported by Flash).
    Where possible, text is analyzed in order to retrieve the data needed for search engine detection, and then exported as a series of image files.
    All uploaded files are stored online in their original format, so you can (...)

  • Submit enhancements and plugins

    13 avril 2011

    If you have developed a new extension to add one or more useful features to MediaSPIP, let us know and its integration into the core MedisSPIP functionality will be considered.
    You can use the development discussion list to request for help with creating a plugin. As MediaSPIP is based on SPIP - or you can use the SPIP discussion list SPIP-Zone.

Sur d’autres sites (5302)

  • Anomalie #1973 (Fermé) : Supprimer la petition ne supprime pas les 3000 spams

    16 mars 2011, par cedric -
  • Revision 3000 : le règlement passe en saisies

    3 mars 2010, par kent1 — Log

    le règlement passe en saisies

  • C# FFMPEG Process and Multiple files

    23 novembre 2023, par wesman

    I am working on a C# Form tool that will help me convert all of my phone and DSLR video to HEVC, currently, i have a program that uploads the photos and videos to different directories in my home server each time i connect to the WiFi. Once a month or so, i manually convert all the videos, but thought I would automate the process.. I have the Form working perfectly for processing 1 file. but get into trouble when processing a Directory (with possible sub-directories) all at once..

    



    Sorry, this is long, just want to be thorough. here is the button calls

    



    private void processFile_Click(object sender, EventArgs e)
    {
        OpenFileDialog file = new OpenFileDialog();
        file.InitialDirectory = baseMediaDirectory;
        if (file.ShowDialog() == DialogResult.OK)
        {
            ProcessSinlgeFile(file.FileName);
        }
    }


    



    (above)for one file and (below) for a directory

    



    private void processDirectory_Click(object sender, EventArgs e)&#xA;{&#xA;    FolderBrowserDialog file = new FolderBrowserDialog();&#xA;    file.SelectedPath = baseMediaDirectory;&#xA;    if(file.ShowDialog() == DialogResult.OK)&#xA;    {&#xA;       ProcessDirectoryOfFiles(file.SelectedPath);&#xA;    }&#xA;}&#xA;&#xA;private void ProcessDirectoryOfFiles(string selectedPath)&#xA;    {&#xA;        List<string> listOfFiles = GetAllFiles(selectedPath);&#xA;        foreach (string s in listOfFiles)&#xA;        {&#xA;            ProcessSinlgeFile(s);&#xA;        }&#xA;    }&#xA;</string>

    &#xA;&#xA;

    both ultimately call this method, to do some checks and setup

    &#xA;&#xA;

    private void ProcessSinlgeFile(string fileName)&#xA;    {&#xA;&#xA;        if (IsAcceptableMediaFile(fileName))&#xA;        {&#xA;            outputWindow.AppendText("File to Process: " &#x2B; fileName);&#xA;            processMediaFile = &#xA;                new MediaFileWrapper(this.outputWindow, new MediaFile(fileName), new NReco.VideoInfo.FFProbe());&#xA;            if (processMediaFile.OkToProcess)&#xA;            {&#xA;                int initialCRFValue = 15;&#xA;                //ultrafast superfast veryfast faster fast medium slow slower veryslow placebo&#xA;                string intialSpeed = "veryfast";&#xA;                try {&#xA;&#xA;                    ConvertToMPEG(processMediaFile.getFFMPEGCommand(initialCRFValue, intialSpeed), processMediaFile);&#xA;                }&#xA;                catch&#xA;                {&#xA;                    // at somepoint, we&#x27;ll catch a bad file size (or compression)&#xA;                    // then change the CRF value and/or compression speed&#xA;                }&#xA;            }&#xA;        }&#xA;    }&#xA;

    &#xA;&#xA;

    ultimately I get to this Method and run into trouble.

    &#xA;&#xA;

        private async void ConvertToMPEG(string arguments, MediaFileWrapper processMediaFile)&#xA;    {&#xA;        startTime = DateTime.Now;&#xA;        watch = new Stopwatch();&#xA;        watch.Start();&#xA;        progressBar1.Minimum = 0;&#xA;        progressBar1.Maximum = processMediaFile.GetTotalMilliseconds();&#xA;&#xA;        // Start the child process.&#xA;        p = new Process();&#xA;&#xA;        //Setup filename and arguments&#xA;        outputWindow.AppendText("ffmpeg " &#x2B; arguments);&#xA;        p.StartInfo.Arguments = arguments;&#xA;        p.StartInfo.FileName = "ffmpeg.exe";&#xA;        p.StartInfo.UseShellExecute = false;&#xA;&#xA;        // Redirect the output stream of the child process.&#xA;        p.StartInfo.RedirectStandardOutput = true;&#xA;        p.StartInfo.RedirectStandardError = true;&#xA;        p.StartInfo.RedirectStandardInput = true;&#xA;&#xA;        // capture the date for stdout and std error&#xA;        // note FFMPEG uses Stderr exclusively&#xA;        p.ErrorDataReceived &#x2B;= new DataReceivedEventHandler(ErrorDataReceived);&#xA;        p.OutputDataReceived &#x2B;= new DataReceivedEventHandler(OutputDataReceived);&#xA;&#xA;        // Hide Console Window&#xA;        p.StartInfo.CreateNoWindow = true;&#xA;        p.StartInfo.WindowStyle = ProcessWindowStyle.Hidden;&#xA;&#xA;        p.Start();&#xA;        p.BeginErrorReadLine();&#xA;        p.BeginOutputReadLine();&#xA;        await p.WaitForExitAsync();&#xA;    }&#xA;

    &#xA;&#xA;

    and WaitForExitAsync is in another class because in can not be in here with a Form

    &#xA;&#xA;

        public static Task WaitForExitAsync(this Process process,&#xA;        CancellationToken cancellationToken = default(CancellationToken))&#xA;    {&#xA;        var tcs = new TaskCompletionSource();&#xA;        process.EnableRaisingEvents = true;&#xA;        process.Exited &#x2B;= (sender, args) => tcs.TrySetResult(null);&#xA;        if (cancellationToken != default(CancellationToken))&#xA;            cancellationToken.Register(tcs.SetCanceled);&#xA;&#xA;        return tcs.Task;&#xA;    }&#xA;

    &#xA;&#xA;

    however, single files work fine, when I call a directory through, it continuously starts processes for each file, trying to run them all at the same time. You can see I tried implementing this &#xA;process.WaitForExit() asynchronously&#xA;with no luck.

    &#xA;