Fix 'blocky' playback with mpeg2video. Add preset for libx264, might be unnecessary/wrong
This commit is contained in:
parent
a72967e575
commit
56a4f3fdd8
@ -495,9 +495,17 @@ class FFMPEG extends events.EventEmitter {
|
|||||||
if ( transcodeVideo && (this.audioOnly !== true) ) {
|
if ( transcodeVideo && (this.audioOnly !== true) ) {
|
||||||
// add the video encoder flags
|
// add the video encoder flags
|
||||||
ffmpegArgs.push(
|
ffmpegArgs.push(
|
||||||
|
'-crf', '22',
|
||||||
`-maxrate:v`, `${this.opts.videoBitrate}k`,
|
`-maxrate:v`, `${this.opts.videoBitrate}k`,
|
||||||
`-bufsize:v`, `${this.opts.videoBufSize}k`
|
`-bufsize:v`, `${this.opts.videoBufSize}k`
|
||||||
);
|
);
|
||||||
|
if (this.opts.videoEncoder.toLowerCase() === "mpeg2video") {
|
||||||
|
// This makes message "impossible bitrate constraints, this will fail" appear but nothing actually fails and it really looks like b:v is the only way to make the video look good when using mpeg2video
|
||||||
|
ffmpegArgs.push(
|
||||||
|
`-qscale:v`, `1`,
|
||||||
|
'-b:v', `${this.opts.videoBitrate}k`
|
||||||
|
);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if ( transcodeAudio ) {
|
if ( transcodeAudio ) {
|
||||||
// add the audio encoder flags
|
// add the audio encoder flags
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user