changed: gcc8 base update
[opensg.git] / Examples / CSM / Shader / Lights / scene.osg
blobd9eec89a73330193d4c4917426010084e9abd713
1 #OSG V1.0 
3 Node
5   core Group {}
7   children
8   [
9     DEF L1Tr Node
10     {
11       core ComponentTransform
12       {
13         translation -10.0 5.0 5.0
14       }
15     }
16     DEF L2Tr Node
17     {
18       core ComponentTransform
19       {
20         translation 10.0 5.0 5.0
21       }
22     }
23     DEF L3Tr Node
24     {
25       core ComponentTransform
26       {
27         translation 0.0 -12.0 5.0
28       }
29     }
31     Node
32     {
33       core DEF PL1 PointLight
34       {
35         beacon USE L1Tr
37         ambient  0 0 0 1
38         diffuse  1 0 0 0
39         specular 1 1 1 1
40       }
41       children
42       [
43         Node 
44         {
45           core DEF PL2 PointLight
46           {
47             beacon USE L2Tr
48             
49             ambient  0 0 0 1
50             diffuse  0 1 0 0
51             specular 1 1 1 1
52           }
53           children
54           [
55             Node
56             {
57               core DEF PL3 PointLight
58               {
59                 beacon USE L3Tr
61                 ambient  0 0 0 1
62                 diffuse  0 0 1 0
63                 specular 1 1 1 1
64               }
65               children
66               [
67                 Node 
68                 {
69                   core MaterialGroup
70                   {
71                     material ChunkMaterial
72                     {
73                       chunks
74                       [
75                         MaterialChunk
76                         {
77                           ambient   0.1 0.1 0.1 1.0
78                           diffuse   0.3 0.3 0.3 1.0
79                           specular  0.8 0.8 0.8 1.0
80                           shininess 100
81                           lit       TRUE
82                         }
84                         SimpleSHLChunk
85                         {
86                           variables ShaderProgramVariables
87                           {
88                             proceduralVariables
89                             [
90                               ShaderVariableOSG
91                               {
92                                 name "OSGLight0Active"
93                               }
94                               ShaderVariableOSG
95                               {
96                                 name "OSGLight1Active"
97                               }
98                               ShaderVariableOSG
99                               {
100                                 name "OSGLight2Active"
101                               }
102                             ]
103                           }
105                           vertexShader 
106                           [
107                             ShaderProgramFile
108                             {
109                               shaderType GL_VERTEX_SHADER
111                               programUrl "lights.vp"
112                             }
113                           ]
115                           fragmentShader 
116                           [
117                             ShaderProgramFile
118                             {
119                               shaderType GL_FRAGMENT_SHADER
121                               programUrl "lights.fp"
122                             }
123                           ]
124                         }
125                       ]
126                     }
127                   }
128                   children
129                   [
130                     Node
131                     {
132                       core Inline
133                       {
134                         url "../../Models/sphere.wrl"
135                       }
136                     }
137                   ]
138                 }
139               ]
140             }
141           ]
142         }
143       ]
144     }
145   ]