} pa_echo_canceller_method_t;
enum {
- AEC_SET_VOLUME,
- AEC_SET_DEVICE,
+ AEC_SET_VOLUME,
+ AEC_SET_DEVICE,
};
#ifdef HAVE_WEBRTC
}
static int extension_cb(pa_native_protocol *p, pa_module *m, pa_native_connection *c, uint32_t tag, pa_tagstruct *t) {
- uint32_t command;
- uint32_t value;
- pa_tagstruct *reply = NULL;
- pa_assert(p);
- pa_assert(m);
- pa_assert(c);
- pa_assert(t);
-
- if (pa_tagstruct_getu32(t, &command) < 0)
- goto fail;
-
- reply = pa_tagstruct_new(NULL, 0);
- pa_tagstruct_putu32(reply, PA_COMMAND_REPLY);
- pa_tagstruct_putu32(reply, tag);
-
- switch (command) {
- case AEC_SET_VOLUME: {
- pa_tagstruct_getu32(t,&value);
- pa_log_debug("AEC_SET_VOLUME in echo cancel = %d",value);
- break;
- }
- case AEC_SET_DEVICE: {
- pa_tagstruct_getu32(t,&value);
- pa_log_debug("AEC_SET_DEVICE in echo cancel = %d",value);
- break;
- }
- default:
- goto fail;
- }
- pa_pstream_send_tagstruct(pa_native_connection_get_pstream(c), reply);
- return 0;
+ uint32_t command;
+ uint32_t value;
+ pa_tagstruct *reply = NULL;
+ pa_assert(p);
+ pa_assert(m);
+ pa_assert(c);
+ pa_assert(t);
+
+ if (pa_tagstruct_getu32(t, &command) < 0)
+ goto fail;
+
+ reply = pa_tagstruct_new(NULL, 0);
+ pa_tagstruct_putu32(reply, PA_COMMAND_REPLY);
+ pa_tagstruct_putu32(reply, tag);
+
+ switch (command) {
+ case AEC_SET_VOLUME: {
+ pa_tagstruct_getu32(t,&value);
+ pa_log_debug("AEC_SET_VOLUME in echo cancel = %d",value);
+ break;
+ }
+ case AEC_SET_DEVICE: {
+ pa_tagstruct_getu32(t,&value);
+ pa_log_debug("AEC_SET_DEVICE in echo cancel = %d",value);
+ break;
+ }
+ default:
+ goto fail;
+ }
+ pa_pstream_send_tagstruct(pa_native_connection_get_pstream(c), reply);
+ return 0;
fail:
- return -1;
+ return -1;
}
/* Common initialisation bits between module-echo-cancel and the standalone