回答編集履歴
1
ソースコードを更に簡略化
test
CHANGED
@@ -40,7 +40,7 @@
|
|
40
40
|
|
41
41
|
```javascript
|
42
42
|
|
43
|
-
|
43
|
+
var text = new Blotter.Text("こんにちは", {
|
44
44
|
|
45
45
|
family : "serif",
|
46
46
|
|
@@ -52,17 +52,9 @@
|
|
52
52
|
|
53
53
|
|
54
54
|
|
55
|
-
|
55
|
+
var mainImageSource = document.getElementById("fs").textContent;
|
56
56
|
|
57
|
-
Blotter.Assets.Shaders.Noise3D,
|
58
|
-
|
59
|
-
document.getElementById("fs").textContent
|
60
|
-
|
61
|
-
].join("\n");
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
57
|
+
var material = new Blotter.ShaderMaterial(mainImageSource, {
|
66
58
|
|
67
59
|
uniforms : {
|
68
60
|
|
@@ -76,9 +68,9 @@
|
|
76
68
|
|
77
69
|
|
78
70
|
|
79
|
-
|
71
|
+
var blotter = new Blotter(material, { texts : text });
|
80
72
|
|
81
|
-
|
73
|
+
var scope = blotter.forText(text);
|
82
74
|
|
83
75
|
scope.appendTo(document.body);
|
84
76
|
|
@@ -92,8 +84,6 @@
|
|
92
84
|
|
93
85
|
});
|
94
86
|
|
95
|
-
|
96
|
-
|
97
87
|
```
|
98
88
|
|
99
89
|
|