Hybrid Renderer not rendering anything?

I have been experimenting with the DOTS/ECS System. This seems like a common problem that people have experienced but in scouring the internet the solutions that others have discovered have either become no longer applicable or are not working for me that I can tell.

I have these packages installed in my project.

  • Entities package 0.50.1-preview.2
  • Hybrid Renderer 0.50.0-preview.44
  • Universal RP 10.9.0

I am using a hybrid ECS approach where I use a GameObject prefab that has a Mesh Filter and a Mesh Renderer and I can see the entities it creates with the ConvertToEntity component do have what appears to be a valid RenderMesh data component with the right mesh and material. But nothing renders in the Game view.

I have even tried placing a vanilla 3D sphere GameObject in the scene with default material, adding the ConvertToEntity component, and even that does not render anything.

1 Like

Hmm… Well this is interesting. I decided to create a fresh UDP project and install the entities and hybrid renderer packages and now at least I am getting a visible error:

A Hybrid Renderer V2 batch is using the shader ā€œHidden/Universal Render Pipeline/FallbackErrorā€, but the shader is either not compatible with Hybrid Renderer V2, is missing the DOTS_INSTANCING_ON variant, or there is a problem with the DOTS_INSTANCING_ON variant.
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)

OK that seems to be because I had pulled a material reference from my previous project in my prefab. After resetting the material to one that is in the proper UDP new project, I am now seeing Entities render! Yay.

So I guess my original problem had something to do with the fact that I was installing the Entities, Hybrid Renderer, and UDP packages to a sample 2D project.

You can right click your material / shader and click reimport to update it to hybrid renderable. Also make sure your URP settings enable SRP batching which it should by default

That’s not changing anything for me …

My Material:

My simple plane:
8128952--1054358--upload_2022-5-15_10-0-54.png

Before Playmode (note: the capsule has not ā€œConvertToEntityā€):

8128952--1054361--upload_2022-5-15_10-1-53.png

In Playmode:
8128952--1054364--upload_2022-5-15_10-2-17.png

DOTS Hierarchy Window:
8128952--1054373--upload_2022-5-15_10-4-37.png

EDIT: Before you ask hybrid renderer is installed! Player has ENABLED_HYBRID_RENDERER_V2 and the base project was a new project based on the URP sample from Unity 2020.3.34f1.

8128952--1054370--upload_2022-5-15_10-3-41.png

HybridChunkInfo not having Valid checked is a problem. That means that the Hybrid Renderer is not processing your entity and initializing its backend rendering state. Make sure the HybridRendererSystem is running and detecting your entity in its queries.

You didn’t happen to install netcode in your project did you?

2 Likes

Wow~ I nerver thought the problem is Netcode package. (╯°▔°)╯︵ ┻━┻

  • Entities 0.50.1-preview.2
  • Hybrid Renderer 0.50.0-preview.44
  • Netcode 0.50.1-preview.19
  • Physics 0.50.0-preview.43
  • Burst 1.6.4
  • Collections 1.2.3
  • Jobs 0.50.0-preview.9
  • Mathematics 1.2.5

After removed Netcode, create a cube and set ConvertToEntity, the cube is renderered.ヽ(t◕oā—•ļ½”)ノ
But I have no idea what’s wrong with installing Netcode…
(Probably when installed Netcode,
Hybrid Renderer System runs in ClientWorld0 but the entity instantiated in Default World?)

Basically you instantiated the entity in the default world and not on server as a ghost or client where the renderer works. NetCode does not support the ConvertToEntity component anymore, subscenes are required.

3 Likes

I also have this problem.
Unity 2021.3.6f1

  • Entites 0.51.0-preview.32
  • Hybrid renderer 0.51.0-preview.32

I don’t have NetCode so that shouldn’t be an issue, right? When I use the Convert To Entity component and hit play the object disapears like OP describes.

1 Like

same problem