mirror of
https://github.com/HifiExperiments/overte.git
synced 2025-08-09 21:51:36 +02:00
Merge pull request #11934 from ctrlaltdavid/21630
Fix cloned 3D overlays' dimensions
This commit is contained in:
commit
4f8a2ea4be
5 changed files with 11 additions and 8 deletions
|
@ -35,7 +35,8 @@ ModelOverlay::ModelOverlay(const ModelOverlay* modelOverlay) :
|
||||||
_modelTextures(QVariantMap()),
|
_modelTextures(QVariantMap()),
|
||||||
_url(modelOverlay->_url),
|
_url(modelOverlay->_url),
|
||||||
_updateModel(false),
|
_updateModel(false),
|
||||||
_loadPriority(modelOverlay->getLoadPriority())
|
_scaleToFit(modelOverlay->_scaleToFit),
|
||||||
|
_loadPriority(modelOverlay->_loadPriority)
|
||||||
{
|
{
|
||||||
_model->init();
|
_model->init();
|
||||||
_model->setLoadingPriority(_loadPriority);
|
_model->setLoadingPriority(_loadPriority);
|
||||||
|
|
|
@ -75,8 +75,8 @@ private:
|
||||||
QVariantMap _modelTextures;
|
QVariantMap _modelTextures;
|
||||||
|
|
||||||
QUrl _url;
|
QUrl _url;
|
||||||
bool _updateModel = { false };
|
bool _updateModel { false };
|
||||||
bool _scaleToFit = { false };
|
bool _scaleToFit { false };
|
||||||
float _loadPriority { 0.0f };
|
float _loadPriority { 0.0f };
|
||||||
|
|
||||||
AnimationPointer _animation;
|
AnimationPointer _animation;
|
||||||
|
@ -87,7 +87,7 @@ private:
|
||||||
bool _animationRunning { false };
|
bool _animationRunning { false };
|
||||||
bool _animationLoop { false };
|
bool _animationLoop { false };
|
||||||
float _animationFirstFrame { 0.0f };
|
float _animationFirstFrame { 0.0f };
|
||||||
float _animationLastFrame = { 0.0f };
|
float _animationLastFrame { 0.0f };
|
||||||
bool _animationHold { false };
|
bool _animationHold { false };
|
||||||
bool _animationAllowTranslation { false };
|
bool _animationAllowTranslation { false };
|
||||||
uint64_t _lastAnimated { 0 };
|
uint64_t _lastAnimated { 0 };
|
||||||
|
|
|
@ -18,8 +18,9 @@
|
||||||
|
|
||||||
QString const Shape3DOverlay::TYPE = "shape";
|
QString const Shape3DOverlay::TYPE = "shape";
|
||||||
|
|
||||||
Shape3DOverlay::Shape3DOverlay(const Shape3DOverlay* Shape3DOverlay) :
|
Shape3DOverlay::Shape3DOverlay(const Shape3DOverlay* shape3DOverlay) :
|
||||||
Volume3DOverlay(Shape3DOverlay)
|
Volume3DOverlay(shape3DOverlay),
|
||||||
|
_shape(shape3DOverlay->_shape)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -23,7 +23,7 @@ public:
|
||||||
virtual QString getType() const override { return TYPE; }
|
virtual QString getType() const override { return TYPE; }
|
||||||
|
|
||||||
Shape3DOverlay() {}
|
Shape3DOverlay() {}
|
||||||
Shape3DOverlay(const Shape3DOverlay* Shape3DOverlay);
|
Shape3DOverlay(const Shape3DOverlay* shape3DOverlay);
|
||||||
|
|
||||||
virtual void render(RenderArgs* args) override;
|
virtual void render(RenderArgs* args) override;
|
||||||
virtual const render::ShapeKey getShapeKey() override;
|
virtual const render::ShapeKey getShapeKey() override;
|
||||||
|
|
|
@ -14,7 +14,8 @@
|
||||||
#include <RegisteredMetaTypes.h>
|
#include <RegisteredMetaTypes.h>
|
||||||
|
|
||||||
Volume3DOverlay::Volume3DOverlay(const Volume3DOverlay* volume3DOverlay) :
|
Volume3DOverlay::Volume3DOverlay(const Volume3DOverlay* volume3DOverlay) :
|
||||||
Base3DOverlay(volume3DOverlay)
|
Base3DOverlay(volume3DOverlay),
|
||||||
|
_localBoundingBox(volume3DOverlay->_localBoundingBox)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue