I migrated an iOS Metal app to OS X and things generally went pretty smoothly. However, on OS X, it does not perform depth testing. The same code on iOS does.
Both of them use a MetalKit view and this code to turn on depth testing:
let modelDepthStencilDescriptor = MTLDepthStencilDescriptor()
modelDepthStencilDescriptor.depthCompareFunction = MTLCompareFunction.Less
modelDepthStencilDescriptor.depthWriteEnabled = true
modelDepthStencilState = SharedDevice.device.newDepthStencilStateWithDescriptor(modelDepthStencilDescriptor)
But on the Mac, it looks exactly the same whether depthWriteEnabled is true or false.
Anywhere jumping to mind where I should be looking?