FastLED 3.9.15
Loading...
Searching...
No Matches
fl::third_party::vorbis Namespace Reference

Classes

struct  Codebook
 
struct  CRCscan
 
union  float_conv
 
union  Floor
 
struct  Floor0
 
struct  Floor1
 
struct  Mapping
 
struct  MappingChannel
 
struct  Mode
 
struct  ProbedPage
 
struct  Residue
 
struct  stb_vorbis
 
struct  stb_vorbis_alloc
 
struct  stb_vorbis_comment
 
struct  stb_vorbis_info
 
struct  stbv__floor_ordering
 
struct  StbvTempBuffer
 

Typedefs

typedef float codetype
 
typedef signed short int16
 
typedef int32_t int32
 
typedef signed char int8
 
typedef struct stb_vorbis stb_vorbis
 
typedef char stb_vorbis_float_size_test[sizeof(float)==4 &&sizeof(int32_t)==4]
 
typedef unsigned short uint16
 
typedef uint32_t uint32
 
typedef unsigned char uint8
 
typedef struct stb_vorbis vorb
 
typedef int16 YTYPE
 

Enumerations

enum  { VORBIS_packet_id = 1 , VORBIS_packet_comment = 3 , VORBIS_packet_setup = 5 }
 
enum  STBVorbisError {
  VORBIS__no_error , VORBIS_need_more_data =1 , VORBIS_invalid_api_mixing , VORBIS_outofmem ,
  VORBIS_feature_not_supported , VORBIS_too_many_channels , VORBIS_file_open_failure , VORBIS_seek_without_length ,
  VORBIS_unexpected_eof =10 , VORBIS_seek_invalid , VORBIS_invalid_setup =20 , VORBIS_invalid_stream ,
  VORBIS_missing_capture_pattern =30 , VORBIS_invalid_stream_structure_version , VORBIS_continued_packet_flag_invalid , VORBIS_incorrect_stream_serial_number ,
  VORBIS_invalid_first_page , VORBIS_bad_packet_type , VORBIS_cant_find_last_page , VORBIS_seek_failed ,
  VORBIS_ogg_skeleton_not_supported
}
 

Functions

static void add_entry (Codebook *c, uint32 huff_code, int32_t symbol, int32_t count, int32_t len, uint32 *values) FL_NOEXCEPT
 
static uint32_t bit_reverse (uint32_t n) FL_NOEXCEPT
 
static int32_t capture_pattern (vorb *f) FL_NOEXCEPT
 
static int32_t codebook_decode (vorb *f, Codebook *c, float *output, int32_t len) FL_NOEXCEPT
 
static int32_t codebook_decode_deinterleave_repeat (vorb *f, Codebook *c, float **outputs, int32_t ch, int32_t *c_inter_p, int32_t *p_inter_p, int32_t len, int32_t total_decode) FL_NOEXCEPT
 
static int32_t codebook_decode_scalar_raw (vorb *f, Codebook *c) FL_NOEXCEPT
 
static int32_t codebook_decode_start (vorb *f, Codebook *c) FL_NOEXCEPT
 
static int32_t codebook_decode_step (vorb *f, Codebook *c, float *output, int32_t len, int32_t step) FL_NOEXCEPT
 
static void compute_accelerated_huffman (Codebook *c) FL_NOEXCEPT
 
static void compute_bitreverse (int32_t n, uint16 *rev) FL_NOEXCEPT
 
static int32_t compute_codewords (Codebook *c, uint8 *len, int32_t n, uint32 *values) FL_NOEXCEPT
 
static void compute_samples (int32_t mask, short *output, int32_t num_c, float **data, int32_t d_offset, int32_t len) FL_NOEXCEPT
 
static void compute_sorted_huffman (Codebook *c, uint8 *lengths, uint32 *values) FL_NOEXCEPT
 
static void compute_stereo_samples (short *output, int32_t num_c, float **data, int32_t d_offset, int32_t len) FL_NOEXCEPT
 
