Skip to content

Commit 0d6c975

Browse files
tsukiyama-3greggman
authored andcommitted
translated webgl-qna-how-to-achieve-moving-line-with-trail-effects.md
1 parent df50c22 commit 0d6c975

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
Title: トレイル効果を使った動く線を書く方法
2+
Description: トレイル効果を使った動く線を書く方法
3+
TOC: トレイル効果を使った動く線を書く方法
4+
5+
## 質問
6+
7+
どのように下記デモにあるような線を描くのか?トレイル効果(trailing effects)でシンプルな線を描くことは簡単に思えるかもしれません。しかし、これらの線は屈折しています。
8+
9+
http://uber.github.io/deck.gl/#/examples/custom-layers/trip-routes
10+
11+
## 回答
12+
13+
線のUV座標を渡すか、UV座標を生成し、それらを使用して線に色をつけることができます。時間を渡すと次のようなスクロールができます。
14+
15+
{{{example url="../webgl-qna-how-to-achieve-moving-line-with-trail-effects-example-1.html"}}}
16+
17+
もちろん、色のコードの代わりにテクスチャを使うこともできます。
18+
19+
{{{example url="../webgl-qna-how-to-achieve-moving-line-with-trail-effects-example-2.html"}}}
20+
21+
<div class="so">
22+
<div>質問とその引用箇所は
23+
<a data-href="http://miaokaixiang.com">K.Miao</a>によるCC BY-SA 3.0
24+
<a data-href="https://stackoverflow.com/questions/44768471">こちら</a>
25+
です。
26+
</div>
27+
</div>

0 commit comments

Comments
 (0)