buf.putMetadata(TARGET_Y, 0);
buf.putMetadata(WIDTH, 4);
buf.putMetadata(HEIGHT, 4);
buf.putMetadata(PIXEL_FORMAT, RGB888LE32);
renderer.handleData(buf, null);
String actualData = Arrays.toString(((DataBufferInt)canvas.getOfflineImage().getRaster().getDataBuffer()).getData());
String expectedData = Arrays.toString(pixelsLE);
if (!actualData.equals(expectedData))
System.err.println("Actual image: " + actualData + "\nExpected image: " + expectedData + ".");