Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrInvalidJoypadCode = errors.New("Invalid joypad code")
ErrInvalidJoypadCode returned for an invalid joypad code
Functions ¶
Types ¶
type ControlEvent ¶
type ControlEvent byte
ControlEvent is a key event that is not one of the 8 gameboy key events
const ControlEventMute ControlEvent = 3
ControlEventMute signals a mute request
const ControlEventPause ControlEvent = 2
ControlEventPause signals a pause request
const ControlEventQuit ControlEvent = 0
ControlEventQuit signals a quit request
const ControlEventReset ControlEvent = 1
ControlEventReset signals a reset request
type Input ¶
type Input struct {
// contains filtered or unexported fields
}
Input is a Keystroker implementer
func (*Input) AddKeyEvent ¶
AddKeyEvent to queue
func (*Input) GetKeystroke ¶
GetKeystroke returns a gameboy key code
func (*Input) WaitForKeyEvents ¶
func (i *Input) WaitForKeyEvents() ControlEvent
WaitForKeyEvents blocks until a key is pressed or unpressed
type Sound ¶
type Sound struct {
// contains filtered or unexported fields
}
Sound plays samples from the apu
func (*Sound) BufferSize ¶
BufferSize is the size of the samples buffer
func (*Sound) SamplesCount ¶
SamplesCount return the current number of samples in buffer
Click to show internal directories.
Click to hide internal directories.