couple of changes to generate ray in camera