diff --git a/docs/index.html b/docs/index.html index b617bde3..94300bd3 100644 --- a/docs/index.html +++ b/docs/index.html @@ -38,7 +38,7 @@ - + @@ -134,7 +134,7 @@
diff --git a/docs/ja-JP/index.html b/docs/ja-JP/index.html index f3061a6b..d4ff083e 100644 --- a/docs/ja-JP/index.html +++ b/docs/ja-JP/index.html @@ -41,7 +41,7 @@ - + @@ -137,7 +137,7 @@
diff --git a/docs/news/2020-09-18.html b/docs/news/2020-09-18.html
index 83a7a625..15583183 100644
--- a/docs/news/2020-09-18.html
+++ b/docs/news/2020-09-18.html
@@ -34,7 +34,7 @@
-
+
diff --git a/docs/news/2020-11-22.html b/docs/news/2020-11-22.html
index b61efba0..29f23c6b 100644
--- a/docs/news/2020-11-22.html
+++ b/docs/news/2020-11-22.html
@@ -34,7 +34,7 @@
-
+
diff --git a/docs/news/index.html b/docs/news/index.html
index 0cf5c7fd..43354283 100644
--- a/docs/news/index.html
+++ b/docs/news/index.html
@@ -33,7 +33,7 @@
-
+
diff --git a/docs/news/rss.xml b/docs/news/rss.xml
index 56733238..b54b77f4 100644
--- a/docs/news/rss.xml
+++ b/docs/news/rss.xml
@@ -6,7 +6,7 @@
@@ -192,7 +192,7 @@
- If we want to draw Bézier curves, we can run through all values of
+ Вместо использования функции математического анализа для нахождения значений Rather than using our calculus function to find
- To see this in action, mouse-over the following sketch. Moving the mouse changes which curve point is explicitly evaluated using de
- Casteljau's algorithm, moving the cursor left-to-right (or, of course, right-to-left), shows you how a curve is generated using this
- approach.
+ Чтобы проверить это в действии, ведите ползунок под ниже представленным графиком слева направо и наоборот, задавая разные значения
+ Let's just use the algorithm we just specified, and implement that: Запишем согласно предложенному алгоритму:
- And done, that's the algorithm implemented. Except usually you don't get the luxury of overloading the "+" operator, so let's also give
- the code for when you need to work with
- So what does this do? This draws a point, if the passed list of points is only 1 point long. Otherwise it will create a new list of
- points that sit at the t ratios (i.e. the "markers" outlined in the above algorithm), and then call the draw function for this
- new list.
+ И что это делает? Это зарисует точку на график, если длинна вводной points составляет всего одну точку. В противном случае — это создает
+ новый список для вводной, составленный из "маркеров", обчисленых пропорционально значению t между поточного списка точек вводной
+ и вызовет саму себя с новой вводной.
diff --git a/docs/zh-CN/index.html b/docs/zh-CN/index.html
index c31b5537..61301f64 100644
--- a/docs/zh-CN/index.html
+++ b/docs/zh-CN/index.html
@@ -41,7 +41,7 @@
-
+
@@ -137,7 +137,7 @@
de Casteljau's algorithm
+ Алгоритм де Кастельжо
- t
from 0 to 1 and then compute the weighted basis function
- at each value, getting the x/y
values we need to plot. Unfortunately, the more complex the curve gets, the more expensive
- this computation becomes. Instead, we can use de Casteljau's algorithm to draw curves. This is a geometric approach to curve
- drawing, and it's really easy to implement. So easy, in fact, you can do it by hand with a pencil and ruler.
+ Для зарисовки кривой Безье, мы можем пробежаться по всем значениям t
от 0 до 1 и скомпилировать вывод базовой функции с
+ подставленными весами для каждого значения. К сожалению, чем замысловатее кривая, тем дороже обходиться это обчисление. Вместо этого, мы
+ можем воспользоваться Алгоритмом де Кастельжо для прорисовки кривых. Этот алгоритм позволяет прорисовывать кривые базируясь на
+ геометрических вычислениях и довольно прост в применении. На деле, настолько прост, что его можно воплотить при помощи карандаша и
+ линейки.
+ x/y
для t
, давайте сделаем
+ следующее:
x/y
values for t
, let's do this instead:
-
t
as a ratio (which it is). t=0 is 0% along a line, t=1 is 100% along a line.n
curve, that's n
lines.t
за пропорцию(чем оно и является). t=0 будет 0% вдоль линии, t=1, соответсвенно, 100% вдоль линии.n
-го порядка это n
линийt
. So if t
is 0.2, place the mark at 20% from the start,
- 80% from the end.
+ Разместим маркеры вдоль линий, соответсвенно значению t
. Так, если t
0.2, разместим маркер на 20% от начала,
+ и, соответственно, 80% от конца.
those
points. This gives n-1
lines.t
.those
points. This'll be n-2
lines.n-1
линий.t
.t
on that line coincides with the original curve point at
- t
.
+ Продолжим повторять два предыдущих шага, пока на выводе у нас останется всего одна линия. Маркер t
на этой линии будет
+ соответствовать точке для t
на нашей кривой.
t
для иллюстрации геометрического построения.
-
+
How to implement de Casteljau's algorithm
- Имплементация Алгоритма де Кастельжо
+
@@ -1784,8 +1785,8 @@ function drawCurve(points[], t):
x
and y
values:
+ Готово, алгоритм воплощен. Помимо того факта, что зачастую мы не располагаем роскошью перенагрузки оператора "+", так давайте совместим
+ вычисление для значений x
и y
:
@@ -1836,9 +1837,9 @@ function drawCurve(points[], t):