import {AbsoluteFill} from 'remotion';
import React, {useMemo} from 'react';
import {
staticFile,
useVideoConfig,
Img,
Easing,
useCurrentFrame,
interpolate,
} from 'remotion';
import imageSequences from './Assets/ImageSequences.json';
import {TransitionSeries} from '@remotion/transitions';
const ImageStream = React.memo(() => {
const {fps} = useVideoConfig();
const imageComponents = useMemo(() => {
return imageSequences.map((entry, index) => (
));
}, [fps]);
return (
{imageComponents}
);
});
const Images = React.memo(({entry}) => {
const frame = useCurrentFrame();
const {fps} = useVideoConfig();
const duration = useMemo(() => fps * 2.5, [fps]);
const ImgScale = useMemo(
() =>
interpolate(frame, [0, duration], [1, 1.2], {
easing: Easing.bezier(0.65, 0, 0.35, 1),
extrapolateRight: 'clamp',
extrapolateLeft: 'clamp',
}),
[frame, duration]
);
return (
);
});
export default ImageStream;