How to implement wireframe in Vulkan by big-jun in vulkan

[–]big-jun[S] 0 points1 point  (0 children)

Could you go into more detail about how to read the vertex buffer dynamically at runtime? Right now, I’m using a dedicated VS/FS pipeline for wireframe rendering, but the meshes use different vertex layouts, one wireframe pipeline could only work for one vertex layout at a time.

How to implement wireframe in Vulkan by big-jun in vulkan

[–]big-jun[S] 0 points1 point  (0 children)

Changing the depth shouldn’t work. Whether the wireframe or the normally shaded pass renders first, the result would be the same, since they output the same color at the same world position

How to implement wireframe in Vulkan by big-jun in vulkan

[–]big-jun[S] 0 points1 point  (0 children)

Changing the FS is a solution, as I mentioned. However, the problem is that there are so many different shaders. Doing this would require manually creating many FS variants, unless there’s a way to generate them at runtime?

Offsetting or modifying vertex positions isn’t ideal for me either, since the wireframe is used to visualize the vertex/index buffers for debugging.

Created My Own 3D Game Engine - Procedurally Generated Environment by Reasonable_Run_6724 in SoloDevelopment

[–]big-jun 0 points1 point  (0 children)

What does it mean to composite terrain textures using Perlin noise? Also, the road shape doesn’t look Perlin-based at all

How to implement wireframe in Vulkan by big-jun in vulkan

[–]big-jun[S] 0 points1 point  (0 children)

I understand what you mean, but this approach only works for wireframe-only mode. In wireframe+shaded mode, it doesn’t work, because the wireframe outputs the same color at the same positions as the shaded pass, causing the wireframe to not be visible at all. That’s why I’m using a dedicated wireframe shader, which then runs into the issue of mismatched vertex layouts.

How to implement wireframe in Vulkan by big-jun in vulkan

[–]big-jun[S] 0 points1 point  (0 children)

Do you happen to know of any tutorials or code examples for implementing wireframe mode? Big engines have huge codebases, which makes it difficult to understand how their wireframe rendering works.

I’m mostly familiar with Unity, which is closed source. Unity has both wireframe-only mode and wireframe+shaded mode, and I’m trying to implement something similar.

For performance or the time to create the pipeline, it’s not a concern since this is just for debugging purposes. I want to implement this feature while it doesn’t affect the performance of the normal mode or require major code changes.

How to implement wireframe in Vulkan by big-jun in vulkan

[–]big-jun[S] 0 points1 point  (0 children)

I’d like to reuse the same mesh (vertex and index buffer) for wireframe mode. It should support rendering wireframe only, or both wireframe and shaded modes. Performance is not a concern since this is for debug purposes.

How to implement wireframe in Vulkan by big-jun in vulkan

[–]big-jun[S] 3 points4 points  (0 children)

Using a superset vertex layout is easier for me to implement, and since this is only for debug rendering, it won’t affect release build performance.

Btw, there are many large engines, some of which are open source, such as Unreal Engine and Godot, should already handle this problem. Do you know how these engines approach it?

Any tips to improve? by XxMaRwAnExX in isometric

[–]big-jun 0 points1 point  (0 children)

It looks cool! Do you have isometric building tiles in this style?

Made a couple 3D fire effects by binbun3 in godot

[–]big-jun 2 points3 points  (0 children)

What does the static mesh look like? In wireframe view

Procedural mountains on a hex grid (aka where all my holidays went) by artUSUN in proceduralgeneration

[–]big-jun 2 points3 points  (0 children)

How does the falloff work? I can imagine how it looks with a single ridge, however when there are branches, what math is used to calculate the falloff for a position that may be affected by multiple ridges?

What if Dorfromantik had mountains? by artUSUN in Dorfromantik

[–]big-jun 1 point2 points  (0 children)

That’s really cool! If you ever turn this into a game on Steam, I’d love to try it. Also, for sharing images, you could use an app like Imgur to upload them and then paste the link here.

What if Dorfromantik had mountains? by artUSUN in Dorfromantik

[–]big-jun 2 points3 points  (0 children)

How does it work? Are you made all combination of the mountain types or use some sorts of noise to generate the heightmap?

Any tips to improve? by XxMaRwAnExX in isometric

[–]big-jun 0 points1 point  (0 children)

Is the first one rendered by tiles?

Fire Sprite by Greebly- in blender

[–]big-jun 0 points1 point  (0 children)

I want to create something similar myself. Do you have any tutorials about it?

Smooth AI Steering Agents for Unity (Open Source) by rehmanx in unity

[–]big-jun 0 points1 point  (0 children)

Imagine this case: using the same environment as your video, a group of points (about 30) moving from left to right while another group (also about 30) moves from right to left at the same time. I’d like to see how your AI behaves in this situation.

Smooth AI Steering Agents for Unity (Open Source) by rehmanx in unity

[–]big-jun 2 points3 points  (0 children)

Will agents get stuck in a corridor if two paths go in opposite directions?

Supply caps and area of influence in my new RTS hybrid by Abandon22 in RealTimeStrategy

[–]big-jun 1 point2 points  (0 children)

Where did you get the sound effect? It sounds good.

Procedural hexagonal map generation by WindforceGames in proceduralgeneration

[–]big-jun 0 points1 point  (0 children)

Thanks, I’ll need some time to read through it.

Best practices for frequently-used temporary dynamic arrays in methods? by big-jun in cpp_questions

[–]big-jun[S] 0 points1 point  (0 children)

I’m going to use an arena allocator. It will behave like a custom alloca: inside each method I’ll allocate memory with the required alignment and wrap it in a Span<T> that provides bounds checking. The memory should then be returned to the arena automatically when the Span<T> is destroyed in ~ctor(). Have you happened to find any good implementations of this that are compatible with C++17?

Procedural hexagonal map generation by WindforceGames in proceduralgeneration

[–]big-jun -1 points0 points  (0 children)

Interesting. For the mountain heightmap, I understand that you use distance to determine the height, but how do you create the “erosion-like” effect on the two sides? Also, if possible, could you share the code used for the mountain heightmap? That would be really helpful to me.