That's the original meaning, however taking the piss now means just giving someone a ribbing and in the most part not meaning to be malicious.
Guy 1: "Hey guys, what do you think to my awesome new haircut?"
Guy 2: "I think you look like a fucking prick, mate...you look like a real slob".
Other guys: "Haha, Guy 2 really took the piss out of guy 1!"
Meaning as it is now:
Guy 1: "Man, I only got a 45 on my last assignment"
Guy 2: "Haha that's fucking shit!"
Guy 1: "Don't be so mean"
Guy 2: "Cheer up man, I was only taking the piss"
2) to do/say something for the hell of it
'No you didn't and that hurt'
'I'm only taking the piss. You fucking filthy mongoloid.'