code: public byte[][] getScaledMatrix(int xScale, int yScale) {
      byte[][] matrixOut = new byte[height * yScale][width * xScale];
      int yMax = height * yScale;
      for (int i = 0; i < yMax; i++) {
        matrixOut[yMax - i - 1] = matrix[i / yScale].getScaledRow(xScale);
      }
      return matrixOut;
    }
docs: /*
  public byte[][] getScaledMatrix(int scale) {
  return getScaledMatrix(scale, scale);
  }