C++ is a statically typed, free-form, multi-paradigm, compiled, general-purpose programming language.

learn more… | top users | synonyms

10
votes
0answers
218 views

My game seems to be incompatible with recording software. What could be causing this?

I've just finished a little Game-Dev project for university and I need to record a video to accompany my submission (just in case they can't get my source to work). Basically my game doesn't work at ...
6
votes
0answers
63 views

Which is the best LOD method for planet rendering?

I'm currently working on my thesis, it is an engine to render terrains of planetary size. I'm still finishing my research and I have encountered a lot of stuff about this subject, the problem is that ...
4
votes
0answers
226 views

How to generate portal zones?

I'm developing a portal-based scene manager. Basically all it does is to check the portals against the camera frustum, and render their associated portal zones accordingly. Is there any way my editor ...
3
votes
0answers
64 views

Custom sampling points for anti-aliasing

I'm trying to write an anti-aliasing shader in HLSL, but I can't find any way to rasterize at a custom point. (in between pixels on the screen, but not orderly like supersampling) Is there any way to ...
3
votes
0answers
379 views

Deep Cloning C++ class that inherits CCNode in Cocos2dx

I'm stuck with something in Cocos2dx ... When i copy my class that inherits CCNode, i get a shallow copy of my class but the base type seem to still point to the original node address. We dont seem ...
2
votes
0answers
89 views

Decomposing a concave mesh into a set of convex meshes

I'd like to be able to decompose a concave mesh into a set of convex meshes for 2 reasons: Transparent rendering Physics shapes Is there an algorithm that takes a set of triangles (concave) as ...
2
votes
0answers
61 views

sdl: unlock mouse in fullscreen mode and make it useable on another monitor

Is it possible to unlock the mouse in fullscreen mode so that you can use it on a another monitor? I read trough the SDL documentation, but I couldn't find anything related to my problem.
2
votes
0answers
61 views

Fragments never falling into spot light's cone

I am using GLSL version 1.20 with OpenGL 2.1 . I am trying to compute when a fragment falls into the area of a spot light. I have already set all the light values with glLightfv and glLightf, also ...
2
votes
0answers
230 views

Where is the Shader Designer?

I have VS2012 Ultimate and I've been trying to access (find) the Shader Designer. I searched through MSDN's text and Channel9's videos, but they keep failing to mention how to access it... Can ...
2
votes
0answers
142 views

Flickering problem with world matrix

I do have a pretty wierd problem today. As soon as I try to change my translation- or rotationmatrix for an object to something else than (0,0,0), the object starts to flicker (scaling works fine). It ...
2
votes
0answers
221 views

Suitable in memory storage library to store components for entity systems

I am studying entity indexed components and came up with a naive C++ implementation which just iterates over all entity "hash tables" and applies update/delete/insert functions in place. I'm having ...
1
vote
0answers
34 views

Separating rendering and logic thread in GLFW?

I want to separate my rendering thread (the main thread) and my logic thread in my GLFW game. I'm new to the concept of threading inside games. How would this be done? GLFW isn't thread safe so it ...
1
vote
0answers
40 views

OpenSceneGraph, multiple instances of a model

Im working on my first project using OpenSceneGraph. The project is a model flight simulator for one of my university courses, I want to be able to load airplanes (consisting of multiple models) and ...
1
vote
0answers
33 views

Why is my XInput gamepad press stamp not working?

