updated for creating avi