I'm using THREE.js to build a game.
Currently, I have an object at this position:
(-83645, 476450, 412912)
and I am trying to do click detection on this object.
However, when I use a raycaster as shown on the THREE.js example site, My rays are always skewed. If I skew all the coordinates down by a value of 100, the raycasting works perfectly.
I imagine this has something to do with either a division issue during normalization, or possibly an overflow error that is happening with some division somewhere.
For now, I'm shrinking the coordinates, however, in the long run, we'd like to have the coordinates stay the same.
Does anybody have any ideas why the large coordinates are skewing our rays? Thanks in advance!
EDIT: Here's a quick fiddle: http://jsfiddle.net/88ehm1yf/