how can I prevent something from zooming w/ camera

Blitz3D Forums/Blitz3D Programming/how can I prevent something from zooming w/ camera

Idiot(Posted 2005) [#1]
I'm playing around with a space simulation idea and I have a decent starfield skybox. The skybox is just a sphere with a texture inside it, that renders before everything else and has the camera in it. It moves with the camera so it appears to be a lot of stars really far away.

The problem is when I use camerazoom to zoom in on a planet, the stars get bigger too, which doesn't make a lot of sense. Is there a way to maintain the unzoomed skybox when zooming in on something?


Ross C(Posted 2005) [#2]
You could do two renders. First show the skysphere and hide everything else in the level, then take a render. Then using the cameraclsmode() command, set it so the z-buffer isn't cleared, hide the skysphere, show the level, then render again, and set the cameraclsmode back to normal. BUT, i think you'd be best to find a better way to move the camera into the planet.

Camera zoom looks weird when zooming in i think. Why don't you just move the camera closer to the planet?


Rottbott(Posted 2005) [#3]
Or change the size of the planet mesh.


Idiot(Posted 2005) [#4]
It works great, thanks! I had tried something like what you'd described but I was missing a couple points. I want it to appear that the camera is stationary when you zoom, as if you were looking through a telescope or something. Plus it was something I didn't know how to do, and it's good to learn and stuff.