![]() |
VR-Link API Documentation for HLA 1.3
|
This file provides a declaration of the class DtPhysicalEntityEncoder. More...
Go to the source code of this file.
Classes | |
| class | DtPhysicalEntityEncoder |
| class DtPhysicalEntityEncoder: More... | |
Defines | |
| #define | DtDEFINE_SIMPLE_PHYS_ENTITY_ATTR_ENCODER(attrName, netType, inspector) |
| This macro is used to define simple attribute encoder functions (members of a derived DtHlaStateEncoder that encode individual attributes). | |
| #define | DtDEFINE_SIMPLE_PHYS_ENTITY_ATTR_CHECKER(attrName, inspector) |
| This macro is used to define simple attribute checker functions (members of a derived DtHlaStateEncoder that check whether a particular attribute is out of date.) The simple implementation is to just compare the values returned by the two StateReps' inspector functions. | |
| #define | DtDEFINE_LIGHT_ATTR_CHECKER(encClass, attrName, arg1) |
| The following macros are used to define checkers and encoders for lightState attributes. | |
| #define | DtDEFINE_LIGHT_ATTR_ENCODER(encClass, attrName, arg1) |
This file provides a declaration of the class DtPhysicalEntityEncoder.
| #define DtDEFINE_LIGHT_ATTR_CHECKER | ( | encClass, | |
| attrName, | |||
| arg1 | |||
| ) |
bool encClass::need##attrName( \ const DtEntityStateRepository& stateRep, \ const DtEntityStateRepository& asSeenByRemote) \ { \ return (bool) (stateRep.lightState(arg1) != asSeenByRemote.lightState(arg1)); \ }
The following macros are used to define checkers and encoders for lightState attributes.
They are a special case of the simple attr checkers and encoders above.
| #define DtDEFINE_LIGHT_ATTR_ENCODER | ( | encClass, | |
| attrName, | |||
| arg1 | |||
| ) |
void encClass::encode##attrName( \ const DtEntityStateRepository& rep, \ RTI::AttributeHandleValuePairSet* attrs, \ RTI::AttributeHandle attrHandle) \ { \ DtNetBoolean netVal; \ netVal = rep.lightState(arg1); \ attrs->add(attrHandle, (char*) &netVal, sizeof(DtNetBoolean)); \ }
| #define DtDEFINE_SIMPLE_PHYS_ENTITY_ATTR_CHECKER | ( | attrName, | |
| inspector | |||
| ) |
DtDEFINE_SIMPLE_ATTR_CHECKER(DtPhysicalEntityEncoder, \ DtEntityStateRepository, \ attrName, inspector)
This macro is used to define simple attribute checker functions (members of a derived DtHlaStateEncoder that check whether a particular attribute is out of date.) The simple implementation is to just compare the values returned by the two StateReps' inspector functions.
| #define DtDEFINE_SIMPLE_PHYS_ENTITY_ATTR_ENCODER | ( | attrName, | |
| netType, | |||
| inspector | |||
| ) |
DtDEFINE_SIMPLE_ATTR_ENCODER(DtPhysicalEntityEncoder, \ DtEntityStateRepository, \ attrName, netType, inspector)
This macro is used to define simple attribute encoder functions (members of a derived DtHlaStateEncoder that encode individual attributes).
The simple encoding is just to implicitly convert the value returned by the inspector to a netType, and add it to the ahvps.