Package fife :: Package extensions :: Module soundmanager :: Class SoundEmitter
[hide private]
[frames] | no frames]

Class SoundEmitter

source code

object --+
         |
        SoundEmitter

Wraps the fife.SoundEmitter class.

This class wraps an instance of a fife.SoundEmitter class along with some information about a sound clip (like gain and if its looping). All instances of SoundEmitter should be created by SoundManager.


To Do: At some point this class will store positional information and also be responsible for updating the fife.SoundEmitter position.

Instance Methods [hide private]
 
__init__(self, soundmanager, clip, soundname, emitter)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
__del__(self) source code
 
play(self) source code
 
stop(self) source code
 
_getClip(self) source code
 
_getGain(self) source code
 
_setGain(self, gain)
Sets the volume of the SoundEmitter.
source code
 
_getLooping(self) source code
 
_setLooping(self, looping) source code
 
_getFifeEmitter(self) source code
 
_setFifeEmitter(self, emitter) source code
 
_getName(self) source code
 
_getCallback(self) source code
 
_setCallback(self, cb) source code
 
_getDuration(self) source code
 
_setDuration(self, millliseconds) source code
 
_getTimer(self) source code
 
_setTimer(self, timer) source code
 
_setPosition(self, position) source code
 
_getPosition(self) source code
 
_setRolloff(self, rolloff) source code
 
_getRolloff(self) source code
 
clip(self) source code
 
name(self) source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  rolloff = property(_getRolloff, _setRolloff)
  position = property(_getPosition, _setPosition)
  timer = property(_getTimer, _setTimer)
  gain = property(_getGain, _setGain)
  looping = property(_getLooping, _setLooping)
  fifeemitter = property(_getFifeEmitter, _setFifeEmitter)
  callback = property(_getCallback, _setCallback)
  duration = property(_getDuration, _setDuration)
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, soundmanager, clip, soundname, emitter)
(Constructor)

source code 

x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Parameters:
  • soundmanager (SoundManager) - A reference to the SoundManager
  • clipid (int) - The FIFE sound clip ID from the sound clip pool
  • soundname (string) - The filename of the sound
  • emitter (fife.SoundEmitter) - A reference to the fife.SoundEmitter associated with this clip
Overrides: object.__init__

_setGain(self, gain)

source code 

Sets the volume of the SoundEmitter.

Parameters:
  • gain (int) - Value should be from 0-255. 0 being mute and 255 being the normal volume of the clip.