Search Issue Tracker
By Design
Votes
0
Found in
2019.4
2020.3
2021.2
2022.1
2022.1.0b7
2022.2
Issue ID
1402743
Regression
No
Video Player rewind button does not pause the video
How to reproduce:
1. Open project "NewVideoPlayer-TestProject-master.zip"
2. Enter Play Mode
3. Press the rewind button
4. Observe the video
Expected result: Video is stopped
Actual result: Video is not stopped
Reproducible with: 2019.4.36f1, 2020.3.30f1, 2021.2.13f1, 2022.1.0b9, 2022.2.0a5
Notes:
- Forward button is pausing the video when pressed
- If pressing the forward button and then pressing the rewind button then the rewind button is working as expected, but if pressing multiple times then the rewind button will do nothing
- Reproducible in the Editor and in the Player
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Mono Windows Builds don't produce full log callstacks when generating logs
- AssetBundles fail to load when running in Built Players for Mobile Devices
- UI elements with text gets bigger and grey when Player window is moved to another screen with different resolution
- System name accepts multiline text but crops it on confirmation, duplicates input, and shrinks the field when empty
- UI element scale and position are wrong in project build when DRS is changed with HDR and Software Dynamic Resolution enabled
Resolution Note:
In this project's VideoControls.cs, your implementation of Rewind() is using VideoPlayer.frame = "some value", which is a seek operation. Seek operations don't interfere with the playback status. If the movie is playing, it continues to do so. If it's paused, it remains paused.
On the other hand, your implementation of Forward() makes use of VideoPlayer.StepFrame(), which not only advances to the next frame, but also forces the player to be paused (assuming the user from this point on wants to keep advancing explicitly step by step).
If it is desirable for your app to preserve the playback state when moving forward, then a similar logic to what's done in Rewind should be done, by directly using vPlayer.frame. Or you could be doing vPlayer.Pause().