Recherche avancée

Médias (91)

Autres articles (72)

  • Le profil des utilisateurs

    12 avril 2011, par

    Chaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
    L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...)

  • Configurer la prise en compte des langues

    15 novembre 2010, par

    Accéder à la configuration et ajouter des langues prises en compte
    Afin de configurer la prise en compte de nouvelles langues, il est nécessaire de se rendre dans la partie "Administrer" du site.
    De là, dans le menu de navigation, vous pouvez accéder à une partie "Gestion des langues" permettant d’activer la prise en compte de nouvelles langues.
    Chaque nouvelle langue ajoutée reste désactivable tant qu’aucun objet n’est créé dans cette langue. Dans ce cas, elle devient grisée dans la configuration et (...)

  • XMP PHP

    13 mai 2011, par

    Dixit Wikipedia, XMP signifie :
    Extensible Metadata Platform ou XMP est un format de métadonnées basé sur XML utilisé dans les applications PDF, de photographie et de graphisme. Il a été lancé par Adobe Systems en avril 2001 en étant intégré à la version 5.0 d’Adobe Acrobat.
    Étant basé sur XML, il gère un ensemble de tags dynamiques pour l’utilisation dans le cadre du Web sémantique.
    XMP permet d’enregistrer sous forme d’un document XML des informations relatives à un fichier : titre, auteur, historique (...)

Sur d’autres sites (9843)

  • FFMPEG read input from text file and filter complex from file at the same time

    28 août 2020, par Arindam Saha

    I am trying to send input media files from a text file instead of inline argument and filter complex from text file as well.

    


    Here is what I have done.

    


      

    1. I have created a text file and pushed all the input medias in te text file like,

      


      file 0.mp3
file 1.mp3
file 2.mp3
file 3.mp3
file 4.mp3
file 5.mp3
file 6.mp3
file 7.mp3
file 8.mp3
file 9.mp3

...


      


    2. 


    3. I also have created another text file called filter.txt and inject all the complex filter rules in that.

      


      [0]adelay=0|0,volume=207[0a];[1]adelay=111400|111400,volume=206[1a];[2]adelay=116300|116300,volume=205[2a];[3]adelay=122300|122300,volume=204[3a];[4]adelay=125600|125600,volume=203[4a];[5]adelay=128000|128000,volume=202[5a];[6]adelay=137800|137800,volume=201[6a];[7]adelay=149100|149100,volume=200[7a];[8]adelay=150400|150400,volume=199[8a];[9]adelay=151900|151900,volume=198[9a];[10]adelay=153300|153300,volume=197[10a];[11]adelay=190300|190300,volume=196[11a];[12]adelay=210000|210000,volume=195[12a];[13]adelay=222500|222500,volume=194[13a];[14]adelay=224400|224400,volume=193[14a];[15]adelay=226900|226900,volume=192[15a];[16]adelay=228700|228700,volume=191[16a];[17]adelay=236100|236100,volume=190[17a];[18]adelay=240000|240000,volume=189[18a];[19]adelay=251200|251200,volume=188[19a];[20]adelay=253400|253400,volume=187[20a];[21]adelay=256500|256500,volume=186[21a];[22]adelay=258800|258800,volume=185[22a];[23]adelay=263700|263700,volume=184[23a];[24]adelay=267500|267500,volume=183[24a];[25]adelay=272000|272000,volume=182[25a];[26]adelay=273500|273500,volume=181[26a];[27]adelay=276600|276600,volume=180[27a];[28]adelay=27920 ....


      


    4. 


    


    Both these 2 files as input individually works fine. However, if I try to pass both of them together the FFMPEG complains.

    


    ffmpeg -y -f concat -i tmp/input.txt -filter_complex_script tmp/filter.txt -map "[a]" tmp/out.mp3


    


    I get this error :

    


    Invalid file index 1 in filtergraph description 


    


    Any help is really appreciated.

    


  • How to control output file name in a batch file ?

    24 décembre 2016, par vini_i

    I’m running a batch file to use FFMPEG to convert all the files with the *.MTS extension in a directory.

    for %%A in (*.MTS) do ffmpeg -i "%%A" -vcodec copy -acodec pcm_s16le -ar 48000 -ac 2 "newfiles\%%A.mov"
    pause

    The output files go to a directory called newfiles. The conversion takes place with no problem. The problem is that if the input is a file name.MTS the output is a file name.MTS.mov

    How can i change the batch file so that with an input of name.MTS the output is name.mov ?

  • How can I transcode a file with FFMPEG and stream the output file in the response of a Java servlet ?

    6 octobre 2012, par user1700589

    Basically, this is what I'm trying to do :
    1. User passes a URL as a GET parameter to my servlet.
    2. Servlet uses a ProcessBuilder to convert the media contained in that URL to a valid media format (ie : MP3).
    3. The servlet streams the output file being transcoded by FFMPEG back to the browser.

    1 and 2 work fine, but it is 3 I am having a problem with. The best I can do is create a FileInputStream to the output file being transcoded and send that as the response but it is not working. My guess is that it is because the file is being written as I'm trying to stream it.

    Is there anyway to intercept the output file argument in FFMPEG and read it into an InputStream ? In my mind it does not seem that it should be difficult to take input file A, transcode it to output file B, and then stream output file B back to the client, on the fly.

    ProcessBuilder pb = new ProcessBuilder("ffmpeg.exe", "-i", url, "file.mp3");
       Process p = pb.start();

       final InputStream inStream = p.getErrorStream();

       new Thread(new Runnable() {

       public void run() {
               InputStreamReader reader = new InputStreamReader(inStream);
               Scanner scan = new Scanner(reader);
               while (scan.hasNextLine()) {
                   System.out.println(scan.nextLine());
               }
           }
       }).start();

       ServletOutputStream stream = null;
       BufferedInputStream buf = null;
       try {

           stream = response.getOutputStream();
           File mp3 = new File(file.mp3");

           //set response headers
           response.setContentType("audio/mpeg");

           response.addHeader("Content-Disposition", "attachment; filename=file.mp3");

           response.setContentLength(-1);

           //response.setContentLength((int) mp3.length());

           FileInputStream input = new FileInputStream(mp3);
           buf = new BufferedInputStream(input);
           int readBytes = 0;
           //read from the file; write to the ServletOutputStream
           while ((readBytes = buf.read()) != -1) {
               stream.write(readBytes);
           }
       } catch (IOException ioe) {
           throw new ServletException(ioe.getMessage());
       } finally {
           if (stream != null) {
               stream.close();
           }
           if (buf != null) {
               buf.close();
           }
       }