From 747ab5a431b7f80824f2fbdbeed2c23f1886a410 Mon Sep 17 00:00:00 2001 From: alteredq Date: Thu, 7 Jun 2012 22:01:53 +0200 Subject: [PATCH] Fixed GL warnings in scene loader example. For some reason before it didn't make troubles when sharing the same geometry for objects with materials requiring different attributes. I guess order of initialization may had changed. Fixes #1876. --- examples/scenes/test_scene.js | 28 ++++++++++++++++++++++++++-- 1 file changed, 26 insertions(+), 2 deletions(-) diff --git a/examples/scenes/test_scene.js b/examples/scenes/test_scene.js index f14d0d7418..ea6f931e50 100644 --- a/examples/scenes/test_scene.js +++ b/examples/scenes/test_scene.js @@ -11,7 +11,7 @@ "objects": { "cube1" : { - "geometry" : "cube", + "geometry" : "cubeNormals", "materials": [ "lambert_red" ], "position" : [ 0, 0, 0 ], "rotation" : [ 0, -0.3, 0 ], @@ -20,7 +20,7 @@ }, "cube2" : { - "geometry" : "cube", + "geometry" : "cubeWire", "materials": [ "basic_white" ], "position" : [ 0, 0, 0 ], "rotation" : [ 0, -0.3, 0 ], @@ -153,6 +153,30 @@ "sides" : { "px": true, "nx": true, "py": true, "ny": true, "pz": true, "nz": true } }, + "cubeNormals": { + "type" : "cube", + "width" : 10, + "height": 10, + "depth" : 10, + "segmentsWidth" : 1, + "segmentsHeight" : 1, + "segmentsDepth" : 1, + "flipped" : false, + "sides" : { "px": true, "nx": true, "py": true, "ny": true, "pz": true, "nz": true } + }, + + "cubeWire": { + "type" : "cube", + "width" : 10, + "height": 10, + "depth" : 10, + "segmentsWidth" : 1, + "segmentsHeight" : 1, + "segmentsDepth" : 1, + "flipped" : false, + "sides" : { "px": true, "nx": true, "py": true, "ny": true, "pz": true, "nz": true } + }, + "plane": { "type" : "plane", "width" : 10, -- GitLab