Skip to content

Conversation

@some-git-user
Copy link

@some-git-user some-git-user commented Aug 8, 2025

Pull Request Type

  • Bugfix
  • Feature Implementation
  • Documentation
  • Other

Related issue

closes #1766

Description

This PR implements a simple silence skip logic, to dynamically determine silent video parts, related to the individual max volume of the audio source.

Screenshots

2025-10-14.21-02-12.1.mp4

Testing

  • Open any video (prefer a podcast with silent or mute parts between conversations).
  • Toggle the function via the overflow menu Button.
  • Watch/hear the player increasing playback speed to 3x between silent/mute audio parts and decreasing to 1x speed when audio is detected.
  • Toggle the function again to deactivate and fallback to default 1x speed

Desktop

  • OS: debian
  • OS Version: 13
  • FreeTube version: v0.23.11 Beta

Additional context

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) August 8, 2025 21:10
@github-actions github-actions bot added the PR: waiting for review For PRs that are complete, tested, and ready for review label Aug 8, 2025
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove all the locale files. Only keep en-us

@efb4f5ff-1298-471a-8973-3d47447115dc efb4f5ff-1298-471a-8973-3d47447115dc added PR: changes requested and removed PR: waiting for review For PRs that are complete, tested, and ready for review labels Aug 9, 2025
auto-merge was automatically disabled August 9, 2025 07:46

Head branch was pushed to by a user without write access

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) August 9, 2025 07:46
auto-merge was automatically disabled August 9, 2025 07:53

Head branch was pushed to by a user without write access

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) August 9, 2025 07:53
auto-merge was automatically disabled August 9, 2025 08:00

Head branch was pushed to by a user without write access

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) August 9, 2025 08:00
@efb4f5ff-1298-471a-8973-3d47447115dc

Im a bit confused by this skip rate. Please elaborate why you chose for 2.5x instead of e.g. 10x

Lets say the ending of a certain video is 60sec it will take 24sec to skip the silence. Thats way too long imo.

Why not detect when there is no audio and detect when audio is playing again and instantly skip towards that timestamp instead of relying on playback rate to handle this

@some-git-user
Copy link
Author

Im a bit confused by this skip rate. Please elaborate why you chose for 2.5x instead of e.g. 10x

Lets say the ending of a certain video is 60sec it will take 24sec to skip the silence. Thats way too long imo.

Why not detect when there is no audio and detect when audio is playing again and instantly skip towards that timestamp instead of relying on playback rate to handle this
the

The main goal of this feature is to skip (accelerate) silence between conversations, or other silent parts, not to fast forward to the end of a video.
I tried different speed steps with multiple videos and 2.5x was the best one in my tests, since faster steps could also "cut off" the beginning of the next non silent part.

I'm not sure how to "detect when there is no audio and detect when audio is playing again and instantly skip towards that timestamp" .
Maybe I'm wrong here, but to know this you must buffer and analyze the whole video before the playback start, so the code knows the parts with no audio.
I also tried to create a little UI, to let the user make individual changes for every video, to match the needed audio threshold, but I'm not familiar with Vue and the lack of Typescript made it even harder for me to get into this project.

@efb4f5ff-1298-471a-8973-3d47447115dc efb4f5ff-1298-471a-8973-3d47447115dc added PR: waiting for review For PRs that are complete, tested, and ready for review and removed PR: changes requested labels Aug 11, 2025
@efb4f5ff-1298-471a-8973-3d47447115dc

This implementation works really well, especially considering that our player is the limiting factor in this case.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would like to be a button for this inside the player instead of outside the player

@efb4f5ff-1298-471a-8973-3d47447115dc efb4f5ff-1298-471a-8973-3d47447115dc added PR: changes requested and removed PR: waiting for review For PRs that are complete, tested, and ready for review labels Aug 12, 2025
auto-merge was automatically disabled August 13, 2025 21:37

Head branch was pushed to by a user without write access

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) August 13, 2025 21:38
auto-merge was automatically disabled November 3, 2025 19:54

