Check RTMP Protocol [DRAFT] for more info.
The header comes in 4 sizes:
The 2 most significant bits (of this first byte) determine the header size
load( "components.asc" );
application.onConnectAccept = function( client) {
trace( application.name + ":onConnectAccept ");
}
application.onConnect = function( newClient) {
trace( application.name + ":onConnect " + newClient);
application.acceptConnection(newClient);
}
The following informations have been found out by looking at the traffic that is sent between the flash client and the FCS in the “sample_noteroom” application.
To request or update a SO, the client sends the following RTMP request:
To get an initial SO, the version and the request size are set to “0”. Therefore the request body is absent. To update a SO, the version is set to the version of the local SO, the request type is “3” and the body contains key / AMF object pairs. Be aware that you may not change the attributes of your local SO yourself as the FCS will generate messages for each of your changes.
Depending on the requests the FCS receives from the different clients, it sends update events to all the clients that requested a SO. The format is described below.
(the following entries may appear multiple times; check using size of body part)
This is sent by the FCS after you sent a request to update your local copy of the SO to make your changes effective.
(the following entries may appear multiple times; check using size of body part)
if subtype != 9 (delete data):
read amf object as value of attribute
else:
delete attribute