Implement vertex and pixel fog.