static void compute_twiddle_factors (int32_t n, float *A, float *B, float *C) FL_NOEXCEPT
 
static void compute_window (int32_t n, float *window) FL_NOEXCEPT
 
static void convert_channels_short_interleaved (int32_t buf_c, short *buffer, int32_t data_c, float **data, int32_t d_offset, int32_t len) FL_NOEXCEPT
 
static void convert_samples_short (int32_t buf_c, short **buffer, int32_t b_offset, int32_t data_c, float **data, int32_t d_offset, int32_t samples) FL_NOEXCEPT
 
static void copy_samples (short *dest, float *src, int32_t len) FL_NOEXCEPT
 
template<typename T>
enable_if< is_fixed_point< T >::value, T >::type cos (T angle) FL_NOEXCEPT
 
static void crc32_init (void) FL_NOEXCEPT
 
FL_ALWAYS_INLINE uint32 crc32_update (uint32 crc, uint8 byte) FL_NOEXCEPT
 
static void decode_residue (vorb *f, float *residue_buffers[], int32_t ch, int32_t n, int32_t rn, uint8 *do_not_decode) FL_NOEXCEPT
 
static int32_t do_floor (vorb *f, Mapping *map, int32_t i, int32_t n, float *target, YTYPE *finalY, uint8 *step2_flag) FL_NOEXCEPT
 
FL_ALWAYS_INLINE void draw_line (float *output, int32_t x0, int32_t y0, int32_t x1, int32_t y1, int32_t n) FL_NOEXCEPT
 
static int32_t error (vorb *f, enum STBVorbisError e) FL_NOEXCEPT
 
template<typename T>
enable_if< is_fixed_point< T >::value, T >::type exp (T x) FL_NOEXCEPT
 
static void * fl_stbv_temp_alloc_impl (vorb *f, int32_t size) FL_NOEXCEPT
 
static void fl_stbv_temp_alloc_restore_impl (vorb *f, int32_t saved) FL_NOEXCEPT
 
static int32_t fl_stbv_temp_alloc_save_impl (vorb *f) FL_NOEXCEPT
 
static float float32_unpack (uint32 x) FL_NOEXCEPT
 
template<typename T>
constexpr enable_if< is_fixed_point< T >::value, T >::type floor (T x) FL_NOEXCEPT
 
static void flush_packet (vorb *f) FL_NOEXCEPT
 
void free (void *ptr)
 
static uint32 get32 (vorb *f) FL_NOEXCEPT
 
static int32_t get32_packet (vorb *f) FL_NOEXCEPT
 
static uint8 get8 (vorb *z) FL_NOEXCEPT
 
static int32_t get8_packet (vorb *f) FL_NOEXCEPT
 
static int32_t get8_packet_raw (vorb *f) FL_NOEXCEPT
 
static uint32 get_bits (vorb *f, int32_t n) FL_NOEXCEPT
 
static int32_t get_seek_page_info (stb_vorbis *f, ProbedPage *z) FL_NOEXCEPT
 
static StbvTempBufferget_stbv_temp_buffer () FL_NOEXCEPT
 
static float * get_window (vorb *f, int32_t len) FL_NOEXCEPT
 
static int32_t getn (vorb *z, uint8 *data, int32_t n) FL_NOEXCEPT
 
static int32_t go_to_page_before (stb_vorbis *f, uint32_t limit_offset) FL_NOEXCEPT
 
static int32_t ilog (int32 n) FL_NOEXCEPT
 
static void imdct_step3_inner_r_loop (int32_t lim, float *e, int32_t d0, int32_t k_off, float *A, int32_t k1) FL_NOEXCEPT
 
static void imdct_step3_inner_s_loop (int32_t n, float *e, int32_t i_off, int32_t k_off, float *A, int32_t a_off, int32_t k0) FL_NOEXCEPT
 
static void imdct_step3_inner_s_loop_ld654 (int32_t n, float *e, int32_t i_off, float *A, int32_t base_n) FL_NOEXCEPT
 
