public class HTTPAudioSink extends JSink
| Modifier and Type | Field and Description |
|---|---|
static int |
HTTP_MULTI |
AV_SYNC_IN, BUFFER_OVERFLOW, CLOSED, CONNECT, CONNECTED, CONNECTION_TIMEOUT, DISPLAY_LOCAL, DUMP, ERROR, HTTP_AUDIO, LOCAL, MAX_BT_DROP, MAX_BT_WARN, MAX_DURATION, MIN_BT, MJPG, MKV, NO_AUDIO, NO_VIDEO, OFFSET_TIME_IN, OFFSET_TIME_OUT, OPT_PKT_SIZE, PIPE_SIZE, pipeSize, PREVIEW, RTMP, RTP, SHOW_DLG_SAVE, SHOW_ENC_DLG, SOCKET_ERROR, SOCKET_SBS, socketSendBufferSize, STARVING, TSNET, UNCONNECTED| Constructor and Description |
|---|
HTTPAudioSink(DSFiltergraph src,
int port,
DSFilterInfo audioEncoder,
int flags)
Creates a server socket on the given port and streams the filtergraph's audio in either (single or multipart) G711 ulaw or alaw
or AAC format (as determined by the output mediatype on the encoder filter and eventually the HTTP_MULTI flag) to clients
accepting "audio/basic" or "audio/mpeg4-generic" mimetypes.
ulaw and alaw encoders ship with Windows ("CCITT u-Law / a-Law". |
HTTPAudioSink(DSFiltergraph src,
java.io.OutputStream out,
DSFilterInfo audioEncoder,
int flags)
Instead of creating a ServerSocket will stream the encoded audio to the given OutputStream.
|
HTTPAudioSink(DSFiltergraph src,
java.lang.String targetURL,
java.lang.String userName,
java.lang.String passWord,
DSFilterInfo audioEncoder,
int flags)
Transmit singlepart G711 ulaw audio to a device at %targetURL.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Shuts down the sink and frees all resources it allocated.
|
void |
sampleReceived(SampleBuffer inBuffer)
Called from SampleAccessFilters used by this sink.
|
create, getID, getOutputBufferSize, getOutputMediaType, propertyChange, setNetworkInterface, setSinkOption, setSocketOptionpublic static final int HTTP_MULTI
public HTTPAudioSink(DSFiltergraph src, int port, DSFilterInfo audioEncoder, int flags) throws java.lang.Exception
java.lang.Exceptionpublic HTTPAudioSink(DSFiltergraph src, java.io.OutputStream out, DSFilterInfo audioEncoder, int flags) throws java.lang.Exception
java.lang.Exceptionpublic HTTPAudioSink(DSFiltergraph src, java.lang.String targetURL, java.lang.String userName, java.lang.String passWord, DSFilterInfo audioEncoder, int flags) throws java.lang.Exception
java.lang.Exceptionpublic void close()
JSinkpublic void sampleReceived(SampleBuffer inBuffer)
JSinksampleReceived in class JSink