mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-12-24 02:38:53 +01:00
Remove audio/internal.Start()
This commit is contained in:
parent
ea78b31414
commit
d321dfe7fd
@ -20,11 +20,11 @@ import (
|
||||
|
||||
// SampleRate returns the sampling frequency (e.g. 44100).
|
||||
func SampleRate() int {
|
||||
return audio.SampleRate
|
||||
return internal.SampleRate
|
||||
}
|
||||
|
||||
// MaxChannel is a max number of channels.
|
||||
var MaxChannel = audio.MaxChannel
|
||||
var MaxChannel = internal.MaxChannel
|
||||
|
||||
// Play appends the given data to the given channel.
|
||||
//
|
||||
@ -33,7 +33,7 @@ var MaxChannel = audio.MaxChannel
|
||||
//
|
||||
// This function is useful to play SE or a note of PCM synthesis immediately.
|
||||
func Play(channel int, l []int16, r []int16) bool {
|
||||
return audio.Play(channel, l, r)
|
||||
return internal.Play(channel, l, r)
|
||||
}
|
||||
|
||||
// Queue queues the given data to the given channel.
|
||||
@ -43,10 +43,10 @@ func Play(channel int, l []int16, r []int16) bool {
|
||||
//
|
||||
// This function is useful to play streaming data.
|
||||
func Queue(channel int, l []int16, r []int16) {
|
||||
audio.Queue(channel, l, r)
|
||||
internal.Queue(channel, l, r)
|
||||
}
|
||||
|
||||
// IsPlaying returns a boolean value which indicates if the channel buffer has data to play.
|
||||
func IsPlaying(channel int) bool {
|
||||
return audio.IsPlaying(channel)
|
||||
return internal.IsPlaying(channel)
|
||||
}
|
||||
|
@ -12,7 +12,7 @@
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
package audio
|
||||
package internal
|
||||
|
||||
import (
|
||||
"sync"
|
||||
@ -46,9 +46,6 @@ func init() {
|
||||
|
||||
func Init() {
|
||||
initialize()
|
||||
}
|
||||
|
||||
func Start() {
|
||||
start()
|
||||
}
|
||||
|
||||
|
@ -14,7 +14,7 @@
|
||||
|
||||
// +build js
|
||||
|
||||
package audio
|
||||
package internal
|
||||
|
||||
import (
|
||||
"github.com/gopherjs/gopherjs/js"
|
||||
|
@ -14,7 +14,7 @@
|
||||
|
||||
// +build !js
|
||||
|
||||
package audio
|
||||
package internal
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
|
@ -15,7 +15,7 @@
|
||||
package ebiten
|
||||
|
||||
import (
|
||||
"github.com/hajimehoshi/ebiten/exp/audio/internal"
|
||||
audio "github.com/hajimehoshi/ebiten/exp/audio/internal"
|
||||
"github.com/hajimehoshi/ebiten/internal/graphics"
|
||||
"github.com/hajimehoshi/ebiten/internal/graphics/internal/opengl"
|
||||
"github.com/hajimehoshi/ebiten/internal/ui"
|
||||
@ -30,7 +30,6 @@ func init() {
|
||||
glContext = opengl.NewContext()
|
||||
})
|
||||
audio.Init()
|
||||
audio.Start()
|
||||
}
|
||||
|
||||
// IsKeyPressed returns a boolean indicating whether key is pressed.
|
||||
|
Loading…
Reference in New Issue
Block a user