static void imdct_step3_iter0_loop (int32_t n, float *e, int32_t i_off, int32_t k_off, float *A) FL_NOEXCEPT
 
static int32_t include_in_sort (Codebook *c, uint8 len) FL_NOEXCEPT
 
static int32_t init_blocksize (vorb *f, int32_t b, int32_t n) FL_NOEXCEPT
 
static void inverse_mdct (float *buffer, int32_t n, vorb *f, int32_t blocktype) FL_NOEXCEPT
 
static int32_t is_whole_packet_present (stb_vorbis *f) FL_NOEXCEPT
 
FL_ALWAYS_INLINE void iter_54 (float *z) FL_NOEXCEPT
 
double ldexp (double value, int exp) FL_NOEXCEPT
 
double log (double value) FL_NOEXCEPT
 
static int32_t lookup1_values (int32_t entries, int32_t dim) FL_NOEXCEPT
 
static void * make_block_array (void *mem, int32_t count, int32_t size) FL_NOEXCEPT
 
void * malloc (size_t size)
 
static int32_t maybe_start_packet (vorb *f) FL_NOEXCEPT
 
int memcmp (const void *s1, const void *s2, size_t n) FL_NOEXCEPT
 
void * memcpy (void *dest, const void *src, size_t n) FL_NOEXCEPT
 
void * memset (void *s, int c, size_t n) FL_NOEXCEPT
 
static void neighbors (uint16 *x, int32_t n, int32_t *plow, int32_t *phigh) FL_NOEXCEPT
 
static int32_t next_segment (vorb *f) FL_NOEXCEPT
 
static int32_t peek_decode_initial (vorb *f, int32_t *p_left_start, int32_t *p_left_end, int32_t *p_right_start, int32_t *p_right_end, int32_t *mode) FL_NOEXCEPT
 
static int point_compare (const void *p, const void *q) FL_NOEXCEPT
 
template<typename T>
enable_if< is_fixed_point< T >::value, T >::type pow (T base, T exp) FL_NOEXCEPT
 
static int32_t predict_point (int32_t x, int32_t x0, int32_t x1, int32_t y0, int32_t y1) FL_NOEXCEPT
 
FL_ALWAYS_INLINE void prep_huffman (vorb *f) FL_NOEXCEPT
 
void qsort (void *base, size_t nmemb, size_t size, qsort_compare_fn compar)
 
static int32_t residue_decode (vorb *f, Codebook *book, float *target, int32_t offset, int32_t n, int32_t rtype) FL_NOEXCEPT
 
static int32_t seek_to_sample_coarse (stb_vorbis *f, uint32 sample_number) FL_NOEXCEPT
 
static int32_t set_file_offset (stb_vorbis *f, uint32_t loc) FL_NOEXCEPT
 
static void setup_free (vorb *f, void *p) FL_NOEXCEPT
 
static void * setup_malloc (vorb *f, int32_t sz) FL_NOEXCEPT
 
static void setup_temp_free (vorb *f, void *p, int32_t sz) FL_NOEXCEPT
 
static void * setup_temp_malloc (vorb *f, int32_t sz) FL_NOEXCEPT
 
template<typename T>
enable_if< is_fixed_point< T >::value, T >::type sin (T angle) FL_NOEXCEPT
 
static void skip (vorb *z, int32_t n) FL_NOEXCEPT
 
static float square (float x) FL_NOEXCEPT
 
static int32_t start_decoder (vorb *f) FL_NOEXCEPT
 
static int32_t start_packet (vorb *f) FL_NOEXCEPT
 
static int32_t start_page (vorb *f) FL_NOEXCEPT
 
static int32_t start_page_no_capturepattern (vorb *f) FL_NOEXCEPT
 
void stb_vorbis_close (stb_vorbis *p) FL_NOEXCEPT
 
int32_t stb_vorbis_decode_filename (const char *filename, int32_t *channels, int32_t *sample_rate, short **output)
 
