AVBPrint part[4], int *print_prefix, int type[2])
{
AVClass* avc = avcl ? *(AVClass **) avcl : NULL;
- av_bprint_init(part+0, 0, 1);
- av_bprint_init(part+1, 0, 1);
- av_bprint_init(part+2, 0, 1);
+ av_bprint_init(part+0, 0, AV_BPRINT_SIZE_AUTOMATIC);
+ av_bprint_init(part+1, 0, AV_BPRINT_SIZE_AUTOMATIC);
+ av_bprint_init(part+2, 0, AV_BPRINT_SIZE_AUTOMATIC);
av_bprint_init(part+3, 0, 65536);
if(type) type[0] = type[1] = AV_CLASS_CATEGORY_NA + 16;
av_bprintf(part+1, "[%s @ %p] ",
avc->item_name(avcl), avcl);
if(type) type[1] = get_category(avcl);
-
- if (flags & AV_LOG_PRINT_LEVEL)
- av_bprintf(part+2, "[%s] ", get_level_str(level));
}
+ if (*print_prefix && (level > AV_LOG_QUIET) && (flags & AV_LOG_PRINT_LEVEL))
+ av_bprintf(part+2, "[%s] ", get_level_str(level));
+
av_vbprintf(part+3, fmt, vl);
if(*part[0].str || *part[1].str || *part[2].str || *part[3].str) {