Capítulo 240 de 988

Chapter 240: #t= Media Fragments

Core Idea

For <OffthreadVideo> and <Html5Video>, Remotion by default adds Media fragment hashes to video URLs. For <Video> and <Audio>, this does not apply.

Key Concepts

  • Behavior
  • Upsides
  • How to disable media fragment hints
  • When to disable media fragment hints
  • Recommendation

Code Examples

export const MyComp: React.FC = () => {
  const {fps} = useVideoConfig();

  return (
    <Sequence from={2 * fps} durationInFrames={4 * fps}>
      <OffthreadVideo src="https://example.com/bbb.mp4" />
    </Sequence>
  );
};
  • What it demonstrates: Usage pattern for #t= Media Fragments from the official docs.

Key Takeaways

  1. Understand behavior when working with #t= Media Fragments.
  2. Understand upsides when working with #t= Media Fragments.
  3. Understand how to disable media fragment hints when working with #t= Media Fragments.
  4. Understand when to disable media fragment hints when working with #t= Media Fragments.
  5. Understand recommendation when working with #t= Media Fragments.

Connects To

  • Animatedimage: related page in the Assets & Media section.
  • Delaying: related page in the Assets & Media section.
  • Exporting: related page in the Assets & Media section.