def get_volume(self): """get_volume(): return value get the playback volume""" check_mixer() volume = sdl.Mix_VolumeChunk(self.chunk, -1) return volume / 128.0
def set_volume(self, volume): """set_volume(value): return None set the playback volume for this Sound""" check_mixer() sdl.Mix_VolumeChunk(self.chunk, int(volume * 128))