Skip to content

Commit

Permalink
Use format streams by default instead of DASH (#53)
Browse files Browse the repository at this point in the history
  • Loading branch information
iBicha authored Mar 2, 2023
1 parent 52b4feb commit aaea507
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Fixed
- Crash in case GetLocalIpAddress() returns invalid
- Use Format Stream (720p) instead of DASH (https://github.com/iv-org/invidious/issues/3666)

## [0.7.0] - 2023-02-04
### Added
Expand Down
15 changes: 8 additions & 7 deletions playlet-lib/src/components/VideoPlayer/VideoPlayer.bs
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,14 @@ function OnVideoDetailsTaskResults(output as object) as void
end if
playletStreamUrls.push(hlsUrlLocal)
else
if metadata.formatStreams.Count() > 0
stream = metadata.formatStreams[metadata.formatStreams.Count() - 1]
itag = stream.itag

playletStreamUrls.push(Invidious.GetVideoUrl(videoId, itag, false))
playletStreamUrls.push(Invidious.GetVideoUrl(videoId, itag, true))
end if

if metadata.dashUrl <> invalid

#if DASH_THUMBNAILS
Expand All @@ -135,13 +143,6 @@ function OnVideoDetailsTaskResults(output as object) as void
playletStreamUrls.push(dashUrlLocal)
end if

if metadata.formatStreams.Count() > 0
stream = metadata.formatStreams[metadata.formatStreams.Count() - 1]
itag = stream.itag

playletStreamUrls.push(Invidious.GetVideoUrl(videoId, itag, false))
playletStreamUrls.push(Invidious.GetVideoUrl(videoId, itag, true))
end if
end if

metadata.playletStreamUrls = playletStreamUrls
Expand Down

0 comments on commit aaea507

Please sign in to comment.