GridVids
Sign in with YouTube

Tutorial - Bad Apple but it's a 172800 Entities in Unity ECS

Tale Forge May 13, 2024 17:09
Create an account to hide videos, mark them watched, or save them to Don't Miss.
Don't Miss
Create an account to hide videos, mark them watched, or save them to Don't Miss.
Mark watched
Create an account to hide videos, mark them watched, or save them to Don't Miss.
Hide
Open in popup Open on YouTube
Share video

Share video

Copy the GridVids link or iframe code.

Video link
Iframe code
Iframe content

Chapters
Tutorial for Bad Apple but it's a 172800 Entities in Unity ECS! What am I trying to achieve in the Bad Apple with Unity ECS video? - I want to show you the capabilities of ECS with Jobs and Burst, where in real time, every frame, we can modify 172800 entities materials while maintaining 170-180 FPS (even 190 FPS without recording)! And there is still the potential of rendering on the graphics card, so the performance can still be increased! How did I do it? - First, the ISystem - BadAppleSpawnerSystem - spawns 172800 entities (quads) based on the size of the RenderTexture (width x height). - Then I bake the RenderTexture as Managed ComponentData and read pixels from the 2D texture (async, 640x480 = 172800 pixels) from SystemBase. I execute several jobs (parallel) in which I write the color as a float4 value into BadAppleVisualizationColorComponentData. Of course, all of this is annotated with the [BurstCompile] attribute. - The value is read by the shader which has the Shader Declaration parameter set to: "Hybrid per instance" (required to work!). Music by Alstroemeria Records (feat nomico): https://www.youtube.com/watch?v=i41KoE0iMYU Animation by あにら (Anira): https://www.youtube.com/watch?v=FtutLA63Cp8 -------------------- We appreciate your support on the Patreon: https://patreon.com/TaleForge --------------------- Documentation: 1. https://docs.unity3d.com/ScriptReference/RenderTexture.html --------------------- Social Media: Discord: https://discord.gg/gZssNGuDdc Facebook: https://www.facebook.com/taleforge/ Instagram: https://www.instagram.com/taleforgegames/ LinkedIn: https://www.linkedin.com/company/tale-forge/ Reddit: https://www.reddit.com/user/taleforge Tiktok: https://www.tiktok.com/@taleforge Twitter: https://twitter.com/TaleForgeStudio #taleforge #unity #ecs #tutorial #gamedev #games #programming #education #learning #trending
Education
#Unity #2D #Game #Developer #Programmer #Tutorial #TaleForge #ECS #GameDev #Programming #Trending #Education #Learning #Unity3D #DOTS