[vlc-commits] chromecast: resize large resolution videos

Erick Tyndall git at videolan.org
Wed Oct 3 09:56:02 CEST 2018


vlc | branch: master | Erick Tyndall <erythros at gmail.com> | Mon Oct  1 12:33:32 2018 -0400| [25d48899ba8dc75df8346a9b72fa094c2c33eb2d] | committer: Thomas Guillem

chromecast: resize large resolution videos

1080p and lower resolution videos correctly scale/resize during transcoding.
This patch corrects the resizing of videos that exceed 1080p.

Signed-off-by: Thomas Guillem <thomas at gllm.fr>

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=25d48899ba8dc75df8346a9b72fa094c2c33eb2d
---

 modules/stream_out/chromecast/cast.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/modules/stream_out/chromecast/cast.cpp b/modules/stream_out/chromecast/cast.cpp
index 2ef26d8eb4..3de2d7a3ba 100644
--- a/modules/stream_out/chromecast/cast.cpp
+++ b/modules/stream_out/chromecast/cast.cpp
@@ -1133,10 +1133,10 @@ sout_stream_sys_t::GetVcodecOption( sout_stream_t *p_stream, vlc_fourcc_t *p_cod
     {
         case CONVERSION_QUALITY_HIGH:
         case CONVERSION_QUALITY_MEDIUM:
-            ssout << video_maxres_hd << ',';
+            ssout << ( ( p_vid->i_width > 1920 ) ? "width=1920," : "" ) << video_maxres_hd << ',';
             break;
         default:
-            ssout << video_maxres_720p << ',';
+            ssout << ( ( p_vid->i_width > 1280 ) ? "width=1280," : "" ) << video_maxres_720p << ',';
     }
 
     if( p_vid == NULL



More information about the vlc-commits mailing list