Remove 8-bit handling in output, promote WAV/FLAC to 16 (#782)
Only the WAV and FLAC generators can generate 8-bit values, so it is more efficient and sane to just have those generators upscale to 16-bit signed (if necessary) in generation and simplify all the other Generators and Outputs.
This commit is contained in:
1 parent
724b6d606e
commit
058e131b26
29 files changed
+43
-163
No files matched your search
@@ -129,7 +129,6 @@ AudioOutputSPDIF::AudioOutputSPDIF(int dout_pin, int port, int dma_buf_count) {
|
||||
#endif
|
||||
i2sOn = true;
|
||||
mono = false;
|
||||
bps = 16;
|
||||
channels = 2;
|
||||
frame_num = 0;
|
||||
SetGain(1.0);
|
||||
@@ -208,14 +207,6 @@ bool AudioOutputSPDIF::SetRate(int hz) {
|
||||
return true;
|
||||
}
|
||||
|
||||
bool AudioOutputSPDIF::SetBitsPerSample(int bits) {
|
||||
if ((bits != 16) && (bits != 8)) {
|
||||
return false;
|
||||
}
|
||||
this->bps = bits;
|
||||
return true;
|
||||
}
|
||||
|
||||
bool AudioOutputSPDIF::SetChannels(int channels) {
|
||||
if ((channels < 1) || (channels > 2)) {
|
||||
return false;
|
||||
|
||||
Reference in new issue
Block a user