Recherche avancée

Médias (1)

Mot : - Tags -/epub

Autres articles (64)

  • Other interesting software

    13 avril 2011, par

    We don’t claim to be the only ones doing what we do ... and especially not to assert claims to be the best either ... What we do, we just try to do it well and getting better ...
    The following list represents softwares that tend to be more or less as MediaSPIP or that MediaSPIP tries more or less to do the same, whatever ...
    We don’t know them, we didn’t try them, but you can take a peek.
    Videopress
    Website : http://videopress.com/
    License : GNU/GPL v2
    Source code : (...)

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

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

  • sharedarraybuffer error in edge and firefox but not in chrome when uploading with ffmpeg in nodejs

    29 juillet 2021, par Juliette

    I have the code below in React.js that uses ffmpeg to convert files :

    


    import { createFFmpeg, fetchFile } from '@ffmpeg/ffmpeg';

  const doTranscode = async () => {
    setMessage('Loading ffmpeg-core.js');
    await ffmpeg.load();
    setMessage('Uploading file');
    ffmpeg.FS('writeFile', filename, await fetchFile(file));
    await ffmpeg.run('-i', filename, 'test.wav');
    setMessage('Upload to manager complete. Sound file will be available and playable on the manger within 1-2 minutes.');
    const data = ffmpeg.FS('readFile', 'test.wav');
    setAudioSrc(URL.createObjectURL(new Blob([data.buffer], { type: 'audio/wav' })));

    var file_name = prompt('What would you like to call this file?');

    if (!file_name) {
      file_name = Date.now()
    }
    
    (async function(){
      let output = await getSoundID(customer_id, file_name);
      let sound_id = output.data;
      var bucket_file = new File([new Blob([data.buffer], { type: 'audio/wav' })], "sounds/" + customer_id + "/" + sound_id + ".wav");
      uploadFileToS3(bucket_file);
      updateSoundData(sound_id, customer_id);
    })();
  };

  useEffect(() => {
    if (file) {
      doTranscode()
    }
  }, [file])


    


    The code above works great in Chrome and the files are successfully converted. However, when I bring it to Firefox or Edge I get this error Unhandled Rejection (ReferenceError): SharedArrayBuffer is not defined.

    


    I looked up this issue and they said I need to modify my headers to include this :

    


    You need to set two response headers for your document:

Cross-Origin-Opener-Policy: same-origin Cross-Origin-Embedder-Policy: require-corp


    


    Not sure how I would this in my JS code ?

    


    Would love to hear what you guys think.

    


  • Transfer audio with ffmpeg, unexpected silent at the beginning [duplicate]

    4 mai 2018, par LouisCJT

    I was using ffmpeg to transfer the format of audio files, like from .wav to mp3. The transfer seemed fine and the audio sounds as expected. However when I check its waveform, I found that after the transfer,

    1. A small portion of silent (and with some very tiny noise) is at the beginning of the output audio. The length is about 1 ms 0.001 sec.

    2. As the silent part is appended, the end of the audio is altered - the length of the output audio is longer than the input file. (my input is exactly 10 sec, now the output is around 10.1 sec.

    Need the transfer precise because need to do further analysis frame by frame, and this situation could not go well. I used the following command to transfer a file.

    ffmpeg -I ..\wav_1K_32bit_24576kbps_384000Hz_stereo.wav -vn -ar 12000 -ac 2 -ab 320000 -f MP3 MP3_12000Hz_32kbps_stereo_VBROff.MP3

    Please refer to the screen crop of waveform view.

    Beginning of audio, input (U) & output (L)

    End of audio, input (U) & output (L)

    Thank you !

  • Why am I getting FPE when using swresample 1.1 ?

    24 janvier 2013, par mystafer

    I am building a project to view a video feed from an IP camera in Android using FFmpeg 1.1.

    I'm attempting to use swresample in an Android project and getting a floating point exception when calling swr_convert. I stepped through the swresample code and found one line in libswresample/swresample.c function swri_realloc_audio where the variables a->bps and a->ch_count are zero causing the FPE.

    int swri_realloc_audio(AudioData *a, int count){
       int i, countb;
       AudioData old;

       LOGD("in swri_realloc_audio - bps[%d], ch_count[%d]", a->bps, a->ch_count);
       if(count < 0 || count > INT_MAX/2/a->bps/a->ch_count)
       return AVERROR(EINVAL);

    01-21 17:29:09.612 : D/swresample.c(18789) : in swri_realloc_audio - bps[0], ch_count[0]

    I found bug ticket #1834 in the FFmpeg project that sounds like the exact same issue, but it was resolved by calling swr_init. However, my code does call this function and still crashes. Here is my JNI code :

    SwrContext* resampleCtx = swr_alloc_set_opts(NULL,
           AV_CH_LAYOUT_MONO, AV_SAMPLE_FMT_S16, pAudioCodecCtx->sample_rate,
           pAudioCodecCtx->channel_layout, pAudioCodecCtx->sample_fmt,
           pAudioCodecCtx->sample_rate, 0, 0);

    swr_init(resampleCtx);
    LOGD("Resample context initialized");

    int dataSize = swr_convert(resampleCtx,
           &pAudioOutBuffer, AVCODEC_MAX_AUDIO_FRAME_SIZE / 2,
           (const uint8_t**) &(pFrame->data[0]), pFrame->nb_samples);
    LOGD("Resample conversion complete");

    swr_free(&resampleCtx);
    LOGD("Obtained data size - dataSize[%d]", dataSize);

    I'm confused because I don't seem to have any control over the variable a in the swri_realloc_audio function. I stepped through the code and noticed that it is from the variable resampleCtx->postin. This variable is copied from resampleCtx->in in the swr_init function, but I don't see where in is ever set to anything.

    What am I doing wrong ? Is it in my code or is there a problem in swresample ?