mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-08-04 04:24:47 +02:00
add orb code added to otheravatar.cpp
This commit is contained in:
parent
b8dea4b869
commit
232dc21c7b
1 changed files with 20 additions and 0 deletions
|
@ -7,6 +7,7 @@
|
||||||
//
|
//
|
||||||
|
|
||||||
#include "OtherAvatar.h"
|
#include "OtherAvatar.h"
|
||||||
|
#include "../../interface/src/Application.h"
|
||||||
|
|
||||||
OtherAvatar::OtherAvatar(QThread* thread) : Avatar(thread) {
|
OtherAvatar::OtherAvatar(QThread* thread) : Avatar(thread) {
|
||||||
// give the pointer to our head to inherited _headData variable from AvatarData
|
// give the pointer to our head to inherited _headData variable from AvatarData
|
||||||
|
@ -16,4 +17,23 @@ OtherAvatar::OtherAvatar(QThread* thread) : Avatar(thread) {
|
||||||
connect(_skeletonModel.get(), &Model::setURLFinished, this, &Avatar::setModelURLFinished);
|
connect(_skeletonModel.get(), &Model::setURLFinished, this, &Avatar::setModelURLFinished);
|
||||||
connect(_skeletonModel.get(), &Model::rigReady, this, &Avatar::rigReady);
|
connect(_skeletonModel.get(), &Model::rigReady, this, &Avatar::rigReady);
|
||||||
connect(_skeletonModel.get(), &Model::rigReset, this, &Avatar::rigReset);
|
connect(_skeletonModel.get(), &Model::rigReset, this, &Avatar::rigReset);
|
||||||
|
|
||||||
|
//add the purple orb
|
||||||
|
if (_purpleOrbMeshPlaceholderID == UNKNOWN_OVERLAY_ID || !qApp->getOverlays().isAddedOverlay(_purpleOrbMeshPlaceholderID)) {
|
||||||
|
_purpleOrbMeshPlaceholder = std::make_shared<Sphere3DOverlay>();
|
||||||
|
_purpleOrbMeshPlaceholder->setAlpha(1.0f);
|
||||||
|
_purpleOrbMeshPlaceholder->setColor({ 0xFF, 0x00, 0xFF });
|
||||||
|
_purpleOrbMeshPlaceholder->setIsSolid(false);
|
||||||
|
_purpleOrbMeshPlaceholder->setPulseMin(0.5);
|
||||||
|
_purpleOrbMeshPlaceholder->setPulseMax(1.0);
|
||||||
|
_purpleOrbMeshPlaceholder->setColorPulse(1.0);
|
||||||
|
_purpleOrbMeshPlaceholder->setIgnoreRayIntersection(true);
|
||||||
|
_purpleOrbMeshPlaceholder->setDrawInFront(false);
|
||||||
|
_purpleOrbMeshPlaceholderID = qApp->getOverlays().addOverlay(_purpleOrbMeshPlaceholder);
|
||||||
|
// Position focus
|
||||||
|
_purpleOrbMeshPlaceholder->setWorldOrientation(glm::quat(0.0f, 0.0f, 0.0f, 1.0));
|
||||||
|
_purpleOrbMeshPlaceholder->setWorldPosition(glm::vec3(476.0f, 500.0f, 493.0f));
|
||||||
|
_purpleOrbMeshPlaceholder->setDimensions(glm::vec3(0.5f, 0.5f, 0.5f));
|
||||||
|
_purpleOrbMeshPlaceholder->setVisible(true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue