Help - Search - Members - Calendar
Full Version: Start full-screen video call with API (Skype 4.0.0.161)
Skype Community > English > Development, Betas and Skype Garage > Public API
Ruslan-spb
Hi.

I want to start full-screen video call from "Skype API Tracer".
I change some skype options:
Tools->Options->Calls->Show advanced option.

Check:
Answer incoming calls automatically
Start my video automatically when I am in a call
Switch to full-screen for incoming video calls

In tracer I write:
CALL <username>
After connection (CALL <id> STATUS INPROGRESS), i start send video from my camera:
ALTER CALL <id> START_VIDEO_SEND
and wait
VIDEO_SEND_STATUS RUNNING

All that is good work: my camera send video and my friend see me.
My friend have a camera too and when I call with skype video call, we see each other in full screen.
But, when I call in tracer with API video call start, but not show video until I select this call in contact list in skype.
How can I simulate this click with API or some else?

In API I found command GET CONTACTS_FOCUSED, but not found SET CONTACTS FOCUSED.

I want to start full-screen video call without click on skype UI. Is't possible?

P.S. Sorry for my bad English smile.png
Avo Nappo
> But, when I call in tracer with API video call start, but not
> show video until I select this call in contact list in skype.

Sorry, I'm confused here.

In your first example you also initiated call via tracer and started the video:

CALL <username>
ALTER CALL <id> START_VIDEO_SEND

If I understand correctly, under some circumstances this does not work and requires manual click on contact in Skype UI. What did you do differently, from the first case?
Ruslan-spb
In first case this don't work too. I see the call in Skype UI and my camera is start to work, but I don't see a video.

Skype require a focus on contact list and then it show video without problem.

The first of all, close skype and run it again (focus not in contact list).
Then send a command with tracer, video not show, but my friend (using Skype UI) see me and his camera is working.
If I click on contact in Skype UI - video is show on full-screen.
If I repeat call with API, video is showing without problem.

My question is:
Can I show video in full-screen mode without using Skype UI (using Skype API) or I always need to click on call in Skype UI?
TheUberOverlord
Actually this is very easy to do, once the contact is in focus, use the "Yes" button" this will start the call.

Here is a Skype4COM example that can emulate this:

http://www.saveontelephonebills.com/skype/...beta/Client.htm

API:

-> BTN_RELEASED YES
<- BTN_RELEASED YES

From: https://developer.skype.com/Docs/ApiDoc/BTN...nd_BTN_RELEASED

FYI BTN_RELEASED NO will end the call.
Ruslan-spb
I tested this command - BTN_RELEASED, but BTN_RELEASED YES command start the call when contact is focused in contact list. And I need video call when focus is not in contact list.
When you fully close Skype and run it again, focus is not in contact list and you don't call on number "abc.xzy", because "-> BTN_RELEASED ." is error.
If you call with "CALL abc.xyz", the command "BTN_RELEASED YES" don't start full-screen video.
TheUberOverlord
You need to read the API documentation

https://developer.skype.com/Docs/ApiDoc/OPEN_CONTACTS

This will first place the Skype client contacts tab in focus.

I gave you a link that shows a working example in Skype4COM on how to do this, please take some time to try playing with it and to read the "Controlling Skype user interface" API documentation here as well:

https://developer.skype.com/Docs/ApiDoc/Con..._user_interface

Ruslan-spb
I tested it:
-> OPEN CONTACTS
<- OPEN CONTACTS

-> GET CONTACTS_FOCUSED
<- CONTACTS FOCUSED

The really, focus is not in contact list. "GET CONTACTS_FOCUSED" return empty result.

https://developer.skype.com/Docs/ApiDoc/Con..._user_interface
I tested all this command and video don't show in full-screen mode.

http://www.saveontelephonebills.com/skype/...beta/Client.htm
This link is work, but I can't call the number with symbol ".".
For example: skype number "abc.xyz" is correct, but "-> BTN_RELEASED ." is error.
TheUberOverlord
Please change the example for your testing needs, but also please remember you are testing with a BETA release of the Skype for Windows client, that may in fact have some differences and you won't get the same results in all cases as you would with the more stable Skype for Client windows releases.
Ruslan-spb
Thank for you answering.
I find the way from this situation:
1) call to the number with command "CALL <number>";
2) send command "BTN_RELEASE NO" after call at once, the Skype UI is show the user that I call;
3) send command "BTN_RELEASE YES" and skype show full-screen video.

