Hi, I'd like to know our audio specification. i.e., what encoding the kernel accepts?
This table shows the status of current implementation, not current documentation. audioplay(1) audio(4) AUDIO_GETENC(*1) ------------------------------------------------------------ s8 accept accept not support s16{be,le} accept accept supported(*2) s24{be,le} accept reject not support s32{be,le} accept accept not support u8 accept accept not support u16{be,le} ? ? supported by emulation u24{be,le} ? reject? not support u32{be,le} ? ? not support mulaw accept accept(ifdef) supported by emulation note: *1 The mismatch of AUDIO_GETENC is described in PR/52585. *2 On LE, s16le is supported natively and s16be is by emulation. On BE, s16be is supported natively and s16le is by emulation. Even if the hardware does not support slinear16 natively. memo: o I confirmed that audioplay(1) accepts u8.wav, s{16,24,32}le.wav, s8.au, s{16,24,32}be.au, and mulaw.au. But I don't know about u{16,24,32}. o I confirmed that audio(4) rejects s24{le,be} by audioplay(1). Is this result expected (= well-planned)? I don't say that "audio(4) does not accpet 24bit, let's add it." Before rev1.26, auconv.c supported 8/16bit only. After rev1.27, auconv.c supports {8,16,24/24,24/32,32} but mostly broken (see PR/52586) but no one noticed it because most of them was dead code. It's better to clarify the specification before implementing. I'm not an audio man, so I don't know details but, Will audio(4) support ulinear{16,24,32} or slinear24 ? i.e., is it worth to pay the maintainance cost to keep supporting it? Thanks, --- Tetsuya Isaki <is...@pastel-flower.jp / is...@netbsd.org>