summaryrefslogtreecommitdiff
path: root/main/format_cache.c
diff options
context:
space:
mode:
authorJoshua Colp <jcolp@digium.com>2017-07-24 18:30:59 +0000
committerJoshua Colp <jcolp@digium.com>2017-07-24 18:30:59 +0000
commita6eb9ee7d22c3cf733e9c05419844519ff3ab05d (patch)
tree7253890c8d4a84800e552913cedfa096186968b3 /main/format_cache.c
parent8b8d5e41102093d4dc3e2f04d5b894e09efe169f (diff)
core: Add VP9 passthrough support.
This change adds VP9 as a known codec and creates a cached "vp9" media format for use. Change-Id: I025a93ed05cf96153d66f36db1839109cc24c5cc
Diffstat (limited to 'main/format_cache.c')
-rw-r--r--main/format_cache.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/main/format_cache.c b/main/format_cache.c
index 302bbf827..1a67ebe60 100644
--- a/main/format_cache.c
+++ b/main/format_cache.c
@@ -191,6 +191,11 @@ struct ast_format *ast_format_mp4;
struct ast_format *ast_format_vp8;
/*!
+ * \brief Built-in cached vp9 format.
+ */
+struct ast_format *ast_format_vp9;
+
+/*!
* \brief Built-in cached jpeg format.
*/
struct ast_format *ast_format_jpeg;
@@ -345,6 +350,7 @@ static void format_cache_shutdown(void)
ao2_replace(ast_format_h264, NULL);
ao2_replace(ast_format_mp4, NULL);
ao2_replace(ast_format_vp8, NULL);
+ ao2_replace(ast_format_vp9, NULL);
ao2_replace(ast_format_t140_red, NULL);
ao2_replace(ast_format_t140, NULL);
ao2_replace(ast_format_t38, NULL);
@@ -444,6 +450,8 @@ static void set_cached_format(const char *name, struct ast_format *format)
ao2_replace(ast_format_mp4, format);
} else if (!strcmp(name, "vp8")) {
ao2_replace(ast_format_vp8, format);
+ } else if (!strcmp(name, "vp9")) {
+ ao2_replace(ast_format_vp9, format);
} else if (!strcmp(name, "red")) {
ao2_replace(ast_format_t140_red, format);
} else if (!strcmp(name, "t140")) {