mirror of
https://github.com/ggerganov/ggwave.git
synced 2026-02-08 18:38:05 +08:00
emscripten : add rx duration frames api getter (#100)
* Add rxDurationFrames api getter * Fixed comment --------- Co-authored-by: Vittorio Palmisano <vittorio.palmisano@ringcentral.com>
This commit is contained in:
committed by
GitHub
parent
c2716d8cff
commit
bac95c8113
@@ -75,7 +75,7 @@ EMSCRIPTEN_BINDINGS(ggwave) {
|
||||
|
||||
int nActual = ggwave_encode(instance, data.data(), data.size(), protocolId, volume, result.data(), 0);
|
||||
|
||||
printf("n = %d, nActual = %d\n", n, nActual);
|
||||
// printf("n = %d, nActual = %d\n", n, nActual);
|
||||
return emscripten::val(emscripten::typed_memory_view(nActual, result.data()));
|
||||
}));
|
||||
|
||||
@@ -128,4 +128,9 @@ EMSCRIPTEN_BINDINGS(ggwave) {
|
||||
int freqStart) {
|
||||
ggwave_txProtocolSetFreqStart(protocolId, freqStart);
|
||||
}));
|
||||
|
||||
emscripten::function("rxDurationFrames", emscripten::optional_override(
|
||||
[](ggwave_Instance instance) {
|
||||
return ggwave_rxDurationFrames(instance);
|
||||
}));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user