Recherche avancée

Médias (91)

Autres articles (68)

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

  • Des sites réalisés avec MediaSPIP

    2 mai 2011, par

    Cette page présente quelques-uns des sites fonctionnant sous MediaSPIP.
    Vous pouvez bien entendu ajouter le votre grâce au formulaire en bas de page.

  • Les autorisations surchargées par les plugins

    27 avril 2010, par

    Mediaspip core
    autoriser_auteur_modifier() afin que les visiteurs soient capables de modifier leurs informations sur la page d’auteurs

Sur d’autres sites (9531)

  • Record Sound on Ubuntu Docker Image

    12 avril 2017, par Daniel Rasmuson

    I would like record audio with ffmpeg when I capture my screen. The error I’m getting when using alsa is that is that my image does not have a sound card -f alsa -ac 2 -i hw:0

    Here is how to reproduce on a fresh version of Ubuntu

    Start a session in a new ubuntu docker image.

    docker pull ubuntu
    docker run -it --rm ubuntu

    Setup alsa (Advanced Linux Sound Architecture)

    apt-get update
    apt-get install alsa-utils

    List the sound cards

    aplay -l
    # aplay: device_list:268: no soundcards found...

    And playing this sound will fail because this image doesn’t have any sound cards

    sudo aplay /usr/share/sounds/alsa/Front_Center.wav
  • How to record live streamed video from rtsp url in android

    22 mars 2017, par Astro

    I am doing an android application. In my application I need to record live streamed video.And here I am using rtsp protocol and ffmpeg library to stream and record video.Live streaming is working properly, but video recording is not working. I think it’s a problem of URL Connection I am used here to record video.But I don’t know what is the correct connection method.I search lot about this, but can’t find anything. If anybody know this please help me.

    This is my startRecording() method

    private void startRecording() {

       try {

           URL url = new URL(path);
           URLConnection urlConnection1 = url.openConnection();
           in1 = new BufferedInputStream(urlConnection1.getInputStream());

       } catch (IOException e) {
           e.printStackTrace();
       }

       try {

           mIn = new MjpegInputStream(in1,MIN_ARRAY_LENGTH);
           mIn.resetFrameCount();
         //  return new MjpegInputStream(in, MIN_ARRAY_LENGTH);
           recorder.start();
           calltimer();

           audioStatus = Micstatus.equals("1");
           startTime = 0;
           completedFrames = 0;
           audioCompleted = 0;

           isRecording = true;
           if (isJelliBean) {
               resetTextureLayout();
           }
           trial.setCanZoom(isRecording);
           setMenuEnabled();

           threadVideo = new VideoRecording();
           threadVideo.start();

           if (audioStatus) {
               threadAudio = new AudioRecordRunnables();
               threadAudio.start();
           }


       } catch (Exception e) {
           try {

               isRecording = false;
               trial.setCanZoom(isRecording);
               setMenuEnabled();

               Toast.makeText(getApplicationContext(), "Try again1", Toast.LENGTH_SHORT).show();
           } catch (Exception e1) {
           }
       }

    }

    This is my ViedoRecording class

    private class VideoRecording extends Thread implements Runnable {

       public void run() {
           try {


               int i = -1;
               int cc = 0;
               int completed = 0;

               FileOutputStream out;
               RecordingHelper recordingHelper;
               try {
                   Thread.sleep(VIDEO_FRAME_RATE < 6 ? 2000 : 300);
               } catch (Exception e) {

               }
               String file = getCacheDir() + "/temp.jpg";
               opencv_core.IplImage iplImage;
               runOnUiThread(videoTimeRunnable);

               while (isRecording || completed < mIn.totalFrames || true)             {
                   try {
                       if (cc < 10) {
                           cc++;
                       }

                       if (i > (MIN_ARRAY_LENGTH - 2)) {
                           i = -1;
                       }
                       recordingHelper = mIn.datas[i + 1];


                       if (recordingHelper != null && recordingHelper.length > 1) {
                           i++;
                           completed++;
                           if (startTime == 0) {
                               startTime = System.currentTimeMillis();
                           }

                           completedFrames++;


                           out = new FileOutputStream(file);
                           out.write(recordingHelper.data);
                           out.flush();

                           out.close();

                           Log.e("recording", "=" + recordingHelper.rotaion);
                           iplImage = cvLoadImage(file, 1);

                           OpenCVFrameConverter.ToIplImage grabberConverter = new OpenCVFrameConverter.ToIplImage();
                           Frame frame = grabberConverter.convert(iplImage);
                           recorder.record(frame);
                           opencv_core.cvReleaseImage(iplImage);
                           mIn.datas[i] = null;
                           totalFramesRecordedByActivity++;
                           runOnUiThread(videoTimeRunnable);

                       } else if (!isRecording && startTime > 0) {
                           break;
                       } else if (cc > 5 && mIn.totalFrames < 1) {
                           break;
                       }

                   } catch (Exception e) {

                   }

               }

               new File(file).delete();
               endTime = System.currentTimeMillis();
               videoThreadFinished = true;

               finalizeRecording();


           } catch (Throwable t) {
               finishThis();

           }

       }
    }
  • Record a html5 page as a video

    14 mars 2017, par user1427930

    My goal is to have a Ubuntu (Desktop) server that "simply" converts html5 webpages into videos. I want to capture the smooth css and js-animations.

    So far I’ve tried this : (phantomjs)
    https://gist.github.com/phanan/e03f75082e6eb114a35c

    The timing and framerate is either choppy or to fast.

    My best solution so far is to open up a Google Chrome window in kiosk mode, wait 3 seconds and then record via ffmpeg with x11grab. It feels like a "bloaty" and unprofessional solution.

    program.sh

    #!/bin/bash
    duration=$1
    outputFile=$2
    stop=$(($duration+5))

    ./openBrowser.sh $stop & PIDOIS=$!
    ./recScreen.sh $duration $outputFile & PIDMIX=$!
    wait $PIDIOS
    wait $PIDMIX

    recScreen.sh

    #!/bin/bash
    sleep 3
    ffmpeg -video_size 1920x1080 -framerate 30 -f x11grab -i :0.0 -c:v libx264 -qp 0 -preset ultrafast -t "$1" "$2".mkv
    killall -9 chrome

    openBrowser.sh

    #!/bin/bash
    /usr/bin/google-chrome --kiosk --incognito http://localhost/testanimation

    Can this be done in a different way ? Perhaps a virtual display ? (must have GPU though). This should be as a desktop server so I don’t want popups or any fail messages from the OS (as it would be burned into the video...)