diff options
author | Clément Foucault <foucault.clem@gmail.com> | 2022-04-20 21:56:56 +0300 |
---|---|---|
committer | Clément Foucault <foucault.clem@gmail.com> | 2022-04-20 22:32:03 +0300 |
commit | 4a03c5acf9ab343d5542427d3fd90b4978f02c23 (patch) | |
tree | 28047f4e53a80cbf19adf58b85a0196ad58557b8 /intern/opensubdiv/internal | |
parent | 8d2da45f98bc326d718b05172ff42300a4ab3988 (diff) |
Revert "Fix GPU subdivision: Crash on adding subdivision surface modifier"
The fix does not fix the case of shaders comming from the OpenSubdiv API.
This reverts commit f5191b87608f6607aa1dbd4b9409174db351984b.
Diffstat (limited to 'intern/opensubdiv/internal')
-rw-r--r-- | intern/opensubdiv/internal/evaluator/shaders/glsl_compute_kernel.glsl | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/intern/opensubdiv/internal/evaluator/shaders/glsl_compute_kernel.glsl b/intern/opensubdiv/internal/evaluator/shaders/glsl_compute_kernel.glsl index 08ba1239cb9..2f60aee0999 100644 --- a/intern/opensubdiv/internal/evaluator/shaders/glsl_compute_kernel.glsl +++ b/intern/opensubdiv/internal/evaluator/shaders/glsl_compute_kernel.glsl @@ -329,10 +329,10 @@ void main() int current = int(gl_GlobalInvocationID.x); OsdPatchCoord coord = GetPatchCoord(current); - OsdPatchArray arr = GetPatchArray(coord.arrayIndex); + OsdPatchArray array = GetPatchArray(coord.arrayIndex); OsdPatchParam param = GetPatchParam(coord.patchIndex); - int patchType = OsdPatchParamIsRegular(param) ? arr.regDesc : arr.desc; + int patchType = OsdPatchParamIsRegular(param) ? array.regDesc : array.desc; float wP[20], wDu[20], wDv[20], wDuu[20], wDuv[20], wDvv[20]; int nPoints = OsdEvaluatePatchBasis( @@ -346,7 +346,7 @@ void main() clear(duv); clear(dvv); - int indexBase = arr.indexBase + arr.stride * (coord.patchIndex - arr.primitiveIdBase); + int indexBase = array.indexBase + array.stride * (coord.patchIndex - array.primitiveIdBase); for (int cv = 0; cv < nPoints; ++cv) { int index = patchIndexBuffer[indexBase + cv]; |