mirror of
https://github.com/immich-app/immich.git
synced 2025-12-01 03:39:43 +09:00
feat(server): better transcoding logs (#13000)
* better transcoding logs * pr feedback
This commit is contained in:
@@ -6,6 +6,7 @@ export interface ILoggerRepository {
|
||||
setAppName(name: string): void;
|
||||
setContext(message: string): void;
|
||||
setLogLevel(level: LogLevel): void;
|
||||
isLevelEnabled(level: LogLevel): boolean;
|
||||
|
||||
verbose(message: any, ...args: any): void;
|
||||
debug(message: any, ...args: any): void;
|
||||
|
||||
@@ -62,6 +62,10 @@ export interface TranscodeCommand {
|
||||
inputOptions: string[];
|
||||
outputOptions: string[];
|
||||
twoPass: boolean;
|
||||
progress: {
|
||||
frameCount: number;
|
||||
percentInterval: number;
|
||||
};
|
||||
}
|
||||
|
||||
export interface BitrateDistribution {
|
||||
@@ -79,6 +83,10 @@ export interface VideoCodecHWConfig extends VideoCodecSWConfig {
|
||||
getSupportedCodecs(): Array<VideoCodec>;
|
||||
}
|
||||
|
||||
export interface ProbeOptions {
|
||||
countFrames: boolean;
|
||||
}
|
||||
|
||||
export interface IMediaRepository {
|
||||
// image
|
||||
extract(input: string, output: string): Promise<boolean>;
|
||||
@@ -87,6 +95,6 @@ export interface IMediaRepository {
|
||||
getImageDimensions(input: string): Promise<ImageDimensions>;
|
||||
|
||||
// video
|
||||
probe(input: string): Promise<VideoInfo>;
|
||||
probe(input: string, options?: ProbeOptions): Promise<VideoInfo>;
|
||||
transcode(input: string, output: string | Writable, command: TranscodeCommand): Promise<void>;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user