X-Git-Url: https://git.sesse.net/?p=stockfish;a=blobdiff_plain;f=src%2Fevaluate.cpp;h=5f86227c2c5e9718e4ec76a967638167054ebff0;hp=9bb6c1c00516446bde294b38da18443c39da25d3;hb=6b7efa0cd14b73416c9030462f79a02bbfc7ad2c;hpb=c23cd4d90aa91504a5a3ec3ce896d1e35e34c494 diff --git a/src/evaluate.cpp b/src/evaluate.cpp index 9bb6c1c0..5f86227c 100644 --- a/src/evaluate.cpp +++ b/src/evaluate.cpp @@ -430,6 +430,13 @@ Value do_evaluate(const Position& pos, EvalInfo& ei, int threadID) { factor[BLACK] = sf; } + // If we don't already have an unusual scale factor, use pawn + // evaluation ones. + if (factor[WHITE] == SCALE_FACTOR_NORMAL) + factor[WHITE] = ei.pi->scale_factor(WHITE); + if (factor[BLACK] == SCALE_FACTOR_NORMAL) + factor[BLACK] = ei.pi->scale_factor(BLACK); + // Interpolate between the middle game and the endgame score Color stm = pos.side_to_move();