Package jmri.jmrit.vsdecoder
Class DieselSound
- java.lang.Object
-
- jmri.jmrit.vsdecoder.VSDSound
-
- jmri.jmrit.vsdecoder.EngineSound
-
- jmri.jmrit.vsdecoder.DieselSound
-
class DieselSound extends EngineSound
Diesel Sound initial version.
This file is part of JMRI.JMRI is free software; you can redistribute it and/or modify it under the terms of version 2 of the GNU General Public License as published by the Free Software Foundation. See the "COPYING" file for a copy of this license.
JMRI is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
-
-
Field Summary
Fields Modifier and Type Field Description (package private) intcurrent_notch(package private) java.util.HashMap<java.lang.Integer,SoundBite>notch_sounds(package private) NotchTransitionnotch_transition(package private) SoundBiteshutdown_sound(package private) SoundBitestart_sound(package private) java.util.ArrayList<NotchTransition>transition_sounds-
Fields inherited from class jmri.jmrit.vsdecoder.EngineSound
auto_start_engine, engine_gain, engine_pane, engine_rd, exponent, fade_in_time, fade_length, fade_out_time, is_auto_start, sleep_interval
-
Fields inherited from class jmri.jmrit.vsdecoder.VSDSound
BufSysNamePrefix, BufUserNamePrefix, default_exponent, default_gain, default_reference_distance, default_sleep_interval, gain, is_tunnel, myposition, name, SrcSysNamePrefix, SrcUserNamePrefix, t, tunnel_volume, volume
-
-
Constructor Summary
Constructors Constructor Description DieselSound(java.lang.String name)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidchangeNotch(int new_notch)org.jdom2.ElementgetXml()protected voidhandleNotchTimerPop(java.awt.event.ActionEvent e)voidloop()voidmute(boolean m)voidplay()voidsetPosition(PhysicalLocation p)voidsetVolume(float v)voidsetXml(org.jdom2.Element e, VSDFile vf)voidshutdown()voidstartEngine()voidstop()voidstopEngine()-
Methods inherited from class jmri.jmrit.vsdecoder.EngineSound
autoStartCheck, calcEngineNotch, calcEngineNotch, changeLocoDirection, fadeIn, fadeOut, functionKey, getActualSpeed, getBuffersFreeState, getFadeInTime, getFadeOutTime, getFirstSpeed, handleSpeedChange, isEngineStarted, setActualSpeed, setBuffersFreeState, setEngineStarted, setFadeInTime, setFadeInTime, setFadeOutTime, setFadeOutTime, setFirstSpeed, setXMLAutoStart, setXMLEngineReferenceDistance, setXMLExponent, setXMLGain, setXMLReferenceDistance, setXMLSleepInterval, speedCurve
-
Methods inherited from class jmri.jmrit.vsdecoder.VSDSound
attachSourcesToEffects, changeThrottle, checkForFreeBuffer, detachSourcesToEffects, getGain, getName, getPosition, getTunnel, newTimer, setGain, setName, setTunnel, setXml
-
-
-
-
Field Detail
-
notch_sounds
java.util.HashMap<java.lang.Integer,SoundBite> notch_sounds
-
transition_sounds
java.util.ArrayList<NotchTransition> transition_sounds
-
start_sound
SoundBite start_sound
-
shutdown_sound
SoundBite shutdown_sound
-
notch_transition
NotchTransition notch_transition
-
current_notch
int current_notch
-
-
Constructor Detail
-
DieselSound
public DieselSound(java.lang.String name)
-
-
Method Detail
-
play
public void play()
- Overrides:
playin classEngineSound
-
loop
public void loop()
- Overrides:
loopin classEngineSound
-
stop
public void stop()
- Overrides:
stopin classEngineSound
-
changeNotch
public void changeNotch(int new_notch)
- Overrides:
changeNotchin classVSDSound
-
handleNotchTimerPop
protected void handleNotchTimerPop(java.awt.event.ActionEvent e)
-
startEngine
public void startEngine()
- Overrides:
startEnginein classEngineSound
-
stopEngine
public void stopEngine()
- Overrides:
stopEnginein classEngineSound
-
shutdown
public void shutdown()
- Overrides:
shutdownin classEngineSound
-
mute
public void mute(boolean m)
- Overrides:
mutein classEngineSound
-
setVolume
public void setVolume(float v)
- Overrides:
setVolumein classEngineSound
-
setPosition
public void setPosition(PhysicalLocation p)
- Overrides:
setPositionin classVSDSound
-
getXml
public org.jdom2.Element getXml()
- Overrides:
getXmlin classEngineSound
-
setXml
public void setXml(org.jdom2.Element e, VSDFile vf)
- Overrides:
setXmlin classEngineSound
-
-