Recherche avancée

Médias (16)

Mot : - Tags -/mp3

Autres articles (20)

  • Création définitive du canal

    12 mars 2010, par

    Lorsque votre demande est validée, vous pouvez alors procéder à la création proprement dite du canal. Chaque canal est un site à part entière placé sous votre responsabilité. Les administrateurs de la plateforme n’y ont aucun accès.
    A la validation, vous recevez un email vous invitant donc à créer votre canal.
    Pour ce faire il vous suffit de vous rendre à son adresse, dans notre exemple "http://votre_sous_domaine.mediaspip.net".
    A ce moment là un mot de passe vous est demandé, il vous suffit d’y (...)

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

  • Taille des images et des logos définissables

    9 février 2011, par

    Dans beaucoup d’endroits du site, logos et images sont redimensionnées pour correspondre aux emplacements définis par les thèmes. L’ensemble des ces tailles pouvant changer d’un thème à un autre peuvent être définies directement dans le thème et éviter ainsi à l’utilisateur de devoir les configurer manuellement après avoir changé l’apparence de son site.
    Ces tailles d’images sont également disponibles dans la configuration spécifique de MediaSPIP Core. La taille maximale du logo du site en pixels, on permet (...)

Sur d’autres sites (3553)

  • ffmpeg - data is being "removed" while h264 is being processed by ffmpeg

    21 mai 2024, par Laki

    I got a file which is created based on messages coming from streaming, all of the "messages" are ending with b'h264\x00'
I got a need to

    


      

    • load the data into ffmpeg
    • 


    • perform some processing of the data
    • 


    • re-attach the data to same "messages"
    • 


    


    Data is loaded with ffmpeg and saved with ffmpeg - however - ffmpeg removes "part" of the data
I have simplified the process and currently I am only loading and saving the data, without any processing, but still - part of the data is being removed

    


    I have used several commands - but always, part of my data is being removed

    


    ffmpeg -i sthg3.h264  -c copy st3.h264
ffmpeg  -err_detect ignore_err -i sthg3.h264  -c copy st3.h264
ffmpeg -fflags +genpts -i sthg3.h264 -c copy st3.h264 


    


    I have created the script for calculating that

    


    file_out = 'sthg3.h264'
def split_file(input_file,chunki):
    output_files = []
    with open(input_file, 'rb') as f:
        file_number = 0
        while True:
            chunk = f.read(504096)  # Read a chunk of data
            if not chunk:  # End of file
                break
            index = chunk.find(chunki)  # Find the delimiter
            while index != -1:
                chunk = chunk[index+len(chunki):]
                file_number += 1
                index = chunk.find(chunki)  # Find the next delimiter
    return file_number

chunki = b'h264\x00'
print(split_file(file_out,chunki))
chunki = b'\x00\x01\x00'
print(split_file(file_out,chunki))
    
chunki = b'h264\x00'
#chunki = b'\x00\x00\xdc\x9e'
print(split_file('st3.h264',chunki))
chunki = b'\x00\x01\x00'
print(split_file('st3.h264',chunki))


    


    and here is the question, how to push data through ffmpeg to avoid removing data, or replace it with something that would not be removed ?

    


  • java.io.IOException : Cannot run program "/data/user/0/com.voi.myapplication8/files/ffmpeg" : error=13, Permission denied

    1er avril 2024, par Harsha
    


    java.io.IOException : Cannot run program
"/data/user/0/com.voi.myapplication8/files/ffmpeg" : error=13,
Permission denied

    


    


    I am using this dependencies
implementation 'com.writingminds:FFmpegAndroid:0.3.2'

    


    


    2024-03-31 21:40:31.045 15937-16762 FFmpeg
    
