mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-09-07 10:06:21 +00:00
fix(producer,engine): gate drawelement on ancestor background-image + tail verify sample
This commit is contained in:
@@ -3107,6 +3107,19 @@ export async function getCompositionDuration(session: CaptureSession): Promise<n
|
||||
* init-time screenshot → the render falls back to the screenshot path (slower,
|
||||
* never wrong). Cost when passing: ~K×(seek+screenshot) ≈ 150–300ms at init.
|
||||
*/
|
||||
/**
|
||||
* Timeline fractions the self-verify samples. First k-1 evenly spaced, last
|
||||
* pinned at 95%: late-onset damage (an end-of-comp reveal exposing pixels DE
|
||||
* paints wrong) was invisible to the old (i+1)/(k+1) grid, whose final sample
|
||||
* sat at 80% — measured miss: a body-gradient drop starting at ~79% of the
|
||||
* timeline passed verification while the drained output bottomed at 30.9 dB.
|
||||
*/
|
||||
export function computeDeVerifySampleFractions(k: number): number[] {
|
||||
if (k <= 0) return [];
|
||||
if (k === 1) return [0.95];
|
||||
return [...Array.from({ length: k - 1 }, (_, i) => (i + 1) / k), 0.95];
|
||||
}
|
||||
|
||||
async function captureDeVerificationFrames(
|
||||
session: CaptureSession,
|
||||
page: Page,
|
||||
@@ -3153,7 +3166,7 @@ async function captureDeVerificationFrames(
|
||||
// render (the detectCssEffectRisk lesson), and because DE frames and truth
|
||||
// would share the corruption, PSNR would pass on the damaged output.
|
||||
// Seeking 0 → ascending reproduces the render's own seek order.
|
||||
const fractions = Array.from({ length: k }, (_, i) => (i + 1) / (k + 1));
|
||||
const fractions = computeDeVerifySampleFractions(k);
|
||||
const seekTo = async (t: number): Promise<void> => {
|
||||
await page.evaluate((tt: number) => {
|
||||
const hf = (
|
||||
|
||||
Reference in New Issue
Block a user