I'm trying to add basic gamepad input to my c++ DirectX game but i'm having some trouble creating a press stamp (registers the press only the first time it's pressed if button held down). The entire ...
1
vote
0answers
26 views

Bullet btGeneric6DofConstraint and btGeneric6DofSpringConstraint constructor arguments

I have a very simple (and maybe too primitive to post here but I’ll try anyway :P) question about Bullet constraints. What are arguments const btTransform &frameInA, const btTransform ...
1
vote
0answers
123 views

Game editor architecture

I'm looking in to developing a game editor - essentially a level editor for my game but a little more advanced i.e edit menus and loading screens and what not. So far, I have come up with a ...
1
vote
0answers
56 views

IwGame (Marmalade): Does CIwGameSprite support SVG? How?

I have a small question about Marmalade IwGame engine. Does the CIwGameSprite support SVG (I've read that yes it does) If it does support SVG, how does it handle it, Does it convert that Vector ...
1
vote
0answers
92 views

Sketchy results from ray-plane intersection code

I've set up a demo with simple first-person controls using C++ and OpenGL, and it seems to work reasonably well. My goal is this: when the player looks at a plane and clicks the left mouse button, ...
1
vote
0answers
52 views

Access violation when playing mp3 using DirectShow

I have reopened one older project that uses DirectShow for audio playback. Before, I would compile and run it on Windows 7 using MVStudio 2010 without trouble, now I have Windows 8 and MVStudio 2012 ...
1
vote
0answers
303 views

2D water shader in SFML

I want to implement the algorithm for a 2D water surface described here and here. Before somebody finds out, beats me up and deletes this, I'm gonna say it myself. I posted this question over at ...
1
vote
0answers
119 views

Help with Windows RawInput

I am having some trouble to receive and interpret mouse movement data from RawInput. Generally mouse input seems to work, I can query mouse buttons and receive updates of mouse movement. The problem ...
1
vote
0answers
69 views

OpenWorld SceneGraph management and optimization

I have a SceneGraph class which for now is just a simple list implementation, and the only optimization I've planned so far is a check is something like this: //GetDistance returns the distance ...
1
vote
0answers
80 views

What is the right way to use a QStateMachine for a text adventure game?

I have seen a couple topics about this already but they were a bit vague for me so I decided to make this. I'm working on a little adventure game just for fun in Qt, its basically just text on the ...
1
vote
0answers
147 views

Access Violation when trying to bind Vertex Object Array

I've just started digging into OpenGL and I've run into a problem trying to set a VOA. It's giving me a run-time error of : An unhandled exception of type 'System.AccessViolationException' At ...
1
vote
0answers
76 views

Command Pattern refactor for input processing?

According to Game Coding Complete 4th. ed. processing input via the following is considered unmanagable and inflexible. But does not show an example. I've used the Command pattern to represent GUI ...
1
vote
0answers
153 views

Obtaining a HBITMAP/HICON from D2D Bitmap

Is there any way to obtain a HBITMAP or HICON from a ID2D1Bitmap* using Direct2D? I am using the following function to load a bitmap: ...
1
vote
0answers
246 views

How to pick a 3D object with known mouse coordinates if the camera is rotated 60 degrees?

I am making a simple game engine for a simple RTS game and would like to be able to pick a cube and move it around with the mouse coordinates. The problem is that my camera is rotated 60 degrees just ...
1
vote
0answers
46 views

Audio Panning using RtAudio

I use Rtaudio library. I would like to implement an audio program where I can control the panning (e.g. shifting the sound from the left channel to the right channel). In my specific case, I use a ...
1
vote
0answers
171 views

DX9 Deferred Rendering, GBuffer displays as clear color only

I'm trying to implement Catalin Zima's Deferred Renderer in a very lightweight c++ DirectX 9 app (only renders a skydome and a model), at this moment I'm trying to render the gbuffer, but I'm having a ...
1
vote
0answers
64 views

failbit is being set and I can't figure out why

I'm writing a MIDI file loader. Everything is going fine until at some track I get a failbit exception while trying to read from file. I can't figure out why, I've checked the file size and it's ok ...
1
vote
0answers
94 views

UDK and Protocol Buffers

Actually two questions: Can I use TCP sockets in UDK to implement my own networking protocol? (I guess TCPLink is an answer) Is there any way I can user Protocol Buffers inside UDK? Or anything like ...
1
vote
0answers
198 views

Full screen shader causes performance hit

I basically want to have a shader run that can do something like toon shading, or grayscale the whole screen, or radial lighting. To do this, I create a new bitmap each time the display resizes that ...
1
vote
0answers
289 views

Looking for a small, light scene graph style abstraction lib for shader based OpenGL

I'm looking for a 'lean and mean' c/c++ scene graph library for OpenGL that doesn't use any deprecated functionality. It should be cross platform (strictly speaking I just dev on Linux so no love lost ...
1
vote
0answers
90 views

How do I get my polygons to be lighted by either side?

Okay, I am using Ogre3D and Gorilla(2D library for ogre3D) and I am making Gorilla::Screenrenderables in the open scene. The problem that I am having is that when I make a light and have my ...
1
vote
0answers
164 views

Smooth Camera Offsets

I am attempting to implement a sort of, smooth camera that has angle offsets from the player as they turn, creating a cinematic effect as well as visual feedback for when the player turns. Here is an ...
1
vote
0answers
251 views

Algorithm for potential fields

Rather than computing potential fields in a grid and performing a lookup for them, I've decided to query the potential fields at a given point in 3D space by simply querying all the objects in a ...
1
vote
0answers
132 views

How do I get the point coords of a rotated SFML shaperect?

I am trying to get collisions of bullets working, and am using SFML. I am using code to get the position of the points of the rectangle for collisions, however I think there's a way to do this without ...
1
vote
0answers
319 views

Countdown Timer for Racing Game

I want to make a countdown timer for my racing game such as "3... 2... 1... GO!" I'm using GLUT, OpenGL, and C++. I was wondering what the most appropriate method to handle this in C++. clock()? ...
1
vote
0answers
171 views

Debugging Minimum Translation Vector

I implemented the minimum translation vector from codezealot's tutorial on SAT (Separating Axis Theorem) but I'm having an issue I can't quite figure out. Here's the example I have: As you can see ...
1
vote
0answers
313 views

Using BulletML in C++

Are there any examples of using BulletML (via the libbullml library), in C++. I'm not sure where to start. For example I know I must extend BulletMLRunner, however there is no such Bullet class which ...
1
vote
0answers
328 views

Joint constraints in PhysX

I'm trying to use PhysX for my physics engine. I'd like to use spherical joints, but I'm having trouble with the constraints. All of the examples that I've found refer to SDK v2.8. I'd like to ...
1
vote
0answers
239 views

GetRasterStatus usage in direct3d

I am interested if anyone has had used GetrasterStatus in direct3d application to control application vsync behaviour in high precision timing? What set of techniques are to be implemented to do the ...
0
votes
0answers
18 views

Default material properties and assimp

I am using assimp to import 3d models and I have a question on the default properties on materials, more specifically on the diffuse, ambient and specular material colors. In assimp, if the model ...
0
votes
0answers
16 views

Design issue: World class only contains Rigidbodies but custom objects need further updating

BACKGROUND: My World class that is responsible for updating the physics for each object in the game contains a std::vector of Rigidbody classes. As Rigidbodies are added to the world, they are also ...
0
votes
0answers
21 views

Size of an image imported with FreeImage

I'm having abit of a brainfart and I can't quite grasp what I'm doing wrong. It's quite simple, I am importing an image with FreeImage (http://freeimage.sourceforge.net/) which has a method ...
0
votes
0answers
78 views

The algorithm for removing a group of adjacent balls of arbitrary shape

I'm writing a game that something like Diamond Dash and/or lines, you can delete on the horizontal / vertical and diagonal directions. Which algorithm is best suited for removing a group of balls ...
0
votes
0answers
160 views

Optimal OpenGL 2D Sprite Batching (Best Practice)

I am working on simple 2D engine using OpenGL (3.3+) for rendering and was wondering what the optimal method of sprite batching would be. I plan to put all sprites into one (or fewer) texture atlases. ...
0
votes
0answers
40 views

DirectX9 toggling display problem

How can I reset a render target? I am trying to toggle between fullscreen mode and windowed mode but without success. I've tried all the possible combinations in the code below. I am rendering to a ...
0
votes
0answers
245 views

How to do collision detection in 3D using bounding boxes?

I am using c++ in visual studio 2010 with opengl. I am trying to make a programme that has 2 boxes that are able to be stacked on top of each other but I am having some trouble with the collision ...
0
votes
0answers
227 views

Loading and displaying a BMP file C++/Opengl

When I run the following code, it just shows a plain color, like Pink or Orange. The picture which I'm trying to load is a 24-bit BMP which should work 100%. (Size 256x256) BmpLoader.h #ifndef ...

1 2