BarcodeRow.java (zxing-zxing-3.4.1) | : | BarcodeRow.java (zxing-zxing-3.5.0) | ||
---|---|---|---|---|
skipping to change at line 66 | skipping to change at line 66 | |||
/** | /** | |||
* @param black A boolean which is true if the bar black false if it is white | * @param black A boolean which is true if the bar black false if it is white | |||
* @param width How many spots wide the bar is. | * @param width How many spots wide the bar is. | |||
*/ | */ | |||
void addBar(boolean black, int width) { | void addBar(boolean black, int width) { | |||
for (int ii = 0; ii < width; ii++) { | for (int ii = 0; ii < width; ii++) { | |||
set(currentLocation++, black); | set(currentLocation++, black); | |||
} | } | |||
} | } | |||
/* | ||||
byte[] getRow() { | ||||
return row; | ||||
} | ||||
*/ | ||||
/** | /** | |||
* This function scales the row | * This function scales the row | |||
* | * | |||
* @param scale How much you want the image to be scaled, must be greater than or equal to 1. | * @param scale How much you want the image to be scaled, must be greater than or equal to 1. | |||
* @return the scaled row | * @return the scaled row | |||
*/ | */ | |||
byte[] getScaledRow(int scale) { | byte[] getScaledRow(int scale) { | |||
byte[] output = new byte[row.length * scale]; | byte[] output = new byte[row.length * scale]; | |||
for (int i = 0; i < output.length; i++) { | for (int i = 0; i < output.length; i++) { | |||
output[i] = row[i / scale]; | output[i] = row[i / scale]; | |||
End of changes. 1 change blocks. | ||||
6 lines changed or deleted | 0 lines changed or added |