improve method for playing video