Changeset 6784 in orxonox.OLD for branches/network/src/lib/coord
- Timestamp:
- Jan 26, 2006, 8:03:40 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/network/src/lib/coord/p_node.cc
r6695 r6784 1077 1077 SYNCHELP_READ_BEGIN(); 1078 1078 1079 SYNCHELP_READ_FKT( BaseObject::writeState );1079 SYNCHELP_READ_FKT( BaseObject::writeState, NWT_PN_BO_WRITESTATE ); 1080 1080 1081 1081 // char * parentName = NULL; … … 1094 1094 1095 1095 int parentMode; 1096 SYNCHELP_READ_INT( parentMode );1096 SYNCHELP_READ_INT( parentMode, NWT_PN_PARENTMODE ); 1097 1097 this->setParentMode((PARENT_MODE)parentMode); 1098 1098 1099 1099 float f1, f2, f3, f4; 1100 1100 1101 SYNCHELP_READ_FLOAT( f1 );1102 SYNCHELP_READ_FLOAT( f2 );1103 SYNCHELP_READ_FLOAT( f3 );1101 SYNCHELP_READ_FLOAT( f1, NWT_PN_COORX ); 1102 SYNCHELP_READ_FLOAT( f2, NWT_PN_COORY ); 1103 SYNCHELP_READ_FLOAT( f3, NWT_PN_COORZ ); 1104 1104 this->setRelCoor( f1, f2, f3 ); 1105 1105 1106 1106 1107 SYNCHELP_READ_FLOAT( f1 );1108 SYNCHELP_READ_FLOAT( f2 );1109 SYNCHELP_READ_FLOAT( f3 );1110 SYNCHELP_READ_FLOAT( f4 );1107 SYNCHELP_READ_FLOAT( f1, NWT_PN_ROTV ); 1108 SYNCHELP_READ_FLOAT( f2, NWT_PN_ROTX ); 1109 SYNCHELP_READ_FLOAT( f3, NWT_PN_ROTY ); 1110 SYNCHELP_READ_FLOAT( f4, NWT_PN_ROTZ ); 1111 1111 this->setRelDir( Quaternion( Vector(f2, f3, f4), f1 ) ); 1112 1112 … … 1140 1140 SYNCHELP_WRITE_BEGIN(); 1141 1141 1142 SYNCHELP_WRITE_FKT( BaseObject::readState );1142 SYNCHELP_WRITE_FKT( BaseObject::readState, NWT_PN_BO_WRITESTATE ); 1143 1143 1144 1144 // if ( this->parent ) … … 1151 1151 // } 1152 1152 1153 SYNCHELP_WRITE_INT( this->parentMode );1154 1155 SYNCHELP_WRITE_FLOAT( this->relCoordinate.x );1156 SYNCHELP_WRITE_FLOAT( this->relCoordinate.y );1157 SYNCHELP_WRITE_FLOAT( this->relCoordinate.z );1158 1159 SYNCHELP_WRITE_FLOAT( this->relDirection.w );1160 SYNCHELP_WRITE_FLOAT( this->relDirection.v.x );1161 SYNCHELP_WRITE_FLOAT( this->relDirection.v.y );1162 SYNCHELP_WRITE_FLOAT( this->relDirection.v.z );1153 SYNCHELP_WRITE_INT( this->parentMode, NWT_PN_PARENTMODE ); 1154 1155 SYNCHELP_WRITE_FLOAT( this->relCoordinate.x, NWT_PN_COORX ); 1156 SYNCHELP_WRITE_FLOAT( this->relCoordinate.y, NWT_PN_COORY ); 1157 SYNCHELP_WRITE_FLOAT( this->relCoordinate.z, NWT_PN_COORZ ); 1158 1159 SYNCHELP_WRITE_FLOAT( this->relDirection.w, NWT_PN_ROTV ); 1160 SYNCHELP_WRITE_FLOAT( this->relDirection.v.x, NWT_PN_ROTX ); 1161 SYNCHELP_WRITE_FLOAT( this->relDirection.v.y, NWT_PN_ROTY ); 1162 SYNCHELP_WRITE_FLOAT( this->relDirection.v.z, NWT_PN_ROTZ ); 1163 1163 1164 1164 // int n = children.size(); … … 1209 1209 1210 1210 byte flags = 0; 1211 SYNCHELP_READ_BYTE( flags );1211 SYNCHELP_READ_BYTE( flags, NWT_PN_FLAGS ); 1212 1212 //PRINTF(0)("%s::FLAGS = %d\n", this->getName(), flags); 1213 1213 … … 1216 1216 if ( flags & __FLAG_COOR ) 1217 1217 { 1218 SYNCHELP_READ_FLOAT( f1 );1219 SYNCHELP_READ_FLOAT( f2 );1220 SYNCHELP_READ_FLOAT( f3 );1218 SYNCHELP_READ_FLOAT( f1, NWT_PN_SCOORX ); 1219 SYNCHELP_READ_FLOAT( f2, NWT_PN_SCOORY ); 1220 SYNCHELP_READ_FLOAT( f3, NWT_PN_SCOORZ ); 1221 1221 PRINTF(0)("RCVD COOR: %f %f %f\n", f1, f2, f3); 1222 1222 this->setRelCoor( f1, f2, f3 ); … … 1225 1225 if ( flags & __FLAG_ROT ) 1226 1226 { 1227 SYNCHELP_READ_FLOAT( f1 );1228 SYNCHELP_READ_FLOAT( f2 );1229 SYNCHELP_READ_FLOAT( f3 );1230 SYNCHELP_READ_FLOAT( f4 );1227 SYNCHELP_READ_FLOAT( f1, NWT_PN_SROTV ); 1228 SYNCHELP_READ_FLOAT( f2, NWT_PN_SROTX ); 1229 SYNCHELP_READ_FLOAT( f3, NWT_PN_SROTY ); 1230 SYNCHELP_READ_FLOAT( f4, NWT_PN_SROTZ ); 1231 1231 PRINTF(0)("RCVD QUAT: %f %f %f %f\n", f1, f2, f3, f4); 1232 1232 //this->setRelDir( Quaternion( Vector(f2, f3, f4), f1 ) ); … … 1270 1270 1271 1271 1272 SYNCHELP_WRITE_BYTE( flags );1272 SYNCHELP_WRITE_BYTE( flags, NWT_PN_FLAGS ); 1273 1273 //PRINTF(0)("FLAGS = %d\n", flags); 1274 1274 … … 1278 1278 PRINTF(0)("SEND COOR: %f %f %f\n", this->relCoordinate.x, this->relCoordinate.y, this->relCoordinate.z); 1279 1279 1280 SYNCHELP_WRITE_FLOAT( this->relCoordinate.x );1281 SYNCHELP_WRITE_FLOAT( this->relCoordinate.y );1282 SYNCHELP_WRITE_FLOAT( this->relCoordinate.z );1280 SYNCHELP_WRITE_FLOAT( this->relCoordinate.x, NWT_PN_SCOORX ); 1281 SYNCHELP_WRITE_FLOAT( this->relCoordinate.y, NWT_PN_SCOORY ); 1282 SYNCHELP_WRITE_FLOAT( this->relCoordinate.z, NWT_PN_SCOORZ ); 1283 1283 1284 1284 coorx = relCoordinate.x; … … 1292 1292 PRINTF(0)("SEND QUAT: %f %f %f %f\n", this->absDirection.w, this->absDirection.v.x, this->absDirection.v.y, this->absDirection.v.z); 1293 1293 1294 SYNCHELP_WRITE_FLOAT( this->absDirection.w );1295 SYNCHELP_WRITE_FLOAT( this->absDirection.v.x );1296 SYNCHELP_WRITE_FLOAT( this->absDirection.v.y );1297 SYNCHELP_WRITE_FLOAT( this->absDirection.v.z );1294 SYNCHELP_WRITE_FLOAT( this->absDirection.w, NWT_PN_SROTV ); 1295 SYNCHELP_WRITE_FLOAT( this->absDirection.v.x, NWT_PN_SROTX ); 1296 SYNCHELP_WRITE_FLOAT( this->absDirection.v.y, NWT_PN_SROTY ); 1297 SYNCHELP_WRITE_FLOAT( this->absDirection.v.z, NWT_PN_SROTZ ); 1298 1298 1299 1299 rotw = absDirection.w;
Note: See TracChangeset
for help on using the changeset viewer.