INNER CODE UNIT · TypeScript

clip

mifi/editly · src/index.ts:511

  const clip = clips.find((c) => {
    if (clipStartTime <= time && clipStartTime + c.duration > time) return true;
    clipStartTime += c.duration;
    return false;
  });
  assert(clip, "No clip found at requested time");
  const clipIndex = clips.indexOf(clip);
  const frameSource = await createFrameSource({
    clip,
    clipIndex,
    width,
    height,
    channels,
    verbose,
    logTimes,
    framerateStr: "1",
  });
  const rgba = await frameSource.readNextFrame({ time: time - clipStartTime });

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…