A man who shot at a police officer in an underground car park on the Gold Coast more than two years ago has been sentenced to nine years in jail.

Key points: Daniel White-Mayne pulled a gun on police in an underground car park during an arrest

Daniel White-Mayne pulled a gun on police in an underground car park during an arrest He was found not guilty of attempted murder but was convicted on a lesser charge of attempted striking

He was found not guilty of attempted murder but was convicted on a lesser charge of attempted striking He will eligible for parole in 2021

During a Supreme Court trial in Brisbane earlier this year, Daniel White-Mayne, 29, admitted to pulling a revolver out of a bag and firing one shot while he was being arrested by police in Surfers Paradise in 2017, but denied he was intending to kill the female constable.

The officer shot White-Mayne in the scrotum and thigh during the struggle.

He told the court he only wanted to "scare" the officer and fired the shot after he was injured.

Earlier this year, a jury found White-Mayne not guilty of attempted murder, but convicted him of the lesser charge of attempted striking in an attempt to resist arrest.

While handing down his sentence today Justice Martin Burns said the officer should be commended for her bravery.

"She has paid and continues to pay a high price for a conspicuous act of bravery," he said.

Justice Burns said the officer had not worked since the incident and her prospect of returning to the service was "bleak".

"It's impacted her personally and financially in various significant ways," he said.

White-Mayne was also convicted on drug and weapons offences but not punished.

He will be eligible for parole in January 2021.

Daniel White-Mayne's lawyer told the court last month his client had a loaded gun in his bag as "protection from people who were after him". ( Facebook )

During sentencing submissions last month, the Crown prosecutor said White-Mayne was on bail, and only for a short time, when the incident happened.

"[The officer] was doing her job, she was confronted with a man … shouting he'll shoot," the prosecutor said.

"He continued to point his weapon at her… He didn't throw down his weapon and surrender."

White-Mayne's barrister Angus Edwards said when his client drew the gun, he only intended to "scare the police" — not pull the trigger.

"He only fired it after being shot four times," Mr Edwards said.

"He did not fire the gun … until he had fallen to his knees and was bleeding profusely.

"It was a momentary intention, which was formed when his judgement was affected by what was going on in the carpark, and having been shot himself."

Asked why White-Mayne had a loaded gun in his bag in the first place, Mr Edwards replied his client said it had been for "protection from people who were after him," after his drug addiction led him in to debt.

Mr Edwards told the court White-Mayne said he had bought the weapon about a month-and-a-half earlier after people who he owed money to "caught up with him".

"He instructs me he was abducted, he was beaten, and threats were made to him and his family, so he purchased a firearm," he said.

"His view of that is it was the worst decision he has ever made."

He said when White-Mayne was approached by police in the carpark that day, he was "very concerned" about being returned to custody and "being a sitting duck for these people".

A letter of apology was also tendered to the court.

"He didn't intend for her to suffer serious injury," he said.