src/classes/sigma.classes.edgequad.js
function _quadIndexes(rectangle, quadCorners) {
    var indexes = [];

    // Iterating through quads
    for (var i = 0; i < 4; i++)
      if ((rectangle.x2 >= quadCorners[i][0].x) &&
          (rectangle.x1 <= quadCorners[i][1].x) &&
          (rectangle.y1 + rectangle.height >= quadCorners[i][0].y) &&
          (rectangle.y1 <= quadCorners[i][2].y))
        indexes.push(i);

    return indexes;
  }
function _quadIndexes(rectangle, quadCorners) {
    var indexes = [];

    // Iterating through quads
    for (var i = 0; i < 4; i++)
      if ((rectangle.x2 >= quadCorners[i][0].x) &&
          (rectangle.x1 <= quadCorners[i][1].x) &&
          (rectangle.y1 + rectangle.height >= quadCorners[i][0].y) &&
          (rectangle.y1 <= quadCorners[i][2].y))
        indexes.push(i);

    return indexes;
  }
function _quadIndexes ( rectangle , quadCorners ) { var indexes = [ ] ; // Iterating through quads for ( var i = 0 ; i < 4 ; i ++ ) if ( ( rectangle . x2 >= quadCorners [ i ] [ 0 ] . x ) && ( rectangle . x1 <= quadCorners [ i ] [ 1 ] . x ) && ( rectangle . y1 + rectangle . height >= quadCorners [ i ] [ 0 ] . y ) && ( rectangle . y1 <= quadCorners [ i ] [ 2 ] . y ) ) indexes . push ( i ) ; return indexes ; }
Get a list of indexes of nodes containing an axis-aligned rectangle

@param  {object}  rectangle   A rectangle defined by two points (x1, y1),
(x2, y2) and height.
@param  {array}   quadCorners An array of the quad nodes' corners.
@return {array}               An array of indexes containing one to
four integers.
Get a list of indexes of nodes containing an axis - aligned rectangle