<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>脚本绑定 on PlumePHP</title><link>https://plumephp.com/tags/%E8%84%9A%E6%9C%AC%E7%BB%91%E5%AE%9A/</link><description>Recent content in 脚本绑定 on PlumePHP</description><generator>Hugo</generator><language>zh-CN</language><lastBuildDate>Sun, 27 Sep 2026 14:00:00 +0800</lastBuildDate><atom:link href="https://plumephp.com/tags/%E8%84%9A%E6%9C%AC%E7%BB%91%E5%AE%9A/index.xml" rel="self" type="application/rss+xml"/><item><title>C++ 嵌入式与游戏引擎集成：宿主嵌入、绑定生成与性能内存约束</title><link>https://plumephp.com/cpp-embedded-game-engine-integration/</link><pubDate>Sun, 27 Sep 2026 14:00:00 +0800</pubDate><guid>https://plumephp.com/cpp-embedded-game-engine-integration/</guid><description>&lt;h2 id="一为什么需要嵌入与绑定"&gt;一、为什么需要嵌入与绑定&lt;/h2&gt;
&lt;h3 id="1-两种嵌入视角"&gt;1. 两种嵌入视角&lt;/h3&gt;
&lt;p&gt;C++ 在系统生态中的独特地位，使它经常扮演&lt;strong&gt;被嵌入的引擎&lt;/strong&gt;，也被迫处理&lt;strong&gt;嵌入其他语言&lt;/strong&gt;的双向需求：&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;作为被嵌入方&lt;/strong&gt;：游戏引擎暴露接口给 Lua/Python/JavaScript 脚本；桌面软件（如 Qt、OBS）嵌入 Python 做自动化；AI 框架（TensorRT/ONNX Runtime）暴露 C API 给上层语言；&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;作为嵌入方&lt;/strong&gt;：C++ 程序内嵌 Lua 做配置与逻辑热更新，内嵌 WASM 运行策略，或通过 RPC 与脚本进程协作。&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;无论哪个方向，核心问题都是同一个：&lt;strong&gt;如何在保持 C++ 性能的同时，安全地跨越语言边界传递控制权与数据&lt;/strong&gt;。&lt;/p&gt;</description></item></channel></rss>