A Mellin transform approach to barrier option pricing