fix bug of camera capture