<p>If you want to implement triangular Gregory patches then you do not have to choose <span class="math-container">$n$</span> since a triangular Gregory patch is special kind of quartic B'ezier triangle, so <span class="math-container">$n = 4$</span>. The patch has special inner control points which are constructed from cubic B'ezier curves on the edges of the triangles.</p>
<p>I take your question about how to compute the control points <span class="math-container">$b_{ijk}$</span> (ordinates) to be how to go from a standard triangular mesh to a mesh of Gregory patches. The easiest way to construct B'ezier control points (ordinates) from a triangular mesh is to first construct vertex normals (by averaging incident face normals) and then to use the procedure from PN triangles (<a href="https://citeseerx.ist.psu.edu/document?repid=rep1&amp;type=pdf&amp;doi=72297b633af266e8a22e861a5c0d8d04281b877a" rel="nofollow noreferrer">Section 3.1</a>) to construct the edge control points of each triangle. Each one of these edges is then a cubic B'ezier curve which can be used as input to construct, through the Chiyokura-Kimura basis patch technique, the inner control points of the Gregory patch.</p>

CC BY-SA 4.0
2023-11-23T13:15:39.983Z
Thanks @Reynolds, I have already implemented the algorithm for curved PN triangles, so I will test it with their control points. If that works well, I will accept this answer
Thomas
CC BY-SA 4.0
2023-11-26T11:11:35.070Z
I was not able to finish implementing it now, but you are right, the control points are the same... +1
Thomas
CC BY-SA 4.0
2023-11-27T10:29:23.967Z
You have to realize that this is merely just a choice for the control points.  I'm not sure what you mean about how they are the same. The cubic control points on the edges of the triangle can be anything as long as adjacent triangles share those control points and at vertices they represent the same normal vector (the first control points on each edge from the vertices represent a plane).
Reynolds
CC BY-SA 4.0
2023-11-28T08:02:58.977Z
Okay, so e. G. b300, b210, b120 and b030 need to lie on a plane... Same for the adjacent triangles edge, where the control points for the same edge need to be identical to there
Thomas
CC BY-SA 4.0
2023-11-23T12:39:38.290Z
2023-11-23T12:39:38.290Z
Reynolds
<p>I am trying to implement the Triangular Gregory patch from <a href="https://www2.eecs.berkeley.edu/Pubs/TechRpts/1987/CSD-87-313.pdf" rel="nofollow noreferrer">this</a> paper.
The goal is to create a <span class="math-container">$G^1$</span> continuity across the patch boundaries. So that the normal vectors of neighboring triangles are equal.</p>
<p>Right now I'm trying to understand how to calculate the Bézier ordinates: <span class="math-container">$b_{i,j,k}$</span> where <span class="math-container">$i,j,k \geq 0$</span> and <span class="math-container">$i+j+k = n$</span></p>
<p>The second thing I'm not sure about is the degree <span class="math-container">$n$</span>. How to choose a good <span class="math-container">$n$</span>?</p>

<bezier-curve><tesselation>
Gregory triangle patch, calculating $b_{i,j,k}$
Thomas
# Gregory triangle patch, calculating $b_{i,j,k}$

(Asked by: username_0 on 2023-11-23)

I am trying to implement the Triangular Gregory patch from [this](https://www2.eecs.berkeley.edu/Pubs/TechRpts/1987/CSD-87-313.pdf) paper.
The goal is to create a $G^1$ continuity across the patch boundaries. So that the normal vectors of neighboring triangles are equal.

Right now I'm trying to understand how to calculate the Bézier ordinates: $b\_{i,j,k}$ where $i,j,k \geq 0$ and $i+j+k = n$

The second thing I'm not sure about is the degree $n$. How to choose a good $n$?

**Tags:** bezier-curve, tesselation


---

## 1 answers

### Answer by username_1 on 2023-11-23. Score: 1 | Accepted answer

If you want to implement triangular Gregory patches then you do not have to choose $n$ since a triangular Gregory patch is special kind of quartic B'ezier triangle, so $n = 4$. The patch has special inner control points which are constructed from cubic B'ezier curves on the edges of the triangles.

I take your question about how to compute the control points $b\_{ijk}$ (ordinates) to be how to go from a standard triangular mesh to a mesh of Gregory patches. The easiest way to construct B'ezier control points (ordinates) from a triangular mesh is to first construct vertex normals (by averaging incident face normals) and then to use the procedure from PN triangles ([Section 3.1](https://citeseerx.ist.psu.edu/document?repid=rep1&type=pdf&doi=72297b633af266e8a22e861a5c0d8d04281b877a)) to construct the edge control points of each triangle. Each one of these edges is then a cubic B'ezier curve which can be used as input to construct, through the Chiyokura-Kimura basis patch technique, the inner control points of the Gregory patch.

> **Comments:**
> **username_0**: Thanks @username_1, I have already implemented the algorithm for curved PN triangles, so I will test it with their control points. If that works well, I will accept this answer  
> **username_0**: I was not able to finish implementing it now, but you are right, the control points are the same... +1  
> **username_1**: You have to realize that this is merely just a choice for the control points.  I'm not sure what you mean about how they are the same. The cubic control points on the edges of the triangle can be anything as long as adjacent triangles share those control points and at vertices they represent the same normal vector (the first control points on each edge from the vertices represent a plane).  
> **username_0**: Okay, so e. G. b300, b210, b120 and b030 need to lie on a plane... Same for the adjacent triangles edge, where the control points for the same edge need to be identical to there  

---

