I watched a physics documentary the other day. What was astounding was the fact that a beam of light was found to not always travel in a straight line when hitting what appears to be solid matter.
Do you mean Straight line after it has hit solid matter? Or Are you talking about the path of a beam running in a straight line as it hits Solid matter?
Because if you are talking about the Second one
then you are talking about light refraction.... Check to my lengthy earlier post about the importance of light refraction.
Refraction of Lightas it passes from less dense to more dense mediums
When light passes from a less dense to a more dense substance, (for example passing from air into water), the light is refracted (or bent) towards the normal.

A demonstration of refraction can be conducted at home in a dark room. All that is needed is a flashlight, a clear glass filled with water and a small mirror.

Figure adapted from Ahrens, 1994
- Figure (a): Shine the light directly into the glass. If the light strikes the water straight on (or parallel to the normal), no bending occurs and it simply passes directly into the water undisturbed, leaving only a straight beam of light all the way to the bottom of the glass.
- Figure (b): Shine the light into the glass at an angle. As the light enters the water, it is refracted. Since the light is passing from air (less dense) into water (more dense), it is bent towards the normal. The beam of light would appear to bend at the surface of the water.
- Figure (c): Place a mirror at the bottom of the glass of water and again shine the light into the glass of water at an angle. As light initially enters the water, it is refracted as in figure (b) and then reflected off the mirror (at the bottom of the glass). Upon exiting the water, the light is bent away from the normal as it passes from water (more dense) and into air (less dense). The light would leave the flashlight, bend at the surface of the water, reflect off the mirror at the bottom of the glass and move towards the surface, where it would bend outward at the same angle it bent in on the way in.