Of course. It's also a question of knowing where the line is depending who you're with. I don't bant with bros at the gym the way I joke with parents during Parent-Teacher night. Gotta know your audience.
Shit, I made that mistake a couple of months ago, i asked for a long island during a dinner and the barmaid completely fucked it up, so I complained that it was shit and the person should be fired. Someone said 'Oh come on she's not that bad' and I answered back that 'I'd rather ask Cosby to mix my drinks'.
Well, most of my friends either laughed hard or at least tried not to, but the girls audibly gasped and shit and some got really offended at the joke. I immediately had to backpedal and go 'Sorry sorry it's just really terrible' but thankfully I was spared a lecture on rape culture or whatever.
Story above is why I restrain all my rape jokes to male audiences who appreciate them (it's always nice to let loose and joke about your passion in life)