summaryrefslogtreecommitdiffstats
path: root/audio/audio.h
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2015-01-13 20:14:25 +0100
committerwm4 <wm4@nowhere>2015-01-13 20:14:25 +0100
commit97becbc31bfd6acb76f584eaf65c1546d6fbcc8b (patch)
tree2296fed4fd1d1da2d0b493b635bdd006e71c6fce /audio/audio.h
parent0bbd65b09cb80ee6a822b27a53e7ddfd5d249cf2 (diff)
downloadmpv-97becbc31bfd6acb76f584eaf65c1546d6fbcc8b.tar.bz2
mpv-97becbc31bfd6acb76f584eaf65c1546d6fbcc8b.tar.xz
audio: add some utility functions for refcounted frames
Used in the following commits.
Diffstat (limited to 'audio/audio.h')
-rw-r--r--audio/audio.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/audio/audio.h b/audio/audio.h
index e2346ee0aa..39ceb00705 100644
--- a/audio/audio.h
+++ b/audio/audio.h
@@ -66,8 +66,10 @@ void mp_audio_fill_silence(struct mp_audio *mpa, int start, int length);
void mp_audio_copy(struct mp_audio *dst, int dst_offset,
struct mp_audio *src, int src_offset, int length);
+void mp_audio_copy_attributes(struct mp_audio *dst, struct mp_audio *src);
void mp_audio_skip_samples(struct mp_audio *data, int samples);
+bool mp_audio_is_writeable(struct mp_audio *data);
int mp_audio_make_writeable(struct mp_audio *data);
struct AVFrame;
@@ -76,5 +78,9 @@ struct mp_audio *mp_audio_from_avframe(struct AVFrame *avframe);
struct mp_audio_pool *mp_audio_pool_create(void *ta_parent);
struct mp_audio *mp_audio_pool_get(struct mp_audio_pool *pool,
const struct mp_audio *fmt, int samples);
+struct mp_audio *mp_audio_pool_new_copy(struct mp_audio_pool *pool,
+ struct mp_audio *frame);
+int mp_audio_pool_make_writeable(struct mp_audio_pool *pool,
+ struct mp_audio *frame);
#endif