Re: dreaming apples
When you dream of an apple, you are perhaps not aware of a real physical apple, and the cognitive machinery of apple-identification is not activated by retinal stimulus.
Nevertheless, the cognitive machinery of apple-identification is still the same. If I see a picture of an apple, or if a futuristic mind-control device convinces me that an apple is in front of me, the apple-identification program in my brain functions the same in every case.
Of course, most of the time we sleep, we're not dreaming. When you're fully unconscious, your cognitive machinery can do nothing, because there's nothing for it to work with. In other words, if you can't recognize apples, it's probably because your entire mind is switched off for some reason (hopefully temporarily, but eventually, permanently.)