FreeBSD kernel sound device code
|
#include <dev/sound/pcm/sound.h>
#include <dev/sound/pcm/pcm.h>
#include "feeder_if.h"
#include "snd_fxdiv_gen.h"
Go to the source code of this file.
Data Structures | |
struct | feed_matrix_info |
Macros | |
#define | SND_USE_FXDIV |
#define | FEEDMATRIX_RESERVOIR (SND_CHN_MAX * PCM_32_BPS) |
#define | SND_CHN_T_EOF 0x00e0fe0f |
#define | SND_CHN_T_NULL 0x0e0e0e0e |
#define | FEEDMATRIX_CLIP_CHECK(...) |
#define | FEEDMATRIX_DECLARE(SIGN, BIT, ENDIAN) |
#define | FEEDMATRIX_ENTRY(SIGN, BIT, ENDIAN) |
#define | FEEDMATRIX_ATTN_SHIFT 16 |
#define | SND_CHN_OSS_VALIDMASK |
#define | SND_CHN_OSS_MAX 8 |
#define | SND_CHN_OSS_BEGIN CHID_L |
#define | SND_CHN_OSS_END CHID_RR |
Typedefs | |
typedef void(* | feed_matrix_t) (struct feed_matrix_info *, uint8_t *, uint8_t *, uint32_t) |
Variables | |
static struct pcmchan_matrix | feeder_matrix_maps [SND_CHN_MATRIX_MAX] |
static int | feeder_matrix_default_ids [9] |
struct { | |
uint32_t format | |
feed_matrix_t apply | |
} | feed_matrix_tab [] |
static struct pcm_feederdesc | feeder_matrix_desc [] |
static kobj_method_t | feeder_matrix_methods [] |
static int | snd_chn_to_oss [SND_CHN_T_MAX] |
static int | oss_to_snd_chn [SND_CHN_OSS_END+1] |
#define FEEDMATRIX_ATTN_SHIFT 16 |
#define FEEDMATRIX_CLIP_CHECK | ( | ... | ) |
Definition at line 115 of file feeder_matrix.c.
#define FEEDMATRIX_DECLARE | ( | SIGN, | |
BIT, | |||
ENDIAN | |||
) |
Definition at line 124 of file feeder_matrix.c.
#define FEEDMATRIX_ENTRY | ( | SIGN, | |
BIT, | |||
ENDIAN | |||
) |
Definition at line 198 of file feeder_matrix.c.
#define FEEDMATRIX_RESERVOIR (SND_CHN_MAX * PCM_32_BPS) |
Definition at line 60 of file feeder_matrix.c.
#define SND_CHN_OSS_BEGIN CHID_L |
Definition at line 724 of file feeder_matrix.c.
#define SND_CHN_OSS_END CHID_RR |
Definition at line 725 of file feeder_matrix.c.
#define SND_CHN_OSS_MAX 8 |
Definition at line 723 of file feeder_matrix.c.
#define SND_CHN_OSS_VALIDMASK |
Definition at line 717 of file feeder_matrix.c.
#define SND_CHN_T_EOF 0x00e0fe0f |
Definition at line 62 of file feeder_matrix.c.
#define SND_CHN_T_NULL 0x0e0e0e0e |
Definition at line 63 of file feeder_matrix.c.
#define SND_USE_FXDIV |
Definition at line 54 of file feeder_matrix.c.
typedef void(* feed_matrix_t) (struct feed_matrix_info *, uint8_t *, uint8_t *, uint32_t) |
Definition at line 67 of file feeder_matrix.c.
|
static |
Definition at line 468 of file feeder_matrix.c.
References feed_matrix_info::apply, b, c, feed_matrix_info::chn, count, pcm_feeder::data, feed_matrix_info::ialign, feed_matrix_info::matrix, feed_matrix_info::oalign, feed_matrix_info::reservoir, SND_CHN_T_EOF, pcm_feeder::source, source, and src.
|
static |
Definition at line 454 of file feeder_matrix.c.
References pcm_feeder::data, and free.
|
static |
Definition at line 397 of file feeder_matrix.c.
References AFMT_ALIGN, AFMT_BPS, AFMT_ENCODING, feed_matrix_info::apply, feed_matrix_info::bps, pcm_feeder::data, pcm_feeder::desc, feed_matrix_setup(), feed_matrix_tab, feeder_format_read_op(), feeder_format_write_op(), feeder_matrix_format_map(), free, feed_matrix_info::ialign, pcm_feederdesc::in, feed_matrix_info::in, feed_matrix_info::oalign, pcm_feederdesc::out, and feed_matrix_info::out.
|
static |
Definition at line 231 of file feeder_matrix.c.
References feed_matrix_info::chn, feed_matrix_info::matrix, feed_matrix_info::mul, feed_matrix_info::shift, and SND_CHN_T_EOF.
Referenced by feed_matrix_setup().
|
static |
Definition at line 294 of file feeder_matrix.c.
References AFMT_CHANNEL, feed_matrix_info::bps, pcmchan_matrix::channels, feed_matrix_info::chn, feed_matrix_reset(), FEEDMATRIX_ATTN_SHIFT, pcmchan_matrix::id, feed_matrix_info::in, pcmchan_matrix::map, pcmchan_matrix::mask, feed_matrix_info::matrix, pcmchan_matrix::members, mul, feed_matrix_info::mul, pcmchan_matrix::offset, feed_matrix_info::out, feed_matrix_info::shift, SND_CHN_MATRIX_1_0, SND_CHN_MATRIX_BEGIN, SND_CHN_MATRIX_END, SND_CHN_MAX, SND_CHN_MIN, SND_CHN_T_BEGIN, SND_CHN_T_END, SND_CHN_T_EOF, SND_CHN_T_MASK_FC, SND_CHN_T_MASK_FL, SND_CHN_T_MASK_FR, SND_CHN_T_MAX, SND_CHN_T_NULL, SND_CHN_T_STEP, and pcmchan_matrix::type.
Referenced by feed_matrix_init(), and feeder_matrix_setup().
FEEDER_DECLARE | ( | feeder_matrix | , |
NULL | |||
) |
int feeder_matrix_compare | ( | struct pcmchan_matrix * | m_in, |
struct pcmchan_matrix * | m_out | ||
) |
Definition at line 673 of file feeder_matrix.c.
References pcmchan_matrix::channels, pcmchan_matrix::ext, pcmchan_matrix::map, pcmchan_matrix::mask, pcmchan_matrix::members, pcmchan_matrix::offset, SND_CHN_T_END, SND_CHN_T_MAX, and pcmchan_matrix::type.
Referenced by feeder_chain().
struct pcmchan_matrix * feeder_matrix_default_channel_map | ( | uint32_t | ch | ) |
Definition at line 575 of file feeder_matrix.c.
References pcmchan_matrix::channels, feeder_matrix_default_ids, feeder_matrix_maps, SND_CHN_MATRIX_BEGIN, and SND_CHN_MATRIX_END.
Referenced by dsp_ioctl(), feed_volume_init(), feed_volume_set(), and feeder_matrix_default_format().
uint32_t feeder_matrix_default_format | ( | uint32_t | format | ) |
Definition at line 591 of file feeder_matrix.c.
References AFMT_CHANNEL, AFMT_EXTCHANNEL, pcmchan_matrix::channels, pcmchan_matrix::ext, feeder_matrix_default_channel_map(), feeder_matrix_maps, format, m, SND_CHN_MATRIX_BEGIN, SND_CHN_MATRIX_END, and SND_FORMAT.
Referenced by uaudio_chan_fill_info_sub().
int feeder_matrix_default_id | ( | uint32_t | ch | ) |
Definition at line 560 of file feeder_matrix.c.
References feeder_matrix_default_ids, feeder_matrix_maps, SND_CHN_MATRIX_BEGIN, SND_CHN_MATRIX_END, and SND_CHN_MATRIX_UNKNOWN.
int feeder_matrix_format_id | ( | uint32_t | format | ) |
Definition at line 619 of file feeder_matrix.c.
References AFMT_CHANNEL, AFMT_EXTCHANNEL, pcmchan_matrix::channels, pcmchan_matrix::ext, feeder_matrix_maps, format, SND_CHN_MATRIX_BEGIN, SND_CHN_MATRIX_END, and SND_CHN_MATRIX_UNKNOWN.
struct pcmchan_matrix * feeder_matrix_format_map | ( | uint32_t | format | ) |
Definition at line 640 of file feeder_matrix.c.
References AFMT_CHANNEL, AFMT_EXTCHANNEL, pcmchan_matrix::channels, pcmchan_matrix::ext, feeder_matrix_maps, format, SND_CHN_MATRIX_BEGIN, and SND_CHN_MATRIX_END.
Referenced by feed_matrix_init(), feeder_chain(), uaudio_chan_getmatrix(), and vchan_getmatrix().
struct pcmchan_matrix * feeder_matrix_id_map | ( | int | id | ) |
Definition at line 660 of file feeder_matrix.c.
References feeder_matrix_maps, and SND_CHN_MATRIX_END.
Referenced by chn_init().
int feeder_matrix_oss_get_channel_order | ( | struct pcmchan_matrix * | m, |
unsigned long long * | map | ||
) |
Definition at line 742 of file feeder_matrix.c.
References pcmchan_matrix::channels, m, pcmchan_matrix::map, pcmchan_matrix::mask, SND_CHN_OSS_MAX, SND_CHN_OSS_VALIDMASK, SND_CHN_T_MAX, snd_chn_to_oss, and pcmchan_matrix::type.
Referenced by chn_oss_getorder().
int feeder_matrix_oss_set_channel_order | ( | struct pcmchan_matrix * | m, |
unsigned long long * | map | ||
) |
Definition at line 772 of file feeder_matrix.c.
References pcmchan_matrix::channels, pcmchan_matrix::ext, m, pcmchan_matrix::map, pcmchan_matrix::mask, pcmchan_matrix::offset, oss_to_snd_chn, SND_CHN_OSS_BEGIN, SND_CHN_OSS_END, SND_CHN_OSS_MAX, SND_CHN_OSS_VALIDMASK, SND_CHN_T_MASK_LF, SND_CHN_T_MAX, and pcmchan_matrix::type.
Referenced by chn_oss_setorder().
int feeder_matrix_setup | ( | struct pcm_feeder * | f, |
struct pcmchan_matrix * | m_in, | ||
struct pcmchan_matrix * | m_out | ||
) |
Definition at line 542 of file feeder_matrix.c.
References pcm_feeder::data, pcm_feeder::desc, feed_matrix_setup(), FEEDER_MATRIX, and pcm_feederdesc::type.
Referenced by feeder_build_matrix().
SND_DECLARE_FILE | ( | "$FreeBSD$" | ) |
feed_matrix_t apply |
Definition at line 206 of file feeder_matrix.c.
const struct { ... } feed_matrix_tab[] |
Referenced by feed_matrix_init().
|
static |
Definition at line 102 of file feeder_matrix.c.
Referenced by feeder_matrix_default_channel_map(), and feeder_matrix_default_id().
|
static |
Definition at line 526 of file feeder_matrix.c.
|
static |
Definition at line 86 of file feeder_matrix.c.
Referenced by feeder_matrix_default_channel_map(), feeder_matrix_default_format(), feeder_matrix_default_id(), feeder_matrix_format_id(), feeder_matrix_format_map(), and feeder_matrix_id_map().
|
static |
Definition at line 531 of file feeder_matrix.c.
uint32_t format |
Definition at line 205 of file feeder_matrix.c.
Referenced by feeder_matrix_default_format(), feeder_matrix_format_id(), and feeder_matrix_format_map().
|
static |
Definition at line 727 of file feeder_matrix.c.
Referenced by feeder_matrix_oss_set_channel_order().
|
static |
Definition at line 706 of file feeder_matrix.c.
Referenced by feeder_matrix_oss_get_channel_order().