(sampleRate int, channelCount int, format mux.Format, bufferSizeInBytes int)
| 47 | var theContext *context |
| 48 | |
| 49 | func newContext(sampleRate int, channelCount int, format mux.Format, bufferSizeInBytes int) (*context, chan struct{}, error) { |
| 50 | ready := make(chan struct{}) |
| 51 | close(ready) |
| 52 | |
| 53 | c := &context{ |
| 54 | mux: mux.New(sampleRate, channelCount, format), |
| 55 | } |
| 56 | theContext = c |
| 57 | C.oto_OpenAudioProxy(C.int(sampleRate), C.int(channelCount), C.int(bufferSizeInBytes)) |
| 58 | |
| 59 | return c, ready, nil |
| 60 | } |
| 61 | |
| 62 | func (c *context) Suspend() error { |
| 63 | // Do nothing so far. |
nothing calls this directly
no test coverage detected
searching dependent graphs…