aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorAniket Kumar Lata <alata@quicinc.com>2019-01-18 16:45:01 -0800
committerEric Laurent <elaurent@google.com>2019-02-08 16:59:28 -0800
commit8751cecd805318f37a99fa241d6e86b607c0d00e (patch)
tree60eb05f2e88de4fce5c0d1574244d042b1357998 /include
parentf7c2a4b1b433eedf287a49af69864d49622e93e1 (diff)
downloadtinycompress-8751cecd805318f37a99fa241d6e86b607c0d00e.tar.gz
tinycompress: tinycompress fixes
- Add get_metadata() and set_metadata() API support - Add support to send codec specific data Bug: 123065627 Test: make Change-Id: I9c3f39e22d7246fbb7cf665a4b5ce71a74e07495
Diffstat (limited to 'include')
-rw-r--r--include/tinycompress/tinycompress.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/include/tinycompress/tinycompress.h b/include/tinycompress/tinycompress.h
index 9f95b87..0ab7134 100644
--- a/include/tinycompress/tinycompress.h
+++ b/include/tinycompress/tinycompress.h
@@ -82,6 +82,10 @@ struct compr_gapless_mdata {
struct compress;
struct snd_compr_tstamp;
+#ifdef ENABLE_EXTENDED_COMPRESS_FORMAT
+union snd_codec_options;
+struct snd_compr_metadata;
+#endif
/*
* compress_open: open a new compress stream
* returns the valid struct compress on success, NULL on failure
@@ -235,6 +239,20 @@ int compress_partial_drain(struct compress *compress);
int compress_set_gapless_metadata(struct compress *compress,
struct compr_gapless_mdata *mdata);
+#ifdef ENABLE_EXTENDED_COMPRESS_FORMAT
+/*
+ * compress_set_next_track_param: set params of next compress stream in gapless
+ *
+ * return 0 on success, negative on error
+ *
+ * @compress: compress stream for which codec options has to be set
+ * @codec_options: codec options of compress stream based on codec type
+ */
+
+int compress_set_next_track_param(struct compress *compress,
+ union snd_codec_options *codec_options);
+#endif
+
/*
* is_codec_supported:check if the given codec is supported
* returns true when supported, false if not
@@ -291,6 +309,15 @@ const char *compress_get_error(struct compress *compress);
/* utility functions */
unsigned int compress_get_alsa_rate(unsigned int rate);
+#ifdef ENABLE_EXTENDED_COMPRESS_FORMAT
+/* set metadata */
+int compress_set_metadata(struct compress *compress,
+ struct snd_compr_metadata *mdata);
+
+/* get metadata */
+int compress_get_metadata(struct compress *compress,
+ struct snd_compr_metadata *mdata);
+#endif
#if defined(__cplusplus)
}