Revert a cherry-picked workaround accidently committed

This reverts commit 08b21109c1.
Stupid git - I never explicitly added this to the branch!
This commit is contained in:
Simon Walton 2019-01-31 15:19:05 -08:00
parent d0fb09a3bd
commit e4ffc93bc2

View file

@ -632,11 +632,9 @@ QByteArray AvatarData::toByteArray(AvatarDataDetail dataDetail, quint64 lastSent
// include jointData if there is room for the most minimal section. i.e. no translations or rotations. // include jointData if there is room for the most minimal section. i.e. no translations or rotations.
IF_AVATAR_SPACE(PACKET_HAS_JOINT_DATA, AvatarDataPacket::minJointDataSize(numJoints)) { IF_AVATAR_SPACE(PACKET_HAS_JOINT_DATA, AvatarDataPacket::minJointDataSize(numJoints)) {
// Minimum space required for another rotation joint - // Allow for faux joints + translation bit-vector:
// size of joint + following translation bit-vector + translation scale + faux joints: const ptrdiff_t minSizeForJoint = sizeof(AvatarDataPacket::SixByteQuat)
const ptrdiff_t minSizeForJoint = sizeof(AvatarDataPacket::SixByteQuat) + jointBitVectorSize + + jointBitVectorSize + AvatarDataPacket::FAUX_JOINTS_SIZE;
sizeof(float) + AvatarDataPacket::FAUX_JOINTS_SIZE;
auto startSection = destinationBuffer; auto startSection = destinationBuffer;
// compute maxTranslationDimension before we send any joint data. // compute maxTranslationDimension before we send any joint data.
@ -726,7 +724,6 @@ QByteArray AvatarData::toByteArray(AvatarDataDetail dataDetail, quint64 lastSent
const JointData& data = joints[i]; const JointData& data = joints[i];
const JointData& last = lastSentJointData[i]; const JointData& last = lastSentJointData[i];
// Note minSizeForJoint is conservative since there isn't a following bit-vector + scale.
if (packetEnd - destinationBuffer >= minSizeForJoint) { if (packetEnd - destinationBuffer >= minSizeForJoint) {
if (!data.translationIsDefaultPose) { if (!data.translationIsDefaultPose) {
if (sendAll || last.translationIsDefaultPose || (!cullSmallChanges && last.translation != data.translation) if (sendAll || last.translationIsDefaultPose || (!cullSmallChanges && last.translation != data.translation)