Anixias
Member
Hi. I decided to optimize how I render my game's terrain. The terrain is tile-based. I was simply looping through every tile on screen every frame and recalculating subimages and rendering tiles. As you can imagine, this didn't really work, as it took 95% of my debugger's profiling time.
So, I made the switch to Vertex Buffers. I used sprite_get_uvs, etc. and got it all rendering 100% perfectly minus one small glitch: There is a grid where it isn't reading colors.
Here is a picture of what I'm talking about:
Notice how the water underneath the map is visible along the edges of the repeated stone texture. I tried the following:
-Turning off AA
-Enabling "Edge Filtering" on all terrain textures
-Increasing "Border Size" on the environment texture page from 2 to 3
-Disabling "Allow Scaling" on the texture page
-Cleaning the project
Sometimes it does this on sand tiles, and other times it doesn't.
So, I made the switch to Vertex Buffers. I used sprite_get_uvs, etc. and got it all rendering 100% perfectly minus one small glitch: There is a grid where it isn't reading colors.
Here is a picture of what I'm talking about:
Notice how the water underneath the map is visible along the edges of the repeated stone texture. I tried the following:
-Turning off AA
-Enabling "Edge Filtering" on all terrain textures
-Increasing "Border Size" on the environment texture page from 2 to 3
-Disabling "Allow Scaling" on the texture page
-Cleaning the project
Sometimes it does this on sand tiles, and other times it doesn't.