Archive for the ‘Documentation’ Category

Changing emote icons in AVChat 3

Wednesday, April 21st, 2010

AVChat 3 supports emote icons and you can add your own emote icons if you want to!

By default AVChat 3 uses the emote icons in the emoticons\standardPack folder. The list of available emote icons in this pack is contained in emoticons\standardPack\emoticons.xml . You can edit this file to add and remove emote icons.

To add an emote icon to the standard pack:

  1. Put the emote icon file (swf, jpg, png, gif) in the emoticons\standardPack folder.
  2. Edit emoticons\standardPack\emoticons.xml and add a new e element before the final </emoticons> tag:
    <e text=”:newemoteicon:” url=”emoticons/standardPack/newemoteicon.swf”></e>
  3. Upload the new emote icon file and the changed emoteicons.xml file to your web site.

In the <e text=”:newemoteicon:” url=”emoticons/standardPack/newemoteicon.swf”></e> XML code:

  • :newemoteicon: is the text that will be replaced in the text chat with the new emote icon
  • emoticons/standardPack/newemoteicon.swf is the path to the emote icon

Some things you should know:

  • AVChat 3 only supports 14x14px .swf, .jpg, .png or .gif files as emote icons.
  • Emote icons larger or smaller than 14×14 will not display properly!
  • Animated GIF’s are not supported (Flash Player limitation).
  • You can also make your own pack with its own emoteicons.xml list file. The path to the emoteicons.xml file used by AVChat 3 can be changed from avc_settings.xxx via the emoticonsurl variable.

On ghost users

Friday, April 9th, 2010

Ghost users are a known issue with all media servers.

What is a ghost user?

A ghost user is a user who’s disconnection from the media server has not been detected by the media server, thus the media server thinks he is still connected.

In a chat you will know there are ghost users when you see 2-3 persons in the users list having the same user name or persons staying for unusual lenghts of time in the chat without activity.possible-ghhost-users

What causes ghost users?

They happen when a user suddenly disconnects from the Internet while connected to a media server (for example by suddenly disconnecting your Ethernet cable or loosing WiFi signal) but in other occasions too like when the user is over a slow connection (mobile connections) or behind some weird combination of network hardware + server software. IE and the way it handles Flash content might also produce ghost users.

How is AVChat 3 dealing with ghost users?

  1. every 3 seconds the client  (swf file) sends a ping to the media server (this value can not be changed)
  2. every 10 seconds the media server (Red5/Wowza/FMIS) check if all clients have sent a ping within the last 10 seconds (already 3 pings should have been sent by every client) and disconnects everyone who has not.

This means that no ghost user will ever stay in the chat for more than 20 seconds.

Starting with build 741 (April) you can contol the above mechanism by changing the value of the checkForGhostConnectionsEveryXSeconds and ghostUsersAreIdleForYSeconds variables in settings.asc (FMIS) or avchat3.properties (Red5 and Wowza). If your users seem to get disconnected for no apparent reason increase the value of ghostUsersAreIdleForYSeconds to for example 20 seconds. Both variables are set by default to 10 seconds.

The IE exception

In some cases when closing a tab in IE, IE will not remove the client side swf (index.swf) from the memory, thus the ping calls will be made  even tough the user has closed the tab containing the chat.  Such ghost users can only be removed by :

  • the user closing all IE tabs and windows
  • an admin kicking him out of the chat

We are working on a  fix for this exception.

HDFVR and FLVAR tip: How to save the recorded files in a different folder on FMIS!

Monday, March 15th, 2010

Both the HD Flash Video Recorder and the FLV Audio Recorder grab the audio/video data from the webcam/mic, encode it and send it to the media server where it is saved in a .flv file.

The folder where the .flv files are crated can be changed on FMIS. To do this you need to :

  1. Copy conf\_defaultRoot_\_defaultVHost_\Application.xml to applications/hdfvr or to applications/audiorecorder.
  2. Edit the newly copied Application.xml with a text editor.
  3. Change the value of the <StorageDir></StorageDir> tag (line 191) to the folder where you want the .flv files to be created.
  4. Save Application.xml and restart FMIS or reload the application using the FMIS Management Console.

Ensuring high connection success rate

Tuesday, February 23rd, 2010

Why a connection attempt to a working media server might fail:

Red5, FMIS and Wowza by default only accept  rtmp connections over port 1935. This will work fine for most home Internet connections however when your user is behind a corporate firewall/network he might hit 2 major restrictions:

  1. NO traffic/connections to non standard ports like 1935 (default port for rtmp). Traffic is only allowed to standard ports like 80 (http) and 443 (https) . The solution for this is to configure the media server to accept  rtmp connections over ports 443 and 80 .
  2. NO non-http traffic allowed (or a proxy server is used). The solution for this is to configure the media server to accept  rtmpt connections. Rtmpt is rtmp wrapped as http and its slower. It also adds some overhead/consumes more bandwidth because each rtmp packet needs to be wrapped as http. According to a 2004 Adobe article, only 4% of Internet users are behind such a network.

