ViewportMode

A viewport mode: a named set of thirteen switches that decide how the viewport draws a scene (viewport-shading-modes §VSMA-1).

In the namespace construct::model. Declared in src/libs/libconstruct/construct/model/ViewportMode.hpp.

Detailed description

A mode is one YAML record, as a material is:

id: clay
name: Clay
icon: ":/icons/construct/sphere.svg"
switches:
  pathTracing: off
  materials: clay
  ...

Each switch takes one of the values that values() lists. The value scene passes the scene's setting through, and a switch that the record does not name has it. A mode of thirteen scene switches shows what a render of the scene writes.

The viewport reads a mode through settings::ViewportModeOverlay. A render job never reads it.

In this section