-
Notifications
You must be signed in to change notification settings - Fork 0
/
SkinnedPbrEffect.qml
39 lines (34 loc) · 1.13 KB
/
SkinnedPbrEffect.qml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import Qt3D.Core 2.10
import Qt3D.Render 2.10
import Qt3D.Input 2.0
import Qt3D.Extras 2.10
Effect {
id: skinnedPbrEffect
parameters: [
Parameter { name: "baseColor"; value: "red" },
Parameter { name: "metalness"; value: 0.1 },
Parameter { name: "roughness"; value: 0.2 }
]
techniques: [
Technique {
filterKeys: FilterKey { name: "renderingStyle"; value: "forward" }
graphicsApiFilter {
api: GraphicsApiFilter.OpenGL
majorVersion: 3
minorVersion: 1
profile: GraphicsApiFilter.CoreProfile
}
renderPasses: RenderPass {
shaderProgram: ShaderProgram {
id: prog
vertexShaderCode: loadSource(Qt.resolvedUrl("skinnedPbr.vert"))
}
ShaderProgramBuilder {
shaderProgram: prog
fragmentShaderGraph: "metalrough.frag.json"
enabledLayers: ["baseColor", "metalness", "roughness", "ambientOcclusion", "normal"]
}
}
}
]
}