
Recherche avancée
Médias (91)
-
MediaSPIP Simple : futur thème graphique par défaut ?
26 septembre 2013, par
Mis à jour : Octobre 2013
Langue : français
Type : Video
-
avec chosen
13 septembre 2013, par
Mis à jour : Septembre 2013
Langue : français
Type : Image
-
sans chosen
13 septembre 2013, par
Mis à jour : Septembre 2013
Langue : français
Type : Image
-
config chosen
13 septembre 2013, par
Mis à jour : Septembre 2013
Langue : français
Type : Image
-
SPIP - plugins - embed code - Exemple
2 septembre 2013, par
Mis à jour : Septembre 2013
Langue : français
Type : Image
-
GetID3 - Bloc informations de fichiers
9 avril 2013, par
Mis à jour : Mai 2013
Langue : français
Type : Image
Autres articles (103)
-
MediaSPIP version 0.1 Beta
16 avril 2011, parMediaSPIP 0.1 beta est la première version de MediaSPIP décrétée comme "utilisable".
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Pour avoir une installation fonctionnelle, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...) -
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
Ajouter notes et légendes aux images
7 février 2011, parPour pouvoir ajouter notes et légendes aux images, la première étape est d’installer le plugin "Légendes".
Une fois le plugin activé, vous pouvez le configurer dans l’espace de configuration afin de modifier les droits de création / modification et de suppression des notes. Par défaut seuls les administrateurs du site peuvent ajouter des notes aux images.
Modification lors de l’ajout d’un média
Lors de l’ajout d’un média de type "image" un nouveau bouton apparait au dessus de la prévisualisation (...)
Sur d’autres sites (7708)
-
I have a m3u8 file where the individual files don't have any .ts format, Is there a way to cocnat them to a single mp4 file
6 septembre 2020, par Suhail HussainHere is a snippet of the m3u8 file


#EXTM3U
#EXTINF:1,0
0
#EXTINF:1695,0c9c3bf590e32dcb8c4b83222056838b
0c9c3bf590e32dcb8c4b83222056838b
#EXTINF:1,1
1
#EXTINF:4,2
2
#EXTINF:3,3
3
#EXTINF:4,4
4
#EXTINF:3,5
5
#EXTINF:3,6
6
#EXTINF:4,7
7
#EXTINF:4,8
8
#EXTINF:3,9
9
#EXTINF:4,10
10



This goes on for some 500 files. I am able to open the folder in vlc as a playlist but it is just a collection of 500 files that play one after the another. I checked online and found that ffmpeg can concatenate a m3u8 file to a mp4. That unfortunately did not work. After trying a few different syntaxes that I found on different forums which also did not work, I tried "ffplay" on the file name which once again gave the same error message as before -
Invalid data found when processing input:= 0B f=0/0


So this made me believe perhaps ffmpeg is unable to open the file while vlc is able to. Any way to combine these files to a single file is appreciated


-
How do I use FFMPEG/libav to access the data in individual audio samples ?
15 octobre 2022, par BreadsnshredsThe end result is I'm trying to visualise the audio waveform to use in a DAW-like software. So I want to get each sample's value and draw it. With that in mind, I'm currently stumped by trying to gain access to the values stored in each sample. For the time being, I'm just trying to access the value in the first sample - I'll build it into a loop once I have some working code.


I started off by following the code in this example. However, LibAV/FFMPEG has been updated since then, so a lot of the code is deprecated or straight up doesn't work the same anymore.


Based on the example above, I believe the logic is as follows :


- 

- get the formatting info of the audio file
- get audio stream info from the format
- check that the codec required for the stream is an audio codec
- get the codec context (I think this is info about the codec) - This is where it gets kinda confusing for me
- create an empty packet and frame to use - packets are for holding compressed data and frames are for holding uncompressed data
- the format reads the first frame from the audio file into our packet
- pass that packet into the codec context to be decoded
- pass our frame to the codec context to receive the uncompressed audio data of the first frame
- create a buffer to hold the values and try allocating samples to it from our frame




















From debugging my code, I can see that step 7 succeeds and the packet that was empty receives some data. In step 8, the frame doesn't receive any data. This is what I need help with. I get that if I get the frame, assuming a stereo audio file, I should have two samples per frame, so really I just need your help to get uncompressed data into the frame.


I've scoured through the documentation for loads of different classes and I'm pretty sure I'm using the right classes and functions to achieve my goal, but evidently not (I'm also using Qt, so I'm using qDebug throughout, and QString to hold the URL for the audio file as path). So without further ado, here's my code :


// Step 1 - get the formatting info of the audio file
 AVFormatContext* format = avformat_alloc_context();
 if (avformat_open_input(&format, path.toStdString().c_str(), NULL, NULL) != 0) {
 qDebug() << "Could not open file " << path;
 return -1;
 }

// Step 2 - get audio stream info from the format
 if (avformat_find_stream_info(format, NULL) < 0) {
 qDebug() << "Could not retrieve stream info from file " << path;
 return -1;
 }

// Step 3 - check that the codec required for the stream is an audio codec
 int stream_index =- 1;
 for (unsigned int i=0; inb_streams; i++) {
 if (format->streams[i]->codecpar->codec_type == AVMEDIA_TYPE_AUDIO) {
 stream_index = i;
 break;
 }
 }

 if (stream_index == -1) {
 qDebug() << "Could not retrieve audio stream from file " << path;
 return -1;
 }

// Step 4 -get the codec context
 const AVCodec *codec = avcodec_find_decoder(format->streams[stream_index]->codecpar->codec_id);
 AVCodecContext *codecContext = avcodec_alloc_context3(codec);
 avcodec_open2(codecContext, codec, NULL);

// Step 5 - create an empty packet and frame to use
 AVPacket *packet = av_packet_alloc();
 AVFrame *frame = av_frame_alloc();

// Step 6 - the format reads the first frame from the audio file into our packet
 av_read_frame(format, packet);
// Step 7 - pass that packet into the codec context to be decoded
 avcodec_send_packet(codecContext, packet);
//Step 8 - pass our frame to the codec context to receive the uncompressed audio data of the first frame
 avcodec_receive_frame(codecContext, frame);

// Step 9 - create a buffer to hold the values and try allocating samples to it from our frame
 double *buffer;
 av_samples_alloc((uint8_t**) &buffer, NULL, 1, frame->nb_samples, AV_SAMPLE_FMT_DBL, 0);
 qDebug () << "packet: " << &packet;
 qDebug() << "frame: " << frame;
 qDebug () << "buffer: " << buffer;



For the time being, step 9 is incomplete as you can probably tell. But for now, I need help with step 8. Am I missing a step, using the wrong function, wrong class ? Cheers.


-
FFmpeg batch file - combine individual set files with randomized selection from another set of files
4 août 2018, par SiampuI need to combine a specific set of files with a randomized selection from another set of files ; for more specific context, voice clips followed by a randomized walky-talky beep. At the moment, I’ve managed to assemble this so far from searching around :
setlocal EnableDelayedExpansion
cd beeps
set n=0
for %%f in (*.*) do (
set /A n+=1
set "file[!n!]=%%f"
)
set /A "rand=(n*%random%)/32768+1"
cd ..
for %%A IN (*.ogg) DO ffmpeg -y -i radio_beep.wav -i "%%A" -i "beeps\!file[%rand%]!" -filter_complex "[0:a:0][1:a:0][2:a:0]concat=n=3:v=0:a=1[outa]" -map "[outa]" "helper\%%A"At the moment, this will only run the randomization once and use that selection for every file. How can I have it do the randomization for each .ogg in the folder, and get that into FFmpeg as an input ?