public abstract class AudioProvider
extends Object
Used to send audio.
The provider uses a shared buffer. Keep this in mind when implementing.
- See Also:
-
-
-
Constructor Summary
Constructors
-
Method Summary
abstract boolean
Called every 20 milliseconds and is expected to provide
Opus-encoded audio according to the format in
Opus
by writing to the provider's
buffer
.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Field Details
-
DEFAULT_BUFFER_SIZE
public static final int DEFAULT_BUFFER_SIZE
- See Also:
-
-
-
Constructor Details
-
AudioProvider
public AudioProvider()
-
-
Method Details
-
-
provide
public abstract boolean provide()
Called every 20 milliseconds and is expected to provide
Opus-encoded audio according to the format in
Opus
by writing to the provider's
buffer
.
- Returns:
- Whether audio was provided (the buffer was mutated).