[Scummvm-tracker] [ScummVM :: Bugs] #13815: GROOVIE video fast playback stop capability & solution

ScummVM :: Bugs trac at scummvm.org
Wed Aug 31 08:14:50 UTC 2022


#13815: GROOVIE video fast playback stop capability & solution
----------------------------+------------------------------
Reporter:  lolovo           |       Owner:  (none)
    Type:  feature request  |      Status:  new
Priority:  normal           |   Component:  Engine: Groovie
 Version:                   |  Resolution:
Keywords:  groovie          |        Game:  7th Guest
----------------------------+------------------------------
Changes (by lolovo):

 * component:  --Unset-- => Engine: Groovie


Old description:

> Hi,
>
> It will be convenient to make stop video fast playback capability (new
> feature in 2.6.0, in groovie engine) because sometime you need to skip
> only some part, not the whole video playback as well as situation when
> you skip slow movement during the game process but want to stop on some
> video scene to watch it (for example, now if you make fast playback by
> clicking right mouse button during movement to skip slow movement
> animation you also skip video scenes with ghosts in the house and this is
> not right).
>
> The solution is the following - when you got second right mouse button
> click and already did fast playback, then just stop it :
>
> groovie/script.cpp (patch starts from /*patch*/ line):
>
> {{{
> ...
> bool Script::playvideofromref(uint32 fileref, bool loopUntilAudioDone) {
> ...
>         // Check if the user wants to skip the video
>         if (_eventMouseClicked == 2 || _eventKbdChar ==
> Common::KEYCODE_ESCAPE || _eventKbdChar == Common::KEYCODE_SPACE) {
>                 // we don't want to clear a left click here, that would
> eat the input
>                 if (_eventMouseClicked == 2)
>                         _eventMouseClicked = 0;
>                 _eventKbdChar = 0;
>                 if (_videoSkipAddress != 0) {
>                         // Jump to the given address
>                         _currentInstruction = _videoSkipAddress;
>
>                         // Reset the skip address
>                         _videoSkipAddress = 0;
>
>                         _bitflags = 0;
>
>                         // End the playback
>                         return true;
>                 }
>                 /*patch*/
>                 if(_fastForwarding == true)
>                 {
>                         resetFastForward();
>                         _vm->_videoPlayer->setOverrideSpeed(false);
>                 }else {
>                         _vm->_videoPlayer->fastForward();
>                         _fastForwarding = true;
>                 }
>         } else if (_fastForwarding) {
>                 _vm->_videoPlayer->fastForward();
>         }
> ...
> }
> ...
> }}}
>
> groovie/video/player.h (setOverrideSpeed should be public not protected
> in this case):
> {{{
> public:
> ...
>         void setOverrideSpeed(bool isOverride);
> protected:
> ...
> }}}
>
> With this fix all works fine. You just can click by right mouse when you
> like to stop fast playback and you start watch video playback with sound
> from this point (without calling setOverrideSpeed fast playback stops
> only from next video scene, in this case you skip ghost scenes after
> movement). Please verify this , it will be very useful and convenient
> capability.

New description:

 Hi,

 It will be convenient to make stop video fast playback capability (new
 feature in 2.6.0, in groovie engine) because sometimes you need to skip
 only some part, not the whole video playback as well as situation when you
 skip slow movement during the game process but want to stop on some video
 scene to watch it (for example, now if you make fast playback by clicking
 right mouse button during movement to skip slow movement animation you
 also skip video scenes with ghosts in the house and this is not right).

 The solution is the following - when you got second right mouse button
 click and already did fast playback, then just stop it :

 groovie/script.cpp (patch starts from /*patch*/ line):

 {{{
 ...
 bool Script::playvideofromref(uint32 fileref, bool loopUntilAudioDone) {
 ...
         // Check if the user wants to skip the video
         if (_eventMouseClicked == 2 || _eventKbdChar ==
 Common::KEYCODE_ESCAPE || _eventKbdChar == Common::KEYCODE_SPACE) {
                 // we don't want to clear a left click here, that would
 eat the input
                 if (_eventMouseClicked == 2)
                         _eventMouseClicked = 0;
                 _eventKbdChar = 0;
                 if (_videoSkipAddress != 0) {
                         // Jump to the given address
                         _currentInstruction = _videoSkipAddress;

                         // Reset the skip address
                         _videoSkipAddress = 0;

                         _bitflags = 0;

                         // End the playback
                         return true;
                 }
                 /*patch*/
                 if(_fastForwarding == true)
                 {
                         resetFastForward();
                         _vm->_videoPlayer->setOverrideSpeed(false);
                 }else {
                         _vm->_videoPlayer->fastForward();
                         _fastForwarding = true;
                 }
         } else if (_fastForwarding) {
                 _vm->_videoPlayer->fastForward();
         }
 ...
 }
 ...
 }}}

 groovie/video/player.h (setOverrideSpeed should be public not protected in
 this case):
 {{{
 public:
 ...
         void setOverrideSpeed(bool isOverride);
 protected:
 ...
 }}}

 With this fix all works fine. You just can click by right mouse when you
 like to stop fast playback and you start watch video playback with sound
 from this point (without calling setOverrideSpeed fast playback stops only
 from next video scene, in this case you skip ghost scenes after movement).
 Please verify this , it will be very useful and convenient capability.

--
-- 
Ticket URL: <https://bugs.scummvm.org/ticket/13815#comment:1>
ScummVM :: Bugs <https://bugs.scummvm.org>
ScummVM


More information about the Scummvm-tracker mailing list