That is no a best way, but it's only one way that all work.
TheUberOverlord
Not sure why you can't do this?

SET CALL <id> STATUS FINISHED
Ruslan-spb
If I send "SET CALL <id> STATUS FINISHED" Skype not show the user in Skype UI and then Skype not start in full-screen video mode.
TheUberOverlord
ok
jawdropped
Ive noticed in the new 4.0 skype no longer has the option to "start my video automatically when i am in a call". I have a scripting background but do not understand how to fast track an option in skype when accepting a call or making a call to...
1. start my video automatically
2. make the video full screen.

How can I make the modifications and implement them? Thank you.

I am planning to make this mod for my grandparents who are using skype on an HTPC with a Logitech USB wireless phone. When they call or answer a call using the phone I would like it to start their video automatically and show full screen mode. They are 80 years old and do not understand anything else but how to work a phone and a TV remote. So a keyboard and mouse is not connected to the machine with skype.

Any step-by-step help would be greatly appreciated. Thanks again.

- Jawdropped
Avo Nappo
> Ive noticed in the new 4.0 skype no longer has the option to
> "start my video automatically when i am in a call".

Aye, you can currently only auto-accept video from incoming calls.

> how to fast track an option in skype when accepting a call or
> making a call to...

The easiest way under Windows would be to use use a language that enables you to use activex objects and then use skype object from skype4com.dll.

Good place to start with would be this page:
https://developer.skype.com/Docs/Skype4COM/Example

Autostarting video on outgoing calls is quite possible.

Making the video fullscreen is a bit more difficult. There is currently no API command for that. The only way would be to find out screen coordinates of the Fullscren button in Skype's video panel and emulate a mouseclick on it. The problem with that approach is that as this is not officially supported, any new Skype version would be quite likely to break this hack.
Remko van Dokkum
using Skype4COM-1.0.31.0 and skype 4.0.0.226

all using Skype4COM api i managed to start a call and full screen video.

i did set the option in skype to ''switch to full-screen for incoming video-calls''

first i opened a chat window
then i started the call
then i started sending video

the video goes to full-screen automatically.

the skype client receiving the call also has the option on for ''switch to full-screen for incoming video-calls''
TheUberOverlord
Gald to hear you got it working.
John.Doe
QUOTE (Avo Nappo @ Mon Mar 2 2009, 17:27)
Go to the original post
The only way would be to find out screen coordinates of the Fullscren button in Skype's video panel and emulate a mouseclick on it. The problem with that approach is that as this is not officially supported, any new Skype version would be quite likely to break this hack.


Well.... I am working on a little program, that might need to interact with the Skype UI that way (maybe even a bit more) for one particular feature. There are multiple failsafes, e.g. I am trying to find the handle of the control I want to interact with and if I don't, I deactive the feature assuming that the Skype version is different than the one I developed for.
Nevertheless, as you said, this is not officially supported - but is it OK for a program to use not officially supported methods if the feature is marked big and fat as an experimental, unsupported, use at your own risc?

I think eventually I want to just put the program out there for anyone to use maybe with a PayPal donate button or so (even though nobody ever donates anyway wink.png).

EDIT: What Avo Nappo describes here in his last post http://forum.skype.com/index.php?showtopic=109965 is very similar to what I do in one part of my app as well.
Avo Nappo
> but is it OK for a program to use not officially supported methods

You mean is it legal?

Well, Public API Terms of Use are here: http://www.skype.com/intl/en/legal/terms/api/

The relevant piece there would be from 3.2:

"Without the prior written consent of Skype, You will not remove or hide (save as permitted in API command "set silent_mode on"), modify, take over or otherwise alter the User Interface."

You will need to consider: regardless of method, could the operation of your feature be reasonalbly classified as "taking over Skype UI".

I'd say sending a mouseclick to get fullscreen video definitely isn't that. Causing Skype main window to run away from the mouse cursor definitely would be smile.png
John.Doe
QUOTE (Avo Nappo @ Thu Jun 4 2009, 17:22)
Go to the original post
You will need to consider: regardless of method, could the operation of your feature be reasonalbly classified as "taking over Skype UI".

I'd say sending a mouseclick to get fullscreen video definitely isn't that. Causing Skype main window to run away from the mouse cursor definitely would be smile.png

Well, I will see if I can achieve what I want with simple things - although I doubt it. So I might then just write that particular feature for personal use and never publish it... or if it is truly super awesome wink.png I can try to contact Skype to see what they say - I don't want to get into any kind of legal troubles...
irisandzoran
skype no longer has the
option Video call only call. Can anybody tell me why?
Ta Zoran

