mirror of
https://github.com/ggerganov/ggwave.git
synced 2026-02-06 16:47:59 +08:00
c-api : add toggleRxProtocol() (#60)
This function allows to enable/disable Rx protocols during the decoding process. This is useful when the Tx/Rx protocol is known in advance.
This commit is contained in:
@@ -88,4 +88,11 @@ EMSCRIPTEN_BINDINGS(ggwave) {
|
||||
[]() {
|
||||
ggwave_setLogFile(stderr);
|
||||
}));
|
||||
|
||||
emscripten::function("toggleRxProtocol", emscripten::optional_override(
|
||||
[](ggwave_Instance instance,
|
||||
ggwave_TxProtocolId rxProtocolId,
|
||||
int state) {
|
||||
ggwave_toggleRxProtocol(instance, rxProtocolId, state);
|
||||
}));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user