In this Sept. 7, 2014, file photo, San Francisco 49ers’ Ray McDonald sits on the bench during the second half of an NFL football game against the Dallas Cowboys in Arlington, Texas. Prosecutors in California have charged former San Francisco 49er defensive tackle Ray McDonald with domestic violence and false imprisonment following allegations he assaulted his ex-fiancee while she held their 2-month-old child. The Santa Clara County district attorney’s office announced the charges Thursday, July 9, 2015. (AP Photo/LM Otero, File)

SAN FRANCISCO (AP) — Former San Francisco 49er defensive tackle Ray McDonald was charged with domestic violence and false imprisonment in connection with allegations he assaulted his ex-fiancee while she held their 2-month-old child, prosecutors said Thursday.

The Santa Clara County district attorney’s office said McDonald was scheduled to be arraigned later in the day on those charges and additional charges of child endangerment and violating a court order. The false imprisonment charge is a felony while the other counts are misdemeanors.

A call to McDonald’s attorney, Steve Defilippis, was not immediately returned.

Prosecutors said police responded to a domestic disturbance at a home around 4 a.m. on May 25 and found McDonald had broken into the woman’s bedroom and assaulted her while his driver tried to stop him and she tried to get away.

McDonald cornered the woman in a dining room and trapped her there before she told investigators he chased her into a bathroom and repeatedly bumped her while trying to grab her cellphone, according to investigators. It continued in the bedroom, where the woman said McDonald jabbed at her head with a finger and tried to pull her off the bed. Part of the incident was caught on cellphone video the woman took.

McDonald eventually left the scene, but then returned as police were interviewing the woman, whom authorities haven’t identified, before his driver sped away, prosecutors said.

McDonald was arrested later that morning. He was arrested again two days later when police and the woman arrived at the home to find McDonald there in violation of a restraining order, prosecutors said.

Defilippis told the San Jose Mercury News at the time that neither he nor his client had been notified about the restraining order.

Citing a pattern of behavior and off-field issues, the 49ers released McDonald on Dec. 17. He was released by the Chicago Bears after his May 25 arrest.

The 49ers let McDonald go just a month after Santa Clara County prosecutors declined to file charges against him in a separate domestic violence investigation stemming from an arrest on Aug. 31 while celebrating his 30th birthday at his home.

Prosecutors cited conflicting versions of what happened, a lack of verifiable eyewitnesses and a lack of cooperation by the alleged victim, McDonald’s then-fiancee, in explaining their decision.

In June, a judge dismissed a defamation lawsuit McDonald filed against a woman who accused him of rape.

McDonald says security camera footage will show a consensual sexual encounter occurred in his hot tub.

Police say the woman doesn’t recall any sexual encounters and reported blacking out after drinking alcohol and falling at McDonald’s home. She said she went to police after waking up naked next to McDonald.

The Santa Clara County district attorney is looking at the case.