At this point in the play, Proctor is probably extremely frustrated, scared, and angry.
He has come to court to try to clear his wife's name. He has decided that he has to denounce Abigail to do so. But then when he and Mary imply that Abigail has been making it all up, Abigail starts claiming that Mary is doing something evil to her (the shadow). All the other girls start making similar claims.
Proctor must be frustrated that the court is paying attention to these girls who are clearly just making things up. He must be afraid for his wife -- afraid she will be convicted and killed. And he must be angry at Abigail for doing this to him.
John Proctor's affair with Abigail now has led to her accusations of his wife engaging in supernatural acts. Elizabeth's life is endangered and their boys are alone without a mother. John is driven by guilt and the need to clear his conscience as well as protect Elizabeth. He witnesses the interview with the girls in the presence of Danforth and Hale. He tries exposing the truth about Abigail.
John accuses Abigail as being a murder because she is willing to allow his wife to die. The whole situation begins to escalate as the girls are further questioned and Abigail leads them on with her lies. She has already told that John's wife has a type of voodoo doll that she uses. When John approaches and catches Mary Warren as she starts to run, Abigail starts to call to Heaven. John is so fed up with her lies and the control that she has over everyone that he grabs her hair pulling her to his feet. At this point he calls her a whore. He then tries to confess the truth.
John must have become so angry that he could not look at her face any longer making the words of lies come out of her mouth. He feels like he has no other recourse and he opts to frighten her into telling the truth.