mirror of
https://github.com/overte-org/overte.git
synced 2025-04-23 10:13:22 +02:00
fixes
This commit is contained in:
parent
c8fb467579
commit
439434b300
2 changed files with 4 additions and 5 deletions
|
@ -363,7 +363,7 @@ void AvatarMixer::broadcastAvatarData() {
|
|||
|
||||
numAvatarDataBytes += avatarPacketList->write(otherNode->getUUID().toRfc4122());
|
||||
numAvatarDataBytes +=
|
||||
avatarPacketList->write(otherAvatar.toByteArray(false, distribution(generator) < AVATAR_SEND_FULL_UPDATE_RATIO), sendMinimumForOutOfView);
|
||||
avatarPacketList->write(otherAvatar.toByteArray(false, distribution(generator) < AVATAR_SEND_FULL_UPDATE_RATIO, sendMinimumForOutOfView));
|
||||
|
||||
avatarPacketList->endSegment();
|
||||
});
|
||||
|
|
|
@ -217,8 +217,7 @@ QByteArray AvatarData::toByteArray(bool cullSmallChanges, bool sendAll, bool sen
|
|||
memcpy(destinationBuffer, &_globalPosition, sizeof(_globalPosition));
|
||||
destinationBuffer += sizeof(_globalPosition);
|
||||
qDebug() << __FUNCTION__ << "minimum... included global position!!";
|
||||
}
|
||||
else {
|
||||
} else {
|
||||
//qDebug() << __FUNCTION__ << "not minimum... sending actual content!!";
|
||||
|
||||
auto header = reinterpret_cast<AvatarDataPacket::Header*>(destinationBuffer);
|
||||
|
@ -541,10 +540,10 @@ int AvatarData::parseDataFromBuffer(const QByteArray& buffer) {
|
|||
|
||||
memcpy(&_globalPosition, sourceBuffer, sizeof(_globalPosition));
|
||||
sourceBuffer += sizeof(_globalPosition);
|
||||
int numBytesRead = (sourceBuffer - startPosition) + sizeof(packetStateFlags);
|
||||
int numBytesRead = (sourceBuffer - startPosition);
|
||||
_averageBytesReceived.updateAverage(numBytesRead);
|
||||
|
||||
qDebug() << __FUNCTION__ << "minimum... included global position!! numBytesRead:" << numBytesRead;
|
||||
//qDebug() << __FUNCTION__ << "minimum... included global position!! numBytesRead:" << numBytesRead;
|
||||
|
||||
return numBytesRead;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue