-
Notifications
You must be signed in to change notification settings - Fork 24
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to adjust camera distance? #26
Comments
Hi Luke, I hope you're going well! |
Thanks so much! That example is very helpful. I'm also working on a game jam game right now -- using W! Sadly I've run into so many roadblocks getting rotations to work correctly (especially a But as for this issue -- if I don't drop my project completely, I intend to expand the perspective, and then can consider how that might be parameterized for W. |
Cool, are you doing that game for GameDevJS 2024? |
Yeah, I'm doing GameDevJS 2024. I was getting confused by trying to get AI to help, but they often use algorithms which infer different ordering or rotations. The MDN docs also say that I made some changes to the W code in |
The near and far values (the min and max values for the camera's frustrum?) are hard-coded to 1 and 1000. It would be useful to be able to adjust these. (Currently I'm working on a prototype of a solar system, and I'd like to use larger numbers for coordinates.)
I think this would involve adjusting the projection? https://github.com/xem/W/blob/gh-pages/w.js#L150 But I don't understand the math here. @xem I think this could be controlled via parameters on the
camera
method without adding too many bytes.The text was updated successfully, but these errors were encountered: