Skip to content

Light Combiner Editor Tool#235

Merged
Cameron-Micka merged 52 commits intomicrosoft:mainfrom
Cameron-Micka:user/cameron-micka/static-light-export
Mar 14, 2025
Merged

Light Combiner Editor Tool#235
Cameron-Micka merged 52 commits intomicrosoft:mainfrom
Cameron-Micka:user/cameron-micka/static-light-export

Conversation

@Cameron-Micka
Copy link
Copy Markdown
Member

Overview

LightCombinerWindow is an EditorWindow class for Unity that provides a user interface to combine light maps with albedo textures or hijack another texture for lightmaps. This is useful for exporting scenes to glTF (or other formats) where lightmaps are not supported.

image

For example, here is a glTF (.glb) of a scene exported without combining lightmaps:
image

an example of a glTF (.glb) after performing the "Merge With Albedo" technique:
image

A follow up to this PR will be docs and samples.

Verification

As a reviewer, it is possible to check out this change locally by using the following
commands (substituting {PR_ID} with the ID of this pull request):

git fetch origin pull/{PR_ID}/head:name_of_local_branch

git checkout name_of_local_branch

@Cameron-Micka Cameron-Micka requested a review from Copilot March 14, 2025 21:17
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces a new Unity Editor component, CustomProbe, to adjust ambient light settings for scenes where lightmaps have been removed.

  • Adds a new CustomProbe class to set custom ambient light values via light probes.
  • Configures material property blocks to update renderer properties accordingly.
Comments suppressed due to low confidence (1)

com.microsoft.mrtk.graphicstools.unity/Runtime/LightCombiner/CustomProbe.cs:23

  • [nitpick] Consider renaming the local variable '_renderer' to 'renderer' since the underscore prefix is typically reserved for private fields, which may improve clarity.
var _renderer = GetComponent<Renderer>();

@Cameron-Micka Cameron-Micka merged commit 612d918 into microsoft:main Mar 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants