summaryrefslogtreecommitdiff
path: root/libavcodec/dcadec.h
diff options
context:
space:
mode:
authorfoo86 <foobaz86@gmail.com>2016-05-13 12:48:24 +0300
committerJames Almer <jamrial@gmail.com>2016-05-20 22:54:48 -0300
commit801dbf0269b1bb5bc70c550e971491e0aea9eb70 (patch)
treeb8701a85692b0369d65471f7c8df8f005d523608 /libavcodec/dcadec.h
parenta0349ae27c127df8c72de1c30dc4090360ec7ef4 (diff)
downloadffmpeg-801dbf0269b1bb5bc70c550e971491e0aea9eb70.tar.gz
avcodec/dca: simplify 'residual ok' flag tracking
Move this from separate structure field to a packet flag. Behavior should be equivalent, except that residual flag is now properly cleared when packet has no core frame at all. Also print a message when forcing recovery mode due to invalid residual to make debugging easier. Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavcodec/dcadec.h')
-rw-r--r--libavcodec/dcadec.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/libavcodec/dcadec.h b/libavcodec/dcadec.h
index 5e4707758b..85283326e7 100644
--- a/libavcodec/dcadec.h
+++ b/libavcodec/dcadec.h
@@ -40,7 +40,10 @@
#define DCA_PACKET_EXSS 0x02
#define DCA_PACKET_XLL 0x04
#define DCA_PACKET_LBR 0x08
-#define DCA_PACKET_RECOVERY 0x10
+#define DCA_PACKET_MASK 0x0f
+
+#define DCA_PACKET_RECOVERY 0x10 ///< Sync error recovery flag
+#define DCA_PACKET_RESIDUAL 0x20 ///< Core valid for residual decoding
typedef struct DCAContext {
const AVClass *class; ///< class for AVOptions
@@ -60,8 +63,6 @@ typedef struct DCAContext {
int packet; ///< Packet flags
- int core_residual_valid; ///< Core valid for residual decoding
-
int request_channel_layout; ///< Converted from avctx.request_channel_layout
int core_only; ///< Core only decoding flag
} DCAContext;