Search Issue Tracker
By Design
Votes
15
Found in [Package]
10.0.0-preview.27
Issue ID
1267776
Regression
No
Graphics.Blit will not apply the Material over the whole GameObject when the Material uses HDRP or Shader Graph shader
How to reproduce:
1. Open the user's attached "Bugreport-Graphics.Blit" project
2. Open the "Scene" Scene
3. In the Hierarchy select the "Plane" GameObject
4. Enter the Play Mode
Expected results: The whole "Plane" GameObject becomes gray
Actual results: Only the corner of the "Plane" GameObject becomes gray
Reproducible with: 2019.3.0b5, 2019.4.8f1, 2020.1.3f1, 2020.2.0a21 (7.1.1, 10.0.0-preview.27)
Could not test with 2018.4.26f1 because of the CS0246 error, 2019.3.0b4 (HDRP 7.0.1) and lower because the shader would not apply
Notes:
- The issue occurs only with these shaders:
HDRP
HDRP Shader Graph
Shader Graph (when using either HDRP or URP. Built-in Render Pipeline does not support Shader Graph)
- Changing the ZTest to Always (or any other option) does not solve the issue
- Changing the Camera's Viewport does not solve the issue
- The issue has been tested and reproduced on Windows
-
cr4y
Aug 26, 2020 16:24
Why is it in category "Package: SRP HD Template"?
I believe it should be "Package: ShaderGraph" instead, as it affects both Universal and HD Rendering Pipelines.
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Undoing the branch rotation resets only wireframe and not mesh when undoing the action first time after launching the project
- Asset Bundles retain their previous hash and CRC values when an object within a bundle is changed and rebuilt
- APV Reflection Probe Normalization breaks when SSGI is enabled
- Default Custom Components in project have Library counterparts
- [iOS]"The destination host has an erroneous SSL certificate" error is thrown when using UnityWebRequest to connect to the server with a self-signed certificate
Resolution Note:
Using a ShaderGraph like this with a Blit is not supposed to work. All current HDRP shader graphs are intended for 3D objects in the scene. As such they apply camera and projection transformations to all vertices, making it unsuitable for 2D blits like this.
I suggest trying to use Custom Render Textures as they are much more suited for writing a brush painting tool: https://docs.unity3d.com/Manual/class-CustomRenderTexture.html
With scripting it is possible to generate strokes on specific part of a render texture.