Unity GPU Instancing in less than 7 minutes!

preview_player
Показать описание

Creative Commons Attribution-ShareAlike 3.0 Unported (CC BY-SA 3.0)

╔═╦╗╔╦╗╔═╦═╦╦╦╦╗╔═╗
║╚╣║║║╚╣╚╣╔╣╔╣║╚╣═╣
╠╗║╚╝║║╠╗║╚╣║║║║║═╣
╚═╩══╩═╩═╩═╩╝╚╩═╩═╝
Рекомендации по теме
Комментарии
Автор

Just a disclamer, When I say 120fps with 100, 000 instances I mean for my rig. Your results may vary with your setup. Thankyou for watching the video and make sure to subscribe!!! Good luck in your procedural Journey.

Flaroon
Автор

Great video!

For anyone wondering about the line that is cut off. Here's a solution:

Batches[Batches.Count - 1].Add(item:
Matrix4x4.TRS(
pos: new Vector3(x: Random.Range(-20, 20), y: Random.Range(-10, 10), z: Random.Range(0, 300)),
q: Random.rotation,
s: new Vector3(x: Random.Range(1, 3), y: Random.Range(1, 3), z: Random.Range(1, 3))));

seekeroftheball
Автор

That was VERY enlightening. Thank you very much.

JamesWjRose
Автор

hey love the vid! I just wanted to ask how can I attach the grass to terrain? I'm a little new to coding

orangejuice
Автор

Thank you, but you can use drawmeshinstancedindirect to bypass the 1000 limit, But I have no idea how to use drawmeshinstancedindirect which is why I'm here.

personmuc
Автор

isnt there a manual version in unity? in blender you can just Alt+D an object and boom, instance. i could really use with a no code solution if there is one

JamFeliix
Автор

Aren't you still having to loop through the batches on the CPU side every frame? I am a bit confused. I recently watched that Acerola tutorial on Grass\GPU instancing and checked his code. It seems that he generates a single buffer with all the grass mesh data and sends only once to the gpu on the start function.

Ariel
Автор

Do you have code for this video uploaded?

jamesmillerjo
Автор

Can you upload the script? for me: error

FenyEro
Автор

I followed this tutorial and the entire mesh rendered as black, any ideas?

yqish
Автор

Great tutorial. But do you know how to make grass using this technique?

Sober-MindedYT
Автор

How to connect colliders to this objects ?

levrisfirst
Автор

There is literally zero demonstration on this video on how to use this script and what the output is. Neither is the code all shown in the video, making this video unhelpful.

OPENPCreviews
Автор

The content is good, but you need to enunciate more clearly. Around 2:10 to 2:15, I have no idea what you are saying.

KVergot
Автор

You need to learn how to vocalize better. It was very hard understanding your pronounciation. On the other side, very nice and well edited video. Keep it up.

leonardomontes
Автор

That's a bullshit video.
First of all this video is incomplete and not showing quite anything here.

The second thing is that I tested both solutions with GPU instancing and this method.
With this method i gained only 5+ fps more... with GPU instancing that provided from unity i gained more than 40+ fps.

This lines of codes is already included in the GPU instancing but even more better because you don't need to manually assign everything.

nikoart