[Scummvm-git-logs] scummvm master -> 8c01800e91f70ef970530a68b2c6b688900d36d7
elasota
noreply at scummvm.org
Thu Mar 16 05:23:30 UTC 2023
This automated email contains information about 3 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
116a3be86b VCRUISE: Fix incorrect volume ramping behavior on 3D sounds
c8e4ea534e VCRUISE: Add swap opcode
8c01800e91 VCRUISE: Remove spammy debug message
Commit: 116a3be86bd6bc13a9c4a0e0e03eeb1e18bf5ea3
https://github.com/scummvm/scummvm/commit/116a3be86bd6bc13a9c4a0e0e03eeb1e18bf5ea3
Author: elasota (ejlasota at gmail.com)
Date: 2023-03-16T01:22:28-04:00
Commit Message:
VCRUISE: Fix incorrect volume ramping behavior on 3D sounds
Changed paths:
engines/vcruise/runtime.cpp
diff --git a/engines/vcruise/runtime.cpp b/engines/vcruise/runtime.cpp
index f43f037fb82..dffb13b0773 100644
--- a/engines/vcruise/runtime.cpp
+++ b/engines/vcruise/runtime.cpp
@@ -1897,8 +1897,11 @@ void Runtime::updateSounds(uint32 timestamp) {
if (snd.volume != newVolume) {
snd.volume = newVolume;
- if (snd.player)
- snd.player->setVolume(snd.volume);
+
+ if (snd.player) {
+ computeEffectiveVolumeAndBalance(snd);
+ snd.player->setVolumeAndBalance(snd.effectiveVolume, snd.effectiveBalance);
+ }
}
}
}
Commit: c8e4ea534e5e2b93f894ad185dcdb43113477a9e
https://github.com/scummvm/scummvm/commit/c8e4ea534e5e2b93f894ad185dcdb43113477a9e
Author: elasota (ejlasota at gmail.com)
Date: 2023-03-16T01:22:28-04:00
Commit Message:
VCRUISE: Add swap opcode
Changed paths:
engines/vcruise/runtime.cpp
engines/vcruise/runtime.h
engines/vcruise/script.cpp
engines/vcruise/script.h
diff --git a/engines/vcruise/runtime.cpp b/engines/vcruise/runtime.cpp
index dffb13b0773..d74f3b44104 100644
--- a/engines/vcruise/runtime.cpp
+++ b/engines/vcruise/runtime.cpp
@@ -1065,6 +1065,7 @@ bool Runtime::runScript() {
DISPATCH_OP(Random);
DISPATCH_OP(Drop);
DISPATCH_OP(Dup);
+ DISPATCH_OP(Swap);
DISPATCH_OP(Say1);
DISPATCH_OP(Say3);
DISPATCH_OP(Say3Get);
@@ -3200,6 +3201,13 @@ void Runtime::scriptOpDup(ScriptArg_t arg) {
_scriptStack.push_back(stackArgs[0]);
}
+void Runtime::scriptOpSwap(ScriptArg_t arg) {
+ TAKE_STACK(2);
+
+ _scriptStack.push_back(stackArgs[1]);
+ _scriptStack.push_back(stackArgs[0]);
+}
+
void Runtime::scriptOpSay1(ScriptArg_t arg) {
TAKE_STACK(3);
diff --git a/engines/vcruise/runtime.h b/engines/vcruise/runtime.h
index a671b2cf2ef..46f86f68483 100644
--- a/engines/vcruise/runtime.h
+++ b/engines/vcruise/runtime.h
@@ -576,6 +576,7 @@ private:
void scriptOpRandom(ScriptArg_t arg);
void scriptOpDrop(ScriptArg_t arg);
void scriptOpDup(ScriptArg_t arg);
+ void scriptOpSwap(ScriptArg_t arg);
void scriptOpSay1(ScriptArg_t arg);
void scriptOpSay3(ScriptArg_t arg);
void scriptOpSay3Get(ScriptArg_t arg);
diff --git a/engines/vcruise/script.cpp b/engines/vcruise/script.cpp
index f67060d46d9..f0afd91c5e2 100644
--- a/engines/vcruise/script.cpp
+++ b/engines/vcruise/script.cpp
@@ -355,6 +355,7 @@ static ScriptNamedInstruction g_namedInstructions[] = {
{"rnd", ProtoOp::kProtoOpScript, ScriptOps::kRandom},
{"drop", ProtoOp::kProtoOpScript, ScriptOps::kDrop},
{"dup", ProtoOp::kProtoOpScript, ScriptOps::kDup},
+ {"swap", ProtoOp::kProtoOpScript, ScriptOps::kSwap},
{"say1", ProtoOp::kProtoOpScript, ScriptOps::kSay1},
{"say2", ProtoOp::kProtoOpScript, ScriptOps::kSay3}, // FIXME: Figure out what the difference is between say2 and say3. I think say2 is repeatable? Maybe works as say1 instead?
{"say3", ProtoOp::kProtoOpScript, ScriptOps::kSay3},
diff --git a/engines/vcruise/script.h b/engines/vcruise/script.h
index ee8be24366d..28179907650 100644
--- a/engines/vcruise/script.h
+++ b/engines/vcruise/script.h
@@ -102,6 +102,7 @@ enum ScriptOp {
kRandom,
kDrop,
kDup,
+ kSwap,
kSay1,
kSay3,
kSay3Get,
Commit: 8c01800e91f70ef970530a68b2c6b688900d36d7
https://github.com/scummvm/scummvm/commit/8c01800e91f70ef970530a68b2c6b688900d36d7
Author: elasota (ejlasota at gmail.com)
Date: 2023-03-16T01:22:29-04:00
Commit Message:
VCRUISE: Remove spammy debug message
Changed paths:
engines/vcruise/runtime.cpp
diff --git a/engines/vcruise/runtime.cpp b/engines/vcruise/runtime.cpp
index d74f3b44104..61e89284ef5 100644
--- a/engines/vcruise/runtime.cpp
+++ b/engines/vcruise/runtime.cpp
@@ -880,7 +880,6 @@ void Runtime::continuePlayingAnimation(bool loop, bool useStopFrame, bool &outAn
// if ((millis - startTime) / 1000 * frameRate) >= framesDecoded
if ((millis - _animStartTime) * static_cast<uint64>(_animFrameRateLock) >= (static_cast<uint64>(_animFramesDecoded) * 1000u))
needNewFrame = true;
- debug("FPS lock: New frame at %u millis and %u decoded? %s", static_cast<uint>(millis - _animStartTime), static_cast<uint>(_animFramesDecoded), needNewFrame ? "yes" : "no");
} else {
if (_animDecoder->getTimeToNextFrame() == 0)
needNewFrame = true;
More information about the Scummvm-git-logs
mailing list