Game worlds are viewed from a camera, which is the viewpoint from which the game world is observed from.

learn more… | top users | synonyms

4
votes
1answer
179 views

How do I ensure that perspective and orthographic projection matricies show objects at the same size on the screen?

I am working on a 3d scene editor and would like to show the scene in orthographic projection. My current problem is that I am not sure how to calculate the orthographic projection matrix such that ...
1
vote
1answer
136 views

LibGDX strange camera behaviour

I'm currently doing my final assessment for my study Game Development. I'm currently facing a real weird (maybe explainable) result from my camera. I just set up my scene with alot of tiles and a ...
-1
votes
2answers
108 views

Using Geometric Slerp to move Camera

I'm writing a program in C++ using OpenGL and GLM; I'm trying to get my camera to follow my car. So far it successfully follows it around the screen, but I'm having trouble adjusting the Camera's ...
1
vote
3answers
110 views

Applying scale to objects appears to have little effect when close up.

I just started out with D3D 11. My goal is to write a cube voxel engine (Minecraft style). Actually it's working pretty solid already, but when I finally tried to change the size of my cubes, I ran ...
1
vote
1answer
95 views

Camera movement and threshold not working

I have a platformer that is in progress, part of this has a camera which I only want to move when the character moves out of a certain threshold, to try to accomplish this I have the following if ...
2
votes
1answer
184 views

How to crop camera's viewport?

