Jump to content


  • Content Count

  • Joined

  • Last visited

Community Reputation

5 Neutral

About Zombie26

  • Rank
  1. That worked! I feel so stupid for not thinking of that before. I had to make a conditional statement in the shader to swap the UV based on the normal position.
  2. So I've been trying to get a texture atlas to display correctly on my chunks but some of the textures are displayed sideways. I'm stumped trying to figure out how to rotate the textures. I've had some success using SetVertexNormal but I don't know how to flip them 90 degrees. Here's the shader I'm using, I converted it from this article. https://0fps.net/2013/07/09/texture-atlases-wrapping-and-mip-mapping/ //Initialize accumulators vec4 color = vec4(0.0, 0.0, 0.0, 0.0); float totalWeight = 0; vec2 tileUV = vec2(dot(ex_normal.zxy, ex_position), do
  3. Zombie26

    Voxel Code

    My hope is that I'll eventually get to having a base template just for that. I can't make any promises thought. Also I have some more question if you don't mind. What is the proper way to unload a leadwerks model? I'm experimenting with loading multiple chunks but I can't figure out how to get rid of models other than using hide(). Also does the engine already have some sort of frustrum culling built in? I know once I get to creating and destroying blocks I'm probably going to have more questions. I can't quite figure out how I'm going to remove faces, since all I see are functions to mov
  4. Zombie26

    Voxel Code

    Thanks for the suggestion I'll keep that in mind. I don't know how to program threads yet but I've heard of other people using them in voxel programs. I'll have to look up some tutorials. So far thought the greedy meshing algorithm is working great! I finally figured out how to generate the mesh separately from the algorithm. I even generated a larger chunk with minimal difference in performance and that's including a collision mesh.
  5. Zombie26

    Voxel Code

    I'm still new to programming but would applying a greedy meshing algorithm make things faster? I'm trying to see if I can somehow use your code to create a mesh from a std::vector<Vec3>. I'm using this greedy algorithm converted to C++. https://0fps.net/2012/06/30/meshing-in-a-minecraft-game/ I'm trying to create a minecraft clone using leadwerks but I think I'm in way over my head. I've already got the algorithm working. Only problem is when I try to create the mesh inside the algorithms loop I'll get like 30fps trying to render it. So I'm trying to figure out how to take a std::v
  • Create New...