-
as seen on Stack Overflow
- Search for 'Stack Overflow'
I have an NSTimer that runs at 60hz. With an OpenGL scene loaded and rendering, my game can get 60fps, solid, all day long.. Then if I go and recompile the app, or reload it, it will get 40fps. Same resources loaded. I've been running into this problem for years, and I just want to know why. It's…
>>> More
-
as seen on Game Development
- Search for 'Game Development'
I am working in Flash and a few things have been brought to my attention. Below is some code I have some questions on:
addEventListener(Event.ENTER_FRAME, function(e:Event):void
{
if (KEY_RIGHT)
{
// Move character right
}
// Etc.
});
stage.addEventListener(KeyboardEvent…
>>> More
-
as seen on Game Development
- Search for 'Game Development'
So I'm working on a puzzle game in flash. For all intents and purposes it's like Tetris. I spawn blocks, they move around the screen, then they get destroyed and disappear. I was having some trouble with the memory usage being too high over time so I read up on memory management and I think I have…
>>> More
-
as seen on Game Development
- Search for 'Game Development'
I've written a simple class to limit the framerate of my current project.
But it does not work as it should. Here is the code:
void FpsCounter::Process()
{
deltaTime = static_cast<double>(frameTimer.GetMsecs());
waitTime = 1000.0/fpsLimit - deltaTime;
frameTimer.Reset();
if(waitTime <=…
>>> More
-
as seen on Stack Overflow
- Search for 'Stack Overflow'
Short version: What's the best practice going forward for efficiently rendering large numbers of independent texture-mapped, lighted 2D/3D primitives (circles, rects, etc.) in OpenGL?
For example: a typical particle system using billboarded quads/triangles, point sprites, or whatever other technique…
>>> More