<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: zhangly1403</title>
    <description>The latest articles on DEV Community by zhangly1403 (@zly258).</description>
    <link>https://dev.to/zly258</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4265878%2F647e7aa6-d1d3-4900-ab12-6671a0d6f04f.png</url>
      <title>DEV Community: zhangly1403</title>
      <link>https://dev.to/zly258</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/zly258"/>
    <language>en</language>
    <item>
      <title>P3dPyPad: F5 Hot-Reload Python Workbench &amp; WASM 3D Studio for AutoCAD Plant 3D</title>
      <dc:creator>zhangly1403</dc:creator>
      <pubDate>Thu, 26 Nov 2026 04:38:53 +0000</pubDate>
      <link>https://dev.to/zly258/p3dpypad-f5-hot-reload-python-workbench-wasm-3d-studio-for-autocad-plant-3d-3fd1</link>
      <guid>https://dev.to/zly258/p3dpypad-f5-hot-reload-python-workbench-wasm-3d-studio-for-autocad-plant-3d-3fd1</guid>
      <description>&lt;p&gt;Developing parametric Python components for &lt;strong&gt;AutoCAD Plant 3D&lt;/strong&gt; has a major productivity bottleneck: because of Python module caching inside the AutoCAD process, modifying a script normally forces you to restart AutoCAD (often 30–60 seconds per iteration).&lt;/p&gt;

&lt;p&gt;I built and open-sourced &lt;strong&gt;P3dPyPad&lt;/strong&gt; (GPL-3.0) to fix this workflow and add offline simulation + batch testing.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Live WASM 3D Demo&lt;/strong&gt;: &lt;a href="https://zly258.github.io/P3dPyPad/" rel="noopener noreferrer"&gt;https://zly258.github.io/P3dPyPad/&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;GitHub&lt;/strong&gt;: &lt;a href="https://github.com/zly258/P3dPyPad" rel="noopener noreferrer"&gt;https://github.com/zly258/P3dPyPad&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  What's Included
&lt;/h2&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Zero-Restart F5 Hot Reload (&lt;code&gt;PYPAD&lt;/code&gt;)&lt;/strong&gt;: Uses an in-memory proxy (&lt;code&gt;DEV_PROXY.py&lt;/code&gt;) and &lt;code&gt;PnP3dACPAdapter.arx&lt;/code&gt; so pressing &lt;code&gt;F5&lt;/code&gt; regenerates and replaces 3D solids directly in the active Plant 3D viewport without restarting AutoCAD.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Automated Batch Testing (&lt;code&gt;PYBATCH&lt;/code&gt; / &lt;code&gt;PYBATCH_RUN&lt;/code&gt;)&lt;/strong&gt;: Recursively validates directories of &lt;code&gt;.py&lt;/code&gt; scripts, captures isometric previews, and surfaces Python stack traces for CI/regression checks.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Standalone PyOCC Offline Workbench (&lt;code&gt;plant3d_occ/&lt;/code&gt;)&lt;/strong&gt;: Aligns Plant 3D geometric primitives on &lt;strong&gt;Python 3 + OpenCASCADE (&lt;code&gt;pythonocc-core 7.7+&lt;/code&gt;)&lt;/strong&gt; and &lt;strong&gt;PySide6&lt;/strong&gt;, supporting offline modeling, 45-degree architectural-tick dimensioning, and &lt;code&gt;.acat&lt;/code&gt;/&lt;code&gt;.pcat&lt;/code&gt;/&lt;code&gt;.peqx&lt;/code&gt;/SQLite publishing without launching AutoCAD.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Zero-Dependency WebAssembly 3D Studio (&lt;code&gt;web/&lt;/code&gt;)&lt;/strong&gt;: Runs OpenCASCADE WASM (&lt;code&gt;occt.js&lt;/code&gt;) and Three.js in the browser with orthographic CAD controls and isometric PNG export.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;494 Parametric Component Scripts (&lt;code&gt;pyscripts/&lt;/code&gt;)&lt;/strong&gt;: Covers fittings, flanges, valves, instruments, equipment, and pipe supports (CD/ZD 2010 and HG/T 21629) with co-located &lt;code&gt;.csv&lt;/code&gt; spec tables.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Dual-Target .NET Plugin&lt;/strong&gt;: Multi-targets &lt;code&gt;net472&lt;/code&gt; (AutoCAD Plant 3D 2019–2024) and &lt;code&gt;net8.0-windows&lt;/code&gt; (2025–2026) in a single &lt;code&gt;P3dPyPad.bundle&lt;/code&gt; package.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Current Limitations
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;The in-process CAD plugin targets Windows AutoCAD Plant 3D, though the PyOCC workbench and browser WASM studio run standalone.&lt;/li&gt;
&lt;li&gt;Licensed under &lt;strong&gt;GPL-3.0&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Try out the browser WASM studio or check out the component scripts on GitHub!&lt;/p&gt;

