SwitchMaterial

Overview


The SwitchMaterial allows you to switch between materials that are not part of the Dwa* material suite. The choice attribute is responsible for selecting the material.

mtl0 = DwaSolidDielectricMaterial("mtl0") {
    ["specular_model"] = 0,
}

mtl1 = DwaRefractiveMaterial("mtl1") {
    ["specular_model"] = 0,
}

mtl2 = DwaMetalMaterial("mtl2") {
    ["specular_model"] = 0,
}

switchMtl0 = SwitchMaterial("switchMtl0") {
    ["choice"] = 0,
    ["material0"] = mtl0,
    ["material1"] = mtl1,
    ["material2"] = mtl2,
}

Attribute Reference

General attributes

choice

Int
default: 0

which of the 64 inputs (0 to 63) to use

extra_aovs

Map
default: None

Bind this attribute to a 'ListMap' that contains references to ExtraAovMaps that specify additional outputs that can be assigned to a RenderOutput "light aov" result

invisible_refractive_cryptomatte

Bool
default: False

Indicates whether material should/should not appear in the refractive cryptomatte layers

label

String
default:

label used in material and light aovs

material0

Material
default: None

material input option

material1

Material
default: None

material input option

material10

Material
default: None

material input option

material11

Material
default: None

material input option

material12

Material
default: None

material input option

material13

Material
default: None

material input option

material14

Material
default: None

material input option

material15

Material
default: None

material input option

material16

Material
default: None

material input option

material17

Material
default: None

material input option

material18

Material
default: None

material input option

material19

Material
default: None

material input option

material2

Material
default: None

material input option

material20

Material
default: None

material input option

material21

Material
default: None

material input option

material22

Material
default: None

material input option

material23

Material
default: None

material input option

material24

Material
default: None

material input option

material25

Material
default: None

material input option

material26

Material
default: None

material input option

material27

Material
default: None

material input option

material28

Material
default: None

material input option

material29

Material
default: None

material input option

material3

Material
default: None

material input option

material30

Material
default: None

material input option

material31

Material
default: None

material input option

material32

Material
default: None

material input option

material33

Material
default: None

material input option

material34

Material
default: None

material input option

material35

Material
default: None

material input option

material36

Material
default: None

material input option

material37

Material
default: None

material input option

material38

Material
default: None

material input option

material39

Material
default: None

material input option

material4

Material
default: None

material input option

material40

Material
default: None

material input option

material41

Material
default: None

material input option

material42

Material
default: None

material input option

material43

Material
default: None

material input option

material44

Material
default: None

material input option

material45

Material
default: None

material input option

material46

Material
default: None

material input option

material47

Material
default: None

material input option

material48

Material
default: None

material input option

material49

Material
default: None

material input option

material5

Material
default: None

material input option

material50

Material
default: None

material input option

material51

Material
default: None

material input option

material52

Material
default: None

material input option

material53

Material
default: None

material input option

material54

Material
default: None

material input option

material55

Material
default: None

material input option

material56

Material
default: None

material input option

material57

Material
default: None

material input option

material58

Material
default: None

material input option

material59

Material
default: None

material input option

material6

Material
default: None

material input option

material60

Material
default: None

material input option

material61

Material
default: None

material input option

material62

Material
default: None

material input option

material63

Material
default: None

material input option

material7

Material
default: None

material input option

material8

Material
default: None

material input option

material9

Material
default: None

material input option

priority

Int
default: 0

The material's place in an order of precedence for overlapping dielectrics. A value of 0 means the priority should be ignored. Materials with lower numbers (higher priority) "override" materials with higher numbers (lower priority). To enable automatic removal of self-overlapping geometry, a non-zero priority must be set on the geometry's material.