Below is a great talk on the topic of mindfulness, or the ability to step back from your emotions and look at your thoughts and feelings in a more objective way. The way we perceive the world is hugely affected by our past experiences and future expectations as is our perception of pain and sensation in our bodies. Developing the skill of mindfulness is commonly the path out of chronic pain for many people.
See below the video for a link to a great book on the topic that dives deeper into the idea and the science behind it.
Mindsight: The new science of personal transformation
Click Picture for details