Head branch was pushed to by a user without write access

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) November 3, 2025 19:54
Co-authored-by: efb4f5ff-1298-471a-8973-3d47447115dc <73130443+efb4f5ff-1298-471a-8973-3d47447115dc@users.noreply.github.com>
auto-merge was automatically disabled November 3, 2025 19:54

Head branch was pushed to by a user without write access

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) November 3, 2025 19:55
auto-merge was automatically disabled November 3, 2025 23:32

Head branch was pushed to by a user without write access

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) November 3, 2025 23:32
@efb4f5ff-1298-471a-8973-3d47447115dc

Umm i think this isnt supposed to happen. It default to 10x now

VirtualBoxVM_g9v0U7dPlB.mp4

Discussion point: What should we do about people that are using a playback speed above 3x? I mean if i use 4x to watch a video and silent parts kicks in it probably shouldnt touch the playback speed right?

I think we probably should implement not touching the playback speed if its above 3x

@some-git-user
Copy link
Author

@efb4f5ff-1298-471a-8973-3d47447115dc I used the user setting values for the fast and normal playback speed. I tested multiple values with various videos and it worked fine even with 10x forward speed. So in your case it's at 10x speed because this should also be your "Max Video Playback Rate"?
image

Do you have problems with speeds above 3x ? I can't unmute in your provided video examples. Are they recorded with sound?
image

@efb4f5ff-1298-471a-8973-3d47447115dc
Copy link
Member

efb4f5ff-1298-471a-8973-3d47447115dc commented Nov 5, 2025

@some-git-user

Do you have problems with speeds above 3x ? I can't unmute in your provided video examples. Are they recorded with sound?

The arent recorded with sound but i think this case doesnt apply anymore because of the change you explained

I used the user setting values for the fast and normal playback speed. I tested multiple values with various videos and it worked fine even with 10x forward speed. So in your case it's at 10x speed because this should also be your "Max Video Playback Rate"?

Yes it is 10x. I will reevaluate!

@efb4f5ff-1298-471a-8973-3d47447115dc

My Max video playback rate is set to 10x in the settings. Within the first 10sec of this video https://youtu.be/gT0rd69e5fo it will skip some silence but it also cuts of 2 words that have been said

@some-git-user
Copy link
Author

@efb4f5ff-1298-471a-8973-3d47447115dc I think the 10x speed is too aggressive in some cases. The default 3x should be enough in most cases?

@efb4f5ff-1298-471a-8973-3d47447115dc

i think 3x should be enough but i would like to hear from @PikachuEXE and @absidue before we decide on the right speed

@PikachuEXE
Copy link
Collaborator

I found it sound too rushy with it enabled, and I am not sure if it's better or worse to add N seconds before/after the speed up
e.g. https://youtu.be/l8h4QgtNL0M
And I am not sure if it also skip through something (but I only tested it briefly so could be wrong)
On the speed I think 3x is fine (the gap/skip too much thing is bigger and once solved the speed while actual silence is not that important
Need longer term testing

auto-merge was automatically disabled November 28, 2025 14:20

Head branch was pushed to by a user without write access

@FreeTubeBot FreeTubeBot enabled auto-merge (squash) November 28, 2025 14:21
@efb4f5ff-1298-471a-8973-3d47447115dc

3x seemed fine to me before it changed so maybe we should go back to that? Or are there other more logical speeds for this?

@some-git-user
Copy link
Author

@efb4f5ff-1298-471a-8973-3d47447115dc would it be a problem,to let it be configurable?

@efb4f5ff-1298-471a-8973-3d47447115dc

@some-git-user i prefer to not make this feature configurable. I prefer to go with good defaults instead of creating yet another slider/toggle in the settings

@github-actions
Copy link
Contributor

github-actions bot commented Dec 3, 2025

This pull request has conflicts, please resolve those before we can evaluate the pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature Request] Skip the silence in media playback

4 participants