summaryrefslogtreecommitdiffstats
path: root/libavcodec/sipr.h
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2011-11-10 03:09:46 +0100
committerMichael Niedermayer <michaelni@gmx.at>2011-11-10 03:45:23 +0100
commitafc0a24d7d60f855676d8069011624d52361d7ed (patch)
tree5480e1c0a3f177805d9a2a85321117a94a2bf878 /libavcodec/sipr.h
parentdec354ba1dcc3c7858277d30c73dac030e2a441e (diff)
parentf1f6d3615f3f9a81f41905ea0c8116b4985870e4 (diff)
downloadffmpeg-streaming-afc0a24d7d60f855676d8069011624d52361d7ed.zip
ffmpeg-streaming-afc0a24d7d60f855676d8069011624d52361d7ed.tar.gz
Merge remote-tracking branch 'qatar/master'
* qatar/master: avcodec: add support for planar signed 8-bit PCM. ra144enc: add sample_fmts list to ff_ra_144_encoder smackaud: use uint8_t* for 8-bit output buffer type smackaud: clip output samples smackaud: use sign_extend() for difference value instead of casting sipr: use a function pointer to select the decode_frame function sipr: set mode based on block_align instead of bit_rate sipr: do not needlessly set *data_size to 0 when returning an error ra288: fix formatting of LOCAL_ALIGNED_16 udp: Allow specifying the local IP address VC1: Add bottom field offset to block_index[] to avoid rewriting (+10L) vc1dec: move an if() block. vc1dec: use correct hybrid prediction threshold. vc1dec: Partial rewrite of vc1_pred_mv() vc1dec: take ME precision into account while scaling MV predictors. lavf: don't leak corrupted packets Conflicts: libavcodec/8svx.c libavcodec/ra288.c libavcodec/version.h libavformat/iff.c libavformat/udp.c libavformat/utils.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/sipr.h')
-rw-r--r--libavcodec/sipr.h24
1 files changed, 14 insertions, 10 deletions
diff --git a/libavcodec/sipr.h b/libavcodec/sipr.h
index 3bb0b37..608636e 100644
--- a/libavcodec/sipr.h
+++ b/libavcodec/sipr.h
@@ -53,8 +53,18 @@ typedef enum {
MODE_COUNT
} SiprMode;
-typedef struct {
+typedef struct SiprParameters {
+ int ma_pred_switch; ///< switched moving average predictor
+ int vq_indexes[5];
+ int pitch_delay[5]; ///< pitch delay
+ int gp_index[5]; ///< adaptive-codebook gain indexes
+ int16_t fc_indexes[5][10]; ///< fixed-codebook indexes
+ int gc_index[5]; ///< fixed-codebook gain indexes
+} SiprParameters;
+
+typedef struct SiprContext {
AVCodecContext *avctx;
+ AVFrame frame;
SiprMode mode;
@@ -85,16 +95,10 @@ typedef struct {
float mem_preemph[LP_FILTER_ORDER_16k];
float synth[LP_FILTER_ORDER_16k];
double lsp_history_16k[16];
-} SiprContext;
-typedef struct {
- int ma_pred_switch; ///< switched moving average predictor
- int vq_indexes[5];
- int pitch_delay[5]; ///< pitch delay
- int gp_index[5]; ///< adaptive-codebook gain indexes
- int16_t fc_indexes[5][10]; ///< fixed-codebook indexes
- int gc_index[5]; ///< fixed-codebook gain indexes
-} SiprParameters;
+ void (*decode_frame)(struct SiprContext *ctx, SiprParameters *params,
+ float *out_data);
+} SiprContext;
extern const float ff_pow_0_5[16];
OpenPOWER on IntegriCloud