CombinedMaterial.cs 1.1 KB

123456789101112131415161718192021222324252627282930
  1. using UnityEngine;
  2. using System.Collections;
  3. using System.Collections.Generic;
  4. namespace LunarCatsStudio.SuperCombiner
  5. {
  6. /// <summary>
  7. /// Stores information about a combined _material
  8. /// </summary>
  9. [System.Serializable]
  10. public class CombinedMaterial
  11. {
  12. // The combined _material
  13. public Material material;
  14. // The list of uvs
  15. public Rect[] uvs;
  16. public Rect[] uvs2;
  17. public List<float> scaleFactors = new List<float>();
  18. // List of meshes UV bound
  19. public List<Rect> meshUVBounds = new List<Rect>();
  20. // This will be true if there is only one _material to combine, is this case we simply reuse the existing _material
  21. public bool isOriginalMaterial = false;
  22. // The _index at which this combined _material will be displayed in the inspector. Usefull in multimaterial when some combined _material are null
  23. public int displayedIndex;
  24. // Editor display parameter
  25. public bool showCombinedMaterial;
  26. public bool showUVs;
  27. public bool showMeshUVBounds;
  28. }
  29. }