chore(streamer): drop cosmetic swscaler deprecated-format spam from logs
This commit is contained in:
parent
bdecc8c819
commit
67beae5f6f
1 changed files with 8 additions and 1 deletions
|
|
@ -71,7 +71,14 @@ async function main() {
|
|||
ice?.start();
|
||||
|
||||
const { videoIn, audioIn } = ffmpeg.start();
|
||||
ffmpeg.on("log", (m: string) => log("info", "ffmpeg", m.trim()));
|
||||
ffmpeg.on("log", (m: string) => {
|
||||
const msg = m.trim();
|
||||
// mjpeg decoder emits an unsuppressable swscaler "deprecated pixel format"
|
||||
// nag before any filters run; cosmetic, drop it from logs.
|
||||
if (msg.includes("deprecated pixel format used")) return;
|
||||
if (/^\[swscaler @ 0x[0-9a-f]+\]\s*$/.test(msg)) return;
|
||||
log("info", "ffmpeg", msg);
|
||||
});
|
||||
ffmpeg.on("exit", (code: number | null) => {
|
||||
log("error", "ffmpeg exited", { code });
|
||||
process.exit(1);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue