Recherche avancée

Médias (0)

Mot : - Tags -/navigation

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

Autres articles (61)

  • Personnaliser en ajoutant son logo, sa bannière ou son image de fond

    5 septembre 2013, par

    Certains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;

  • Mise à jour de la version 0.1 vers 0.2

    24 juin 2013, par

    Explications des différents changements notables lors du passage de la version 0.1 de MediaSPIP à la version 0.3. Quelles sont les nouveautés
    Au niveau des dépendances logicielles Utilisation des dernières versions de FFMpeg (>= v1.2.1) ; Installation des dépendances pour Smush ; Installation de MediaInfo et FFprobe pour la récupération des métadonnées ; On n’utilise plus ffmpeg2theora ; On n’installe plus flvtool2 au profit de flvtool++ ; On n’installe plus ffmpeg-php qui n’est plus maintenu au (...)

  • Soumettre améliorations et plugins supplémentaires

    10 avril 2011

    Si vous avez développé une nouvelle extension permettant d’ajouter une ou plusieurs fonctionnalités utiles à MediaSPIP, faites le nous savoir et son intégration dans la distribution officielle sera envisagée.
    Vous pouvez utiliser la liste de discussion de développement afin de le faire savoir ou demander de l’aide quant à la réalisation de ce plugin. MediaSPIP étant basé sur SPIP, il est également possible d’utiliser le liste de discussion SPIP-zone de SPIP pour (...)

Sur d’autres sites (11431)

  • C# Process in loop reading error output, causes "No async read operation is in progress on the stream" error

    29 mai 2023, par TSLee

    I am trying to read the format of multiple video files using ffmpeg in an asynchronous operation of Process and facing an error, "No async read operation is in progress on the stream". According to https://social.msdn.microsoft.com/Forums/vstudio/en-US/c961f461-7afb-4a92-b0ae-f78c2003b5de/help-an-asynchronous-read-operation-is-already-in-progress-on-the-standardoutput-stream?forum=csharpgeneral, I think I have to use CancelErrorRead(), as BeginErrorReadLine() can't be launched more than once. I also wonder if I use this function in the wrong place, because the read operation has ended in process1.exited() ? But the operation can't proceed to the second index with this error.

    


    How could I use CancelErrorRead()/CancelOutputRead() properly and where should I place them on the code ? I also did an experiment in that I commented these two CancelRead(), and a different error "async read operation has been started on the stream" will appear.

    


                Process process1 = new Process();
            process1.StartInfo.WindowStyle = ProcessWindowStyle.Hidden;
            process1.StartInfo.CreateNoWindow = true;
            process1.StartInfo.UseShellExecute = false;
            process1.StartInfo.FileName = ".\\ffmpeg.exe";
            process1.StartInfo.WorkingDirectory = ".\\";
            process1.EnableRaisingEvents = true;
            process1.StartInfo.RedirectStandardOutput = true; //if this is true, UseShellExecute must be false. true if output should be written to StandardOutput
            process1.StartInfo.RedirectStandardError = true;
            //indicates that the associated Process has written a line that's terminated with a newline
            process1.ErrorDataReceived += new DataReceivedEventHandler(inputHandler);
            process1.Exited += (ending, p) =>
            {
                flag = true;
                process1.CancelOutputRead();
                process1.CancelErrorRead();//
            };
            foreach (String file in inputList)
            {
                if (flag == true)
                {
                    flag = false;
                    process1.StartInfo.Arguments = "-i " + " \"" + file + "\"";
                    Console.WriteLine(process1.StartInfo.Arguments);
                    process1.Start();
                    process1.BeginOutputReadLine();//
                    process1.BeginErrorReadLine();
                    process1.WaitForExit(); //for asynchronous output
                }


            }
        }
        private void inputHandler(object sender, DataReceivedEventArgs l)
        {
             cba.Append(l.Data + "\n");
             videoInput = l.Data;
             //Console.WriteLine(cba);
             //Process p = sender as Process;
             Console.WriteLine(videoInput);

             this.BeginInvoke(new MethodInvoker(() =>
             {

              if (!String.IsNullOrEmpty(videoInput))
              {
                    if (videoInput.Contains("Stream #0:0"))
                    {
                        String subvideoInput1 = 
                        videoInput.Substring(videoInput.IndexOf("Stream #0:0"));
                        String video_inputType = subvideoInput1;
                        textBox1.Text += video_inputType + System.Environment.NewLine;
                        Console.WriteLine(video_inputType);
                     }
                     if (videoInput.Contains("Stream #0:1"))
                     {
                         String subvideoInput2 = 
                         videoInput.Substring(videoInput.IndexOf("Stream #0:1"));
                         Console.WriteLine(subvideoInput2.IndexOf("\n"));
                         Console.WriteLine(subvideoInput2);
                         String audio_inputType = subvideoInput2;
                         textBox1.AppendText(audio_inputType + System.Environment.NewLine);
                         Console.WriteLine(audio_inputType);
                     }
                     if (videoInput.Contains("Duration:"))
                     {
                         String videoinputDuration = 
                         videoInput.Substring(videoInput.IndexOf("Duration:"));
                         String subvideo_inputDuration = videoinputDuration.Substring(9);
                         String inputvideoDuration = 
                     subvideo_inputDuration.Remove(subvideo_inputDuration.IndexOf("."));
                         Console.WriteLine(inputvideoDuration);
                         double totalseconds = 
                         TimeSpan.Parse(inputvideoDuration).TotalSeconds;
                    
                    

                }
            }

        }));


    }


    


  • The error "Failed to query nvenc max version" typically occurs when using FFmpeg on Linux

    28 juillet 2023, par Well Chen

    The error "Failed to query nvenc max version" typically occurs when using FFmpeg with NVIDIA GPU acceleration (hevc_nvenc) on Linux.

    


    Does anyone know how to solve this bug ? Thank you very much.

    


    The following code is the FFmpeg code I entered, along with the output content.

    


    ffmpeg -ss 10:00 -i /www/wwwroot/pyffmpeg/videos/0/011.mp4 -t 20 -r 30 -b:v 4M -an -vcodec hevc_nvenc -y /www/wwwroot/pyffmpeg/videos/post/999.mp4
