wonder.js
Version:
29 lines (25 loc) • 1.58 kB
JavaScript
;
var Log$WonderLog = require("wonder-log/lib/js/src/Log.js");
var Contract$WonderLog = require("wonder-log/lib/js/src/Contract.js");
var StateDataMain$Wonderjs = require("../../../state/main/data/StateDataMain.js");
var IsDebugMainService$Wonderjs = require("../../../state/main/state/IsDebugMainService.js");
var ArrayService$WonderCommonlib = require("wonder-commonlib/lib/js/src/ArrayService.js");
var JudgeService$WonderCommonlib = require("wonder-commonlib/lib/js/src/JudgeService.js");
function disableVertexAttribArray(gl, vertexAttribHistoryArray) {
Contract$WonderLog.requireCheck((function (param) {
return Contract$WonderLog.test(Log$WonderLog.buildAssertMessage("vertexAttribHistory:array(\'a) has no hole", "not"), (function (param) {
return Contract$WonderLog.Operators[/* = */0](vertexAttribHistoryArray.filter(JudgeService$WonderCommonlib.isBool).length, vertexAttribHistoryArray.length);
}));
}), IsDebugMainService$Wonderjs.getIsDebug(StateDataMain$Wonderjs.stateData));
vertexAttribHistoryArray.forEach((function (isEnable, pos) {
if (isEnable) {
gl.disableVertexAttribArray(pos);
return /* () */0;
} else {
return Log$WonderLog.fatal(Log$WonderLog.buildFatalMessage("disableVertexAttribArray", "should always be true", "", "", ""));
}
}));
return ArrayService$WonderCommonlib.createEmpty(/* () */0);
}
exports.disableVertexAttribArray = disableVertexAttribArray;
/* Log-WonderLog Not a pure module */