Class PcmVolumeProcessor
- java.lang.Object
-
- com.sedmelluq.discord.lavaplayer.filter.volume.PcmVolumeProcessor
-
public class PcmVolumeProcessor extends java.lang.ObjectClass used to apply a volume level to short PCM buffers
-
-
Constructor Summary
Constructors Constructor Description PcmVolumeProcessor(int initialVolume)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidapplyVolume(int initialVolume, int targetVolume, java.nio.ShortBuffer buffer)intgetLastVolume()voidsetLastVolume(int lastVolume)
-
-
-
Method Detail
-
getLastVolume
public int getLastVolume()
- Returns:
- Last volume level used with this processor
-
setLastVolume
public void setLastVolume(int lastVolume)
- Parameters:
lastVolume- Value to explicitly set for the return value of getLastVolume()
-
applyVolume
public void applyVolume(int initialVolume, int targetVolume, java.nio.ShortBuffer buffer)- Parameters:
initialVolume- The input volume of the samplestargetVolume- The target volume of the samplesbuffer- The buffer containing the samples
-
-