We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi! I noticed that when trying to run libcec_mute_audio through the C library, it wouldn't work on my TV (I don't have an audio system).
libcec_mute_audio
It looks like SendMuteAudio is designed to send key presses if there isn't an audio system, but the C library doesn't use it:
SendMuteAudio
src/libcec/LibCECC.cpp
#if CEC_LIB_VERSION_MAJOR >= 5 int libcec_mute_audio(libcec_connection_t connection, int UNUSED(bSendRelease)) { ICECAdapter* adapter = static_cast<ICECAdapter*>(connection); return adapter ? adapter->AudioToggleMute() : -1; } #endif
src/libcec/LibCEC.cpp
#if CEC_LIB_VERSION_MAJOR >= 5 uint8_t CLibCEC::MuteAudio(void) { return !!m_client ? m_client->SendMuteAudio() : (uint8_t)CEC_AUDIO_VOLUME_STATUS_UNKNOWN; } #endif
I'm working around this, by just sending key presses manually (I'm using https://github.com/ssalonen/cec-rs in Rust, which internally uses the C library):
fn mute(cec: &CecConnection) -> CecConnectionResult<()> { cec.send_keypress(CecLogicalAddress::Tv, CecUserControlCode::Mute, true)?; cec.send_key_release(CecLogicalAddress::Tv, true)?; Ok(()) }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Hi! I noticed that when trying to run
libcec_mute_audio
through the C library, it wouldn't work on my TV (I don't have an audio system).It looks like
SendMuteAudio
is designed to send key presses if there isn't an audio system, but the C library doesn't use it:C:
src/libcec/LibCECC.cpp
:C++:
src/libcec/LibCEC.cpp
:I'm working around this, by just sending key presses manually (I'm using https://github.com/ssalonen/cec-rs in Rust, which internally uses the C library):
The text was updated successfully, but these errors were encountered: