I had a horrible experience of this when I woke up today. I'd had a rather nasty dream about cheating on my partner and when I awoke I swore I saw their corpse on the floor next to my bed. Not nice.
The apparitions however, are nowhere near as common as what you describe. If I were you, I'd take the advice of the others and talk to someone about your medication.