Add handling of more cases to sad calculation.
Add handling of more cases to sad calculation.

lu-zero/kvazaar,lu-zero/kvazaar,ultravideo/kvazaar,lu-zero/kvazaar,ultravideo/kvazaar,ultravideo/kvazaar,lu-zero/kvazaar,ultravideo/kvazaar,ultravideo/kvazaar