Skip to content

Commit

Permalink
Fix Light Intensity UI Prefab Override Application (1299563) (#3061)
Browse files Browse the repository at this point in the history
* Fixed Render Graph immediate mode. (#3033)

Co-authored-by: Sebastien Lagarde <sebastien@unity3d.com>

* Fix issue with shadow mask and area lights (#3019)

* Not checking NdotL since it's not really valid for area lights (We have multiple valid light directions, not one)

* Changelog

Co-authored-by: sebastienlagarde <sebastien@unity3d.com>

* Fix issue with capture callback (now includes post processing results) (#3035)

Co-authored-by: sebastienlagarde <sebastien@unity3d.com>

* [HDRP] Fix decal draw order for ShaderGraph decal materials (#3018)

* Fixed ShaderGraph decal draw order

* Updated changelog

Co-authored-by: sebastienlagarde <sebastien@unity3d.com>

* Fixed various Look Dev issues after exiting Playmode (#2956)

* Fixed access to invalid Contexts references after exiting playmode.

* Fixed comparison gizmo after playmode.

* Fixes from PR feedback

* Apply the fix

* Changelog

* Mofified approach to the fix, this time also fixing override saving of light unit

* Use more precise rect line offset calculation

* Update CHANGELOG.md

Co-authored-by: JulienIgnace-Unity <julien@unity3d.com>
Co-authored-by: Sebastien Lagarde <sebastien@unity3d.com>
Co-authored-by: FrancescoC-unity <43168857+FrancescoC-unity@users.noreply.github.com>
Co-authored-by: Pavlos Mavridis <pavlos.mavridis@unity3d.com>
Co-authored-by: Antoine Lelievre <antoinel@unity3d.com>
  • Loading branch information
6 people committed Jan 14, 2021
1 parent b21345b commit 9581f38
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
1 change: 1 addition & 0 deletions com.unity.render-pipelines.high-definition/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- Fixed GC allocations from XR occlusion mesh when using multipass.
- Fixed XR depth copy when using MSAA.
- Fixed after post process custom pass scale issue when dynamic resolution is enabled (case 1299194).
- Fixed an issue with light intensity prefab override application not visible in the inspector (case 1299563).

### Changed
- Change the source value for the ray tracing frame index iterator from m_FrameCount to the camera frame count (case 1301356).
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -599,11 +599,18 @@ static void DrawLightIntensityGUILayout(SerializedHDLight serialized, Editor own
Rect labelRect = lineRect;
labelRect.width = EditorGUIUtility.labelWidth;

// Expand to reach both lines of the intensity field.
var interlineOffset = EditorGUIUtility.singleLineHeight + 2f;
labelRect.height += interlineOffset;

//handling of prefab overrides in a parent label
GUIContent parentLabel = s_Styles.lightIntensity;
parentLabel = EditorGUI.BeginProperty(labelRect, parentLabel, serialized.intensity);
parentLabel = EditorGUI.BeginProperty(labelRect, parentLabel, serialized.lightUnit);
parentLabel = EditorGUI.BeginProperty(labelRect, parentLabel, serialized.intensity);
{
// Restore the original rect for actually drawing the label.
labelRect.height -= interlineOffset;

EditorGUI.LabelField(labelRect, parentLabel);
}
EditorGUI.EndProperty();
Expand Down

0 comments on commit 9581f38

Please sign in to comment.