I'm making an Android game using LibGDX. I want to do something hard to explain but I'll try nonetheless. Look at this camera view (it's from 3ds max): I can get same exact view in LibGDX without ...
2
votes
1answer
144 views

Rotate Camera as an Object Manoeuvres

There are loads of questions (all of which I have looked at) on here about cameras following objects. Using them, I have successfully got my camera to follow my car when driving, but I am unable to ...
0
votes
1answer
107 views

How can I get my Android camera system working more like Google Earth's? [duplicate]

I'm implementing a touch screen interface whereby the user dragging their finger on the screen will rotate the camera in a sphere around the central point. My code works well for the horizontal swipe ...
0
votes
0answers
79 views

Coordinate system of android.graphics.Camera?

I asked this question before in StackOverflow.But I have not found any answer. I have to use Camera to draw some things in Canvas.But I can not detect that coordinate system of Camera is Right hand ...
0
votes
2answers
191 views

How to detect collision between a camera and a mesh?

I am wondering how you would be able to extract mesh properties (i.e. faces, vertices, and vertex normals) and use them to create a collidable object, one that a camera can't go through ? I am using ...
0
votes
1answer
192 views

How can I have my third-person camera track slightly ahead of the player as he or she moves?

I have a 3rd person camera controller in a top-down game. I have my cameran following the player and I currently use linear interpolation to make the movement smooth and a little laggy. But I would ...
0
votes
1answer
125 views

LWJGL: Camera distance from image plane?

Let me paste some code before I ask the question... public static void createWindow(int[] args) { try { Display.setFullscreen(false); DisplayMode d[] = ...
4
votes
2answers
513 views

Camera chasing player

I want the camera to follow the player and lag a little bit and then catch up with the player when the player halts. When stopped the player is in the center. At the moment im at the point where i ...
1
vote
1answer
130 views

Augmented reality on Mobile platform - iOS

Is there a way that we can control the iOS device camera to an extent what colors it sees, what shapes it sees ? etc I'm speaking about the ability to read information before the image is captured. ...
0
votes
1answer
169 views

How to stop camera from rotating in 2.5d platformer

I'm stuck with a problem: I can not make my camera stop rotating after character. What I already have tried: using empty game object with rigid body and locked rotation and make it parent of camera, ...
2
votes
1answer
209 views

Project collision shapes to plane for 2.5D collision detection

I am working on a top down 2.5D game. In the game anything that overlaps on the screen should be 'colliding' with each other regardless of whether they are on the same plane in the 3D world. This is ...
0
votes
1answer
447 views

Quaternion LookAt for camera

I am using the following code to rotate entities to look at points. glm::vec3 forwardVector = glm::normalize(point - position); float dot = glm::dot(glm::vec3(0.0f, 0.0f, 1.0f), forwardVector); ...
2
votes
0answers
431 views

Arcball 3D camera

I have checked multiple threads before posting, but i havent been able to figure this one out. Ok so i have been following this tutorial, but im not using glm, ive been implementing everything up ...
0
votes
3answers
195 views

OpenGL camera moves faster than player

I have a side scroller game made in OpenGL, and I'm trying to center the player in the viewport when he moves. I know how to do it: cameraX = Width / 2 / TileSize - playerPosX cameraY = Height / 2 / ...
1
vote
0answers
296 views

Cocos2d-x CCFollow Zooming issue

Hi I am currently building a cocos2d-x game which incorporates pinch zoom using CCLayerPanZoom class which can be found here The problem is basically when using CCFollow and zooming and out, it ...
5
votes
2answers
433 views

Rotating object around moving object/player in 2D

I am trying to implement a camera which rotates around the world around the player. I have found many solutions online to the task of rotating an object about the origin, or about an arbitrary point. ...
1
vote
1answer
352 views

How to automatically render all opaque meshes with a specific shader?

I have a specular outline shader that I want to be used on all opaque meshes of the scene whenever a specific camera renders. The shader is working properly when it is manually applied to some ...
2
votes
1answer
153 views

First Person Camera strafing at angle

I have a simple camera class working in directx 11 allowing moving forward and rotating left and right. I'm trying to implement strafing into it but having some problems. The strafing works when ...
1
vote
1answer
76 views

Drawing chunks, and positioning the camera

I've seen many questions and answers regarding how to draw tiled maps but I can't really get my head around it. Many answers suggest either loading the visible part of the map, or loading and ...
1
vote
1answer
103 views

Automatically zoom out the camera to show all players

I am building a game in XNA that takes place in a rectangular arena. The game is multiplayer and each player may go where they like within the arena. The camera is a perspective camera that looks ...
0
votes
1answer
134 views

Obtain rectangle indicating 2D world space camera can see

I have a 2D tile based game in XNA, with a moveable camera that can scroll around and zoom. I'm trying to obtain a rectangle which indicates the area, in world space, that my camera is looking at, so ...
0
votes
1answer
148 views

How to code camera for layered map in unity

For a current unity project I need a layered map like in Dwarf Fortress. The game will take place in a 3D city enviroment and the camera should be 'snapped' to layers. So there will be (for example) a ...
1
vote
3answers
108 views

Can I use a translate function to implement a viewport?

I read this great question and its accompanying great answer about rendering a viewport in a top down 2D game: As for actually drawing the objects the camera can "see", you now draw all objects ...
2
votes
4answers
189 views

How do I rotate a camera around the Y axis of the object it's looking at? [duplicate]

I'm making a camera that can currently rotate freely from the back to the front of a target object by giving it an angle and a distance. I do the above with the following code directionVector = ...
0
votes
0answers
52 views

camera panning problems with “modelviewer” camera

I have a camera that rotates around a center point using a rotation matrix and radius for the zoom from the object. I need to add right mouse button panning in. Here is the problem: when I change ...
0
votes
1answer
348 views

Simulate camera movement in two dimensions (OpenGL)

I've been told by the folks over at Stack Overflow that there's no way to move the camera in OpenGL. I'm developing a 2D RPG with LWJGL and need to know the proper way to simulate camera movement as ...
0
votes
1answer
142 views

Adding Functionality to a basic Java 2D Camera

Creating a little LoZ inspired game in Java here just to get into the feeling of things (learning CS at my school but the only teacher who's willing to help is travelling for 6-months, so I'm teaching ...
0
votes
0answers
112 views

Why my camera sees what is behind it?

I am building a minimal opengl viewer and I am puzzled by what I see : the camera see the (test) object that is behind her. the front and back of the camera looks reverted. I am wondering what could ...
0
votes
1answer
143 views

OpenGL camera translate and rotate on cameras local axis

How can I make rotation and translation on a local camera axis in OpenGL? I want to make camera like "aeroplane" camera with a pitch yaw and roll. I want to have good explanation on everything! Can ...
0
votes
1answer
157 views

XNA Zoom in/out on model instead of scaling the model

I'm trying to implement zoom in/out functionality into my game. I can change the cameraDistance value with the Z and X keys. Instead of zooming, it looks like the model is scaled smaller or larger ...
0
votes
1answer
223 views

XNA Arcball and moving model - the model is altered instead of the camera

I'm trying to implement an arcball type camera, I've got all controls working very nicely. I can rotate the X/Y axis with my mouse and zoom in and out with the Z/X keys. The problem is, that the ...
0
votes
1answer
303 views

switching from third person view to first person view

I have done a scene in opengl where I'm using a third person camera (that I can control with the mouse). Then, inside it, it has the camera of the first view (that I called thirdpersonCamera, see the ...
2
votes
2answers
183 views

Player jitter when positioned at large coordinate values

I am trying to make a simple top down scrolling shooter using Unity3D comprising of the following elements: 1) Top down orthographic camera: points at 65 degrees towards the ground. At a height of ...
2
votes
1answer
423 views

How to smoothly change the target of smooth follow without camera glitch?

I am trying to change the target of the smooth follow at runtime, but there is a glitch in the camera since the targets are different sizes. I tried using lerp and smooth damp both gave the same ...
1
vote
1answer
119 views

Cartesian Coordinates & Layout [duplicate]

The way cartesian coordinations are presented and used is kinda confusing. When working with 2D the vertical axis is Y, though when working with 3D the vertical axis is Z and Y becomes the "depth" ...
0
votes
1answer
77 views

How to rotate the camera to point to a specified location?

I have a quaternion based camera class (which controls a view matrix) and would like a function to rotate the camera to face a specified point. The best approach I can come up with is that I rotate ...
0
votes
1answer
124 views

Orbiting a camera around the Y axis whilst remaining up

I've been having difficulty with a problem which I thought was going to be a simple solution. I have a camera facing downwards on a character. The can camera be lowered and when it's lowered it ...
1
vote
2answers
293 views

Rotate around the centre of the screen

I want my camera to rotate around the centre of screen and I'm not sure how to achieve that. I have a rotation in the camera but I'm not sure what its rotating around. (I think it might be rotating ...
1
vote
0answers
84 views

Determining axis to rotate around

I'm trying to implement a free-look third person camera (using glm). I know that the general transformation is newCameraPosition = translate(lookatPoint) * rotation(angle,axis) * ...
0
votes
1answer
160 views

First person shooter camera movement

I am making an FPS in XNA. I cannot seem to make a FPS camera that I can move Forward, Back, Side to Side using the keyboard. How do I do that?
0
votes
2answers
393 views

First person camera: problem

I have created a simple camera class, moved it from my C# (XNA) source to C++ for d3d. Commonly it is okay, but something is wrong with rotation. If i increase its pitch/yaw values, according to ...
1
vote
1answer
287 views

Understanding the z-axis vector from OpenGL modelview matrix

I would like to shoot spheres in the current view direction in a simple scene. I use an FPS camera, so no z-rotation. The vector pointing in the correct direction should be (m[8], m[9], m[10]) where m ...
2
votes
2answers
193 views

Field of view settings for first person shooter

Are there any industry standards for setting the field of view (FOV) for FPS games or is it solely based on trial and error? Are there any guidelines for choosing the correct value?
3
votes
1answer
479 views

Second camera record and export to video file (Unity)

I'm making horror quest game for PC on Unity. I'm trying my best to make it kind of unique and trying not to use standard methods like screamers etc. What i want to do badly is camera recording ...
-1
votes
1answer
171 views

Pinhole matrix problem

I made a program to represent a 3D world. I use the projection matrix we can find on wikipedia. For viewing a scene it's very nice but when I straff in the scene, everything behind the camera go on ...