|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.skype.ipc.SidObject
com.skype.api.Video
public final class Video
This class contains basic video control functionality for live conversations with video. Basically, Video objects represent specific Participant's video state in a live Conversation. The Video class can represent both local (outgoing) and remote (incoming) video streams. Note that as of SkypeKit SDK version 3.2, this class no longer handles video rendering in the UI. Currently available SkypeKit runtimes do not support multi-party video. The API however is designed with future compatibility in mind, so the Video class is attached to Participant class rather than Conversation class. Once multi-party video will become available for SkypeKit, the logic should go like this: Let there be 4-way live conversation C and participants P1, P2, P3 and P4. P1 is the local user. Remote participants P2 and P3 are capable of sending video. Remote user P4 is not capable of sending video. You would then end up with 4 video objects: V1, V2, V3 and V0. - C->P1->V1-> outgoing video stream - C->P2->V2-> incoming video stream 1 - C->P3->V3-> incoming video stream 2 - C->P4-> no video object as participant P4 does not advertise supporting video - V0-> local webcam preview - this is not attached to any particular conversation, however the corresponding video object can be retrieved with Skype.GetPreviewVideo method. As getting from a live conversation to running video streams involves three classes, it can be somewhat less than obvious. The basic state transition logic goes like this: You start out with a Conversation, that suddenly becomes live CONVERSATION.LOCAL_LIVESTATUS = IM_LIVE At this point you have access to participant list of that conversation. The next step will be to catch Partcipant property changes for PARTICIPANT.VIDEO_STATUS to see if any of the people in conversation have Video available. Note that you should not make assumptions on when this availability happens. Remote users may switch their video on-off as they please. PARTICIPANT.VIDEO_STATUS = VIDEO_AVAILABLE If you get to VIDEO_AVAILABLE (not necessarily for all Participants), you can retrieve Video object, with Participant.GetVideo method. Now you will need to handle Video.STATUS property changes. In case of successful video call, the sequence of Video.STATUS and Participant.VIDEO_STATUS changes for each Participant and Video object should look like this: - Video.STATUS = AVAILABLE - Video.STATUS = STARTING - Video.STATUS = CHECKING_SUBSCRIPTION - Video.STATUS = STARTING Participant.VIDEO_STATUS = VIDEO_CONNECTING - Video.STATUS = RUNNING - Participant.VIDEO_STATUS = STREAMING Both Video.STATUS == RUNNING and Participant.VIDEO_STATUS == STREAMING are indicative that the video for that particular participant is up and running, and your UI should update itself accordingly. NB! Note that it is not enough to check for Video.STATUS property updates. By the time you obtain the Video object in your client, it may already it may already have progressed to a further status. You should always check the status property immediately after obtaining the Video object.
| Nested Class Summary | |
|---|---|
class |
Video.GetCurrentVideoDeviceResponse
|
static class |
Video.MediaType
|
static class |
Video.Property
Properties of the Video class |
static class |
Video.Status
|
class |
Video.SubmitCaptureRequestResponse
|
static class |
Video.VideoDeviceCapability
|
| Field Summary | |
|---|---|
Conversation |
mConvoId
|
java.lang.String |
mDebugInfo
|
java.lang.String |
mDevicePath
|
java.lang.String |
mDimensions
|
java.lang.String |
mError
|
Video.MediaType |
mMediaType
|
Video.Status |
mStatus
|
static java.lang.String |
VIDEO_ADVERTPOLICY
Setupkey SETUPKEY_VIDEO_ADVERTPOLICY type:string default value:"contacts" noone | contacts | everyone This is account-specific setup key. |
static java.lang.String |
VIDEO_AUTOSEND
Setupkey SETUPKEY_VIDEO_AUTOSEND type:int Setting this to 1 starts sending video automatically when call starts This is account-specific setup key. |
static java.lang.String |
VIDEO_DEVICE
Setupkey SETUPKEY_VIDEO_DEVICE type:string Selected video device name This is account-specific setup key. |
static java.lang.String |
VIDEO_DEVICE_PATH
Setupkey SETUPKEY_VIDEO_DEVICE_PATH type:string Currently selected video device path. |
static java.lang.String |
VIDEO_DISABLE
Setupkey SETUPKEY_VIDEO_DISABLE type:int Setting this to 1 disables all video functionality. |
static java.lang.String |
VIDEO_RECVPOLICY
Setupkey SETUPKEY_VIDEO_RECVPOLICY type:string default value:"contacts" noone | contacts | callpolicy This is account-specific setup key. |
| Fields inherited from class com.skype.ipc.SidObject |
|---|
mSidCached, mSidOid, mSidRoot, mSidTimestamp |
| Constructor Summary | |
|---|---|
Video(int oid,
SidRoot root)
|
|
| Method Summary | |
|---|---|
Conversation |
getConvoId()
conference id to be able to identify remote/local video in the same call |
Video.GetCurrentVideoDeviceResponse |
getCurrentVideoDevice()
getCurrentVideoDevice |
java.lang.String |
getDebugInfo()
space-separated string of tokens |
java.lang.String |
getDevicePath()
device path used by video object |
java.lang.String |
getDimensions()
This property does not currently work, always containing an empty string. |
java.lang.String |
getError()
'errorcode errortext' |
Video.MediaType |
getMediaType()
Indicates whether the video object is streaming webcam video or screensharing session, values: MEDIA_SCREENSHARING, MEDIA_VIDEO |
java.lang.String |
getPropertyAsString(int prop)
|
java.lang.String |
getPropertyAsString(Video.Property prop)
|
Video.Status |
getStatus()
Video.STATUS |
int |
moduleId()
|
void |
selectVideoSource(Video.MediaType mediaType,
java.lang.String webcamName,
java.lang.String devicePath,
boolean updateSetup)
This method has no effect in current version. |
void |
setRemoteRendererId(int id)
setRemoteRendererId |
void |
setRenderRectangle(int x0,
int y0,
int width,
int height)
setRenderRectangle |
void |
setScreen(int windowh)
setScreen |
void |
setScreenCaptureRectangle(int x0,
int y0,
int width,
int height,
int monitorNumber,
int windowHandle)
This method has no known effect in current version. |
EnumConverting |
sidGetEnumProperty(PropertyEnumConverting prop)
|
SidObject |
sidGetObjectProperty(PropertyEnumConverting prop)
|
java.lang.String |
sidGetStringProperty(PropertyEnumConverting prop)
|
SidGetResponding |
sidMultiGet(Video.Property[] requested)
generic multiget of a list of Property |
static SidGetResponding[] |
sidMultiGet(Video.Property[] requested,
Video[] objects)
generic multiget of list of Property for a list of Video |
protected void |
sidOnChangedProperty(int propertyId,
int value,
java.lang.String svalue)
|
void |
sidSetProperty(PropertyEnumConverting prop,
int newValue)
|
void |
sidSetProperty(PropertyEnumConverting prop,
SidObject newValue)
|
void |
sidSetProperty(PropertyEnumConverting prop,
java.lang.String newValue)
|
void |
start()
This method starts either video send or video receive, depending on whether the video object is sender or receiver. |
void |
stop()
This method stops either video send or video receive, depending on whether the video object is sender or receiver. |
Video.SubmitCaptureRequestResponse |
submitCaptureRequest()
submitCaptureRequest |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String VIDEO_DEVICE
public static final java.lang.String VIDEO_DEVICE_PATH
public static final java.lang.String VIDEO_AUTOSEND
public static final java.lang.String VIDEO_DISABLE
public static final java.lang.String VIDEO_RECVPOLICY
public static final java.lang.String VIDEO_ADVERTPOLICY
public Video.Status mStatus
public java.lang.String mError
public java.lang.String mDebugInfo
public java.lang.String mDimensions
public Video.MediaType mMediaType
public Conversation mConvoId
public java.lang.String mDevicePath
| Constructor Detail |
|---|
public Video(int oid,
SidRoot root)
| Method Detail |
|---|
public void setScreen(int windowh)
windowh - public void start()
public void stop()
public Video.SubmitCaptureRequestResponse submitCaptureRequest()
public void setScreenCaptureRectangle(int x0,
int y0,
int width,
int height,
int monitorNumber,
int windowHandle)
y0 - width - height - monitorNumber - windowHandle -
public void setRenderRectangle(int x0,
int y0,
int width,
int height)
x0 - y0 - width - height - public void setRemoteRendererId(int id)
id -
public void selectVideoSource(Video.MediaType mediaType,
java.lang.String webcamName,
java.lang.String devicePath,
boolean updateSetup)
webcamName - devicePath - updateSetup - public Video.GetCurrentVideoDeviceResponse getCurrentVideoDevice()
public SidGetResponding sidMultiGet(Video.Property[] requested)
requested - the list of requested properties of Video
public static SidGetResponding[] sidMultiGet(Video.Property[] requested,
Video[] objects)
requested - the list of requested properties
public Video.Status getStatus()
public java.lang.String getError()
public java.lang.String getDebugInfo()
public java.lang.String getDimensions()
public Video.MediaType getMediaType()
public Conversation getConvoId()
public java.lang.String getDevicePath()
public java.lang.String sidGetStringProperty(PropertyEnumConverting prop)
sidGetStringProperty in interface SidGetRespondingsidGetStringProperty in class SidObjectpublic SidObject sidGetObjectProperty(PropertyEnumConverting prop)
sidGetObjectProperty in interface SidGetRespondingsidGetObjectProperty in class SidObjectpublic EnumConverting sidGetEnumProperty(PropertyEnumConverting prop)
sidGetEnumProperty in interface SidGetRespondingsidGetEnumProperty in class SidObjectpublic java.lang.String getPropertyAsString(int prop)
public java.lang.String getPropertyAsString(Video.Property prop)
protected void sidOnChangedProperty(int propertyId,
int value,
java.lang.String svalue)
sidOnChangedProperty in class SidObject
public void sidSetProperty(PropertyEnumConverting prop,
java.lang.String newValue)
sidSetProperty in interface SidGetRespondingsidSetProperty in class SidObject
public void sidSetProperty(PropertyEnumConverting prop,
SidObject newValue)
sidSetProperty in interface SidGetRespondingsidSetProperty in class SidObject
public void sidSetProperty(PropertyEnumConverting prop,
int newValue)
sidSetProperty in interface SidGetRespondingsidSetProperty in class SidObjectpublic int moduleId()
moduleId in class SidObject
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||