vlc | branch: master | Steve Lhomme <[email protected]> | Mon May 2 18:00:04 2016 +0200| [770626332b44979fa93a54e05b8b9afee94bc255] | committer: Jean-Baptiste Kempf
chromecast: send the volume and mute values when about to start playback Signed-off-by: Jean-Baptiste Kempf <[email protected]> > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=770626332b44979fa93a54e05b8b9afee94bc255 --- modules/stream_out/chromecast/chromecast_ctrl.cpp | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/modules/stream_out/chromecast/chromecast_ctrl.cpp b/modules/stream_out/chromecast/chromecast_ctrl.cpp index 9e37603..58dd4ad 100644 --- a/modules/stream_out/chromecast/chromecast_ctrl.cpp +++ b/modules/stream_out/chromecast/chromecast_ctrl.cpp @@ -584,6 +584,11 @@ void intf_sys_t::processMessage(const castchannel::CastMessage &msg) msg_Dbg( p_module, "Playback pending with an offset of %" PRId64, m_chromecast_start_time); } m_time_playback_started = VLC_TS_INVALID; + if (!mediaSessionId.empty()) + { + msgPlayerSetMute( var_InheritBool( p_module, "mute" ) ); + msgPlayerSetVolume( var_InheritFloat( p_module, "volume" ) ); + } break; case RECEIVER_PLAYING: @@ -600,6 +605,12 @@ void intf_sys_t::processMessage(const castchannel::CastMessage &msg) break; case RECEIVER_PAUSED: + if (!mediaSessionId.empty()) + { + msgPlayerSetMute( var_InheritBool( p_module, "mute" ) ); + msgPlayerSetVolume( var_InheritFloat( p_module, "volume" ) ); + } + m_chromecast_start_time = (1 + mtime_t( double( status[0]["currentTime"] ) ) ) * 1000000L; #ifndef NDEBUG msg_Dbg( p_module, "Playback paused with an offset of %" PRId64 " date_play_start:%" PRId64, m_chromecast_start_time, m_time_playback_started); _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
