Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7670021
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T15:43:38+00:00 2026-05-31T15:43:38+00:00

So I’m making a game in C++. And I’m at a fork in the

  • 0

So I’m making a game in C++. And I’m at a fork in the road.

I am now planning how I am going to handle animation and optimize rendering. I’m rendering using immediate mode which I was told was very slow. I go looking for alternatives and then there’s a bunch of different ways, and it differs depending on how you handle the animations, so I thought I’d just ask what would be a good optimal way to do both.

For animations, I thought about using sequences of images stored in memory, but only testing with a 50 image sequence, memory jumped to like 200 mb, when it was 30 before. (There’s no leak, it stays at 200, but if I have large levels, it looks like I’ll be running out of memory). Would sprite sheets help in this case?

I was told the reason atlases or sprite sheets were used was because binding different textures was an expensive operation, so the only way this would work is by putting in all the texture I will use for level 1 for example in one huge texture so I’m only binding once. Is this possible dynamically?

Would using one gigantic PNG be better memory-wise than loading 50 PNG’s?

Any help with either optimizing rendering or some information about the drawbacks of these animation techniques would be really appreciated!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T15:43:40+00:00Added an answer on May 31, 2026 at 3:43 pm

    I was told was very slow

    I recommend to ignore this. Unless you’re going to use insane number of sprites (tens of thousands), your bottleneck will be reading data from textures, which is limited by videocard’s memory transfer rate. In other words, if you have 1280×1024 viewport and you draw 1280×1024 texture that covers entire viewport (and every texel maps to screen pixel), your FPS will drop and VBOs won’t help. Also immediate mode is easier to use for 2D than VBOs. So keep using immediate mode until you decide to use HUGE number of sprites.

    I thought about using sequences of images stored in memory

    You need to cram as many sprites as you can into single texture. Switching textures will produce big slowdown, so the best idea would be to use huge texture (4096×4096 or larger – 16384×16384 would be nice) and load all sprites you can into it. This can be done using glSubTexImage2D. Storing every frame separate texture will produce huge slowdown. Please note that you don’t have to store sprites on disk merged into single texture. You can glue them together while loading.

    Would using one gigantic PNG be better memory-wise than loading 50 PNG’s?

    PNG image file format that is stored on disk. It has nothing to do with OpenGL. Once you load the texture it is no longer a “png” – it is fully decompressed. So how you store image data on disk is pretty much irrelevant. It will affect image loading speed but texture performance/memory usage has nothing to do with image storage format. If you’re running out of memory then you’ll have to do something about it – implement game asset streaming, or adjust level’s sprite/texture “budget”.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am using Paperclip to handle profile photo uploads in my app. They upload
I'm making a simple page using Google Maps API 3. My first. One marker
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
I have a jquery bug and I've been looking for hours now, I can't
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
this is what i have right now Drawing an RSS feed into the php,
I am reading a book about Javascript and jQuery and using one of the
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and
We're building an app, our first using Rails 3, and we're having to build

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.