added fixes for video generation