public interface MediaElement extends MediaObject
A MediaElement
is a module that encapsulates a specific media
capability, and that is able to exchange media with other MediaElements
through an internal element called pad.
A pad can be defined as an input or output interface. Input pads are called sinks, and it's where the media elements receive media from other media elements. Output interfaces are called sources, and it's the pad used by the media element to feed media to other media elements. There can be only one sink pad per media element. On the other hand, the number of source pads is unconstrained. This means that a certain media element can receive media only from one element at a time, while it can send media to many others. Pads are created on demand, when the connect method is invoked. When two media elements are connected, one media pad is created for each type of media connected. For example, if you connect AUDIO and VIDEO between two media elements, each one will need to create two new pads: one for AUDIO and one for VIDEO.
When media elements are connected, it can be the case that the encoding required in both input and output pads is not the same, and thus it needs to be transcoded. This is something that is handled transparently by the MediaElement internals, but such transcoding has a toll in the form of a higher CPU load, so connecting MediaElements that need media encoded in different formats is something to consider as a high load operation. The event `MediaTranscodingStateChanged` allows to inform the client application of whether media transcoding is being enabled or not inside any MediaElement object.
Modifier and Type | Method and Description |
---|---|
ListenerSubscription |
addElementConnectedListener(EventListener<ElementConnectedEvent> listener)
Add a
EventListener for event ElementConnectedEvent . |
void |
addElementConnectedListener(EventListener<ElementConnectedEvent> listener,
Continuation<ListenerSubscription> cont)
Add a
EventListener for event ElementConnectedEvent . |
ListenerSubscription |
addElementDisconnectedListener(EventListener<ElementDisconnectedEvent> listener)
Add a
EventListener for event ElementDisconnectedEvent . |
void |
addElementDisconnectedListener(EventListener<ElementDisconnectedEvent> listener,
Continuation<ListenerSubscription> cont)
Add a
EventListener for event ElementDisconnectedEvent . |
ListenerSubscription |
addMediaFlowInStateChangedListener(EventListener<MediaFlowInStateChangedEvent> listener)
Add a
EventListener for event MediaFlowInStateChangedEvent . |
void |
addMediaFlowInStateChangedListener(EventListener<MediaFlowInStateChangedEvent> listener,
Continuation<ListenerSubscription> cont)
Add a
EventListener for event MediaFlowInStateChangedEvent . |
ListenerSubscription |
addMediaFlowInStateChangeListener(EventListener<MediaFlowInStateChangeEvent> listener)
Add a
EventListener for event MediaFlowInStateChangeEvent . |
void |
addMediaFlowInStateChangeListener(EventListener<MediaFlowInStateChangeEvent> listener,
Continuation<ListenerSubscription> cont)
Add a
EventListener for event MediaFlowInStateChangeEvent . |
ListenerSubscription |
addMediaFlowOutStateChangedListener(EventListener<MediaFlowOutStateChangedEvent> listener)
Add a
EventListener for event MediaFlowOutStateChangedEvent . |
void |
addMediaFlowOutStateChangedListener(EventListener<MediaFlowOutStateChangedEvent> listener,
Continuation<ListenerSubscription> cont)
Add a
EventListener for event MediaFlowOutStateChangedEvent . |
ListenerSubscription |
addMediaFlowOutStateChangeListener(EventListener<MediaFlowOutStateChangeEvent> listener)
Add a
EventListener for event MediaFlowOutStateChangeEvent . |
void |
addMediaFlowOutStateChangeListener(EventListener<MediaFlowOutStateChangeEvent> listener,
Continuation<ListenerSubscription> cont)
Add a
EventListener for event MediaFlowOutStateChangeEvent . |
ListenerSubscription |
addMediaTranscodingStateChangedListener(EventListener<MediaTranscodingStateChangedEvent> listener)
Add a
EventListener for event MediaTranscodingStateChangedEvent . |
void |
addMediaTranscodingStateChangedListener(EventListener<MediaTranscodingStateChangedEvent> listener,
Continuation<ListenerSubscription> cont)
Add a
EventListener for event MediaTranscodingStateChangedEvent . |
ListenerSubscription |
addMediaTranscodingStateChangeListener(EventListener<MediaTranscodingStateChangeEvent> listener)
Add a
EventListener for event MediaTranscodingStateChangeEvent . |
void |
addMediaTranscodingStateChangeListener(EventListener<MediaTranscodingStateChangeEvent> listener,
Continuation<ListenerSubscription> cont)
Add a
EventListener for event MediaTranscodingStateChangeEvent . |
void |
connect(MediaElement sink)
Connects two elements, with the media flowing from left to right.
|
void |
connect(MediaElement sink,
Continuation<Void> cont)
Asynchronous version of connect:
Continuation.onSuccess(F) is called when the action is
done. |
void |
connect(MediaElement sink,
MediaType mediaType)
Connects two elements, with the media flowing from left to right.
|
void |
connect(MediaElement sink,
MediaType mediaType,
Continuation<Void> cont)
Asynchronous version of connect:
Continuation.onSuccess(F) is called when the action is
done. |
void |
connect(MediaElement sink,
MediaType mediaType,
String sourceMediaDescription)
Connects two elements, with the media flowing from left to right.
|
void |
connect(MediaElement sink,
MediaType mediaType,
String sourceMediaDescription,
Continuation<Void> cont)
Asynchronous version of connect:
Continuation.onSuccess(F) is called when the action is
done. |
void |
connect(MediaElement sink,
MediaType mediaType,
String sourceMediaDescription,
String sinkMediaDescription)
Connects two elements, with the media flowing from left to right.
|
void |
connect(MediaElement sink,
MediaType mediaType,
String sourceMediaDescription,
String sinkMediaDescription,
Continuation<Void> cont)
Asynchronous version of connect:
Continuation.onSuccess(F) is called when the action is
done. |
void |
connect(Transaction tx,
MediaElement sink)
Connects two elements, with the media flowing from left to right.
|
void |
connect(Transaction tx,
MediaElement sink,
MediaType mediaType)
Connects two elements, with the media flowing from left to right.
|
void |
connect(Transaction tx,
MediaElement sink,
MediaType mediaType,
String sourceMediaDescription)
Connects two elements, with the media flowing from left to right.
|
void |
connect(Transaction tx,
MediaElement sink,
MediaType mediaType,
String sourceMediaDescription,
String sinkMediaDescription)
Connects two elements, with the media flowing from left to right.
|
void |
disconnect(MediaElement sink)
Disconnects two media elements.
|
void |
disconnect(MediaElement sink,
Continuation<Void> cont)
Asynchronous version of disconnect:
Continuation.onSuccess(F) is called when the action is
done. |
void |
disconnect(MediaElement sink,
MediaType mediaType)
Disconnects two media elements.
|
void |
disconnect(MediaElement sink,
MediaType mediaType,
Continuation<Void> cont)
Asynchronous version of disconnect:
Continuation.onSuccess(F) is called when the action is
done. |
void |
disconnect(MediaElement sink,
MediaType mediaType,
String sourceMediaDescription)
Disconnects two media elements.
|
void |
disconnect(MediaElement sink,
MediaType mediaType,
String sourceMediaDescription,
Continuation<Void> cont)
Asynchronous version of disconnect:
Continuation.onSuccess(F) is called when the action is
done. |
void |
disconnect(MediaElement sink,
MediaType mediaType,
String sourceMediaDescription,
String sinkMediaDescription)
Disconnects two media elements.
|
void |
disconnect(MediaElement sink,
MediaType mediaType,
String sourceMediaDescription,
String sinkMediaDescription,
Continuation<Void> cont)
Asynchronous version of disconnect:
Continuation.onSuccess(F) is called when the action is
done. |
void |
disconnect(Transaction tx,
MediaElement sink)
Disconnects two media elements.
|
void |
disconnect(Transaction tx,
MediaElement sink,
MediaType mediaType)
Disconnects two media elements.
|
void |
disconnect(Transaction tx,
MediaElement sink,
MediaType mediaType,
String sourceMediaDescription)
Disconnects two media elements.
|
void |
disconnect(Transaction tx,
MediaElement sink,
MediaType mediaType,
String sourceMediaDescription,
String sinkMediaDescription)
Disconnects two media elements.
|
String |
getGstreamerDot()
Return a .dot file describing the topology of the media element.
|
void |
getGstreamerDot(Continuation<String> cont)
Asynchronous version of getGstreamerDot:
Continuation.onSuccess(F) is called when the action is
done. |
String |
getGstreamerDot(GstreamerDotDetails details)
Return a .dot file describing the topology of the media element.
|
void |
getGstreamerDot(GstreamerDotDetails details,
Continuation<String> cont)
Asynchronous version of getGstreamerDot:
Continuation.onSuccess(F) is called when the action is
done. |
TFuture<String> |
getGstreamerDot(Transaction tx)
Return a .dot file describing the topology of the media element.
|
TFuture<String> |
getGstreamerDot(Transaction tx,
GstreamerDotDetails details)
Return a .dot file describing the topology of the media element.
|
int |
getMaxOuputBitrate()
Deprecated.
Deprecated due to a typo. Use :rom:meth:`maxOutputBitrate` instead of this function.
|
void |
getMaxOuputBitrate(Continuation<Integer> cont)
Deprecated.
Deprecated due to a typo. Use :rom:meth:`maxOutputBitrate` instead of this function.
|
TFuture<Integer> |
getMaxOuputBitrate(Transaction tx)
Deprecated.
Deprecated due to a typo. Use :rom:meth:`maxOutputBitrate` instead of this function.
|
int |
getMaxOutputBitrate()
Get Maximum video bitrate for transcoding.
|
void |
getMaxOutputBitrate(Continuation<Integer> cont)
Get Maximum video bitrate for transcoding.
|
TFuture<Integer> |
getMaxOutputBitrate(Transaction tx)
Get Maximum video bitrate for transcoding.
|
int |
getMinOuputBitrate()
Deprecated.
Deprecated due to a typo. Use :rom:meth:`minOutputBitrate` instead of this function.
|
void |
getMinOuputBitrate(Continuation<Integer> cont)
Deprecated.
Deprecated due to a typo. Use :rom:meth:`minOutputBitrate` instead of this function.
|
TFuture<Integer> |
getMinOuputBitrate(Transaction tx)
Deprecated.
Deprecated due to a typo. Use :rom:meth:`minOutputBitrate` instead of this function.
|
int |
getMinOutputBitrate()
Get Minimum video bitrate for transcoding.
|
void |
getMinOutputBitrate(Continuation<Integer> cont)
Get Minimum video bitrate for transcoding.
|
TFuture<Integer> |
getMinOutputBitrate(Transaction tx)
Get Minimum video bitrate for transcoding.
|
List<ElementConnectionData> |
getSinkConnections()
Gets information about the source pads of this media element.
|
void |
getSinkConnections(Continuation<List<ElementConnectionData>> cont)
Asynchronous version of getSinkConnections:
Continuation.onSuccess(F) is called when the action is
done. |
List<ElementConnectionData> |
getSinkConnections(MediaType mediaType)
Gets information about the source pads of this media element.
|
void |
getSinkConnections(MediaType mediaType,
Continuation<List<ElementConnectionData>> cont)
Asynchronous version of getSinkConnections:
Continuation.onSuccess(F) is called when the action is
done. |
List<ElementConnectionData> |
getSinkConnections(MediaType mediaType,
String description)
Gets information about the source pads of this media element.
|
void |
getSinkConnections(MediaType mediaType,
String description,
Continuation<List<ElementConnectionData>> cont)
Asynchronous version of getSinkConnections:
Continuation.onSuccess(F) is called when the action is
done. |
TFuture<List<ElementConnectionData>> |
getSinkConnections(Transaction tx)
Gets information about the source pads of this media element.
|
TFuture<List<ElementConnectionData>> |
getSinkConnections(Transaction tx,
MediaType mediaType)
Gets information about the source pads of this media element.
|
TFuture<List<ElementConnectionData>> |
getSinkConnections(Transaction tx,
MediaType mediaType,
String description)
Gets information about the source pads of this media element.
|
List<ElementConnectionData> |
getSourceConnections()
Gets information about the sink pads of this media element.
|
void |
getSourceConnections(Continuation<List<ElementConnectionData>> cont)
Asynchronous version of getSourceConnections:
Continuation.onSuccess(F) is called when the action is
done. |
List<ElementConnectionData> |
getSourceConnections(MediaType mediaType)
Gets information about the sink pads of this media element.
|
void |
getSourceConnections(MediaType mediaType,
Continuation<List<ElementConnectionData>> cont)
Asynchronous version of getSourceConnections:
Continuation.onSuccess(F) is called when the action is
done. |
List<ElementConnectionData> |
getSourceConnections(MediaType mediaType,
String description)
Gets information about the sink pads of this media element.
|
void |
getSourceConnections(MediaType mediaType,
String description,
Continuation<List<ElementConnectionData>> cont)
Asynchronous version of getSourceConnections:
Continuation.onSuccess(F) is called when the action is
done. |
TFuture<List<ElementConnectionData>> |
getSourceConnections(Transaction tx)
Gets information about the sink pads of this media element.
|
TFuture<List<ElementConnectionData>> |
getSourceConnections(Transaction tx,
MediaType mediaType)
Gets information about the sink pads of this media element.
|
TFuture<List<ElementConnectionData>> |
getSourceConnections(Transaction tx,
MediaType mediaType,
String description)
Gets information about the sink pads of this media element.
|
Map<String,Stats> |
getStats()
Gets the statistics related to an endpoint.
|
void |
getStats(Continuation<Map<String,Stats>> cont)
Asynchronous version of getStats:
Continuation.onSuccess(F) is called when the action is
done. |
Map<String,Stats> |
getStats(MediaType mediaType)
Gets the statistics related to an endpoint.
|
void |
getStats(MediaType mediaType,
Continuation<Map<String,Stats>> cont)
Asynchronous version of getStats:
Continuation.onSuccess(F) is called when the action is
done. |
TFuture<Map<String,Stats>> |
getStats(Transaction tx)
Gets the statistics related to an endpoint.
|
TFuture<Map<String,Stats>> |
getStats(Transaction tx,
MediaType mediaType)
Gets the statistics related to an endpoint.
|
boolean |
isMediaFlowingIn(MediaType mediaType)
This method indicates whether the media element is receiving media of a certain type.
|
void |
isMediaFlowingIn(MediaType mediaType,
Continuation<Boolean> cont)
Asynchronous version of isMediaFlowingIn:
Continuation.onSuccess(F) is called when the action is
done. |
boolean |
isMediaFlowingIn(MediaType mediaType,
String sinkMediaDescription)
This method indicates whether the media element is receiving media of a certain type.
|
void |
isMediaFlowingIn(MediaType mediaType,
String sinkMediaDescription,
Continuation<Boolean> cont)
Asynchronous version of isMediaFlowingIn:
Continuation.onSuccess(F) is called when the action is
done. |
TFuture<Boolean> |
isMediaFlowingIn(Transaction tx,
MediaType mediaType)
This method indicates whether the media element is receiving media of a certain type.
|
TFuture<Boolean> |
isMediaFlowingIn(Transaction tx,
MediaType mediaType,
String sinkMediaDescription)
This method indicates whether the media element is receiving media of a certain type.
|
boolean |
isMediaFlowingOut(MediaType mediaType)
This method indicates whether the media element is emitting media of a certain type.
|
void |
isMediaFlowingOut(MediaType mediaType,
Continuation<Boolean> cont)
Asynchronous version of isMediaFlowingOut:
Continuation.onSuccess(F) is called when the action is
done. |
boolean |
isMediaFlowingOut(MediaType mediaType,
String sourceMediaDescription)
This method indicates whether the media element is emitting media of a certain type.
|
void |
isMediaFlowingOut(MediaType mediaType,
String sourceMediaDescription,
Continuation<Boolean> cont)
Asynchronous version of isMediaFlowingOut:
Continuation.onSuccess(F) is called when the action is
done. |
TFuture<Boolean> |
isMediaFlowingOut(Transaction tx,
MediaType mediaType)
This method indicates whether the media element is emitting media of a certain type.
|
TFuture<Boolean> |
isMediaFlowingOut(Transaction tx,
MediaType mediaType,
String sourceMediaDescription)
This method indicates whether the media element is emitting media of a certain type.
|
boolean |
isMediaTranscoding(MediaType mediaType)
Indicates whether this media element is actively transcoding between input and output pads.
|
void |
isMediaTranscoding(MediaType mediaType,
Continuation<Boolean> cont)
Asynchronous version of isMediaTranscoding:
Continuation.onSuccess(F) is called when the action is
done. |
boolean |
isMediaTranscoding(MediaType mediaType,
String binName)
Indicates whether this media element is actively transcoding between input and output pads.
|
void |
isMediaTranscoding(MediaType mediaType,
String binName,
Continuation<Boolean> cont)
Asynchronous version of isMediaTranscoding:
Continuation.onSuccess(F) is called when the action is
done. |
TFuture<Boolean> |
isMediaTranscoding(Transaction tx,
MediaType mediaType)
Indicates whether this media element is actively transcoding between input and output pads.
|
TFuture<Boolean> |
isMediaTranscoding(Transaction tx,
MediaType mediaType,
String binName)
Indicates whether this media element is actively transcoding between input and output pads.
|
void |
removeElementConnectedListener(ListenerSubscription listenerSubscription)
Remove a
ListenerSubscription for event ElementConnectedEvent . |
void |
removeElementConnectedListener(ListenerSubscription listenerSubscription,
Continuation<Void> cont)
Remove a
ListenerSubscription for event ElementConnectedEvent . |
void |
removeElementDisconnectedListener(ListenerSubscription listenerSubscription)
Remove a
ListenerSubscription for event ElementDisconnectedEvent . |
void |
removeElementDisconnectedListener(ListenerSubscription listenerSubscription,
Continuation<Void> cont)
Remove a
ListenerSubscription for event ElementDisconnectedEvent . |
void |
removeMediaFlowInStateChangedListener(ListenerSubscription listenerSubscription)
Remove a
ListenerSubscription for event MediaFlowInStateChangedEvent . |
void |
removeMediaFlowInStateChangedListener(ListenerSubscription listenerSubscription,
Continuation<Void> cont)
Remove a
ListenerSubscription for event MediaFlowInStateChangedEvent . |
void |
removeMediaFlowInStateChangeListener(ListenerSubscription listenerSubscription)
Remove a
ListenerSubscription for event MediaFlowInStateChangeEvent . |
void |
removeMediaFlowInStateChangeListener(ListenerSubscription listenerSubscription,
Continuation<Void> cont)
Remove a
ListenerSubscription for event MediaFlowInStateChangeEvent . |
void |
removeMediaFlowOutStateChangedListener(ListenerSubscription listenerSubscription)
Remove a
ListenerSubscription for event MediaFlowOutStateChangedEvent . |
void |
removeMediaFlowOutStateChangedListener(ListenerSubscription listenerSubscription,
Continuation<Void> cont)
Remove a
ListenerSubscription for event MediaFlowOutStateChangedEvent . |
void |
removeMediaFlowOutStateChangeListener(ListenerSubscription listenerSubscription)
Remove a
ListenerSubscription for event MediaFlowOutStateChangeEvent . |
void |
removeMediaFlowOutStateChangeListener(ListenerSubscription listenerSubscription,
Continuation<Void> cont)
Remove a
ListenerSubscription for event MediaFlowOutStateChangeEvent . |
void |
removeMediaTranscodingStateChangedListener(ListenerSubscription listenerSubscription)
Remove a
ListenerSubscription for event MediaTranscodingStateChangedEvent . |
void |
removeMediaTranscodingStateChangedListener(ListenerSubscription listenerSubscription,
Continuation<Void> cont)
Remove a
ListenerSubscription for event MediaTranscodingStateChangedEvent . |
void |
removeMediaTranscodingStateChangeListener(ListenerSubscription listenerSubscription)
Remove a
ListenerSubscription for event MediaTranscodingStateChangeEvent . |
void |
removeMediaTranscodingStateChangeListener(ListenerSubscription listenerSubscription,
Continuation<Void> cont)
Remove a
ListenerSubscription for event MediaTranscodingStateChangeEvent . |
void |
setAudioFormat(AudioCaps caps)
Set the type of data for the audio stream.
|
void |
setAudioFormat(AudioCaps caps,
Continuation<Void> cont)
Asynchronous version of setAudioFormat:
Continuation.onSuccess(F) is called when the action is
done. |
void |
setAudioFormat(Transaction tx,
AudioCaps caps)
Set the type of data for the audio stream.
|
void |
setMaxOuputBitrate(int maxOuputBitrate)
Deprecated.
Deprecated due to a typo. Use :rom:meth:`maxOutputBitrate` instead of this function.
|
void |
setMaxOuputBitrate(int maxOuputBitrate,
Continuation<Void> cont)
Deprecated.
Deprecated due to a typo. Use :rom:meth:`maxOutputBitrate` instead of this function.
|
void |
setMaxOuputBitrate(int maxOuputBitrate,
Transaction tx)
Deprecated.
Deprecated due to a typo. Use :rom:meth:`maxOutputBitrate` instead of this function.
|
void |
setMaxOutputBitrate(int maxOutputBitrate)
Set Maximum video bitrate for transcoding.
|
void |
setMaxOutputBitrate(int maxOutputBitrate,
Continuation<Void> cont)
Set Maximum video bitrate for transcoding.
|
void |
setMaxOutputBitrate(int maxOutputBitrate,
Transaction tx)
Set Maximum video bitrate for transcoding.
|
void |
setMinOuputBitrate(int minOuputBitrate)
Deprecated.
Deprecated due to a typo. Use :rom:meth:`minOutputBitrate` instead of this function.
|
void |
setMinOuputBitrate(int minOuputBitrate,
Continuation<Void> cont)
Deprecated.
Deprecated due to a typo. Use :rom:meth:`minOutputBitrate` instead of this function.
|
void |
setMinOuputBitrate(int minOuputBitrate,
Transaction tx)
Deprecated.
Deprecated due to a typo. Use :rom:meth:`minOutputBitrate` instead of this function.
|
void |
setMinOutputBitrate(int minOutputBitrate)
Set Minimum video bitrate for transcoding.
|
void |
setMinOutputBitrate(int minOutputBitrate,
Continuation<Void> cont)
Set Minimum video bitrate for transcoding.
|
void |
setMinOutputBitrate(int minOutputBitrate,
Transaction tx)
Set Minimum video bitrate for transcoding.
|
void |
setOutputBitrate(int bitrate)
Deprecated.
Allows change the target bitrate for the media output, if the media is encoded using VP8 or H264. This method only works if it is called before the media starts to flow.
|
void |
setOutputBitrate(int bitrate,
Continuation<Void> cont)
Asynchronous version of setOutputBitrate:
Continuation.onSuccess(F) is called when the action is
done. |
void |
setOutputBitrate(Transaction tx,
int bitrate)
Deprecated.
Allows change the target bitrate for the media output, if the media is encoded using VP8 or H264. This method only works if it is called before the media starts to flow.
|
void |
setVideoFormat(Transaction tx,
VideoCaps caps)
Set the type of data for the video stream.
|
void |
setVideoFormat(VideoCaps caps)
Set the type of data for the video stream.
|
void |
setVideoFormat(VideoCaps caps,
Continuation<Void> cont)
Asynchronous version of setVideoFormat:
Continuation.onSuccess(F) is called when the action is
done. |
addErrorListener, addErrorListener, addTag, addTag, addTag, getChildren, getChildren, getChildren, getChilds, getChilds, getChilds, getCreationTime, getCreationTime, getCreationTime, getId, getId, getId, getMediaPipeline, getMediaPipeline, getMediaPipeline, getName, getName, getName, getParent, getParent, getParent, getSendTagsInEvents, getSendTagsInEvents, getSendTagsInEvents, getTag, getTag, getTag, getTags, getTags, getTags, removeErrorListener, removeErrorListener, removeTag, removeTag, removeTag, setName, setName, setName, setSendTagsInEvents, setSendTagsInEvents, setSendTagsInEvents
addEventListener, invoke, isCommited, release, release, release, removeEventListener, waitCommited, whenCommited, whenCommited
int getMinOuputBitrate()
void getMinOuputBitrate(Continuation<Integer> cont)
TFuture<Integer> getMinOuputBitrate(Transaction tx)
void setMinOuputBitrate(int minOuputBitrate)
void setMinOuputBitrate(int minOuputBitrate, Continuation<Void> cont)
void setMinOuputBitrate(int minOuputBitrate, Transaction tx)
int getMinOutputBitrate()
void getMinOutputBitrate(Continuation<Integer> cont)
TFuture<Integer> getMinOutputBitrate(Transaction tx)
void setMinOutputBitrate(int minOutputBitrate)
void setMinOutputBitrate(int minOutputBitrate, Continuation<Void> cont)
void setMinOutputBitrate(int minOutputBitrate, Transaction tx)
int getMaxOuputBitrate()
void getMaxOuputBitrate(Continuation<Integer> cont)
TFuture<Integer> getMaxOuputBitrate(Transaction tx)
void setMaxOuputBitrate(int maxOuputBitrate)
void setMaxOuputBitrate(int maxOuputBitrate, Continuation<Void> cont)
void setMaxOuputBitrate(int maxOuputBitrate, Transaction tx)
int getMaxOutputBitrate()
void getMaxOutputBitrate(Continuation<Integer> cont)
TFuture<Integer> getMaxOutputBitrate(Transaction tx)
void setMaxOutputBitrate(int maxOutputBitrate)
void setMaxOutputBitrate(int maxOutputBitrate, Continuation<Void> cont)
void setMaxOutputBitrate(int maxOutputBitrate, Transaction tx)
List<ElementConnectionData> getSourceConnections(MediaType mediaType, String description)
Since sink pads are the interface through which a media element gets it's media, whatever is connected to an element's sink pad is formally a source of media. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
description
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesvoid getSourceConnections(MediaType mediaType, String description, Continuation<List<ElementConnectionData>> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
description
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesgetSourceConnections(org.kurento.client.MediaType, java.lang.String)
TFuture<List<ElementConnectionData>> getSourceConnections(Transaction tx, MediaType mediaType, String description)
Since sink pads are the interface through which a media element gets it's media, whatever is connected to an element's sink pad is formally a source of media. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
description
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesList<ElementConnectionData> getSinkConnections(MediaType mediaType, String description)
Since source pads connect to other media element's sinks, this is formally the sink of media from the element's perspective. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
description
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesvoid getSinkConnections(MediaType mediaType, String description, Continuation<List<ElementConnectionData>> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
description
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesgetSinkConnections(org.kurento.client.MediaType, java.lang.String)
TFuture<List<ElementConnectionData>> getSinkConnections(Transaction tx, MediaType mediaType, String description)
Since source pads connect to other media element's sinks, this is formally the sink of media from the element's perspective. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
description
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesvoid connect(MediaElement sink, MediaType mediaType, String sourceMediaDescription, String sinkMediaDescription)
The element that invokes the connect will be the source of media, creating one sink pad for each type of media connected. The element given as parameter to the method will be the sink, and it will create one sink pad per media type connected.
If otherwise not specified, all types of media are connected by default (AUDIO, VIDEO and DATA). It is recommended to connect the specific types of media if not all of them will be used. For this purpose, the connect method can be invoked more than once on the same two elements, but with different media types.
The connection is unidirectional. If a bidirectional connection is desired, the position of the media elements must be inverted. For instance, webrtc1.connect(webrtc2) is connecting webrtc1 as source of webrtc2. In order to create a WebRTC one-2one conversation, the user would need to specify the connection on the other direction with webrtc2.connect(webrtc1).
Even though one media element can have one sink pad per type of media, only one media element can be connected to another at a given time. If a media element is connected to another, the former will become the source of the sink media element, regardless whether there was another element connected or not.
sink
- the target MediaElement
that will receive mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcessinkMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesvoid connect(MediaElement sink, MediaType mediaType, String sourceMediaDescription, String sinkMediaDescription, Continuation<Void> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.sink
- the target MediaElement
that will receive mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcessinkMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesconnect(org.kurento.client.MediaElement, org.kurento.client.MediaType, java.lang.String, java.lang.String)
void connect(Transaction tx, MediaElement sink, MediaType mediaType, String sourceMediaDescription, String sinkMediaDescription)
The element that invokes the connect will be the source of media, creating one sink pad for each type of media connected. The element given as parameter to the method will be the sink, and it will create one sink pad per media type connected.
If otherwise not specified, all types of media are connected by default (AUDIO, VIDEO and DATA). It is recommended to connect the specific types of media if not all of them will be used. For this purpose, the connect method can be invoked more than once on the same two elements, but with different media types.
The connection is unidirectional. If a bidirectional connection is desired, the position of the media elements must be inverted. For instance, webrtc1.connect(webrtc2) is connecting webrtc1 as source of webrtc2. In order to create a WebRTC one-2one conversation, the user would need to specify the connection on the other direction with webrtc2.connect(webrtc1).
Even though one media element can have one sink pad per type of media, only one media element can be connected to another at a given time. If a media element is connected to another, the former will become the source of the sink media element, regardless whether there was another element connected or not.
sink
- the target MediaElement
that will receive mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcessinkMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesvoid disconnect(MediaElement sink, MediaType mediaType, String sourceMediaDescription, String sinkMediaDescription)
sink
- the target MediaElement
that will stop receiving mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcessinkMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesvoid disconnect(MediaElement sink, MediaType mediaType, String sourceMediaDescription, String sinkMediaDescription, Continuation<Void> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.sink
- the target MediaElement
that will stop receiving mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcessinkMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesdisconnect(org.kurento.client.MediaElement, org.kurento.client.MediaType, java.lang.String, java.lang.String)
void disconnect(Transaction tx, MediaElement sink, MediaType mediaType, String sourceMediaDescription, String sinkMediaDescription)
sink
- the target MediaElement
that will stop receiving mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcessinkMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesvoid setAudioFormat(AudioCaps caps)
MediaElements that do not support configuration of audio capabilities will throw a MEDIA_OBJECT_ILLEGAL_PARAM_ERROR exception.
NOTE: This method is not implemented yet by the Media Server to do anything useful.
caps
- The format for the stream of audiovoid setAudioFormat(AudioCaps caps, Continuation<Void> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.caps
- The format for the stream of audiosetAudioFormat(org.kurento.client.AudioCaps)
void setAudioFormat(Transaction tx, AudioCaps caps)
MediaElements that do not support configuration of audio capabilities will throw a MEDIA_OBJECT_ILLEGAL_PARAM_ERROR exception.
NOTE: This method is not implemented yet by the Media Server to do anything useful.
caps
- The format for the stream of audiovoid setVideoFormat(VideoCaps caps)
MediaElements that do not support configuration of video capabilities will throw a MEDIA_OBJECT_ILLEGAL_PARAM_ERROR exception
NOTE: This method is not implemented yet by the Media Server to do anything useful.
caps
- The format for the stream of videovoid setVideoFormat(VideoCaps caps, Continuation<Void> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.caps
- The format for the stream of videosetVideoFormat(org.kurento.client.VideoCaps)
void setVideoFormat(Transaction tx, VideoCaps caps)
MediaElements that do not support configuration of video capabilities will throw a MEDIA_OBJECT_ILLEGAL_PARAM_ERROR exception
NOTE: This method is not implemented yet by the Media Server to do anything useful.
caps
- The format for the stream of videoString getGstreamerDot(GstreamerDotDetails details)
The element can be queried for certain type of data:
details
- Details of graphvoid getGstreamerDot(GstreamerDotDetails details, Continuation<String> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.details
- Details of graphgetGstreamerDot(org.kurento.client.GstreamerDotDetails)
TFuture<String> getGstreamerDot(Transaction tx, GstreamerDotDetails details)
The element can be queried for certain type of data:
details
- Details of graphvoid setOutputBitrate(int bitrate)
bitrate
- Configure the enconding media bitrate in bpsvoid setOutputBitrate(int bitrate, Continuation<Void> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.bitrate
- Configure the enconding media bitrate in bpssetOutputBitrate(int)
void setOutputBitrate(Transaction tx, int bitrate)
bitrate
- Configure the enconding media bitrate in bpsMap<String,Stats> getStats(MediaType mediaType)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
void getStats(MediaType mediaType, Continuation<Map<String,Stats>> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
getStats(org.kurento.client.MediaType)
TFuture<Map<String,Stats>> getStats(Transaction tx, MediaType mediaType)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
boolean isMediaFlowingIn(MediaType mediaType, String sinkMediaDescription)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
sinkMediaDescription
- Description of the sinkvoid isMediaFlowingIn(MediaType mediaType, String sinkMediaDescription, Continuation<Boolean> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
sinkMediaDescription
- Description of the sinkisMediaFlowingIn(org.kurento.client.MediaType, java.lang.String)
TFuture<Boolean> isMediaFlowingIn(Transaction tx, MediaType mediaType, String sinkMediaDescription)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
sinkMediaDescription
- Description of the sinkboolean isMediaFlowingOut(MediaType mediaType, String sourceMediaDescription)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
sourceMediaDescription
- Description of the sourcevoid isMediaFlowingOut(MediaType mediaType, String sourceMediaDescription, Continuation<Boolean> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
sourceMediaDescription
- Description of the sourceisMediaFlowingOut(org.kurento.client.MediaType, java.lang.String)
TFuture<Boolean> isMediaFlowingOut(Transaction tx, MediaType mediaType, String sourceMediaDescription)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
sourceMediaDescription
- Description of the sourceboolean isMediaTranscoding(MediaType mediaType, String binName)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
binName
- Internal name of the processing bin, as previously given by MediaTranscodingStateChanged
.void isMediaTranscoding(MediaType mediaType, String binName, Continuation<Boolean> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
binName
- Internal name of the processing bin, as previously given by MediaTranscodingStateChanged
.isMediaTranscoding(org.kurento.client.MediaType, java.lang.String)
TFuture<Boolean> isMediaTranscoding(Transaction tx, MediaType mediaType, String binName)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
binName
- Internal name of the processing bin, as previously given by MediaTranscodingStateChanged
.List<ElementConnectionData> getSourceConnections()
Since sink pads are the interface through which a media element gets it's media, whatever is connected to an element's sink pad is formally a source of media. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
void getSourceConnections(Continuation<List<ElementConnectionData>> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.TFuture<List<ElementConnectionData>> getSourceConnections(Transaction tx)
Since sink pads are the interface through which a media element gets it's media, whatever is connected to an element's sink pad is formally a source of media. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
List<ElementConnectionData> getSourceConnections(MediaType mediaType)
Since sink pads are the interface through which a media element gets it's media, whatever is connected to an element's sink pad is formally a source of media. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
void getSourceConnections(MediaType mediaType, Continuation<List<ElementConnectionData>> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
getSourceConnections(org.kurento.client.MediaType, java.lang.String)
TFuture<List<ElementConnectionData>> getSourceConnections(Transaction tx, MediaType mediaType)
Since sink pads are the interface through which a media element gets it's media, whatever is connected to an element's sink pad is formally a source of media. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
List<ElementConnectionData> getSinkConnections()
Since source pads connect to other media element's sinks, this is formally the sink of media from the element's perspective. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
void getSinkConnections(Continuation<List<ElementConnectionData>> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.TFuture<List<ElementConnectionData>> getSinkConnections(Transaction tx)
Since source pads connect to other media element's sinks, this is formally the sink of media from the element's perspective. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
List<ElementConnectionData> getSinkConnections(MediaType mediaType)
Since source pads connect to other media element's sinks, this is formally the sink of media from the element's perspective. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
void getSinkConnections(MediaType mediaType, Continuation<List<ElementConnectionData>> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
getSinkConnections(org.kurento.client.MediaType, java.lang.String)
TFuture<List<ElementConnectionData>> getSinkConnections(Transaction tx, MediaType mediaType)
Since source pads connect to other media element's sinks, this is formally the sink of media from the element's perspective. Media can be filtered by type, or by the description given to the pad though which both elements are connected.
mediaType
- One of MediaType.AUDIO
, MediaType.VIDEO
or MediaType.DATA
void connect(MediaElement sink)
The element that invokes the connect will be the source of media, creating one sink pad for each type of media connected. The element given as parameter to the method will be the sink, and it will create one sink pad per media type connected.
If otherwise not specified, all types of media are connected by default (AUDIO, VIDEO and DATA). It is recommended to connect the specific types of media if not all of them will be used. For this purpose, the connect method can be invoked more than once on the same two elements, but with different media types.
The connection is unidirectional. If a bidirectional connection is desired, the position of the media elements must be inverted. For instance, webrtc1.connect(webrtc2) is connecting webrtc1 as source of webrtc2. In order to create a WebRTC one-2one conversation, the user would need to specify the connection on the other direction with webrtc2.connect(webrtc1).
Even though one media element can have one sink pad per type of media, only one media element can be connected to another at a given time. If a media element is connected to another, the former will become the source of the sink media element, regardless whether there was another element connected or not.
sink
- the target MediaElement
that will receive mediavoid connect(MediaElement sink, Continuation<Void> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.sink
- the target MediaElement
that will receive mediaconnect(org.kurento.client.MediaElement, org.kurento.client.MediaType, java.lang.String, java.lang.String)
void connect(Transaction tx, MediaElement sink)
The element that invokes the connect will be the source of media, creating one sink pad for each type of media connected. The element given as parameter to the method will be the sink, and it will create one sink pad per media type connected.
If otherwise not specified, all types of media are connected by default (AUDIO, VIDEO and DATA). It is recommended to connect the specific types of media if not all of them will be used. For this purpose, the connect method can be invoked more than once on the same two elements, but with different media types.
The connection is unidirectional. If a bidirectional connection is desired, the position of the media elements must be inverted. For instance, webrtc1.connect(webrtc2) is connecting webrtc1 as source of webrtc2. In order to create a WebRTC one-2one conversation, the user would need to specify the connection on the other direction with webrtc2.connect(webrtc1).
Even though one media element can have one sink pad per type of media, only one media element can be connected to another at a given time. If a media element is connected to another, the former will become the source of the sink media element, regardless whether there was another element connected or not.
sink
- the target MediaElement
that will receive mediavoid connect(MediaElement sink, MediaType mediaType)
The element that invokes the connect will be the source of media, creating one sink pad for each type of media connected. The element given as parameter to the method will be the sink, and it will create one sink pad per media type connected.
If otherwise not specified, all types of media are connected by default (AUDIO, VIDEO and DATA). It is recommended to connect the specific types of media if not all of them will be used. For this purpose, the connect method can be invoked more than once on the same two elements, but with different media types.
The connection is unidirectional. If a bidirectional connection is desired, the position of the media elements must be inverted. For instance, webrtc1.connect(webrtc2) is connecting webrtc1 as source of webrtc2. In order to create a WebRTC one-2one conversation, the user would need to specify the connection on the other direction with webrtc2.connect(webrtc1).
Even though one media element can have one sink pad per type of media, only one media element can be connected to another at a given time. If a media element is connected to another, the former will become the source of the sink media element, regardless whether there was another element connected or not.
sink
- the target MediaElement
that will receive mediamediaType
- the MediaType
of the pads that will be connectedvoid connect(MediaElement sink, MediaType mediaType, Continuation<Void> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.sink
- the target MediaElement
that will receive mediamediaType
- the MediaType
of the pads that will be connectedconnect(org.kurento.client.MediaElement, org.kurento.client.MediaType, java.lang.String, java.lang.String)
void connect(Transaction tx, MediaElement sink, MediaType mediaType)
The element that invokes the connect will be the source of media, creating one sink pad for each type of media connected. The element given as parameter to the method will be the sink, and it will create one sink pad per media type connected.
If otherwise not specified, all types of media are connected by default (AUDIO, VIDEO and DATA). It is recommended to connect the specific types of media if not all of them will be used. For this purpose, the connect method can be invoked more than once on the same two elements, but with different media types.
The connection is unidirectional. If a bidirectional connection is desired, the position of the media elements must be inverted. For instance, webrtc1.connect(webrtc2) is connecting webrtc1 as source of webrtc2. In order to create a WebRTC one-2one conversation, the user would need to specify the connection on the other direction with webrtc2.connect(webrtc1).
Even though one media element can have one sink pad per type of media, only one media element can be connected to another at a given time. If a media element is connected to another, the former will become the source of the sink media element, regardless whether there was another element connected or not.
sink
- the target MediaElement
that will receive mediamediaType
- the MediaType
of the pads that will be connectedvoid connect(MediaElement sink, MediaType mediaType, String sourceMediaDescription)
The element that invokes the connect will be the source of media, creating one sink pad for each type of media connected. The element given as parameter to the method will be the sink, and it will create one sink pad per media type connected.
If otherwise not specified, all types of media are connected by default (AUDIO, VIDEO and DATA). It is recommended to connect the specific types of media if not all of them will be used. For this purpose, the connect method can be invoked more than once on the same two elements, but with different media types.
The connection is unidirectional. If a bidirectional connection is desired, the position of the media elements must be inverted. For instance, webrtc1.connect(webrtc2) is connecting webrtc1 as source of webrtc2. In order to create a WebRTC one-2one conversation, the user would need to specify the connection on the other direction with webrtc2.connect(webrtc1).
Even though one media element can have one sink pad per type of media, only one media element can be connected to another at a given time. If a media element is connected to another, the former will become the source of the sink media element, regardless whether there was another element connected or not.
sink
- the target MediaElement
that will receive mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesvoid connect(MediaElement sink, MediaType mediaType, String sourceMediaDescription, Continuation<Void> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.sink
- the target MediaElement
that will receive mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesconnect(org.kurento.client.MediaElement, org.kurento.client.MediaType, java.lang.String, java.lang.String)
void connect(Transaction tx, MediaElement sink, MediaType mediaType, String sourceMediaDescription)
The element that invokes the connect will be the source of media, creating one sink pad for each type of media connected. The element given as parameter to the method will be the sink, and it will create one sink pad per media type connected.
If otherwise not specified, all types of media are connected by default (AUDIO, VIDEO and DATA). It is recommended to connect the specific types of media if not all of them will be used. For this purpose, the connect method can be invoked more than once on the same two elements, but with different media types.
The connection is unidirectional. If a bidirectional connection is desired, the position of the media elements must be inverted. For instance, webrtc1.connect(webrtc2) is connecting webrtc1 as source of webrtc2. In order to create a WebRTC one-2one conversation, the user would need to specify the connection on the other direction with webrtc2.connect(webrtc1).
Even though one media element can have one sink pad per type of media, only one media element can be connected to another at a given time. If a media element is connected to another, the former will become the source of the sink media element, regardless whether there was another element connected or not.
sink
- the target MediaElement
that will receive mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesvoid disconnect(MediaElement sink)
sink
- the target MediaElement
that will stop receiving mediavoid disconnect(MediaElement sink, Continuation<Void> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.sink
- the target MediaElement
that will stop receiving mediadisconnect(org.kurento.client.MediaElement, org.kurento.client.MediaType, java.lang.String, java.lang.String)
void disconnect(Transaction tx, MediaElement sink)
sink
- the target MediaElement
that will stop receiving mediavoid disconnect(MediaElement sink, MediaType mediaType)
sink
- the target MediaElement
that will stop receiving mediamediaType
- the MediaType
of the pads that will be connectedvoid disconnect(MediaElement sink, MediaType mediaType, Continuation<Void> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.sink
- the target MediaElement
that will stop receiving mediamediaType
- the MediaType
of the pads that will be connecteddisconnect(org.kurento.client.MediaElement, org.kurento.client.MediaType, java.lang.String, java.lang.String)
void disconnect(Transaction tx, MediaElement sink, MediaType mediaType)
sink
- the target MediaElement
that will stop receiving mediamediaType
- the MediaType
of the pads that will be connectedvoid disconnect(MediaElement sink, MediaType mediaType, String sourceMediaDescription)
sink
- the target MediaElement
that will stop receiving mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesvoid disconnect(MediaElement sink, MediaType mediaType, String sourceMediaDescription, Continuation<Void> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.sink
- the target MediaElement
that will stop receiving mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesdisconnect(org.kurento.client.MediaElement, org.kurento.client.MediaType, java.lang.String, java.lang.String)
void disconnect(Transaction tx, MediaElement sink, MediaType mediaType, String sourceMediaDescription)
sink
- the target MediaElement
that will stop receiving mediamediaType
- the MediaType
of the pads that will be connectedsourceMediaDescription
- A textual description of the media source. Currently not used, aimed mainly for MediaType.DATA
sourcesString getGstreamerDot()
The element can be queried for certain type of data:
void getGstreamerDot(Continuation<String> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.TFuture<String> getGstreamerDot(Transaction tx)
The element can be queried for certain type of data:
Map<String,Stats> getStats()
void getStats(Continuation<Map<String,Stats>> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.getStats(org.kurento.client.MediaType)
TFuture<Map<String,Stats>> getStats(Transaction tx)
boolean isMediaFlowingIn(MediaType mediaType)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
void isMediaFlowingIn(MediaType mediaType, Continuation<Boolean> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
isMediaFlowingIn(org.kurento.client.MediaType, java.lang.String)
TFuture<Boolean> isMediaFlowingIn(Transaction tx, MediaType mediaType)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
boolean isMediaFlowingOut(MediaType mediaType)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
void isMediaFlowingOut(MediaType mediaType, Continuation<Boolean> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
isMediaFlowingOut(org.kurento.client.MediaType, java.lang.String)
TFuture<Boolean> isMediaFlowingOut(Transaction tx, MediaType mediaType)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
boolean isMediaTranscoding(MediaType mediaType)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
void isMediaTranscoding(MediaType mediaType, Continuation<Boolean> cont)
Continuation.onSuccess(F)
is called when the action is
done. If an error occurs, Continuation.onError(java.lang.Throwable)
is called.mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
isMediaTranscoding(org.kurento.client.MediaType, java.lang.String)
TFuture<Boolean> isMediaTranscoding(Transaction tx, MediaType mediaType)
mediaType
- One of MediaType.AUDIO
or MediaType.VIDEO
ListenerSubscription addElementConnectedListener(EventListener<ElementConnectedEvent> listener)
EventListener
for event ElementConnectedEvent
. Synchronous call.listener
- Listener to be called on ElementConnectedEventvoid addElementConnectedListener(EventListener<ElementConnectedEvent> listener, Continuation<ListenerSubscription> cont)
EventListener
for event ElementConnectedEvent
. Asynchronous call.
Calls Continuation<ListenerSubscription> when it has been added.listener
- Listener to be called on ElementConnectedEventcont
- Continuation to be called when the listener is registeredvoid removeElementConnectedListener(ListenerSubscription listenerSubscription)
ListenerSubscription
for event ElementConnectedEvent
. Synchronous call.listenerSubscription
- Listener subscription to be removedvoid removeElementConnectedListener(ListenerSubscription listenerSubscription, Continuation<Void> cont)
ListenerSubscription
for event ElementConnectedEvent
. Asynchronous call.
Calls Continuation<Void> when it has been removed.listenerSubscription
- Listener subscription to be removedcont
- Continuation to be called when the listener is removedListenerSubscription addElementDisconnectedListener(EventListener<ElementDisconnectedEvent> listener)
EventListener
for event ElementDisconnectedEvent
. Synchronous call.listener
- Listener to be called on ElementDisconnectedEventvoid addElementDisconnectedListener(EventListener<ElementDisconnectedEvent> listener, Continuation<ListenerSubscription> cont)
EventListener
for event ElementDisconnectedEvent
. Asynchronous call.
Calls Continuation<ListenerSubscription> when it has been added.listener
- Listener to be called on ElementDisconnectedEventcont
- Continuation to be called when the listener is registeredvoid removeElementDisconnectedListener(ListenerSubscription listenerSubscription)
ListenerSubscription
for event ElementDisconnectedEvent
. Synchronous call.listenerSubscription
- Listener subscription to be removedvoid removeElementDisconnectedListener(ListenerSubscription listenerSubscription, Continuation<Void> cont)
ListenerSubscription
for event ElementDisconnectedEvent
. Asynchronous call.
Calls Continuation<Void> when it has been removed.listenerSubscription
- Listener subscription to be removedcont
- Continuation to be called when the listener is removedListenerSubscription addMediaFlowOutStateChangeListener(EventListener<MediaFlowOutStateChangeEvent> listener)
EventListener
for event MediaFlowOutStateChangeEvent
. Synchronous call.listener
- Listener to be called on MediaFlowOutStateChangeEventvoid addMediaFlowOutStateChangeListener(EventListener<MediaFlowOutStateChangeEvent> listener, Continuation<ListenerSubscription> cont)
EventListener
for event MediaFlowOutStateChangeEvent
. Asynchronous call.
Calls Continuation<ListenerSubscription> when it has been added.listener
- Listener to be called on MediaFlowOutStateChangeEventcont
- Continuation to be called when the listener is registeredvoid removeMediaFlowOutStateChangeListener(ListenerSubscription listenerSubscription)
ListenerSubscription
for event MediaFlowOutStateChangeEvent
. Synchronous call.listenerSubscription
- Listener subscription to be removedvoid removeMediaFlowOutStateChangeListener(ListenerSubscription listenerSubscription, Continuation<Void> cont)
ListenerSubscription
for event MediaFlowOutStateChangeEvent
. Asynchronous call.
Calls Continuation<Void> when it has been removed.listenerSubscription
- Listener subscription to be removedcont
- Continuation to be called when the listener is removedListenerSubscription addMediaFlowOutStateChangedListener(EventListener<MediaFlowOutStateChangedEvent> listener)
EventListener
for event MediaFlowOutStateChangedEvent
. Synchronous call.listener
- Listener to be called on MediaFlowOutStateChangedEventvoid addMediaFlowOutStateChangedListener(EventListener<MediaFlowOutStateChangedEvent> listener, Continuation<ListenerSubscription> cont)
EventListener
for event MediaFlowOutStateChangedEvent
. Asynchronous call.
Calls Continuation<ListenerSubscription> when it has been added.listener
- Listener to be called on MediaFlowOutStateChangedEventcont
- Continuation to be called when the listener is registeredvoid removeMediaFlowOutStateChangedListener(ListenerSubscription listenerSubscription)
ListenerSubscription
for event MediaFlowOutStateChangedEvent
. Synchronous call.listenerSubscription
- Listener subscription to be removedvoid removeMediaFlowOutStateChangedListener(ListenerSubscription listenerSubscription, Continuation<Void> cont)
ListenerSubscription
for event MediaFlowOutStateChangedEvent
. Asynchronous call.
Calls Continuation<Void> when it has been removed.listenerSubscription
- Listener subscription to be removedcont
- Continuation to be called when the listener is removedListenerSubscription addMediaFlowInStateChangeListener(EventListener<MediaFlowInStateChangeEvent> listener)
EventListener
for event MediaFlowInStateChangeEvent
. Synchronous call.listener
- Listener to be called on MediaFlowInStateChangeEventvoid addMediaFlowInStateChangeListener(EventListener<MediaFlowInStateChangeEvent> listener, Continuation<ListenerSubscription> cont)
EventListener
for event MediaFlowInStateChangeEvent
. Asynchronous call.
Calls Continuation<ListenerSubscription> when it has been added.listener
- Listener to be called on MediaFlowInStateChangeEventcont
- Continuation to be called when the listener is registeredvoid removeMediaFlowInStateChangeListener(ListenerSubscription listenerSubscription)
ListenerSubscription
for event MediaFlowInStateChangeEvent
. Synchronous call.listenerSubscription
- Listener subscription to be removedvoid removeMediaFlowInStateChangeListener(ListenerSubscription listenerSubscription, Continuation<Void> cont)
ListenerSubscription
for event MediaFlowInStateChangeEvent
. Asynchronous call.
Calls Continuation<Void> when it has been removed.listenerSubscription
- Listener subscription to be removedcont
- Continuation to be called when the listener is removedListenerSubscription addMediaFlowInStateChangedListener(EventListener<MediaFlowInStateChangedEvent> listener)
EventListener
for event MediaFlowInStateChangedEvent
. Synchronous call.listener
- Listener to be called on MediaFlowInStateChangedEventvoid addMediaFlowInStateChangedListener(EventListener<MediaFlowInStateChangedEvent> listener, Continuation<ListenerSubscription> cont)
EventListener
for event MediaFlowInStateChangedEvent
. Asynchronous call.
Calls Continuation<ListenerSubscription> when it has been added.listener
- Listener to be called on MediaFlowInStateChangedEventcont
- Continuation to be called when the listener is registeredvoid removeMediaFlowInStateChangedListener(ListenerSubscription listenerSubscription)
ListenerSubscription
for event MediaFlowInStateChangedEvent
. Synchronous call.listenerSubscription
- Listener subscription to be removedvoid removeMediaFlowInStateChangedListener(ListenerSubscription listenerSubscription, Continuation<Void> cont)
ListenerSubscription
for event MediaFlowInStateChangedEvent
. Asynchronous call.
Calls Continuation<Void> when it has been removed.listenerSubscription
- Listener subscription to be removedcont
- Continuation to be called when the listener is removedListenerSubscription addMediaTranscodingStateChangeListener(EventListener<MediaTranscodingStateChangeEvent> listener)
EventListener
for event MediaTranscodingStateChangeEvent
. Synchronous call.listener
- Listener to be called on MediaTranscodingStateChangeEventvoid addMediaTranscodingStateChangeListener(EventListener<MediaTranscodingStateChangeEvent> listener, Continuation<ListenerSubscription> cont)
EventListener
for event MediaTranscodingStateChangeEvent
. Asynchronous call.
Calls Continuation<ListenerSubscription> when it has been added.listener
- Listener to be called on MediaTranscodingStateChangeEventcont
- Continuation to be called when the listener is registeredvoid removeMediaTranscodingStateChangeListener(ListenerSubscription listenerSubscription)
ListenerSubscription
for event MediaTranscodingStateChangeEvent
. Synchronous call.listenerSubscription
- Listener subscription to be removedvoid removeMediaTranscodingStateChangeListener(ListenerSubscription listenerSubscription, Continuation<Void> cont)
ListenerSubscription
for event MediaTranscodingStateChangeEvent
. Asynchronous call.
Calls Continuation<Void> when it has been removed.listenerSubscription
- Listener subscription to be removedcont
- Continuation to be called when the listener is removedListenerSubscription addMediaTranscodingStateChangedListener(EventListener<MediaTranscodingStateChangedEvent> listener)
EventListener
for event MediaTranscodingStateChangedEvent
. Synchronous call.listener
- Listener to be called on MediaTranscodingStateChangedEventvoid addMediaTranscodingStateChangedListener(EventListener<MediaTranscodingStateChangedEvent> listener, Continuation<ListenerSubscription> cont)
EventListener
for event MediaTranscodingStateChangedEvent
. Asynchronous call.
Calls Continuation<ListenerSubscription> when it has been added.listener
- Listener to be called on MediaTranscodingStateChangedEventcont
- Continuation to be called when the listener is registeredvoid removeMediaTranscodingStateChangedListener(ListenerSubscription listenerSubscription)
ListenerSubscription
for event MediaTranscodingStateChangedEvent
. Synchronous call.listenerSubscription
- Listener subscription to be removedvoid removeMediaTranscodingStateChangedListener(ListenerSubscription listenerSubscription, Continuation<Void> cont)
ListenerSubscription
for event MediaTranscodingStateChangedEvent
. Asynchronous call.
Calls Continuation<Void> when it has been removed.listenerSubscription
- Listener subscription to be removedcont
- Continuation to be called when the listener is removedCopyright © 2022 Kurento. All rights reserved.