Intro to PCG Compute Shaders (UE 5.5)

  Рет қаралды 2,147

Alex

Alex

Күн бұрын

Пікірлер: 18
@friedunicorn
@friedunicorn 21 күн бұрын
So excited for this. All your videos are pure gold. Thank you for them!
@TechArtAlex
@TechArtAlex 21 күн бұрын
Thanks! Yeah - I think this change is a huge game changer. I've been experimenting a lot and can't wait to see what other GPU nodes we get too.
@XeroXXL
@XeroXXL 28 күн бұрын
Keep going man, love all your videos =)
@nfdgoisn
@nfdgoisn 24 күн бұрын
Thanks for making this video!
@TechArtAlex
@TechArtAlex 24 күн бұрын
Thanks for watching!
@graemepalmer2306
@graemepalmer2306 28 күн бұрын
Great video, thanks for sharing!
@TechArtAlex
@TechArtAlex 28 күн бұрын
Thanks!
@Stygmire
@Stygmire 20 күн бұрын
I wonder if it's going to be doable to sample textures in the HLSL? Looks like Landscape-based grass (going to an RVT) might be doable with PCG after all?
@TechArtAlex
@TechArtAlex 20 күн бұрын
It can already sample textures, but unfortunately I have not found a way to sample landscape RVT specifically yet. The solution I'm currently experimenting with is to use the regular CPU points to sample landscape layer weights at a small number of "probe" positions, and then interpolate that data across the individual grass instances.
@allenzhang1824
@allenzhang1824 18 күн бұрын
Cool! But I found that after I check 'Execute on GPU' at Static Mesh Spawner node in 'Play Mode' or 'Silulate Mode', the meshes disappear. Have you noticed that? Its seems some bug? I can`t see those spawned mesh when I play
@TechArtAlex
@TechArtAlex 17 күн бұрын
Changing the generation trigger to "Generate at Runtime" should fix this. Presumably you could also do "Generate on Demand" and request the generation via BP/code. But you're right, "Generate on Load" seems bugged.
@mic007129
@mic007129 28 күн бұрын
Great video thanks! Any idea on how we could use an input to remove grass in some area? Like rocks? Mostly do a "difference bool" in HLSL?
@TechArtAlex
@TechArtAlex 27 күн бұрын
You can remove points with *bool Out_RemovePoint(uint DataIndex, uint ElementIndex);* Unfortunately, a shader only knows what we can explicitly tell it. Meaning we need to define each Element we want to cull explicitly - So the challenge becomes how do you define what ElementIndex should be culled? The optimal way would likely be to have a texture which defines where the grass can or can't spawn. Unfortunately this can't currently sample landscape RVTs or landscape layer weights directly. The simple but expensive option would be to pass the data back to the CPU and run your difference operation there. Another option would be to simply just spawn the grass everywhere, but then sink it beneath the ground in the vertex shader wherever you want to hide it. PrismaticaDev has a video called Easy Grass Occlusion in UE4 where they write the rocks and other objects into the landscape RVT, which is then sampled by the grass material and used to sink the object beneath the ground.
@mic007129
@mic007129 27 күн бұрын
@TechArtAlex thank you for the great answer, that give me a lot to think about. This will be an interesting challenge to do.
@gangsterhommie9345
@gangsterhommie9345 15 күн бұрын
Hey man! Great work! This helped me out a ton! I've been working on a very similar thing recently and just stumbled upon your channel. It looks like the lag when moving faster is because the pcg graph samples the whole landscape no matter what the grid size is. In Unreal's video kzbin.info/www/bejne/oGTOlmmDosiUm7s it looks like they're using the point generator to create points for each grid segment without sampling the whole entire thing. Correct me if I'm wrong. Anyways if you figure it out, I'd love to hear about it. I'll update here if i figure it out too! Great work!
@TechArtAlex
@TechArtAlex 15 күн бұрын
Thanks for watching, glad it helped! I have a prototype of hi-gen GPU grass and the performance while moving is significantly better than in my recent CPU hi-gen video. Currently I'm at 10 million points without any hitches. At 20 million blades of grass it eventually crashes my rig. You can also set a ms frame budget for PCG updates (using a cvar), which can defer grid updates if the frame time goes too high. This will cause a grid of missing content in that event, but I find that far better than a stutter. I believe the "Get landscape data" node is the for entire landscape, but I think the actual samples are constrained to the bounding shape. Either way, this seems to be a non-issue for the GPU method.
@Mad94John
@Mad94John 28 күн бұрын
Nice, I tried to use grass on the landscape with pc and in crashes my project every time
@TechArtAlex
@TechArtAlex 28 күн бұрын
Yeah, CPU compute with so many instances has a tendency to cause crashes. I think this will be a lot more stable workflow for grass especially.
I Tried Real Augmented Reality Glasses!
20:29
Marques Brownlee
Рет қаралды 5 МЛН
Симбу закрыли дома?! 🔒 #симба #симбочка #арти
00:41
Симбочка Пимпочка
Рет қаралды 5 МЛН
How to Fight a Gross Man 😡
00:19
Alan Chikin Chow
Рет қаралды 18 МЛН
When Cucumbers Meet PVC Pipe The Results Are Wild! 🤭
00:44
Crafty Buddy
Рет қаралды 61 МЛН
How do Video Game Graphics Work?
21:00
Branch Education
Рет қаралды 4 МЛН
Real-time animation using Unreal Engine on ‘War Is Over!’
5:33
Unreal Engine
Рет қаралды 38 М.
RealityCapture 자동화 테스트 과정
25:57
김재승의 포토스캔
Рет қаралды 69
Modo is Dead
5:15
Gamefromscratch
Рет қаралды 23 М.
Unreal Engine free assets November 2024 Part 1
13:20
LeafBranchGames
Рет қаралды 7 М.
PCG Ray Casting is Here And It Opens Crazy New Opportunities
24:23
Procedural Minds
Рет қаралды 2 М.
Why do Studios Ignore Blender?
8:52
Film Stop
Рет қаралды 227 М.
How To Make Roads with Splines and PCG in Unreal Engine 5
23:15
Симбу закрыли дома?! 🔒 #симба #симбочка #арти
00:41
Симбочка Пимпочка
Рет қаралды 5 МЛН