diff options
author | wm4 <wm4@nowhere> | 2013-11-10 23:05:51 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2013-11-10 23:05:59 +0100 |
commit | 3cb4116243e54b0452d88c70a7acd4af17cf8d02 (patch) | |
tree | f1e97c8d9f630e81c3e7e7c4022b87952bcfcc15 /audio/format.h | |
parent | 6ec1f317654ae1e1424ec7c519cf307aae7c3efe (diff) | |
download | mpv-3cb4116243e54b0452d88c70a7acd4af17cf8d02.tar.bz2 mpv-3cb4116243e54b0452d88c70a7acd4af17cf8d02.tar.xz |
ao: add ao_play_silence, use for ao_alsa and ao_oss
Also add a corresponding function to audio/format.c, which fills an
audio block with silence.
Diffstat (limited to 'audio/format.h')
-rw-r--r-- | audio/format.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/audio/format.h b/audio/format.h index 3a80a601c5..95e792340c 100644 --- a/audio/format.h +++ b/audio/format.h @@ -134,6 +134,9 @@ enum af_format { (AF_FORMAT_IS_AC3(fmt) || \ ((fmt) & AF_FORMAT_SPECIAL_MASK) == AF_FORMAT_S_IEC61937) +#define AF_FORMAT_IS_SPECIAL(fmt) \ + ((fmt & AF_FORMAT_SPECIAL_MASK) != 0) + struct af_fmt_entry { const char *name; int format; @@ -152,4 +155,6 @@ int af_fmt_seconds_to_bytes(int format, float seconds, int channels, int sampler bool af_fmt_is_valid(int format); +void af_fill_silence(void *dst, size_t bytes, int format); + #endif /* MPLAYER_AF_FORMAT_H */ |