mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-03 17:59:37 +02:00
Support RTMPS
This commit is contained in:
parent
8dd754c767
commit
df1db951c5
20 changed files with 343 additions and 51 deletions
|
@ -219,7 +219,7 @@ async function transcode (options: TranscodeOptions) {
|
|||
// ---------------------------------------------------------------------------
|
||||
|
||||
async function getLiveTranscodingCommand (options: {
|
||||
rtmpUrl: string
|
||||
inputUrl: string
|
||||
|
||||
outPath: string
|
||||
masterPlaylistName: string
|
||||
|
@ -234,10 +234,9 @@ async function getLiveTranscodingCommand (options: {
|
|||
availableEncoders: AvailableEncoders
|
||||
profile: string
|
||||
}) {
|
||||
const { rtmpUrl, outPath, resolutions, fps, bitrate, availableEncoders, profile, masterPlaylistName, ratio } = options
|
||||
const input = rtmpUrl
|
||||
const { inputUrl, outPath, resolutions, fps, bitrate, availableEncoders, profile, masterPlaylistName, ratio } = options
|
||||
|
||||
const command = getFFmpeg(input, 'live')
|
||||
const command = getFFmpeg(inputUrl, 'live')
|
||||
|
||||
const varStreamMap: string[] = []
|
||||
|
||||
|
@ -259,7 +258,7 @@ async function getLiveTranscodingCommand (options: {
|
|||
const resolutionFPS = computeFPS(fps, resolution)
|
||||
|
||||
const baseEncoderBuilderParams = {
|
||||
input,
|
||||
input: inputUrl,
|
||||
|
||||
availableEncoders,
|
||||
profile,
|
||||
|
@ -327,8 +326,8 @@ async function getLiveTranscodingCommand (options: {
|
|||
return command
|
||||
}
|
||||
|
||||
function getLiveMuxingCommand (rtmpUrl: string, outPath: string, masterPlaylistName: string) {
|
||||
const command = getFFmpeg(rtmpUrl, 'live')
|
||||
function getLiveMuxingCommand (inputUrl: string, outPath: string, masterPlaylistName: string) {
|
||||
const command = getFFmpeg(inputUrl, 'live')
|
||||
|
||||
command.outputOption('-c:v copy')
|
||||
command.outputOption('-c:a copy')
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue