CR feedback

This commit is contained in:
Brad Hefta-Gaub 2015-10-07 11:23:24 -07:00
parent 016bf4011d
commit 6eeb64b032
5 changed files with 6 additions and 8 deletions

View file

@ -50,7 +50,6 @@
var properties = {}; var properties = {};
properties[group] = {}; properties[group] = {};
properties[group][propertyName] = this.checked; properties[group][propertyName] = this.checked;
//debugPrint(" about to emitWebEvent() properties:" + JSON.stringify(properties));
EventBridge.emitWebEvent( EventBridge.emitWebEvent(
JSON.stringify({ JSON.stringify({
type: "update", type: "update",

View file

@ -92,7 +92,7 @@ public:
float getLastFrame() const { return _animationLoop.getLastFrame(); } float getLastFrame() const { return _animationLoop.getLastFrame(); }
void setRunning(bool running, bool restoreJoints = true); void setRunning(bool running, bool restoreJoints = true);
bool isRunning() const { return _animationLoop.isRunning(); } bool isRunning() const { return _animationLoop.getRunning(); }
void setFrameIndex(float frameIndex) { _animationLoop.setFrameIndex(frameIndex); } void setFrameIndex(float frameIndex) { _animationLoop.setFrameIndex(frameIndex); }
float getFrameIndex() const { return _animationLoop.getFrameIndex(); } float getFrameIndex() const { return _animationLoop.getFrameIndex(); }

View file

@ -26,7 +26,7 @@ AnimationLoop::AnimationLoop() :
_running(false), _running(false),
_frameIndex(0.0f), _frameIndex(0.0f),
_maxFrameIndexHint(MAXIMUM_POSSIBLE_FRAME), _maxFrameIndexHint(MAXIMUM_POSSIBLE_FRAME),
_resetOnRunning(false), _resetOnRunning(true),
_lastSimulated(usecTimestampNow()) _lastSimulated(usecTimestampNow())
{ {
} }
@ -40,7 +40,7 @@ AnimationLoop::AnimationLoop(const AnimationDetails& animationDetails) :
_lastFrame(animationDetails.lastFrame), _lastFrame(animationDetails.lastFrame),
_running(animationDetails.running), _running(animationDetails.running),
_frameIndex(animationDetails.frameIndex), _frameIndex(animationDetails.frameIndex),
_resetOnRunning(false), _resetOnRunning(true),
_lastSimulated(usecTimestampNow()) _lastSimulated(usecTimestampNow())
{ {
} }
@ -55,7 +55,7 @@ AnimationLoop::AnimationLoop(float fps, bool loop, bool hold, bool startAutomati
_lastFrame(lastFrame), _lastFrame(lastFrame),
_running(running), _running(running),
_frameIndex(frameIndex), _frameIndex(frameIndex),
_resetOnRunning(false), _resetOnRunning(true),
_lastSimulated(usecTimestampNow()) _lastSimulated(usecTimestampNow())
{ {
} }
@ -91,7 +91,7 @@ void AnimationLoop::simulate(float deltaTime) {
} }
void AnimationLoop::setStartAutomatically(bool startAutomatically) { void AnimationLoop::setStartAutomatically(bool startAutomatically) {
if ((_startAutomatically = startAutomatically) && !isRunning()) { if ((_startAutomatically = startAutomatically) && !getRunning()) {
start(); start();
} }
} }

View file

@ -47,7 +47,6 @@ public:
void setResetOnRunning(bool resetOnRunning) { _resetOnRunning = resetOnRunning; } void setResetOnRunning(bool resetOnRunning) { _resetOnRunning = resetOnRunning; }
void setRunning(bool running); void setRunning(bool running);
bool getRunning() const { return _running; } bool getRunning() const { return _running; }
bool isRunning() const { return _running; }
void setFrameIndex(float frameIndex) { _frameIndex = glm::clamp(frameIndex, _firstFrame, _lastFrame); } void setFrameIndex(float frameIndex) { _frameIndex = glm::clamp(frameIndex, _firstFrame, _lastFrame); }
float getFrameIndex() const { return _frameIndex; } float getFrameIndex() const { return _frameIndex; }

View file

@ -107,7 +107,7 @@ public:
void getAnimationFrame(bool& newFrame, QVector<glm::quat>& rotationsResult, QVector<glm::vec3>& translationsResult); void getAnimationFrame(bool& newFrame, QVector<glm::quat>& rotationsResult, QVector<glm::vec3>& translationsResult);
bool jointsMapped() const { return _jointMappingCompleted; } bool jointsMapped() const { return _jointMappingCompleted; }
bool getAnimationIsPlaying() const { return _animationLoop.isRunning(); } bool getAnimationIsPlaying() const { return _animationLoop.getRunning(); }
float getAnimationFrameIndex() const { return _animationLoop.getFrameIndex(); } float getAnimationFrameIndex() const { return _animationLoop.getFrameIndex(); }
float getAnimationFPS() const { return _animationLoop.getFPS(); } float getAnimationFPS() const { return _animationLoop.getFPS(); }