public static AnimationInfo CreateAnimationInfo(string assetPath) { AnimationInfo mInfo = null; if (!m_dictMatInfo.TryGetValue(assetPath, out mInfo)) { mInfo = new AnimationInfo(); m_dictMatInfo.Add(assetPath, mInfo); } ModelImporter tImporter = AssetImporter.GetAtPath(assetPath) as ModelImporter; if (tImporter == null || tImporter.clipAnimations == null) { return(null); } mInfo.Path = assetPath; mInfo.AnimationType = tImporter.animationType; mInfo.AnimationCompression = tImporter.animationCompression; mInfo.MemSize = EditorCommon.CalculateAnimationSizeBytes(assetPath); if (++m_loadCount % 256 == 0) { Resources.UnloadUnusedAssets(); } return(mInfo); }