diff options
author | Peter Kohaut | 2019-03-04 19:10:45 +0100 |
---|---|---|
committer | Peter Kohaut | 2019-03-04 19:43:45 +0100 |
commit | 59f4893547fc9b4506a104876b6c37ded5ffc340 (patch) | |
tree | d365d94209e9add5078e56269a5cdcfdad56c342 /engines | |
parent | 9c25be9121bbd159163c458ce500379774a2ef3e (diff) | |
download | scummvm-rg350-59f4893547fc9b4506a104876b6c37ded5ffc340.tar.gz scummvm-rg350-59f4893547fc9b4506a104876b6c37ded5ffc340.tar.bz2 scummvm-rg350-59f4893547fc9b4506a104876b6c37ded5ffc340.zip |
BLADERUNNER: Fixed stereo balance for speech
Diffstat (limited to 'engines')
-rw-r--r-- | engines/bladerunner/actor.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/engines/bladerunner/actor.cpp b/engines/bladerunner/actor.cpp index a5cc4c492b..f616614ee0 100644 --- a/engines/bladerunner/actor.cpp +++ b/engines/bladerunner/actor.cpp @@ -1144,10 +1144,8 @@ void Actor::speechPlay(int sentenceId, bool voiceOver) { int balance = 0; if (!voiceOver && _id != BladeRunnerEngine::kActorVoiceOver) { - // Vector3 pos = _vm->_view->_frameViewMatrix * _position; - int screenX = 320; //, screenY = 0; - //TODO: transform to screen space using fov; - balance = 127 * (2 * screenX - 640) / 640; + Vector3 screenPosition = _vm->_view->calculateScreenPosition(_position); + balance = (127 * (2 * screenPosition.x - 640)) / 640; balance = CLIP<int>(balance, -127, 127); } |