qd-changjing/public/static/Build/Documentation/Cartesian2.html

7084 lines
138 KiB
HTML
Raw Normal View History

2022-07-05 16:56:29 +08:00
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Cartesian2 - Cesium Documentation</title>
<!--[if lt IE 9]>
<script src="javascript/html5.js"></script>
<![endif]-->
<link href="styles/jsdoc-default.css" rel="stylesheet">
<link href="styles/prism.css" rel="stylesheet">
</head>
<body>
<div id="main">
<h1 class="page-title">
<a href="index.html"><img src="Images/CesiumLogo.png" class="cesiumLogo"></a>
Cartesian2
<div class="titleCenterer"></div>
</h1>
<section>
<header>
</header>
<article>
<div class="container-overview">
<div class="nameContainer">
<h4 class="name" id="Cartesian2">
<a href="#Cartesian2" class="doc-link"></a>
new Cesium.Cartesian2<span class="signature">(<span class="optional">x</span>, <span class="optional">y</span>)</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L19">Core/Cartesian2.js 19</a>
</div>
</h4>
</div>
<div class="description">
A 2D Cartesian point.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>x</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="default">
<code class="language-javascript">0.0</code>
</td>
<td class="description last">
<span class="optional">optional</span>
The X component.</td>
</tr>
<tr>
<td class="name"><code>y</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="default">
<code class="language-javascript">0.0</code>
</td>
<td class="description last">
<span class="optional">optional</span>
The Y component.</td>
</tr>
</tbody>
</table>
<dl class="details">
<h5>See:</h5>
<ul class="see-list">
<li><a href="Cartesian3.html">Cartesian3</a></li>
<li><a href="Cartesian4.html">Cartesian4</a></li>
<li><a href="Packable.html">Packable</a></li>
</ul>
</dl>
</div>
<h3 class="subsection-title">Members</h3>
<div class="nameContainer">
<h4 class="name" id="x">
<a href="#x" class="doc-link"></a>
x<span class="type-signature"> : Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L25">Core/Cartesian2.js 25</a>
</div>
</h4>
</div>
<div class="description">
The X component.
</div>
<dl class="details">
<span class="details-header">Default Value:</span>
<code class="language-javascript">0.0</code>
</dl>
<div class="nameContainer">
<h4 class="name" id="y">
<a href="#y" class="doc-link"></a>
y<span class="type-signature"> : Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L32">Core/Cartesian2.js 32</a>
</div>
</h4>
</div>
<div class="description">
The Y component.
</div>
<dl class="details">
<span class="details-header">Default Value:</span>
<code class="language-javascript">0.0</code>
</dl>
<div class="nameContainer">
<h4 class="name" id=".ONE">
<a href="#.ONE" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> <span class="type-signature attribute-constant">constant</span> Cesium.Cartesian2.ONE<span class="type-signature"> : <a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L728">Core/Cartesian2.js 728</a>
</div>
</h4>
</div>
<div class="description">
An immutable Cartesian2 instance initialized to (1.0, 1.0).
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".packedLength">
<a href="#.packedLength" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.packedLength<span class="type-signature"> : Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L99">Core/Cartesian2.js 99</a>
</div>
</h4>
</div>
<div class="description">
The number of elements used to pack the object into an array.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".UNIT_X">
<a href="#.UNIT_X" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> <span class="type-signature attribute-constant">constant</span> Cesium.Cartesian2.UNIT_X<span class="type-signature"> : <a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L736">Core/Cartesian2.js 736</a>
</div>
</h4>
</div>
<div class="description">
An immutable Cartesian2 instance initialized to (1.0, 0.0).
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".UNIT_Y">
<a href="#.UNIT_Y" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> <span class="type-signature attribute-constant">constant</span> Cesium.Cartesian2.UNIT_Y<span class="type-signature"> : <a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L744">Core/Cartesian2.js 744</a>
</div>
</h4>
</div>
<div class="description">
An immutable Cartesian2 instance initialized to (0.0, 1.0).
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".ZERO">
<a href="#.ZERO" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> <span class="type-signature attribute-constant">constant</span> Cesium.Cartesian2.ZERO<span class="type-signature"> : <a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L720">Core/Cartesian2.js 720</a>
</div>
</h4>
</div>
<div class="description">
An immutable Cartesian2 instance initialized to (0.0, 0.0).
</div>
<dl class="details">
</dl>
<h3 class="subsection-title">Methods</h3>
<div class="nameContainer">
<h4 class="name" id="clone">
<a href="#clone" class="doc-link"></a>
clone<span class="signature">(<span class="optional">result</span>)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L752">Core/Cartesian2.js 752</a>
</div>
</h4>
</div>
<div class="description">
Duplicates this Cartesian2 instance.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
<span class="optional">optional</span>
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter or a new Cartesian2 instance if one was not provided.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id="equals">
<a href="#equals" class="doc-link"></a>
equals<span class="signature">(<span class="optional">right</span>)</span> &rarr; <span class="type-signature returnType">Boolean</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L763">Core/Cartesian2.js 763</a>
</div>
</h4>
</div>
<div class="description">
Compares this Cartesian against the provided Cartesian componentwise and returns
<code>true</code> if they are equal, <code>false</code> otherwise.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
<span class="optional">optional</span>
The right hand side Cartesian.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
<code>true</code> if they are equal, <code>false</code> otherwise.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id="equalsEpsilon">
<a href="#equalsEpsilon" class="doc-link"></a>
equalsEpsilon<span class="signature">(<span class="optional">right</span>, <span class="optional">relativeEpsilon</span>, <span class="optional">absoluteEpsilon</span>)</span> &rarr; <span class="type-signature returnType">Boolean</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L777">Core/Cartesian2.js 777</a>
</div>
</h4>
</div>
<div class="description">
Compares this Cartesian against the provided Cartesian componentwise and returns
<code>true</code> if they pass an absolute or relative tolerance test,
<code>false</code> otherwise.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="default">
</td>
<td class="description last">
<span class="optional">optional</span>
The right hand side Cartesian.</td>
</tr>
<tr>
<td class="name"><code>relativeEpsilon</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="default">
<code class="language-javascript">0</code>
</td>
<td class="description last">
<span class="optional">optional</span>
The relative epsilon tolerance to use for equality testing.</td>
</tr>
<tr>
<td class="name"><code>absoluteEpsilon</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="default">
<code class="language-javascript">relativeEpsilon</code>
</td>
<td class="description last">
<span class="optional">optional</span>
The absolute epsilon tolerance to use for equality testing.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
<code>true</code> if they are within the provided epsilon, <code>false</code> otherwise.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id="toString">
<a href="#toString" class="doc-link"></a>
toString<span class="signature">()</span> &rarr; <span class="type-signature returnType">String</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L795">Core/Cartesian2.js 795</a>
</div>
</h4>
</div>
<div class="description">
Creates a string representing this Cartesian in the format '(x, y)'.
</div>
<h5>Returns:</h5>
<div class="param-desc">
A string representing the provided Cartesian in the format '(x, y)'.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".abs">
<a href="#.abs" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.abs<span class="signature">(cartesian, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L571">Core/Cartesian2.js 571</a>
</div>
</h4>
</div>
<div class="description">
Computes the absolute value of the provided Cartesian.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The Cartesian whose absolute value is to be computed.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".add">
<a href="#.add" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.add<span class="signature">(left, right, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L474">Core/Cartesian2.js 474</a>
</div>
</h4>
</div>
<div class="description">
Computes the componentwise sum of two Cartesians.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The first Cartesian.</td>
</tr>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The second Cartesian.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".angleBetween">
<a href="#.angleBetween" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.angleBetween<span class="signature">(left, right)</span> &rarr; <span class="type-signature returnType">Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L614">Core/Cartesian2.js 614</a>
</div>
</h4>
</div>
<div class="description">
Returns the angle, in radians, between the provided Cartesians.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The first Cartesian.</td>
</tr>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The second Cartesian.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The angle between the Cartesians.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".clone">
<a href="#.clone" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.clone<span class="signature">(cartesian, <span class="optional">result</span>)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L60">Core/Cartesian2.js 60</a>
</div>
</h4>
</div>
<div class="description">
Duplicates a Cartesian2 instance.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The Cartesian to duplicate.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
<span class="optional">optional</span>
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter or a new Cartesian2 instance if one was not provided. (Returns undefined if cartesian is undefined)
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".cross">
<a href="#.cross" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.cross<span class="signature">(left, right)</span> &rarr; <span class="type-signature returnType">Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L417">Core/Cartesian2.js 417</a>
</div>
</h4>
</div>
<div class="description">
Computes the magnitude of the cross product that would result from implicitly setting the Z coordinate of the input vectors to 0
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The first Cartesian.</td>
</tr>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The second Cartesian.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The cross product.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".distance">
<a href="#.distance" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.distance<span class="signature">(left, right)</span> &rarr; <span class="type-signature returnType">Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L335">Core/Cartesian2.js 335</a>
</div>
</h4>
</div>
<div class="description">
Computes the distance between two points.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The first point to compute the distance from.</td>
</tr>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The second point to compute the distance to.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The distance between two points.
</div>
<dl class="details">
<h5>Example:</h5>
<pre><code class="language-javascript">// Returns 1.0
const d = Cesium.Cartesian2.distance(new Cesium.Cartesian2(1.0, 0.0), new Cesium.Cartesian2(2.0, 0.0));</code></pre>
</dl>
<div class="nameContainer">
<h4 class="name" id=".distanceSquared">
<a href="#.distanceSquared" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.distanceSquared<span class="signature">(left, right)</span> &rarr; <span class="type-signature returnType">Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L357">Core/Cartesian2.js 357</a>
</div>
</h4>
</div>
<div class="description">
Computes the squared distance between two points. Comparing squared distances
using this function is more efficient than comparing distances using <code>Cartesian2#distance</code>.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The first point to compute the distance from.</td>
</tr>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The second point to compute the distance to.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The distance between two points.
</div>
<dl class="details">
<h5>Example:</h5>
<pre><code class="language-javascript">// Returns 4.0, not 2.0
const d = Cesium.Cartesian2.distance(new Cesium.Cartesian2(1.0, 0.0), new Cesium.Cartesian2(3.0, 0.0));</code></pre>
</dl>
<div class="nameContainer">
<h4 class="name" id=".divideByScalar">
<a href="#.divideByScalar" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.divideByScalar<span class="signature">(cartesian, scalar, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L534">Core/Cartesian2.js 534</a>
</div>
</h4>
</div>
<div class="description">
Divides the provided Cartesian componentwise by the provided scalar.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The Cartesian to be divided.</td>
</tr>
<tr>
<td class="name"><code>scalar</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="description last">
The scalar to divide by.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".divideComponents">
<a href="#.divideComponents" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.divideComponents<span class="signature">(left, right, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L454">Core/Cartesian2.js 454</a>
</div>
</h4>
</div>
<div class="description">
Computes the componentwise quotient of two Cartesians.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The first Cartesian.</td>
</tr>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The second Cartesian.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".dot">
<a href="#.dot" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.dot<span class="signature">(left, right)</span> &rarr; <span class="type-signature returnType">Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L401">Core/Cartesian2.js 401</a>
</div>
</h4>
</div>
<div class="description">
Computes the dot (scalar) product of two Cartesians.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The first Cartesian.</td>
</tr>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The second Cartesian.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The dot product.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".equals">
<a href="#.equals" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.equals<span class="signature">(<span class="optional">left</span>, <span class="optional">right</span>)</span> &rarr; <span class="type-signature returnType">Boolean</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L661">Core/Cartesian2.js 661</a>
</div>
</h4>
</div>
<div class="description">
Compares the provided Cartesians componentwise and returns
<code>true</code> if they are equal, <code>false</code> otherwise.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
<span class="optional">optional</span>
The first Cartesian.</td>
</tr>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
<span class="optional">optional</span>
The second Cartesian.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
<code>true</code> if left and right are equal, <code>false</code> otherwise.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".equalsEpsilon">
<a href="#.equalsEpsilon" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.equalsEpsilon<span class="signature">(<span class="optional">left</span>, <span class="optional">right</span>, <span class="optional">relativeEpsilon</span>, <span class="optional">absoluteEpsilon</span>)</span> &rarr; <span class="type-signature returnType">Boolean</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L689">Core/Cartesian2.js 689</a>
</div>
</h4>
</div>
<div class="description">
Compares the provided Cartesians componentwise and returns
<code>true</code> if they pass an absolute or relative tolerance test,
<code>false</code> otherwise.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="default">
</td>
<td class="description last">
<span class="optional">optional</span>
The first Cartesian.</td>
</tr>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="default">
</td>
<td class="description last">
<span class="optional">optional</span>
The second Cartesian.</td>
</tr>
<tr>
<td class="name"><code>relativeEpsilon</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="default">
<code class="language-javascript">0</code>
</td>
<td class="description last">
<span class="optional">optional</span>
The relative epsilon tolerance to use for equality testing.</td>
</tr>
<tr>
<td class="name"><code>absoluteEpsilon</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="default">
<code class="language-javascript">relativeEpsilon</code>
</td>
<td class="description last">
<span class="optional">optional</span>
The absolute epsilon tolerance to use for equality testing.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
<code>true</code> if left and right are within the provided epsilon, <code>false</code> otherwise.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".fromArray">
<a href="#.fromArray" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.fromArray<span class="signature">(array, <span class="optional">startingIndex</span>, <span class="optional">result</span>)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L227">Core/Cartesian2.js 227</a>
</div>
</h4>
</div>
<div class="description">
Creates a Cartesian2 from two consecutive elements in an array.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>array</code></td>
<td class="type">
<span class="param-type">Array.&lt;Number></span>
</td>
<td class="default">
</td>
<td class="description last">
The array whose two consecutive elements correspond to the x and y components, respectively.</td>
</tr>
<tr>
<td class="name"><code>startingIndex</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="default">
<code class="language-javascript">0</code>
</td>
<td class="description last">
<span class="optional">optional</span>
The offset into the array of the first element, which corresponds to the x component.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="default">
</td>
<td class="description last">
<span class="optional">optional</span>
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter or a new Cartesian2 instance if one was not provided.
</div>
<dl class="details">
<h5>Example:</h5>
<pre><code class="language-javascript">// Create a Cartesian2 with (1.0, 2.0)
const v = [1.0, 2.0];
const p = Cesium.Cartesian2.fromArray(v);
// Create a Cartesian2 with (1.0, 2.0) using an offset into an array
const v2 = [0.0, 0.0, 1.0, 2.0];
const p2 = Cesium.Cartesian2.fromArray(v2, 2);</code></pre>
</dl>
<div class="nameContainer">
<h4 class="name" id=".fromCartesian3">
<a href="#.fromCartesian3" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.fromCartesian3<span class="signature">(cartesian, <span class="optional">result</span>)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L82">Core/Cartesian2.js 82</a>
</div>
</h4>
</div>
<div class="description">
Creates a Cartesian2 instance from an existing Cartesian3. This simply takes the
x and y properties of the Cartesian3 and drops z.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian3.html">Cartesian3</a></span>
</td>
<td class="description last">
The Cartesian3 instance to create a Cartesian2 instance from.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
<span class="optional">optional</span>
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter or a new Cartesian2 instance if one was not provided.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".fromCartesian4">
<a href="#.fromCartesian4" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.fromCartesian4<span class="signature">(cartesian, <span class="optional">result</span>)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L93">Core/Cartesian2.js 93</a>
</div>
</h4>
</div>
<div class="description">
Creates a Cartesian2 instance from an existing Cartesian4. This simply takes the
x and y properties of the Cartesian4 and drops z and w.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian4.html">Cartesian4</a></span>
</td>
<td class="description last">
The Cartesian4 instance to create a Cartesian2 instance from.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
<span class="optional">optional</span>
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter or a new Cartesian2 instance if one was not provided.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".fromElements">
<a href="#.fromElements" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.fromElements<span class="signature">(x, y, <span class="optional">result</span>)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L43">Core/Cartesian2.js 43</a>
</div>
</h4>
</div>
<div class="description">
Creates a Cartesian2 instance from x and y coordinates.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>x</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="description last">
The x coordinate.</td>
</tr>
<tr>
<td class="name"><code>y</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="description last">
The y coordinate.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
<span class="optional">optional</span>
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter or a new Cartesian2 instance if one was not provided.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".lerp">
<a href="#.lerp" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.lerp<span class="signature">(start, end, t, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L592">Core/Cartesian2.js 592</a>
</div>
</h4>
</div>
<div class="description">
Computes the linear interpolation or extrapolation at t using the provided cartesians.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>start</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The value corresponding to t at 0.0.</td>
</tr>
<tr>
<td class="name"><code>end</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The value corresponding to t at 1.0.</td>
</tr>
<tr>
<td class="name"><code>t</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="description last">
The point along t at which to interpolate.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".magnitude">
<a href="#.magnitude" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.magnitude<span class="signature">(cartesian)</span> &rarr; <span class="type-signature returnType">Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L318">Core/Cartesian2.js 318</a>
</div>
</h4>
</div>
<div class="description">
Computes the Cartesian's magnitude (length).
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The Cartesian instance whose magnitude is to be computed.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The magnitude.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".magnitudeSquared">
<a href="#.magnitudeSquared" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.magnitudeSquared<span class="signature">(cartesian)</span> &rarr; <span class="type-signature returnType">Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L304">Core/Cartesian2.js 304</a>
</div>
</h4>
</div>
<div class="description">
Computes the provided Cartesian's squared magnitude.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The Cartesian instance whose squared magnitude is to be computed.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The squared magnitude.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".maximumByComponent">
<a href="#.maximumByComponent" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.maximumByComponent<span class="signature">(first, second, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L286">Core/Cartesian2.js 286</a>
</div>
</h4>
</div>
<div class="description">
Compares two Cartesians and computes a Cartesian which contains the maximum components of the supplied Cartesians.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>first</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
A cartesian to compare.</td>
</tr>
<tr>
<td class="name"><code>second</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
A cartesian to compare.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object into which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
A cartesian with the maximum components.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".maximumComponent">
<a href="#.maximumComponent" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.maximumComponent<span class="signature">(cartesian)</span> &rarr; <span class="type-signature returnType">Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L235">Core/Cartesian2.js 235</a>
</div>
</h4>
</div>
<div class="description">
Computes the value of the maximum component for the supplied Cartesian.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The cartesian to use.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The value of the maximum component.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".minimumByComponent">
<a href="#.minimumByComponent" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.minimumByComponent<span class="signature">(first, second, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L265">Core/Cartesian2.js 265</a>
</div>
</h4>
</div>
<div class="description">
Compares two Cartesians and computes a Cartesian which contains the minimum components of the supplied Cartesians.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>first</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
A cartesian to compare.</td>
</tr>
<tr>
<td class="name"><code>second</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
A cartesian to compare.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object into which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
A cartesian with the minimum components.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".minimumComponent">
<a href="#.minimumComponent" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.minimumComponent<span class="signature">(cartesian)</span> &rarr; <span class="type-signature returnType">Number</span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L249">Core/Cartesian2.js 249</a>
</div>
</h4>
</div>
<div class="description">
Computes the value of the minimum component for the supplied Cartesian.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The cartesian to use.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The value of the minimum component.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".mostOrthogonalAxis">
<a href="#.mostOrthogonalAxis" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.mostOrthogonalAxis<span class="signature">(cartesian, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L635">Core/Cartesian2.js 635</a>
</div>
</h4>
</div>
<div class="description">
Returns the axis that is most orthogonal to the provided Cartesian.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The Cartesian on which to find the most orthogonal axis.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The most orthogonal axis.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".multiplyByScalar">
<a href="#.multiplyByScalar" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.multiplyByScalar<span class="signature">(cartesian, scalar, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L514">Core/Cartesian2.js 514</a>
</div>
</h4>
</div>
<div class="description">
Multiplies the provided Cartesian componentwise by the provided scalar.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The Cartesian to be scaled.</td>
</tr>
<tr>
<td class="name"><code>scalar</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="description last">
The scalar to multiply with.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".multiplyComponents">
<a href="#.multiplyComponents" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.multiplyComponents<span class="signature">(left, right, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L434">Core/Cartesian2.js 434</a>
</div>
</h4>
</div>
<div class="description">
Computes the componentwise product of two Cartesians.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The first Cartesian.</td>
</tr>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The second Cartesian.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".negate">
<a href="#.negate" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.negate<span class="signature">(cartesian, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L553">Core/Cartesian2.js 553</a>
</div>
</h4>
</div>
<div class="description">
Negates the provided Cartesian.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The Cartesian to be negated.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".normalize">
<a href="#.normalize" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.normalize<span class="signature">(cartesian, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L374">Core/Cartesian2.js 374</a>
</div>
</h4>
</div>
<div class="description">
Computes the normalized form of the supplied Cartesian.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>cartesian</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The Cartesian to be normalized.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".pack">
<a href="#.pack" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.pack<span class="signature">(value, array, <span class="optional">startingIndex</span>)</span> &rarr; <span class="type-signature returnType">Array.&lt;Number></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L110">Core/Cartesian2.js 110</a>
</div>
</h4>
</div>
<div class="description">
Stores the provided instance into the provided array.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>value</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="default">
</td>
<td class="description last">
The value to pack.</td>
</tr>
<tr>
<td class="name"><code>array</code></td>
<td class="type">
<span class="param-type">Array.&lt;Number></span>
</td>
<td class="default">
</td>
<td class="description last">
The array to pack into.</td>
</tr>
<tr>
<td class="name"><code>startingIndex</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="default">
<code class="language-javascript">0</code>
</td>
<td class="description last">
<span class="optional">optional</span>
The index into the array at which to start packing the elements.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The array that was packed into
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".packArray">
<a href="#.packArray" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.packArray<span class="signature">(array, <span class="optional">result</span>)</span> &rarr; <span class="type-signature returnType">Array.&lt;Number></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L154">Core/Cartesian2.js 154</a>
</div>
</h4>
</div>
<div class="description">
Flattens an array of Cartesian2s into an array of components.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>array</code></td>
<td class="type">
<span class="param-type">Array.&lt;<a href="Cartesian2.html">Cartesian2</a>></span>
</td>
<td class="description last">
The array of cartesians to pack.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type">Array.&lt;Number></span>
</td>
<td class="description last">
<span class="optional">optional</span>
The array onto which to store the result. If this is a typed array, it must have array.length * 2 components, else a <a href="DeveloperError.html"><code>DeveloperError</code></a> will be thrown. If it is a regular array, it will be resized to have (array.length * 2) elements.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The packed array.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".subtract">
<a href="#.subtract" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.subtract<span class="signature">(left, right, result)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L494">Core/Cartesian2.js 494</a>
</div>
</h4>
</div>
<div class="description">
Computes the componentwise difference of two Cartesians.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>left</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The first Cartesian.</td>
</tr>
<tr>
<td class="name"><code>right</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The second Cartesian.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="description last">
The object onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".unpack">
<a href="#.unpack" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.unpack<span class="signature">(array, <span class="optional">startingIndex</span>, <span class="optional">result</span>)</span> &rarr; <span class="type-signature returnType"><a href="Cartesian2.html">Cartesian2</a></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L132">Core/Cartesian2.js 132</a>
</div>
</h4>
</div>
<div class="description">
Retrieves an instance from a packed array.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th>Default</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>array</code></td>
<td class="type">
<span class="param-type">Array.&lt;Number></span>
</td>
<td class="default">
</td>
<td class="description last">
The packed array.</td>
</tr>
<tr>
<td class="name"><code>startingIndex</code></td>
<td class="type">
<span class="param-type">Number</span>
</td>
<td class="default">
<code class="language-javascript">0</code>
</td>
<td class="description last">
<span class="optional">optional</span>
The starting index of the element to be unpacked.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type"><a href="Cartesian2.html">Cartesian2</a></span>
</td>
<td class="default">
</td>
<td class="description last">
<span class="optional">optional</span>
The object into which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The modified result parameter or a new Cartesian2 instance if one was not provided.
</div>
<dl class="details">
</dl>
<div class="nameContainer">
<h4 class="name" id=".unpackArray">
<a href="#.unpackArray" class="doc-link"></a>
<span class="type-signature attribute-static">static</span> Cesium.Cartesian2.unpackArray<span class="signature">(array, <span class="optional">result</span>)</span> &rarr; <span class="type-signature returnType">Array.&lt;<a href="Cartesian2.html">Cartesian2</a>></span>
<div class="source-link rightLinks">
<a href="https://github.com/CesiumGS/cesium/blob/1.91/Source/Core/Cartesian2.js#L186">Core/Cartesian2.js 186</a>
</div>
</h4>
</div>
<div class="description">
Unpacks an array of cartesian components into an array of Cartesian2s.
</div>
<table class="params">
<thead>
<tr>
<th>Name</th>
<th>Type</th>
<th class="last">Description</th>
</tr>
</thead>
<tbody>
<tr>
<td class="name"><code>array</code></td>
<td class="type">
<span class="param-type">Array.&lt;Number></span>
</td>
<td class="description last">
The array of components to unpack.</td>
</tr>
<tr>
<td class="name"><code>result</code></td>
<td class="type">
<span class="param-type">Array.&lt;<a href="Cartesian2.html">Cartesian2</a>></span>
</td>
<td class="description last">
<span class="optional">optional</span>
The array onto which to store the result.</td>
</tr>
</tbody>
</table>
<h5>Returns:</h5>
<div class="param-desc">
The unpacked array.
</div>
<dl class="details">
</dl>
</article>
</section>
<footer>
Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.6.10</a>
</footer>
</div>
<div class="nav">
<div class="menu">
<input type="text" class="classFilter" id="ClassFilter" placeholder="Search">
<ul id="ClassList"><li data-name="Animation"><a href="Animation.html">Animation</a></li><li data-name="AnimationViewModel"><a href="AnimationViewModel.html">AnimationViewModel</a></li><li data-name="Appearance"><a href="Appearance.html">Appearance</a></li><li data-name="ArcGisMapServerImageryProvider"><a href="ArcGisMapServerImageryProvider.html">ArcGisMapServerImageryProvider</a></li><li data-name="ArcGISTiledElevationTerrainProvider"><a href="ArcGISTiledElevationTerrainProvider.html">ArcGISTiledElevationTerrainProvider</a></li><li data-name="ArcType"><a href="global.html#ArcType">ArcType</a></li><li data-name="AssociativeArray"><a href="AssociativeArray.html">AssociativeArray</a></li><li data-name="Axis"><a href="global.html#Axis">Axis</a></li><li data-name="AxisAlignedBoundingBox"><a href="AxisAlignedBoundingBox.html">AxisAlignedBoundingBox</a></li><li data-name="backFaceCulling"><a href="global.html#backFaceCulling">backFaceCulling</a></li><li data-name="barycentricCoordinates"><a href="global.html#barycentricCoordinates">barycentricCoordinates</a></li><li data-name="BaseLayerPicker"><a href="BaseLayerPicker.html">BaseLayerPicker</a></li><li data-name="BaseLayerPickerViewModel"><a href="BaseLayerPickerViewModel.html">BaseLayerPickerViewModel</a></li><li data-name="Billboard"><a href="Billboard.html">Billboard</a></li><li data-name="BillboardCollection"><a href="BillboardCollection.html">BillboardCollection</a></li><li data-name="BillboardGraphics"><a href="BillboardGraphics.html">BillboardGraphics</a></li><li data-name="BillboardVisualizer"><a href="BillboardVisualizer.html">BillboardVisualizer</a></li><li data-name="binarySearch"><a href="global.html#binarySearch">binarySearch</a></li><li data-name="binarySearchComparator"><a href="global.html#binarySearchComparator">binarySearchComparator</a></li><li data-name="BingMapsGeocoderService"><a href="BingMapsGeocoderService.html">BingMapsGeocoderService</a></li><li data-name="BingMapsImageryProvider"><a href="BingMapsImageryProvider.html">BingMapsImageryProvider</a></li><li data-name="BingMapsStyle"><a href="global.html#BingMapsStyle">BingMapsStyle</a></li><li data-name="BlendEquation"><a href="global.html#BlendEquation">BlendEquation</a></li><li data-name="BlendFunction"><a href="global.html#BlendFunction">BlendFunction</a></li><li data-name="BlendingState"><a href="BlendingState.html">BlendingState</a></li><li data-name="BlendOption"><a href="global.html#BlendOption">BlendOption</a></li><li data-name="BoundingRectangle"><a href="BoundingRectangle.html">BoundingRectangle</a></li><li data-name="BoundingSphere"><a href="BoundingSphere.html">BoundingSphere</a></li><li data-name="boundingSphere"><a href="global.html#boundingSphere">boundingSphere</a></li><li data-name="BoxEmitter"><a href="BoxEmitter.html">BoxEmitter</a></li><li data-name="BoxGeometry"><a href="BoxGeometry.html">BoxGeometry</a></li><li data-name="BoxGeometryUpdater"><a href="BoxGeometryUpdater.html">BoxGeometryUpdater</a></li><li data-name="BoxGraphics"><a href="BoxGraphics.html">BoxGraphics</a></li><li data-name="BoxOutlineGeometry"><a href="BoxOutlineGeometry.html">BoxOutlineGeometry</a></li><li data-name="buildModuleUrl"><a href="global.html#buildModuleUrl">buildModuleUrl</a></li><li data-name="CallbackProperty"><a href="CallbackProperty.html">CallbackProperty</a></li><li data-name="Camera"><a href="Camera.html">Camera</a></li><li data-name="CameraEventAggregator"><a href="CameraEventAggregator.html">CameraEventAggregator</a></li><li data-name="CameraEventType"><a href="global.html#CameraEventType">CameraEventType</a></li><li data-name="cancelAnimationFrame"><a href="global.html#cancelAnimationFrame">cancelAnimationFrame</a></li><li data-name="Cartesian2"><a href="Cartesian2.html">Cartesian2</a></li><li data-name="Cartesian3"><a href="Cartesian3.html">Cartesian3</a></li><li data-name="Cartesian4"><a href="Cartesian4.html">Cartesian4</a></li><li data-name="Cartographic"><a href="Cartographic.html">Cartographic</a></li><li data-name="CartographicGeocoderService"><a href="CartographicGeocoderServic
</div>
</div>
<script>
if (window.frameElement) {
document.body.className = 'embedded';
var ele = document.createElement('a');
ele.className = 'popout';
ele.target = '_blank';
ele.href = window.location.href;
ele.title = 'Pop out';
document.getElementById('main').appendChild(ele);
}
// Set targets on external links. Sandcastle and GitHub shouldn't be embedded in any iframe.
Array.prototype.forEach.call(document.getElementsByTagName('a'), function(a) {
if (/^https?:/i.test(a.getAttribute('href'))) {
a.target='_blank';
}
});
</script>
<script src="javascript/prism.js"></script>
<script src="javascript/cesiumDoc.js"></script>
</body>
</html>