summaryrefslogtreecommitdiff
path: root/include/asterisk/channel.h
diff options
context:
space:
mode:
authorJason Parker <jparker@digium.com>2013-07-18 16:03:12 +0000
committerJason Parker <jparker@digium.com>2013-07-18 16:03:12 +0000
commitc1a7567d24a08377438837ed26b1f8a886867c10 (patch)
tree4e137b98205c9c96b590b3707ec81c69df84f96b /include/asterisk/channel.h
parent3a2a12ca1ad8097482fe621e8b877db682601905 (diff)
ARI: Add support for suppressing media streams.
Also convert res_mutestream to use the core feature behind this. (closes issue ASTERISK-21618) Review: https://reviewboard.asterisk.org/r/2652/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@394715 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'include/asterisk/channel.h')
-rw-r--r--include/asterisk/channel.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/include/asterisk/channel.h b/include/asterisk/channel.h
index 94053eec2..59145fc08 100644
--- a/include/asterisk/channel.h
+++ b/include/asterisk/channel.h
@@ -4334,4 +4334,35 @@ const char *ast_channel_oldest_linkedid(const char *a, const char *b);
*/
void ast_channel_name_to_dial_string(char *channel_name);
+#define AST_MUTE_DIRECTION_READ (1 << 0)
+#define AST_MUTE_DIRECTION_WRITE (1 << 1)
+
+/*!
+ * \brief Suppress passing of a frame type on a channel
+ *
+ * \note The channel should be locked before calling this function.
+ *
+ * \param chan The channel to suppress
+ * \param direction The direction in which to suppress
+ * \param frametype The type of frame (AST_FRAME_VOICE, etc) to suppress
+ *
+ * \retval 0 Success
+ * \retval -1 Failure
+ */
+int ast_channel_suppress(struct ast_channel *chan, unsigned int direction, enum ast_frame_type frametype);
+
+/*!
+ * \brief Stop suppressing of a frame type on a channel
+ *
+ * \note The channel should be locked before calling this function.
+ *
+ * \param chan The channel to stop suppressing
+ * \param direction The direction in which to stop suppressing
+ * \param frametype The type of frame (AST_FRAME_VOICE, etc) to stop suppressing
+ *
+ * \retval 0 Success
+ * \retval -1 Failure
+ */
+int ast_channel_unsuppress(struct ast_channel *chan, unsigned int direction, enum ast_frame_type frametype);
+
#endif /* _ASTERISK_CHANNEL_H */