[vlc-commits] [Git][videolan/vlc][master] 2 commits: input: es_out: refactor setting es lang/title for consistency

Steve Lhomme (@robUx4) gitlab at videolan.org
Fri Nov 17 19:55:43 UTC 2023



Steve Lhomme pushed to branch master at VideoLAN / VLC


Commits:
a3afca22 by François Cartegnie at 2023-11-17T19:22:11+00:00
input: es_out: refactor setting es lang/title for consistency

- - - - -
4397478b by François Cartegnie at 2023-11-17T19:22:11+00:00
input: es_out: set original_codec on SET_ES_FMT fourcc translation

Otherwise ends up setting wrong fourcc combination.
ex: avc1/0 -> H264/0, which is meaning annexb, instead of avc1/0 -> H264/avc1

consistency with es_out_Add

- - - - -


1 changed file:

- src/input/es_out.c


Changes:

=====================================
src/input/es_out.c
=====================================
@@ -2142,9 +2142,10 @@ static es_out_id_t *EsOutAddLocked( es_out_t *out, input_source_t *source,
         break;
     }
     EsOutFillEsFmt( out, &es->fmt );
-    es->psz_language = LanguageGetName( es->fmt.psz_language ); /* remember so we only need to do it once */
-    es->psz_language_code = LanguageGetCode( es->fmt.psz_language );
-    es->psz_title = EsGetTitle(es);
+    es->psz_title = NULL;
+    es->psz_language = NULL;
+    es->psz_language_code = NULL;
+    EsOutUpdateEsLanguageTitle( es, &es->fmt ); /* remember so we only need to do it once */
     es->p_dec = NULL;
     es->p_dec_record = NULL;
     es->p_clock = NULL;
@@ -3454,6 +3455,8 @@ static int EsOutVaControlLocked( es_out_t *out, input_source_t *source,
         if( ret != VLC_SUCCESS )
             return ret;
         es->fmt.i_id = i_id;
+        if( !es->fmt.i_original_fourcc )
+            es->fmt.i_original_fourcc = es->fmt.i_codec;
         EsOutFillEsFmt( out, &es->fmt );
         EsOutUpdateEsLanguageTitle(es, &es->fmt);
 



View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/6928d7658452692ac36c386f3c3b6178b7f838f0...4397478b7bca9395e70f41fbcbae8c0078429f60

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/6928d7658452692ac36c386f3c3b6178b7f838f0...4397478b7bca9395e70f41fbcbae8c0078429f60
You're receiving this email because of your account on code.videolan.org.


VideoLAN code repository instance


More information about the vlc-commits mailing list