]> git.sesse.net Git - vlc/commitdiff
telx/zvbi: initialize aspect ratio
authorRafaël Carré <funman@videolan.org>
Fri, 7 Nov 2014 11:48:37 +0000 (12:48 +0100)
committerRafaël Carré <funman@videolan.org>
Fri, 7 Nov 2014 11:56:23 +0000 (12:56 +0100)
modules/codec/telx.c
modules/codec/zvbi.c

index 9e4228b37e0f80ed37ede5547ace176ba50819bc..3b221fb04926515d8933996275e26165636cc4c7 100644 (file)
@@ -693,8 +693,7 @@ static subpicture_t *Decode( decoder_t *p_dec, block_t **pp_block )
     }
  
     /* Create a new subpicture region */
-    memset( &fmt, 0, sizeof(video_format_t) );
-    fmt.i_chroma = VLC_CODEC_TEXT;
+    video_format_Init(&fmt, VLC_CODEC_TEXT);
     fmt.i_width = fmt.i_height = 0;
     fmt.i_x_offset = fmt.i_y_offset = 0;
     p_spu->p_region = subpicture_region_New( &fmt );
index 2d2d32f4a3043626f4f9b9db578837c018d6b530..1331e09f03bd7c15288f4a4ae08a14eb57eb23dd 100644 (file)
@@ -503,10 +503,7 @@ static subpicture_t *Subpicture( decoder_t *p_dec, video_format_t *p_fmt,
         return NULL;
     }
 
-    memset( &fmt, 0, sizeof(video_format_t) );
-    fmt.i_chroma = b_text ? VLC_CODEC_TEXT : VLC_CODEC_RGBA;
-    fmt.i_sar_num = 0;
-    fmt.i_sar_den = 1;
+    video_format_Init(&fmt, b_text ? VLC_CODEC_TEXT : VLC_CODEC_RGBA);
     if( b_text )
     {
         fmt.i_bits_per_pixel = 0;