Comparing PNG images using ErrorMetric.Absolute option #1259
Answered
by
dlemstra
bokhanhanna
asked this question in
Help
-
Beta Was this translation helpful? Give feedback.
Answered by
dlemstra
Sep 23, 2022
Replies: 1 comment 1 reply
-
You will get the correct result when you do |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
bokhanhanna
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You will get the correct result when you do
actualImage.Compare(expectedImage
instead. This is happening because the actual image only has two channels and the expected image has 4 channels. This might be a bug that I will need to investigate in more detail. My advise would be to set theColorType
of both images toTrueColorAlpha
before comparing them. Then you are comparing the correct channels. Or you could useErrorMetric.RootMeanSquared
instead.