Singer Chris Brown has been arrested in Los Angeles on suspicion of assault with deadly weapon.
Police were called to Brown's home after he reportedly pointed a gun at a woman.
Brown came out of the house peacefully after posting videos online criticising police and denying reports that he was barricaded inside.
He was taken into custody by police, who have arrested him on suspicion of assault with a deadly weapon, which is a felony charge.
The singer has several convictions for violence, including a 2009 assault on his then girlfriend, pop star Rihanna.
"When you get the warrant for whatever you need to do, you're going to walk right up in here and you're going to see nothing, you idiots," he said in one Instagram video, posted to his 30 million followers.
Police received an emergency call from a woman. She was not in Brown's home at the time the call was made.
Entertainment news site TMZ identified her as Baylee Curran, who was crowned Miss California Regional in a beauty pageant this year.
Ms Curran told TMZ that Mr Brown had become angry when she admired the jewellery of a member of his entourage while in a hot tub at his home.
"If somebody put a gun to your head, what would you do? Call the police," Ms Curran said on her Instagram account, AFP news agency reported.
Police said people leaving Mr Brown's home were being searched by police but no-one had been arrested.
In his Instagram video, Mr Brown also voiced support for the Black Lives Matter movement against police brutality, saying: "You're all the worst gang in the world, the police."
Brown cancelled a concert in Auckland late last year, after anti-violence groups spoke out against his trip because of his assault conviction.
The star applied for a work visa for New Zealand, but his conviction for assaulting pop star Rihanna in 2009 meant he may have needed a special direction under the Immigration Act to be able to enter the country.
He was denied entry to Britain in 2010 and Canada earlier in 2015.