mirror of
https://github.com/immich-app/immich.git
synced 2025-02-03 01:22:44 +01:00
fix formatting
This commit is contained in:
parent
38f903d317
commit
5942d9b52c
2 changed files with 4 additions and 3 deletions
server/src
|
@ -432,11 +432,12 @@ export class MediaService extends BaseService {
|
|||
const targetRes = Number.parseInt(ffmpegConfig.targetResolution);
|
||||
const isLargerThanTargetRes = scalingEnabled && Math.min(stream.height, stream.width) > targetRes;
|
||||
const isLargerThanTargetBitrate = stream.bitrate > this.parseBitrateToBps(ffmpegConfig.maxBitrate);
|
||||
const supportedPixelFormats: string[] = ["yuv420p", "yuvj420p", "yuva420p", "yuv420p10le"]
|
||||
const supportedPixelFormats: string[] = ['yuv420p', 'yuvj420p', 'yuva420p', 'yuv420p10le'];
|
||||
|
||||
const isTargetVideoCodec = ffmpegConfig.acceptedVideoCodecs.includes(stream.codecName as VideoCodec);
|
||||
const isTargetDynamicRange = !ffmpegConfig.transcodeHDR || !stream.isHDR;
|
||||
const isRequired = !isTargetVideoCodec || !isTargetDynamicRange || !supportedPixelFormats.includes(stream.pixelFormat);
|
||||
const isRequired =
|
||||
!isTargetVideoCodec || !isTargetDynamicRange || !supportedPixelFormats.includes(stream.pixelFormat);
|
||||
|
||||
switch (ffmpegConfig.transcode) {
|
||||
case TranscodePolicy.DISABLED: {
|
||||
|
|
|
@ -160,7 +160,7 @@ export class BaseConfig implements VideoCodecSWConfig {
|
|||
}
|
||||
|
||||
if (!this.config.transcodeHDR && videoStream.isHDR) {
|
||||
options.push(`format=yuv420p10le`)
|
||||
options.push(`format=yuv420p10le`);
|
||||
} else {
|
||||
options.push(...this.getToneMapping(videoStream));
|
||||
if (options.length === 0 && !videoStream.pixelFormat.endsWith('420p')) {
|
||||
|
|
Loading…
Reference in a new issue