mirror of
https://github.com/overte-org/overte.git
synced 2025-06-22 08:22:11 +02:00
Include the neck pivot when we get the eye locations.
This commit is contained in:
parent
d4c4cbc981
commit
40d195595f
1 changed files with 2 additions and 1 deletions
|
@ -178,7 +178,8 @@ void BlendFace::getEyePositions(glm::vec3& firstEyePosition, glm::vec3& secondEy
|
||||||
|
|
||||||
foreach (const FBXMesh& mesh, _geometry.meshes) {
|
foreach (const FBXMesh& mesh, _geometry.meshes) {
|
||||||
if (mesh.isEye) {
|
if (mesh.isEye) {
|
||||||
glm::vec3 position = orientation * (mesh.pivot * scale + MODEL_TRANSLATION) + _owningHead->getPosition();
|
glm::vec3 position = orientation * ((mesh.pivot - _geometry.neckPivot) * scale + MODEL_TRANSLATION) +
|
||||||
|
_owningHead->getPosition();
|
||||||
if (foundFirst) {
|
if (foundFirst) {
|
||||||
secondEyePosition = position;
|
secondEyePosition = position;
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in a new issue