Shapes do not render in URP with 2D renderer

Avatar
  • updated
  • Fixed

Bought shapes today and ive been having some issues with URP.

On a new project using URP, add a Polyline or any other shape to scene, swap the URP pipeline asset to use the 2D renderer and the shape disappears.

Commenting out the code which automatically upgrades the shaders from built-in to URP (so its using the original shaders in URP) makes them render again but this had problems getting things to render with immediate draw mode.

Reporting a bug? please specify Unity version:
2019.4.10f1
Reporting a bug? please specify Shapes version:
2.3.2
Reporting a bug? please specify Render Pipeline:
Pinned replies
Avatar
Freya Holmér creator
  • Answer
  • Fixed

URP 2D support has now been added as of Shapes 4.1.1

Avatar
Freya Holmér creator
  • Not a bug

since the 2D renderer is still experimental (as far as I know), I won't be adding support for it just yet - but there are workarounds, similar to what you mentioned:

https://shapes.userecho.com/en/communities/1/topics/81-shapes-not-rendering-with-2d-renderer-after-regenerating-shaders

as for immediate mode, this could be because onPostRender isn't called in the SRP, so you might have to look into the FPS example code for how to set up immediate mode calls within SRP contexts

Avatar
Freya Holmér creator
  • Answer
  • Fixed

URP 2D support has now been added as of Shapes 4.1.1