2025-07-18 15:38:28 +08:00

617 lines
16 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Struct bind_t | HiAPI-C# 2025 </title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="title" content="Struct bind_t | HiAPI-C# 2025 ">
<meta name="description" content="Runtime rendering data for each iteration in rendering loop. It manipulates geometry transformation, such as moving, rotatingand scaling. It also deal with color and picking. A bind_t object is generated by rendering in the every beginning of each rendering iteration.">
<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.Native.bind_t">
<h1 id="Hi_Native_bind_t" data-uid="Hi.Native.bind_t" class="text-break">
Struct bind_t
</h1>
<div class="facts text-secondary">
<dl><dt>Namespace</dt><dd><a class="xref" href="Hi.html">Hi</a>.<a class="xref" href="Hi.Native.html">Native</a></dd></dl>
<dl><dt>Assembly</dt><dd>HiDisp.dll</dd></dl>
</div>
<div class="markdown summary"><p>Runtime rendering data for each iteration in rendering loop.
It manipulates geometry transformation, such as moving, rotatingand scaling.
It also deal with color and picking.
A bind_t object is generated by rendering in the every beginning of each rendering iteration.</p>
</div>
<div class="markdown conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public struct bind_t</code></pre>
</div>
<dl class="typelist inheritedMembers">
<dt>Inherited Members</dt>
<dd>
<div>
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.valuetype.equals">ValueType.Equals(object)</a>
</div>
<div>
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.valuetype.gethashcode">ValueType.GetHashCode()</a>
</div>
<div>
<a class="xref" href="https://learn.microsoft.com/dotnet/api/system.valuetype.tostring">ValueType.ToString()</a>
</div>
<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.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.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.Common.MaskUtil.html#Hi_Common_MaskUtil_GetMaskedValue__1___0___0_System_Boolean_">MaskUtil.GetMaskedValue&lt;T&gt;(T, T, bool)</a>
</div>
<div>
<a class="xref" href="Hi.Common.MaskUtil.html#Hi_Common_MaskUtil_SetMask__1___0____0_System_Boolean_">MaskUtil.SetMask&lt;T&gt;(ref T, T, bool)</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="fields">Fields
</h2>
<h3 id="Hi_Native_bind_t_height" data-uid="Hi.Native.bind_t.height">
height
</h3>
<div class="markdown level1 summary"><p>Canvas height.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public int height</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></dt>
<dd></dd>
</dl>
<h3 id="Hi_Native_bind_t_is_picking_mode" data-uid="Hi.Native.bind_t.is_picking_mode">
is_picking_mode
</h3>
<div class="markdown level1 summary"><p>Is picking mode.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public int is_picking_mode</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></dt>
<dd></dd>
</dl>
<h3 id="Hi_Native_bind_t_models" data-uid="Hi.Native.bind_t.models">
models
</h3>
<div class="markdown level1 summary"><p>Model matrixes in MVP convention.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public mat_stack_t models</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Native.mat_stack_t.html">mat_stack_t</a></dt>
<dd></dd>
</dl>
<h3 id="Hi_Native_bind_t_picking_id" data-uid="Hi.Native.bind_t.picking_id">
picking_id
</h3>
<div class="markdown level1 summary"><p>Current picking id.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public int picking_id</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></dt>
<dd></dd>
</dl>
<h3 id="Hi_Native_bind_t_pixelProj" data-uid="Hi.Native.bind_t.pixelProj">
pixelProj
</h3>
<div class="markdown level1 summary"><p>Pixel mapping part of the projection matrix in MVP convention.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public mat4d pixelProj</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Native.mat4d.html">mat4d</a></dt>
<dd></dd>
</dl>
<dl class="typelist seealso">
<dt>See Also</dt>
<dd>
<div><a class="xref" href="Hi.Native.bind_t.html#Hi_Native_bind_t_projMat">projMat</a></div>
</dd>
</dl>
<h3 id="Hi_Native_bind_t_pixel_width_on_model" data-uid="Hi.Native.bind_t.pixel_width_on_model">
pixel_width_on_model
</h3>
<div class="markdown level1 summary"><p>Pixel width on model layer.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public double pixel_width_on_model</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.double">double</a></dt>
<dd></dd>
</dl>
<h3 id="Hi_Native_bind_t_projMat" data-uid="Hi.Native.bind_t.projMat">
projMat
</h3>
<div class="markdown level1 summary"><p>Projection matrix in MVP convention. Equal to <a class="xref" href="Hi.Native.bind_t.html#Hi_Native_bind_t_scaleProj">scaleProj</a> * <a class="xref" href="Hi.Native.bind_t.html#Hi_Native_bind_t_pixelProj">pixelProj</a>.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public mat4d projMat</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Native.mat4d.html">mat4d</a></dt>
<dd></dd>
</dl>
<h3 id="Hi_Native_bind_t_rgb" data-uid="Hi.Native.bind_t.rgb">
rgb
</h3>
<div class="markdown level1 summary"><p>Current color (rgb).</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public vec3f rgb</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Native.vec3f.html">vec3f</a></dt>
<dd></dd>
</dl>
<h3 id="Hi_Native_bind_t_scaleProj" data-uid="Hi.Native.bind_t.scaleProj">
scaleProj
</h3>
<div class="markdown level1 summary"><p>Scale part of the projection matrix in MVP convention.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public mat4d scaleProj</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Native.mat4d.html">mat4d</a></dt>
<dd></dd>
</dl>
<dl class="typelist seealso">
<dt>See Also</dt>
<dd>
<div><a class="xref" href="Hi.Native.bind_t.html#Hi_Native_bind_t_projMat">projMat</a></div>
</dd>
</dl>
<h3 id="Hi_Native_bind_t_sparkle_rate" data-uid="Hi.Native.bind_t.sparkle_rate">
sparkle_rate
</h3>
<div class="markdown level1 summary"><p>Sparkle rate of specular light. The rate only effects on the Drawing which contains N(normal) value.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public float sparkle_rate</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.single">float</a></dt>
<dd></dd>
</dl>
<h3 id="Hi_Native_bind_t_view" data-uid="Hi.Native.bind_t.view">
view
</h3>
<div class="markdown level1 summary"><p>View matrix in MVP convention.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public mat4d view</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Native.mat4d.html">mat4d</a></dt>
<dd></dd>
</dl>
<h3 id="Hi_Native_bind_t_vpMat" data-uid="Hi.Native.bind_t.vpMat">
vpMat
</h3>
<div class="markdown level1 summary"><p><a class="xref" href="Hi.Native.bind_t.html#Hi_Native_bind_t_view">view</a> * <a class="xref" href="Hi.Native.bind_t.html#Hi_Native_bind_t_projMat">projMat</a>.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public mat4d vpMat</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="Hi.Native.mat4d.html">mat4d</a></dt>
<dd></dd>
</dl>
<h3 id="Hi_Native_bind_t_width" data-uid="Hi.Native.bind_t.width">
width
</h3>
<div class="markdown level1 summary"><p>Canvas width.</p>
</div>
<div class="markdown level1 conceptual"></div>
<div class="codewrapper">
<pre><code class="lang-csharp hljs">public int width</code></pre>
</div>
<h4 class="section">Field Value</h4>
<dl class="parameters">
<dt><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.int32">int</a></dt>
<dd></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>