Media playback is unsupported on your device Media caption The FBI agent was performing a backflip

An off-duty FBI agent who accidentally shot a man while dancing in a Denver nightclub has been charged with second-degree assault.

The agent, named by police as Chase Bishop, was performing a backflip in a nightclub when his gun fell out of his pocket and shot a bystander in the leg.

Mr Bishop handed himself in to police on Tuesday and has been charged with second-degree assault.

He is scheduled to appear in court on Wednesday for a hearing.

"Additional charges may be filed based on the results of a pending blood alcohol content analysis," the Denver District Attorney's office said in a statement on Tuesday.

An FBI spokeswoman would not comment on the incident "in order to preserve the integrity of the investigation," the Associated Press news agency reported.

Image copyright Denver Police Department Image caption Video of Chase Bishop who accidentally shot a man while dancing in a Denver nightclub went viral

Video of the incident involving Mr Bishop, 29, was widely viewed on social media.

The gun fell to the floor and, as the agent went to grab it, it fired a shot.

The customer hit by the bullet was taken to hospital with a non-life-threatening injury.