</description>
      <category>cad</category>
      <category>python</category>
      <category>webassembly</category>
      <category>opensource</category>
    </item>
    <item>
      <title>OcctCSharpBridge 3.0: Bridging Open CASCADE 7.9.0 to .NET 8/9/10 for CAD &amp; BIM Apps</title>
      <dc:creator>zhangly1403</dc:creator>
      <pubDate>Thu, 26 Nov 2026 04:33:15 +0000</pubDate>
      <link>https://dev.to/zly258/occtcsharpbridge-30-bridging-open-cascade-790-to-net-8910-for-cad-bim-apps-4ke9</link>
      <guid>https://dev.to/zly258/occtcsharpbridge-30-bridging-open-cascade-790-to-net-8910-for-cad-bim-apps-4ke9</guid>
      <description>&lt;p&gt;Integrating &lt;strong&gt;Open CASCADE Technology (OCCT)&lt;/strong&gt;—the industry-standard open-source C++ B-Rep geometry kernel—into modern &lt;strong&gt;.NET (C#)&lt;/strong&gt; desktop applications usually requires writing fragile, boilerplate-heavy C++/CLI glue code and manually managing OCCT's &lt;code&gt;Handle(Standard_Transient)&lt;/code&gt; reference counting against the .NET GC.&lt;/p&gt;

&lt;p&gt;I open-sourced &lt;strong&gt;OcctCSharpBridge&lt;/strong&gt; to provide a reusable &lt;strong&gt;OCCT 7.9.0 → .NET&lt;/strong&gt; bridge for CAD, BIM, and engineering applications.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;GitHub&lt;/strong&gt;: &lt;a href="https://github.com/zly258/OcctCSharpBridge" rel="noopener noreferrer"&gt;https://github.com/zly258/OcctCSharpBridge&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Unified Demo Branch&lt;/strong&gt;: &lt;a href="https://github.com/zly258/OcctCSharpBridge/tree/demo" rel="noopener noreferrer"&gt;https://github.com/zly258/OcctCSharpBridge/tree/demo&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Baseline &amp;amp; Architecture
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;OCCT Version&lt;/strong&gt;: 7.9.0&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Native ABI&lt;/strong&gt;: ABI 5&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Managed Targets&lt;/strong&gt;: &lt;code&gt;.NET 8 / 9 / 10&lt;/code&gt; (built with .NET 10 SDK)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;UI Frameworks&lt;/strong&gt;: WinForms, WPF, and Avalonia on Windows (&lt;code&gt;win-x64&lt;/code&gt;); Avalonia source build on Linux&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;SDK Distribution&lt;/strong&gt;: Installs as a shared Windows x64 SDK (&lt;code&gt;C:\Program Files\OcctCSharpBridge\SDK\3.0\win-x64&lt;/code&gt; or via &lt;code&gt;OCCTCSHARPBRIDGE_SDK&lt;/code&gt;) so consumer apps reference the system SDK directly without duplicating copies across repos.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  What It Solves
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Exposes OCCT B-Rep modeling, boolean operations, STEP/IGES/BREP import &amp;amp; export, and 3D visualization to managed C# code.&lt;/li&gt;
&lt;li&gt;Eliminates the need for every .NET CAD/BIM team to maintain custom C++/CLI wrappers from scratch.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Current Limitations
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Official prebuilt binaries target &lt;strong&gt;Windows x64&lt;/strong&gt; (Linux Avalonia requires building from source).&lt;/li&gt;
&lt;li&gt;Requires matching the OCCT 7.9.0 runtime.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you are building CAD/BIM tools in C# / .NET / Avalonia and using Open CASCADE under the hood, feedback and contributions are welcome!&lt;/p&gt;

</description>
      <category>dotnet</category>
      <category>cad</category>
      <category>opensource</category>
      <category>csharp</category>
    </item>
    <item>
      <title>3dbrowser: Streaming a 2.9GB / 186M-Triangle BIM Model in Three.js Under ~3GB JS Heap</title>
      <dc:creator>zhangly1403</dc:creator>
      <pubDate>Thu, 26 Nov 2026 04:30:32 +0000</pubDate>
      <link>https://dev.to/zly258/3dbrowser-streaming-a-29gb-186m-triangle-bim-model-in-threejs-under-3gb-js-heap-2mjb</link>
      <guid>https://dev.to/zly258/3dbrowser-streaming-a-29gb-186m-triangle-bim-model-in-threejs-under-3gb-js-heap-2mjb</guid>
      <description>&lt;p&gt;Standard web glTF/OBJ viewers usually run out of memory or stall for minutes when given multi-gigabyte industrial or BIM assemblies. I built and open-sourced &lt;strong&gt;3dbrowser&lt;/strong&gt; (GPL-3.0) to keep browser memory bounded and render the first frame quickly.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;GitHub&lt;/strong&gt;: &lt;a href="https://github.com/zly258/3dbrowser" rel="noopener noreferrer"&gt;https://github.com/zly258/3dbrowser&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Tech Stack&lt;/strong&gt;: React 19, Three.js, TypeScript, WebAssembly (&lt;code&gt;web-ifc&lt;/code&gt;, &lt;code&gt;occt-import-js&lt;/code&gt;)&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Why a Custom Streaming Format?
&lt;/h2&gt;

&lt;p&gt;When a 2+ GB BIM or plant assembly is exported to plain glTF/JSON, parsing and expanding it in the browser easily multiplies memory usage several times over, crashing the tab. Even if it fits in memory, hundreds of thousands of separate meshes produce too many WebGL draw calls.&lt;/p&gt;

&lt;p&gt;&lt;code&gt;3dbrowser&lt;/code&gt; is designed around six-figure component counts from the ground up:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;NBIM v11 Single-File Container&lt;/strong&gt;: Packs geometry, properties, and the structure tree into one binary container (with fixed-point coordinate quantization and columnar blocks).&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Octree Chunk Streaming&lt;/strong&gt;: Instead of waiting for the entire file to download before rendering, chunks stream in by spatial octree so the first frame appears in ~3–4.5s.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Three.js &lt;code&gt;BatchedMesh&lt;/code&gt;&lt;/strong&gt;: Merges heterogeneous components sharing materials into far fewer draw calls to maintain smooth frame rates.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;On-Demand Property Resolution&lt;/strong&gt;: Component metadata is resolved when selected rather than kept resident in memory alongside geometry.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Benchmark &amp;amp; Capabilities
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Tested on a &lt;strong&gt;2.9 GB&lt;/strong&gt; NBIM file (&lt;strong&gt;231,353 components&lt;/strong&gt;, &lt;strong&gt;186 million rendered triangles&lt;/strong&gt;) in a single browser tab while keeping JS heap under &lt;strong&gt;~3 GB&lt;/strong&gt;.&lt;/li&gt;
&lt;li&gt;Supports &lt;strong&gt;IFC&lt;/strong&gt; (&lt;code&gt;web-ifc&lt;/code&gt;), &lt;strong&gt;STEP/STP &amp;amp; IGES/IGS&lt;/strong&gt; (&lt;code&gt;occt-import-js&lt;/code&gt;), &lt;strong&gt;GLB/GLTF, FBX, OBJ, STL, PLY, 3DS, DAE&lt;/strong&gt;, and &lt;strong&gt;NBIM v11&lt;/strong&gt; (&lt;code&gt;.nbim&lt;/code&gt;).&lt;/li&gt;
&lt;li&gt;Includes distance/angle/point measurement, real-time sectioning planes, hierarchical scene tree search, and marquee box selection.&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  Current Limitations
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Multi-GB models need to be converted to the NBIM v11 format first; loading raw multi-GB IFC or STEP files directly in-browser is still bound by client-side WASM memory.&lt;/li&gt;
&lt;li&gt;Licensed under &lt;strong&gt;GPL-3.0&lt;/strong&gt;.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;If you are working on WebGL CAD/BIM viewers or Three.js &lt;code&gt;BatchedMesh&lt;/code&gt; pipelines, I'd love your feedback on the repo!&lt;/p&gt;

</description>
      <category>threejs</category>
      <category>webgl</category>
      <category>opensource</category>
      <category>typescript</category>
    </item>
  </channel>
</rss>
