using System; using System.Collections.Generic; using System.ComponentModel; using System.Runtime.CompilerServices; using UnityEngine.Internal; using UnityEngine.Scripting; namespace UnityEngine { // Token: 0x0200008D RID: 141 public sealed class Mesh : Object { // Token: 0x06000A55 RID: 2645 RVA: 0x0000F97C File Offset: 0x0000DB7C public Mesh() { Mesh.Internal_Create(this); } // Token: 0x06000A56 RID: 2646 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private static extern void Internal_Create([Writable] Mesh mono); // Token: 0x06000A57 RID: 2647 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern void Clear([UnityEngine.Internal.DefaultValue("true")] bool keepVertexLayout); // Token: 0x06000A58 RID: 2648 RVA: 0x0000F98C File Offset: 0x0000DB8C [ExcludeFromDocs] public void Clear() { bool flag = true; this.Clear(flag); } // Token: 0x1700025B RID: 603 // (get) Token: 0x06000A59 RID: 2649 public extern bool isReadable { [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] get; } // Token: 0x1700025C RID: 604 // (get) Token: 0x06000A5A RID: 2650 internal extern bool canAccess { [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] get; } // Token: 0x06000A5B RID: 2651 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] internal extern void PrintErrorCantAccessMesh(Mesh.InternalShaderChannel channel); // Token: 0x06000A5C RID: 2652 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] internal extern void PrintErrorCantAccessMeshForIndices(); // Token: 0x06000A5D RID: 2653 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] internal extern void PrintErrorBadSubmeshIndexTriangles(); // Token: 0x06000A5E RID: 2654 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] internal extern void PrintErrorBadSubmeshIndexIndices(); // Token: 0x06000A5F RID: 2655 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern void SetArrayForChannelImpl(Mesh.InternalShaderChannel channel, Mesh.InternalVertexChannelType format, int dim, Array values, int arraySize); // Token: 0x06000A60 RID: 2656 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern Array GetAllocArrayFromChannelImpl(Mesh.InternalShaderChannel channel, Mesh.InternalVertexChannelType format, int dim); // Token: 0x06000A61 RID: 2657 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern void GetArrayFromChannelImpl(Mesh.InternalShaderChannel channel, Mesh.InternalVertexChannelType format, int dim, Array values); // Token: 0x06000A62 RID: 2658 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] internal extern bool HasChannel(Mesh.InternalShaderChannel channel); // Token: 0x06000A63 RID: 2659 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private static extern void ResizeList(object list, int size); // Token: 0x06000A64 RID: 2660 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private static extern Array ExtractArrayFromList(object list); // Token: 0x06000A65 RID: 2661 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern int[] GetTrianglesImpl(int submesh); // Token: 0x06000A66 RID: 2662 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern void GetTrianglesNonAllocImpl(object values, int submesh); // Token: 0x06000A67 RID: 2663 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern int[] GetIndicesImpl(int submesh); // Token: 0x06000A68 RID: 2664 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern void GetIndicesNonAllocImpl(object values, int submesh); // Token: 0x06000A69 RID: 2665 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern void SetTrianglesImpl(int submesh, Array triangles, int arraySize, [UnityEngine.Internal.DefaultValue("true")] bool calculateBounds); // Token: 0x06000A6A RID: 2666 RVA: 0x0000F9A4 File Offset: 0x0000DBA4 [ExcludeFromDocs] private void SetTrianglesImpl(int submesh, Array triangles, int arraySize) { bool flag = true; this.SetTrianglesImpl(submesh, triangles, arraySize, flag); } // Token: 0x06000A6B RID: 2667 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern void SetIndicesImpl(int submesh, MeshTopology topology, Array indices, int arraySize, [UnityEngine.Internal.DefaultValue("true")] bool calculateBounds); // Token: 0x06000A6C RID: 2668 RVA: 0x0000F9C0 File Offset: 0x0000DBC0 [ExcludeFromDocs] private void SetIndicesImpl(int submesh, MeshTopology topology, Array indices, int arraySize) { bool flag = true; this.SetIndicesImpl(submesh, topology, indices, arraySize, flag); } // Token: 0x06000A6D RID: 2669 RVA: 0x0000F9DC File Offset: 0x0000DBDC [ExcludeFromDocs] public void SetTriangles(int[] triangles, int submesh) { bool flag = true; this.SetTriangles(triangles, submesh, flag); } // Token: 0x06000A6E RID: 2670 RVA: 0x0000F9F8 File Offset: 0x0000DBF8 public void SetTriangles(int[] triangles, int submesh, [UnityEngine.Internal.DefaultValue("true")] bool calculateBounds) { if (this.CheckCanAccessSubmeshTriangles(submesh)) { this.SetTrianglesImpl(submesh, triangles, this.SafeLength(triangles), calculateBounds); } } // Token: 0x06000A6F RID: 2671 RVA: 0x0000FA18 File Offset: 0x0000DC18 [ExcludeFromDocs] public void SetTriangles(List triangles, int submesh) { bool flag = true; this.SetTriangles(triangles, submesh, flag); } // Token: 0x06000A70 RID: 2672 RVA: 0x0000FA34 File Offset: 0x0000DC34 public void SetTriangles(List triangles, int submesh, [UnityEngine.Internal.DefaultValue("true")] bool calculateBounds) { if (this.CheckCanAccessSubmeshTriangles(submesh)) { this.SetTrianglesImpl(submesh, Mesh.ExtractArrayFromList(triangles), this.SafeLength(triangles), calculateBounds); } } // Token: 0x06000A71 RID: 2673 RVA: 0x0000FA58 File Offset: 0x0000DC58 [ExcludeFromDocs] public void SetIndices(int[] indices, MeshTopology topology, int submesh) { bool flag = true; this.SetIndices(indices, topology, submesh, flag); } // Token: 0x06000A72 RID: 2674 RVA: 0x0000FA74 File Offset: 0x0000DC74 public void SetIndices(int[] indices, MeshTopology topology, int submesh, [UnityEngine.Internal.DefaultValue("true")] bool calculateBounds) { if (this.CheckCanAccessSubmeshIndices(submesh)) { this.SetIndicesImpl(submesh, topology, indices, this.SafeLength(indices), calculateBounds); } } // Token: 0x1700025D RID: 605 // (get) Token: 0x06000A73 RID: 2675 public extern int blendShapeCount { [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] get; } // Token: 0x06000A74 RID: 2676 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern void ClearBlendShapes(); // Token: 0x06000A75 RID: 2677 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern string GetBlendShapeName(int shapeIndex); // Token: 0x06000A76 RID: 2678 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern int GetBlendShapeFrameCount(int shapeIndex); // Token: 0x06000A77 RID: 2679 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern float GetBlendShapeFrameWeight(int shapeIndex, int frameIndex); // Token: 0x06000A78 RID: 2680 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern void GetBlendShapeFrameVertices(int shapeIndex, int frameIndex, Vector3[] deltaVertices, Vector3[] deltaNormals, Vector3[] deltaTangents); // Token: 0x06000A79 RID: 2681 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern void AddBlendShapeFrame(string shapeName, float frameWeight, Vector3[] deltaVertices, Vector3[] deltaNormals, Vector3[] deltaTangents); // Token: 0x1700025E RID: 606 // (get) Token: 0x06000A7A RID: 2682 public extern int vertexBufferCount { [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] get; } // Token: 0x06000A7B RID: 2683 RVA: 0x0000FA98 File Offset: 0x0000DC98 public IntPtr GetNativeVertexBufferPtr(int bufferIndex) { IntPtr intPtr; Mesh.INTERNAL_CALL_GetNativeVertexBufferPtr(this, bufferIndex, out intPtr); return intPtr; } // Token: 0x06000A7C RID: 2684 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private static extern void INTERNAL_CALL_GetNativeVertexBufferPtr(Mesh self, int bufferIndex, out IntPtr value); // Token: 0x06000A7D RID: 2685 RVA: 0x0000FAB8 File Offset: 0x0000DCB8 public IntPtr GetNativeIndexBufferPtr() { IntPtr intPtr; Mesh.INTERNAL_CALL_GetNativeIndexBufferPtr(this, out intPtr); return intPtr; } // Token: 0x06000A7E RID: 2686 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private static extern void INTERNAL_CALL_GetNativeIndexBufferPtr(Mesh self, out IntPtr value); // Token: 0x1700025F RID: 607 // (get) Token: 0x06000A7F RID: 2687 RVA: 0x0000FAD8 File Offset: 0x0000DCD8 // (set) Token: 0x06000A80 RID: 2688 RVA: 0x0000FAF8 File Offset: 0x0000DCF8 public Bounds bounds { get { Bounds bounds; this.INTERNAL_get_bounds(out bounds); return bounds; } set { this.INTERNAL_set_bounds(ref value); } } // Token: 0x06000A81 RID: 2689 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern void INTERNAL_get_bounds(out Bounds value); // Token: 0x06000A82 RID: 2690 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern void INTERNAL_set_bounds(ref Bounds value); // Token: 0x06000A83 RID: 2691 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern void RecalculateBounds(); // Token: 0x06000A84 RID: 2692 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern void RecalculateNormals(); // Token: 0x06000A85 RID: 2693 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern void RecalculateTangents(); // Token: 0x06000A86 RID: 2694 [EditorBrowsable(EditorBrowsableState.Never)] [Obsolete("This method is no longer supported (UnityUpgradable)", true)] [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern void Optimize(); // Token: 0x06000A87 RID: 2695 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern MeshTopology GetTopology(int submesh); // Token: 0x17000260 RID: 608 // (get) Token: 0x06000A88 RID: 2696 public extern int vertexCount { [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] get; } // Token: 0x17000261 RID: 609 // (get) Token: 0x06000A89 RID: 2697 // (set) Token: 0x06000A8A RID: 2698 public extern int subMeshCount { [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] get; [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] set; } // Token: 0x06000A8B RID: 2699 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern uint GetIndexStart(int submesh); // Token: 0x06000A8C RID: 2700 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern uint GetIndexCount(int submesh); // Token: 0x06000A8D RID: 2701 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern void CombineMeshes(CombineInstance[] combine, [UnityEngine.Internal.DefaultValue("true")] bool mergeSubMeshes, [UnityEngine.Internal.DefaultValue("true")] bool useMatrices, [UnityEngine.Internal.DefaultValue("false")] bool hasLightmapData); // Token: 0x06000A8E RID: 2702 RVA: 0x0000FB04 File Offset: 0x0000DD04 [ExcludeFromDocs] public void CombineMeshes(CombineInstance[] combine, bool mergeSubMeshes, bool useMatrices) { bool flag = false; this.CombineMeshes(combine, mergeSubMeshes, useMatrices, flag); } // Token: 0x06000A8F RID: 2703 RVA: 0x0000FB20 File Offset: 0x0000DD20 [ExcludeFromDocs] public void CombineMeshes(CombineInstance[] combine, bool mergeSubMeshes) { bool flag = false; bool flag2 = true; this.CombineMeshes(combine, mergeSubMeshes, flag2, flag); } // Token: 0x06000A90 RID: 2704 RVA: 0x0000FB3C File Offset: 0x0000DD3C [ExcludeFromDocs] public void CombineMeshes(CombineInstance[] combine) { bool flag = false; bool flag2 = true; bool flag3 = true; this.CombineMeshes(combine, flag3, flag2, flag); } // Token: 0x17000262 RID: 610 // (get) Token: 0x06000A91 RID: 2705 // (set) Token: 0x06000A92 RID: 2706 public extern BoneWeight[] boneWeights { [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] get; [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] set; } // Token: 0x06000A93 RID: 2707 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern void GetBoneWeightsNonAllocImpl(object values); // Token: 0x17000263 RID: 611 // (get) Token: 0x06000A94 RID: 2708 // (set) Token: 0x06000A95 RID: 2709 public extern Matrix4x4[] bindposes { [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] get; [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] set; } // Token: 0x06000A96 RID: 2710 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern int GetBindposeCount(); // Token: 0x06000A97 RID: 2711 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] private extern void GetBindposesNonAllocImpl(object values); // Token: 0x06000A98 RID: 2712 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern void MarkDynamic(); // Token: 0x06000A99 RID: 2713 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern void UploadMeshData(bool markNoLogerReadable); // Token: 0x06000A9A RID: 2714 [GeneratedByOldBindingsGenerator] [MethodImpl(MethodImplOptions.InternalCall)] public extern int GetBlendShapeIndex(string blendShapeName); // Token: 0x06000A9B RID: 2715 RVA: 0x0000FB5C File Offset: 0x0000DD5C internal Mesh.InternalShaderChannel GetUVChannel(int uvIndex) { if (uvIndex < 0 || uvIndex > 3) { throw new ArgumentException("GetUVChannel called for bad uvIndex", "uvIndex"); } return Mesh.InternalShaderChannel.TexCoord0 + uvIndex; } // Token: 0x06000A9C RID: 2716 RVA: 0x0000FB94 File Offset: 0x0000DD94 internal static int DefaultDimensionForChannel(Mesh.InternalShaderChannel channel) { int num; if (channel == Mesh.InternalShaderChannel.Vertex || channel == Mesh.InternalShaderChannel.Normal) { num = 3; } else if (channel >= Mesh.InternalShaderChannel.TexCoord0 && channel <= Mesh.InternalShaderChannel.TexCoord3) { num = 2; } else { if (channel != Mesh.InternalShaderChannel.Tangent && channel != Mesh.InternalShaderChannel.Color) { throw new ArgumentException("DefaultDimensionForChannel called for bad channel", "channel"); } num = 4; } return num; } // Token: 0x06000A9D RID: 2717 RVA: 0x0000FBF4 File Offset: 0x0000DDF4 private T[] GetAllocArrayFromChannel(Mesh.InternalShaderChannel channel, Mesh.InternalVertexChannelType format, int dim) { if (this.canAccess) { if (this.HasChannel(channel)) { return (T[])this.GetAllocArrayFromChannelImpl(channel, format, dim); } } else { this.PrintErrorCantAccessMesh(channel); } return new T[0]; } // Token: 0x06000A9E RID: 2718 RVA: 0x0000FC4C File Offset: 0x0000DE4C private T[] GetAllocArrayFromChannel(Mesh.InternalShaderChannel channel) { return this.GetAllocArrayFromChannel(channel, Mesh.InternalVertexChannelType.Float, Mesh.DefaultDimensionForChannel(channel)); } // Token: 0x06000A9F RID: 2719 RVA: 0x0000FC70 File Offset: 0x0000DE70 private int SafeLength(Array values) { return (values == null) ? 0 : values.Length; } // Token: 0x06000AA0 RID: 2720 RVA: 0x0000FC98 File Offset: 0x0000DE98 private int SafeLength(List values) { return (values == null) ? 0 : values.Count; } // Token: 0x06000AA1 RID: 2721 RVA: 0x0000FCC0 File Offset: 0x0000DEC0 private void SetSizedArrayForChannel(Mesh.InternalShaderChannel channel, Mesh.InternalVertexChannelType format, int dim, Array values, int valuesCount) { if (this.canAccess) { this.SetArrayForChannelImpl(channel, format, dim, values, valuesCount); } else { this.PrintErrorCantAccessMesh(channel); } } // Token: 0x06000AA2 RID: 2722 RVA: 0x0000FCE8 File Offset: 0x0000DEE8 private void SetArrayForChannel(Mesh.InternalShaderChannel channel, Mesh.InternalVertexChannelType format, int dim, T[] values) { this.SetSizedArrayForChannel(channel, format, dim, values, this.SafeLength(values)); } // Token: 0x06000AA3 RID: 2723 RVA: 0x0000FD00 File Offset: 0x0000DF00 private void SetArrayForChannel(Mesh.InternalShaderChannel channel, T[] values) { this.SetSizedArrayForChannel(channel, Mesh.InternalVertexChannelType.Float, Mesh.DefaultDimensionForChannel(channel), values, this.SafeLength(values)); } // Token: 0x06000AA4 RID: 2724 RVA: 0x0000FD1C File Offset: 0x0000DF1C private void SetListForChannel(Mesh.InternalShaderChannel channel, Mesh.InternalVertexChannelType format, int dim, List values) { this.SetSizedArrayForChannel(channel, format, dim, Mesh.ExtractArrayFromList(values), this.SafeLength(values)); } // Token: 0x06000AA5 RID: 2725 RVA: 0x0000FD38 File Offset: 0x0000DF38 private void SetListForChannel(Mesh.InternalShaderChannel channel, List values) { this.SetSizedArrayForChannel(channel, Mesh.InternalVertexChannelType.Float, Mesh.DefaultDimensionForChannel(channel), Mesh.ExtractArrayFromList(values), this.SafeLength(values)); } // Token: 0x06000AA6 RID: 2726 RVA: 0x0000FD58 File Offset: 0x0000DF58 private void GetListForChannel(List buffer, int capacity, Mesh.InternalShaderChannel channel, int dim) { this.GetListForChannel(buffer, capacity, channel, dim, Mesh.InternalVertexChannelType.Float); } // Token: 0x06000AA7 RID: 2727 RVA: 0x0000FD68 File Offset: 0x0000DF68 private void GetListForChannel(List buffer, int capacity, Mesh.InternalShaderChannel channel, int dim, Mesh.InternalVertexChannelType channelType) { buffer.Clear(); if (!this.canAccess) { this.PrintErrorCantAccessMesh(channel); } else if (this.HasChannel(channel)) { this.PrepareUserBuffer(buffer, capacity); this.GetArrayFromChannelImpl(channel, channelType, dim, Mesh.ExtractArrayFromList(buffer)); } } // Token: 0x06000AA8 RID: 2728 RVA: 0x0000FDC0 File Offset: 0x0000DFC0 private void PrepareUserBuffer(List buffer, int capacity) { buffer.Clear(); if (buffer.Capacity < capacity) { buffer.Capacity = capacity; } Mesh.ResizeList(buffer, capacity); } // Token: 0x17000264 RID: 612 // (get) Token: 0x06000AA9 RID: 2729 RVA: 0x0000FDE4 File Offset: 0x0000DFE4 // (set) Token: 0x06000AAA RID: 2730 RVA: 0x0000FE00 File Offset: 0x0000E000 public Vector3[] vertices { get { return this.GetAllocArrayFromChannel(Mesh.InternalShaderChannel.Vertex); } set { this.SetArrayForChannel(Mesh.InternalShaderChannel.Vertex, value); } } // Token: 0x17000265 RID: 613 // (get) Token: 0x06000AAB RID: 2731 RVA: 0x0000FE0C File Offset: 0x0000E00C // (set) Token: 0x06000AAC RID: 2732 RVA: 0x0000FE28 File Offset: 0x0000E028 public Vector3[] normals { get { return this.GetAllocArrayFromChannel(Mesh.InternalShaderChannel.Normal); } set { this.SetArrayForChannel(Mesh.InternalShaderChannel.Normal, value); } } // Token: 0x17000266 RID: 614 // (get) Token: 0x06000AAD RID: 2733 RVA: 0x0000FE34 File Offset: 0x0000E034 // (set) Token: 0x06000AAE RID: 2734 RVA: 0x0000FE50 File Offset: 0x0000E050 public Vector4[] tangents { get { return this.GetAllocArrayFromChannel(Mesh.InternalShaderChannel.Tangent); } set { this.SetArrayForChannel(Mesh.InternalShaderChannel.Tangent, value); } } // Token: 0x17000267 RID: 615 // (get) Token: 0x06000AAF RID: 2735 RVA: 0x0000FE5C File Offset: 0x0000E05C // (set) Token: 0x06000AB0 RID: 2736 RVA: 0x0000FE78 File Offset: 0x0000E078 public Vector2[] uv { get { return this.GetAllocArrayFromChannel(Mesh.InternalShaderChannel.TexCoord0); } set { this.SetArrayForChannel(Mesh.InternalShaderChannel.TexCoord0, value); } } // Token: 0x17000268 RID: 616 // (get) Token: 0x06000AB1 RID: 2737 RVA: 0x0000FE84 File Offset: 0x0000E084 // (set) Token: 0x06000AB2 RID: 2738 RVA: 0x0000FEA0 File Offset: 0x0000E0A0 public Vector2[] uv2 { get { return this.GetAllocArrayFromChannel(Mesh.InternalShaderChannel.TexCoord1); } set { this.SetArrayForChannel(Mesh.InternalShaderChannel.TexCoord1, value); } } // Token: 0x17000269 RID: 617 // (get) Token: 0x06000AB3 RID: 2739 RVA: 0x0000FEAC File Offset: 0x0000E0AC // (set) Token: 0x06000AB4 RID: 2740 RVA: 0x0000FEC8 File Offset: 0x0000E0C8 public Vector2[] uv3 { get { return this.GetAllocArrayFromChannel(Mesh.InternalShaderChannel.TexCoord2); } set { this.SetArrayForChannel(Mesh.InternalShaderChannel.TexCoord2, value); } } // Token: 0x1700026A RID: 618 // (get) Token: 0x06000AB5 RID: 2741 RVA: 0x0000FED4 File Offset: 0x0000E0D4 // (set) Token: 0x06000AB6 RID: 2742 RVA: 0x0000FEF0 File Offset: 0x0000E0F0 public Vector2[] uv4 { get { return this.GetAllocArrayFromChannel(Mesh.InternalShaderChannel.TexCoord3); } set { this.SetArrayForChannel(Mesh.InternalShaderChannel.TexCoord3, value); } } // Token: 0x1700026B RID: 619 // (get) Token: 0x06000AB7 RID: 2743 RVA: 0x0000FEFC File Offset: 0x0000E0FC // (set) Token: 0x06000AB8 RID: 2744 RVA: 0x0000FF18 File Offset: 0x0000E118 public Color[] colors { get { return this.GetAllocArrayFromChannel(Mesh.InternalShaderChannel.Color); } set { this.SetArrayForChannel(Mesh.InternalShaderChannel.Color, value); } } // Token: 0x1700026C RID: 620 // (get) Token: 0x06000AB9 RID: 2745 RVA: 0x0000FF24 File Offset: 0x0000E124 // (set) Token: 0x06000ABA RID: 2746 RVA: 0x0000FF44 File Offset: 0x0000E144 public Color32[] colors32 { get { return this.GetAllocArrayFromChannel(Mesh.InternalShaderChannel.Color, Mesh.InternalVertexChannelType.Color, 1); } set { this.SetArrayForChannel(Mesh.InternalShaderChannel.Color, Mesh.InternalVertexChannelType.Color, 1, value); } } // Token: 0x06000ABB RID: 2747 RVA: 0x0000FF54 File Offset: 0x0000E154 public void GetVertices(List vertices) { if (vertices == null) { throw new ArgumentNullException("The result vertices list cannot be null.", "vertices"); } this.GetListForChannel(vertices, this.vertexCount, Mesh.InternalShaderChannel.Vertex, Mesh.DefaultDimensionForChannel(Mesh.InternalShaderChannel.Vertex)); } // Token: 0x06000ABC RID: 2748 RVA: 0x0000FF84 File Offset: 0x0000E184 public void SetVertices(List inVertices) { this.SetListForChannel(Mesh.InternalShaderChannel.Vertex, inVertices); } // Token: 0x06000ABD RID: 2749 RVA: 0x0000FF90 File Offset: 0x0000E190 public void GetNormals(List normals) { if (normals == null) { throw new ArgumentNullException("The result normals list cannot be null.", "normals"); } this.GetListForChannel(normals, this.vertexCount, Mesh.InternalShaderChannel.Normal, Mesh.DefaultDimensionForChannel(Mesh.InternalShaderChannel.Normal)); } // Token: 0x06000ABE RID: 2750 RVA: 0x0000FFC0 File Offset: 0x0000E1C0 public void SetNormals(List inNormals) { this.SetListForChannel(Mesh.InternalShaderChannel.Normal, inNormals); } // Token: 0x06000ABF RID: 2751 RVA: 0x0000FFCC File Offset: 0x0000E1CC public void GetTangents(List tangents) { if (tangents == null) { throw new ArgumentNullException("The result tangents list cannot be null.", "tangents"); } this.GetListForChannel(tangents, this.vertexCount, Mesh.InternalShaderChannel.Tangent, Mesh.DefaultDimensionForChannel(Mesh.InternalShaderChannel.Tangent)); } // Token: 0x06000AC0 RID: 2752 RVA: 0x0000FFFC File Offset: 0x0000E1FC public void SetTangents(List inTangents) { this.SetListForChannel(Mesh.InternalShaderChannel.Tangent, inTangents); } // Token: 0x06000AC1 RID: 2753 RVA: 0x00010008 File Offset: 0x0000E208 public void GetColors(List colors) { if (colors == null) { throw new ArgumentNullException("The result colors list cannot be null.", "colors"); } this.GetListForChannel(colors, this.vertexCount, Mesh.InternalShaderChannel.Color, Mesh.DefaultDimensionForChannel(Mesh.InternalShaderChannel.Color)); } // Token: 0x06000AC2 RID: 2754 RVA: 0x00010038 File Offset: 0x0000E238 public void SetColors(List inColors) { this.SetListForChannel(Mesh.InternalShaderChannel.Color, inColors); } // Token: 0x06000AC3 RID: 2755 RVA: 0x00010044 File Offset: 0x0000E244 public void GetColors(List colors) { if (colors == null) { throw new ArgumentNullException("The result colors list cannot be null.", "colors"); } this.GetListForChannel(colors, this.vertexCount, Mesh.InternalShaderChannel.Color, 1, Mesh.InternalVertexChannelType.Color); } // Token: 0x06000AC4 RID: 2756 RVA: 0x00010070 File Offset: 0x0000E270 public void SetColors(List inColors) { this.SetListForChannel(Mesh.InternalShaderChannel.Color, Mesh.InternalVertexChannelType.Color, 1, inColors); } // Token: 0x06000AC5 RID: 2757 RVA: 0x00010080 File Offset: 0x0000E280 private void SetUvsImpl(int uvIndex, int dim, List uvs) { if (uvIndex < 0 || uvIndex > 3) { Debug.LogError("The uv index is invalid (must be in [0..3]"); } else { this.SetListForChannel(this.GetUVChannel(uvIndex), Mesh.InternalVertexChannelType.Float, dim, uvs); } } // Token: 0x06000AC6 RID: 2758 RVA: 0x000100B4 File Offset: 0x0000E2B4 public void SetUVs(int channel, List uvs) { this.SetUvsImpl(channel, 2, uvs); } // Token: 0x06000AC7 RID: 2759 RVA: 0x000100C0 File Offset: 0x0000E2C0 public void SetUVs(int channel, List uvs) { this.SetUvsImpl(channel, 3, uvs); } // Token: 0x06000AC8 RID: 2760 RVA: 0x000100CC File Offset: 0x0000E2CC public void SetUVs(int channel, List uvs) { this.SetUvsImpl(channel, 4, uvs); } // Token: 0x06000AC9 RID: 2761 RVA: 0x000100D8 File Offset: 0x0000E2D8 private void GetUVsImpl(int uvIndex, List uvs, int dim) { if (uvs == null) { throw new ArgumentNullException("The result uvs list cannot be null.", "uvs"); } if (uvIndex < 0 || uvIndex > 3) { throw new IndexOutOfRangeException("Specified uv index is out of range. Must be in the range [0, 3]."); } this.GetListForChannel(uvs, this.vertexCount, this.GetUVChannel(uvIndex), dim); } // Token: 0x06000ACA RID: 2762 RVA: 0x0001012C File Offset: 0x0000E32C public void GetUVs(int channel, List uvs) { this.GetUVsImpl(channel, uvs, 2); } // Token: 0x06000ACB RID: 2763 RVA: 0x00010138 File Offset: 0x0000E338 public void GetUVs(int channel, List uvs) { this.GetUVsImpl(channel, uvs, 3); } // Token: 0x06000ACC RID: 2764 RVA: 0x00010144 File Offset: 0x0000E344 public void GetUVs(int channel, List uvs) { this.GetUVsImpl(channel, uvs, 4); } // Token: 0x06000ACD RID: 2765 RVA: 0x00010150 File Offset: 0x0000E350 private bool CheckCanAccessSubmesh(int submesh, bool errorAboutTriangles) { bool flag; if (!this.canAccess) { this.PrintErrorCantAccessMeshForIndices(); flag = false; } else if (submesh < 0 || submesh >= this.subMeshCount) { if (errorAboutTriangles) { this.PrintErrorBadSubmeshIndexTriangles(); } else { this.PrintErrorBadSubmeshIndexIndices(); } flag = false; } else { flag = true; } return flag; } // Token: 0x06000ACE RID: 2766 RVA: 0x000101B4 File Offset: 0x0000E3B4 private bool CheckCanAccessSubmeshTriangles(int submesh) { return this.CheckCanAccessSubmesh(submesh, true); } // Token: 0x06000ACF RID: 2767 RVA: 0x000101D4 File Offset: 0x0000E3D4 private bool CheckCanAccessSubmeshIndices(int submesh) { return this.CheckCanAccessSubmesh(submesh, false); } // Token: 0x1700026D RID: 621 // (get) Token: 0x06000AD0 RID: 2768 RVA: 0x000101F4 File Offset: 0x0000E3F4 // (set) Token: 0x06000AD1 RID: 2769 RVA: 0x00010230 File Offset: 0x0000E430 public int[] triangles { get { int[] array; if (this.canAccess) { array = this.GetTrianglesImpl(-1); } else { this.PrintErrorCantAccessMeshForIndices(); array = new int[0]; } return array; } set { if (this.canAccess) { this.SetTrianglesImpl(-1, value, this.SafeLength(value)); } else { this.PrintErrorCantAccessMeshForIndices(); } } } // Token: 0x06000AD2 RID: 2770 RVA: 0x00010258 File Offset: 0x0000E458 public int[] GetTriangles(int submesh) { return (!this.CheckCanAccessSubmeshTriangles(submesh)) ? new int[0] : this.GetTrianglesImpl(submesh); } // Token: 0x06000AD3 RID: 2771 RVA: 0x0001028C File Offset: 0x0000E48C public void GetTriangles(List triangles, int submesh) { if (triangles == null) { throw new ArgumentNullException("The result triangles list cannot be null.", "triangles"); } if (submesh < 0 || submesh >= this.subMeshCount) { throw new IndexOutOfRangeException("Specified sub mesh is out of range. Must be greater or equal to 0 and less than subMeshCount."); } this.PrepareUserBuffer(triangles, (int)this.GetIndexCount(submesh)); this.GetTrianglesNonAllocImpl(triangles, submesh); } // Token: 0x06000AD4 RID: 2772 RVA: 0x000102E4 File Offset: 0x0000E4E4 public int[] GetIndices(int submesh) { return (!this.CheckCanAccessSubmeshIndices(submesh)) ? new int[0] : this.GetIndicesImpl(submesh); } // Token: 0x06000AD5 RID: 2773 RVA: 0x00010318 File Offset: 0x0000E518 public void GetIndices(List indices, int submesh) { if (indices == null) { throw new ArgumentNullException("The result indices list cannot be null.", "indices"); } if (submesh < 0 || submesh >= this.subMeshCount) { throw new IndexOutOfRangeException("Specified sub mesh is out of range. Must be greater or equal to 0 and less than subMeshCount."); } this.PrepareUserBuffer(indices, (int)this.GetIndexCount(submesh)); indices.Clear(); this.GetIndicesNonAllocImpl(indices, submesh); } // Token: 0x06000AD6 RID: 2774 RVA: 0x00010378 File Offset: 0x0000E578 public void GetBindposes(List bindposes) { if (bindposes == null) { throw new ArgumentNullException("The result bindposes list cannot be null.", "bindposes"); } this.PrepareUserBuffer(bindposes, this.GetBindposeCount()); this.GetBindposesNonAllocImpl(bindposes); } // Token: 0x06000AD7 RID: 2775 RVA: 0x000103A8 File Offset: 0x0000E5A8 public void GetBoneWeights(List boneWeights) { if (boneWeights == null) { throw new ArgumentNullException("The result boneWeights list cannot be null.", "boneWeights"); } this.PrepareUserBuffer(boneWeights, this.vertexCount); this.GetBoneWeightsNonAllocImpl(boneWeights); } // Token: 0x0200008E RID: 142 internal enum InternalShaderChannel { // Token: 0x0400010C RID: 268 Vertex, // Token: 0x0400010D RID: 269 Normal, // Token: 0x0400010E RID: 270 Color, // Token: 0x0400010F RID: 271 TexCoord0, // Token: 0x04000110 RID: 272 TexCoord1, // Token: 0x04000111 RID: 273 TexCoord2, // Token: 0x04000112 RID: 274 TexCoord3, // Token: 0x04000113 RID: 275 Tangent } // Token: 0x0200008F RID: 143 internal enum InternalVertexChannelType { // Token: 0x04000115 RID: 277 Float, // Token: 0x04000116 RID: 278 Color = 2 } } }