using System; namespace UnityEditor.XR.ARSubsystems { /// /// Extensions to [System.Guid](xref:System.Guid) /// public static class GuidExtensions { /// /// Decomposes a 16-byte [Guid](xref:System.Guid) into two 8-byte ulongs. /// Recompose using [UnityEngine.XR.ARSubsystems.GuidUtil.Compose](xref:UnityEngine.XR.ARSubsystems.GuidUtil.Compose(System.UInt64,System.UInt64)). /// /// The Guid being extended /// The lower 8 bytes of the Guid. /// The upper 8 bytes of the Guid. public static void Decompose(this Guid guid, out ulong low, out ulong high) { var bytes = guid.ToByteArray(); low = BitConverter.ToUInt64(bytes, 0); high = BitConverter.ToUInt64(bytes, 8); } } }