🎥 Make videos programmatically with React
Update frame-accuracy.test.ts
Jonny Burger20f5c6488b39
diff --git a/packages/it-tests/src/rendering/frame-accuracy.test.ts b/packages/it-tests/src/rendering/frame-accuracy.test.tsindex c007b2cfb1..0c64b9e4ea 100644--- a/packages/it-tests/src/rendering/frame-accuracy.test.ts+++ b/packages/it-tests/src/rendering/frame-accuracy.test.ts@@ -30,15 +30,11 @@ const getMissedFramesforCodec = async (`video-testing-${codec}${offthread ? "-offthread" : ""}`,outputPath,"--image-format",- "jpeg",- "--jpeg-quality",- "100",+ "png","--sequence",- "--log=verbose",],{cwd: path.join(process.cwd(), "..", "example"),- stdio: "inherit",});@@ -55,7 +51,7 @@ const getMissedFramesforCodec = async (// extract the actual RGB color value of the top left pixel in the frame image that was generated by remotionconst paddedIndex = String(frame).padStart(2, "0");- const filename = path.join(outputPath, `element-${paddedIndex}.jpeg`);+ const filename = path.join(outputPath, `element-${paddedIndex}.png`);const img = await sharp(filename).raw().toBuffer();const actualColor = {@@ -77,7 +73,7 @@ const getMissedFramesforCodec = async (colorDistance.blue,colorDistance.green);- const threshold = 40;+ const threshold = 30;if (highestDistance > threshold) {console.log(colorDistance, { threshold, frame, filename });missedFrames++;