GafferHQ / gaffer

Gaffer is a node-based application for lookdev, lighting and automation
http://www.gafferhq.org
BSD 3-Clause "New" or "Revised" License
958 stars 206 forks source link

Viewer : Light texture visualisation improvements #3407

Closed johnhaddon closed 4 years ago

johnhaddon commented 5 years ago

Summary

Gaffer should visualise area based lights according to their illumination properties. Textures should be displayed in the positions and proportions they will be rendered with.

User story

What

As a lighter, I would like to be able to see (at a glance) the lighting configuration of my scene.

Why

Feature proposal

Defining the following as "area based lights": quad_light, disk_light, cylinder_light and skydome_light.

quad lights skydome

  1. Area based lights will be rendered to indicate their color, and the effects of a connected shading network where applicable.
  2. Area based lights will be selectable by clicking on any part of their representation.
  3. A global Viewer > Drawing > Area Lights > Shaded toggle will allow shading for area based lights to be controlled for all lights. When this is disabled lights will revert to their yellow outline only.
  4. Each light will have an option in its Visualisation tab to disable shaded previews for that specific light.

"Shaded" mode means:

  1. Lights will render their color as a solid fill (as per the left hand quad light in the images above). This will not include the effects of intensity or exposure or any other light parameters that affect the output illumination. Think "everything up to the color plug".
  2. When color is connected to a shading network, the following will be visualised:
    • OSL-based networks <TBC, how P, s, t, etc... are populated>
    • Arnold shader networks will support finding the first aiImage node and using that.
    • <TBC st/offsets>
      1. For envionment and infinitely sized lights such as skydome_light:
      2. The dome will be 'inside out' (as above).
      3. The Visualiser Scale plug can be used to adjust the size of the dome.
      4. Upon creation sky_dome lights will default to a Visualiser Scale of 1000. This can be customised per-facility/etc... via the usual means.

Technical Notes

This old PR from Matti has some work in this direction, so we should see what we can salvage from it as we go : https://github.com/GafferHQ/gaffer/pull/3257.

themissingcow commented 4 years ago

Note: We need to determine if we need to support https://docs.arnoldrenderer.com/display/NodeRef/skydome_light#skydome_light-format