Recherche avancée

Médias (1)

Mot : - Tags -/getid3

Autres articles (79)

  • 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

  • Contribute to documentation

    13 avril 2011

    Documentation is vital to the development of improved technical capabilities.
    MediaSPIP welcomes documentation by users as well as developers - including : critique of existing features and functions articles contributed by developers, administrators, content producers and editors screenshots to illustrate the above translations of existing documentation into other languages
    To contribute, register to the project users’ mailing (...)

  • Selection of projects using MediaSPIP

    2 mai 2011, par

    The examples below are representative elements of MediaSPIP specific uses for specific projects.
    MediaSPIP farm @ Infini
    The non profit organizationInfini develops hospitality activities, internet access point, training, realizing innovative projects in the field of information and communication technologies and Communication, and hosting of websites. It plays a unique and prominent role in the Brest (France) area, at the national level, among the half-dozen such association. Its members (...)

Sur d’autres sites (7809)

  • Pass a process to a subclass

    16 décembre 2014, par Brett

    I would like to pass a process to a subclass so I may kill it but I can’t figure out how to pass the process. I’m unsure how to store it so I can return it to the form and be able to call the subclass method to kill it. here are my classes

    package my.mashformcnts;
    import java.io.IOException;
    import java.util.Scanner;
    import java.util.regex.Pattern;


    /**
    *
    * @author brett
    */
    public class MashRocks {

       public static Process startThread(MashFormCnts mashFormCnts) throws IOException {
           ProcessBuilder pb = new ProcessBuilder("ffmpeg", "-i", "C:\\Users\\brett\\Documents\\Telegraph_Road.mp4", "C:\\Users\\brett\\Documents\\out.mp4");

           //Here is where i would like to name and store the Process


           final Process p = pb.start();
           // create a new thread to get progress from ffmpeg command , override  
           // it's run method, and start it!  
           Thread t = new Thread() {
               @Override
               public void run() {
                   Scanner sc = new Scanner(p.getErrorStream());
                   // Find duration  
                   Pattern durPattern = Pattern.compile("(?<=Duration: )[^,]*");
                   String dur = sc.findWithinHorizon(durPattern, 0);
                   if (dur == null) {
                       throw new RuntimeException("Could not parse duration.");
                   }
                   String[] hms = dur.split(":");
                   double totalSecs = Integer.parseInt(hms[0]) * 3600 + Integer.parseInt(hms[1]) * 60 + Double.parseDouble(hms[2]);
                   System.out.println("Total duration: " + totalSecs + " seconds.");
                   // Find time as long as possible.  
                   Pattern timePattern = Pattern.compile("(?<=time=)[\\d:.]*");
                   String match;
                   String[] matchSplit;
                   //MashForm pgbar = new MashForm();
                   while (null != (match = sc.findWithinHorizon(timePattern, 0))) {
                       matchSplit = match.split(":");
                       double progress = (Integer.parseInt(matchSplit[0]) * 3600 + Integer.parseInt(matchSplit[1]) * 60 + Double.parseDouble(matchSplit[2])) / totalSecs;
                       int prog = (int) (progress * 100);
                       mashFormCunts.setbar(prog);
                   }
               }
           };
          t.start();
          return p;
       }
      public synchronized static void stop(Thread t) throws IOException{
              Runtime.getRuntime().exec("taskkill /F /IM ffmpeg.exe");  
               t = null;
             //t.interrupt();



      }
    }
      class killMash extends MashRocks{
       public static void Kfpeg(Process p){

         p.destroyForcibly();
       }
    }

    So those are my classes. I’m very new.

    Next there is the event Listener on the form, so when I click this I want to kill the ffmpeg proecess with the Thread t :

     private void jButton2ActionPerformed(java.awt.event.ActionEvent evt) {                                        
           // TODO add your handling code here:
           Thread n = Thread.currentThread();
           System.out.print(n);
           try {
               //MashRocks.stop(n);
                //This isnt working but i think its closer
                killMash.Kfpeg(MashRocks.startThread(this));
    //Not Sure what to do here
     //here is where i want to pass the process sorry for the typo
     killMash.kfpeg(p);
               } catch (IOException ex) {
                   Logger.getLogger(MashFormCunts.class.getName()).log(Level.SEVERE, null, ex);
               }

           }  

    Any help is awesome cheers

  • How Much H.264 In Each Encoder ?

    8 septembre 2010, par Multimedia Mike — General

    Thanks to my recent experiments with code coverage tools, I have a powerful new — admittedly somewhat specious — method of comparing programs. For example, I am certain that I have read on more than one occasion that Apple’s H.264 encoder sucks compared to x264 due, at least in part, to the Apple encoder’s alleged inability to exercise all of H.264′s features. I wonder how to test that claim ?

    Experiment
    Use code coverage tools to determine which H.264 encoder uses the most features.

    Assumptions

    • Movie trailers hosted by Apple will all be encoded with the same settings using Apple’s encoder.
    • Similarly, Yahoo’s movie trailers will be encoded with consistent settings using an unknown encoder.
    • Encoding a video using FFmpeg’s libx264-slow setting will necessarily throw a bunch of H.264′s features into the mix (I really don’t think this assumption holds much water, but I also don’t know what “standard” x264 settings are).

    Methodology

    • Grab a random Apple-hosted 1080p movie trailer and random Yahoo-hosted 1080p movie trailer from Dave’s Trailer Page.
    • Use libx264/FFmpeg with the ‘slow’ preset to encode Big Buck Bunny 1080p from raw PNG files.
    • Build FFmpeg with code coverage enabled.
    • Decode each file to raw YUV, ignore audio decoding, generate code coverage statistics using gcovr, reset stats after each run by deleting *.gcda files.

    Results

    • x264 1080p video : 9968 / 134203 lines
    • Apple 1080p trailer : 9968 / 134203 lines
    • Yahoo 1080p trailer : 9914 / 134203 lines

    I also ran this old x264-encoded file (ImperishableNightStage6Low.mp4) through the same test. It demonstrated the most code coverage with 10671 / 134203 lines.

    Conclusions
    Conclusions ? Ha ! Go ahead and jump all over this test. I’m already fairly confident that it’s impossible (or maybe just very difficult) to build a single H.264-encoded video that exercises every feature that FFmpeg’s decoder supports. For example, is it possible for a file to use both CABAC and CAVLC entropy methods ? If it’s possible, does any current encoder do that ?

  • Revision 31957 : légère amélioration ... Un peu de documentation dans le code également

    7 octobre 2009, par kent1@… — Log

    légère amélioration ...
    Un peu de documentation dans le code également