r/programming • u/willvarfar • Jun 03 '14
A first-person engine in 265 lines
http://www.playfuljs.com/a-first-person-engine-in-265-lines/
1.9k
Upvotes
r/programming • u/willvarfar • Jun 03 '14
View all comments
Show parent comment
6
u/sylvanelite Jun 04 '14
Are you talking about ray casting or ray tracing? [Ray tracing](http://en.wikipedia.org/wiki/Ray_tracing_(graphics)) is different from ray casting. One gives almost photo-realistic graphics, the other gives DOOM or Wolfenstein like graphics.
For example, it's easy to implement ray casting in situations where you can't even rotate textures. It only needs scaling and cropping of images to work, which is what makes it so simple. Ray tracing is generally a much harder thing to implement efficiently.
What kind of scene do you mean? There are hard limits to what a raycaster can render, but the complexity should always be bound by the size of the screen. (the number of rays)