The hammer drill vibrates in and out very fast to make masonry drilling much easier.
Rotary hammers are drills with a piston on the inside which is operated by the motor and gears. When the motor turns, it moves a gear, which then moves a rod. The rod hits a hammer mechanism which transfers the strike force into the rotary hammer bit. All of this happens very rapidly. Because there is a piston being struck, the force of the blow against the bit is much harder than that of a hammer drill.
Hammer drills have a motor that turns a splined gear type mechanism inside the tool. These splined gears are meshed together and hit against each other creating a vibrating action that is transferred to the drill chuck and bit. The hammering is rapid, but the force is only a fraction of that delivered by a rotary hammer.
The primary use for the rotary hammer is to drill holes (from 1/4" to 2" in diameter) in hard concrete using a solid bit. It's also used for light chipping.
The primary use for the hammer drill is to drill holes (from 3/16" to 7/8" in diameter) in masonry or brick. It's also used as a heavy-duty drill motor for standard drilling.
Typically, a hammer drill has a chuck and uses bits that have straight shanks. Most rotary hammers use bits that have either slots and grooves in the shank (SDS) or spline shanks. Also becoming popular is a slotted shank bit called the "SDS-Max" which is for larger hammers.
There is a major difference between a standard hammer drill and a rotary hammer drill. A standard hammer-drill uses 2 grooved plates that rotate opposite of each other; when they slip and the grooves connect, a bang is heard, "hammering" the chuck in and out, allowing a carbide bit to go through masonry materials. This method generates quite a bit of noise and often requires hearing protection. A rotary hammer is extremely more efficient than a regular hammer drill, because it drives a piston that compresses an air pocket, that, in turn, pounds the chuck with measurable impact energy. There really is no question which is better and faster. Rotary hammer drills do the same job in far less time, with less noise and with less effort. For many applications, like drilling into tough materials like aged concrete, a rotary hammer is the only tool to use.