From 331b2ad4d602016f9bb3d03be759fd81fed50c10 Mon Sep 17 00:00:00 2001 From: hwc487 Date: Fri, 13 Apr 2012 07:08:42 -0700 Subject: Cloud Material --- js/lib/geom/rectangle.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'js/lib/geom') diff --git a/js/lib/geom/rectangle.js b/js/lib/geom/rectangle.js index f41c27f6..d4dd8033 100755 --- a/js/lib/geom/rectangle.js +++ b/js/lib/geom/rectangle.js @@ -12,7 +12,11 @@ var MaterialsModel = require("js/models/materials-model").MaterialsModel; // GL representation of a rectangle. // Derived from class GeomObj /////////////////////////////////////////////////////////////////////// -var Rectangle = function GLRectangle() { +var Rectangle = function GLRectangle() +{ + if (!MaterialsModel) + MaterialsModel = require("js/models/materials-model").MaterialsModel; + // CONSTANTS this.N_TRIANGLES = 15; -- cgit v1.2.3