> For the complete documentation index, see [llms.txt](https://docs.convai.com/api-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.convai.com/api-docs/zh/cha-jian-yu-ji-cheng/convai-unity-sdk/compatibility-and-requirements/unity-versions-and-render-pipelines.md).

# Unity 版本和渲染管线

Convai Unity SDK 环境要求参考，包括最低 Unity 版本、所需包依赖项和渲染管线支持。

Convai Unity SDK 需要 Unity <code class="expression">space.vars.unity\_min\_version</code>。在更早的 Unity 版本上没有受支持的配置，而 SDK 可在 Unity 上编译 `6000.5` 现在 Unity 已将场景标识移至 64 位。Unity 的三种渲染管线均受支持，无需额外配置，而且两种安装方式——Package Manager 和 Asset Store——都会自动解析所需的软件包依赖。

### Unity 版本要求

| 要求      | 版本                                                                     |
| ------- | ---------------------------------------------------------------------- |
| 最低要求    | <code class="expression">space.vars.unity\_min\_version</code>         |
| 推荐用于新项目 | <code class="expression">space.vars.unity\_recommended\_version</code> |

{% hint style="warning" %}
最低版本是硬性下限。Convai 不支持低于 Unity 的任何配置 <code class="expression">space.vars.unity\_min\_version</code>，包括更早的 LTS 版本。请在安装 SDK 之前升级项目。
{% endhint %}

### 所需软件包依赖

该 SDK 依赖四个 Unity 软件包。两种安装方式都会自动安装这些包——除非你遇到版本冲突，否则无需手动添加。

| 包                                 | 版本                                                                        |
| --------------------------------- | ------------------------------------------------------------------------- |
| `com.unity.ai.inference`          | <code class="expression">space.vars.dep\_ai\_inference\_version</code>    |
| `com.unity.nuget.newtonsoft-json` | <code class="expression">space.vars.dep\_newtonsoft\_json\_version</code> |
| `com.unity.ugui`                  | <code class="expression">space.vars.dep\_ugui\_version</code>             |
| `com.unity.inputsystem`           | <code class="expression">space.vars.dep\_inputsystem\_version</code>      |

{% hint style="warning" %}
安装后不要降级这些软件包。SDK 目标版本为上面列出的版本，在更低版本上的行为未定义。如果你的项目已在 `Packages/manifest.json`中锁定了其中任何一个的旧版本，请在安装前移除或更新该锁定。
{% endhint %}

由 NavMesh 驱动的移动还需要一个 SDK 不会安装的额外软件包。 `ConvaiNavMeshLocomotion` 会驱动 Unity 内置的 `NavMeshAgent`，但 NavMesh 的制作—— `窗口 > AI > Navigation` 以及 `NavMeshSurface` 组件——来自 `com.unity.ai.navigation`。如果你的项目为角色移动烘焙了 NavMesh，请安装 `com.unity.ai.navigation` 。

### 渲染管线支持

该 SDK 会在运行时检测当前激活的渲染管线并自动适配。例如，Vision 模块的相机捕获路径在未分配渲染管线资源时使用内置渲染钩子，而在 URP 和 HDRP 上使用显式渲染路径。Unity 的三种渲染管线均完全受支持，无需手动配置。

| 渲染管线         | 受支持  |
| ------------ | ---- |
| 内置渲染管线       | ✅ 完整 |
| 通用渲染管线（URP）  | ✅ 完整 |
| 高清渲染管线（HDRP） | ✅ 完整 |

在任何管线中支持都无需手动配置，但 Vision 模块的 `CameraVisionFrameSource` 捕获方式会因管线而异。在 Built-in 管线上，它使用命令缓冲区渲染钩子，不需要额外的渲染通道。在 URP 和 HDRP 上，它会回退到显式的渲染兼容路径，并额外发出一次 `Camera.Render()` 调用，每捕获一帧一次。

随附的示例场景使用 URP 材质。如果你的项目使用 Built-in 或 HDRP 管线，则需要重新分配示例场景材质。位于 `SamplesShared/Camera/` 中的可选景深相机脚本支持 URP 和 HDRP；在 Built-in 管线上，它们会跳过景深并改为记录警告。这些脚本都不是 SDK 功能所必需的。

### 下一步

确认 Unity 版本和软件包后，请检查你的目标平台。

{% content-ref url="/pages/d9f64c1a3c295b98fd7638d4cc75e01943fa23bc" %}
[平台支持矩阵](/api-docs/zh/cha-jian-yu-ji-cheng/convai-unity-sdk/compatibility-and-requirements/platform-support-matrix.md)
{% endcontent-ref %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.convai.com/api-docs/zh/cha-jian-yu-ji-cheng/convai-unity-sdk/compatibility-and-requirements/unity-versions-and-render-pipelines.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
