public class CsrcAudioLevelDispatcher
extends java.lang.Object
implements java.lang.Runnable
Constructor and Description |
---|
CsrcAudioLevelDispatcher(AudioMediaStreamImpl mediaStream)
Initializes a new CsrcAudioLevelDispatcher to dispatch events
to a specific AudioMediaStreamImpl.
|
Modifier and Type | Method and Description |
---|---|
void |
addLevels(long[] levels,
long rtpTime)
A level matrix that we should deliver to our media stream and its
listeners in a separate thread.
|
void |
run()
Waits for new levels to be reported via the addLevels() method
and then delivers them to the AudioMediaStream that we are
associated with.
|
void |
setMediaStream(AudioMediaStreamImpl mediaStream)
Causes our run method to exit so that this thread would stop
handling levels.
|
public CsrcAudioLevelDispatcher(AudioMediaStreamImpl mediaStream)
mediaStream
- the AudioMediaStreamImpl to which the new
instance is to dispatch eventspublic void addLevels(long[] levels, long rtpTime)
levels
- the levels that we'd like to queue for processing.rtpTime
- the timestamp carried by the RTP packet which carries the
specified levelspublic void run()
run
in interface java.lang.Runnable
public void setMediaStream(AudioMediaStreamImpl mediaStream)
Jitsi, the OpenSource Java VoIP and Instant Messaging client.
Distributable under Apache license.