Search Unity

Feedback Wanted: High Definition Render Pipeline

Discussion in 'Graphics Experimental Previews' started by Tim-C, Sep 25, 2018.

  1. Korindian

    Korindian

    Joined:
    Jun 25, 2013
    Posts:
    444
    Thanks... Can you also see my questions on the post 3 posts before this one? Would love to know how to do those things.
     
  2. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    25,606
    4.0/2018.3.b4
     
  3. konsic

    konsic

    Joined:
    Oct 19, 2015
    Posts:
    688
    Please add in HDRP and LWRP additional parametres for procedural sky like Mie and Rayleigh

     
  4. thelebaron

    thelebaron

    Joined:
    Jun 2, 2013
    Posts:
    298
    Are the draw modes for the scene currently working properly for hdrp or are they in flux? Its related to https://forum.unity.com/threads/gpu-lightmapper-preview.561103/page-2#post-3754222 in that I cant view the sceneview for uv overlap to display any meaningful information, nor lightmap preview for uv overlap which doesnt show anything just a "Loading..." text where the lightmap image should be(as I get some console warnings about overlapping uvs which I believe is the texel overlap rather than uv overlap).
     
  5. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    25,606
    As I understand it, it's a WIP, but please file a bug report if you can use the existing menu and they don't function correctly.
     
  6. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    25,606
    Terrain Lit:
    I was wondering if it's possible to think about pixel displacement for terrain on a single primary layer in the future. All layers do not need it only one.

    The single layer using it could be rocks or stones, or chunky feature, and that would be marvellous - currently terrain looks a bit old school despite up to 8 layers. We would not need a separate height value, a slider is sufficient.

    Contact Shadows with pixel displacement:
    If contact shadows would work with pixel displacement, this would be wonderful also. I wasn't able to see a result my end so I guess that the pixel displacement is not writing to depth in my test.
     
  7. Korindian

    Korindian

    Joined:
    Jun 25, 2013
    Posts:
    444
    HDRP Unlit shader's color, when used with particles, overrides the Particle System's Start Color parameter. Changing the Particle System's Start Color doesn't do anything when used with that shader.

    Also, the Unlit Master node in ShaderGraph is missing a lot of the options available in the HDRP unlit shader, like Enable fog, distortion, transparency sort priority, per refraction pass, etc. Will there be a HDRP Unlit master node like there is for the HDRP Lit node?
     
  8. rizu

    rizu

    Joined:
    Oct 8, 2013
    Posts:
    1,177
    Is Unity preparing proper HD shader for Shuriken? I know it's been stated many times it's not compatible but I did notice some changes on SRP git a long time ago related to this (but couldn't test them at that time as they required 2018.3). Now that 2018.3 betas have been out for a while, I tried what happens now on Shuriken particles with custom HD Master Lit node graph:

    https://www.dropbox.com/s/g5o7mq0k14nyt5o/hdrp_lit_shuriken_vertex_color.mp4?raw=1
    https://www.dropbox.com/s/df4pwbijtdu2cmp/hdrp_lit_particle_demo.mp4?raw=1

    it seems that it might already be possible to write a fully featured HD particle shader for Shuriken (I only tried small subset of particle shader feats here), are there still some showstoppers for making this happen on official HDRP release or is it simply matter of time?

    Edit: I guess they are working on it:
     
    Last edited: Oct 8, 2018
    thelebaron and konsic like this.
  9. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    560
    Last I reply I remember seeing on this was that the Unlit shader works but Lit one was limited.

    upload_2018-10-8_8-49-14.png

    I think VFX Editor will be the way to go for HDRP particles. It's already capable of doing stuff shuriken can't and most of its features. (Didn't see anything similar to the new features for Shuriken in 2018.3 in the VFX Editor yet)
    I'm not a VFX artist so haven't really messed with Shuriken but I've seen videos on it and have an understanding of how it works. I've also played around with the VFX Editor and it seems that in HDRP it's going to be a replacement from my understanding.
     
  10. rizu

    rizu

    Joined:
    Oct 8, 2013
    Posts:
    1,177
    I do remember the message you quoted, but like mentioned on my post, there isn't technical limitation for vertex color etc to not work if there's a dedicated particle shader that implements it (as you can see on the few clips I made with custom HD Lit SG shader). I got texture input and vertex color working with HD Lit graph but still missed bunch of other shader feats as it was a simple test.

    VFX editor is cool and more important in the future, but right now it's important to get existing particle effects to work on HD, especially since there doesn't seem to be any real reasons preventing it from happening. I can imagine new vfx work being authored in new vfx editor but people will still need to be able to use the old system as well during the transition.

    If they can make a conversion tool from Shuriken to VFX editor, then this would be fine, but I don't think they have feature parity?
     
    Last edited: Oct 8, 2018
  11. elbows

    elbows

    Joined:
    Nov 28, 2009
    Posts:
    2,360
    At this stage VFX system supports collision with various primitive shapes, and also with signed distance fields (specifically, SDFs stored in 3D textures). So it is already possible to do various kinds of collision with this system, if you are prepared to do the work yourself 'manually'. But I would assume that when some people mention collision, they are often talking about the system automatically knowing what else is in the scene and colliding accordingly. I dont know all that much about that side of things, except its a challenge for GPU-based particle systems and requires clever systems to generate and make use of data in the appropriate format, unless we are talking only about basic stuff like that seen in the past with the use of depth maps. Perhaps Unity will have some forms of scene SDF baking one day (or 3rd party-provided solutions), or perhaps the methods of transferring scene geometry data to GPUs for modern GPU raytracing purposes will have uses in this realm too one day. Another thing people might be implicitly implying when they mention collision is the sort of data about collision events that particle systems pass to other CPU-based code. I havent looked at that side of things with VFX but its another area I would expect to have traditionally contained some barriers when it comes to GPU->CPU data.

    I am reasonably sure that advanced particle authors will find all manner of differences between the two systems, each have strengths and weaknesses and no doubt a few differences will remain no matter what progress is made with the VFX system going forwards.
     
    hippocoder likes this.
  12. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    560
    Yea for sure, this is definitely something I've been looking into for when we switch over our project to HDRP. Currently, I'm just testing out everything I can to see when it will be suitable to make the jump for our case. I get what you're saying, it would be nice if HDRP had a temp shader (or do as you did and used shader graph to make one) to render particles in Shuriken until you are able to remake them in VFX Editor.

    It seems they would like the GPU to be used if possible rather than CPU so providing a shader or (promoting) Shuriken might have users using it for production when it's not recommended. If you upgrade to HDRP and your effects still work out of the box most people won't want to remake them unless it's really killing there perf. This is just what I think though we will have to wait for a dev to reply and see what the real reason for not providing a shader or really recommending the use of Shuriken.

    There are similar features in both so at least some effects might be able to be converted?
     
    hippocoder likes this.
  13. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    25,606
    Any ETA when VFX will arrive in package manager format so we can properly give feedback vs dipping in and out of github?
     
    elbows likes this.
  14. elbows

    elbows

    Joined:
    Nov 28, 2009
    Posts:
    2,360
    I dont want to go on too much about VFX in this thread, but since I mentioned signed distance fields I should probably say that they arent just for collisions either, the nature of signed distance fields make them useful for other things such as pretty efficient attraction. On this note there is a Conform to Signed Distance Field block which is a lot of fun. These things combined with ability to read vector fields from 3D textures makes the VFX system heaven for me :)

    SDFCollideComform.png
     
    hippocoder likes this.
  15. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    25,606
    The SDF would be particularly useful for generating outdoor shadows as well, so I would prefer it be something native to the shadow system for a first pass optionally, then feed that to VFX for further fun (as I need good performance!)

    Absolutely love what you're doing @elbows - any vids yet? ;)
     
  16. elbows

    elbows

    Joined:
    Nov 28, 2009
    Posts:
    2,360
    Yeah SDFs have been on my radar for all sorts of purposes for a while now, I'm not going to get carried away in my expectations for what ways they might be part of Unity one day but I live in hope.

    Cheers regarding my stuff, no video yet, I keep getting distracted by stuff and have spread myself too thin. eg at the weekend I decided that my fluid sim really needed to support torus shapes like VFX does, and changing my use of 3d texture emitters in it so that I can use the same SDF format textures for both the sim and the VFX system. Now I have those things working but my system doesnt support scaling and rotating yet, and there is a lot of fun to be had in the VFX system with rotating and scaling various things at runtime. But I dont see me having much time to do that this month so I shall have to knock out something more basic in a video at some point in the meantime.
     
    hippocoder likes this.
  17. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    560
    I'm gonna go a little off topic from HDRP as well because I remember watching a TextMesh Pro talk from either GDC or Unite Berlin where it was said that SDF will be integrated into the editor for it's text so maybe it will also be integrated for workflow at some point?

    After finding the video it seems it's from Unite Berlin and - Source as always
     
    hippocoder likes this.
  18. poa123

    poa123

    Joined:
    Jul 13, 2018
    Posts:
    22
    Please...
    Is there a way to "disable receive shadows" on specific objects (like water surfaces or transparent objects)?
     
  19. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    25,606
    Tried transparent render queue?
     
  20. discofhc

    discofhc

    Joined:
    Dec 18, 2017
    Posts:
    39
    Please, can you point me to this hdrp docs with volume fog info you mentioned? In the wiki i did not find any specific info.
    I have the same problem with volumetric fog (only when the light is casting shadows), and tweak the controller values did not help me.
    Maybe i am missing something, or maybe it is not ready yet :)

    Do you mean tweak the values on the Volumetric Fog Controller? No success :(
    Any news about the shadow filtering mentioned above?

    Thanks!
     
  21. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    25,606
    Volumetric Fog Controller. Works great here - perhaps you have a bug or are just making the range too big. Dont' have a small near range and don't have a big far range. Imagine a really crappy depth buffer.
     
  22. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,374
    @SebLagarde any plan to add a specular highlight value clamp into HDRP? just clamp the highest spec value to around 0.9 or something but keep the cubemap to use highest mip? looking a way to reduce specular fireflies :/
     
  23. theprotonfactor

    theprotonfactor

    Joined:
    Oct 10, 2014
    Posts:
    139
    I've been spending time porting shaders to HDRP and thus far everything works perfectly, essentially just copying the Lit shader and changing include files to custom ones works great, except for one shader that needs some niche functionality. It writes to a ComputeBuffer while rendering a mesh. However, with HDRP there doesn't seem to be any way to bind a uav during normal rendering or before a pass. It would be really cool if we could get some type of api to set a random write target before a renderer gets drawn or before a pass. Maybe something like Graphics.DrawMesh with a CommandBuffer parameter? I think I could also just modify the pipeline script directly to support this i.e. by invoking an event in the RenderForward method for example, but it would make upgrading HDRP very difficult.
     
  24. TerraUnity

    TerraUnity

    Joined:
    Aug 3, 2012
    Posts:
    729
    I second this, TerrainLit shader needs pixel and especially tessellation displacement embedded, I have no idea why they removed these features while porting this shader as it has been written on top of the Lit shader! I gave it a try to add tessellation into the TerrainLit shader but failed at the end due to a lot of missing includes and built-in functions.

    Currently we use the LayeredLit shader for the terrain, but now as terrains in 18.3 feature instanced rendering and per pixel normal blending, a proper merge of these shaders are needed. I couldn't even add instancing and pixel normals to the Lit shader as these shaders go through a lot of shared stuff which are not extendable and requires a lot of source code edits. Below is a screenshot of our terrain surface with tessellation:

    TerraWorld_TerrainShader.jpg


    No need to mention the value and realism of the extra dimension created by tessellation to bring life to those flat surfaces.
     
    rizu and Elecman like this.
  25. HD-MI

    HD-MI

    Joined:
    Mar 9, 2017
    Posts:
    13
    I have to third the above feedback. The lack of tessellation support of TerrainLit really is a downgrade visually to what was the previous method (even though LayeredLitTessellation was limited to 4 layers). Height map blending is supported, so perhaps tessellation could be too...? :)
     
  26. TerraUnity

    TerraUnity

    Joined:
    Aug 3, 2012
    Posts:
    729
    Does anyone know of a shader which works with DrawMeshInstancedIndirect in HDRP for GPU Instancing?

    DrawMeshInstanced works just fine but using it I'm sure creating hundreds of instanced patches due to 1024 limit is not ideal and performant in comparison to the Indirect method!
     
    bac9-flcl likes this.
  27. poa123

    poa123

    Joined:
    Jul 13, 2018
    Posts:
    22
    I had the same results as yours on earlier versions, but the results are excelent on the latest beta - 2018.3b5 (even with the same 3.3 HD version). I dont know why, but is working "properly" now :)
     
  28. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    25,606
    It's important we only ask for the base layer to have the displacement because otherwise it will be way too slow to be usable and it's probably not possible to engineer it so it can support n layers. Otherwise Unity might just refuse on account of it being way too slow.

    I can't see a situation where we need more than one anyway, and it's worth building around.
     
  29. Elecman

    Elecman

    Joined:
    May 5, 2011
    Posts:
    1,332
    Any news on the Unlit Emissive custom shader not working with EvaluateAtmosphericScattering()?

    Edit:
    Never mind. I should have used this:
    Code (CSharp):
    1. #define _SURFACE_TYPE_TRANSPARENT 1
    2. #define _BLENDMODE_ALPHA 1
    3. #define _ENABLE_FOG_ON_TRANSPARENT 1
    instead of this:
    Code (CSharp):
    1. #pragma shader_feature _SURFACE_TYPE_TRANSPARENT
    2. #pragma shader_feature _BLENDMODE_ALPHA
    3. #pragma shader_feature _ENABLE_FOG_ON_TRANSPARENT
    Additionally, I forgot to add the tag "Queue" = "Transparent".
     
    Last edited: Oct 19, 2018
  30. discofhc

    discofhc

    Joined:
    Dec 18, 2017
    Posts:
    39
    Three general questions about HD Pipe, please :)

    1 - So far the Volumetric Fog is great! But i wonder if we can wait for some solution allowing us to move a volumetric light, without leaving "the trail"...
    2 - Regarding particles, i know the new Visual Effects Editor will be the solution for the HD Pipe... HD lit particles (like dust being lit by lights) will be supportd in the earlier versions?
    3 - I saw some commits regarding "Realtime Raytracing Support"... what does it means? Related "only" to the new GPU Lightmapper?

    Thanks a lot!
     
  31. elbows

    elbows

    Joined:
    Nov 28, 2009
    Posts:
    2,360
    Even though I go on about how great the VFX system is, I would still be a little surprised if they dont support existing particle system in HDRP, because these two systems have different strengths and weaknesses.

    I'm sure we will hear more about their realtime raytracing plans soon, maybe at Unite LA. But it is already possible to tell that they will use this stuff for the same sort of things as were shown earlier this year by nvidia in regards to RTX - eg there is already a HDRP branch on github that is dealing with realtime reflections using raytracing.
     
    discofhc likes this.
  32. Korindian

    Korindian

    Joined:
    Jun 25, 2013
    Posts:
    444
    Would you mind sharing your opinion as to the different strengths and weaknesses?

    I've had a play with the VFX Editor in the experimental SRP from @rizu (thanks by the way!), and I found that there is only world and local (to the object the vfx script is on) space for the particles. For what I'm doing, I need local to another designated transform, like Shuriken has, and I'm hoping they're going to add that support to the VFX Editor. It's too bad there's no place to request that yet.
     
  33. Elecman

    Elecman

    Joined:
    May 5, 2011
    Posts:
    1,332
    When calling material.HasProperty("_MainTex") on the HD Lit shader, it returns true, but material.SetTexture("_MainTex", texture) fails because it should be "_BaseColorMap" instead.

    HasProperty("_MainTex") should return false.
     
  34. optimise

    optimise

    Joined:
    Jan 22, 2014
    Posts:
    456
    I cannot understand why removed Environment section from Lighting Window without providing the similar thing at Volume component. I still need the Environment section to tweak the scene.

    upload_2018-10-20_15-55-57.png
     
  35. rizu

    rizu

    Joined:
    Oct 8, 2013
    Posts:
    1,177
    People kept using that and then complaining when it didn't work as expected, removing the options from that dialog was inevitable. I'm curious though, what settings are you missing? Relevant parts should be in Volume Settings.
     
  36. Grimreaper358

    Grimreaper358

    Joined:
    Apr 8, 2013
    Posts:
    560
    The only thing the environment settings offered was to change skybox and adjust the ambient lighting intensity both of which are available on the Scene Settings/Volume Component. No functionality lost (Adding to this the Indirect Lighting control was added in 4.x.x before that it was auto-calculated for HDRP so if you are using a lover version then you gotta update your package)

    upload_2018-10-20_9-31-52.png
     
    optimise likes this.
  37. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    25,606
    I find the whole "baking sky" duplication of the main volume a complete chore really and would rather the volume also include baked data, if only to cut down on the sheer amount of freaking files I need to make minor changes with. It's actually less files in total if both were combined. I see there's an "include sun in baked..." option now which probably kind of helps that pain. I wouldn't know because docs are still from the 1960s.

    But having a whole asset just for baking with minor tweaks seems tits backward to me for organisation. I'm just having a moan though because it feels like uncertain ground to me. What do I put here? what do I not etc.
     
    dadude123 likes this.
  38. konsic

    konsic

    Joined:
    Oct 19, 2015
    Posts:
    688
    Will HDRP and LWRP support irradiance volumes for lighting ?
     
  39. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,374
    @SebLagarde Distortion also distort it's own material not the refraction buffer, is this intended? i believe it's only distort the refraction buffer in previous version.
    Distortion On
    dist_on.png
    Distortion Off
    dist_off.png
    as you can see the surface are affected by the distortion

    Also what is "Fade Scale" property for the Decal Projector? it seems doesn't have any effect
     
    Last edited: Oct 23, 2018
  40. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    915
    I was working on a small racing project using the standard 3D pipeline and i did some code cleanup and optimization in order to get smooth game play in build. I managed to do it ! However i wanted to try ( again ) the HDRP cause i really want to get better graphics but unfortunately i am always getting spikes in builds. The lags are different every time.

    I am getting a ton of spikes like these in the images below. I am not even sure where are these issues come from and it is hard to understand the profiled or at least to understand what could lead to these spikes.

    There is no a transparent object in scene except the car's windows which are visible all the time.

    upload_2018-10-24_17-19-37.png

    Another spike and this time the CPU seems to not be waiting for the GPU ( gpu seems smooth ). Where does this spike come from.

    upload_2018-10-24_17-22-37.png

    And yet another

    upload_2018-10-24_17-26-2.png

    And another

    upload_2018-10-24_17-29-44.png

    I don't understand how every spike is related to different thing and why .

    Any suggestions ( i tried setting on/off a lot of settings, batching, Graphics Jobs, disable object groups from scene ) ?
     
    Last edited: Oct 24, 2018
  41. bac9-flcl

    bac9-flcl

    Joined:
    Dec 5, 2012
    Posts:
    779
    I'd really like to know this too since we're hitting the exact same situation now.
     
  42. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,374
    can someone explain to me what is AxF Shader?
     
  43. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    25,606
    I think it's just standard shader for autodesk type materials?
     
  44. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,374
    Ah i see okay then, Thanks
     
  45. hippocoder

    hippocoder

    Digital Ape Moderator

    Joined:
    Apr 11, 2010
    Posts:
    25,606
  46. Reanimate_L

    Reanimate_L

    Joined:
    Oct 10, 2009
    Posts:
    2,374
    Huh. . . automotive rendering? for non realtime stuff it seems.
     
  47. sendspace

    sendspace

    Joined:
    Jul 24, 2016
    Posts:
    26
    is v5 really got released or its a mistake cuz i cant have it on package manager.
     
  48. Vagabond_

    Vagabond_

    Joined:
    Aug 26, 2014
    Posts:
    915
    As i understand, package manager will display only supported by your unity editor HDRPs.
    HDRP 5.0.0 requires Unity 2019.1 alpha !
     
  49. sendspace

    sendspace

    Joined:
    Jul 24, 2016
    Posts:
    26
    too bad unity is pushing the latest hdrp for the latest unity version. i wish we can use hdrp 5 in unity 2018.2 or beta.
     
  50. elbows

    elbows

    Joined:
    Nov 28, 2009
    Posts:
    2,360
    sendspace likes this.