It's me again. This one is really eluding me. I slapped together some code for a voxel rendering engine and I'm in the process of cleaning it up and optimizing it. I'm using VBO's and VAO's and I just converted from using IBO's to not. I also just changed the way my vertex/color data is passed and the structure of my shaders. the method I was using can be seen in my renderplayer() method as I haven't bothered updating it yet. The next step is changing all of my rendering data to shorts or bytes.
All of my chunks were rendering properly before but now I get a weird errror where any chunk that is not init'd with the default configuration appears to -I'm gonna say- bleed
over the three chunks preceding it in the list of chunks.
I am seeing the preceding chunks render as if they had block list composed of both
their own and that of the offending chunk.
I've numbered chunks 0-5 here in blue and circled the offending chunk. Number 5 should appear as a y=x
structure with no red base and the others should appear as y=0
In addition I've pointed out a weird thing
where chunk[offending - 3], in this case 2, renders differently from the others.
When I check the block list of my chunks they appear correct. The list of vertices for each chunk is the correct length, and the engine appears to be rendering the proper number of chunks.
Here is my code. Engine.java
// rendering happens hereChunkManager.java
//should be of no use as far as this errorUtils.java
// only included for completeness
I'm posting here because I can't find my error and I'm not sure if it's some stupid numerical typo or a fundamental misunderstanding of the rendering process I've built.
Thanks all in advance,EDIT:
Almost forgot to mention that my engine extends a program written ra4king and uses another.
They too are included for completeness.