diff options
Diffstat (limited to 'apps/metadata/rm.c')
-rw-r--r-- | apps/metadata/rm.c | 22 |
1 files changed, 5 insertions, 17 deletions
diff --git a/apps/metadata/rm.c b/apps/metadata/rm.c index 9e42367c58..fd6f1d984c 100644 --- a/apps/metadata/rm.c +++ b/apps/metadata/rm.c | |||
@@ -38,26 +38,14 @@ | |||
38 | #define DEBUGF(...) | 38 | #define DEBUGF(...) |
39 | #endif | 39 | #endif |
40 | 40 | ||
41 | #ifdef DEBUG_RM | ||
42 | static uint16_t get_uint16be(uint8_t *buf) | ||
43 | { | ||
44 | return (uint16_t)((buf[0] << 8)|buf[1]); | ||
45 | } | ||
46 | |||
47 | static uint32_t get_uint32be(uint8_t *buf) | ||
48 | { | ||
49 | return (uint32_t)((buf[0] << 24) | (buf[1] << 16) | (buf[2] << 8) | buf[3]); | ||
50 | } | ||
51 | #endif | ||
52 | |||
53 | static inline void print_cook_extradata(RMContext *rmctx) { | 41 | static inline void print_cook_extradata(RMContext *rmctx) { |
54 | 42 | ||
55 | DEBUGF(" cook_version = 0x%08lx\n", get_uint32be(rmctx->codec_extradata)); | 43 | DEBUGF(" cook_version = 0x%08lx\n", rm_get_uint32be(rmctx->codec_extradata)); |
56 | DEBUGF(" samples_per_frame_per_channel = %d\n", get_uint16be(&rmctx->codec_extradata[4])); | 44 | DEBUGF(" samples_per_frame_per_channel = %d\n", rm_get_uint16be(&rmctx->codec_extradata[4])); |
57 | DEBUGF(" number_of_subbands_in_freq_domain = %d\n", get_uint16be(&rmctx->codec_extradata[6])); | 45 | DEBUGF(" number_of_subbands_in_freq_domain = %d\n", rm_get_uint16be(&rmctx->codec_extradata[6])); |
58 | if(rmctx->extradata_size == 16) { | 46 | if(rmctx->extradata_size == 16) { |
59 | DEBUGF(" joint_stereo_subband_start = %d\n",get_uint16be(&rmctx->codec_extradata[12])); | 47 | DEBUGF(" joint_stereo_subband_start = %d\n",rm_get_uint16be(&rmctx->codec_extradata[12])); |
60 | DEBUGF(" joint_stereo_vlc_bits = %d\n", get_uint16be(&rmctx->codec_extradata[14])); | 48 | DEBUGF(" joint_stereo_vlc_bits = %d\n", rm_get_uint16be(&rmctx->codec_extradata[14])); |
61 | } | 49 | } |
62 | } | 50 | } |
63 | 51 | ||