up to you. You didn't bother to say what passport you had. And so had to guess you were not Thai because you asked about visa because you are married to a thai. If not Thai you need 400,000 for marriage visa. Or can fly in on tourist visa. If Thai you don't need visa. Perhaps give some facts people can use to advise you.
House has nothing to do with visa. Apply for non O based on marriage in home country. Enter Thailand. Open bank account. Deposit 400,000 tbt. Season money. Apply for 12 month extension of stay. Can get a re-entry permit to leave and come back during the 12 months. But need to be back to apply for another extension. But if you are building a house why are you leaving?