audio: Bug fix: Avoid blocking when sending buffer

This commit is contained in:
Hajime Hoshi 2016-05-31 10:17:22 +09:00
parent 1ca76b64f7
commit 84bf1ddf5c

View File

@ -202,7 +202,7 @@ func NewPlayer(sampleRate, channelNum, bytesPerSample int) (*Player, error) {
bytesPerSample: bytesPerSample,
buffer: []byte{},
chErr: make(chan error),
chBuffer: make(chan []byte),
chBuffer: make(chan []byte, 8),
}
if err := jni.RunOnJVM(func(vm, env, ctx uintptr) error {
audioTrack := C.jobject(nil)