Recherche avancée

Médias (1)

Mot : - Tags -/university

Autres articles (55)

  • 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

  • Supporting all media types

    13 avril 2011, par

    Unlike most software and media-sharing platforms, MediaSPIP aims to manage as many different media types as possible. The following are just a few examples from an ever-expanding list of supported formats : images : png, gif, jpg, bmp and more audio : MP3, Ogg, Wav and more video : AVI, MP4, OGV, mpg, mov, wmv and more text, code and other data : OpenOffice, Microsoft Office (Word, PowerPoint, Excel), web (html, CSS), LaTeX, Google Earth and (...)

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

Sur d’autres sites (7341)

  • Working with ffmpeg in Xamarin Android

    8 janvier 2018, par Ahmed Mujtaba

    I’m building an android app using Xamarin. The requirement of the app is to capture video from the camera and encode the video to send it across to a server. Initially I was using an encoder library on the server side to encode recorded video but it was proving to be extremely unreliable and inefficient specially for large sized video files. I have posted my issues on another thread here I then decided to encode the video on the client side and then send it to the server. I’ve found encoding to be a bit complicated and there isn’t much information available on how this can be done so I search for the only way I knew how to encode a video that is by using ffmpeg codec. I’ve found some solutions. There’s a project on github that demonstrates how ffmpeg is used inside a Xamarin android project. However running the solution doesn’t give any output. The project has a binary ffmpeg file which is installed to the phone directory using the code below :

    _ffmpegBin = InstallBinary(XamarinAndroidFFmpeg.Resource.Raw.ffmpeg, "ffmpeg", false);

    Below is the example code for encoding video into different set of outputs :

               _workingDirectory = Android.OS.Environment.ExternalStorageDirectory.AbsolutePath;
           var sourceMp4 = "cat1.mp4";
           var destinationPathAndFilename = System.IO.Path.Combine (_workingDirectory, "cat1_out.mp4");
           var destinationPathAndFilename2 = System.IO.Path.Combine (_workingDirectory, "cat1_out2.mp4");
           var destinationPathAndFilename4 = System.IO.Path.Combine (_workingDirectory, "cat1_out4.wav");
           if (File.Exists (destinationPathAndFilename))
               File.Delete (destinationPathAndFilename);
           CreateSampleFile(Resource.Raw.cat1, _workingDirectory, sourceMp4);


           var ffmpeg = new FFMpeg (this, _workingDirectory);

           var sourceClip = new Clip (System.IO.Path.Combine(_workingDirectory, sourceMp4));

           var result = ffmpeg.GetInfo (sourceClip);

           var br = System.Environment.NewLine;

           // There are callbacks based on Standard Output and Standard Error when ffmpeg binary is running as a process:

           var onComplete = new MyCommand ((_) => {
               RunOnUiThread(() =>_logView.Append("DONE!" + br + br));
           });

           var onMessage = new MyCommand ((message) => {
               RunOnUiThread(() =>_logView.Append(message + br + br));
           });

           var callbacks = new FFMpegCallbacks (onComplete, onMessage);

           // 1. The idea of this first test is to show that video editing is possible via FFmpeg:
           // It results in a 150x150 movie that eventually zooms on a cat ear. This is desaturated, and there's a fade in.

           var filters = new List<videofilter> ();
           filters.Add (new FadeVideoFilter ("in", 0, 100));
           filters.Add(new CropVideoFilter("150","150","0","0"));
           filters.Add(new ColorVideoFilter(1.0m, 1.0m, 0.0m, 0.5m, 1.0m, 1.0m, 1.0m, 1.0m));
           var outputClip = new Clip (destinationPathAndFilename) { videoFilter = VideoFilter.Build (filters)  };
           outputClip.H264_CRF = "18"; // It's the quality coefficient for H264 - Default is 28. I think 18 is pretty good.
           ffmpeg.ProcessVideo(sourceClip, outputClip, true, new FFMpegCallbacks(onComplete, onMessage));

           //2. This is a similar version version in command line only:
           string[] cmds = new string[] {
               "-y",
               "-i",
               sourceClip.path,
               "-strict",
               "-2",
               "-vf",
               "mp=eq2=1:1.68:0.3:1.25:1:0.96:1",
               destinationPathAndFilename2,
               "-acodec",
               "copy",
           };
           ffmpeg.Execute (cmds, callbacks);

           // 3. This lists codecs:
           string[] cmds3 = new string[] {
               "-codecs",
           };
           ffmpeg.Execute (cmds, callbacks);

           // 4. This convers to WAV
           // Note that the cat movie just has some silent house noise.
           ffmpeg.ConvertToWaveAudio(sourceClip, destinationPathAndFilename4, 44100, 2, callbacks, true);
    </videofilter>

    I have tried different commands but no output file is generated. I have tried to use another project found here but this one has the same issue. I don’t get any errors but no output file is generated. I’m really hoping someone can help me find a way I can manage to use ffmpeg in my project or some way to compress video to transport it to the server.

    I will really appreciate if someone can point me to the right direction.

  • How to Merge two videos without re-encoding [duplicate]

    2 février, par Yogesh Agarwal

    I am trying to Merge two video without re-encoding them.

    &#xA;&#xA;

    Currently i use a approach which is too much time consuming and resource as well. I just want to merge without re-encoding them. Currently i am using

    &#xA;&#xA;

            exec ( "cpulimit -l 90 ffmpeg -i $filename1 -qscale 0  $intermediate1 &amp;> stream1.log" );&#xA;        exec ( "cpulimit -l 90 ffmpeg -i $filename2 -qscale 0  $intermediate2 &amp;> stream2.log" );&#xA;        $output = &#x27;/var/www/html/myserver/merg/&#x27;.uniqid().&#x27;_merge.&#x27;.$ext;&#xA;        exec ( "cpulimit -l 90 cat $intermediate1 $intermediate2 | ffmpeg -i - -qscale 0 $output &amp;> stream3.log" );&#xA;

    &#xA;&#xA;

    Above takes a lot of time.. I want a quick way to do it.

    &#xA;

  • OpenCV VideoCapture closes with videos from GoPro

    10 février 2021, par Michael

    I have a videofile from a GoPro device and I simply work with it from a VideoCapture like this :

    &#xA;&#xA;

    cap = cv2.VideoCapture(path)&#xA;        index = 0&#xA;        start = time.time()&#xA;&#xA;        while cap.isOpened():&#xA;            ret, frame = cap.read()&#xA;            if not ret:&#xA;                break&#xA;            # do something here&#xA;        end = time.time()&#xA;

    &#xA;&#xA;

    It is very weird, but I can operate with any files except ones, captured at the GoPro. Stream just closes at some point because ret value becomes False and frame becomes None. No exceptions or anything else.

    &#xA;&#xA;

    Googling helped me to find this question. I have deleted audio streams from file with ffmpeg tool and then everything works just fine. So why it is like so ? Pleas help !

    &#xA;&#xA;

    I am using Python 3.6.4 x64, Windows 10 (however at Linux same) and precompiled binaries for OpenCV from this resource.

    &#xA;