int32_t stb_vorbis_decode_frame_pushdata (stb_vorbis *f, const uint8 *data, int32_t data_len, int32_t *channels, float ***output, int32_t *samples) FL_NOEXCEPT
 
int32_t stb_vorbis_decode_memory (const uint8 *mem, int32_t len, int32_t *channels, int32_t *sample_rate, short **output) FL_NOEXCEPT
 
int32_t stb_vorbis_decode_memory (const unsigned char *mem, int32_t len, int32_t *channels, int32_t *sample_rate, int16_t **output) FL_NOEXCEPT
 
void stb_vorbis_flush_pushdata (stb_vorbis *f) FL_NOEXCEPT
 
stb_vorbis_comment stb_vorbis_get_comment (stb_vorbis *f) FL_NOEXCEPT
 
int32_t stb_vorbis_get_error (stb_vorbis *f) FL_NOEXCEPT
 
uint32_t stb_vorbis_get_file_offset (stb_vorbis *f) FL_NOEXCEPT
 
int32_t stb_vorbis_get_frame_float (stb_vorbis *f, int32_t *channels, float ***output) FL_NOEXCEPT
 
int32_t stb_vorbis_get_frame_short (stb_vorbis *f, int32_t num_c, int16_t **buffer, int32_t num_samples) FL_NOEXCEPT
 
int32_t stb_vorbis_get_frame_short (stb_vorbis *f, int32_t num_c, short **buffer, int32_t num_samples) FL_NOEXCEPT
 
int32_t stb_vorbis_get_frame_short_interleaved (stb_vorbis *f, int32_t num_c, int16_t *buffer, int32_t num_shorts) FL_NOEXCEPT
 
int32_t stb_vorbis_get_frame_short_interleaved (stb_vorbis *f, int32_t num_c, short *buffer, int32_t num_shorts) FL_NOEXCEPT
 
stb_vorbis_info stb_vorbis_get_info (stb_vorbis *f) FL_NOEXCEPT
 
int32_t stb_vorbis_get_sample_offset (stb_vorbis *f) FL_NOEXCEPT
 
int32_t stb_vorbis_get_samples_float (stb_vorbis *f, int32_t channels, float **buffer, int32_t num_samples) FL_NOEXCEPT
 
int32_t stb_vorbis_get_samples_float_interleaved (stb_vorbis *f, int32_t channels, float *buffer, int32_t num_floats) FL_NOEXCEPT
 
int32_t stb_vorbis_get_samples_short (stb_vorbis *f, int32_t channels, int16_t **buffer, int32_t num_samples) FL_NOEXCEPT
 
int32_t stb_vorbis_get_samples_short (stb_vorbis *f, int32_t channels, short **buffer, int32_t len) FL_NOEXCEPT
 
int32_t stb_vorbis_get_samples_short_interleaved (stb_vorbis *f, int32_t channels, int16_t *buffer, int32_t num_shorts) FL_NOEXCEPT
 
int32_t stb_vorbis_get_samples_short_interleaved (stb_vorbis *f, int32_t channels, short *buffer, int32_t num_shorts) FL_NOEXCEPT
 
stb_vorbisstb_vorbis_open_file (fl::FILE *file, int32_t close_on_free, int32_t *error, const stb_vorbis_alloc *alloc)
 
stb_vorbisstb_vorbis_open_file_section (fl::FILE *file, int32_t close_on_free, int32_t *error, const stb_vorbis_alloc *alloc, uint32_t length)
 
stb_vorbisstb_vorbis_open_filename (const char *filename, int32_t *error, const stb_vorbis_alloc *alloc)
 
stb_vorbisstb_vorbis_open_memory (const unsigned char *data, int32_t len, int32_t *error, const stb_vorbis_alloc *alloc) FL_NOEXCEPT
 
stb_vorbisstb_vorbis_open_pushdata (const unsigned char *data, int32_t data_len, int32_t *data_used, int32_t *error, const stb_vorbis_alloc *alloc) FL_NOEXCEPT
 
