SDL_Function

Name

Mix_Volume -- Change the volume of a channel

Synopsis

#include "SDL_mixer.h"

int Mix_Volume(int channel, int volume);

Description

MIx_Volume changes the volume of the channel specified in channel by the amount set in volume. The range of volume is from 0 to MIX_MAX_VOLUME which is 128. Passing -1 to channel will change the volume of all channels. If the specified volume is -1, it will just return the current volume.

Return Value

Returns the previously set volume of the channel.

Example

Mix_Volume(-1, MIX_MAX_VOLUME);

See Also

Mix_VolumeChunk, Mix_VolumeMusic

Mix_Volume (last edited 2008-11-16 16:13:16 by dsl-189-159-20-177)