Advertisement Jump to content
  • Advertisement
Sign in to follow this  
  • entries
  • comments
  • views

Camera Obscura

Sign in to follow this  


Camera Obscura

Spent the last couple of days on the camera & controls. Tonight I added several more text-tweakable camera options, such as the camera's distance behind the player, the min & max camera height, etc. I also made the camera position averaging time-proportional so it would feel the same at different fps.

Yesterday I added the option to make the camera always able to see the player. It checks for occlusions with a series of raycasts, then if it finds an occluder, it attempts to rise up until its clear. We may experiment more with this, but right now it seems as if this height adjustment is more distracting
than the character being obscured by something. It's not like you don't know where your character is - he's always near the middle of the screen. Plus, the player can always zoom out, which is much more unlikely to occlude the character. It seems this is best left to the player to deal with, but perhaps we'll revisit this option in the future.

Right now the mouse left/right turns both the character and the camera CCW/CW. One of the new tweaks we tried tonight was making the mouse up/down changing the camera pitch, well, actually not the pitch, but moving the camera look at point towards and away from the character. We don't ever want the view to go parallel to the ground - that becomes a first-person view, and can create board design problems, especially when we don't model ceilings, and don't want the player to see across the entire level.

I added min & max target distance parameters to the render options to play with various pitch options, and it seemed the more tweakable the camera up/down was, the more control you wanted over it. I'm currently thinking that we will just choose a good view point for close-up, and the players will get used to what it can and can't do pretty easily.

Right now it looks like 4 meters in front of the characer lets you see down a hallway a good distance without letting you look through the whole level at once.

Here are three shots, one zoomed out, the other zoomed in, and another with the camera target point set quite far away. I have to say I think the 3rd shot looks the most appealing, other than the black area in the 'sky'. I'm somewhat worried about performance on a larger indoor level, but I suppose we could fog out the world lighting in the distance or some other technique to keep perf up. Perhaps simply dimming lights that are far from the player, and then culling those that are effectively black would work well.

I'd appreciate hearing your thoughts on the 2nd vs the 3rd pic?

I'm preparing to go out of town this week, so I probably won't update again until Wednesday, but I'll probably be on-line a bit here and there.
Sign in to follow this  


Recommended Comments

I suggested to you in your previous entry to see WoW, and now I suggest you that again :)
They set the orientation of character to the mouse+Right button, both for rotation and lookin up&down.
Then they set the camera movement (wothout changing character orientation) to the mouse + Left button - again, 2 angles of freedom - that way you can move, and see around you without changing the movement direction (and then you release the Left button, the camera slides back, along the movement).
The 3rd view is the one I use most when playing WoW... :)

Share this comment

Link to comment
I'd suggest using the second view, possibly with an option to allow the player to look around using the mouse, but always going back to the "default" state of the second view afterwards.

Share this comment

Link to comment
I prefer the second over the third, but as the other have said, allowing customizability is never a sin. :)

(Except that one time..)

Share this comment

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using, you agree to our community Guidelines, Terms of Use, and Privacy Policy. is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!