imgconvert-test: skip pix formats without name

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2012-11-21 20:08:53 +01:00
parent 64dc383de5
commit fb1bb97d87
1 changed files with 1 additions and 1 deletions

View File

@ -637,7 +637,7 @@ int main(void){
for (i=0; i<AV_PIX_FMT_NB*2; i++) {
AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(i);
if(!desc)
if(!desc || !desc->name)
continue;
av_log(0, AV_LOG_INFO, "pix fmt %s yuv_plan:%d avg_bpp:%d colortype:%d\n", desc->name, is_yuv_planar(desc), av_get_padded_bits_per_pixel(desc), get_color_type(desc));
if ((!(desc->flags & PIX_FMT_ALPHA)) != (desc->nb_components != 2 && desc->nb_components != 4)) {