diff --git a/GPU/Common/SplineCommon.cpp b/GPU/Common/SplineCommon.cpp index 7df0db85e5..1f3ea46629 100644 --- a/GPU/Common/SplineCommon.cpp +++ b/GPU/Common/SplineCommon.cpp @@ -307,15 +307,15 @@ static void SplinePatchFullQuality(u8 *&dest, u16 *indices, int &count, const Sp patch_div_t /= quality; } - if (patch_div_s < 2) patch_div_s = 2; - if (patch_div_t < 2) patch_div_t = 2; - // Downsample until it fits, in case crazy tesselation factors are sent. while ((patch_div_s + 1) * (patch_div_t + 1) > maxVertices) { patch_div_s /= 2; patch_div_t /= 2; } + if (patch_div_s < 2) patch_div_s = 2; + if (patch_div_t < 2) patch_div_t = 2; + // First compute all the vertices and put them in an array SimpleVertex *&vertices = (SimpleVertex*&)dest;