The quality, efficiency, and speed of running gameplay as a result of several factors in the design and structure of the game and its architecture.
1
vote
2answers
100 views
Input of mouseclick not always registered in XNA Update method
I have a problem that not all inputs of my mouse events seem to be registered.
The update logic is checking a 2 dimensional array of 10x10 .
It's logic for a jewel matching game.
So when i switch my ...
5
votes
1answer
175 views
Implementing algorithms via compute shaders vs. pipeline shaders
With the availability of compute shaders for both DirectX and OpenGL it's now possible to implement many algorithms without going through the rasterization pipeline and instead use general purpose ...
1
vote
0answers
44 views
Different ways to pass Textures into HLSL shaders
The GraphicsDevice class of xna 4 has the properties Textures and VertexTextures.
What is the exact difference? I don't really understand what MSDN tells me about this.
I usually use Effect ...
0
votes
1answer
41 views
Timing Calculations for Opengl ES 2.0 draw calls
I am drawing a cube in OpenGL ES 2.0 in Linux.
I am calculating the time taken for each frame using below function
#define NANO 1000000000
#define NANO_TO_MICRO(x) ((x)/1000)
uint64_t getTick()
{
...
8
votes
1answer
221 views
Fast lighting with multiple lights
How can I implement fast lighting with multiple lights?
I don't want to restrain the player, he can place an unlimited number and possibly overlapping (point) lights into the level.
The problem is ...
2
votes
1answer
131 views
Why is there high performance hit with many meshes?
I am currently reading upon Geometry Instancing, as I want to render a lot of animatable objects on the screen.
However I have come to a more fundamental question first: Why do I even need to use it?
...
0
votes
1answer
96 views
Directional light causes an FPS drop
I have only one object in the scene and it is lit with a directional light. It uses the mobile/diffuse shader. The issue is that on iPhone 4 the FPS drops from ~42FPS to ~11FPS when the directional ...
2
votes
1answer
99 views
Poor mobile performance when running from Eclipse
So after weeks of thinking my rendering code was bad, I accidentally discovered the following:
Running my game on a Nexus S
From Eclipse (Debug as -> Android application): 12fps
From the device
...
4
votes
1answer
80 views
Multiple render targets: Output target format performance questions
This is probably API independent (more dependent on hardware implementation), but just in case, I'm using OpenGL.
The question is restricted to PC hardware.
I have a couple of questions concerning ...
0
votes
0answers
62 views
Rendering tile maps for mobile devices
Hitting a bit of a roadblock with my game's development and I'm just looking for some outside advice.
I'm trying to render a tilemap for my mobile game (Android) and I'm using LibGDX.
Now, here's ...
3
votes
1answer
138 views
Controlling Constantly Running AIs
So, I'm not really sure where to start with this question. Feel free to tell me I'm stupid and Off Topic but I'd also like you to tell me why.
So, the maps in the game I am designing will consist of ...
3
votes
2answers
318 views
Small, High-Speed Object Collisions: Avoiding Tunneling
EDIT/UPDATE: My biggest question right now is whether step 3's "t=..." equation is a good idea or there a better way to do it. Most other issues have been partially or fully addressed, but no ...
-1
votes
1answer
78 views
Game Engine Design for the LWJGL [closed]
I'm about to begin on the engine for the game I am making. However, I am quite uncertain how I should design it. I have heard lots about threaded games, component and asynchronous systems. I'm ...
0
votes
4answers
181 views
HTML5 Jump and Run Game Performance issues
we're developing a HTML5/Javascript jump and run game and therefore we have developed our own gameframework.
It consists of following most important structures:
Stage/Scene/Layer: divs
...
-1
votes
1answer
49 views
Creating and drawing models efficiently
As I am learning the basics of game programming (in xna), I want to start creating simple 3d models and draw them (I'm already able to draw, control and animate them).
I want to create the following: ...
3
votes
1answer
166 views
Javascript tile map -> bitmap or JSON
I would like to know which idea is better in terms of performance.
The map is 5000x5000 tiles and I plan to expand it even more. It is split into 50x50 regions and camera doesn't move with player, ...
2
votes
1answer
159 views
Alpha Blending performance on IOS
I've got few questions without responses about my game development, can you help me? Here is the questions:
In my game when a large object appear on the screen, the GPU go to his limits, my ...
1
vote
3answers
206 views
Ways to make my game world bigger without slowing users CPU
I've been developing my first game for a little while now, but I've found that I want to make the game world MUCH bigger. It's currently about 300*300 tiles, but has creatures and bad guys running ...
2
votes
2answers
159 views
Confusion about systems implementation of ECS
For reference I am mostly imitating the architecture in this tutorial, the "Entity System" section: http://www.raywenderlich.com/24878/introduction-to-component-based-architecture-in-games
NOTE: the ...
1
vote
2answers
105 views
OpenGL ES - DrawCalls count - bottleneck?
I am newbie to OpenGL ES (so far, I used mainly DX11). Now for my scene, I have about 100 draw calls. I can use instancing, but only about half of objects can be instanced, so draw calls count would ...
-1
votes
1answer
93 views
OpenGL: How to map textures to geometry without using filter parameters
following my another question I have studied in the documentations that I should use this procedure :
Define the texture filter parameters. This will control what happens when a texture is scaled ...
1
vote
1answer
133 views
Batching and performances
I'm trying to understand batching and I'm not sure to understand how to do that, can I have more informations please? Here is what I found for the moment:
Batching informations
There is many types ...
4
votes
1answer
180 views
What is faster — full size with AA or reduced to screen size with no AA?
I wonder what is less expensive resource-wise:
Drawing a usual modern 3D game scene with some geometry at 100% scale, with some AA;
Drawing a downscaled scene (to fit the screen, but originally a ...
1
vote
1answer
67 views
Locating point on a closed path to maximize sum of distances to a sample of weighted points
I'm doing AI for a simple puzzled game and need to solve the following problem efficiently (less than 1 sec for the range specified since I need to do many iterations in a game).
A sample of N (1 ...
5
votes
2answers
382 views
How do collision meshes work in games like Zelda on the N64?
I was recently reading about the technology of Ocarina of Time/Majoras Mask and discovered that world collision is done using a single triangle mesh (vertices, normals, etc) for an entire area. There ...
-2
votes
1answer
131 views
Optimization Question about Singleton [closed]
I am using Unity with c#.
I have two objects and one needs to call a function from the other which is a Singleton. For this I have two solutions. But what's the best thing to do :
- Call for :
...
3
votes
2answers
125 views
Reducing overdraw cost: does triangle ordering matter?
I'm working on a project with procedural geometry, and will potentially have lots of opaque faces overlapping within the same model. Imagine an onion's layers. My understanding is it is better to draw ...
3
votes
2answers
275 views
How to implement an event system
Im trying to implement an Event System for a game, where there are classes that can fire or handle an event wheter or not they implement these interfaces:
public interface IGameEvent<T> where T ...
0
votes
3answers
49 views
Blender and the smoothing effect
I just started using blender again and I'd like to know if smoothing your model out adds a performance hit to your game?
By smoothing I mean when you hit ctrl+X (number from 1-9). The number of ...
2
votes
3answers
130 views
Is creating vertex/index buffer optimized this way?
I have some vertices in an array from which I create a vertex buffer. Let's say I have vertices:
v1, v2, v3, v4
I use indices:
0, 1, 2, 3
Is there any performance impact if I change the indices ...
1
vote
1answer
311 views
Voxel Performance
So Im trying to make a minecraft style voxel game to learn OpenGL, but Im running into performance issues. I found this thread :
http://stackoverflow.com/questions/4995652/3d-occlusion-culling
where ...
8
votes
3answers
472 views
Grouping entities of the same component template to linear containers
EDIT: Looks like people are actually doing this!
http://www.randygaul.net/2013/05/20/component-based-engine-design/
Another example of using this data accesing pattern.
I've done a lot of research ...
7
votes
3answers
838 views
Voxel Face Crawling (Mesh simplification, possibly using greedy)
Edit: This is just for my own learning experience, it is NOT for performance reasons that I ask this question.
This is in regards to a Minecraft-like terrain engine. I store blocks in chunks ...
1
vote
1answer
95 views
Determining explosion radius damage - Circle to Rectangle 2D
One of the Cocos2D games I am working on has circular explosion effects. These explosion effects need to deal a percentage of their set maximum damage to all game characters (represented by ...
3
votes
2answers
132 views
Spritesheet filesize gets huge after compiling
I have a 14x2 spritesheet which has 125 Kb in raw .png.
But as soon as I compile that to .xnb, it mutates to 4 MB.
So my question is: Why is that? And how can I fix that?
6
votes
1answer
164 views
Best way to determine surface normal for a group of pixels?
One of my current endeavors is creating a 2D destructible terrain engine for iOS Cocos2D (See https://github.com/crebstar/PWNDestructibleTerrain ). It is in an infant stages no doubt, but I have made ...
3
votes
2answers
199 views
What would be the most simple following target and neighbors avoidance algorithm in 2D space on plane?
I have ~20 or more enemies and they need to follow a target and avoid to go on top of themselves. I mean follow a target and avoid to collide with each other. Area, on which they are walking, is just ...
13
votes
4answers
1k views
Optimizing collision engine bottleneck
If this is your first time on this question, I suggest reading the pre-update part below first, then this part. Here's a synthesis of the problem, though:
Basically, I have a collision detection ...
0
votes
1answer
84 views
Displaying performance data per engine subsystem
Our game (Android based) traces how long it takes to do the world logic updates, and how long it takes to a render a frame to the device screen.
These traces are collected every frame, and displayed ...
1
vote
2answers
119 views
Throttling MonoGame actions (explosions, sounds, etc)
I'm trying to find a way to deal with throttling/managing actions that need to happen on a regular (regulated) basis.
Right now, if I want to throttle an "action" in MonoGame I need to setup a ...
1
vote
0answers
68 views
Persist or Recreate Ads?
I am developing an XNA game for windows phone 7 & 8.
The game is level based. After finishing each level a screen comes up with a bit of level stats summary. I wish to embed an ad in this screen ...
5
votes
4answers
642 views
Do associative array data structures have a place in game development?
Is it a bad idea to use a map data structure (an associative array or dictionary) in game development?
According to this flowchart, the ideal container for storing game object's container would ...
4
votes
1answer
150 views
Per frame: Many draw calls with fewer total vertices vs fewer draw calls with more total vertices?
Is there any chance draw calls like XNA's Graphics.DrawIndexedPrimitives has an extremely low overhead and performance issues are more than likely due to the complexity of the meshes?
If I had a ...
1
vote
2answers
163 views
Optimize DOM game performance
I am working on a game developed on DOM using Crafty JS framework, and Greensock GSAP JS (http://www.greensock.com/gsap-js/) for animations. It is my first time working with these technologies.
I am ...
3
votes
1answer
125 views
Using a switch command in one shader vs multiple shaders
If you have multiple shaders, could you instead of switching between shaders all the time just have one shader with a switch and each case will send you along to another shader function which you ...
2
votes
1answer
152 views
What is the interval of fragment-shader code execution?
Without any intended delay, is the code of a fragment-shader run once per frame? If not, how often will the code be executed? (I'm new to shaders: I'm talking about glsl if it makes any difference)
4
votes
1answer
182 views
Drawing different per-pixel data on the screen
I want to draw different per-pixel data on the screen, where each pixel has a specific value according to my needs. An example may be a random noise pattern where each pixel is randomly generated.
...
2
votes
2answers
140 views
How to load up many images without using too much memory
When writing games, I am aware that images take up a lot of space. If one has a large graphical game, they don't want problems with memory, or to give players the message "Go buy a better computer to ...
6
votes
1answer
219 views
How to find the bottleneck in a typical OpenGL game?
I am working on a little game engine. All major features are implemented yet, despite game logic which I assume not to be such a computational effort. The framerate is at least around 40 FPS, most of ...
1
vote
0answers
75 views
Non-smooth noise with optimal performance?
Any suggestions on how to get more 'jagged' results like linear interpolation gives with value noise using a faster algorithm concept like simplex noise?
Simplex noise I haven't spent enough time ...