优化性能,降低GC

This commit is contained in:
monitor1394
2019-07-23 21:43:01 +08:00
parent d0b51d9297
commit cb6d0765ca
12 changed files with 276 additions and 161 deletions

View File

@@ -160,6 +160,7 @@ namespace XCharts
InitIndicator();
}
HashSet<string> serieNameSet = new HashSet<string>();
private void DrawData(VertexHelper vh)
{
int indicatorNum = m_Radar.indicatorList.Count;
@@ -170,7 +171,7 @@ namespace XCharts
Vector3 firstPoint = Vector3.zero;
dataPosList.Clear();
dataPosList.Capacity = m_Series.Count;
HashSet<string> serieNameSet = new HashSet<string>();
serieNameSet.Clear();
int serieNameCount = -1;
for (int i = 0; i < m_Series.Count; i++)
{