Pushing the rendering limits - Rust Voxel Engine

preview_player
Показать описание
I implemented 6 new rendering related techniques in my voxel engine using the rust programming language and Bevy game engine.
pbr integration, shadow rendering, fog, level of detail (LOD), far distance heightmap approximation, skybox.

My discord group:

Want to support me?
⁍ Monero: 43Ktj1Bd4Nkaj4fdx6nPvBZkJewcPjxPB9nafnepM7SdGtcU6rhpxyLiV9w3k92rE1UqHTr4BNqe2ScsK1eEENvZDC3W1ur

Resources: (The tech I'm using for my larger voxel game project)
world generation: my own custom implementation is not open source at the moment.

other rust libraries, that I recommend:

#gamedev #rustlang
Рекомендации по теме
Комментарии
Автор

This man is singlehandedly porting Veloren to Bevy.

fendoroid
Автор

PBR, Shadows, and LODS oh my! Really interesting to hear the different problems you encountered with each steps and the solutions. Great work!

TonsOfHunStudios
Автор

Genuinely my favorite programming channel. I love coding in Rust, and watching these videos is super interesting to see how you structure all of this

eboatwright_
Автор

I am making a voxel game in Bevy too, what I do is I have a .draw() method on my Chunk struct, that returns a Bevy Mesh, and then I draw it with PbrBundle.

oglothenerd
Автор

Do you need some kind of hysteresis, so if you step back and forward over the edge of one area you're not constantly loading and unloading the same boundary tiles?

RoamingAdhocrat
Автор

The progress is very cool! I see that the mesh generation is a bit slow, I noticed that you're using hash map structures, and I was wondering if it would be possible to avoid those, since they cause a lot of memory cache misses (especially if you have very large ones). Or maybe having a lot of smaller ones so they fit inside the L2/L1 caches would be enough!

giacomo.delazzari
Автор

Nice video! Might I suggest making your voiceover track mono in future uploads? Something about the phase of your mic makes it really hard (personally) to listen to with headphones. Cheers!

ETBCOR
Автор

If you're still looking for something to do with the LOD misalignment you can look into adapting the surface shifting technique described in the Transvoxel paper in ch 4

on-hvco
Автор

Got that sweet, sweet Patreon support locked in! Been loving your content and energy, and it's both educating me and motivating me to revisit a game I didn't finish for ludum dare earlier this year!

senkwich
Автор

Love a Tantan video. Thanks for uploading!

Neph
Автор

Nice Video, I've never done anything with Graphics Programming. So this is really impressive!

thexadgaming
Автор

It's stupid that Minecraft still doesn't have LOD

jboblk
Автор

6:00 Damn I feel your pain! I spent couple weeks to do it right in my game and it still have some issues.

RSchenal
Автор

Fascinating to see what problems you've been running into! Great video Tantan.

Skeffles
Автор

Without this video I wouldn't have discovered you could import shader code! It's helped my project, thank you :)

trentbillington
Автор

This stuff looks advanced. Great work. At the moment I make only simple games, so I can only try to imagine how hard this Voxel thing is. Congrats on making it work. Keep up the good work ;)
- Dan

PixelsGames
Автор

Like some other commenters, I notice that you're using hashmaps to keep track of things. I don't know if they are a performance bottleneck for you, but did you know that the default hashing algorithm used by Rust hashmaps is slow? You can replace the hashing function with a crate like FxHasher, and net performance gains from a simple find/replace :)
(The default hashing algorithm is slow because it was chosen to be DDOS-resistant, but for graphics code that doesn't matter.)

DouglasDwyer
Автор

For LOD you could arrange the chunk data like a .png, where the spaced out blocks come first and the next data fills in the gaps

redinatork
Автор

Bevy has been so interesting to work in. I've been working on a multiplayer FPS similar to Quake Arena using GGRS for networking. When Bevy works, oh boy it's so nice. Writing a system that just does what it needs to is so awesome. When things don't work tho...it's... interesting

zactron
Автор

you can probably force your world preview to be behind your voxel mesh in shader code by adding some offset before writing to the depth buffer, but i know neither bevy or rust, so that could be hard to do

coppertones