ashot
ashot copied to clipboard
markign differrence with rectangle
Is it possible to mark diff area with rectangle instead of some solid color OR is ti possible to get marking on x,y co ordinates in image where the diff is identified
@valfirst - CAn you please help me in this case
with rectangle instead of some solid color
sorry, could you please elaborate on this?
is ti possible to get marking on x,y co ordinates in image where the diff is identified
do you need to get the coordinates (x, y)
of the all found diffs?
with rectangle instead of some solid color
sorry, could you please elaborate on this?
is ti possible to get marking on x,y co ordinates in image where the diff is identified
do you need to get the coordinates
(x, y)
of the all found diffs?
Yes. Basically when there is very small diff on the screen then its difficult to locate. So if we can have the area of diff marked as rectangle that will be really helpful.
https://github.com/romankh3/image-comparison this one draws rectangles
val imageDiff = new ImageComparison(
read(getRelativeResourceAsStream(getClass(),
"example.png")),
read(getRelativeResourceAsStream(getClass(),
"example-different.png")));
val d = imageDiff
.setDifferenceRectangleFilling(true, 10)
.compareImages();
try (val o = new FileOutputStream("diff.png")) {
write(d.getResult(), "png", o);
}
assertThat(d.getImageComparisonState(),
is(MISMATCH));
Thanks so much @adrian-herscu ! Will give a try but looks exactly what I was looking for!
Thanks so much @adrian-herscu ! Will give a try but looks exactly what I was looking for!
You're welcome :) Actually, I don't know why this library does comparison at all... Maybe join forces somehow?...