Howdy!
So basically I’m a crazy person who wants to make a 2d game with just base opengl and C, I have a not terrible understanding of everything up to making a draw call on a single object I guess. I’m at the point where I can draw whatever, but it’d be with single draw calls and swapping entire textures and binding everything every time I call draw, and obviously that’s not gonna work for long so I just want to skip past it into making a long term solution. I’m manually loading opengl functions and pulling supported stuff from the graphics card, have my program set up to draw in SRGB if it’s supported, have basic transparency and depth testing, with basic matrices, transformations and understanding of what I’m doing up to this point. So I guess the list of things I’m looking to do and having trouble finding a good resource for; in order of least to most important:
Automatically pack textures into an atlas
Automatically getting the texture coords for an individual part of that atlas / automatically converting literal pixel coordinates to 0-1 texture coords
Having a way to tell my program what part of the atlas to draw on each triangle
Actually efficiently swap between the textures w/o re-binding them
Actually drawing things with a single draw call
and having a way to do all that in an efficient way; such as -> Draw(sprite, spriteLocation, spriteOrigin, spriteSize, (etc));
in as few actual draw calls as possible
So I guess I’m looking to be pointed in the right direction, a guide, specific opengl documentation, even keywords to search up and learn about, that can get me to where I’m looking to be.
I greatly appreciate any help