Skip to content

Commit

Permalink
fix wrong timeline display
Browse files Browse the repository at this point in the history
  • Loading branch information
JonnyBurger committed May 27, 2022
1 parent d9ddded commit 479673b
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export const TimelineSequence: React.FC<{
// If a duration is 1, it is essentially a still and it should have width 0
// Some compositions may not be longer than their media duration,
// if that is the case, it needs to be asynchronously determined
const [maxMediaDuration, setMaxMediaDuration] = useState(Infinity);
const [maxMediaDuration, setMaxMediaDuration] = useState(() => s.duration);

const video = Internals.useVideo();

Expand Down Expand Up @@ -97,7 +97,7 @@ export const TimelineSequence: React.FC<{
doesVolumeChange={s.doesVolumeChange}
visualizationWidth={width}
startFrom={s.startMediaFrom}
durationInFrames={s.duration}
durationInFrames={maxMediaDuration}
fps={fps}
volume={s.volume}
setMaxMediaDuration={setMaxMediaDuration}
Expand Down

0 comments on commit 479673b

Please sign in to comment.