float CSliderJoint::getSpeed() const { if (mInternal == nullptr) return 0.0f; return _getInternal()->getSpeed(); }
Radian CD6Joint::getSwingZ() const { if (mInternal == nullptr) return Radian(0.0f); return _getInternal()->getSwingZ(); }
void CSliderJoint::setLimit(const LimitLinearRange& limit) { if (mDesc.limit == limit) return; mDesc.limit = limit; if (mInternal != nullptr) _getInternal()->setLimit(limit); }
void CD6Joint::setLimitSwing(const LimitConeRange& limit) { if (mDesc.limitSwing == limit) return; mDesc.limitSwing = limit; if (mInternal != nullptr) _getInternal()->setLimitSwing(limit); }
void CD6Joint::setLimitTwist(const LimitAngularRange& limit) { if (mDesc.limitTwist == limit) return; mDesc.limitTwist = limit; if (mInternal != nullptr) _getInternal()->setLimitTwist(limit); }
void CD6Joint::setLimitLinear(const LimitLinear& limit) { if (mDesc.limitLinear == limit) return; mDesc.limitLinear = limit; if (mInternal != nullptr) _getInternal()->setLimitLinear(limit); }
void CD6Joint::setMotion(D6Joint::Axis axis, D6Joint::Motion motion) { if (mDesc.motion[(int)axis] == motion) return; mDesc.motion[(int)axis] = motion; if (mInternal != nullptr) _getInternal()->setMotion(axis, motion); }
void CD6Joint::setDrive(D6Joint::DriveType type, const D6Joint::Drive& drive) { if (mDesc.drive[(int)type] == drive) return; mDesc.drive[(int)type] = drive; if (mInternal != nullptr) _getInternal()->setDrive(type, drive); }
void CD6Joint::setDriveVelocity(const Vector3& linear, const Vector3& angular) { if (mDesc.driveLinearVelocity == linear && mDesc.driveAngularVelocity == angular) return; mDesc.driveLinearVelocity = linear; mDesc.driveAngularVelocity = angular; if (mInternal != nullptr) _getInternal()->setDriveVelocity(linear, angular); }
void CD6Joint::setDriveTransform(const Vector3& position, const Quaternion& rotation) { if (mDesc.drivePosition == position && mDesc.driveRotation == rotation) return; mDesc.drivePosition = position; mDesc.driveRotation = rotation; if (mInternal != nullptr) _getInternal()->setDriveTransform(position, rotation); }
void CSliderJoint::setFlag(SliderJointFlag flag, bool enabled) { bool isEnabled = ((UINT32)mDesc.flag & (UINT32)flag) != 0; if (isEnabled == enabled) return; if (enabled) mDesc.flag = (SliderJointFlag)((UINT32)mDesc.flag | (UINT32)flag); else mDesc.flag = (SliderJointFlag)((UINT32)mDesc.flag & ~(UINT32)flag); if (mInternal != nullptr) _getInternal()->setFlag(flag, enabled); }
const NdbDictionary::Table* TableInfoCache::set(/*const string& databaseName, */const string& storeName, Ndb* ndb) { // string fullTableName = _getFullTableName(databaseName, storeName); // cout<<"Table name "<<fullTableName<<endl; const NdbDictionary::Table* newTableInfo = _getInternal(storeName, ndb); if(newTableInfo) { // cout<<"Setting up cache"<<endl; boost::unique_lock< boost::shared_mutex > lock(_access); _entries[storeName] = newTableInfo; } return newTableInfo; }
void CBoxCollider::setExtents(const Vector3& extents) { Vector3 clampedExtents = Vector3::max(extents, Vector3(0.01f, 0.01f, 0.01f)); if (mExtents == clampedExtents) return; mExtents = clampedExtents; if (mInternal != nullptr) { _getInternal()->setExtents(clampedExtents); if (mParent != nullptr) mParent->_updateMassDistribution(); } }