code: function(r) {
        var llc = this.lowerLeftCoor(r),
            lrc = this.lowerRightCoor(r, llc);
  
        return [
          {x: r.x1, y: r.y1},
          {x: r.x2, y: r.y2},
          {x: llc.x, y: llc.y},
          {x: lrc.x, y: lrc.y}
        ];
      }
docs: Get the coordinates of all the corners of a rectangle from its top point.
  
  @param  {object} A rectangle defined by two points (x1, y1) and (x2, y2).
  @return {array}  An array of the four corners' coordinates (x, y).