The lead order settled with MacLeod ahead of Irish driver Charlie Eastwood with John Simonyan third.
TRS driver Sam MacLeod with the NZ Motor Cup.
Eastwood slid wide at turn one and Simonyan was up to second place, Artem Markelov third.
Championship leader Lance Stroll had come through to hold fourth place ahead of Santino Ferrucci and Arjun Maini. Simonyan had cut Macleod's lead from five seconds back to 3.5, but then slid wide in a brush with another car. Markelov too slipped back, and Stroll was up to second place, his team-mate Maisano third.
As the track dried MacLeod was able to control the race from a lead that eventually stretched back out to five seconds.
With three laps to run, Arjun Maini had overtaken made sure of fourth place, ready to pounce if the leading three made a mistake.
But the race belonged to MacLeod, who had put in a dominant flag to flag performance and become the sixth different race winner of the series, the third different feature race winner.
Leading New Zealand was James Munro, ninth.
The championship top three are now Lance Stroll (515 points), Arjun Maini (460) and Brandon Maisano (429). The top New Zealand driver is Munro, who is sixth on 325 points.