ffmpeg version 6.0 Copyright (c) 2000-2023 the FFmpeg developers
  built with gcc 8 (GCC)
  configuration: --extra-cflags='-I/usr/local/cuda/include -fPIC ' --extra-ldflags='-L/usr/local/cuda/lib64 -ldl ' --pkg-config-flags=--static --enable-shared --enable-gpl --enable-cuvid --enable-nvenc --enable-nonfree --nvcc='nvcc=/usr/local/cuda-12.2/bin/nvcc'
  WARNING: library configuration mismatch
  avutil      configuration: --extra-cflags='-I/usr/local/cuda-12.2/include -fPIC ' --extra-ldflags='-L/usr/local/cuda-12.2/lib64 -ldl ' --pkg-config-flags=--static --enable-shared --enable-gpl --enable-libfreetype --enable-cuvid --enable-nvenc --enable-nonfree --nvcc=/usr/local/cuda-12.2/bin/nvcc --prefix=/usr/local/ffmpeg
  avcodec     configuration: --extra-cflags='-I/usr/local/cuda-12.2/include -fPIC ' --extra-ldflags='-L/usr/local/cuda-12.2/lib64 -ldl ' --pkg-config-flags=--static --enable-shared --enable-gpl --enable-libfreetype --enable-cuvid --enable-nvenc --enable-nonfree --nvcc=/usr/local/cuda-12.2/bin/nvcc --prefix=/usr/local/ffmpeg
  avformat    configuration: --extra-cflags='-I/usr/local/cuda-12.2/include -fPIC ' --extra-ldflags='-L/usr/local/cuda-12.2/lib64 -ldl ' --pkg-config-flags=--static --enable-shared --enable-gpl --enable-libfreetype --enable-cuvid --enable-nvenc --enable-nonfree --nvcc=/usr/local/cuda-12.2/bin/nvcc --prefix=/usr/local/ffmpeg
  avdevice    configuration: --extra-cflags='-I/usr/local/cuda-12.2/include -fPIC ' --extra-ldflags='-L/usr/local/cuda-12.2/lib64 -ldl ' --pkg-config-flags=--static --enable-shared --enable-gpl --enable-libfreetype --enable-cuvid --enable-nvenc --enable-nonfree --nvcc=/usr/local/cuda-12.2/bin/nvcc --prefix=/usr/local/ffmpeg
  avfilter    configuration: --extra-cflags='-I/usr/local/cuda-12.2/include -fPIC ' --extra-ldflags='-L/usr/local/cuda-12.2/lib64 -ldl ' --pkg-config-flags=--static --enable-shared --enable-gpl --enable-libfreetype --enable-cuvid --enable-nvenc --enable-nonfree --nvcc=/usr/local/cuda-12.2/bin/nvcc --prefix=/usr/local/ffmpeg
  swscale     configuration: --extra-cflags='-I/usr/local/cuda-12.2/include -fPIC ' --extra-ldflags='-L/usr/local/cuda-12.2/lib64 -ldl ' --pkg-config-flags=--static --enable-shared --enable-gpl --enable-libfreetype --enable-cuvid --enable-nvenc --enable-nonfree --nvcc=/usr/local/cuda-12.2/bin/nvcc --prefix=/usr/local/ffmpeg
  swresample  configuration: --extra-cflags='-I/usr/local/cuda-12.2/include -fPIC ' --extra-ldflags='-L/usr/local/cuda-12.2/lib64 -ldl ' --pkg-config-flags=--static --enable-shared --enable-gpl --enable-libfreetype --enable-cuvid --enable-nvenc --enable-nonfree --nvcc=/usr/local/cuda-12.2/bin/nvcc --prefix=/usr/local/ffmpeg
  postproc    configuration: --extra-cflags='-I/usr/local/cuda-12.2/include -fPIC ' --extra-ldflags='-L/usr/local/cuda-12.2/lib64 -ldl ' --pkg-config-flags=--static --enable-shared --enable-gpl --enable-libfreetype --enable-cuvid --enable-nvenc --enable-nonfree --nvcc=/usr/local/cuda-12.2/bin/nvcc --prefix=/usr/local/ffmpeg
  libavutil      58.  2.100 / 58.  2.100
  libavcodec     60.  3.100 / 60.  3.100
  libavformat    60.  3.100 / 60.  3.100
  libavdevice    60.  1.100 / 60.  1.100
  libavfilter     9.  3.100 /  9.  3.100
  libswscale      7.  1.100 /  7.  1.100
  libswresample   4. 10.100 /  4. 10.100
  libpostproc    57.  1.100 / 57.  1.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/www/wwwroot/pyffmpeg/videos/0/011.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf59.6.100
  Duration: 00:17:48.83, start: 0.000000, bitrate: 4617 kb/s
  Stream #0:0[0x1](und): Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, smpte170m/bt470bg/bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], 4481 kb/s, 30 fps, 30 tbr, 15360 tbn (default)
    Metadata:
      handler_name    : ISO Media file produced by Google Inc.
      vendor_id       : [0][0][0][0]
  Stream #0:1[0x2](und): Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 127 kb/s (default)
    Metadata:
      handler_name    : ISO Media file produced by Google Inc.
      vendor_id       : [0][0][0][0]
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> hevc (hevc_nvenc))
Press [q] to stop, [?] for help
[hevc_nvenc @ 0x2a577790] Failed to query nvenc max version: unknown error (-756041696): (no details)
Segmentation faul


    


    I have installed FFmpeg, NVIDIA GPU drivers, and SDK. It works fine without using GPU acceleration, but it throws an error when using GPU acceleration.

    


  • Fluent FFmpeg Thumbnail Extraction Error : "muxing overhead : unknown, conversion failed"

    21 août 2024, par Abdul Hannan Mahmood

    I'm trying to extract a thumbnail from a video using Fluent FFmpeg, but I'm encountering the error "muxing overhead : unknown, conversion failed." Despite this error, the thumbnail is being generated correctly.

    


    Here's my code :

    


    const screenshotPath = resolve(`${output}/${videoId}_thumbnail.png`);
ffmpeg(inputUrl)
  .screenshots({
    timestamps: [timestamp],
    filename: screenshotPath,
    size: '640x360'
  })
  .output(screenshotPath)
  .on('error', (err) => {
    log.error(`VideoId:${videoId} -> Error while extracting screenshot`, err);
  });


    


    I've already verified the following :

    


      

    • Input file integrity : The input video file is not corrupted.
    • 


    • Supported formats : The video format is compatible with Fluent FFmpeg.
    • 


    • System resources : My system has sufficient resources for the conversion.
    • 


    • Conversion tool : I'm using the latest version of Fluent FFmpeg.
    • 


    


    Despite these checks, the error persists. I'm wondering if this is a known issue or if there's something else I might be missing.