Publish new version

This commit is contained in:
schmelczerandras 2020-09-29 17:22:13 +02:00
parent d241f36866
commit d2ae2cc489
15 changed files with 226 additions and 195 deletions

View file

@ -3,8 +3,8 @@
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>RotatedRectangle | SDF-2D - v0.3.3</title>
<meta name="description" content="Documentation for SDF-2D - v0.3.3">
<title>RotatedRectangle | SDF-2D - v0.3.4</title>
<meta name="description" content="Documentation for SDF-2D - v0.3.4">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="../assets/css/main.css">
<link rel="icon" href="../favicon.ico" />
@ -23,7 +23,7 @@
<li class="state loading">Preparing search index...</li>
<li class="state failure">The search index is not available</li>
</ul>
<a href="../index.html" class="title">SDF-2D - v0.3.3</a>
<a href="../index.html" class="title">SDF-2D - v0.3.4</a>
</div>
<div class="table-cell" id="tsd-widgets">
<div id="tsd-filter">
@ -127,7 +127,7 @@
<li class="tsd-description">
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L46">drawables/shapes/rotated-rectangle.ts:46</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L46">drawables/shapes/rotated-rectangle.ts:46</a></li>
</ul>
</aside>
<h4 class="tsd-parameters-title">Parameters</h4>
@ -155,7 +155,7 @@
<div class="tsd-signature tsd-kind-icon">center<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">vec2</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L48">drawables/shapes/rotated-rectangle.ts:48</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L48">drawables/shapes/rotated-rectangle.ts:48</a></li>
</ul>
</aside>
</section>
@ -165,7 +165,7 @@
<div class="tsd-signature tsd-kind-icon">rotation<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L48">drawables/shapes/rotated-rectangle.ts:48</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L48">drawables/shapes/rotated-rectangle.ts:48</a></li>
</ul>
</aside>
</section>
@ -175,7 +175,7 @@
<div class="tsd-signature tsd-kind-icon">size<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">vec2</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L48">drawables/shapes/rotated-rectangle.ts:48</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L48">drawables/shapes/rotated-rectangle.ts:48</a></li>
</ul>
</aside>
</section>
@ -193,7 +193,7 @@
<aside class="tsd-sources">
<p>Overrides <a href="drawable.html">Drawable</a>.<a href="drawable.html#getobjecttoserialize">getObjectToSerialize</a></p>
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L60">drawables/shapes/rotated-rectangle.ts:60</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L60">drawables/shapes/rotated-rectangle.ts:60</a></li>
</ul>
</aside>
<h4 class="tsd-parameters-title">Parameters</h4>
@ -220,7 +220,7 @@
<aside class="tsd-sources">
<p>Overrides <a href="drawable.html">Drawable</a>.<a href="drawable.html#mindistance">minDistance</a></p>
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L56">drawables/shapes/rotated-rectangle.ts:56</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L56">drawables/shapes/rotated-rectangle.ts:56</a></li>
</ul>
</aside>
<div class="tsd-comment tsd-typography">
@ -251,7 +251,7 @@
<aside class="tsd-sources">
<p>Inherited from <a href="drawable.html">Drawable</a>.<a href="drawable.html#serializetouniforms">serializeToUniforms</a></p>
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/drawable.ts#L36">drawables/drawable.ts:36</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/drawable.ts#L36">drawables/drawable.ts:36</a></li>
</ul>
</aside>
<h4 class="tsd-parameters-title">Parameters</h4>
@ -280,7 +280,7 @@
<aside class="tsd-sources">
<p>Overrides <a href="drawable.html">Drawable</a>.<a href="drawable.html#descriptor">descriptor</a></p>
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L9">drawables/shapes/rotated-rectangle.ts:9</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L9">drawables/shapes/rotated-rectangle.ts:9</a></li>
</ul>
</aside>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal">
@ -289,7 +289,7 @@
<div class="tsd-signature tsd-kind-icon">empty<span class="tsd-signature-symbol">:</span> <a href="rotatedrectangle.html" class="tsd-signature-type">RotatedRectangle</a><span class="tsd-signature-symbol"> = new RotatedRectangle(vec2.create(), vec2.create(), 0)</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L45">drawables/shapes/rotated-rectangle.ts:45</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L45">drawables/shapes/rotated-rectangle.ts:45</a></li>
</ul>
</aside>
</section>
@ -299,7 +299,7 @@
<div class="tsd-signature tsd-kind-icon">shader<wbr>Combination<wbr>Steps<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">number</span><span class="tsd-signature-symbol">[]</span><span class="tsd-signature-symbol"> = [0, 1, 2, 3, 8, 16]</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L44">drawables/shapes/rotated-rectangle.ts:44</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L44">drawables/shapes/rotated-rectangle.ts:44</a></li>
</ul>
</aside>
</section>
@ -309,7 +309,7 @@
<div class="tsd-signature tsd-kind-icon">uniform<wbr>Count<wbr>Macro<wbr>Name<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> = &quot;ROTATED_RECTANGLE_COUNT&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L43">drawables/shapes/rotated-rectangle.ts:43</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L43">drawables/shapes/rotated-rectangle.ts:43</a></li>
</ul>
</aside>
</section>
@ -319,7 +319,7 @@
<div class="tsd-signature tsd-kind-icon">property<wbr>Uniform<wbr>Mapping<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">object</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L38">drawables/shapes/rotated-rectangle.ts:38</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L38">drawables/shapes/rotated-rectangle.ts:38</a></li>
</ul>
</aside>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal">
@ -328,7 +328,7 @@
<div class="tsd-signature tsd-kind-icon">bottom<wbr>Center<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> = &quot;rotatedRectangleBottomCenters&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L40">drawables/shapes/rotated-rectangle.ts:40</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L40">drawables/shapes/rotated-rectangle.ts:40</a></li>
</ul>
</aside>
</section>
@ -338,7 +338,7 @@
<div class="tsd-signature tsd-kind-icon">top<wbr>Center<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> = &quot;rotatedRectangleTopCenters&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L39">drawables/shapes/rotated-rectangle.ts:39</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L39">drawables/shapes/rotated-rectangle.ts:39</a></li>
</ul>
</aside>
</section>
@ -348,7 +348,7 @@
<div class="tsd-signature tsd-kind-icon">width<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> = &quot;rotatedRectangleWidths&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L41">drawables/shapes/rotated-rectangle.ts:41</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L41">drawables/shapes/rotated-rectangle.ts:41</a></li>
</ul>
</aside>
</section>
@ -359,7 +359,7 @@
<div class="tsd-signature tsd-kind-icon">sdf<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">object</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L10">drawables/shapes/rotated-rectangle.ts:10</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L10">drawables/shapes/rotated-rectangle.ts:10</a></li>
</ul>
</aside>
<section class="tsd-panel tsd-member tsd-kind-variable tsd-parent-kind-object-literal">
@ -368,7 +368,7 @@
<div class="tsd-signature tsd-kind-icon">distance<wbr>Function<wbr>Name<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> = &quot;rotatedRectangleMinDistance&quot;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L36">drawables/shapes/rotated-rectangle.ts:36</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L36">drawables/shapes/rotated-rectangle.ts:36</a></li>
</ul>
</aside>
</section>
@ -378,7 +378,7 @@
<div class="tsd-signature tsd-kind-icon">shader<span class="tsd-signature-symbol">:</span> <span class="tsd-signature-type">string</span><span class="tsd-signature-symbol"> = &#x60;uniform vec2 rotatedRectangleTopCenters[ROTATED_RECTANGLE_COUNT];uniform vec2 rotatedRectangleBottomCenters[ROTATED_RECTANGLE_COUNT];uniform float rotatedRectangleWidths[ROTATED_RECTANGLE_COUNT];float rotatedRectangleMinDistance(vec2 target, out float colorIndex) {colorIndex &#x3D; 4.0;float minDistance &#x3D; 1000.0;for (int i &#x3D; 0; i &lt; ROTATED_RECTANGLE_COUNT; i++) {vec2 top &#x3D; rotatedRectangleTopCenters[i];vec2 bottom &#x3D; rotatedRectangleBottomCenters[i];float height &#x3D; length(bottom - top);vec2 d &#x3D; (bottom - top) / height;vec2 q &#x3D; (target - (top + bottom) * 0.5);q &#x3D; mat2(d.x, -d.y, d.y, d.x) * q;q &#x3D; abs(q) - vec2(height, rotatedRectangleWidths[i]) * 0.5;float dist &#x3D; length(max(q, 0.0)) + min(max(q.x, q.y), 0.0);minDistance &#x3D; min(minDistance, dist);}return minDistance;}&#x60;</span></div>
<aside class="tsd-sources">
<ul>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/39bd551/src/drawables/shapes/rotated-rectangle.ts#L12">drawables/shapes/rotated-rectangle.ts:12</a></li>
<li>Defined in <a href="https://github.com/schmelczerandras/sdf-2d/blob/d241f36/src/drawables/shapes/rotated-rectangle.ts#L12">drawables/shapes/rotated-rectangle.ts:12</a></li>
</ul>
</aside>
</section>