skype no longer has the
option Video call only call. Can anybody tell me why?
Ta Zoran
TheUberOverlord
Please explain, what method of the public API do you think was removed/modified?
John.Doe
QUOTE (Avo Nappo @ Thu Jun 4 2009, 17:22)
Go to the original post
You will need to consider: regardless of method, could the operation of your feature be reasonalbly classified as "taking over Skype UI".

I'd say sending a mouseclick to get fullscreen video definitely isn't that. Causing Skype main window to run away from the mouse cursor definitely would be smile.png


Hi, I would like to follow up on this. I would like to create a user interface for Skype, that allows it to be controlled via keyboard/remote control ("remoteUI"). For all of the voice functions this is not a problem, the API has sufficient support for all the needs. Video control is the problem... the API does not support positioning and size at all and according to the terms you are not allowed to control the Skype UI.

From a programming standpoint here are the current options for video control as I see it:

1) Maximize Button
The remoteUI is running in full screen and as a topmost window. A video call is started. The full screen button is pressed programatically. After the application checked, that the video window is in full screen, the main window of the remoteUI hides or blends to be transparent for the duration of the call. And it will restore itself, if Skype or the remoteUI loses focus (depends on which app is keeping focus in the first place).
This works with a two way video call, but is difficult, if you are only sending. So if you are only sending, you would be unable to switch to the video. It would be great, if you could maximize the video window, when in a video call even if you are only sending.

2) Maximize with separate window
Very similar to the first approach the remoteUI will work in full screen. When video is started the remoteUI ensures, that the video is either in a separate window or that Skype is running in compact mode. Then the separate video window is maximized even when Skype is only sending. I am unsure yet on how to get Skype into compact mode or enforce a separate video window. It would be great, if there would be an API for that...
The separate window along with programatically positioning it underneath the remoteUI before hiding it or making it transparent gives a little bit more control and could result in a consistent behavior.

3) Total control wink.png
Well, this works flawlessly: The remoteUI stays in full screen mode and has two place holder controls for the send and received video - both have their own handle. The application monitors the Skype window and reparents the send and received video window into the place holder controls when found. If the remoteUI looses focus, then the video windows are immediatly reparented to their original parent windows as if it never happened...


Well, while option 3 is from my viewpoint of course the best, being the most reliable and giving the user a seemless experience, but I guess this violates the terms of the API (3.1 (vii) and/or 3.2). Option 1 will most likely work and be compliant with the terms of the API, but has significant drawback for one-way calls. Option 2 might be the compromize, but I think it will be very hard to programmatically ensure that Skype starts the video in a separate window.


Couldn't Skype just add some features to the API like:

VIDEO_CONTROL_MODE - similar to silent mode, but informs Skype, that the application wants control over the video

SET_SEND_VIDEO_WINDOW MAXIMIZE|MINIMIZE|ABSOLUTE x,y,width,height

SET_RECV_VIDEO_WINDOW MAXIMIZE|MINIMIZE|ABSOLUTE x,y,width,height

REHOST_SEND_VIDEO_WINDOW handle - reparents the video into the window identified by the handle

REHOST_RECV_VIDEO_WINDOW handle - reparents the video into the window identified by the handle

If the videos are not active the calls still should work, but show a placeholder image. The rehosting is essentially what I did with option 3, implementing an API call would leave the control over the video windows to Skype and the API call "gives" the controls to the windows identified by the handle - instead of the application "taking" them from Skype.


Well, but that is just a suggestion...

What is your opinion about the outlined approaches to control the video?
Which one _might_ be viable and conform with the API terms - if one of them is it at all?

Thanks,
Alex
John.Doe
I did write it up a little bit and added a comment here:
https://developer.skype.com/jira/browse/SPA-117
I hope someone reads the comments....
TheUberOverlord
Could you please explain in more detail, what you feel was there and is now missing?
John.Doe
QUOTE (TheUberOverlord @ Sun Oct 4 2009, 01:32)
Go to the original post
Could you please explain in more detail, what you feel was there and is now missing?

Hi TheUberOverlord, did you accidentally reply again the the last post on the previous page from June 10th? Or was that directed at me?

I don't think that anything was there and is missing now... video stream/window control is missing functionality and always was. I am just trying to search for legit ways to workaround as outlined in the post above...
TheUberOverlord
ok
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.