Optimization: if gamma is 1.0 don't eval image