]> icculus.org git repositories - taylor/freespace2.git/blob - include/multi_rate.h
embed standalone web in executable
[taylor/freespace2.git] / include / multi_rate.h
1 /*
2  * Copyright (C) Volition, Inc. 1999.  All rights reserved.
3  *
4  * All source code herein is the property of Volition, Inc. You may not sell 
5  * or otherwise commercially exploit the source or things you created based on
6  * the source.
7  */
8
9 /*
10  * $Logfile: /Freespace2/code/Network/multi_rate.h $
11  * $Revision$
12  * $Date$
13  * $Author$
14  * 
15  * $Log$
16  * Revision 1.2  2002/06/09 04:41:14  relnev
17  * added copyright header
18  *
19  * Revision 1.1.1.1  2002/05/03 03:28:12  root
20  * Initial import.
21  *
22  * 
23  * 2     3/09/99 6:24p Dave
24  * More work on object update revamping. Identified several sources of
25  * unnecessary bandwidth.
26  *  
27  *   
28  * $NoKeywords: $
29  */
30
31 #ifndef _FS2_MULTI_DATA_RATE_HEADER_FILE
32 #define _FS2_MULTI_DATA_RATE_HEADER_FILE
33
34 // -----------------------------------------------------------------------------------------------------------------------
35 // MULTI RATE DEFINES/VARS
36 //
37
38 #define MAX_RATE_TYPE_LEN                       50                              // max length of a type string
39 #define MAX_RATE_PLAYERS                        12                              // how many player we'll keep track of
40 #define MAX_RATE_TYPES                          32                              // how many types we'll keep track of per player
41
42 // -----------------------------------------------------------------------------------------------------------------------
43 // MULTI RATE FUNCTIONS
44 //
45
46 // notify of a player join
47 void multi_rate_reset(int np_index);
48
49 // add data of the specified type to datarate processing, returns 0 on fail (if we ran out of types, etc, etc)
50 int multi_rate_add(int np_index, const char *type, int size);
51
52 // process. call _before_ doing network operations each frame
53 void multi_rate_process();
54
55 // display
56 void multi_rate_display(int np_index, int x, int y);
57
58 #endif
59