# ArgumentException: CommandBuffer: 无效的 ComputeBuffer 名称（空或 null）

- **ID:** `unity/rendering-command-buffer-invalid`
- **领域:** unity
- **类别:** runtime_error
- **验证级别:** ai_generated
- **修复率:** 96%

## 根因

CommandBuffer.SetComputeBufferParam 调用使用了空或 null 字符串作为着色器属性名称。

## 版本兼容性

| 版本 | 状态 | 引入 | 弃用 |
|------|------|------|------|
| Unity 2022.3 | active | — | — |
| Unity 2023.2 | active | — | — |
| Unity 6000.0 | active | — | — |

## 解决方案

1. ```
   Ensure the property name passed to SetComputeBufferParam matches the name in the compute shader's [numthreads] or buffer declaration.
   ```
2. ```
   Add a null check before calling SetComputeBufferParam to avoid passing empty strings.
   ```

## 无效尝试

- **** — The shader property name must be consistent between C# and the shader code; arbitrary names cause shader binding failures. (95% 失败率)
- **** — This workaround removes the functionality instead of fixing the root cause. (60% 失败率)
