Not sure best way to describe this. I want to do a SumIF, but instead of a range I want a formula, for example...

A B C
1 5 5
2 2 9
3 8 9
4 1 8

Is it possible to do a SumIF where I sum the values of C only if (B-A) > 3, or something along those lines.
The way I've been doing it is by creating an extra column and then putting column D in the range argument, but I was wondering if there was a simpler way to do it. Something like [b:b-a:a] as the range, but not sure if that's possible.

Thanks