1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-06 03:50:26 +02:00

Merge branch 'release/6.3.0' into develop

This commit is contained in:
Chocobozzz 2024-10-22 10:53:11 +02:00
commit 5af6cf6e82
No known key found for this signature in database
GPG key ID: 583A612D890159BE
10 changed files with 126 additions and 29 deletions

View file

@ -1,6 +1,6 @@
import ffmpeg, { FfprobeData } from 'fluent-ffmpeg'
import { buildAspectRatio, forceNumber } from '@peertube/peertube-core-utils'
import { VideoResolution } from '@peertube/peertube-models'
import ffmpeg, { FfprobeData } from 'fluent-ffmpeg'
/**
*
@ -111,7 +111,11 @@ async function getVideoStreamDimensionsInfo (path: string, existingProbe?: Ffpro
}
}
if (videoStream.rotation === '90' || videoStream.rotation === '-90') {
const rotation = videoStream.rotation
? videoStream.rotation + ''
: undefined
if (rotation === '90' || rotation === '-90') {
const width = videoStream.width
videoStream.width = videoStream.height
videoStream.height = width
@ -202,16 +206,19 @@ async function getChaptersFromContainer (options: {
// ---------------------------------------------------------------------------
export {
getVideoStreamDimensionsInfo,
getChaptersFromContainer,
getMaxAudioBitrate,
getVideoStream,
getVideoStreamDuration,
getAudioStream,
getVideoStreamFPS,
isAudioFile,
ffprobePromise,
getAudioStream,
getChaptersFromContainer,
getMaxAudioBitrate,
getVideoStream,
getVideoStreamBitrate,
getVideoStreamDimensionsInfo,
getVideoStreamDuration,
getVideoStreamFPS,
hasAudioStream,
hasVideoStream
hasVideoStream,
isAudioFile
}