Unity CanvasRenderer期望使用16位索引的网格来绘制图形图表[已解决]

问题描述 投票:0回答:1

IndexFormat.UInt32应用于UI网格

mesh.indexFormat = IndexFormat.UInt32;

Unity抱怨CanvasRenderer期望具有16位索引的网格,但我还没有找到如何将其更改为32位索引的方法。

是否可以将IndexFormat.UInt32应用于CanvasRenderer?

[编辑1]

我正在使用Unity 2019.3.0f3,此软件包附带此问题:assetstore.unity.com/packages/tools/gui/graph-and-chart

有时一个图形图表可以包含5000多个项目。

unity3d
1个回答
0
投票

作为修复,我已经使用Douglas-Peucker线近似算法过滤了数据,其中包括压缩数据曲线。

实现的源代码可以在这里找到:A C# Implementation of Douglas-Peucker Line Approximation Algorithm

© www.soinside.com 2019 - 2024. All rights reserved.