autosize videos in canvas