webkit  2cdf99a9e3038c7e01b3c37e8ad903ecbe5eecf1
https://github.com/WebKit/webkit
Classes | Macros | Functions
opus_encoder.c File Reference
#include <stdarg.h>
#include "celt.h"
#include "entenc.h"
#include "modes.h"
#include "API.h"
#include "stack_alloc.h"
#include "float_cast.h"
#include "opus.h"
#include "arch.h"
#include "pitch.h"
#include "opus_private.h"
#include "os_support.h"
#include "cpu_support.h"
#include "analysis.h"
#include "mathops.h"
#include "tuning_parameters.h"
#include "float/structs_FLP.h"

Classes

struct  StereoWidthState
 
struct  OpusEncoder
 

Macros

#define MAX_ENCODER_BUFFER   480
 
#define OPUS_ENCODER_RESET_START   stream_channels
 
#define MAX_DYNAMIC_FRAMESIZE   24
 
#define PCM2VAL(x)   SCALEIN(x)
 

Functions

int opus_encoder_get_size (int channels)
 
int opus_encoder_init (OpusEncoder *st, opus_int32 Fs, int channels, int application)
 
OpusEncoderopus_encoder_create (opus_int32 Fs, int channels, int application, int *error)
 
void downmix_float (const void *_x, opus_val32 *sub, int subframe, int offset, int c1, int c2, int C)
 
void downmix_int (const void *_x, opus_val32 *sub, int subframe, int offset, int c1, int c2, int C)
 
opus_int32 frame_size_select (opus_int32 frame_size, int variable_duration, opus_int32 Fs)
 
opus_int32 compute_frame_size (const void *analysis_pcm, int frame_size, int variable_duration, int C, opus_int32 Fs, int bitrate_bps, int delay_compensation, downmix_func downmix, float *subframe_mem)
 
opus_val16 compute_stereo_width (const opus_val16 *pcm, int frame_size, opus_int32 Fs, StereoWidthState *mem)
 
opus_int32 opus_encode_native (OpusEncoder *st, const opus_val16 *pcm, int frame_size, unsigned char *data, opus_int32 out_data_bytes, int lsb_depth, const void *analysis_pcm, opus_int32 analysis_size, int c1, int c2, int analysis_channels, downmix_func downmix, int float_api)
 
opus_int32 opus_encode (OpusEncoder *st, const opus_int16 *pcm, int analysis_frame_size, unsigned char *data, opus_int32 max_data_bytes)
 
opus_int32 opus_encode_float (OpusEncoder *st, const float *pcm, int analysis_frame_size, unsigned char *data, opus_int32 out_data_bytes)
 
int opus_encoder_ctl (OpusEncoder *st, int request,...)
 
void opus_encoder_destroy (OpusEncoder *st)
 

Macro Definition Documentation

◆ MAX_DYNAMIC_FRAMESIZE

#define MAX_DYNAMIC_FRAMESIZE   24

◆ MAX_ENCODER_BUFFER

#define MAX_ENCODER_BUFFER   480

◆ OPUS_ENCODER_RESET_START

#define OPUS_ENCODER_RESET_START   stream_channels

◆ PCM2VAL

#define PCM2VAL (   x)    SCALEIN(x)

Function Documentation

◆ compute_frame_size()

opus_int32 compute_frame_size ( const void analysis_pcm,
int  frame_size,
int  variable_duration,
int  C,
opus_int32  Fs,
int  bitrate_bps,
int  delay_compensation,
downmix_func  downmix,
float *  subframe_mem 
)

◆ compute_stereo_width()

opus_val16 compute_stereo_width ( const opus_val16 pcm,
int  frame_size,
opus_int32  Fs,
StereoWidthState mem 
)

◆ downmix_float()

void downmix_float ( const void _x,
opus_val32 sub,
int  subframe,
int  offset,
int  c1,
int  c2,
int  C 
)

◆ downmix_int()

void downmix_int ( const void _x,
opus_val32 sub,
int  subframe,
int  offset,
int  c1,
int  c2,
int  C 
)

◆ frame_size_select()

opus_int32 frame_size_select ( opus_int32  frame_size,
int  variable_duration,
opus_int32  Fs 
)

◆ opus_encode_native()

opus_int32 opus_encode_native ( OpusEncoder st,
const opus_val16 pcm,
int  frame_size,
unsigned char *  data,
opus_int32  out_data_bytes,
int  lsb_depth,
const void analysis_pcm,
opus_int32  analysis_size,
int  c1,
int  c2,
int  analysis_channels,
downmix_func  downmix,
int  float_api 
)