Handbook
Glossary
audio-source
Audio playback engine
»
Audio source protocol
Prev:
audio-rolloff ( source -- rolloff )
Vocabulary
audio
.
engine
Class description
A tuple class that trivially implements the
Audio source protocol
with accessors on its tuple slots.
•
position
provides the
audio-position
.
•
gain
provides the
audio-gain
.
•
velocity
provides the
audio-velocity
.
•
relative?
provides the
audio-relative?
value.
•
distance
provides the
audio-distance
.
•
rolloff
provides the
audio-rolloff
.
Definition
USING:
kernel
math
;
IN:
audio.engine
TUPLE:
audio-source
{
position
initial:
{
0.0 0.0 0.0
}
}
{
gain
float
initial:
1.0
}
{
velocity
initial:
{
0.0 0.0 0.0
}
}
{
relative?
boolean
initial:
f
}
{
distance
float
initial:
1.0
}
{
rolloff
float
initial:
1.0
}
;
Methods
USING:
accessors
audio.engine
;
M:
audio-source
audio-distance
distance>>
;
inline
USING:
accessors
audio.engine
;
M:
audio-source
audio-gain
gain>>
;
inline
USING:
accessors
audio.engine
;
M:
audio-source
audio-position
position>>
;
inline
USING:
accessors
audio.engine
;
M:
audio-source
audio-relative?
relative?>>
;
inline
USING:
accessors
audio.engine
;
M:
audio-source
audio-rolloff
rolloff>>
;
inline
USING:
accessors
audio.engine
;
M:
audio-source
audio-velocity
velocity>>
;
inline