jogramming / dca

Go implementation for the DCA audio format
BSD 3-Clause "New" or "Revised" License
75 stars 60 forks source link

[Request] Changing volume mid-stream #10

Closed d3nw0 closed 5 years ago

d3nw0 commented 5 years ago

is this possible?

d3nw0 commented 5 years ago

ok i figured this out, but ended up making my own library. basically you need to change the PCM values while encoding.

for k := range buf {
    buf[k] = int16(math.Floor(float64(buf[k]) * volume))
}