2025-07-25 16:27:29 +08:00

1791 lines
44 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Class Box2d | HiAPI-C# 2025 </title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="title" content="Class Box2d | HiAPI-C# 2025 ">
<meta name="description" content="Lightweight 2d box. An orthogonal box which the edges are all parallel with Cartesian Coordinate. The data contains in a is and .">
<link rel="icon" href="../img/HiAPI.favicon.ico">
<link rel="stylesheet" href="../public/docfx.min.css">
<link rel="stylesheet" href="../public/main.css">
<meta name="docfx:navrel" content="../toc.html">
<meta name="docfx:tocrel" content="toc.html">
<meta name="docfx:rel" content="../">
<meta name="loc:inThisArticle" content="In this article">
<meta name="loc:searchResultsCount" content="{count} results for &quot;{query}&quot;">
<meta name="loc:searchNoResults" content="No results for &quot;{query}&quot;">
<meta name="loc:tocFilter" content="Filter by title">
<meta name="loc:nextArticle" content="Next">
<meta name="loc:prevArticle" content="Previous">
<meta name="loc:themeLight" content="Light">
<meta name="loc:themeDark" content="Dark">
<meta name="loc:themeAuto" content="Auto">
<meta name="loc:changeTheme" content="Change theme">
<meta name="loc:copy" content="Copy">
<meta name="loc:downloadPdf" content="Download PDF">
<script type="module" src="./../public/docfx.min.js"></script>
<script>
const theme = localStorage.getItem('theme') || 'auto'
document.documentElement.setAttribute('data-bs-theme', theme === 'auto' ? (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light') : theme)
</script>
</head>
<body class="tex2jax_ignore" data-layout="" data-yaml-mime="ManagedReference">
<header class="bg-body border-bottom">
<nav id="autocollapse" class="navbar navbar-expand-md" role="navigation">
<div class="container-xxl flex-nowrap">
<a class="navbar-brand" href="../index.html">
<img id="logo" class="svg" src="../img/HiAPI.logo.png" alt="">
</a>
<button class="btn btn-lg d-md-none border-0" type="button" data-bs-toggle="collapse" data-bs-target="#navpanel" aria-controls="navpanel" aria-expanded="false" aria-label="Toggle navigation">
<i class="bi bi-three-dots"></i>
</button>
<div class="collapse navbar-collapse" id="navpanel">
<div id="navbar">
<form class="search" role="search" id="search">
<i class="bi bi-search"></i>
<input class="form-control" id="search-query" type="search" disabled placeholder="Search" autocomplete="off" aria-label="Search">
</form>
</div>
</div>
</div>
</nav>
</header>
<main class="container-xxl">
<div class="toc-offcanvas">
<div class="offcanvas-md offcanvas-start" tabindex="-1" id="tocOffcanvas" aria-labelledby="tocOffcanvasLabel">
<div class="offcanvas-header">
<h5 class="offcanvas-title" id="tocOffcanvasLabel">Table of Contents</h5>
<button type="button" class="btn-close" data-bs-dismiss="offcanvas" data-bs-target="#tocOffcanvas" aria-label="Close"></button>
</div>
<div class="offcanvas-body">
<nav class="toc" id="toc"></nav>
</div>
</div>
</div>
<div class="content">
<div class="actionbar">
<button class="btn btn-lg border-0 d-md-none" type="button" data-bs-toggle="offcanvas" data-bs-target="#tocOffcanvas" aria-controls="tocOffcanvas" aria-expanded="false" aria-label="Show table of contents">
<i class="bi bi-list"></i>
</button>
<nav id="breadcrumb"></nav>
</div>
<article data-uid="Hi.Geom.Box2d">
<h1 id="Hi_Geom_Box2d" data-uid="Hi.Geom.Box2d" class="text-break">
Class Box2d
</h1>
<div class="facts text-secondary">
<dl><dt>Namespace</dt><dd><a class="xref" href="Hi.html">Hi</a>.<a class="xref" href="Hi.Geom.html">Geom</a></dd></dl>
<dl><dt>Assembly</dt><dd>HiGeom.dll</dd></dl>
</div>
<div class="markdown summary"><p>Lightweight 2d box.
An orthogonal box which the edges are all parallel with Cartesian Coordinate.
The data contains in a <a class="xref" href="Hi.Geom.Box2d.html">Box2d</a> is <a class="xref" href="Hi.Geom.Box2d.html#Hi_Geom_Box2d_Min">Min</a> and <a class="xref" href="Hi.Geom.Box2d.html#Hi_Geom_Box2d_Max">Max</a>.</p>
</div>
<div class="markdown conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public class Box2d : IExpandToBox2d, IEquatable&lt;Box2d&gt;, IBinaryIo, IWriteBin, IFormattable</code></pre>
</div>
<dl class="typelist inheritance">
<dt>Inheritance</dt>
<dd>
<div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object">object</a></div>
<div><span class="xref">Box2d</span></div>
</dd>
</dl>
<dl class="typelist implements">
<dt>Implements</dt>
<dd>
<div><a class="xref" href="Hi.Geom.IExpandToBox2d.html">IExpandToBox2d</a></div>
<div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.iequatable-1">IEquatable</a>&lt;<a class="xref" href="Hi.Geom.Box2d.html">Box2d</a>&gt;</div>
<div><a class="xref" href="Hi.Common.IBinaryIo.html">IBinaryIo</a></div>
<div><a class="xref" href="Hi.Common.IWriteBin.html">IWriteBin</a></div>
<div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.iformattable">IFormattable</a></div>
</dd>
</dl>
<dl class="typelist inheritedMembers">
<dt>Inherited Members</dt>
<dd>
<div>
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object.equals#system-object-equals(system-object-system-object)">object.Equals(object, object)</a>
</div>
<div>
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object.gettype">object.GetType()</a>
</div>
<div>
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object.memberwiseclone">object.MemberwiseClone()</a>
</div>
<div>
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object.referenceequals">object.ReferenceEquals(object, object)</a>
</div>
</dd></dl>
<dl class="typelist extensionMethods">
<dt>Extension Methods</dt>
<dd>
<div>
<a class="xref" href="Hi.Common.BinIoUtil.html#Hi_Common_BinIoUtil_ToBytes_Hi_Common_IWriteBin_">BinIoUtil.ToBytes(IWriteBin)</a>
</div>
<div>
<a class="xref" href="Hi.Common.DuplicateUtil.html#Hi_Common_DuplicateUtil_TryDuplicate__1___0_System_Object___">DuplicateUtil.TryDuplicate&lt;TSelf&gt;(TSelf, params object[])</a>
</div>
<div>
<a class="xref" href="Hi.Common.InvokeUtil.html#Hi_Common_InvokeUtil_SelfInvoke__1___0_System_Action___0__">InvokeUtil.SelfInvoke&lt;TSrc&gt;(TSrc, Action&lt;TSrc&gt;)</a>
</div>
<div>
<a class="xref" href="Hi.Common.InvokeUtil.html#Hi_Common_InvokeUtil_SelfInvoke__2___0_System_Func___0___1__">InvokeUtil.SelfInvoke&lt;TSrc, TDst&gt;(TSrc, Func&lt;TSrc, TDst&gt;)</a>
</div>
<div>
<a class="xref" href="Hi.Coloring.ColorUtil.html#Hi_Coloring_ColorUtil_GetGloomyColor_System_Object_System_Double_System_Double_">ColorUtil.GetGloomyColor(object, double, double)</a>
</div>
<div>
<a class="xref" href="Hi.Common.NameUtil.html#Hi_Common_NameUtil_GetSelectionName_System_Object_">NameUtil.GetSelectionName(object)</a>
</div>
<div>
<a class="xref" href="Hi.Common.StringUtil.html#Hi_Common_StringUtil_GetPropertyStringIfToStringNotOverloaded_System_Object_System_Boolean_System_Boolean_">StringUtil.GetPropertyStringIfToStringNotOverloaded(object, bool, bool)</a>
</div>
<div>
<a class="xref" href="Hi.Parallels.LockUtil.html#Hi_Parallels_LockUtil_Lock_System_Object_">LockUtil.Lock(object)</a>
</div>
</dd></dl>
<h2 class="section" id="constructors">Constructors
</h2>
<a id="Hi_Geom_Box2d__ctor_" data-uid="Hi.Geom.Box2d.#ctor*"></a>
<h3 id="Hi_Geom_Box2d__ctor" data-uid="Hi.Geom.Box2d.#ctor">
Box2d()
</h3>
<div class="markdown level1 summary"><p>Ctor.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d()</code></pre>
</div>
<a id="Hi_Geom_Box2d__ctor_" data-uid="Hi.Geom.Box2d.#ctor*"></a>
<h3 id="Hi_Geom_Box2d__ctor_Hi_Geom_Box2d_NoInit_" data-uid="Hi.Geom.Box2d.#ctor(Hi.Geom.Box2d.NoInit)">
Box2d(NoInit)
</h3>
<div class="markdown level1 summary"><p>Ctor.
The Ctor keeps <a class="xref" href="Hi.Geom.Box2d.html#Hi_Geom_Box2d_Min">Min</a> and <a class="xref" href="Hi.Geom.Box2d.html#Hi_Geom_Box2d_Max">Max</a> to null.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d(Box2d.NoInit noInit)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>noInit</code> <a class="xref" href="Hi.Geom.Box2d.html">Box2d</a>.<a class="xref" href="Hi.Geom.Box2d.NoInit.html">NoInit</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d__ctor_" data-uid="Hi.Geom.Box2d.#ctor*"></a>
<h3 id="Hi_Geom_Box2d__ctor_Hi_Geom_IExpandToBox2d___" data-uid="Hi.Geom.Box2d.#ctor(Hi.Geom.IExpandToBox2d[])">
Box2d(params IExpandToBox2d[])
</h3>
<div class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="Hi.Geom.Box2d.html">Box2d</a> class that encompasses all the specified objects.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d(params IExpandToBox2d[] src)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>src</code> <a class="xref" href="Hi.Geom.IExpandToBox2d.html">IExpandToBox2d</a>[]</dt>
<dd><p>The objects to include in the box.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d__ctor_" data-uid="Hi.Geom.Box2d.#ctor*"></a>
<h3 id="Hi_Geom_Box2d__ctor_Hi_Geom_Vec2d_Hi_Geom_Vec2d_" data-uid="Hi.Geom.Box2d.#ctor(Hi.Geom.Vec2d,Hi.Geom.Vec2d)">
Box2d(Vec2d, Vec2d)
</h3>
<div class="markdown level1 summary"><p>Ctor.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d(Vec2d min, Vec2d max)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>min</code> <a class="xref" href="Hi.Geom.Vec2d.html">Vec2d</a></dt>
<dd><p><a class="xref" href="Hi.Geom.Box2d.html#Hi_Geom_Box2d_Min">Min</a></p>
</dd>
<dt><code>max</code> <a class="xref" href="Hi.Geom.Vec2d.html">Vec2d</a></dt>
<dd><p><a class="xref" href="Hi.Geom.Box2d.html#Hi_Geom_Box2d_Max">Max</a></p>
</dd>
</dl>
<a id="Hi_Geom_Box2d__ctor_" data-uid="Hi.Geom.Box2d.#ctor*"></a>
<h3 id="Hi_Geom_Box2d__ctor_Hi_Native_box2d_" data-uid="Hi.Geom.Box2d.#ctor(Hi.Native.box2d)">
Box2d(box2d)
</h3>
<div class="markdown level1 summary"><p>Ctor.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d(box2d src)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>src</code> <a class="xref" href="Hi.Native.box2d.html">box2d</a></dt>
<dd><p>src</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d__ctor_" data-uid="Hi.Geom.Box2d.#ctor*"></a>
<h3 id="Hi_Geom_Box2d__ctor_System_Collections_Generic_IEnumerable_Hi_Geom_IExpandToBox2d__" data-uid="Hi.Geom.Box2d.#ctor(System.Collections.Generic.IEnumerable{Hi.Geom.IExpandToBox2d})">
Box2d(IEnumerable&lt;IExpandToBox2d&gt;)
</h3>
<div class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="Hi.Geom.Box2d.html">Box2d</a> class that encompasses all the objects in the specified collection.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d(IEnumerable&lt;IExpandToBox2d&gt; src)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>src</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1">IEnumerable</a>&lt;<a class="xref" href="Hi.Geom.IExpandToBox2d.html">IExpandToBox2d</a>&gt;</dt>
<dd><p>The collection of objects to include in the box.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d__ctor_" data-uid="Hi.Geom.Box2d.#ctor*"></a>
<h3 id="Hi_Geom_Box2d__ctor_System_Double_System_Double_System_Double_System_Double_" data-uid="Hi.Geom.Box2d.#ctor(System.Double,System.Double,System.Double,System.Double)">
Box2d(double, double, double, double)
</h3>
<div class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="Hi.Geom.Box2d.html">Box2d</a> class with the specified minimum and maximum coordinates.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d(double minx, double miny, double maxx, double maxy)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>minx</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd><p>The minimum X coordinate.</p>
</dd>
<dt><code>miny</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd><p>The minimum Y coordinate.</p>
</dd>
<dt><code>maxx</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd><p>The maximum X coordinate.</p>
</dd>
<dt><code>maxy</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd><p>The maximum Y coordinate.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d__ctor_" data-uid="Hi.Geom.Box2d.#ctor*"></a>
<h3 id="Hi_Geom_Box2d__ctor_System_IO_BinaryReader_" data-uid="Hi.Geom.Box2d.#ctor(System.IO.BinaryReader)">
Box2d(BinaryReader)
</h3>
<div class="markdown level1 summary"><p>Initializes a new instance of the <a class="xref" href="Hi.Geom.Box2d.html">Box2d</a> class from binary data.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d(BinaryReader reader)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>reader</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.io.binaryreader">BinaryReader</a></dt>
<dd><p>The binary reader to read the data from.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d__ctor_" data-uid="Hi.Geom.Box2d.#ctor*"></a>
<h3 id="Hi_Geom_Box2d__ctor_System_Xml_Linq_XElement_" data-uid="Hi.Geom.Box2d.#ctor(System.Xml.Linq.XElement)">
Box2d(XElement)
</h3>
<div class="markdown level1 summary"><p>Ctor.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d(XElement src)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>src</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.xml.linq.xelement">XElement</a></dt>
<dd><p>XML</p>
</dd>
</dl>
<h2 class="section" id="properties">Properties
</h2>
<a id="Hi_Geom_Box2d_Center_" data-uid="Hi.Geom.Box2d.Center*"></a>
<h3 id="Hi_Geom_Box2d_Center" data-uid="Hi.Geom.Box2d.Center">
Center
</h3>
<div class="markdown level1 summary"><p>Center</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Vec2d Center { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Vec2d.html">Vec2d</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_CenterUnitBox_" data-uid="Hi.Geom.Box2d.CenterUnitBox*"></a>
<h3 id="Hi_Geom_Box2d_CenterUnitBox" data-uid="Hi.Geom.Box2d.CenterUnitBox">
CenterUnitBox
</h3>
<div class="markdown level1 summary"><p>Generate a center unit box which min~max is (-0.5,-0.5,-0.5)~(-0.5,0.5,0.5).</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Box2d CenterUnitBox { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_DiagonalLength_" data-uid="Hi.Geom.Box2d.DiagonalLength*"></a>
<h3 id="Hi_Geom_Box2d_DiagonalLength" data-uid="Hi.Geom.Box2d.DiagonalLength">
DiagonalLength
</h3>
<div class="markdown level1 summary"><p>Diagonal length.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public double DiagonalLength { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_Dim_" data-uid="Hi.Geom.Box2d.Dim*"></a>
<h3 id="Hi_Geom_Box2d_Dim" data-uid="Hi.Geom.Box2d.Dim">
Dim
</h3>
<div class="markdown level1 summary"><p>Dimension.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Vec2d Dim { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Vec2d.html">Vec2d</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_HasVolume_" data-uid="Hi.Geom.Box2d.HasVolume*"></a>
<h3 id="Hi_Geom_Box2d_HasVolume" data-uid="Hi.Geom.Box2d.HasVolume">
HasVolume
</h3>
<div class="markdown level1 summary"><p>Gets a value indicating whether this box has a non-zero volume.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public bool HasVolume { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_IsAllNaN_" data-uid="Hi.Geom.Box2d.IsAllNaN*"></a>
<h3 id="Hi_Geom_Box2d_IsAllNaN" data-uid="Hi.Geom.Box2d.IsAllNaN">
IsAllNaN
</h3>
<div class="markdown level1 summary"><p>Determines whether all coordinates of this box are NaN.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public bool IsAllNaN { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_IsFinite_" data-uid="Hi.Geom.Box2d.IsFinite*"></a>
<h3 id="Hi_Geom_Box2d_IsFinite" data-uid="Hi.Geom.Box2d.IsFinite">
IsFinite
</h3>
<div class="markdown level1 summary"><p>True if the box is finite.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public bool IsFinite { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_IsReversedPoleBox_" data-uid="Hi.Geom.Box2d.IsReversedPoleBox*"></a>
<h3 id="Hi_Geom_Box2d_IsReversedPoleBox" data-uid="Hi.Geom.Box2d.IsReversedPoleBox">
IsReversedPoleBox
</h3>
<div class="markdown level1 summary"><p>True if the box is <a class="xref" href="Hi.Geom.Box2d.html#Hi_Geom_Box2d_ReversedPoleBox">ReversedPoleBox</a></p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public bool IsReversedPoleBox { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_Max_" data-uid="Hi.Geom.Box2d.Max*"></a>
<h3 id="Hi_Geom_Box2d_Max" data-uid="Hi.Geom.Box2d.Max">
Max
</h3>
<div class="markdown level1 summary"><p>Maximum point of the box.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Vec2d Max { get; set; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Vec2d.html">Vec2d</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_Min_" data-uid="Hi.Geom.Box2d.Min*"></a>
<h3 id="Hi_Geom_Box2d_Min" data-uid="Hi.Geom.Box2d.Min">
Min
</h3>
<div class="markdown level1 summary"><p>Minimum point of the box.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Vec2d Min { get; set; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Vec2d.html">Vec2d</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_NaN_" data-uid="Hi.Geom.Box2d.NaN*"></a>
<h3 id="Hi_Geom_Box2d_NaN" data-uid="Hi.Geom.Box2d.NaN">
NaN
</h3>
<div class="markdown level1 summary"><p>Generate a nan box which min~max is (nan,nan,nan)~(nan,nan,nan).</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Box2d NaN { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_NativeByteSize_" data-uid="Hi.Geom.Box2d.NativeByteSize*"></a>
<h3 id="Hi_Geom_Box2d_NativeByteSize" data-uid="Hi.Geom.Box2d.NativeByteSize">
NativeByteSize
</h3>
<div class="markdown level1 summary"><p>Gets the size in bytes of the native representation of this box.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static int NativeByteSize { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_ReversedPoleBox_" data-uid="Hi.Geom.Box2d.ReversedPoleBox*"></a>
<h3 id="Hi_Geom_Box2d_ReversedPoleBox" data-uid="Hi.Geom.Box2d.ReversedPoleBox">
ReversedPoleBox
</h3>
<div class="markdown level1 summary"><p>Generate a reversed pole box which min~max is (∞,∞,∞)~(-∞,-∞,-∞).</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Box2d ReversedPoleBox { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_UnitBox_" data-uid="Hi.Geom.Box2d.UnitBox*"></a>
<h3 id="Hi_Geom_Box2d_UnitBox" data-uid="Hi.Geom.Box2d.UnitBox">
UnitBox
</h3>
<div class="markdown level1 summary"><p>Generate a unit box which min~max is (0,0,0)~(1,1,1).</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Box2d UnitBox { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_Volume_" data-uid="Hi.Geom.Box2d.Volume*"></a>
<h3 id="Hi_Geom_Box2d_Volume" data-uid="Hi.Geom.Box2d.Volume">
Volume
</h3>
<div class="markdown level1 summary"><p>Gets the volume (area) of this box.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public double Volume { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_XName_" data-uid="Hi.Geom.Box2d.XName*"></a>
<h3 id="Hi_Geom_Box2d_XName" data-uid="Hi.Geom.Box2d.XName">
XName
</h3>
<div class="markdown level1 summary"><p>Name for XML IO.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static string XName { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_ZeroBox_" data-uid="Hi.Geom.Box2d.ZeroBox*"></a>
<h3 id="Hi_Geom_Box2d_ZeroBox" data-uid="Hi.Geom.Box2d.ZeroBox">
ZeroBox
</h3>
<div class="markdown level1 summary"><p>Generate a zero box which min~max is (0,0,0)~(0,0,0).</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public static Box2d ZeroBox { get; }</code></pre>
</div>
<h4 class="section">Property Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd></dd>
</dl>
<h2 class="section" id="methods">Methods
</h2>
<a id="Hi_Geom_Box2d_ApexAt_" data-uid="Hi.Geom.Box2d.ApexAt*"></a>
<h3 id="Hi_Geom_Box2d_ApexAt_System_Int32_" data-uid="Hi.Geom.Box2d.ApexAt(System.Int32)">
ApexAt(int)
</h3>
<div class="markdown level1 summary"><p>Get Apex at the box.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Vec2d ApexAt(int index)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>index</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></dt>
<dd><p>index 0~7. all of 8 apex.</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Vec2d.html">Vec2d</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_Equals_" data-uid="Hi.Geom.Box2d.Equals*"></a>
<h3 id="Hi_Geom_Box2d_Equals_Hi_Geom_Box2d_" data-uid="Hi.Geom.Box2d.Equals(Hi.Geom.Box2d)">
Equals(Box2d)
</h3>
<div class="markdown level1 summary"><p>Indicates whether the current object is equal to another object of the same type.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public bool Equals(Box2d other)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>other</code> <a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>An object to compare with this object.</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></dt>
<dd><p><a href="https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool">true</a> if the current object is equal to the <code class="paramref">other</code> parameter; otherwise, <a href="https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool">false</a>.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_Equals_" data-uid="Hi.Geom.Box2d.Equals*"></a>
<h3 id="Hi_Geom_Box2d_Equals_System_Object_" data-uid="Hi.Geom.Box2d.Equals(System.Object)">
Equals(object)
</h3>
<div class="markdown level1 summary"><p>Determines whether the specified object is equal to the current object.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public override bool Equals(object obj)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>obj</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object">object</a></dt>
<dd><p>The object to compare with the current object.</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></dt>
<dd><p><a href="https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool">true</a> if the specified object is equal to the current object; otherwise, <a href="https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool">false</a>.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_Expand_" data-uid="Hi.Geom.Box2d.Expand*"></a>
<h3 id="Hi_Geom_Box2d_Expand_Hi_Geom_Box2d_" data-uid="Hi.Geom.Box2d.Expand(Hi.Geom.Box2d)">
Expand(Box2d)
</h3>
<div class="markdown level1 summary"><p>Expands this box to include the specified box.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d Expand(Box2d src)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>src</code> <a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>The box to include.</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>This box instance after expansion.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_Expand_" data-uid="Hi.Geom.Box2d.Expand*"></a>
<h3 id="Hi_Geom_Box2d_Expand_Hi_Geom_Vec2d_" data-uid="Hi.Geom.Box2d.Expand(Hi.Geom.Vec2d)">
Expand(Vec2d)
</h3>
<div class="markdown level1 summary"><p>Expands this box to include the specified point.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d Expand(Vec2d p)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>p</code> <a class="xref" href="Hi.Geom.Vec2d.html">Vec2d</a></dt>
<dd><p>The point to include in the box.</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>This box instance after expansion.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_ExpandToBox2d_" data-uid="Hi.Geom.Box2d.ExpandToBox2d*"></a>
<h3 id="Hi_Geom_Box2d_ExpandToBox2d_Hi_Geom_Box2d_" data-uid="Hi.Geom.Box2d.ExpandToBox2d(Hi.Geom.Box2d)">
ExpandToBox2d(Box2d)
</h3>
<div class="markdown level1 summary"><p>Expands the specified destination box to include this box.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public void ExpandToBox2d(Box2d dst)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>dst</code> <a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>The destination box to expand.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_GetHashCode_" data-uid="Hi.Geom.Box2d.GetHashCode*"></a>
<h3 id="Hi_Geom_Box2d_GetHashCode" data-uid="Hi.Geom.Box2d.GetHashCode">
GetHashCode()
</h3>
<div class="markdown level1 summary"><p>Serves as the default hash function.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public override int GetHashCode()</code></pre>
</div>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></dt>
<dd><p>A hash code for the current object.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_IsOverlapped_" data-uid="Hi.Geom.Box2d.IsOverlapped*"></a>
<h3 id="Hi_Geom_Box2d_IsOverlapped_Hi_Geom_Box2d_" data-uid="Hi.Geom.Box2d.IsOverlapped(Hi.Geom.Box2d)">
IsOverlapped(Box2d)
</h3>
<div class="markdown level1 summary"><p>Is the box overlapped to <code class="paramref">otherBox</code>.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public bool IsOverlapped(Box2d otherBox)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>otherBox</code> <a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>other box</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.boolean">bool</a></dt>
<dd><p>is overlapped</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_MakeXmlSource_" data-uid="Hi.Geom.Box2d.MakeXmlSource*"></a>
<h3 id="Hi_Geom_Box2d_MakeXmlSource_System_String_" data-uid="Hi.Geom.Box2d.MakeXmlSource(System.String)">
MakeXmlSource(string)
</h3>
<div class="markdown level1 summary"></div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public XElement MakeXmlSource(string baseDirectory)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>baseDirectory</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></dt>
<dd></dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.xml.linq.xelement">XElement</a></dt>
<dd></dd>
</dl>
<a id="Hi_Geom_Box2d_ReadBin_" data-uid="Hi.Geom.Box2d.ReadBin*"></a>
<h3 id="Hi_Geom_Box2d_ReadBin_System_IO_BinaryReader_" data-uid="Hi.Geom.Box2d.ReadBin(System.IO.BinaryReader)">
ReadBin(BinaryReader)
</h3>
<div class="markdown level1 summary"><p>Reads binary data to initialize the object.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public void ReadBin(BinaryReader reader)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>reader</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.io.binaryreader">BinaryReader</a></dt>
<dd><p>The binary reader to read from</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_Scale_" data-uid="Hi.Geom.Box2d.Scale*"></a>
<h3 id="Hi_Geom_Box2d_Scale_System_Double_" data-uid="Hi.Geom.Box2d.Scale(System.Double)">
Scale(double)
</h3>
<div class="markdown level1 summary"><p>Scale the box from the coordinate origin.
The operation is equal to:</p>
<pre><code class="lang-csharp">Min *= s;
Max *= s;</code></pre>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d Scale(double s)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>s</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd><p>scale</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>this</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_ScaleFromCenter_" data-uid="Hi.Geom.Box2d.ScaleFromCenter*"></a>
<h3 id="Hi_Geom_Box2d_ScaleFromCenter_System_Double_" data-uid="Hi.Geom.Box2d.ScaleFromCenter(System.Double)">
ScaleFromCenter(double)
</h3>
<div class="markdown level1 summary"><p>Scales this box from its center by the specified factor.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d ScaleFromCenter(double s)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>s</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd><p>The scale factor.</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>This box instance after scaling.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_Set_" data-uid="Hi.Geom.Box2d.Set*"></a>
<h3 id="Hi_Geom_Box2d_Set_Hi_Geom_Box2d_" data-uid="Hi.Geom.Box2d.Set(Hi.Geom.Box2d)">
Set(Box2d)
</h3>
<div class="markdown level1 summary"><p>Copy the <code class="paramref">src</code>.
The <a class="xref" href="Hi.Geom.Box2d.html#Hi_Geom_Box2d_Min">Min</a> and <a class="xref" href="Hi.Geom.Box2d.html#Hi_Geom_Box2d_Max">Max</a> are kept the same object. Only the double values changed.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d Set(Box2d src)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>src</code> <a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>src</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>this</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_Set_" data-uid="Hi.Geom.Box2d.Set*"></a>
<h3 id="Hi_Geom_Box2d_Set_Hi_Native_box2d_" data-uid="Hi.Geom.Box2d.Set(Hi.Native.box2d)">
Set(box2d)
</h3>
<div class="markdown level1 summary"><p>Copy the <code class="paramref">src</code>.
The <a class="xref" href="Hi.Geom.Box2d.html#Hi_Geom_Box2d_Min">Min</a> and <a class="xref" href="Hi.Geom.Box2d.html#Hi_Geom_Box2d_Max">Max</a> are kept the same object. Only the double values changed.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d Set(box2d src)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>src</code> <a class="xref" href="Hi.Native.box2d.html">box2d</a></dt>
<dd><p>src</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>this</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_Set_" data-uid="Hi.Geom.Box2d.Set*"></a>
<h3 id="Hi_Geom_Box2d_Set_System_Double_System_Double_System_Double_System_Double_" data-uid="Hi.Geom.Box2d.Set(System.Double,System.Double,System.Double,System.Double)">
Set(double, double, double, double)
</h3>
<div class="markdown level1 summary"><p>Sets the minimum and maximum coordinates of this box.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d Set(double minx, double miny, double maxx, double maxy)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>minx</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd><p>The minimum X coordinate.</p>
</dd>
<dt><code>miny</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd><p>The minimum Y coordinate.</p>
</dd>
<dt><code>maxx</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd><p>The maximum X coordinate.</p>
</dd>
<dt><code>maxy</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd><p>The maximum Y coordinate.</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>This box instance.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_ToString_" data-uid="Hi.Geom.Box2d.ToString*"></a>
<h3 id="Hi_Geom_Box2d_ToString" data-uid="Hi.Geom.Box2d.ToString">
ToString()
</h3>
<div class="markdown level1 summary"><p>Returns a string that represents the current object.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public override string ToString()</code></pre>
</div>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></dt>
<dd><p>A string that represents the current object.</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_ToString_" data-uid="Hi.Geom.Box2d.ToString*"></a>
<h3 id="Hi_Geom_Box2d_ToString_System_String_System_IFormatProvider_" data-uid="Hi.Geom.Box2d.ToString(System.String,System.IFormatProvider)">
ToString(string, IFormatProvider)
</h3>
<div class="markdown level1 summary"><p>Returns a string representation of the box formatted according to the specified format.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public string ToString(string format, IFormatProvider formatProvider)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>format</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></dt>
<dd><p>The format to use for each component</p>
</dd>
<dt><code>formatProvider</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.iformatprovider">IFormatProvider</a></dt>
<dd><p>The format provider to use</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.string">string</a></dt>
<dd><p>A formatted string representation of the box</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_Translate_" data-uid="Hi.Geom.Box2d.Translate*"></a>
<h3 id="Hi_Geom_Box2d_Translate_Hi_Geom_Vec2d_" data-uid="Hi.Geom.Box2d.Translate(Hi.Geom.Vec2d)">
Translate(Vec2d)
</h3>
<div class="markdown level1 summary"><p>Translate the box.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public Box2d Translate(Vec2d vec)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>vec</code> <a class="xref" href="Hi.Geom.Vec2d.html">Vec2d</a></dt>
<dd><p>translation vector</p>
</dd>
</dl>
<h4 class="section">Returns</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Geom.Box2d.html">Box2d</a></dt>
<dd><p>this</p>
</dd>
</dl>
<a id="Hi_Geom_Box2d_WriteBin_" data-uid="Hi.Geom.Box2d.WriteBin*"></a>
<h3 id="Hi_Geom_Box2d_WriteBin_System_IO_BinaryWriter_" data-uid="Hi.Geom.Box2d.WriteBin(System.IO.BinaryWriter)">
WriteBin(BinaryWriter)
</h3>
<div class="markdown level1 summary"><p>Writes the box data to a binary writer.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public void WriteBin(BinaryWriter writer)</code></pre>
</div>
<h4 class="section">Parameters</h4>
<dl class="parameters">
<dt><code>writer</code> <a class="xref" href="https://learn.microsoft.com/dotnet/api/system.io.binarywriter">BinaryWriter</a></dt>
<dd><p>The binary writer to write the data to.</p>
</dd>
</dl>
</article>
<div class="contribution d-print-none">
</div>
</div>
<div class="affix">
<nav id="affix"></nav>
</div>
</main>
<div class="container-xxl search-results" id="search-results"></div>
<footer class="border-top text-secondary">
<div class="container-xxl">
<div class="flex-fill">
<span> Copyright © 2025 <a href='https://superhightech.com.tw'>Tech Coordinate</a>. All rights reserved. <a href='https://superhightech.com.tw'>超級高科技股份有限公司</a> © 2025 版權所有 </span>
</div>
</div>
</footer>
</body>
</html>