private int[][] getCharacterPositions(OCRImage image, int brightness, boolean spaces, int spaceDistance) {
		int[][] pos = new int[getEstimatedLength(image, brightness, spaces, spaceDistance)][4];
		int count = 0, lastX = 0;
		for(int x = 0; x < image.getWidth(); x++) {
			for(int y = 0; y < image.getHeight(); y++) {
				int color = image.getData()[(y * image.getWidth()) + x];
				if(getBrightness(color, brightness)) {
					if(lastX == 0)
						lastX = x;
					if(x - lastX > 1)
						count++;
					if(x - lastX > spaceDistance && spaces) {
						int temp = ((x - lastX) / spaceDistance);
						for(int i = 0; i < temp; i++) {
							pos[count][0] = -1;
							pos[count][1] = -1;
							pos[count][2] = -1;
							pos[count][3] = -1;
							count++;
						}
						lastX = x;
					}
					lastX = x;
					if(pos[count][0] == 0) {
						pos[count][0] = x;
						pos[count][1] = y;
					}
					if(x < pos[count][0])
						pos[count][0] = x;
					if(y < pos[count][1])
						pos[count][1] = y;
					if(x > pos[count][2])
						pos[count][2] = x;
					if(y > pos[count][3])
						pos[count][3] = y;
				}
			}
		}
		return pos;
	}