31 lines
835 B
C#
31 lines
835 B
C#
|
using System.Collections.Generic;
|
|||
|
using System.Linq;
|
|||
|
using UnityEngine;
|
|||
|
|
|||
|
namespace PhxhSDK.Phxh.Others
|
|||
|
{
|
|||
|
public class CmpSkinCombine : MonoBehaviour
|
|||
|
{
|
|||
|
|
|||
|
[ContextMenu("强制合并")]
|
|||
|
public void ForceCombine()
|
|||
|
{
|
|||
|
AutoCombineMesh(gameObject, new string[] { "_MainTex", "_MaskTex" });
|
|||
|
}
|
|||
|
|
|||
|
/// <summary>
|
|||
|
/// 自动合并网格,贴图及骨骼
|
|||
|
/// </summary>
|
|||
|
/// <param name="obj"></param>
|
|||
|
/// <param name="textureNames"></param>
|
|||
|
/// <param name="combineTexSize"></param>
|
|||
|
public static void AutoCombineMesh(GameObject obj,
|
|||
|
string[] textureNames,
|
|||
|
int combineTexSize = 2048)
|
|||
|
{
|
|||
|
// AutoCombine.CombineSkinMesh(obj, textureNames, combineTexSize);
|
|||
|
}
|
|||
|
|
|||
|
}
|
|||
|
}
|