MCPcopy Create free account
hub / github.com/SuperMap/iClient-JavaScript / Plane

Function Plane

libs/mapv/mapv.3d.js:423–437  ·  view source on GitHub ↗
(GL, obj)

Source from the content-addressed store, hash-verified

421 inherits(Plane, _Obj);
422
423 function Plane(GL, obj) {
424 classCallCheck(this, Plane);
425
426 var _this = possibleConstructorReturn(this, (Plane.__proto__ || Object.getPrototypeOf(Plane)).call(this, GL, obj));
427
428 _this.width = obj.width || 10.0;
429 _this.height = obj.height || 10.0;
430
431 var color = _this.color;
432
433 _this.verticesColors = new Float32Array([-_this.width / 2, +_this.height / 2, 0.0, color[0], color[1], color[2], +_this.width / 2, +_this.height / 2, 0.0, color[0], color[1], color[2], +_this.width / 2, -_this.height / 2, 0.0, color[0], color[1], color[2], -_this.width / 2, -_this.height / 2, 0.0, color[0], color[1], color[2]]);
434
435 _this.indices = new Uint8Array([0, 1, 2, 0, 2, 3]);
436 return _this;
437 }
438
439 createClass(Plane, [{
440 key: 'render',

Callers

nothing calls this directly

Calls 2

classCallCheckFunction · 0.70

Tested by

no test coverage detected