San Francisco police have released dramatic video of a shootout inside a barbershop that left a gunman dead and five people wounded, including an officer.