Associated Press

Donatas Motiejunas and the Houston Rockets have agreed to a new contract.

Adrian Wojnarowski of The Vertical reported the sides agreed to a four-year, $35 million deal after the Rockets pulled their offer sheet. Motiejunas can earn up to $37 million as part of the deal, per Wojnarowski.

On Dec. 5, Wojnarowski reported that the Rockets matched the four-year, $37 million offer sheet that Marc J. Spears of The Undefeated reported the Nets gave Motiejunas on Dec. 2. Wojnarowski reported at the time that the Nets' offer sheet included two non-guaranteed years at the end.

Wojnarowski reported on Dec. 1 that the Nets gave Motiejunas a physical and were thinking about signing him to an offer sheet. Marc Stein of ESPN later reported that the Nets were "comfortable" with Motiejunas' health.

On Nov. 23, the Rockets rescinded a contract offer to Motiejunas, according to Stein.

Stein offered more details on the situation:

Video Play Button Videos you might like

Motiejunas, 26, turned down the team's $4.4 million qualifying offer for this season, per Stein, making him a restricted free agent on Oct. 1. Stein also reported that the Rockets offered the power forward a multiyear contract worth "$7 million annually, with attainable incentives that could take it to $8 million" after Motiejunas turned down the qualifying offer.

By most measures, Motiejunas would be the sort of stretch 4 who would fit head coach Mike D'Antoni's offensive approach coming off the bench. In 37 games last season, he averaged 6.2 points and 2.9 rebounds in 14.8 minutes per game. Two seasons ago, he shot a solid 36.8 percent from beyond the arc.

You can follow Timothy Rapp on Twitter.