mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2025-01-13 12:32:05 +01:00
audio: Fix compile error on Windows
This commit is contained in:
parent
3cbcda1bb0
commit
76a2dbad26
@ -28,7 +28,6 @@ import (
|
|||||||
"fmt"
|
"fmt"
|
||||||
"io"
|
"io"
|
||||||
"runtime"
|
"runtime"
|
||||||
"time"
|
|
||||||
"unsafe"
|
"unsafe"
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -75,7 +74,10 @@ func releaseSemaphore() {
|
|||||||
<-sem
|
<-sem
|
||||||
}
|
}
|
||||||
|
|
||||||
func startPlaying(src io.Reader, sampleRate int) error {
|
type player struct {
|
||||||
|
}
|
||||||
|
|
||||||
|
func startPlaying(src io.Reader, sampleRate int) (*player, error) {
|
||||||
const numChannels = 2
|
const numChannels = 2
|
||||||
const bitsPerSample = 16
|
const bitsPerSample = 16
|
||||||
const numBlockAlign = numChannels * bitsPerSample / 8
|
const numBlockAlign = numChannels * bitsPerSample / 8
|
||||||
@ -123,5 +125,5 @@ func startPlaying(src io.Reader, sampleRate int) error {
|
|||||||
}
|
}
|
||||||
// TODO: Finalize the wave handler
|
// TODO: Finalize the wave handler
|
||||||
}()
|
}()
|
||||||
return nil
|
return &player{}, nil
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user