mirror of
https://github.com/overte-org/overte.git
synced 2025-08-06 20:58:38 +02:00
Merge branch 'master' of https://github.com/worklist/hifi into off
This commit is contained in:
commit
3a195951db
3 changed files with 26 additions and 10 deletions
|
@ -54,6 +54,7 @@ find_package(Qt5OpenGL REQUIRED)
|
||||||
find_package(Qt5Svg REQUIRED)
|
find_package(Qt5Svg REQUIRED)
|
||||||
|
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
|
set(MACOSX_BUNDLE_BUNDLE_NAME Interface)
|
||||||
# set how the icon shows up in the Info.plist file
|
# set how the icon shows up in the Info.plist file
|
||||||
SET(MACOSX_BUNDLE_ICON_FILE interface.icns)
|
SET(MACOSX_BUNDLE_ICON_FILE interface.icns)
|
||||||
|
|
||||||
|
|
|
@ -189,15 +189,18 @@ void Head::simulate(float deltaTime, bool isMine, float gyroCameraSensitivity) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update audio attack data for facial animation (eyebrows and mouth)
|
// Update audio attack data for facial animation (eyebrows and mouth)
|
||||||
_audioAttack = 0.9 * _audioAttack + 0.1 * fabs(_audioLoudness - _lastLoudness);
|
_audioAttack = 0.9f * _audioAttack + 0.1f * fabs(_audioLoudness - _lastLoudness);
|
||||||
_lastLoudness = _audioLoudness;
|
_lastLoudness = _audioLoudness;
|
||||||
|
|
||||||
const float BROW_LIFT_THRESHOLD = 100;
|
const float BROW_LIFT_THRESHOLD = 100.0f;
|
||||||
if (_audioAttack > BROW_LIFT_THRESHOLD)
|
if (_audioAttack > BROW_LIFT_THRESHOLD) {
|
||||||
_browAudioLift += sqrt(_audioAttack) * 0.00005;
|
_browAudioLift += sqrtf(_audioAttack) * 0.00005f;
|
||||||
|
}
|
||||||
float clamp = 0.01;
|
|
||||||
if (_browAudioLift > clamp) { _browAudioLift = clamp; }
|
const float CLAMP = 0.01f;
|
||||||
|
if (_browAudioLift > CLAMP) {
|
||||||
|
_browAudioLift = CLAMP;
|
||||||
|
}
|
||||||
|
|
||||||
_browAudioLift *= 0.7f;
|
_browAudioLift *= 0.7f;
|
||||||
|
|
||||||
|
|
|
@ -13,9 +13,21 @@
|
||||||
using namespace fs;
|
using namespace fs;
|
||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
||||||
Faceshift::Faceshift() : _enabled(false), _eyeGazeLeftPitch(0.0f), _eyeGazeLeftYaw(0.0f), _eyeGazeRightPitch(0.0f),
|
Faceshift::Faceshift() :
|
||||||
_eyeGazeRightYaw(0.0f), _leftBlink(0.0f), _rightBlink(0.0f), _leftBlinkIndex(-1), _rightBlinkIndex(-1),
|
_enabled(false),
|
||||||
_browHeight(0.0f), _browUpCenterIndex(-1), _mouthSize(0.0f), _jawOpenIndex(-1) {
|
_eyeGazeLeftPitch(0.0f),
|
||||||
|
_eyeGazeLeftYaw(0.0f),
|
||||||
|
_eyeGazeRightPitch(0.0f),
|
||||||
|
_eyeGazeRightYaw(0.0f),
|
||||||
|
_leftBlink(0.0f),
|
||||||
|
_rightBlink(0.0f),
|
||||||
|
_leftBlinkIndex(-1),
|
||||||
|
_rightBlinkIndex(-1),
|
||||||
|
_browHeight(0.0f),
|
||||||
|
_browUpCenterIndex(-1),
|
||||||
|
_mouthSize(0.0f),
|
||||||
|
_jawOpenIndex(-1)
|
||||||
|
{
|
||||||
connect(&_socket, SIGNAL(connected()), SLOT(noteConnected()));
|
connect(&_socket, SIGNAL(connected()), SLOT(noteConnected()));
|
||||||
connect(&_socket, SIGNAL(error(QAbstractSocket::SocketError)), SLOT(noteError(QAbstractSocket::SocketError)));
|
connect(&_socket, SIGNAL(error(QAbstractSocket::SocketError)), SLOT(noteError(QAbstractSocket::SocketError)));
|
||||||
connect(&_socket, SIGNAL(readyRead()), SLOT(readFromSocket()));
|
connect(&_socket, SIGNAL(readyRead()), SLOT(readFromSocket()));
|
||||||
|
|
Loading…
Reference in a new issue