Gary has a good answer. In my opinion (American usage), it is used to describe "feeling terrible" after excessive drinking. I don't think I've ever heard it used in another context.
The Oxford Learner's Dictionaries are an excellent, online resource. They give a British usage as "not feeling well."
(British English) not feeling well
You look rough—are you OK?
I had a rough night (= I didn't sleep well).
There is also the related British phrase "to sleep rough" which means to sleep in the streets.