The automatic connection sequence in Flash Player:

By default, when a Flash Player app (AVChat 3 for example) tries to connect to a media server (Red5, FMIS or Wowza), it automatically tries to establish a connection by using the following sequence of ports and protocols:

  1. rtmp://myserver:1935/avchat30/_definst_
  2. rtmp://myserver:443/avchat30/_definst_
  3. rtmp://myserver:80/avchat30/_definst_
  4. rtmpt://myserver:80/avchat30/_definst_

This connection sequence can enable connections to succeed that otherwise would not. This automatic retry sequence occurs only if the initial connection specifies the RTMP protocol and does not specify a port – for example rtmp://myserver/avchat30/_definst_ . During this connection sequence, users may wait several seconds for multiple connection attempts to time out.

However for the above connection sequence to actually produce more sucessfull connection attempts, the media server must also be properly configured to listen for rtmp connections over ports 1935, 443 and 80 and for rtmpt connections over port 80.

Configuring your media server for best connection success rate:

[Before making the below changes make sure there is no other program listening on port 80 or 443 on your media server. These ports are surely already used by Apache. Use the netstat -ant command on linux to see which ports are already used.  FMIS, Red5 and Wowza use port 1935 by default for a reason]

If you’re using FMIS:

  • solution for restriction 1: configure it to listen for rtmp connections over ports 1935, 443 and 80. You need to edit conf/fms.ini, set ADAPTOR.HOSTPORT = :1935,443,80 and restart FMIS. Make sure you don’t have other apps (like the Apache web server) started and listening on 80 or 443.
  • solution for restriction 2:  same as above, FMIS can listen for both rtmp and rtmpt connections over the same ports at the same time

Most FMIS hosting services (like influxis.com) are already configured like this  out of the box.

If you’re using  Wowza:

  • solution for restriction 1: make it listen for rtmp connections over ports 1935, 443 and 80. You need to edit conf/VHost.xml , set <Port>1935,443,80</Port> and restart Wowza. Make sure you don’t have other apps (like the Apache web server) started and listening on 80 or 443.
  • solution for restriction 2: same as above, Wowza can listen for both rtmp and rtmpt connections over the same ports at the same time

If you’re using Red5:

  • solution for restriction 1: bind rtmp connections to port 443 instead of 1935 (Red5 0.9 can not listen for rtmp connections over several simultaneous ports like Wowza and FMIS can). You need to edit conf/red5.properties, set rtmp.port=443 and restart Red5. Make sure you don’t have other apps (like the Apache web server) started and listening on 443 . You can also use port 80 but we will use that for listening for rtmpt connections as explained below.
  • solution for restriction 2: bind rtmpt connections to port 80. You need to edit conf/red5.properties, set rtmpt.port=80 and restart Red5. Make sure you don’t have other apps (like the Apache web server) started and listening on 80.

How can you check your connection

Here you will find 2 port testers which will attempt to establish rtmp and rtmpt connections (using all ports) to a properly configured media server. Red5 ships with a similar tool and you can download another one from here.

More info

There is a great article (from 2005 I think) on the Adobe website that goes more in depth about these issues. I recommend you read it if you want to understand a little bit more about how the Internet works and why these steps are necessary and why such configurations are not the default: http://www.adobe.com/devnet/flashcom/articles/firewalls_proxy.html .

How to bypass the login screen in AVChat 3

Tuesday, January 26th, 2010

The login screen in AVChat 3 shows up to ask the user for its username and gender. However if you provide these info’s via avc_settings.php or avc_settings.asp the login is not needed anymore so it will be skipped!

So this is what you need to do in order to auto login users:

  • set the value of $config['username'] to something (like the username of the person logged in the website)
  • change the value of $config['gender'] to male, female or couple
  • set $config['changegender']=0; so the user will not be given the chance to change its gender
  • set $config['changeuser']=0; so the user will not be given the chance to change its username

You can also use $config['disableGenderSelection'] to disable the gender selection altogether and $config['coupleGenderEnabled'] to disable the couple gender.

Calculating AVChat 3 bandwidth usage

Monday, November 9th, 2009

About bandwidth usage

The bandwidth usage/month depends on many factors and can never be guessed without several days of actual running the video chat software on your website:

  • number of people online watching cams and how much time they spend watching
  • number of people online broadcasting cams and how much time they spend broadcasting
  • how many cams a user can see at once
  • audio/video quality (128,256,512kbits/s etc…)

