# # vim:sw=2 ts=8:et sta # # NOTE THAT ALL OF THESE TUNABLES ARE PURELY ADMINISTRATIVE AND REQUIRE # ROOT PRIVILEGE. TUNABLES ARE ~*~*____EVIL_____*~*~ . # General: ------- 1) hw.snd.latency_profile purpose: Define sets of buffering latency conversion tables for "hw.snd.latency" / SNDCTL_DSP_POLICY ioctl. hw.snd.latency / SNDCTL_DSP_POLICY ioctl. Lower settings = low latency profile, possible underruns if the application cannot keep up with rapid irq especially during high workload. Higher settings = high latency, less or no underruns, smoother playback during high workload. kenv tunable: "hw.snd.latency_profile" sysctl tunable: "hw.snd.latency_profile" min: 0 (aggresive low latency profile) max: 1 (moderate/safe latency profile) default: 1 2) hw.snd.latency purpose: Default latency settings. Applications that doesn't explicitly request blocksize / fragments eg: mplayer, xine, mpg123/321, etc. Same as "hw.snd.latency_profile", with finer latency granulity. kenv tunable: "hw.snd.latency" sysctl tunable: "hw.snd.latency" min: 0 (lowest latency) max: 10 (highest latency) default: 5 3) hw.snd.report_soft_formats purpose: refer sound(4) Applications using SNDCTL_DSP_GETFMTS ioctl. kenv tunable: NONE sysctl tunable: "hw.snd.report_soft_formats" min / max: zero (false) or nonzero (true) default: 1 (true) 4) hw.snd.feeder_buffersize purpose: Size of temporary buffer for various feeder converter eg: feeder_rate, feeder_formats*, etc. kenv tunable: "hw.snd.feeder_buffersize" sysctl tunable: "hw.snd.feeder_buffersize" (readonly) min: 2048 max: 131072 default: 65536 5) hw.snd.feeder_rate_round purpose: Sample rate rounding threshold, to avoid large prime division at the cost of accuracy. All requested sample rate will be rounded to the nearest threshold value eg: 44113 -> 44100 (threshold = 25). kenv tunable: "hw.snd.feeder_rate_round" sysctl tunable: "hw.snd.feeder_rate_round" min: 0 (disable) max: 500 default: 25 6) hw.snd.feeder_rate_max purpose: Maximum allowable sample rate. kenv tunable: "hw.snd.feeder_rate_max" sysctl tunable: "hw.snd.feeder_rate_max" min: 2 _AND_ larger than hw.snd.feeder_rate_min max: 2016000 ~ (48000 * 42) default: 2016000 7) hw.snd.feeder_rate_min: 1 purpose: Minimum allowable sample rate. kenv tunable: "hw.snd.feeder_rate_min" sysctl tunable: "hw.snd.feeder_rate_min" min: 1 max: 2015999 _AND_ smaller than hw.snd.feeder_rate_max default: 1 8) hw.snd.verbose purpose: Verbosity level for sndstat / debug messages. kenv tunable: "hw.snd.verbose" sysctl tunable: "hw.snd.verbose" min: 0 max: 4 default: 1 9) hw.snd.maxautovchans purpose: Maximum vchan that will be created automatically. kenv tunable: "hw.snd.maxautovchans" sysctl tunable: "hw.snd.maxautovchans" min: 0 (disable) max: 255 10) hw.snd.default_unit purpose: Default soundcard for system with multiple soundcards. kenv tunable: "hw.snd.default_unit" sysctl tunable: "hw.snd.default_unit" min: 0 (first soundcard) max: (total soundcards) - 1 Device Specific: --------------- 1) dev.pcm..buffersize purpose: Allocated hardware DMA buffer. The smaller, the better/lower latency at the cost of higher irq rate. kenv tunable: "hint.pcm..buffersize" sysctl tunable: "dev.pcm..buffersize" (readonly) min: 4096 max: 65536 default: driver specific 2) dev.pcm..vchans purpose: Static vchan allocation kenv tunable: NONE sysctl tunable: "dev.pcm..vchans" min: 0 (disable vchan) max: 255 default: 1 3) dev.pcm..vchanrate purpose: Sample rate speed for vchan mixing. All playback path will be converted to this sample rate before mixing process. kenv tunable: "hint.pcm..vchanrate" sysctl tunable: "dev.pcm..vchanrate" min: driver specific minspeed max: driver specific maxspeed default: 48000 or driver specific maximum supported sample rate, whichever less. Special Note: if "hw.snd.feeder_rate_round" is 0, there will be no min / max limitation :) 4) dev.pcm..vchanformat purpose: Format for vchan mixing. All playback path will be converted to this format before mixing process. kenv tunable: "hint.pcm..vchanformat" sysctl tunable: "dev.pcm..vchanformat" min: - max: - default: s16le (sign 16 bit little endian) Choices: u8, s8, s16le, s16be, u16le .. etc.. as long as it can be abbreviated. "8", "16", "24" and "32" are defined as "u8", "s16le", "s24le" and "s32le" respectively for simplification.