Stephane Laroche
3187dab5
New StackLit forward only material: Can serve as a basic template for a new lit material creation with a different lighting code path glued in material.hlsl.
Only supports base unlit material parameters with the addition of : analytical lights with a diffuse lambert BSDF, interpolated geometric normal and double sided option.
7 年前
sebastienlagarde
66ff4e4a
Add normal view debug mode
7 年前
Stephane Laroche
ad31624f
-Add base 2 lobe specular GGX along with inputs and UI.
-Fix missing base* keyword setting and gui virtual function callbacks (in addition to their abstract equivalent already handled) (see BaseUnlitUI)
7 年前
Sebastien Lagarde
4a161d5a
HDRenderPipeline: Sharing envlight code
7 年前
sebastienlagarde
fbf1ccab
Remove indirect GTAO debug mode
7 年前
Stephane Laroche
61ee5830
Merge branch 'master' into stacklit
7 年前
Stephane Laroche
32c8ec15
-Add slight changes from similar Lit material code changes.
7 年前
Stephane Laroche
959a0e88
-Add environment lighting that accounts for our 2 lobes base layer, for reflections only for now.
7 年前
Stephane Laroche
8a39a724
Fix roughness transfer from bsdfdata to precalculated data.
7 年前
sebastienlagarde
3f91b8e1
HDRenderPipeline: Remove sampleDirectionDiscardWS in reflection (not used)
7 年前
Stephane Laroche
e5b6c4fb
Implement vertically layered BSDF model with anisotropy.
7 年前
GitHub
413e6a25
Merge pull request #1232 from Unity-Technologies/remove-sampleDirectionDiscardWS
HDRenderPipeline: Remove sampleDirectionDiscardWS in reflection (not used)
7 年前
Stephane Laroche
10f8090a
Merge branch 'stacklit' into stacklit_vl_merge
# Conflicts:
# ScriptableRenderPipeline/Core/CoreRP/ShaderLibrary/BSDF.hlsl
# ScriptableRenderPipeline/HDRenderPipeline/HDRP/Editor/Material/StackLit/StackLitUI.cs
# ScriptableRenderPipeline/HDRenderPipeline/HDRP/Material/StackLit/StackLit.hlsl
# ScriptableRenderPipeline/HDRenderPipeline/HDRP/Material/StackLit/StackLit.shader
# ScriptableRenderPipeline/HDRenderPipeline/HDRP/Material/StackLit/StackLitData.hlsl
7 年前
Stephane Laroche
6a42ea81
Uniformity, dual lobe material feature keyword.
7 年前
Stephane Laroche
42284de1
Cosmetics, auto-merge cleanup (VolumetricLighting.cs vs compute should be fixed though)
7 年前
Stephane Laroche
e982f099
Some modifications (not enabled for now) to try to handle anisotropy better.
7 年前
Stephane Laroche
031ca429
Fix static compilation issues.
7 年前
Jean-François F Fortin
6f2a25cc
SSS + Transmission
7 年前
sebastienlagarde
96365a48
Rename RoughnessToAnisotropy to ConvertRoughnessToAnisotropy
7 年前
sebastienlagarde
bac63c51
Add ambient occlusion properties on Stacklit
7 年前
sebastienlagarde
f5c025d5
Add support for ambient occlusion on stacklit + misc fix in UI
7 年前
Stephane Laroche
f022bbc2
Merge branch 'master' into stacklit
7 年前
Stephane Laroche
1ad0a84c
wip
7 年前
Stephane Laroche
c286bf9c
wip
7 年前
Stephane Laroche
d760c6a1
Working analytical lights with anisotropy and coat, per light recalculations should work.
7 年前
Stephane Laroche
d2ea2ac9
Fix typo.
7 年前
Stephane Laroche
088b48f1
Bug fix (swapped a lobe id somewhere, looks better now), vlayering anisotropic "matching" hack, energy compensation per lobe, debug mode
7 年前
Jean-François F Fortin
9f8080f8
Added SSS (works, untested) and Transmission (untested).
7 年前
Stephane Laroche
3175d3e9
Fix: use top angle for LambdaV for clearcoat if an option is enabled to use different angles for top and bottom interfaces.
7 年前
Stephane Laroche
863da95a
(alignments)
7 年前
sebastienlagarde
c53df482
Fix various problem + add DielectricIor
7 年前
Stephane Laroche
9e86a357
Enable coat effect on diffuse lighting.
7 年前
sebastienlagarde
877657e9
Add Transmisison support to stacklit
7 年前
sebastienlagarde
3094fbeb
Fix issue with smoothness and sky lighting
7 年前
Stephane Laroche
0bff25c5
Independent Coat Normap Map : WIP
7 年前
Stephane Laroche
0fe9e92a
Independent Coat Normal Map: WIP: Most of the work is there, need cleanup and fix artefacts (probably need better patching of EvalBSDF functions or...)
7 年前
Jean-François F Fortin
994a42d3
Added geometric filtering for spec AA.
7 年前
Stephane Laroche
ed9250ea
Fix vlayering recompute per light option and make it a shader feature for easier testing.
7 年前
Stephane Laroche
7c5c2c6d
Expose more config options and make them work with dual normal maps. Streamline more code for BSDF evaluation wrt all config switches.
7 年前
Jean-François F Fortin
ec47ffff
Added the texture filtering for normal maps + the roughness filtering. (DISABLED+UNTESTED)
7 年前
Stephane Laroche
43efd730
Finish testing dual normals: push N dependent geometric term inside BSDF( ) evaluation, use geometric normals for receiver bias and base normal (for now) for diffuse, SSS and transmission.
7 年前
Stephane Laroche
1ba253a4
Fix normal map filtering for both base roughnesses and coat normal map.
7 年前
Tim Cooper
fafb59af
Run code formatter.
7 年前
Sebastien Lagarde
2871eb29
Update specularAA handling in stacklit
7 年前
Stephane Laroche
6830f5c5
Added iridescence on the bottom of the stack (needs a bit of work still, had to hack to avoid TIR, dual normal will still cause artefacts because of the fake refraction through the geometric normal. Also to check/fix f0 handling and conversion).
7 年前
sebastienlagarde
423674f8
Revert #1466 and fix issue with specular lighting mode not working
The planar reflection was not working anymore, so revert 1466
7 年前
Stephane Laroche
f7d6e7db
Merge remote-tracking branch 'mainrepo/master' into StackLit2
7 年前
Stephane Laroche
82cd91dd
Including TIR in iridescence F reflectance, useful when using dual normal maps (only for stacklit).
7 年前
sebastienlagarde
5fd64011
Prepare NormalBuffer support in forward
7 年前
Sebastien Lagarde
96a16f75
Fix various compilation error
7 年前
Sebastien Lagarde
4d25d4a1
Add normal buffer to directional shadow and forwar
+ add poistion input to prototype of ConvertSurfaceDataToBSDFData
7 年前
sebastienlagarde
5afa37a8
HDRP: Visualize shadow map minor ident
7 年前
sebastienlagarde
0e0c9931
Merge branch 'master' into normal-buffer-support
7 年前
sebastienlagarde
03a88ecd
change perceptualSmoothness - perceptualRoughness
7 年前
Stephane Laroche
7842bbf8
Merge remote-tracking branch 'mainrepo/master' into StackLit2
7 年前
Sebastien Lagarde
ba6fd164
Factor Lit and StackLit code
Factor code from Lit and stacklit to MaterialEvaluation.hlsl
Move AO function in LightEvalaution.hlsl to MaterialEvaluation.hlsl
7 年前
Stephane Laroche
a49a696e
Merge branch 'master' into StackLit2
7 年前
Stephane Laroche
333ce3d1
StackLit : Working LTC Area lights. Fixed GetBakedDiffuseLighting to use the diffuseEnergy factor calculated when coat is enabled, along with SSS texturing modes.
7 年前
Antoine Lelievre
f8468529
Removed contact shadows on light transmission
7 年前
Antoine Lelievre
38287b48
Fixed contact shadows with light transmission
7 年前
Antoine Lelievre
c8a540d3
Fixed contact shadows on transparent objects
7 年前
sebastienlagarde
aa5363e0
Refactor tranmission and lightEvaluation code to have more cleaner code
7 年前
sebastienlagarde
86dfa8ec
Take into account feedback
7 年前
sebastienlagarde
1fa4d8c6
Mpore update with feedback
7 年前
Sebastien Lagarde
162b8ee9
Draft of refactoring of SSS and Transmission code, to share more code
7 年前
sebastienlagarde
870dbb61
Large refactor of transmission code to share it between material
7 年前
sebastienlagarde
ed6aecc7
Update Changelog and integrate PR feedback
7 年前
Stephane Laroche
f46075fb
Merge remote-tracking branch 'mainrepo/master' into StackLit2
# Conflicts:
# com.unity.render-pipelines.high-definition/HDRP/Material/Lit/Lit.hlsl
# com.unity.render-pipelines.high-definition/HDRP/Material/StackLit/StackLit.cs.hlsl
# com.unity.render-pipelines.high-definition/HDRP/Material/StackLit/StackLit.hlsl
7 年前
Stephane Laroche
9580854c
Fix a merge omission that disabled diffuse light from area lights
7 年前
sebastienlagarde
777bb5a5
HDRP: Lighting - Fix shader warning + Remove comment
7 年前
Sebastien Lagarde
8146a8c1
Share punctual light vector calculation code (GetPunctualLightVectors) + cleanup
7 年前
Sebastien Lagarde
629a7b7e
HDRP: Factor anisotropy code
7 年前
Stephane Laroche
27bea6de
Fix anisotropy.
7 年前
Sebastien Lagarde
d4c5fff5
HDRP: Add support of detail normal and smoothness to Stacklit
- Fix an issue in the UI with Remap and Range
- Add detail normal and smoothness map (overlay for smoothness)
- Fix compilation issue with GetGGXAnisotropicModifiedNormalAndRoughness refactor
7 年前
Stephane Laroche
21f0e8a4
Fix anisotropy.
This will be refactored as the needed array organization stabilize.
7 年前
Stephane Laroche
a4accf0c
SPTD based specular occlusion enabled in Lit material.
-Full SPTD code in /SphericalCapPivot, with documentation and tweaks to reference glsl code:
-Methods are in worldspace
-ComputeVS should not be multiplied by FGD (see comments)
-Stability issue with pivot transforming extreme cases of spherical caps
-Specular occlusion with cone-cone method: further options and tweaks to the original method.
-Refactoring of common orthogonal basis aligned with reflection plane (view-normal)
6 年前
sebastienlagarde
1555fbce
HDRP: More renaming for camera relative rendering (rename lightDefinition)
6 年前
Stephane Laroche
cbb9a885
Merge branch 'master' into StackLit2
# Conflicts:
# com.unity.render-pipelines.high-definition/HDRP/Material/StackLit/StackLit.hlsl
6 年前
Stephane Laroche
6a34e975
StackLit: proper ambient occlusion, specular occlusion and bentnormals
-Make the AO and SO path clean since we're forward based (no more double occlusion and occlusion on emissive).
-Configurable per-lobe specular occlusion on environment lights and debug options. Also use GTAOMultiBounce tint in the context of vertical layering.
(Enabling SO is orthogonal to bentnormals presence, the choosen algo for the data-based occlusion will use the normal or bentnormal if present)
-Bentnormal map which piggy backs on all normal map parameters (add UI code to allow this too)
-Fix GGX energy compensation term application
-Reuse some Lit shader_feature keywords
6 年前
Stephane Laroche
12aebb34
StackLit: New base parametrization and dual lobe hazy gloss parametrization.
-SpecularColor mode now selectable
-Dual specular lobe has two parametrization: direct and hazy gloss (Barla et al. 2018-07)
-UI changes to support multiple parametrizations and also avoid useless keyword switching in some instances
-Additional note on specular occlusion and anisotropy
6 年前
Stephane Laroche
09d96a6f
Add a UIBufferedProperty and implement a limiting option for hazy gloss parametrization's output f0 for dielectrics when metallic input is used.
Also move static property forwarding setup functions in BaseMaterialUI.
6 年前
Stephane Laroche
8e152582
Add secondary lobe independent anisotropy control (also used for hazeExtent in the hazyGloss parametrization of dual specular lobes)
6 年前
sebastienlagarde
8a207497
HDRP: Fix warning in shader stacklit
6 年前
sebastienlagarde
092d7fe0
Fix warning in stacklit.hlsl
6 年前
Stephane Laroche
73aab246
Merge branch 'hdrp/staging' into StackLit2_TrunkTest
# Conflicts:
# com.unity.render-pipelines.high-definition/HDRP/Material/StackLit/StackLit.cs
6 年前
GitHub
80d748f5
Add light linking support ( #1758 )
* HDRP: Add support of light layering for forward (first draft)
TODO:
- Test instancing
- Check perf
- add an option to disable light layer support + in frameSettings
- add deferred rendering support (mean add an optional extra GBuffer)
* Add LightLinking support (version 1 - compile)
This PR add support of LightLayers feature.
To use it, setup mask renderingLayers on renderers and LightLayers on a lights. If a logical and of both give a non 0 value, the light is apply, otherwise it isn't.
This mean that by default LightLayers is 1 and RenderingLayers is 1. Then user can say LightLayers is only 2 and it will only affect renderingLayers with 2 or 3 mask value.
LightLayers require an extra GBuffer in deferred, mean it have extra bandwidth and memory cost.
LightLayers once enabled in HDRPAsset with SupportLightLayers can be control by FrameSettings. Mean a camera can enable extra RT only for an in game cinematic.
This PR refactor...
6 年前
Sebastien Lagarde
f0619d1d
Handle emissiveColor separate of bakeDiffuseLighting in forward
6 年前
Sebastien Lagarde
93ff11d4
Correctly split AO to not affect emissive in forward
6 年前
Sebastien Lagarde
56790568
Refactor GetBakedDiffuseLighting
- Shader code change: Rename GetBakedDiffuseLighting to ModifyBakedDiffuseLighting. This function now handle lighting model for transmission too. Lux meter debug mode is factor outisde.
- Shader code change: GetBakedDiffuseLighting is not call anymore in GBuffer or forward pass, including the ConvertSurfaceDataToBSDFData and GetPreLightData, this is done in ModifyBakedDiffuseLighting now
- Shader code change: Added a backBakeDiffuseLighting to BuiltinData to handle lighting for transmission
- Shader code change: Material must now call InitBuiltinData (Init all to zero + init bakeDiffuseLighting and backBakeDiffuseLighting ) and PostInitBuiltinData
- Update shader graph associate code
6 年前
sebastienlagarde
b55f5754
Fix issue with shader graph - wasn't compiling
6 年前
Antoine Lelievre
779c6cd9
Added indirect light control for stacklit
6 年前
Antoine Lelievre
71ec7369
Merge HDRP/staging
6 年前