For example a user broadcasting its webcam for 30 minutes at 256kbits/s will use  57Mbytes of bandwdith (256kbits/s * 60 seconds * 30 minutes=57Mbytes).

Another user viewing the first one for 30 minutes will use the same amount: 57Mbytes. Total: 114Mbytes for a 30 minute 1 to 1 video chat session.

Reducing bandwidth usage

AVChat 3 offers several ways to reduce the monthly bandwidth used on the media server:

How to remove the who-is-typing box inside AVChat 3

Wednesday, November 4th, 2009
Who is typing box in AVChat 3

Who is typing box in AVChat 3

In avc_settings.php you will find the following config option:

$config['showWhoIsTyping']=1;

Set it to 0 and the who-is-typing box will not be shown anymore in the chat.

If you are using avc_settings.asp look for the showWhoIsTyping variable and set it to 0!

Why would AVChat 3 fail to connect to the media server?

Wednesday, November 4th, 2009

Error 1: If, when trying to connect using AVChat 3, you are getting this error message: Connection failed, media server might be down or firewall might be blocking the connection! like this:

Error message shown when AVChat 3 can not connect to the media server

You need to check:

  • your rtmp connection string inserted in avc_settings.xxx
  • the media server might not be running (you can check if Red5 is running by going to http://yourred5server.com:5080/)
  • the media server might have not started properly (thus is not running, you can check the logs in Red5/log for any ERROR messages during startup)
  • there is a firewall on the media server blocking TCP traffic over port 1935 (and 5080)
  • the user trying to connect is behind a firewall that blocks the connection (either a personal one installed on his computer or a corporate one installed on his network, to test his connection capabilities he should run these connection tests: http://www.flashcomguru.com/apps/port_test/index.cfm )

Error 2: If, when trying to connect using AVChat 3, you are getting this error message:  Connection Rejected:No scope ”avchat30/_definst_” on this server OR The connection with the video chat server could not be made like this:

AVChat 3 error message when there is an issue with the AVChat 3 Red5 media server files

It means you are using Red5 and your Red5  is running but:

  • make sure you use Red5 0.8 final (AVChat 3 is not compatible with any other versions)
  • make sure you installed the AVChat 3 Red5 server files properly (Red5/webapps/avchat30)
  • make sure you restart Red5 after you installed the Red5 server side files (Red5/webapps/avchat30)

Error 3: When trying to connect using AVChat 3, you are getting this error message: Application (avchat30) is not defined , like this:

AVChat 3 error essage shown when the FMIS app is not set up

There are 2 causes/solutions for this error:

Error 4: When trying to connect using AVChat 3, you are getting this error message: Connection success, waiting for server… .

There is 1 possibe cause/solution for this issue:


Changing the license key in AVChat 3

Wednesday, September 2nd, 2009

Changing the license key:

Why would I change the license key?

  • Insert a new trial key
  • Switch from trial to non-trial key
  • Switch the domain on which the software will be used
  • Upgrade from Lite to 40 users (for example)

What do I have to do?

  1. Log in the video chat using the admin interface (admin.swf)
  2. Click the Settings button at the top
  3. In the window that shows up, delete the old key from the text field and insert the new key
  4. Press the [Change Key] button
  5. If successful, you should now see the new  limits/expiration date/domain above the license key text field!

Resetting the license key:

If something goes awfully wrong and you find yourself locked out of the video chat (you’ve inserted a key for a domain to which you do not have yet access or has not yet been registered ) you can reset the license key.

What do I have to do?

  1. Delete this file
    • on Red5:   red5/webapps/avchat30/persistence/SharedObject/_definst_/licensekey.red5
    • on FMIS:   fms/applications/avchat30/sharedobjects/_definst_/licensekey.fso
    • on Wowza: wowza/applications/avchat30/sharedobjects/_definst_/licensekey.rso
  2. Restart Red5, FMIS or Wowza
  3. Enter the video chat and you will be asked for the key again!

What AVChat 3 build do I have?

Tuesday, August 18th, 2009

To see what AVChat 3 build you have installed you need to right click on the video chat software. The first item in the menu that shows up is the build number:

The AVChat 3 build number showing up on right click!

The AVChat 3 build number showing up on right click!

Why is the build number important?

The build number allows you to check if you have the latest version of our software.  If your build number is 284 and on the blog we announce a  new release with the build number 340, then it means you should consider upgrading your installation!

Each increment in the build number might represent any of the following things:

  • code cleaning
  • bug fix
  • new feature
  • new file
  • new entry in the translation file
  • new setting in the config files
  • etc…

but you should check the release notes for the exact new features and bug fixes in each build.

Build numbers on our demo of AVChat 3

Our online demo of AVChat 3 is frequently updated, so even tough the latest build available for download might be 284, the demo might be 310 for example. We update the demo more frequently to test new features and UI changes before we release these changes to the customers.