mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-05 02:39:33 +02:00
Add video aspect ratio in server
This commit is contained in:
parent
c75381208f
commit
b6b1aaa56f
52 changed files with 345 additions and 237 deletions
|
@ -12,6 +12,7 @@ import { getTranscodingJobPriority } from './transcoding/transcoding-priority.js
|
|||
import { buildNewFile, removeHLSPlaylist, removeWebVideoFile } from './video-file.js'
|
||||
import { VideoPathManager } from './video-path-manager.js'
|
||||
import { buildStoryboardJobIfNeeded } from './video-jobs.js'
|
||||
import { buildAspectRatio } from '@peertube/peertube-core-utils'
|
||||
|
||||
const lTags = loggerTagsFactory('video-studio')
|
||||
|
||||
|
@ -104,6 +105,7 @@ export async function onVideoStudioEnded (options: {
|
|||
await newFile.save()
|
||||
|
||||
video.duration = await getVideoStreamDuration(outputPath)
|
||||
video.aspectRatio = buildAspectRatio({ width: newFile.width, height: newFile.height })
|
||||
await video.save()
|
||||
|
||||
return JobQueue.Instance.createSequentialJobFlow(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue