
Recherche avancée
Médias (1)
-
The pirate bay depuis la Belgique
1er avril 2013, par
Mis à jour : Avril 2013
Langue : français
Type : Image
Autres articles (24)
-
MediaSPIP Core : La Configuration
9 novembre 2010, parMediaSPIP Core fournit par défaut trois pages différentes de configuration (ces pages utilisent le plugin de configuration CFG pour fonctionner) : une page spécifique à la configuration générale du squelettes ; une page spécifique à la configuration de la page d’accueil du site ; une page spécifique à la configuration des secteurs ;
Il fournit également une page supplémentaire qui n’apparait que lorsque certains plugins sont activés permettant de contrôler l’affichage et les fonctionnalités spécifiques (...) -
Les tâches Cron régulières de la ferme
1er décembre 2010, parLa 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 (...) -
Use, discuss, criticize
13 avril 2011, parTalk to people directly involved in MediaSPIP’s development, or to people around you who could use MediaSPIP to share, enhance or develop their creative projects.
The bigger the community, the more MediaSPIP’s potential will be explored and the faster the software will evolve.
A discussion list is available for all exchanges between users.
Sur d’autres sites (3504)
-
libswresample/swresample : avoid s16p internal transfer format
5 janvier 2023, par Paul B Mahollibswresample/swresample : avoid s16p internal transfer format
Instead use float one by default for sample rate conversions.
The s16p internal transfer format produces visible and hearable
quantization artifacts.Signed-off-by : Paul B Mahol <onemda@gmail.com>
for S8 we continue to use S16 as it should have enough precision
Fate is adjusted so bitexactness is maintained between mips/arm/x86
if more tests became bit-inexact on some platform, the same change
can be done to themThe use of higher precision and float intermediates inevitably
leads to more differences between platforms.Signed-off-by : Michael Niedermayer <michael@niedermayer.cc>
-
lavfi/vf_libvmaf : add warning when color ranges differ
1er avril 2023, par Chema Gonzalezlavfi/vf_libvmaf : add warning when color ranges differ
The VMAF filter uses the pixel values without considering
the color ranges. This is incorrect. Patch adds a warning
so at least the user knows it.Let's see an example.
(1) Let's get FR and LR versions of the same image.
```
$ ffmpeg -y -i /tmp/lena.490x490.ppm -vf scale="out_range=full" -pix_fmt yuv420p /tmp/lena.full.y4m
$ xxd /tmp/lena.full.y4m |head
00000000 : 5955 5634 4d50 4547 3220 5734 3930 2048 YUV4MPEG2 W490 H
00000010 : 3439 3020 4632 353a 3120 4970 2041 303a 490 F25:1 Ip A0 :
00000020 : 3020 4334 3230 6a70 6567 2058 5953 4353 0 C420jpeg XYSCS
00000030 : 533d 3432 304a 5045 4720 5843 4f4c 4f52 S=420JPEG XCOLOR
00000040 : 5241 4e47 453d 4655 4c4c 0a46 5241 4d45 RANGE=FULL.FRAME
00000050 : 0a72 7271 7070 706f 6f6e 6d6d 6c6d 6d6d .rrqpppoonmmlmmm
00000060 : 6c6e 6e6d 6d6e 6e6e 6d6c 6d6d 6d6d 6d6d lnnmmnnnmlmmmmmm
00000070 : 6d6e 6d6b 6c6d 6e6e 6d6c 6d6d 6e6e 6f6f mnmklmnnmlmmnnoo
00000080 : 6f6f 6e6e 6e6e 6f70 7172 7375 7676 7370 oonnnnopqrsuvvsp
00000090 : 6d69 6662 5e59 534d 4845 3d35 302e 2d2c mifb^YSMHE=50.-,
``````
$ ffmpeg -y -i /tmp/lena.490x490.ppm -vf scale="out_range=limited" -pix_fmt yuv420p /tmp/lena.limited.y4m
$ xxd /tmp/lena.limited.y4m | head
00000000 : 5955 5634 4d50 4547 3220 5734 3930 2048 YUV4MPEG2 W490 H
00000010 : 3439 3020 4632 353a 3120 4970 2041 303a 490 F25:1 Ip A0 :
00000020 : 3020 4334 3230 6a70 6567 2058 5953 4353 0 C420jpeg XYSCS
00000030 : 533d 3432 304a 5045 4720 5843 4f4c 4f52 S=420JPEG XCOLOR
00000040 : 5241 4e47 453d 4c49 4d49 5445 440a 4652 RANGE=LIMITED.FR
00000050 : 414d 450a 7272 7170 7070 6f6f 6e6e 6e6d AME.rrqpppoonnnm
00000060 : 6e6e 6e6d 6f6e 6e6e 6e6e 6e6e 6d6e 6e6e nnnmonnnnnnnmnnn
00000070 : 6e6e 6e6e 6f6e 6c6d 6e6f 6e6e 6d6e 6e6f nnnnonlmnonnmnno
00000080 : 6f6f 6f6f 6f6f 6f6f 6f6f 7071 7273 7576 oooooooooopqrsuv
00000090 : 7673 706e 6a68 6461 5c57 524e 4b44 3d39 vspnjhda\WRNKD=9
```Note that the 2x images are the same. Only difference is the range,
and the precision issues related to range conversion.(2) Let's calculate the VMAF score :
```
$ ./ffmpeg -filter_threads 1 -filter_complex_threads 1 -i /tmp/lena.full.y4m -i /tmp/lena.limited.y4m -lavfi libvmaf="model=path=/usr/share/model/vmaf_v0.6.1neg.json" -report -f null -
...
[Parsed_libvmaf_0 @ 0x3cc9b40] VMAF score : 85.530109
```As we are comparing an image with itself, we expect the score to
be close to 100. Issue here is that the VMAF filter just uses the
pixel values, ignoring the color ranges.Proposed solution is to add a warning.
```
$ ./ffmpeg -filter_threads 1 -filter_complex_threads 1 -i /tmp/lena.full.y4m -i /tmp/lena.limited.y4m -lavfi libvmaf="model=path=/us
r/share/model/vmaf_v0.6.1neg.json" -report -f null -
...
[Parsed_libvmaf_0 @ 0x3cc9b40] distorted and reference frames use different color ranges (pc != tv)
...
[Parsed_libvmaf_0 @ 0x3cc9b40] VMAF score : 85.530109
```Tested :
Ran fate.
```
$ make fate -j
...
TEST seek-lavf-ppmpipe
TEST seek-lavf-pgmpipe
TEST seek-lavf-mxf_opatom
``` -
how can i use the sox library to process the audio frame decoded by ffmpeg ?
14 juin 2023, par bishop使用sox音频处理库处理经过ffmpeg解码得到的音频帧,


//使用sox处理音频
 int sox_count = 9;
 if (StreamType::AUDIO == stream_type_ ) {
 sox_init();

 sox_signalinfo_t* in_signal = new sox_signalinfo_t();
 in_signal->rate = frame->sample_rate;
 in_signal->channels = frame->ch_layout.nb_channels;
 in_signal->length = frame->nb_samples * in_signal->channels;
 in_signal->precision = av_get_bytes_per_sample(static_cast<avsampleformat>(frame->format)) * 8;

 //= new sox_format_t();
 sox_encodinginfo_t* in_encoding = new sox_encodinginfo_t ();
 in_encoding->encoding = SOX_ENCODING_SIGN2 ;
 sox_format_t* tempFormat = sox_open_mem_read(frame->data[0],
 frame->linesize[0],
 in_signal, in_encoding, "raw");

 //sox_write(tempFormat, reinterpret_cast<const>(frame->data[0]), frame->nb_samples);

 sox_signalinfo_t* out_signal = in_signal; // 输出音频的参数与输入音频相同
 //out_signal->rate = new_sample_rate; // 新的采样率,根据需要进行修改

 sox_encodinginfo_t* out_encoding = in_encoding; // 输出音频的编码格式与输入音频相同

 sox_format_t* outputFormat = sox_open_mem_write(frame->data[0],
 frame->linesize[0],
 out_signal, out_encoding, "raw", nullptr);

 // 3. 使用SoX处理临时文件中的音频数据
 sox_effects_chain_t* chain = sox_create_effects_chain(&tempFormat->encoding, &outputFormat->encoding);
 sox_effect_t* effect;
 char* args[10];

 effect = sox_create_effect(sox_find_effect("input"));
 args[0] = (char*)tempFormat; // 变调参数,可以根据需求进行修改
 assert(sox_effect_options(effect, 1, args) ==SOX_SUCCESS);
 assert(sox_add_effect(chain, effect, &tempFormat->signal, &tempFormat->signal) == SOX_SUCCESS);
 free(effect);


 effect = sox_create_effect(sox_find_effect("vol"));
 args[0] = "200dB", assert(sox_effect_options(effect, 1, args) == SOX_SUCCESS);
 /* Add the effect to the end of the effects processing chain: */
 assert(sox_add_effect(chain, effect, &tempFormat->signal, &tempFormat->signal) == SOX_SUCCESS);
 free(effect);

 /*
 effect = sox_create_effect(sox_find_effect("pitch"));
 args[0] = {"50.0"}; // 变调参数,可以根据需求进行修改
 assert(sox_effect_options(effect, 1, args) == SOX_SUCCESS);
 assert(sox_add_effect(chain, effect, &tempFormat->signal, &outputFormat->signal) == SOX_SUCCESS);
 free(effect);
 */

 effect = sox_create_effect(sox_find_effect("output"));
 args[0] = (char*)outputFormat; // 变调参数,可以根据需求进行修改
 assert(sox_effect_options(effect, 1, args) == SOX_SUCCESS);
 if(sox_add_effect(chain, effect, &tempFormat->signal, &outputFormat->signal) == SOX_SUCCESS) {
 std::cout<<"true"</assert(sox_add_effect(chain, effect, &tempFormat->signal, &outputFormat->signal) == SOX_SUCCESS);
 free(effect);

 // 4. 处理音频数据
 sox_flow_effects(chain, nullptr, nullptr);

 fflush((FILE*)outputFormat->fp); 
 memcpy(frame->data[1], frame->data[0], frame->linesize[0]);

 // 释放资源
 sox_delete_effects_chain(chain);
 sox_close(tempFormat);
 sox_close(outputFormat);
 sox_quit();

 }
</const></avsampleformat>


error :"input : : this handler does not support this data size"


when execute in the line of "sox_flow_effects(chain, nullptr, nullptr) ;"


how can i fixed this problem ?


i have changed the val of "sox_format_t* tempFormat = sox_open_mem_read(frame->data[0],
frame->linesize[0],
in_signal, in_encoding, "raw") ;" buffer_size,but also not right.