|
Jitsi: the OpenSource Java VoIP and Instant Messaging client. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.java.sip.communicator.util.event.PropertyChangeNotifier
net.java.sip.communicator.impl.neomedia.MediaServiceImpl
public class MediaServiceImpl
Implements MediaService for JMF.
| Field Summary | |
|---|---|
static String |
DISABLE_AUDIO_SUPPORT_PNAME
The name of the boolean ConfigurationService property which indicates whether the detection of audio CaptureDevices is to be disabled. |
static String |
DISABLE_VIDEO_SUPPORT_PNAME
The name of the boolean ConfigurationService property which indicates whether the detection of video CaptureDevices is to be disabled. |
| Fields inherited from interface net.java.sip.communicator.service.neomedia.MediaService |
|---|
DEFAULT_DEVICE |
| Constructor Summary | |
|---|---|
MediaServiceImpl()
Initializes a new MediaServiceImpl instance. |
|
| Method Summary | |
|---|---|
void |
addRecorderListener(Recorder.Listener listener)
Those interested in Recorder events add listener through MediaService. |
MediaStream |
createMediaStream(MediaDevice device)
Create a MediaStream which will use a specific MediaDevice for capture and playback of media. |
MediaStream |
createMediaStream(StreamConnector connector,
MediaDevice device)
Creates a new MediaStream instance which will use the specified MediaDevice for both capture and playback of media exchanged via the specified StreamConnector. |
MediaStream |
createMediaStream(StreamConnector connector,
MediaDevice device,
SrtpControl srtpControl)
Creates a new MediaStream instance which will use the specified MediaDevice for both capture and playback of media exchanged via the specified StreamConnector. |
MediaDevice |
createMixer(MediaDevice device)
Creates a new MediaDevice which uses a specific MediaDevice to capture and play back media and performs mixing of the captured media and the media played back by any other users of the returned MediaDevice. |
Recorder |
createRecorder(MediaDevice device)
Creates a new Recorder instance that can be used to record a call which captures and plays back media using a specific MediaDevice. |
RTPTranslator |
createRTPTranslator()
Initializes a new RTPTranslator which is to forward RTP and RTCP traffic between multiple MediaStreams. |
SDesControl |
createSDesControl()
Initializes a new SDesControl instance which is to control all SDes options. |
ZrtpControl |
createZrtpControl()
Initializes a new ZrtpControl instance which is to control all ZRTP options. |
List<ScreenDevice> |
getAvailableScreenDevices()
Get available screens. |
MediaDevice |
getDefaultDevice(MediaType mediaType,
MediaUseCase useCase)
Gets the default MediaDevice for the specified MediaType. |
ScreenDevice |
getDefaultScreenDevice()
Get default screen device. |
DeviceConfiguration |
getDeviceConfiguration()
Gets the CaptureDevice user choices such as the default audio and video capture devices. |
List<MediaDevice> |
getDevices(MediaType mediaType,
MediaUseCase useCase)
Gets a list of the MediaDevices known to this MediaService and handling the specified MediaType. |
Map<MediaFormat,Byte> |
getDynamicPayloadTypePreferences()
Returns a Map that binds indicates whatever preferences this
media service implementation may have for the RTP payload type numbers
that get dynamically assigned to MediaFormats with no static
payload type. |
EncodingConfiguration |
getEncodingConfiguration()
Gets the format-related user choices such as the enabled and disabled codecs and the order of their preference. |
MediaFormatFactory |
getFormatFactory()
Gets the MediaFormatFactory through which MediaFormat instances may be created for the purposes of working with the MediaStreams created by this MediaService. |
VolumeControl |
getInputVolumeControl()
Gets the VolumeControl which controls the volume level of audio input/capture. |
MediaDevice |
getMediaDeviceForPartialDesktopStreaming(int width,
int height,
int x,
int y)
Get a MediaDevice for a part of desktop streaming/sharing. |
Point |
getOriginForDesktopStreamingDevice(MediaDevice mediaDevice)
Gets the origin of a specific desktop streaming device. |
VolumeControl |
getOutputVolumeControl()
Gets the VolumeControl which controls the volume level of audio output/playback. |
Iterator<Recorder.Listener> |
getRecorderListeners()
Gives access to currently registered Recorder.Listeners. |
ScreenDevice |
getScreenForPoint(Point p)
Find the screen device that contains specified point. |
Object |
getVideoPreviewComponent(MediaDevice device,
int preferredWidth,
int preferredHeight)
Creates a preview component for the specified device(video device) used to show video preview from that device. |
boolean |
isPartialStreaming(MediaDevice mediaDevice)
If the MediaDevice corresponds to partial desktop streaming device. |
void |
removeRecorderListener(Recorder.Listener listener)
Removes an existing Recorder.Listener from the list of listeners interested in notifications from Recorders. |
(package private) void |
start()
Starts this MediaService implementation and thus makes it operational. |
(package private) void |
stop()
Stops this MediaService implementation and thus signals that its utilization should cease. |
| Methods inherited from class net.java.sip.communicator.util.event.PropertyChangeNotifier |
|---|
addPropertyChangeListener, firePropertyChange, getPropertyChangeSource, removePropertyChangeListener |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface net.java.sip.communicator.service.neomedia.MediaService |
|---|
addPropertyChangeListener, removePropertyChangeListener |
| Field Detail |
|---|
public static final String DISABLE_AUDIO_SUPPORT_PNAME
public static final String DISABLE_VIDEO_SUPPORT_PNAME
| Constructor Detail |
|---|
public MediaServiceImpl()
| Method Detail |
|---|
public MediaStream createMediaStream(MediaDevice device)
createMediaStream in interface MediaServicedevice - the MediaDevice to be used by the new instance for
capture and playback of media
MediaService.createMediaStream(MediaDevice)
public MediaStream createMediaStream(StreamConnector connector,
MediaDevice device)
createMediaStream in interface MediaServiceconnector - the StreamConnector that the new
MediaStream instance is to use for sending and receiving mediadevice - the MediaDevice that the new MediaStream
instance is to use for both capture and playback of media exchanged via
the specified connector
MediaService.createMediaStream(StreamConnector, MediaDevice)
public MediaStream createMediaStream(StreamConnector connector,
MediaDevice device,
SrtpControl srtpControl)
createMediaStream in interface MediaServiceconnector - the StreamConnector that the new
MediaStream instance is to use for sending and receiving mediadevice - the MediaDevice that the new MediaStream
instance is to use for both capture and playback of media exchanged via
the specified connectorsrtpControl - a control which is already created, used to control
the srtp operations.
MediaService.createMediaStream(StreamConnector, MediaDevice)public MediaDevice createMixer(MediaDevice device)
createMixer in interface MediaServicedevice - the MediaDevice which is to be used by the
returned MediaDevice to actually capture and play back media
MediaService.createMixer(MediaDevice)
public MediaDevice getDefaultDevice(MediaType mediaType,
MediaUseCase useCase)
getDefaultDevice in interface MediaServicemediaType - a MediaType value indicating the type of media
to be handled by the MediaDevice to be obtaineduseCase - the MediaUseCase to obtain the
MediaDevice list for
MediaService.getDefaultDevice(MediaType, MediaUseCase)public DeviceConfiguration getDeviceConfiguration()
public List<MediaDevice> getDevices(MediaType mediaType,
MediaUseCase useCase)
getDevices in interface MediaServicemediaType - the MediaType to obtain the
MediaDevice list foruseCase - the MediaUseCase to obtain the
MediaDevice list for
MediaService.getDevices(MediaType, MediaUseCase)public EncodingConfiguration getEncodingConfiguration()
public MediaFormatFactory getFormatFactory()
getFormatFactory in interface MediaServiceMediaService.getFormatFactory()void start()
void stop()
public ZrtpControl createZrtpControl()
createZrtpControl in interface MediaServicepublic SDesControl createSDesControl()
createSDesControl in interface MediaServicepublic VolumeControl getOutputVolumeControl()
getOutputVolumeControl in interface MediaServiceMediaService.getOutputVolumeControl()public VolumeControl getInputVolumeControl()
getInputVolumeControl in interface MediaServiceMediaService.getInputVolumeControl()public List<ScreenDevice> getAvailableScreenDevices()
getAvailableScreenDevices in interface MediaServicepublic ScreenDevice getDefaultScreenDevice()
getDefaultScreenDevice in interface MediaServicepublic Recorder createRecorder(MediaDevice device)
createRecorder in interface MediaServicedevice - the MediaDevice which is used for media capture
and playback by the call to be recorded
MediaService.createRecorder(MediaDevice)public Map<MediaFormat,Byte> getDynamicPayloadTypePreferences()
Map that binds indicates whatever preferences this
media service implementation may have for the RTP payload type numbers
that get dynamically assigned to MediaFormats with no static
payload type. The method is useful for formats such as "telephone-event"
for example that is statically assigned the 101 payload type by some
legacy systems. Signaling protocol implementations such as SIP and XMPP
should make sure that, whenever this is possible, they assign to formats
the dynamic payload type returned in this Map.
getDynamicPayloadTypePreferences in interface MediaServiceMap binding some formats to a preferred dynamic RTP
payload type number.
public Object getVideoPreviewComponent(MediaDevice device,
int preferredWidth,
int preferredHeight)
getVideoPreviewComponent in interface MediaServicedevice - the video devicepreferredWidth - the width we prefer for the componentpreferredHeight - the height we prefer for the component
public MediaDevice getMediaDeviceForPartialDesktopStreaming(int width,
int height,
int x,
int y)
getMediaDeviceForPartialDesktopStreaming in interface MediaServicewidth - width of the partheight - height of the partx - origin of the x coordinate (relative to the full desktop)y - origin of the y coordinate (relative to the full desktop)
public boolean isPartialStreaming(MediaDevice mediaDevice)
isPartialStreaming in interface MediaServicemediaDevice - MediaDevice
public ScreenDevice getScreenForPoint(Point p)
p - point coordinates
public Point getOriginForDesktopStreamingDevice(MediaDevice mediaDevice)
getOriginForDesktopStreamingDevice in interface MediaServicemediaDevice - the desktop streaming device to get the origin on
public void addRecorderListener(Recorder.Listener listener)
addRecorderListener in interface MediaServicelistener - the new Recorder.Listener to be added to the
list of listeners interested in notifications from Recorders.public void removeRecorderListener(Recorder.Listener listener)
removeRecorderListener in interface MediaServicelistener - the existing Listener to be removed from the
list of listeners interested in notifications from Recorderspublic Iterator<Recorder.Listener> getRecorderListeners()
getRecorderListeners in interface MediaServicepublic RTPTranslator createRTPTranslator()
createRTPTranslator in interface MediaServiceMediaService.createRTPTranslator()
|
Jitsi: the OpenSource Java VoIP and Instant Messaging client. | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||