public class LM_SoundEventServer extends EventServer
| Modifier and Type | Field and Description |
|---|---|
protected java.lang.String |
agentCompName
The agent comp name.
|
protected java.lang.String |
agentName
The agent name.
|
(package private) javax.sound.midi.MidiChannel |
channel
The channel.
|
(package private) java.util.ArrayList<Event> |
events
The events.
|
private int |
lastMidiNote
The last midi note.
|
(package private) LM_World.Sound[][] |
newSounds
The new sounds.
|
(package private) javax.sound.midi.Receiver |
rcv
The rcv.
|
(package private) javax.sound.midi.Synthesizer |
synth
The synth.
|
(package private) LM_World |
world
The world.
|
actuators, clock, comm, earlyEvents, envAgent, eventHandlers, frameTime, happeningFrame, myActuator, mySensor, parameters, period, periodDeadline, receiveDeadline, receivingFrame, sendDeadline, sensors, startTime, waitTime, workingFrame| Constructor and Description |
|---|
LM_SoundEventServer() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
configure()
User-implemented method that configures the component, setting up user parameters and essential properties.
|
boolean |
finit()
User-implemented finalization method, called by stop().
|
boolean |
init()
User-implemented initialization method, called by start().
|
void |
process()
Método chamado para efetuar algum processamento sobre os eventos recebidos, e enviar eventos em seguida.
|
protected Event |
processAction(Event evt)
Método chamado para enviar um evento pelo process().
|
void |
processSense(Event evt)
Método chamado ao receber um evento.
|
private void |
propagateSound(LM_World.Sound sound,
int i,
int j,
int note,
int amplitude,
int direction)
Propagate sound.
|
private void |
setSound(int x,
int y,
int note,
int amplitude,
int direction)
Sets the sound.
|
act, actuatorDeregistered, actuatorRegistered, addOutputEvent, addParameter, addParameters, createMemory, deregisterEventHandler, getAddress, getCommType, getEventExchange, getEventType, getParameter, getParameter, getParameters, parameterUpdate, processCommand, receiveCommand, registerEventHandler, searchRegisteredEventHandler, sendCommand, sendEvent, sense, senseEarlyEvents, sensorDeregistered, sensorRegistered, setCommType, setEnvAgent, setEventExchange, setEventExchange, setEventType, setParameters, start, stopLM_World world
LM_World.Sound[][] newSounds
protected java.lang.String agentName
protected java.lang.String agentCompName
private int lastMidiNote
java.util.ArrayList<Event> events
javax.sound.midi.Synthesizer synth
javax.sound.midi.MidiChannel channel
javax.sound.midi.Receiver rcv
public boolean configure()
LifeCyclepublic boolean init()
LifeCycleinit in interface LifeCycleinit in class EventServerpublic boolean finit()
LifeCyclefinit in interface LifeCyclefinit in class EventServerprivate void setSound(int x,
int y,
int note,
int amplitude,
int direction)
x - the xy - the ynote - the noteamplitude - the amplitudedirection - the directionprivate void propagateSound(LM_World.Sound sound, int i, int j, int note, int amplitude, int direction)
sound - the soundi - the ij - the jnote - the noteamplitude - the amplitudedirection - the directionpublic void process()
EventServerprocess in class EventServerpublic void processSense(Event evt)
EventServerprocessSense in class EventServerevt - the evtprotected Event processAction(Event evt)
EventServerprocessAction in class EventServerevt - the evt