int32_t stb_vorbis_seek (stb_vorbis *f, uint32_t sample_number) FL_NOEXCEPT
 
int32_t stb_vorbis_seek_frame (stb_vorbis *f, uint32_t sample_number) FL_NOEXCEPT
 
int32_t stb_vorbis_seek_start (stb_vorbis *f) FL_NOEXCEPT
 
uint32_t stb_vorbis_stream_length_in_samples (stb_vorbis *f) FL_NOEXCEPT
 
float stb_vorbis_stream_length_in_seconds (stb_vorbis *f) FL_NOEXCEPT
 
static int uint32_compare (const void *p, const void *q) FL_NOEXCEPT
 
static stb_vorbisvorbis_alloc (stb_vorbis *f) FL_NOEXCEPT
 
static int32_t vorbis_decode_initial (vorb *f, int32_t *p_left_start, int32_t *p_left_end, int32_t *p_right_start, int32_t *p_right_end, int32_t *mode) FL_NOEXCEPT
 
static int32_t vorbis_decode_packet (vorb *f, int32_t *len, int32_t *p_left, int32_t *p_right) FL_NOEXCEPT
 
static int32_t vorbis_decode_packet_rest (vorb *f, int32_t *len, Mode *m, int32_t left_start, int32_t left_end, int32_t right_start, int32_t right_end, int32_t *p_left) FL_NOEXCEPT
 
static void vorbis_deinit (stb_vorbis *p) FL_NOEXCEPT
 
static uint32 vorbis_find_page (stb_vorbis *f, uint32 *end, uint32 *last) FL_NOEXCEPT
 
static int32_t vorbis_finish_frame (stb_vorbis *f, int32_t len, int32_t left, int32_t right) FL_NOEXCEPT
 
static void vorbis_init (stb_vorbis *p, const stb_vorbis_alloc *z) FL_NOEXCEPT
 
static int32_t vorbis_pump_first_frame (stb_vorbis *f) FL_NOEXCEPT
 
static int32_t vorbis_search_for_page_pushdata (vorb *f, uint8 *data, int32_t data_len) FL_NOEXCEPT
 
static int32_t vorbis_validate (uint8 *data) FL_NOEXCEPT
 

Variables

static constexpr int8_t C = (PLAYBACK_LEFT | PLAYBACK_RIGHT | PLAYBACK_MONO)
 
static int8 channel_position [7][6]
 
static constexpr uint32_t CRC32_POLY = 0x04c11db7
 
static uint32 crc_table [256]
 
static constexpr int32_t DIVTAB_DENOM = 64
 
static constexpr int32_t DIVTAB_NUMER = 32
 
static constexpr int32_t EOP = -1
 
int8 integer_divide_table [DIVTAB_NUMER][DIVTAB_DENOM]
 
static constexpr int32_t INVALID_BITS = -1
 
static float inverse_db_table [256]
 
static constexpr int8_t L = (PLAYBACK_LEFT | PLAYBACK_MONO)
 
static constexpr int32_t MAX_BLOCKSIZE = (1 << MAX_BLOCKSIZE_LOG)
 
static constexpr int32_t MAX_BLOCKSIZE_LOG = 13
 
static constexpr uint8_t NO_CODE = 255
 
static uint8 ogg_page_header [4] = { 0x4f, 0x67, 0x67, 0x53 }
 
static constexpr uint8_t PAGEFLAG_continued_packet = 1
 
static constexpr uint8_t PAGEFLAG_first_page = 2
 
static constexpr uint8_t PAGEFLAG_last_page = 4
 
static constexpr int8_t PLAYBACK_LEFT = 2
 
static constexpr int8_t PLAYBACK_MONO = 1
 
static constexpr int8_t PLAYBACK_RIGHT = 4
 
static constexpr int8_t R = (PLAYBACK_RIGHT | PLAYBACK_MONO)
 
static constexpr uint32_t SAMPLE_unknown = 0xffffffff