Paul Gali, 32, pleaded guilty to one count of unlawful wounding with intent to resist lawful detention in the Brisbane District Court on Monday, and one count of obstructing a police officer with an offensive instrument.
Crown prosecutor Melissa Wilson said police had been called to Gali's home at Rothwell, north of Brisbane, at 9.20am on May 1, 2023 in response to him threatening family members with a knife.
Judge Carl Heaton was shown bodycam footage that showed Gali, dressed in a yellow high-visibility shirt, climb over a police vehicle's bonnet and roof before charging at the officer with a knife raised.
"The officer repeatedly told (Gali) to drop the knife. He was in the process of holstering his firearm and drawing his taser when (Gali) jumped down and ran at him," Ms Wilson said.
Ms Wilson said the officer was retreating and attempting to strike Gali with the taser when he was stabbed in a shoulder area that was not covered by his protective vest.
In the footage, Blood could be seen dripping onto the road as the officer called for backup and told his partner, who had his firearm drawn, not to shoot Gali.
Gali told officers to shoot him throughout his attack and performed an act of self-harm during the standoff.
He surrendered soon after when reinforcement officers arrived and also pointed their firearms at him.
Court heard a police officer had holstered his firearm and was drawing a taser when he was stabbed. (Dave Hunt/AAP PHOTOS)
Ms Wilson said the wounded officer spent two days in hospital but had suffered ongoing psychological effects that had taken away the happiness and sense of purpose he took in police work.
"He feels a deep sense of shame, self-blame, anxiety and depression that he was a victim and he left members of the public and his police partner exposed to Gali's violence," she said.
Defence barrister Kerala Drew said Gali had been diagnosed with bipolar affective disorder whose medication had been reduced at the time.
"He is exceptionally remorseful for what happened on that day. Â He is grateful the officer bears him no ill will. He was shocked when he heard that," Ms Drew said.
Judge Heaton said he accepted Gali now had insight into his offending but he had committed an extremely serious offence against a police officer.
"The officer decided to use non-lethal force rather than shoot you, a decision he made for your benefit in a split second but for which he then suffered greatly by your assault upon him," Judge Heaton said.
Judge Heaton said Gali's attack affected the whole community through making the difficult job of police work even harder and by potentially deterring good candidates from joining the force.
Gali was sentenced to five years' imprisonment and ordered immediately eligible to apply for parole, having spent 19 months in custody.
Judge Heaton said Gali's release would depend on the decision by the parole board and the outcome of his other charges in the Magistrates Court.
Lifeline 13 11 14
beyondblue 1300 22 4636
1800 RESPECT (1800 737 732)