use generator for video files