com.voi.myapplication8 E Exception while trying to run :
[Ljava.lang.String ;@71d4c0f
java.io.IOException : Cannot run program
"/data/user/0/com.voi.myapplication8/files/ffmpeg" : error=13,
Permission denied
at java.lang.ProcessBuilder.start(ProcessBuilder.java:1050)
at java.lang.Runtime.exec(Runtime.java:712)
at java.lang.Runtime.exec(Runtime.java:571)
at
com.github.hiteshsondhi88.libffmpeg.ShellCommand.run(ShellCommand.java:10)
at
com.github.hiteshsondhi88.libffmpeg.FFmpegExecuteAsyncTask.doInBackground(FFmpegExecuteAsyncTask.java:38)
at
com.github.hiteshsondhi88.libffmpeg.FFmpegExecuteAsyncTask.doInBackground(FFmpegExecuteAsyncTask.java:10)
at android.os.AsyncTask$3.call(AsyncTask.java:394)
at java.util.concurrent.FutureTask.run(FutureTask.java:264)
at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:305)
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:644)
at java.lang.Thread.run(Thread.java:1012)
Caused by : java.io.IOException : error=13, Permission denied
at java.lang.UNIXProcess.forkAndExec(Native Method)
at java.lang.UNIXProcess.(UNIXProcess.java:133)
at java.lang.ProcessImpl.start(ProcessImpl.java:141)
at java.lang.ProcessBuilder.start(ProcessBuilder.java:1029)
at java.lang.Runtime.exec(Runtime.java:712) 
at java.lang.Runtime.exec(Runtime.java:571) 
at
com.github.hiteshsondhi88.libffmpeg.ShellCommand.run(ShellCommand.java:10) 
at
com.github.hiteshsondhi88.libffmpeg.FFmpegExecuteAsyncTask.doInBackground(FFmpegExecuteAsyncTask.java:38) 
at
com.github.hiteshsondhi88.libffmpeg.FFmpegExecuteAsyncTask.doInBackground(FFmpegExecuteAsyncTask.java:10) 
at android.os.AsyncTask$3.call(AsyncTask.java:394) 
at java.util.concurrent.FutureTask.run(FutureTask.java:264) 
at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:305) 
at
java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) 
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:644) 
at java.lang.Thread.run(Thread.java:1012)  2024-03-31 21:40:31.045
15937-15937 FFmpeg com.voi.myapplication8
    
E Video cropping failed :

    


    


  • flient-ffmpeg getting error as "ffmpeg exited with code 1 : pipe:0 : Invalid data found when processing input"

    6 avril 2023, par Abhishek Rawal

    I am trying to create API where i need to get uploaded video and create thumbnail from that video. But conditions are :

    


      

    • Video should not store on local disk
    • 


    • Once thumbnail is create it should not store on local disk, instead it should directly uploaded to AWS s3 bucket.
    • 


    


    Following is the code i am trying with :

    


    

    

    const ffmpeg = require('fluent-ffmpeg');
const stream = require('stream');

router.post('/thumbnail', upload.any(), (req, res) => {
  const videoBuffer = req.files[0].buffer;
  
  let readableVideoBuffer = new stream.PassThrough();
    readableVideoBuffer.write(videoBuffer);
    readableVideoBuffer.end()
    
  let bufferStream = new stream.PassThrough();
  
  ffmpeg(readableVideoBuffer)
    .on('filenames', function(filenames) {
      console.log('Will generate ' + filenames.join(', '))
    })
    .on('end', function() {
      console.log('Screenshots taken');
    })
    .on('error', (err) => {
      console.log(err);
    })
    .screenshots({
      count: 4,
      size: '100x100',
      timestamps: ['00:00:01.000'],
    })
    .writeToStream(bufferStream, { end: true });  /* while using this statement i am getting error */
    
    const buffers = [];
    bufferStream.on('data', function (buf) {
      buffers.push(buf);
    });
    bufferStream.on('end', function () {
      const outputBuffer = Buffer.concat(buffers);
      // use s3 bucket code here
      console.log('outputBuffer===========>', outputBuffer)
    });
})

    


    


    



    so while calling this API my app is crashing and i am getting error as :

    


    


    Error : ffmpeg exited with code 1 : pipe:0 : Invalid data found when
processing input

    


    


    Blockquote

    


    If i am not using this statement :

    


    


    .writeToStream(bufferStream, end : true ) ;

    


    


    then able to save file but in local disk, which is not required in my case.

    


    Please help me to understand what is wrong in this code, how i can resolve it.
Any type of help is appreciated.