Skip to content

Commit

Permalink
addressed @fedarko's comments
Browse files Browse the repository at this point in the history
  • Loading branch information
kwcantrell committed Oct 28, 2020
1 parent 3037f2e commit f515617
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions empress/support_files/js/drawer.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
define(["glMatrix", "Camera"], function (gl, Camera) {
define(["underscore", "glMatrix", "Camera"], function (_, gl, Camera) {
// Shaders used in Drawer
var vertShaderTxt = [
"precision mediump float;",
Expand Down Expand Up @@ -249,7 +249,7 @@ define(["glMatrix", "Camera"], function (gl, Camera) {
* @param {Number} vertSize The size of the vertex for webgl
*/
Drawer.prototype.bindBuffer = function (buffer, buffType, vertSize) {
if (this.BUFF_TYPES.indexOf(buffType) == -1) {
if (!_.contains(this.BUFF_TYPES, buffType)) {
throw "Invalid buffer type";
}

Expand Down Expand Up @@ -288,9 +288,9 @@ define(["glMatrix", "Camera"], function (gl, Camera) {
};

/**
* Fills the buffer used to draw the tree
* Fills the buffer used to draw the tree.
*
* @param {Array} data The coordinate and color data to fill tree buffer
* @param {Array} data The coordinates [x, y, ...] to fill treeCoordBuffr
*/
Drawer.prototype.loadTreeCoordsBuff = function (data) {
data = new Float32Array(data);
Expand All @@ -301,7 +301,7 @@ define(["glMatrix", "Camera"], function (gl, Camera) {
/**
* Fills the buffer used to draw the tree
*
* @param {Array} data The coordinate and color data to fill tree buffer
* @param {Array} data The color data to fill treeColorBuff
*/
Drawer.prototype.loadTreeColorBuff = function (data) {
data = new Float32Array(data);
Expand Down
2 changes: 1 addition & 1 deletion tests/test-circular-layout-computation.js
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ require(["jquery", "BPTree", "BiomTable", "Empress"], function (
// the above calculation can be found at
// Empress._numSampToApproximate()
ok(Math.abs(coords[250] + 2) < 1.0e-15); // end arc x
ok(Math.abs(coords[251]) < 1.0e-15);
ok(Math.abs(coords[251]) < 1.0e-15); //end arc y
});
});
});

0 comments on commit f515617

Please sign in to comment.