alsa_in/out: Use float to S32 conversion if requested
sample_move_d32u24_sS() converts into samples like 0x00****** but S32 format expects samples like 0x********. Therefore it will not use the full volume range when also using sample_move_d32u24_sS() for S32. Signed-off-by: Timo Wischer <twischer@de.adit-jv.com>
This commit is contained in:
parent
d017e1fffe
commit
148c8d8e6a
|
@ -95,9 +95,9 @@ typedef struct alsa_format {
|
|||
|
||||
alsa_format_t formats[] = {
|
||||
{ SND_PCM_FORMAT_FLOAT_LE, 4, sample_move_dS_floatLE, sample_move_floatLE_sSs, "float" },
|
||||
{ SND_PCM_FORMAT_S32, 4, sample_move_d32u24_sS, sample_move_dS_s32u24, "32bit" },
|
||||
{ SND_PCM_FORMAT_S32, 4, sample_move_d32_sS, sample_move_dS_s32, "32bit" },
|
||||
{ SND_PCM_FORMAT_S24_3LE, 3, sample_move_d24_sS, sample_move_dS_s24, "24bit - real" },
|
||||
{ SND_PCM_FORMAT_S24, 4, sample_move_d24_sS, sample_move_dS_s24, "24bit" },
|
||||
{ SND_PCM_FORMAT_S24, 4, sample_move_d32u24_sS, sample_move_dS_s32u24, "24bit" },
|
||||
{ SND_PCM_FORMAT_S16, 2, sample_move_d16_sS, sample_move_dS_s16, "16bit" }
|
||||
#ifdef __ANDROID__
|
||||
,{ SND_PCM_FORMAT_S16_LE, 2, sample_move_d16_sS, sample_move_dS_s16, "16bit little-endian" }
|
||||
|
|
|
@ -96,9 +96,9 @@ typedef struct alsa_format {
|
|||
|
||||
alsa_format_t formats[] = {
|
||||
{ SND_PCM_FORMAT_FLOAT_LE, 4, sample_move_dS_floatLE, sample_move_floatLE_sSs, "float" },
|
||||
{ SND_PCM_FORMAT_S32, 4, sample_move_d32u24_sS, sample_move_dS_s32u24, "32bit" },
|
||||
{ SND_PCM_FORMAT_S32, 4, sample_move_d32_sS, sample_move_dS_s32, "32bit" },
|
||||
{ SND_PCM_FORMAT_S24_3LE, 3, sample_move_d24_sS, sample_move_dS_s24, "24bit - real" },
|
||||
{ SND_PCM_FORMAT_S24, 4, sample_move_d24_sS, sample_move_dS_s24, "24bit" },
|
||||
{ SND_PCM_FORMAT_S24, 4, sample_move_d32u24_sS, sample_move_dS_s32u24, "24bit" },
|
||||
{ SND_PCM_FORMAT_S16, 2, sample_move_d16_sS, sample_move_dS_s16, "16bit" }
|
||||
#ifdef __ANDROID__
|
||||
,{ SND_PCM_FORMAT_S16_LE, 2, sample_move_d16_sS, sample_move_dS_s16, "16bit little-endian" }
|
||||
|
|
Loading…
Reference in New Issue