2026-01-08 21:07:15 +08:00

197 lines
9.5 KiB
HTML

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>Player Panel | HiAPI-C# 2025 </title>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="title" content="Player Panel | 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="player-panel">Player Panel</h1>
<p>The Player Panel is the primary visualization component for machining simulation playback.</p>
<h2 id="key-models">Key Models</h2>
<ul>
<li><a class="xref" href="../../../api/Hi.MachiningProcs.LocalProjectService.html">LocalProjectService</a> - Project data service</li>
<li><a class="xref" href="../../../api/Hi.HiNcKits.UserService.html">UserService</a> - User service</li>
</ul>
<h2 id="associated-tool-bars">Associated Tool Bars</h2>
<ul>
<li><a href="player-tool-bar.html">Player Tool Bar</a></li>
<li><a href="../renderingcanvas-tool-bar.html">RenderingCanvas Tool Bar</a></li>
<li><a href="player-extended-renderingcanvas-tool-bar.html">Player extended RenderingCanvas Tool Bar</a></li>
</ul>
<h2 id="layout-structure">Layout Structure</h2>
<p>The Player Panel consists of:</p>
<ul>
<li><strong>Central Area</strong>: <a href="../../basic/rendering/rendering-canvas/index.html">RenderingCanvas</a> for 3D visualization</li>
<li><strong>Vertical Splitter</strong>: Draggable bar to resize widths</li>
<li><strong>Side Panel</strong>:
<ul>
<li>Upper: <a href="selected-step-info-panel.html">Selected-Step Info Panel</a></li>
<li>Horizontal Splitter: Draggable bar to resize heights</li>
<li>Lower: <a href="../session-message-panel/index.html">Session Message Panel</a></li>
</ul>
</li>
</ul>
<h2 id="default-panel-configuration">Default Panel Configuration</h2>
<p>The Player Panel is set as the default panel on the <code>Page Panel</code> when the main window opens. The associated toolbars (Player Tool Bar, RenderingCanvas Tool Bar, Player Extended RenderingCanvas Tool Bar) are also configured accordingly.</p>
<h2 id="player-extended-renderingcanvas-tool-bar-behavior">Player Extended RenderingCanvas Tool Bar Behavior</h2>
<p>The <a href="player-extended-renderingcanvas-tool-bar.html">Player Extended RenderingCanvas Tool Bar</a> provides additional controls:</p>
<ul>
<li><a href="player-extended-renderingcanvas-tool-bar.html#behavior-of-cl-strip-buttons-and-fit-view-button">CL Strip Buttons and Fit View Button</a> - Controls for CL strip display and view fitting</li>
<li><a href="player-extended-renderingcanvas-tool-bar.html#behavior-of-project-rendering-items-dropdown">Project Rendering Items DropDown</a> - Selection of rendering items</li>
</ul>
<p>The toolbar receives notifications when the project is changed from <a href="../main-panel.html">Main Panel</a>.</p>
<h2 id="related-preference">Related Preference</h2>
<ul>
<li><a href="../preference/step-present-preference-page.html">Step Present Preference Page</a> - Controls step presentation settings</li>
</ul>
<h2 id="renderingcanvas-behavior">RenderingCanvas Behavior</h2>
<p>The RenderingCanvas displays the machining project visualization:</p>
<ol>
<li>On initialization, a <a class="xref" href="../../../api/Hi.MachiningProcs.MachiningProjectDisplayee.html">MachiningProjectDisplayee</a> is created and assigned to <code>RenderingCanvas</code>.<a class="xref" href="../../../api/Hi.Disp.DispEngine.html">DispEngine</a>.<a class="xref" href="../../../api/Hi.Disp.DispEngine.html#Hi_Disp_DispEngine_Displayee">Displayee</a></li>
<li>The displayee receives project data from <a class="xref" href="../../../api/Hi.MachiningProcs.LocalProjectService.html">LocalProjectService</a></li>
<li>The RenderingCanvas is disposed when the Player Panel is disposed</li>
</ol>
<h2 id="source-code-locations">Source Code Locations</h2>
<p>See <a href="../index.html">HiNC GUI Architecture</a> for git repository links.</p>
<h3 id="wpf-application">WPF Application</h3>
<ul>
<li><code>Play/PlayerPanel</code></li>
</ul>
<h3 id="web-application">Web Application</h3>
<p><strong>Frontend:</strong></p>
<ul>
<li><code>wwwroot/player/player-panel.js</code></li>
<li><code>wwwroot/player/player-panel.html</code></li>
</ul>
<p><strong>Backend:</strong></p>
<ul>
<li><code>Players/PlayerController.cs</code></li>
<li><code>Players/PlayerStatusHub.cs</code></li>
<li><code>Players/PlayerStatusService.cs</code></li>
<li><code>Players/SessionMessageHub.cs</code></li>
<li><code>Players/SessionMessageService.cs</code></li>
<li><code>Players/SelectedStepInfoHub.cs</code></li>
<li><code>Players/SelectedStepInfoService.cs</code></li>
</ul>
<h2 id="implementation-checklist">Implementation Checklist</h2>
<div class="TIP">
<h5>Tip</h5>
<p>When building a new Player Panel implementation:</p>
<ol>
<li>Create the layout with RenderingCanvas</li>
<li>Set up RenderingCanvas behavior</li>
<li>Create <a href="player-tool-bar.html">Player Tool Bar</a></li>
<li>Create <a href="player-extended-renderingcanvas-tool-bar.html">Player Extended RenderingCanvas Tool Bar</a> with CL Strip, Fit View, and Rendering Items behaviors</li>
<li>Connect to Navigation Menu on <a href="../main-panel.html">Main Panel</a></li>
<li>Set Player Panel as default panel with associated toolbars</li>
<li>Build <a href="../session-message-panel/index.html">Session Message Panel</a>, <a href="selected-step-info-panel.html">Selected-Step Info Panel</a>, and <a href="../preference/step-present-preference-page.html">Step Present Preference Page</a></li>
</ol>
</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>