This commit is contained in:
2025-07-18 15:38:28 +08:00
parent aabaf90482
commit 38b27cd481
2003 changed files with 683103 additions and 0 deletions
@@ -0,0 +1,151 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>程序幾何 | HiAPI-C# 2025 </title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="title" content="程序幾何 | HiAPI-C# 2025 ">
<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="">
<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="">
<h1 id="程序幾何">程序幾何</h1>
<p>程序幾何(RuntimeGeom)是工件幾何在HiNC仿真運作期間的資料格式,由大小不一的正立方線架構網格組成。</p>
<figure class="alert text-bg-light">
<img src="cubesolid.png" alt="cubesolid.png">
<figcaption>程序幾何外觀</figcaption>
</figure>
<figure class="alert text-bg-light">
<img src="cubewire.png" alt="cubewire.png">
<figcaption>程序幾何的正立方線架構網格</figcaption>
</figure>
<h2 id="讀寫程序幾何">讀寫程序幾何</h2>
<p><code>ReadRuntimeGeom</code><code>WriteRuntimeGeom</code>可以讀寫程序幾何至檔案。</p>
<p><code>WriteRuntimeGeomToStl</code>可以將程序幾何轉換為STL並寫入檔案。</p>
<div class="NOTE">
<h5>Note</h5>
<p><strong>指令格式</strong></p>
<pre><code class="lang-csharp">WriteRuntimeGeom(&lt;檔案路徑&gt;);
ReadRuntimeGeom(&lt;檔案路徑&gt;);
WriteRuntimeGeomToStl(&lt;檔案路徑&gt;, &lt;解析度(mm)&gt; = 0);
</code></pre>
<p>&lt;檔案路徑&gt; 的根目錄為專案目錄。</p>
<p>&lt;解析度&gt; 輸出STL時依據的最小工件網格立方體寬度。
該寬度不小於<a href="../Resolution/index.html">實體解析度</a>。若設定本參數小於實體解析度,則等同於設定為實體解析度。
預設值為0,意同採用實體解析度。
解析度越大,則檔案生成速度越快、佔用記憶體空間越小。</p>
</div>
<div class="TIP">
<h5>Tip</h5>
<p><strong>指令範例</strong></p>
<pre><code class="lang-csharp">ReadRuntimeGeom(&quot;Cache/init.wct&quot;);
RunNcFile(&quot;NC/file1.nc&quot;);
WriteRuntimeGeom(&quot;Cache/file1.wct&quot;);
WriteRuntimeGeomToStl(&quot;Output/file1.stl&quot;);
</code></pre>
<p>在仿真開始時,會將幾何模型轉換為程序幾何,轉換時間會依照初始解析度及幾何複雜度有所不同。</p>
<p>如果工件模型會重複使用且轉換時間很長,可以在腳本執行NC指令前搭配使用<code>ReadRuntimeGeom</code><code>WriteRuntimeGeom</code>,節省等待時間。</p>
</div>
</article>
<div class="contribution d-print-none">
</div>
<div class="next-article d-print-none border-top" id="nextArticle"></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>