mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-08 14:42:09 +02:00
Merge pull request #15163 from danteruiz/fix-laser-scaling
Case 21499: Lasers are offset in front of hands after scaling avatar down then relaunching
This commit is contained in:
commit
33e73953eb
2 changed files with 5 additions and 2 deletions
|
@ -1122,6 +1122,7 @@ public:
|
|||
float getUserEyeHeight() const;
|
||||
|
||||
virtual SpatialParentTree* getParentTree() const override;
|
||||
virtual glm::vec3 scaleForChildren() const override { return glm::vec3(getSensorToWorldScale()); }
|
||||
|
||||
const QUuid& getSelfID() const { return AVATAR_SELF_ID; }
|
||||
|
||||
|
|
|
@ -20,8 +20,10 @@ public:
|
|||
_jointIndex(jointIndex) {
|
||||
auto nestablePointer = _spatiallyNestable.lock();
|
||||
if (nestablePointer) {
|
||||
glm::vec3 nestableDimensions = getActualScale(nestablePointer);
|
||||
_baseScale = glm::max(glm::vec3(0.001f), nestableDimensions);
|
||||
if (nestablePointer->getNestableType() != NestableType::Avatar) {
|
||||
glm::vec3 nestableDimensions = getActualScale(nestablePointer);
|
||||
_baseScale = glm::max(glm::vec3(0.001f), nestableDimensions);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue