1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-05 19:42:24 +02:00

Separate HLS audio and video streams

Allows:
  * The HLS player to propose an "Audio only" resolution
  * The live to output an "Audio only" resolution
  * The live to ingest and output an "Audio only" stream

 This feature is under a config for VOD videos and is enabled by default for lives

 In the future we can imagine:
  * To propose multiple audio streams for a specific video
  * To ingest an audio only VOD and just output an audio only "video"
    (the player would play the audio file and PeerTube would not
    generate additional resolutions)

This commit introduce a new way to download videos:
 * Add "/download/videos/generate/:videoId" endpoint where PeerTube can
   mux an audio only and a video only file to a mp4 container
 * The download client modal introduces a new default panel where the
   user can choose resolutions it wants to download
This commit is contained in:
Chocobozzz 2024-07-23 16:38:51 +02:00 committed by Chocobozzz
parent e77ba2dfbc
commit 816f346a60
186 changed files with 5748 additions and 2807 deletions

View file

@ -289,6 +289,8 @@ tags:
description: Video statistics
- name: Video Feeds
description: Server syndication feeds of videos
- name: Video Download
description: Download video files
- name: Search
description: |
The search helps to find _videos_ or _channels_ from within the instance and beyond.
@ -318,6 +320,9 @@ x-tagGroups:
- name: Static endpoints
tags:
- Static Video Files
- name: Download
tags:
- Video Download
- name: Feeds
tags:
- Video Feeds
@ -449,6 +454,32 @@ paths:
'404':
description: not found
'/download/videos/generate/:videoId':
get:
tags:
- Video Download
summary: Download video file
description: Generate a mp4 container that contains at most 1 video stream and at most 1 audio stream.
Mainly used to merge the HLS audio only video file and the HLS video only resolution file.
parameters:
- name: videoId
in: path
required: true
description: The video id
schema:
$ref: '#/components/schemas/Video/properties/id'
- name: videoFileIds
in: query
required: true
description: streams of video files to mux in the output
schema:
type: array
items:
type: integer
- $ref: '#/components/parameters/videoFileToken'
responses:
'200':
description: successful operation
'/feeds/video-comments.{format}':
get:
@ -9542,6 +9573,8 @@ components:
properties:
enabled:
type: boolean
splitAudioAndVideo:
type: boolean
import:
type: object
properties: