![]() |
RflySimSDK v3.05
RflySimSDK说明文档
|
#include <vrpn_RedundantTransmission.h>
类 | |
struct | RRMemory |
struct | RRRecord |
Public 成员函数 | |
vrpn_RedundantReceiver (vrpn_Connection *) | |
virtual int | register_handler (vrpn_int32 type, vrpn_MESSAGEHANDLER handler, void *userdata, vrpn_int32 sender=vrpn_ANY_SENDER) |
virtual int | unregister_handler (vrpn_int32 type, vrpn_MESSAGEHANDLER handler, void *userdata, vrpn_int32 sender=vrpn_ANY_SENDER) |
void | record (vrpn_bool) |
void | writeMemory (const char *filename) |
void | clearMemory (void) |
Throws away / resets statistics. | |
静态 Protected 成员函数 | |
static int VRPN_CALLBACK | handle_possiblyRedundantMessage (void *, vrpn_HANDLERPARAM) |
Protected 属性 | |
vrpn_Connection * | d_connection |
RRRecord | d_records [vrpn_CONNECTION_MAX_TYPES] |
RRRecord | d_generic |
RRMemory * | d_memory |
RRMemory * | d_lastMemory |
vrpn_bool | d_record |
Helper class that eliminates duplicates; only the first instance of a message is delivered. Registers a callback on connection for any type it's told to monitor; when it gets a message back, checks its list of recently-seen-timestamps for that type; if it isn't on the list, it's dispatched and replaces the oldest item on the list. List length is limited, so if too many messages of the same type (more than VRPN_RR_LENGTH) are interleaved - if transmissionInterval * numRetransmissions > VRPN_RR_LENGTH * the normal rate of message generation - it will not detect the redundant messages.
void clearMemory | ( | void | ) |
Throws away / resets statistics.
void record | ( | vrpn_bool | ) |
Turns "memory" (tracking statistics of redundant reception) on and off.
void writeMemory | ( | const char * | filename | ) |
Writes statistics to the named file: timestamp of every message received and number of copies of that message. Detects partial losses, but not when all copies are lost, since vrpn_RR doesn't expect messages.