orIndex];
                    let segmentsForFinalPatch = this.numSurfaceSegments;
                    if (targetMaxLevel > 0) {
                        segmentsForFinalPatch = Math.max(3, this.numSurfaceSegments - targetMaxLevel * 3);
                    }
                    this._drawControlGrid(ctx, patch, colorScheme);
                    this._drawBezierSurface(ctx, patch, colorScheme, segmentsForFinalPatch);
                    for (let i = 0; i < 4; i++) {
                        for (let j = 0; j <