It is not necessary to think of something sad in order to bring out the emotion in a sad piece. It is necessary to LISTEN to yourself play. How often do you actually listen to yourself while playing? The composer has written the piece in order to create certain emotions in the listener. If you follow the written phrasing, dynamics, and rhythmic instructions and listen to your playing, it will evoke certain emotions in you. Those emotions will then further affect your playing, which will intensify the emotions. There is a feedback effect here. But really, the most important thing is to listen to yourself play.
IDefinitely don't think, "I hope I don't screw up this section" or anything like that because that will almost guarantee that you will screw it up.
My teacher says I should be thinking about something when I perform. Usually, I'm thinking along the lines of 'okay, don't flub up the fingering in this passage; crescendo coming up- sink into it; alright, this is a 'happy' passage, play those staccatos nice and bright; etc." However she says that, for example, when playing a sad piece you should try to think of something sad so you can put more emotion into it.
... when I try to do that I usually end up thinking about something stupid- like for Bach's Invention No. 1, I thought of riding my bike-
There's a thread asking what you think about when you perform...well, let me tell you. On the Mendelssohn, my mind wasn't very focused, and I was thinking about pretty random stuff. Lol, i was even thinking about whether or not to post anything on this forum about the recital when it was finished! I didn't have very much time to think during the chopin, it's only a minute long. Mainly I was focusing on relaxing my right hand and hitting the right chords in the left. On the Brahms, I tried really hard just to listen to myself, and hear how I sounded. I found this is really helpful: a.) I really got into the music much more than the other peices, b.) I was much more focused, c.) I hit the right notes, and i wasn't just relying on pure muscle memory and reflex.