Proof of concept to start videochat from Plex (in external program)

presently for iChat and Skype
UPDATE June 26 2010

Hi all,

I created a plugin to start a videochat from Plex and answer a videochat from Plex (or EyeTV). This plugin is still beta, but I wanted to get some more input about the problems and also successes of this plugin.

The external programs for this plugin are iChat, Skype and RemoteBuddy (and if you have EyeTV, you're lucky, here it works as well)

This plugin will list your online contacts and when clicked on, will start a videochat with this contact. (some error checking as in e.g.: "network problem" has not been tackled)

The installation is not as easy as downloading an app from the appstore.
1. you'll have to make sure you installed GCC (insert original os x disk:optional installs:xcode tools and install "xcodetools.mpkg")
2. install appscript for version 2.5 (I installed it in terminal with "sudo easy_install-2.5 appscript" and to make sure everything works fine, I also installed it using "sudo easy_install appscript")
3. restart your computer (just to make sure)
4. install videochat.plexapp

Now, launch Plex and go to "Applications". There a new plugin should pop up with a combined iChat and Skype logo.
The plugin will launch iChat and if installed also Skype. After checking if both are online, a list will be created of your online buddies. (be patient when iChat and Skype weren't running). Presently there is no automatic update of the list.
When you select one of your buddies, Plex will tell either iChat or Skype to start a videochat. Plex minimizes and puts the videochat to full screen. When the chat has ended, Plex will automatically open again. The plugin assumes that Plex is running in full screen mode.
For iChat and Plex to act nicely, you need to link FullScreenChat and CloseChatWindow to iChat (for incoming calls: link IncomingChatRequest applescripts to iChat and you need to add some scripts to RemoteBuddy)
For Skype and Plex to act nicely, RemoteBuddy is not needed. (If you want to accept incoming calls, you need to add some scripts to RemoteBuddy.)

Check it out on [youtube](http://www.youtube.com/watch?v=nWdZBo3BIKc)

Just a clarification, in case you don't have RemoteBuddy, you will be able to make calls from within Plex, but you will not be able to answer incoming calls when in Plex or EyeTV. Also you'll need to ask the remote party to end the conversation, so that Plex will maximize again.

Install applescripts: extract all files somewhere, open iChat, preferences, alerts, events,
1. A/V chat started: run an applescript, select FullScreenChat
2. A/V chat ended: run an applescript, select CloseChatWindow
3. Video Invitation: run an applescript, select IncomingVideoChatRequestiChat (only if you use RemoteBuddy)

Install RemoteBuddy scripts:
Under Preferences, Mapping, Behaviours, Plex add new applescript (copy&paste):
1. Button Left: LeftArrowAccept
2. Button Right: RightArrowDecline
3. Button Menu: MenuHangup

Under Preferences, Mapping, Behaviours, EyeTV add new applescript (copy&paste):
1. Button Left: LeftArrowAccept
2. Button Right: RightArrowDecline
3. Button Menu: MenuHangup

Under Preferences, Mapping, Behaviours, Skype add new applescript (copy&paste):
1. Button Menu: SkypeHangup
(if Skype isn't available, create new behavior in behaviour construction kit.)

Under Preferences, Mapping, Behaviours, iChat add new applescript (copy&paste):
1. Button Menu: iChatHangup
(if iChat isn't available, create new behavior in behaviour construction kit.)

If English is not your OS language:
you have to change 2 lines in RemoteBuddy's Plex scripts LeftArrowAccept, RightArrowDecline and RemoteBuddy's EyeTV scripts LeftArrowAccept, RightArrowDecline.
The first line in all of those scripts should be changed to the name of the "Quick Answer Window" (found by running NameOfQuickAnswerWindow when there is an incoming Skype call)
The second line should be changed to the text on the green button (answer) or the red button (decline) during an incoming call. Type this text exactly, so including any capital characters.

If you have a problem with this plugin, please reply to this thread directly (no PM)

have fun
oortmanp


edited march 10. 2010: updated plugin, added short information of what the plugin does, added applescripts and explanation
edited june 26. 2010: updated plugin and added new information of what the plugin does, added applescripts
edited june 30. 2010: made leopard compatible and removed some glitches in scripts. latest version is 0.0.3b

Very cool! I’ll give it a shot and let you know.

Sounds good. My point in the earlier disussion was that none of the Plex developers wanted to work on this feature, but of course that’s the whole idea behind the plugin system. As we have time we may be able to look at extending the plugin API to give plugin more control of Plex.



that would be great. Presently it's difficult to give the user the feeling that it is al seamlessly integrated... :(

The plugin idea is great. What is missing on the Plex side is some kind of unobtrusive notification system the plugin would use. The user could then decide to either pause the movie and navigate the menus to run the plugin or ignore the notification / call. Of course the use of notifications would be optional through Preferences.



Sound notifications may be easier to implement but are not really unobtrusive. I think on screen notifications in growl style would satisfy a lot of people but may put more demands on the developers. But it could be useful for other types of plugins - e.g. Transmission.


Why not just use Growl? The notifications show in front of Plex, and there is plenty of scripting support in Growl.



Seconded.
http://forums.plexapp.com/index.php?/topic/12664-my-growl-plugin/page__p__75828__hl__growl__fromsearch__1&#entry75828

hey, thanks! i did not know there is a growl plugin already…




Any update here for us technology-challenged folks? Maybe not requiring steps 1 and 2? Also, when you say 'install plexapp', what does that mean since its a file? Where to i put the file?


Hi cfriedberg,

this file videochat.plexapp is a plex plugin installer. Normally you should see the plex app maker icon:

http://elan.plexapp.com/wp-content/uploads/2009/10/Plug-in-Installer.jpg



On my second mac I had this problem (just seeing a file) as well. At that time I was running 0.8.3 and I updated to 0.8.5. Then the file was recognised as a plex plugin installer file.

I hope this helps you out. (in case you're running 0.8.5 already, search the forum for another solution)

Regarding the updates about the necessary steps, no improvement yet. Although I am working on an updated code for the plugin, so that you don't necessarily need skype.

oortmanp



oortmanp,

thanks for the reply..so i still need to install GCC and applescript 2.5? Any other way to install GCC if i don't have the Snow Leopard disk?



Hi cfriedberg,

it's perhaps a long shot and most likely it won't work because of some dependencies or path settings, but try to create the following directory:
/Library/Python/2.5/site-packages/

If you're running snowleopard, download the following file, unpack it and put it in the just created directory. Now restart plex, including plex media server and start plex again.

Now start the videochat plugin.

Good luck and let me know if this works

oortmanp

UPDATE 07 MAR 2010: doesn't work, you still need to perform step 1 and 2 from initial post


much appreciated, i will try this weekend and report back...




You can download xcode for free from apple.com
Read this page for instructions: http://www.macworld.com/article/46286/2005/08/installxcode.html

oortmanp

so i followed the instructions but no dice.

1. the directory you reference for me to create actually already existed...the Macintosh HD//Library/Python/2.5/site-packages/. So i put the .egg file in there.
2. closed out of Plex, including Media Server, installed app (so bundle is there), reopened Plex and the app isn't anywhere to be found....



I was afraid of that already.
Try downloading xcode from the link I posted in the previous post.



well, i read that macworld article, and according to it...i should avoid installing xcode as i was unfamiliar with any of the things they recommend you be familiar with...but even despite that i went in search of the xcode download and all i found on the apple store was a link to a developers page that had a 'buy now' button on it...



here is a download link with the download now option. First you have to register as an apple developer. I assume you already have an apple account or mac account or itunes account. If so, then there is no need to buy the xcode

https://connect.apple.com/cgi-bin/WebObjects/MemberSite.woa/wa/getSoftware?bundleID=20505

and if you don't want to install the complete xtools, you can then just install gcc from that same xcodetools.dmg, inside the Packages folder (i.e. don't use the main XcodeTools.mpkg, but Packages/gcc4.2.pkg)


another option is trying google with: xcode download rapidshare

so i installed xcode, the dmg only had the option to install the whole thing…so installed, rebooted mac, still don’t see the app anywhere…