I’ve an image located at images/image.png in my java project. I want to write a method its signature is as follow
byte[] mergeImageAndText(String imageFilePath, String text, Point textPosition);
This method will load the image located at imageFilePath and at position textPosition of the image (left upper) I want to write the text, then I want to return a byte[] that represents the new image merged with text.
Try this way: