Project

General

Profile

Actions

action #42050

closed

Improve video player (was: Add note about time scaling of OGV files)

Added by mkittler over 5 years ago. Updated about 4 years ago.

Status:
Resolved
Priority:
Low
Assignee:
Category:
Feature requests
Target version:
Start date:
2018-10-05
Due date:
% Done:

0%

Estimated time:

Description

Motivation

Better video player with information about how the video run time relates to real time.

Acceptance criteria

  • AC1: Video player reflects information about time scaling

Suggestions

Further details

Original proposal

Currently videoencoder.cpp produces an OGG/Theora stream with the framerate hardcoded to 24 FPS. Of course 24 FPS is not really the case, leading to the videos played 12 times faster. It would be useful to add a note in the web UI that the videos are played faster by a constant factor of 12 so people can multiply timestamps or durations to know how long something took for real.


Related issues 1 (0 open1 closed)

Related to openQA Project - action #34345: use streams in ogg format to embed more information in the videoRejectedokurz2018-04-05

Actions
Actions #1

Updated by okurz over 5 years ago

I like the time lapse effect of the current implementation. If you make the videos play in real-time speed by default I am sure some people would watch the videos in real-time and waste their time :D

Actions #2

Updated by coolo over 5 years ago

And the fact remains that the video is not real time, but really jumpy - turtle speed :)

Actions #3

Updated by mkittler over 5 years ago

Mh... haven't tough about Chromium users. In Firefox one can just select the desired playback speed in the right-click context menu but Chromium doesn't offer this (actually one of the reasons I still prefer Firefox). Not sure how people actually watch these videos. I usually use mpv URL because it is really good at seeking and shortcuts are nice (including ] to increase the speed).

And the fact remains that the video is not real time, but really jumpy - turtle speed

That is true. Maybe it would be nice if only the timestamps would be adjusted but not the playback speed. So the player's progress bar would show the real time but still play it by default with 24 FPS. Likely that's not possible.

Is the speed of the video as it is right now increased by a constant factor? If so, I could just tell people (who are asking me about this) to multiply by a certain factor if they want to know the real time.

Actions #4

Updated by coolo over 5 years ago

I disagree to play the video at real time by default. And firefox only allows between 0.5x and 2x speed - and our videos are 12x. Putting that info in the webui could help users I guess

Actions #5

Updated by mkittler over 5 years ago

  • Subject changed from Produce correctly timed OGV files to Add note about time scaling of OGV files
  • Description updated (diff)

I agree that playing in realtime would make things worse. I updated the ticket description.

Actions #6

Updated by sebchlad over 5 years ago

" so people can multiply timestamps or durations to know how long something took for real." if this information is indeed useful, should we perhaps add the adjusted timestamps to logs?

Actions #7

Updated by coolo over 5 years ago

the logs contain real timestamps. this is just about netflix customers

Actions #8

Updated by StefanBruens over 5 years ago

Videos are not written with a constant "real time" frame rate, but based on similarity level. See
https://github.com/os-autoinst/os-autoinst/blob/23d7584b7ff798fe9bd33e9faf5e8ef9cd5900a4/backend/baseclass.pm#L424

One possibility to make the relation between "real time"/wallclock timestamps and video time visible would be to:

  1. output the video timestamp in the autoinst.log every time(?) a video frame is written
  2. create a subtitle file showing the wallclock time - https://hacks.mozilla.org/2014/07/adding-captions-and-subtitles-to-html5-video/
Actions #9

Updated by coolo over 5 years ago

we either write a new frame or a R - so IMO it is constant frame rate

Actions #10

Updated by StefanBruens over 5 years ago

You are almost correct - we try to push frames at a constant rate of 0.5s/frames, but in reality this ends up somewhat slower, sometimes significanly slower in case of stalls.

I have created a prototype for overlaying wall clock timestamps (can be switched of), see https://stefanbruens.github.io/

Actions #11

Updated by coolo over 5 years ago

But does the error really matter? I guess the use case is to report 'it took 2 minutes for X' - and this might have been actually 110 or 130 seconds instead (and the error is most likely not even that big).

Having said that, I do like your prototype

Actions #12

Updated by mkittler over 5 years ago

@StefanBruens I never considered the possibility of creating our own web-based media player. But this looks good and it wouldn't be a big effort to include it in openQA.

Reference to outstanding PR: https://github.com/os-autoinst/os-autoinst/pull/1059

Actions #13

Updated by okurz over 5 years ago

  • Status changed from New to Workable

@mkittler what do you see missing after the PR?

Actions #14

Updated by okurz over 5 years ago

  • Related to action #34345: use streams in ogg format to embed more information in the video added
Actions #15

Updated by okurz over 4 years ago

@StefanBruens could you share a bit about your prototype from #42050#note-10 ? Can you say where is the code for that?

Actions #16

Updated by StefanBruens over 4 years ago

okurz wrote:

@StefanBruens could you share a bit about your prototype from #42050#note-10 ? Can you say where is the code for that?

The complete code is actually in the link above, https://stefanbruens.github.io/ , or if you prefer a github repository, https://github.com/StefanBruens/StefanBruens.github.io

Everything is in the index.html, which links to the video.ogv and video_time.vtt

Actions #17

Updated by okurz over 4 years ago

ah, great! I did not know if you "generate" any code for the HTML document in https://stefanbruens.github.io/ so this is why I asked but, yeah, the HTML source is clean and easy to read. So, do you have any preferences or suggestions how to continue? If you propose a PR for openQA yourself we can integrate it of course. If you suggest someone else takes the code as template then it would be good if you can confirm someone else may use it, at best licensed under GPLv2, same as openQA. Ok for you?

Actions #18

Updated by okurz over 4 years ago

  • Subject changed from Add note about time scaling of OGV files to Improve video player (was: Add note about time scaling of OGV files)
  • Description updated (diff)
Actions #19

Updated by okurz over 4 years ago

  • Status changed from Workable to Feedback
  • Assignee set to okurz
  • Target version set to Current Sprint

My proposal incorporating the prototype from StefanBruens into openQA: https://github.com/os-autoinst/openQA/pull/2604 and https://github.com/os-autoinst/openQA/pull/2605 for a simplified alternative.

Actions #20

Updated by okurz over 4 years ago

simplified version merged

Actions #21

Updated by livdywan about 4 years ago

So #2605 was merged, #2604 is still marked as WIP. Are there more features being worked on?

Actions #22

Updated by okurz about 4 years ago

  • Status changed from Feedback to Resolved

Well, I don't have any further plans for the next days. I closed https://github.com/os-autoinst/openQA/pull/2604 and based on the existing ACs I think we can call this done. Eventually we might want to improve the video player further but I guess it's currently ok.

Actions

Also available in: Atom PDF