mirror of
https://github.com/lubosz/overte.git
synced 2025-08-08 03:48:38 +02:00
quiet compiler
This commit is contained in:
parent
e65ef93663
commit
49ee251238
20 changed files with 86 additions and 84 deletions
|
@ -5070,7 +5070,7 @@ void Application::emulateMouse(Hand* hand, float click, float shift, int index)
|
||||||
glm::vec3 direction = glm::inverse(_myAvatar->getOrientation()) * palm->getFingerDirection();
|
glm::vec3 direction = glm::inverse(_myAvatar->getOrientation()) * palm->getFingerDirection();
|
||||||
|
|
||||||
// Get the angles, scaled between (-0.5,0.5)
|
// Get the angles, scaled between (-0.5,0.5)
|
||||||
float xAngle = (atan2(direction.z, direction.x) + M_PI_2);
|
float xAngle = (atan2f(direction.z, direction.x) + (float)M_PI_2);
|
||||||
float yAngle = 0.5f - ((atan2f(direction.z, direction.y) + (float)M_PI_2));
|
float yAngle = 0.5f - ((atan2f(direction.z, direction.y) + (float)M_PI_2));
|
||||||
auto canvasSize = qApp->getCanvasSize();
|
auto canvasSize = qApp->getCanvasSize();
|
||||||
// Get the pixel range over which the xAngle and yAngle are scaled
|
// Get the pixel range over which the xAngle and yAngle are scaled
|
||||||
|
|
|
@ -53,7 +53,7 @@ public:
|
||||||
protected:
|
protected:
|
||||||
void rollFileIfNecessary(QFile& file) {
|
void rollFileIfNecessary(QFile& file) {
|
||||||
uint64_t now = usecTimestampNow();
|
uint64_t now = usecTimestampNow();
|
||||||
if ((file.size() > MAX_LOG_SIZE) || (now - _lastRollTime) > MAX_LOG_AGE_USECS) {
|
if ((file.size() > (qint64)MAX_LOG_SIZE) || (now - _lastRollTime) > MAX_LOG_AGE_USECS) {
|
||||||
QString newFileName = getLogRollerFilename();
|
QString newFileName = getLogRollerFilename();
|
||||||
if (file.copy(newFileName)) {
|
if (file.copy(newFileName)) {
|
||||||
_lastRollTime = now;
|
_lastRollTime = now;
|
||||||
|
|
|
@ -6,7 +6,6 @@
|
||||||
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
|
||||||
//
|
//
|
||||||
#include "OpenGLDisplayPlugin.h"
|
#include "OpenGLDisplayPlugin.h"
|
||||||
|
|
||||||
#include <QOpenGLContext>
|
#include <QOpenGLContext>
|
||||||
#include <QCoreApplication>
|
#include <QCoreApplication>
|
||||||
|
|
||||||
|
|
|
@ -21,8 +21,20 @@
|
||||||
#include <oglplus/opt/list_init.hpp>
|
#include <oglplus/opt/list_init.hpp>
|
||||||
#include <oglplus/shapes/vector.hpp>
|
#include <oglplus/shapes/vector.hpp>
|
||||||
#include <oglplus/opt/list_init.hpp>
|
#include <oglplus/opt/list_init.hpp>
|
||||||
|
|
||||||
|
|
||||||
|
#if defined(__GNUC__) && !defined(__clang__)
|
||||||
|
#pragma GCC diagnostic push
|
||||||
|
#pragma GCC diagnostic ignored "-Wdouble-promotion"
|
||||||
|
#endif
|
||||||
|
|
||||||
#include <oglplus/shapes/obj_mesh.hpp>
|
#include <oglplus/shapes/obj_mesh.hpp>
|
||||||
|
|
||||||
|
#if defined(__GNUC__) && !defined(__clang__)
|
||||||
|
#pragma GCC diagnostic pop
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#include <PerfStat.h>
|
#include <PerfStat.h>
|
||||||
#include <plugins/PluginContainer.h>
|
#include <plugins/PluginContainer.h>
|
||||||
#include <ViewFrustum.h>
|
#include <ViewFrustum.h>
|
||||||
|
|
|
@ -184,7 +184,10 @@ void OculusLegacyDisplayPlugin::activate() {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
ovrBool result = ovrHmd_ConfigureRendering(_hmd, &config.Config, distortionCaps, _eyeFovs, _eyeRenderDescs);
|
#ifndef QT_NO_DEBUG
|
||||||
|
ovrBool result =
|
||||||
|
#endif
|
||||||
|
ovrHmd_ConfigureRendering(_hmd, &config.Config, distortionCaps, _eyeFovs, _eyeRenderDescs);
|
||||||
Q_ASSERT(result);
|
Q_ASSERT(result);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
#include "EntitiesLogging.h"
|
#include "EntitiesLogging.h"
|
||||||
#include "EntityTreeElement.h"
|
#include "EntityTreeElement.h"
|
||||||
|
|
||||||
EntityTreeElement::EntityTreeElement(unsigned char* octalCode) : OctreeElement(), _entityItems(NULL) {
|
EntityTreeElement::EntityTreeElement(unsigned char* octalCode) : OctreeElement() {
|
||||||
init(octalCode);
|
init(octalCode);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -73,34 +73,9 @@ EntityItemPointer ParticleEffectEntityItem::factory(const EntityItemID& entityID
|
||||||
// our non-pure virtual subclass for now...
|
// our non-pure virtual subclass for now...
|
||||||
ParticleEffectEntityItem::ParticleEffectEntityItem(const EntityItemID& entityItemID, const EntityItemProperties& properties) :
|
ParticleEffectEntityItem::ParticleEffectEntityItem(const EntityItemID& entityItemID, const EntityItemProperties& properties) :
|
||||||
EntityItem(entityItemID),
|
EntityItem(entityItemID),
|
||||||
_maxParticles(DEFAULT_MAX_PARTICLES),
|
|
||||||
_lifespan(DEFAULT_LIFESPAN),
|
|
||||||
_emitRate(DEFAULT_EMIT_RATE),
|
|
||||||
_emitVelocity(DEFAULT_EMIT_VELOCITY),
|
|
||||||
_velocitySpread(DEFAULT_VELOCITY_SPREAD),
|
|
||||||
_emitAcceleration(DEFAULT_EMIT_ACCELERATION),
|
|
||||||
_accelerationSpread(DEFAULT_ACCELERATION_SPREAD),
|
|
||||||
_particleRadius(DEFAULT_PARTICLE_RADIUS),
|
|
||||||
_radiusSpread(DEFAULT_RADIUS_SPREAD),
|
|
||||||
_radiusStart(DEFAULT_RADIUS_START),
|
|
||||||
_radiusFinish(DEFAULT_RADIUS_FINISH),
|
|
||||||
_lastAnimated(usecTimestampNow()),
|
_lastAnimated(usecTimestampNow()),
|
||||||
_animationLoop(),
|
_animationLoop(),
|
||||||
_animationSettings(),
|
_animationSettings(),
|
||||||
_textures(DEFAULT_TEXTURES),
|
|
||||||
_texturesChangedFlag(false),
|
|
||||||
_shapeType(SHAPE_TYPE_NONE),
|
|
||||||
_colorSpread(DEFAULT_COLOR_SPREAD),
|
|
||||||
_colorStart(DEFAULT_COLOR),
|
|
||||||
_colorFinish(DEFAULT_COLOR),
|
|
||||||
_isColorStartInitialized(false),
|
|
||||||
_isColorFinishInitialized(false),
|
|
||||||
_alpha(DEFAULT_ALPHA),
|
|
||||||
_alphaSpread(DEFAULT_ALPHA_SPREAD),
|
|
||||||
_alphaStart(DEFAULT_ALPHA_START),
|
|
||||||
_alphaFinish(DEFAULT_ALPHA_FINISH),
|
|
||||||
_isAlphaStartInitialized(false),
|
|
||||||
_isAlphaFinishInitialized(false),
|
|
||||||
_particleLifetimes(DEFAULT_MAX_PARTICLES, 0.0f),
|
_particleLifetimes(DEFAULT_MAX_PARTICLES, 0.0f),
|
||||||
_particlePositions(DEFAULT_MAX_PARTICLES, glm::vec3(0.0f, 0.0f, 0.0f)),
|
_particlePositions(DEFAULT_MAX_PARTICLES, glm::vec3(0.0f, 0.0f, 0.0f)),
|
||||||
_particleVelocities(DEFAULT_MAX_PARTICLES, glm::vec3(0.0f, 0.0f, 0.0f)),
|
_particleVelocities(DEFAULT_MAX_PARTICLES, glm::vec3(0.0f, 0.0f, 0.0f)),
|
||||||
|
@ -117,9 +92,6 @@ ParticleEffectEntityItem::ParticleEffectEntityItem(const EntityItemID& entityIte
|
||||||
_alphaStarts(DEFAULT_MAX_PARTICLES, DEFAULT_ALPHA),
|
_alphaStarts(DEFAULT_MAX_PARTICLES, DEFAULT_ALPHA),
|
||||||
_alphaMiddles(DEFAULT_MAX_PARTICLES, DEFAULT_ALPHA),
|
_alphaMiddles(DEFAULT_MAX_PARTICLES, DEFAULT_ALPHA),
|
||||||
_alphaFinishes(DEFAULT_MAX_PARTICLES, DEFAULT_ALPHA),
|
_alphaFinishes(DEFAULT_MAX_PARTICLES, DEFAULT_ALPHA),
|
||||||
_timeUntilNextEmit(0.0f),
|
|
||||||
_particleHeadIndex(0),
|
|
||||||
_particleTailIndex(0),
|
|
||||||
_particleMaxBound(glm::vec3(1.0f, 1.0f, 1.0f)),
|
_particleMaxBound(glm::vec3(1.0f, 1.0f, 1.0f)),
|
||||||
_particleMinBound(glm::vec3(-1.0f, -1.0f, -1.0f)) {
|
_particleMinBound(glm::vec3(-1.0f, -1.0f, -1.0f)) {
|
||||||
|
|
||||||
|
|
|
@ -56,11 +56,11 @@ public:
|
||||||
_color[BLUE_INDEX] = value.blue;
|
_color[BLUE_INDEX] = value.blue;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool _isColorStartInitialized;
|
bool _isColorStartInitialized = false;
|
||||||
void setColorStart(const xColor& colorStart) { _colorStart = colorStart; _isColorStartInitialized = true; }
|
void setColorStart(const xColor& colorStart) { _colorStart = colorStart; _isColorStartInitialized = true; }
|
||||||
xColor getColorStart() const { return _isColorStartInitialized ? _colorStart : getXColor(); }
|
xColor getColorStart() const { return _isColorStartInitialized ? _colorStart : getXColor(); }
|
||||||
|
|
||||||
bool _isColorFinishInitialized;
|
bool _isColorFinishInitialized = false;
|
||||||
void setColorFinish(const xColor& colorFinish) { _colorFinish = colorFinish; _isColorFinishInitialized = true; }
|
void setColorFinish(const xColor& colorFinish) { _colorFinish = colorFinish; _isColorFinishInitialized = true; }
|
||||||
xColor getColorFinish() const { return _isColorFinishInitialized ? _colorFinish : getXColor(); }
|
xColor getColorFinish() const { return _isColorFinishInitialized ? _colorFinish : getXColor(); }
|
||||||
|
|
||||||
|
@ -73,12 +73,12 @@ public:
|
||||||
float getAlpha() const { return _alpha; }
|
float getAlpha() const { return _alpha; }
|
||||||
|
|
||||||
static const float DEFAULT_ALPHA_START;
|
static const float DEFAULT_ALPHA_START;
|
||||||
bool _isAlphaStartInitialized;
|
bool _isAlphaStartInitialized = false;
|
||||||
void setAlphaStart(float alphaStart) { _alphaStart = alphaStart; _isAlphaStartInitialized = true; }
|
void setAlphaStart(float alphaStart) { _alphaStart = alphaStart; _isAlphaStartInitialized = true; }
|
||||||
float getAlphaStart() const { return _isAlphaStartInitialized ? _alphaStart : _alpha; }
|
float getAlphaStart() const { return _isAlphaStartInitialized ? _alphaStart : _alpha; }
|
||||||
|
|
||||||
static const float DEFAULT_ALPHA_FINISH;
|
static const float DEFAULT_ALPHA_FINISH;
|
||||||
bool _isAlphaFinishInitialized;
|
bool _isAlphaFinishInitialized = false;
|
||||||
void setAlphaFinish(float alphaFinish) { _alphaFinish = alphaFinish; _isAlphaFinishInitialized = true; }
|
void setAlphaFinish(float alphaFinish) { _alphaFinish = alphaFinish; _isAlphaFinishInitialized = true; }
|
||||||
float getAlphaFinish() const { return _isAlphaFinishInitialized ? _alphaFinish : _alpha; }
|
float getAlphaFinish() const { return _isAlphaFinishInitialized ? _alphaFinish : _alpha; }
|
||||||
|
|
||||||
|
@ -192,29 +192,29 @@ protected:
|
||||||
|
|
||||||
// the properties of this entity
|
// the properties of this entity
|
||||||
rgbColor _color;
|
rgbColor _color;
|
||||||
xColor _colorStart;
|
xColor _colorStart = DEFAULT_COLOR;
|
||||||
xColor _colorFinish;
|
xColor _colorFinish = DEFAULT_COLOR;
|
||||||
xColor _colorSpread;
|
xColor _colorSpread = DEFAULT_COLOR_SPREAD;
|
||||||
float _alpha;
|
float _alpha = DEFAULT_ALPHA;
|
||||||
float _alphaStart;
|
float _alphaStart = DEFAULT_ALPHA_START;
|
||||||
float _alphaFinish;
|
float _alphaFinish = DEFAULT_ALPHA_FINISH;
|
||||||
float _alphaSpread;
|
float _alphaSpread = DEFAULT_ALPHA_SPREAD;
|
||||||
quint32 _maxParticles;
|
quint32 _maxParticles = DEFAULT_MAX_PARTICLES;
|
||||||
float _lifespan;
|
float _lifespan = DEFAULT_LIFESPAN;
|
||||||
float _emitRate;
|
float _emitRate = DEFAULT_EMIT_RATE;
|
||||||
glm::vec3 _emitVelocity;
|
glm::vec3 _emitVelocity = DEFAULT_EMIT_VELOCITY;
|
||||||
glm::vec3 _velocitySpread;
|
glm::vec3 _velocitySpread = DEFAULT_VELOCITY_SPREAD;
|
||||||
glm::vec3 _emitAcceleration;
|
glm::vec3 _emitAcceleration = DEFAULT_EMIT_ACCELERATION;
|
||||||
glm::vec3 _accelerationSpread;
|
glm::vec3 _accelerationSpread = DEFAULT_ACCELERATION_SPREAD;
|
||||||
float _particleRadius;
|
float _particleRadius = DEFAULT_PARTICLE_RADIUS;
|
||||||
float _radiusStart;
|
float _radiusStart = DEFAULT_RADIUS_START;
|
||||||
float _radiusFinish;
|
float _radiusFinish = DEFAULT_RADIUS_FINISH;
|
||||||
float _radiusSpread;
|
float _radiusSpread = DEFAULT_RADIUS_SPREAD;
|
||||||
quint64 _lastAnimated;
|
quint64 _lastAnimated;
|
||||||
AnimationLoop _animationLoop;
|
AnimationLoop _animationLoop;
|
||||||
QString _animationSettings;
|
QString _animationSettings;
|
||||||
QString _textures;
|
QString _textures = DEFAULT_TEXTURES;
|
||||||
bool _texturesChangedFlag;
|
bool _texturesChangedFlag = false;
|
||||||
ShapeType _shapeType = SHAPE_TYPE_NONE;
|
ShapeType _shapeType = SHAPE_TYPE_NONE;
|
||||||
|
|
||||||
// all the internals of running the particle sim
|
// all the internals of running the particle sim
|
||||||
|
@ -235,12 +235,12 @@ protected:
|
||||||
QVector<float> _alphaMiddles;
|
QVector<float> _alphaMiddles;
|
||||||
QVector<float> _alphaFinishes;
|
QVector<float> _alphaFinishes;
|
||||||
|
|
||||||
float _timeUntilNextEmit;
|
float _timeUntilNextEmit = 0.0f;
|
||||||
|
|
||||||
// particle arrays are a ring buffer, use these indices
|
// particle arrays are a ring buffer, use these indices
|
||||||
// to keep track of the living particles.
|
// to keep track of the living particles.
|
||||||
quint32 _particleHeadIndex;
|
quint32 _particleHeadIndex = 0;
|
||||||
quint32 _particleTailIndex;
|
quint32 _particleTailIndex = 0;
|
||||||
|
|
||||||
// bounding volume
|
// bounding volume
|
||||||
glm::vec3 _particleMaxBound;
|
glm::vec3 _particleMaxBound;
|
||||||
|
|
|
@ -1129,6 +1129,8 @@ ExtractedMesh extractMesh(const FBXNode& object, unsigned int& meshIndex) {
|
||||||
if (isMaterialPerPolygon) {
|
if (isMaterialPerPolygon) {
|
||||||
isMultiMaterial = true;
|
isMultiMaterial = true;
|
||||||
}
|
}
|
||||||
|
// TODO: make excellent use of isMultiMaterial
|
||||||
|
Q_UNUSED(isMultiMaterial);
|
||||||
|
|
||||||
// convert the polygons to quads and triangles
|
// convert the polygons to quads and triangles
|
||||||
int polygonIndex = 0;
|
int polygonIndex = 0;
|
||||||
|
|
|
@ -33,6 +33,7 @@ HifiSockAddr::HifiSockAddr(const QHostAddress& address, quint16 port) :
|
||||||
}
|
}
|
||||||
|
|
||||||
HifiSockAddr::HifiSockAddr(const HifiSockAddr& otherSockAddr) :
|
HifiSockAddr::HifiSockAddr(const HifiSockAddr& otherSockAddr) :
|
||||||
|
QObject(),
|
||||||
_address(otherSockAddr._address),
|
_address(otherSockAddr._address),
|
||||||
_port(otherSockAddr._port)
|
_port(otherSockAddr._port)
|
||||||
{
|
{
|
||||||
|
|
|
@ -202,8 +202,8 @@ static void addBone(const AnimPose& rootPose, const AnimPose& pose, float radius
|
||||||
glm::vec3 zRing[NUM_CIRCLE_SLICES + 1];
|
glm::vec3 zRing[NUM_CIRCLE_SLICES + 1];
|
||||||
const float dTheta = (2.0f * (float)M_PI) / NUM_CIRCLE_SLICES;
|
const float dTheta = (2.0f * (float)M_PI) / NUM_CIRCLE_SLICES;
|
||||||
for (int i = 0; i < NUM_CIRCLE_SLICES + 1; i++) {
|
for (int i = 0; i < NUM_CIRCLE_SLICES + 1; i++) {
|
||||||
float rCosTheta = radius * cos(dTheta * i);
|
float rCosTheta = radius * cosf(dTheta * i);
|
||||||
float rSinTheta = radius * sin(dTheta * i);
|
float rSinTheta = radius * sinf(dTheta * i);
|
||||||
xRing[i] = finalPose * glm::vec3(0.0f, rCosTheta, rSinTheta);
|
xRing[i] = finalPose * glm::vec3(0.0f, rCosTheta, rSinTheta);
|
||||||
yRing[i] = finalPose * glm::vec3(rCosTheta, 0.0f, rSinTheta);
|
yRing[i] = finalPose * glm::vec3(rCosTheta, 0.0f, rSinTheta);
|
||||||
zRing[i] = finalPose * glm::vec3(rCosTheta, rSinTheta, 0.0f);
|
zRing[i] = finalPose * glm::vec3(rCosTheta, rSinTheta, 0.0f);
|
||||||
|
|
|
@ -110,10 +110,10 @@ void Antialiasing::run(const render::SceneContextPointer& sceneContext, const re
|
||||||
QSize framebufferSize = framebufferCache->getFrameBufferSize();
|
QSize framebufferSize = framebufferCache->getFrameBufferSize();
|
||||||
float fbWidth = framebufferSize.width();
|
float fbWidth = framebufferSize.width();
|
||||||
float fbHeight = framebufferSize.height();
|
float fbHeight = framebufferSize.height();
|
||||||
float sMin = args->_viewport.x / fbWidth;
|
// float sMin = args->_viewport.x / fbWidth;
|
||||||
float sWidth = args->_viewport.z / fbWidth;
|
// float sWidth = args->_viewport.z / fbWidth;
|
||||||
float tMin = args->_viewport.y / fbHeight;
|
// float tMin = args->_viewport.y / fbHeight;
|
||||||
float tHeight = args->_viewport.w / fbHeight;
|
// float tHeight = args->_viewport.w / fbHeight;
|
||||||
|
|
||||||
glm::mat4 projMat;
|
glm::mat4 projMat;
|
||||||
Transform viewMat;
|
Transform viewMat;
|
||||||
|
@ -136,14 +136,14 @@ void Antialiasing::run(const render::SceneContextPointer& sceneContext, const re
|
||||||
|
|
||||||
args->_viewFrustum->computeOffAxisFrustum(left, right, bottom, top, nearVal, farVal, nearClipPlane, farClipPlane);
|
args->_viewFrustum->computeOffAxisFrustum(left, right, bottom, top, nearVal, farVal, nearClipPlane, farClipPlane);
|
||||||
|
|
||||||
float depthScale = (farVal - nearVal) / farVal;
|
// float depthScale = (farVal - nearVal) / farVal;
|
||||||
float nearScale = -1.0f / nearVal;
|
// float nearScale = -1.0f / nearVal;
|
||||||
float depthTexCoordScaleS = (right - left) * nearScale / sWidth;
|
// float depthTexCoordScaleS = (right - left) * nearScale / sWidth;
|
||||||
float depthTexCoordScaleT = (top - bottom) * nearScale / tHeight;
|
// float depthTexCoordScaleT = (top - bottom) * nearScale / tHeight;
|
||||||
float depthTexCoordOffsetS = left * nearScale - sMin * depthTexCoordScaleS;
|
// float depthTexCoordOffsetS = left * nearScale - sMin * depthTexCoordScaleS;
|
||||||
float depthTexCoordOffsetT = bottom * nearScale - tMin * depthTexCoordScaleT;
|
// float depthTexCoordOffsetT = bottom * nearScale - tMin * depthTexCoordScaleT;
|
||||||
|
|
||||||
batch._glUniform2f(_texcoordOffsetLoc, 1.0 / fbWidth, 1.0 / fbHeight);
|
batch._glUniform2f(_texcoordOffsetLoc, 1.0f / fbWidth, 1.0f / fbHeight);
|
||||||
|
|
||||||
glm::vec4 color(0.0f, 0.0f, 0.0f, 1.0f);
|
glm::vec4 color(0.0f, 0.0f, 0.0f, 1.0f);
|
||||||
glm::vec2 bottomLeft(-1.0f, -1.0f);
|
glm::vec2 bottomLeft(-1.0f, -1.0f);
|
||||||
|
|
|
@ -43,7 +43,10 @@ bool GlWindow::makeCurrent() {
|
||||||
qDebug() << "GL Renderer: " << QString((const char*) glGetString(GL_RENDERER));
|
qDebug() << "GL Renderer: " << QString((const char*) glGetString(GL_RENDERER));
|
||||||
});
|
});
|
||||||
|
|
||||||
QOpenGLContext * currentContext = QOpenGLContext::currentContext();
|
#ifndef QT_NO_DEBUG
|
||||||
|
QOpenGLContext * currentContext =
|
||||||
|
#endif
|
||||||
|
QOpenGLContext::currentContext();
|
||||||
Q_ASSERT(_context == currentContext);
|
Q_ASSERT(_context == currentContext);
|
||||||
return makeCurrentResult;
|
return makeCurrentResult;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1745,6 +1745,8 @@ void Model::segregateMeshGroups() {
|
||||||
if (wireframe) {
|
if (wireframe) {
|
||||||
translucentMesh = hasTangents = hasSpecular = hasLightmap = isSkinned = false;
|
translucentMesh = hasTangents = hasSpecular = hasLightmap = isSkinned = false;
|
||||||
}
|
}
|
||||||
|
// TODO: make excellent use of translucentMesh
|
||||||
|
Q_UNUSED(translucentMesh);
|
||||||
|
|
||||||
// Create the render payloads
|
// Create the render payloads
|
||||||
int totalParts = mesh.parts.size();
|
int totalParts = mesh.parts.size();
|
||||||
|
|
|
@ -94,8 +94,8 @@ ScriptEngine::ScriptEngine(const QString& scriptContents, const QString& fileNam
|
||||||
_isListeningToAudioStream(false),
|
_isListeningToAudioStream(false),
|
||||||
_avatarSound(NULL),
|
_avatarSound(NULL),
|
||||||
_numAvatarSoundSentBytes(0),
|
_numAvatarSoundSentBytes(0),
|
||||||
_controllerScriptingInterface(controllerScriptingInterface),
|
|
||||||
_wantSignals(wantSignals),
|
_wantSignals(wantSignals),
|
||||||
|
_controllerScriptingInterface(controllerScriptingInterface),
|
||||||
_avatarData(NULL),
|
_avatarData(NULL),
|
||||||
_scriptName(),
|
_scriptName(),
|
||||||
_fileNameString(fileNameString),
|
_fileNameString(fileNameString),
|
||||||
|
|
|
@ -156,7 +156,7 @@ protected:
|
||||||
bool _isAgent = false;
|
bool _isAgent = false;
|
||||||
QSet<QUrl> _includedURLs;
|
QSet<QUrl> _includedURLs;
|
||||||
bool _wantSignals = true;
|
bool _wantSignals = true;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void stopAllTimers();
|
void stopAllTimers();
|
||||||
void sendAvatarIdentityPacket();
|
void sendAvatarIdentityPacket();
|
||||||
|
|
|
@ -108,7 +108,10 @@ void VrMenu::addMenu(QMenu* menu) {
|
||||||
Q_ASSERT(false);
|
Q_ASSERT(false);
|
||||||
}
|
}
|
||||||
QVariant returnedValue;
|
QVariant returnedValue;
|
||||||
bool invokeResult = QMetaObject::invokeMethod(this, "addMenu", Qt::DirectConnection,
|
#ifndef QT_NO_DEBUG
|
||||||
|
bool invokeResult =
|
||||||
|
#endif
|
||||||
|
QMetaObject::invokeMethod(this, "addMenu", Qt::DirectConnection,
|
||||||
Q_RETURN_ARG(QVariant, returnedValue),
|
Q_RETURN_ARG(QVariant, returnedValue),
|
||||||
Q_ARG(QVariant, QVariant::fromValue(qmlParent)),
|
Q_ARG(QVariant, QVariant::fromValue(qmlParent)),
|
||||||
Q_ARG(QVariant, QVariant::fromValue(menu->title())));
|
Q_ARG(QVariant, QVariant::fromValue(menu->title())));
|
||||||
|
@ -146,8 +149,11 @@ void VrMenu::addAction(QMenu* menu, QAction* action) {
|
||||||
MenuUserData* userData = MenuUserData::forObject(menu);
|
MenuUserData* userData = MenuUserData::forObject(menu);
|
||||||
QObject* menuQml = findMenuObject(userData->uuid.toString());
|
QObject* menuQml = findMenuObject(userData->uuid.toString());
|
||||||
Q_ASSERT(menuQml);
|
Q_ASSERT(menuQml);
|
||||||
QVariant returnedValue;
|
QVariant returnedValue;
|
||||||
bool invokeResult = QMetaObject::invokeMethod(this, "addItem", Qt::DirectConnection,
|
#ifndef QT_NO_DEBUG
|
||||||
|
bool invokeResult =
|
||||||
|
#endif
|
||||||
|
QMetaObject::invokeMethod(this, "addItem", Qt::DirectConnection,
|
||||||
Q_RETURN_ARG(QVariant, returnedValue),
|
Q_RETURN_ARG(QVariant, returnedValue),
|
||||||
Q_ARG(QVariant, QVariant::fromValue(menuQml)),
|
Q_ARG(QVariant, QVariant::fromValue(menuQml)),
|
||||||
Q_ARG(QVariant, QVariant::fromValue(action->text())));
|
Q_ARG(QVariant, QVariant::fromValue(action->text())));
|
||||||
|
@ -167,7 +173,10 @@ void VrMenu::insertAction(QAction* before, QAction* action) {
|
||||||
}
|
}
|
||||||
QObject* menu = beforeQml->parent();
|
QObject* menu = beforeQml->parent();
|
||||||
QVariant returnedValue;
|
QVariant returnedValue;
|
||||||
bool invokeResult = QMetaObject::invokeMethod(this, "insertItem", Qt::DirectConnection,
|
#ifndef QT_NO_DEBUG
|
||||||
|
bool invokeResult =
|
||||||
|
#endif
|
||||||
|
QMetaObject::invokeMethod(this, "insertItem", Qt::DirectConnection,
|
||||||
Q_RETURN_ARG(QVariant, returnedValue),
|
Q_RETURN_ARG(QVariant, returnedValue),
|
||||||
Q_ARG(QVariant, QVariant::fromValue(menu)),
|
Q_ARG(QVariant, QVariant::fromValue(menu)),
|
||||||
Q_ARG(QVariant, QVariant::fromValue(beforeQml)),
|
Q_ARG(QVariant, QVariant::fromValue(beforeQml)),
|
||||||
|
|
|
@ -93,8 +93,9 @@ template <typename T>
|
||||||
void testByteCountCoded() {
|
void testByteCountCoded() {
|
||||||
testByteCountCodedStable<T>(0);
|
testByteCountCodedStable<T>(0);
|
||||||
testByteCountCodedStable<T>(1);
|
testByteCountCodedStable<T>(1);
|
||||||
testByteCountCodedStable<T>(1 << 8*sizeof(T));
|
// These two can't possibly be right. TODO: figure out what was being tested, here
|
||||||
testByteCountCodedStable<T>(std::numeric_limits<T>::max() >> 8*sizeof(T));
|
// testByteCountCodedStable<T>(1 << 8*sizeof(T));
|
||||||
|
// testByteCountCodedStable<T>(std::numeric_limits<T>::max() >> 8*sizeof(T));
|
||||||
testByteCountCodedStable<T>(std::numeric_limits<T>::max() >> 8);
|
testByteCountCodedStable<T>(std::numeric_limits<T>::max() >> 8);
|
||||||
testByteCountCodedStable<T>(std::numeric_limits<T>::max() >> 1);
|
testByteCountCodedStable<T>(std::numeric_limits<T>::max() >> 1);
|
||||||
testByteCountCodedStable<T>(std::numeric_limits<T>::max());
|
testByteCountCodedStable<T>(std::numeric_limits<T>::max());
|
||||||
|
|
|
@ -25,7 +25,6 @@
|
||||||
#include <gpu/Stream.h>
|
#include <gpu/Stream.h>
|
||||||
#include <gpu/StandardShaderLib.h>
|
#include <gpu/StandardShaderLib.h>
|
||||||
#include <gpu/GLBackend.h>
|
#include <gpu/GLBackend.h>
|
||||||
|
|
||||||
#include <QOpenGLContext>
|
#include <QOpenGLContext>
|
||||||
#include <QResizeEvent>
|
#include <QResizeEvent>
|
||||||
#include <QTime>
|
#include <QTime>
|
||||||
|
|
|
@ -13,7 +13,6 @@
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include <gpu/GLBackend.h>
|
#include <gpu/GLBackend.h>
|
||||||
|
|
||||||
#include <QOpenGLContext>
|
#include <QOpenGLContext>
|
||||||
#include <QOpenGLDebugLogger>
|
#include <QOpenGLDebugLogger>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue