Skip to content

Commit c3feed8

Browse files
committed
Refactor OpenIMAJRectExample
1 parent 338deb1 commit c3feed8

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎imageprocessing/src/main/java/com/baeldung/imageprocessing/openimaj/OpenIMAJRectExample.java‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,10 @@ public static void main(String[] args) throws IOException {
1919

2020
private static void drawRectangle(MBFImage image) {
2121
Point2d tl = new Point2dImpl(10, 10);
22-
Point2d bl = new Point2dImpl(10, image.getHeight()-10);
23-
Point2d br = new Point2dImpl(image.getWidth()-10, image.getHeight()-10);
22+
Point2d bl = new Point2dImpl(10, image.getHeight() - 10);
23+
Point2d br = new Point2dImpl(image.getWidth() - 10, image.getHeight() - 10);
2424
Point2d tr = new Point2dImpl(image.getWidth() - 10, 10);
2525
Polygon polygon = new Polygon(Arrays.asList(tl, bl, br, tr));
26-
image.drawPolygon(polygon, 4, new Float[] {new Float(0),new Float(0),new Float(255.0)});
26+
image.drawPolygon(polygon, 4, new Float[] { 0f, 0f, 255.0f });
2727
}
2828
}

0 commit comments

Comments
 (0)