diff --git a/Explorer/Assets/DCL/Browser/DecentralandUrls/DecentralandUrlsSource.cs b/Explorer/Assets/DCL/Browser/DecentralandUrls/DecentralandUrlsSource.cs index 01f7c92a041..8e596112a73 100644 --- a/Explorer/Assets/DCL/Browser/DecentralandUrls/DecentralandUrlsSource.cs +++ b/Explorer/Assets/DCL/Browser/DecentralandUrls/DecentralandUrlsSource.cs @@ -121,7 +121,7 @@ private static string RawUrl(DecentralandUrl decentralandUrl) => DecentralandUrl.MarketplaceClaimName => $"https://decentraland.{ENV}/marketplace/names/claim", DecentralandUrl.WorldContentServer => $"https://worlds-content-server.decentraland.{ENV}/world", DecentralandUrl.Servers => $"https://peer.decentraland.{ENV}/lambdas/contracts/servers", - DecentralandUrl.MediaConverter => $"https://media-opticonverter.decentraland.{ENV}/convert?ktx2=true&fileUrl={{0}}", + DecentralandUrl.MediaConverter => $"https://metamorph-api.decentraland.{ENV}/convert?url={{0}}", DecentralandUrl.MarketplaceCredits => $"https://credits.decentraland.{ENV}", DecentralandUrl.GoShoppingWithMarketplaceCredits => $"https://decentraland.{ENV}/marketplace/browse?sortBy=newest&status=on_sale&withCredits=true", DecentralandUrl.EmailSubscriptions => $"https://notifications.decentraland.{ENV}", diff --git a/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/NFTShapes/GetNFTShapeIntention.cs b/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/NFTShapes/GetNFTShapeIntention.cs index eafaf6a5548..27e7032d69f 100644 --- a/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/NFTShapes/GetNFTShapeIntention.cs +++ b/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/NFTShapes/GetNFTShapeIntention.cs @@ -14,7 +14,6 @@ public struct GetNFTShapeIntention : ILoadingIntention, IEquatable true; public CommonLoadingArguments CommonArguments { get; set; } public readonly CancellationTokenSource CancellationTokenSource => CommonArguments.CancellationTokenSource; diff --git a/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/NFTShapes/LoadNFTShapeSystem.cs b/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/NFTShapes/LoadNFTShapeSystem.cs index b7878f93133..c1be04151c2 100644 --- a/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/NFTShapes/LoadNFTShapeSystem.cs +++ b/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/NFTShapes/LoadNFTShapeSystem.cs @@ -3,9 +3,9 @@ using CommunicationData.URLHelpers; using Cysharp.Threading.Tasks; using DCL.Diagnostics; -using DCL.FeatureFlags; +using DCL.Multiplayer.Connections.DecentralandUrls; +using DCL.Optimization.Pools; using DCL.WebRequests; -using DCL.WebRequests.WebContentSizes; using ECS.Prioritization.Components; using ECS.StreamableLoading.Cache; using ECS.StreamableLoading.Cache.Disk; @@ -15,6 +15,7 @@ using ECS.StreamableLoading.Textures; using System; using System.Threading; +using UnityEngine; namespace ECS.StreamableLoading.NFTShapes { @@ -22,38 +23,45 @@ namespace ECS.StreamableLoading.NFTShapes [LogCategory(ReportCategory.NFT_SHAPE_WEB_REQUEST)] public partial class LoadNFTShapeSystem : LoadSystemBase { + private const long MAX_PREVIEW_SIZE = 8388608; + private readonly IWebRequestController webRequestController; - private readonly IWebContentSizes webContentSizes; + private readonly ExtendedObjectPool videoTexturePool; + private readonly IDecentralandUrlsSource urlsSource; private readonly bool ktxEnabled; - public LoadNFTShapeSystem(World world, IStreamableCache cache, IWebRequestController webRequestController, IDiskCache diskCache, IWebContentSizes webContentSizes, - bool ktxEnabled) - : base( - world, cache, new DiskCacheOptions(diskCache, GetNFTShapeIntention.DiskHashCompute.INSTANCE, "nft") - ) + public LoadNFTShapeSystem(World world, IStreamableCache cache, IWebRequestController webRequestController, IDiskCache diskCache, bool ktxEnabled, + ExtendedObjectPool videoTexturePool, IDecentralandUrlsSource urlsSource) + : base(world, cache, new DiskCacheOptions(diskCache, GetNFTShapeIntention.DiskHashCompute.INSTANCE, "nft")) { this.webRequestController = webRequestController; - this.webContentSizes = webContentSizes; + this.videoTexturePool = videoTexturePool; + this.urlsSource = urlsSource; this.ktxEnabled = ktxEnabled; } protected override async UniTask> FlowInternalAsync(GetNFTShapeIntention intention, StreamableLoadingState state, IPartitionComponent partition, CancellationToken ct) { string imageUrl = await ImageUrlAsync(intention.CommonArguments, ct); + string convertUrl = ktxEnabled ? string.Format(urlsSource.Url(DecentralandUrl.MediaConverter), Uri.EscapeDataString(imageUrl)) : imageUrl; + var contentInfo = await WebContentInfo.FetchAsync(convertUrl, ct); - if (!ktxEnabled) - { - bool isOkSize = await webContentSizes.IsOkSizeAsync(imageUrl, ct); + if (!ktxEnabled && contentInfo is { Type: WebContentInfo.ContentType.Image, SizeInBytes: > MAX_PREVIEW_SIZE }) + return new StreamableLoadingResult(GetReportCategory(), new Exception("Image size is too big")); - if (isOkSize == false) - return new StreamableLoadingResult(GetReportCategory(), new Exception("Image size is too big")); - } + return contentInfo.Type switch + { + WebContentInfo.ContentType.Image or WebContentInfo.ContentType.KTX2 => await HandleImageAsync(imageUrl, ct), + WebContentInfo.ContentType.Video => HandleVideo(convertUrl), + _ => throw new NotSupportedException("Could not handle content type " + contentInfo.Type + " for url " + convertUrl) + }; + } - // No need to check the size since we're using our converter so size will always be ok - // texture request + private async UniTask> HandleImageAsync(string url, CancellationToken ct) + { // Attempts should be always 1 as there is a repeat loop in `LoadSystemBase` var result = await webRequestController.GetTextureAsync( - new CommonLoadingArguments(URLAddress.FromString(imageUrl), attempts: 1), + new CommonLoadingArguments(URLAddress.FromString(url), attempts: 1), new GetTextureArguments(TextureType.Albedo, true), new GetTextureWebRequest.CreateTextureOp(GetNFTShapeIntention.WRAP_MODE, GetNFTShapeIntention.FILTER_MODE), ct, @@ -63,12 +71,18 @@ protected override async UniTask> FlowInt if (result == null) return new StreamableLoadingResult( GetReportData(), - new Exception($"Error loading texture from url {intention.CommonArguments.URL}") + new Exception($"Error loading texture from url {url}") ); return new StreamableLoadingResult(new Texture2DData(result)); } + private StreamableLoadingResult HandleVideo(string url) + { + var texture2D = videoTexturePool.Get(); + return new StreamableLoadingResult(new Texture2DData(texture2D, url)); + } + private async UniTask ImageUrlAsync(CommonArguments commonArguments, CancellationToken ct) { GenericDownloadHandlerUtils.Adapter infoRequest = webRequestController.GetAsync(commonArguments, ct, GetReportData()); diff --git a/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/GetTextureIntention.cs b/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/GetTextureIntention.cs index dc119caec1b..f4e22caa584 100644 --- a/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/GetTextureIntention.cs +++ b/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/GetTextureIntention.cs @@ -10,7 +10,6 @@ namespace ECS.StreamableLoading.Textures { public struct GetTextureIntention : ILoadingIntention, IEquatable { - public bool DisableDiskCache => true; public CommonLoadingArguments CommonArguments { get; set; } public readonly TextureWrapMode WrapMode; diff --git a/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/Texture2DData.cs b/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/Texture2DData.cs index 60686d1fe9b..662ece115d7 100644 --- a/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/Texture2DData.cs +++ b/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/Texture2DData.cs @@ -11,6 +11,7 @@ namespace ECS.StreamableLoading.Textures public class Texture2DData : StreamableRefCountData, ISizedContent { private readonly IOwnedTexture2D? ownedTexture2D; + public string? VideoURL { get; set; } public long ByteSize => Asset.GetRawTextureData().Length; @@ -21,11 +22,18 @@ public class Texture2DData : StreamableRefCountData, ISizedContent protected override void DestroyObject() { ownedTexture2D?.Dispose(); - UnityObjectUtils.SafeDestroy(Asset); + + if (VideoURL == null) + UnityObjectUtils.SafeDestroy(Asset); } public Texture2DData(Texture2D texture) : base(texture, ReportCategory.TEXTURES) { } + public Texture2DData(Texture2D texture, string videoUrl) : base(texture, ReportCategory.TEXTURES) + { + VideoURL = videoUrl; + } + public Texture2DData(IOwnedTexture2D asset) : base(asset.Texture, ReportCategory.TEXTURES) { ownedTexture2D = asset; diff --git a/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/TextureDiskSerializer.cs b/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/TextureDiskSerializer.cs index 8be0b7c8ab1..4c6d0b5249f 100644 --- a/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/TextureDiskSerializer.cs +++ b/Explorer/Assets/DCL/Infrastructure/ECS/StreamableLoading/Textures/TextureDiskSerializer.cs @@ -10,9 +10,6 @@ namespace ECS.StreamableLoading.Textures { public class TextureDiskSerializer : IDiskSerializer> { - public SerializeMemoryIterator Serialize(Texture2DData data) => - ToArray(data); - public async UniTask DeserializeAsync(SlicedOwnedMemory data, CancellationToken token) { var meta = Meta.FromSpan(data.Memory.Span); @@ -32,7 +29,7 @@ public async UniTask DeserializeAsync(SlicedOwnedMemory dat return new Texture2DData(texture); } - private static SerializeMemoryIterator ToArray(Texture2DData data) + public SerializeMemoryIterator Serialize(Texture2DData data) { var textureData = data.Asset.GetRawTextureData()!; diff --git a/Explorer/Assets/DCL/Infrastructure/ECS/Unity/Textures/Components/VideoTextureConsumer.cs b/Explorer/Assets/DCL/Infrastructure/ECS/Unity/Textures/Components/VideoTextureConsumer.cs index 274ade16522..661cab28b3f 100644 --- a/Explorer/Assets/DCL/Infrastructure/ECS/Unity/Textures/Components/VideoTextureConsumer.cs +++ b/Explorer/Assets/DCL/Infrastructure/ECS/Unity/Textures/Components/VideoTextureConsumer.cs @@ -62,6 +62,12 @@ public VideoTextureConsumer(Texture2D texture) renderers = new List(); } + public VideoTextureConsumer(Texture2DData t2dd) + { + Texture = t2dd; + renderers = new List(); + } + public void Dispose() { // On Dispose video textures are dereferenced by material that acquired it diff --git a/Explorer/Assets/DCL/Infrastructure/Global/StaticContainer.cs b/Explorer/Assets/DCL/Infrastructure/Global/StaticContainer.cs index b9a981e6468..6acd4cbe65a 100644 --- a/Explorer/Assets/DCL/Infrastructure/Global/StaticContainer.cs +++ b/Explorer/Assets/DCL/Infrastructure/Global/StaticContainer.cs @@ -264,7 +264,7 @@ await UniTask.WhenAll( { new TransformsPlugin(sharedDependencies, exposedPlayerTransform, exposedGlobalDataContainer.ExposedCameraData), new BillboardPlugin(exposedGlobalDataContainer.ExposedCameraData), - new NFTShapePlugin(decentralandUrlsSource, container.assetsProvisioner, sharedDependencies.FrameTimeBudget, componentsContainer.ComponentPoolsRegistry, container.WebRequestsContainer.WebRequestController, container.CacheCleaner, textureDiskCache, container.FeatureFlagsCache), + new NFTShapePlugin(decentralandUrlsSource, container.assetsProvisioner, sharedDependencies.FrameTimeBudget, componentsContainer.ComponentPoolsRegistry, container.WebRequestsContainer.WebRequestController, container.CacheCleaner, textureDiskCache, container.FeatureFlagsCache, videoTexturePool), new TextShapePlugin(sharedDependencies.FrameTimeBudget, container.CacheCleaner, componentsContainer.ComponentPoolsRegistry), new MaterialsPlugin(sharedDependencies, videoTexturePool), textureResolvePlugin, diff --git a/Explorer/Assets/DCL/PluginSystem/Global/NFTShapePluginSettings.cs b/Explorer/Assets/DCL/PluginSystem/Global/NFTShapePluginSettings.cs index c4b4750fa1c..d5803fbe687 100644 --- a/Explorer/Assets/DCL/PluginSystem/Global/NFTShapePluginSettings.cs +++ b/Explorer/Assets/DCL/PluginSystem/Global/NFTShapePluginSettings.cs @@ -1,5 +1,4 @@ using DCL.SDKComponents.NFTShape.Frames.Pool; -using DCL.WebRequests.WebContentSizes.Sizes; using System; using UnityEngine; @@ -11,8 +10,5 @@ public class NFTShapePluginSettings : IDCLPluginSettings [field: Header("Nft Shape")] [field: Space] [field: SerializeField] public NFTShapeSettings Settings { get; private set; } - - [field: SerializeField] - public MaxSize MaxSizeOfNftForDownload { get; private set; } } } diff --git a/Explorer/Assets/DCL/PluginSystem/World/NFTShapePlugin.cs b/Explorer/Assets/DCL/PluginSystem/World/NFTShapePlugin.cs index 4cf92bb2140..a284adfe461 100644 --- a/Explorer/Assets/DCL/PluginSystem/World/NFTShapePlugin.cs +++ b/Explorer/Assets/DCL/PluginSystem/World/NFTShapePlugin.cs @@ -16,8 +16,6 @@ using DCL.SDKComponents.NFTShape.Renderer.Factory; using DCL.SDKComponents.NFTShape.System; using DCL.WebRequests; -using DCL.WebRequests.WebContentSizes; -using DCL.WebRequests.WebContentSizes.Sizes.Lazy; using ECS.Abstract; using ECS.LifeCycle; using ECS.LifeCycle.Systems; @@ -28,6 +26,7 @@ using ECS.StreamableLoading.Textures; using System.Collections.Generic; using System.Threading; +using UnityEngine; namespace DCL.PluginSystem.World { @@ -39,10 +38,9 @@ public class NFTShapePlugin : IDCLWorldPlugin private readonly IComponentPoolsRegistry componentPoolsRegistry; private readonly IWebRequestController webRequestController; private readonly IFramePrefabs framePrefabs; - private readonly IWebContentSizes webContentSizes; - private readonly ILazyMaxSize lazyMaxSize; private readonly IDiskCache diskCache; private readonly FeatureFlagsCache featureFlags; + private readonly ExtendedObjectPool videoTexturePool; private readonly ISizedStreamableCache cache = new NftShapeCache(); static NFTShapePlugin() @@ -58,7 +56,8 @@ public NFTShapePlugin( IWebRequestController webRequestController, CacheCleaner cacheCleaner, IDiskCache diskCache, - FeatureFlagsCache featureFlags + FeatureFlagsCache featureFlags, + ExtendedObjectPool videoTexturePool ) : this( decentralandUrlsSource, instantiationFrameTimeBudgetProvider, @@ -67,10 +66,9 @@ FeatureFlagsCache featureFlags framePrefabs, webRequestController, cacheCleaner, - new IWebContentSizes.Default(LazyMaxSize(out var lazyMaxSize)), - lazyMaxSize, diskCache, - featureFlags + featureFlags, + videoTexturePool ) { } public NFTShapePlugin( @@ -81,10 +79,9 @@ public NFTShapePlugin( IFramePrefabs framePrefabs, IWebRequestController webRequestController, CacheCleaner cacheCleaner, - IWebContentSizes webContentSizes, - ILazyMaxSize lazyMaxSize, IDiskCache diskCache, - FeatureFlagsCache featureFlags + FeatureFlagsCache featureFlags, + ExtendedObjectPool videoTexturePool ) : this( decentralandUrlsSource, new PoolNFTShapeRendererFactory(componentPoolsRegistry, framesPool), @@ -93,10 +90,9 @@ FeatureFlagsCache featureFlags webRequestController, cacheCleaner, framePrefabs, - webContentSizes, - lazyMaxSize, diskCache, - featureFlags + featureFlags, + videoTexturePool ) { } public NFTShapePlugin( @@ -107,10 +103,9 @@ public NFTShapePlugin( IWebRequestController webRequestController, CacheCleaner cacheCleaner, IFramePrefabs framePrefabs, - IWebContentSizes webContentSizes, - ILazyMaxSize lazyMaxSize, IDiskCache diskCache, - FeatureFlagsCache featureFlags + FeatureFlagsCache featureFlags, + ExtendedObjectPool videoTexturePool ) { this.decentralandUrlsSource = decentralandUrlsSource; @@ -119,10 +114,9 @@ FeatureFlagsCache featureFlags this.componentPoolsRegistry = componentPoolsRegistry; this.webRequestController = webRequestController; this.framePrefabs = framePrefabs; - this.webContentSizes = webContentSizes; - this.lazyMaxSize = lazyMaxSize; this.diskCache = diskCache; this.featureFlags = featureFlags; + this.videoTexturePool = videoTexturePool; cacheCleaner.Register(cache); } @@ -133,8 +127,6 @@ public void Dispose() public UniTask InitializeAsync(NFTShapePluginSettings settings, CancellationToken ct) { - lazyMaxSize.Initialize(settings.MaxSizeOfNftForDownload); - return framePrefabs.InitializeAsync( settings.Settings.FramePrefabs(), settings.Settings.DefaultFrame(), @@ -148,7 +140,7 @@ public void InjectToWorld(ref ArchSystemsWorldBuilder builder, bool isKtxEnabled = featureFlags.Configuration.IsEnabled(FeatureFlagsStrings.KTX2_CONVERSION); - LoadNFTShapeSystem.InjectToWorld(ref builder, cache, webRequestController, diskCache, webContentSizes, isKtxEnabled); + LoadNFTShapeSystem.InjectToWorld(ref builder, cache, webRequestController, diskCache, isKtxEnabled, videoTexturePool, decentralandUrlsSource); LoadCycleNftShapeSystem.InjectToWorld(ref builder, new BasedURNSource(decentralandUrlsSource)); InstantiateNftShapeSystem.InjectToWorld(ref builder, nftShapeRendererFactory, instantiationFrameTimeBudgetProvider, framePrefabs, buffer); VisibilityNftShapeSystem.InjectToWorld(ref builder, buffer); @@ -163,10 +155,5 @@ private static IFramePrefabs NewFramePrefabs(IAssetsProvisioner assetsProvisione { return framePrefabs = new AssetProvisionerFramePrefabs(assetsProvisioner); } - - private static ILazyMaxSize LazyMaxSize(out ILazyMaxSize lazyMaxSize) - { - return lazyMaxSize = new LazyMaxSize(); - } } } diff --git a/Explorer/Assets/DCL/SDKComponents/NFTShape/Demo/NFTShapeDemoWorld.cs b/Explorer/Assets/DCL/SDKComponents/NFTShape/Demo/NFTShapeDemoWorld.cs index fd406dce668..04d4a649690 100644 --- a/Explorer/Assets/DCL/SDKComponents/NFTShape/Demo/NFTShapeDemoWorld.cs +++ b/Explorer/Assets/DCL/SDKComponents/NFTShape/Demo/NFTShapeDemoWorld.cs @@ -2,7 +2,6 @@ using DCL.Browser.DecentralandUrls; using DCL.DemoWorlds; using DCL.ECSComponents; -using DCL.FeatureFlags; using DCL.Multiplayer.Connections.DecentralandUrls; using DCL.Optimization.PerformanceBudgeting; using DCL.Optimization.Pools; @@ -11,10 +10,9 @@ using DCL.SDKComponents.NFTShape.Frames.Pool; using DCL.SDKComponents.NFTShape.Renderer.Factory; using DCL.SDKComponents.NFTShape.System; +using DCL.SDKComponents.VideoPlayer; using DCL.Utilities.Extensions; using DCL.WebRequests; -using DCL.WebRequests.WebContentSizes; -using DCL.WebRequests.WebContentSizes.Sizes; using ECS.Abstract; using ECS.Prioritization.Components; using ECS.StreamableLoading.Cache.Disk; @@ -63,13 +61,9 @@ public NFTShapeDemoWorld(World world, IFramesPool framesPool, new NftShapeCache(), IWebRequestController.DEFAULT, IDiskCache.Null.INSTANCE, - new IWebContentSizes.Default( - new MaxSize - { - maxSizeInBytes = 300 * 1024 * 1024, - } - ), - true + true, + VideoTextureFactory.CreateVideoTexturesPool(), + new DecentralandUrlsSource(DecentralandEnvironment.Zone, ILaunchMode.PLAY) ).InitializeAndReturnSelf(), w => new LoadCycleNftShapeSystem(w, new BasedURNSource(new DecentralandUrlsSource(DecentralandEnvironment.Org, ILaunchMode.PLAY))), w => new InstantiateNftShapeSystem(w, new PoolNFTShapeRendererFactory(new ComponentPoolsRegistry(), framesPool), new FrameTimeCapBudget.Default(), framePrefabs, buffer), diff --git a/Explorer/Assets/DCL/SDKComponents/NFTShape/System/LoadCycleNftShapeSystem.cs b/Explorer/Assets/DCL/SDKComponents/NFTShape/System/LoadCycleNftShapeSystem.cs index 032a2b9be34..e2f4339fb10 100644 --- a/Explorer/Assets/DCL/SDKComponents/NFTShape/System/LoadCycleNftShapeSystem.cs +++ b/Explorer/Assets/DCL/SDKComponents/NFTShape/System/LoadCycleNftShapeSystem.cs @@ -11,6 +11,9 @@ using ECS.StreamableLoading.NFTShapes.URNs; using ECS.StreamableLoading.Textures; using ECS.Unity.Groups; +using ECS.Unity.Textures.Components; +using UnityEngine; +using Utility.Arch; using Promise = ECS.StreamableLoading.Common.AssetPromise; namespace DCL.SDKComponents.NFTShape.System @@ -42,14 +45,43 @@ private void Start(in Entity entity, in PBNftShape nftShape, in PartitionCompone } [Query] - private void FinishAndApply(ref NFTLoadingComponent nftLoadingComponent, in NftShapeRendererComponent nftShapeRendererComponent) + private void FinishAndApply(Entity entity, ref NFTLoadingComponent nftLoadingComponent, in NftShapeRendererComponent nftShapeRendererComponent) { if (!nftLoadingComponent.Promise.IsConsumed && nftLoadingComponent.Promise.TryConsume(World!, out StreamableLoadingResult result)) { if (result.Succeeded) + { nftShapeRendererComponent.PoolableComponent.Apply(result.Asset!); - else - nftShapeRendererComponent.PoolableComponent.NotifyFailed(); + + if (result.Asset?.VideoURL != null) + { + var vtc = new VideoTextureConsumer(result.Asset); + var texture2D = vtc.Texture.Asset; + texture2D.Reinitialize(1, 1); + texture2D.SetPixel(0, 0, Color.clear); + texture2D.Apply(); + + if (World.TryGet(entity, out var videoPlayer)) + { + videoPlayer!.Src = result.Asset.VideoURL; + videoPlayer.IsDirty = true; + + World.Add(entity, vtc); + } + else + { + var pbVideo = new PBVideoPlayer + { + Src = result.Asset.VideoURL, + Playing = true, + Loop = true, + }; + + World.Add(entity, pbVideo, vtc); + } + } + } + else { nftShapeRendererComponent.PoolableComponent.NotifyFailed(); } } } } diff --git a/Explorer/Assets/DCL/WebRequests/Texture/GetTextureArguments.cs b/Explorer/Assets/DCL/WebRequests/Texture/GetTextureArguments.cs index 3e34806cebb..8aa9753b57e 100644 --- a/Explorer/Assets/DCL/WebRequests/Texture/GetTextureArguments.cs +++ b/Explorer/Assets/DCL/WebRequests/Texture/GetTextureArguments.cs @@ -5,7 +5,7 @@ public readonly struct GetTextureArguments public readonly TextureType TextureType; public readonly bool UseKtx; - public GetTextureArguments(TextureType textureType, bool useKtx = false) + public GetTextureArguments(TextureType textureType, bool useKtx = true) { this.TextureType = textureType; this.UseKtx = useKtx; diff --git a/Explorer/Assets/DCL/WebRequests/Texture/GetTextureWebRequest.cs b/Explorer/Assets/DCL/WebRequests/Texture/GetTextureWebRequest.cs index fd8913f55a9..acad2897df8 100644 --- a/Explorer/Assets/DCL/WebRequests/Texture/GetTextureWebRequest.cs +++ b/Explorer/Assets/DCL/WebRequests/Texture/GetTextureWebRequest.cs @@ -17,13 +17,11 @@ namespace DCL.WebRequests { private readonly string url; private readonly TextureType textureType; - private readonly bool ktxEnabled; - private GetTextureWebRequest(UnityWebRequest unityWebRequest, string url, TextureType textureType, bool ktxEnabled) + private GetTextureWebRequest(UnityWebRequest unityWebRequest, string url, TextureType textureType) { this.url = url; this.textureType = textureType; - this.ktxEnabled = ktxEnabled; UnityWebRequest = unityWebRequest; } @@ -38,12 +36,10 @@ public static CreateTextureOp CreateTexture(TextureWrapMode wrapMode, FilterMode internal static GetTextureWebRequest Initialize(in CommonArguments commonArguments, GetTextureArguments textureArguments, IDecentralandUrlsSource urlsSource, bool ktxEnabled) { bool useKtx = textureArguments.UseKtx && ktxEnabled; - - // $"http://localhost:8000/convert?ktx2=true&fileUrl={{1}}"; string requestUrl = useKtx ? string.Format(urlsSource.Url(DecentralandUrl.MediaConverter), Uri.EscapeDataString(commonArguments.URL)) : commonArguments.URL; + UnityWebRequest webRequest = UnityWebRequest.Get(requestUrl); - UnityWebRequest wr = UnityWebRequest.Get(requestUrl); - return new GetTextureWebRequest(wr, requestUrl, textureArguments.TextureType, useKtx); + return new GetTextureWebRequest(webRequest, requestUrl, textureArguments.TextureType); } public readonly struct CreateTextureOp : IWebRequestOp @@ -59,7 +55,9 @@ public CreateTextureOp(TextureWrapMode wrapMode, FilterMode filterMode) public UniTask ExecuteAsync(GetTextureWebRequest webRequest, CancellationToken ct) { - return webRequest.ktxEnabled ? ExecuteKtxAsync(webRequest, ct) : ExecuteNoCompressionAsync(webRequest, ct); + string? contentType = webRequest.UnityWebRequest.GetResponseHeader("Content-Type"); + + return contentType == "image/ktx2" ? ExecuteKtxAsync(webRequest, ct) : ExecuteNoCompressionAsync(webRequest, ct); } private UniTask ExecuteNoCompressionAsync(GetTextureWebRequest webRequest, CancellationToken ct) @@ -85,7 +83,7 @@ public CreateTextureOp(TextureWrapMode wrapMode, FilterMode filterMode) texture.filterMode = filterMode; texture.SetDebugName(webRequest.url); ProfilingCounters.TexturesAmount.Value++; - return UniTask.FromResult((IOwnedTexture2D?)new IOwnedTexture2D.Const(texture)); + return UniTask.FromResult(new IOwnedTexture2D.Const(texture)); } private async UniTask ExecuteKtxAsync(GetTextureWebRequest webRequest, CancellationToken ct) diff --git a/Explorer/Assets/DCL/WebRequests/WebContentInfo.cs b/Explorer/Assets/DCL/WebRequests/WebContentInfo.cs new file mode 100644 index 00000000000..b00d7e5eec6 --- /dev/null +++ b/Explorer/Assets/DCL/WebRequests/WebContentInfo.cs @@ -0,0 +1,78 @@ +using Cysharp.Threading.Tasks; +using System; +using System.Threading; +using System.Threading.Tasks; +using UnityEngine.Networking; + +namespace DCL.WebRequests +{ + public class WebContentInfo + { + public readonly ContentType Type; + public readonly long SizeInBytes; + + public WebContentInfo(ContentType type, long sizeInBytes) + { + Type = type; + SizeInBytes = sizeInBytes; + } + + public static async Task FetchAsync(string url, CancellationToken ct = default) + { + var request = UnityWebRequest.Head(url); + await request.SendWebRequest().WithCancellation(ct); + + return await FetchAsync(request); + } + + public static Task FetchAsync(UnityWebRequest request) + { + if (request.result != UnityWebRequest.Result.Success) + throw new Exception("Failed to fetch web content info: " + request.error); + + return Task.FromResult(new WebContentInfo( + GetContentType(request), + GetSizeInBytes(request) + )); + } + + private static ContentType GetContentType(UnityWebRequest request) + { + string? contentType = request.GetResponseHeader("Content-Type"); + + if (contentType == null) + { + // For old converter only, which does not return content type + if(request.url.EndsWith(".ktx2")) return ContentType.KTX2; + if(request.url.EndsWith(".mp4")) return ContentType.Video; + + return ContentType.Unknown; + } + + + if (contentType == "image/ktx2") return ContentType.KTX2; + if (contentType.StartsWith("image/")) return ContentType.Image; + if (contentType.StartsWith("video/")) return ContentType.Video; + + return ContentType.Unknown; + } + + private static long GetSizeInBytes(UnityWebRequest request) + { + if (long.TryParse(request.GetResponseHeader("Content-Length") ?? "NONE", out long length)) + { + return length; + } + + return -1; + } + + public enum ContentType + { + Image, + KTX2, + Video, + Unknown + } + } +} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentInfo.cs.meta b/Explorer/Assets/DCL/WebRequests/WebContentInfo.cs.meta new file mode 100644 index 00000000000..4e2339cfeed --- /dev/null +++ b/Explorer/Assets/DCL/WebRequests/WebContentInfo.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 268cc9206c354b0396b67d76686fe209 +timeCreated: 1746639313 \ No newline at end of file diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/ContentLengthBasedWebContentSizes.cs b/Explorer/Assets/DCL/WebRequests/WebContentSizes/ContentLengthBasedWebContentSizes.cs deleted file mode 100644 index 17c76d40594..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/ContentLengthBasedWebContentSizes.cs +++ /dev/null @@ -1,33 +0,0 @@ -#nullable enable - -using Cysharp.Threading.Tasks; -using DCL.WebRequests.WebContentSizes.Sizes; -using System.Threading; -using UnityEngine.Networking; - -namespace DCL.WebRequests.WebContentSizes -{ - public class ContentLengthBasedWebContentSizes : IWebContentSizes - { - private readonly IMaxSize maxSize; - - public ContentLengthBasedWebContentSizes(IMaxSize maxSize) - { - this.maxSize = maxSize; - } - - public async UniTask IsOkSizeAsync(string url, CancellationToken cancellationToken) - { - var request = UnityWebRequest.Head(url)!; - await request.SendWebRequest()!.WithCancellation(cancellationToken); - - if (request.isDone && TryGetLength(request, out ulong length)) - return length != 0 && length < maxSize.MaxSizeInBytes(); - - return false; - } - - private static bool TryGetLength(UnityWebRequest request, out ulong length) => - ulong.TryParse(request.GetResponseHeader("Content-Length") ?? "NONE", out length); - } -} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/IWebContentSizes.cs b/Explorer/Assets/DCL/WebRequests/WebContentSizes/IWebContentSizes.cs deleted file mode 100644 index a336a9a44d3..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/IWebContentSizes.cs +++ /dev/null @@ -1,27 +0,0 @@ -using Cysharp.Threading.Tasks; -using DCL.WebRequests.WebContentSizes.Sizes; -using System.Threading; - -namespace DCL.WebRequests.WebContentSizes -{ - public interface IWebContentSizes - { - UniTask IsOkSizeAsync(string url, CancellationToken cancellationToken); - - class Default : IWebContentSizes - { - private readonly IWebContentSizes webContentSizes; - - public Default(IMaxSize maxSize) - { - webContentSizes = new SeveralWebContentSizes( - new ContentLengthBasedWebContentSizes(maxSize), - new RangeBasedWebContentSizes(maxSize) - ); - } - - public UniTask IsOkSizeAsync(string url, CancellationToken cancellationToken) => - webContentSizes.IsOkSizeAsync(url, cancellationToken); - } - } -} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.cs b/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.cs deleted file mode 100644 index 0831e9506cb..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.cs +++ /dev/null @@ -1,36 +0,0 @@ -#nullable enable - -using DCL.WebRequests.WebContentSizes.Sizes; -using UnityEngine; - -namespace DCL.WebRequests.WebContentSizes.Playground -{ - public class WebContentsSizesPlayground : MonoBehaviour - { - [SerializeField] private MaxSize maxSize = new (); - [SerializeField] private string targetUrl = string.Empty; - - private IWebContentSizes? webContentSizes; - - private void Start() - { - webContentSizes = AvailableWebContentSizes(); - } - - [ContextMenu(nameof(LaunchAsync))] - public async void LaunchAsync() - { - if (webContentSizes is null) - { - print("No IWebContentSizes available: launch scene"); - return; - } - - bool isOk = await webContentSizes.IsOkSizeAsync(targetUrl, destroyCancellationToken); - print($"Size for {targetUrl} is ok: {isOk}"); - } - - private IWebContentSizes AvailableWebContentSizes() => - webContentSizes ?? new IWebContentSizes.Default(maxSize); - } -} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.unity b/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.unity deleted file mode 100644 index 0b9ecc4908a..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.unity +++ /dev/null @@ -1,433 +0,0 @@ -%YAML 1.1 -%TAG !u! tag:unity3d.com,2011: ---- !u!29 &1 -OcclusionCullingSettings: - m_ObjectHideFlags: 0 - serializedVersion: 2 - m_OcclusionBakeSettings: - smallestOccluder: 5 - smallestHole: 0.25 - backfaceThreshold: 100 - m_SceneGUID: 00000000000000000000000000000000 - m_OcclusionCullingData: {fileID: 0} ---- !u!104 &2 -RenderSettings: - m_ObjectHideFlags: 0 - serializedVersion: 10 - m_Fog: 0 - m_FogColor: {r: 0.5, g: 0.5, b: 0.5, a: 1} - m_FogMode: 3 - m_FogDensity: 0.01 - m_LinearFogStart: 0 - m_LinearFogEnd: 300 - m_AmbientSkyColor: {r: 0.212, g: 0.227, b: 0.259, a: 1} - m_AmbientEquatorColor: {r: 0.114, g: 0.125, b: 0.133, a: 1} - m_AmbientGroundColor: {r: 0.047, g: 0.043, b: 0.035, a: 1} - m_AmbientIntensity: 1 - m_AmbientMode: 0 - m_SubtractiveShadowColor: {r: 0.42, g: 0.478, b: 0.627, a: 1} - m_SkyboxMaterial: {fileID: 10304, guid: 0000000000000000f000000000000000, type: 0} - m_HaloStrength: 0.5 - m_FlareStrength: 1 - m_FlareFadeSpeed: 3 - m_HaloTexture: {fileID: 0} - m_SpotCookie: {fileID: 10001, guid: 0000000000000000e000000000000000, type: 0} - m_DefaultReflectionMode: 0 - m_DefaultReflectionResolution: 128 - m_ReflectionBounces: 1 - m_ReflectionIntensity: 1 - m_CustomReflection: {fileID: 0} - m_Sun: {fileID: 0} - m_UseRadianceAmbientProbe: 0 ---- !u!157 &3 -LightmapSettings: - m_ObjectHideFlags: 0 - serializedVersion: 13 - m_BakeOnSceneLoad: 0 - m_GISettings: - serializedVersion: 2 - m_BounceScale: 1 - m_IndirectOutputScale: 1 - m_AlbedoBoost: 1 - m_EnvironmentLightingMode: 0 - m_EnableBakedLightmaps: 1 - m_EnableRealtimeLightmaps: 0 - m_LightmapEditorSettings: - serializedVersion: 12 - m_Resolution: 2 - m_BakeResolution: 40 - m_AtlasSize: 1024 - m_AO: 0 - m_AOMaxDistance: 1 - m_CompAOExponent: 1 - m_CompAOExponentDirect: 0 - m_ExtractAmbientOcclusion: 0 - m_Padding: 2 - m_LightmapParameters: {fileID: 0} - m_LightmapsBakeMode: 1 - m_TextureCompression: 1 - m_ReflectionCompression: 2 - m_MixedBakeMode: 2 - m_BakeBackend: 1 - m_PVRSampling: 1 - m_PVRDirectSampleCount: 32 - m_PVRSampleCount: 512 - m_PVRBounces: 2 - m_PVREnvironmentSampleCount: 256 - m_PVREnvironmentReferencePointCount: 2048 - m_PVRFilteringMode: 1 - m_PVRDenoiserTypeDirect: 1 - m_PVRDenoiserTypeIndirect: 1 - m_PVRDenoiserTypeAO: 1 - m_PVRFilterTypeDirect: 0 - m_PVRFilterTypeIndirect: 0 - m_PVRFilterTypeAO: 0 - m_PVREnvironmentMIS: 1 - m_PVRCulling: 1 - m_PVRFilteringGaussRadiusDirect: 1 - m_PVRFilteringGaussRadiusIndirect: 5 - m_PVRFilteringGaussRadiusAO: 2 - m_PVRFilteringAtrousPositionSigmaDirect: 0.5 - m_PVRFilteringAtrousPositionSigmaIndirect: 2 - m_PVRFilteringAtrousPositionSigmaAO: 1 - m_ExportTrainingData: 0 - m_TrainingDataDestination: TrainingData - m_LightProbeSampleCountMultiplier: 4 - m_LightingDataAsset: {fileID: 20201, guid: 0000000000000000f000000000000000, type: 0} - m_LightingSettings: {fileID: 0} ---- !u!196 &4 -NavMeshSettings: - serializedVersion: 2 - m_ObjectHideFlags: 0 - m_BuildSettings: - serializedVersion: 3 - agentTypeID: 0 - agentRadius: 0.5 - agentHeight: 2 - agentSlope: 45 - agentClimb: 0.4 - ledgeDropHeight: 0 - maxJumpAcrossDistance: 0 - minRegionArea: 2 - manualCellSize: 0 - cellSize: 0.16666667 - manualTileSize: 0 - tileSize: 256 - buildHeightMesh: 0 - maxJobWorkers: 0 - preserveTilesOutsideBounds: 0 - debug: - m_Flags: 0 - m_NavMeshData: {fileID: 0} ---- !u!1 &317106666 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 317106669} - - component: {fileID: 317106668} - - component: {fileID: 317106667} - - component: {fileID: 317106670} - m_Layer: 0 - m_Name: Main Camera - m_TagString: MainCamera - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!81 &317106667 -AudioListener: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 317106666} - m_Enabled: 1 ---- !u!20 &317106668 -Camera: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 317106666} - m_Enabled: 1 - serializedVersion: 2 - m_ClearFlags: 1 - m_BackGroundColor: {r: 0.19215687, g: 0.3019608, b: 0.4745098, a: 0} - m_projectionMatrixMode: 1 - m_GateFitMode: 2 - m_FOVAxisMode: 0 - m_Iso: 200 - m_ShutterSpeed: 0.005 - m_Aperture: 16 - m_FocusDistance: 10 - m_FocalLength: 50 - m_BladeCount: 5 - m_Curvature: {x: 2, y: 11} - m_BarrelClipping: 0.25 - m_Anamorphism: 0 - m_SensorSize: {x: 36, y: 24} - m_LensShift: {x: 0, y: 0} - m_NormalizedViewPortRect: - serializedVersion: 2 - x: 0 - y: 0 - width: 1 - height: 1 - near clip plane: 0.3 - far clip plane: 1000 - field of view: 60 - orthographic: 0 - orthographic size: 5 - m_Depth: -1 - m_CullingMask: - serializedVersion: 2 - m_Bits: 4294967295 - m_RenderingPath: -1 - m_TargetTexture: {fileID: 0} - m_TargetDisplay: 0 - m_TargetEye: 3 - m_HDR: 1 - m_AllowMSAA: 1 - m_AllowDynamicResolution: 0 - m_ForceIntoRT: 0 - m_OcclusionCulling: 1 - m_StereoConvergence: 10 - m_StereoSeparation: 0.022 ---- !u!4 &317106669 -Transform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 317106666} - serializedVersion: 2 - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 1, z: -10} - m_LocalScale: {x: 1, y: 1, z: 1} - m_ConstrainProportionsScale: 0 - m_Children: [] - m_Father: {fileID: 0} - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!114 &317106670 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 317106666} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: a79441f348de89743a2939f4d699eac1, type: 3} - m_Name: - m_EditorClassIdentifier: - m_RenderShadows: 1 - m_RequiresDepthTextureOption: 2 - m_RequiresOpaqueTextureOption: 2 - m_CameraType: 0 - m_Cameras: [] - m_RendererIndex: -1 - m_VolumeLayerMask: - serializedVersion: 2 - m_Bits: 1 - m_VolumeTrigger: {fileID: 0} - m_VolumeFrameworkUpdateModeOption: 2 - m_RenderPostProcessing: 0 - m_Antialiasing: 0 - m_AntialiasingQuality: 2 - m_StopNaN: 0 - m_Dithering: 0 - m_ClearDepth: 1 - m_AllowXRRendering: 1 - m_AllowHDROutput: 1 - m_UseScreenCoordOverride: 0 - m_ScreenSizeOverride: {x: 0, y: 0, z: 0, w: 0} - m_ScreenCoordScaleBias: {x: 0, y: 0, z: 0, w: 0} - m_RequiresDepthTexture: 0 - m_RequiresColorTexture: 0 - m_Version: 2 - m_TaaSettings: - m_Quality: 3 - m_FrameInfluence: 0.1 - m_JitterScale: 1 - m_MipBias: 0 - m_VarianceClampScale: 0.9 - m_ContrastAdaptiveSharpening: 0 ---- !u!1 &1076564014 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 1076564016} - - component: {fileID: 1076564015} - - component: {fileID: 1076564017} - m_Layer: 0 - m_Name: Directional Light - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!108 &1076564015 -Light: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1076564014} - m_Enabled: 1 - serializedVersion: 11 - m_Type: 1 - m_Color: {r: 1, g: 0.95686275, b: 0.8392157, a: 1} - m_Intensity: 1 - m_Range: 10 - m_SpotAngle: 30 - m_InnerSpotAngle: 21.80208 - m_CookieSize: 10 - m_Shadows: - m_Type: 2 - m_Resolution: -1 - m_CustomResolution: -1 - m_Strength: 1 - m_Bias: 0.05 - m_NormalBias: 0.4 - m_NearPlane: 0.2 - m_CullingMatrixOverride: - e00: 1 - e01: 0 - e02: 0 - e03: 0 - e10: 0 - e11: 1 - e12: 0 - e13: 0 - e20: 0 - e21: 0 - e22: 1 - e23: 0 - e30: 0 - e31: 0 - e32: 0 - e33: 1 - m_UseCullingMatrixOverride: 0 - m_Cookie: {fileID: 0} - m_DrawHalo: 0 - m_Flare: {fileID: 0} - m_RenderMode: 0 - m_CullingMask: - serializedVersion: 2 - m_Bits: 4294967295 - m_RenderingLayerMask: 1 - m_Lightmapping: 4 - m_LightShadowCasterMode: 0 - m_AreaSize: {x: 1, y: 1} - m_BounceIntensity: 1 - m_ColorTemperature: 6570 - m_UseColorTemperature: 0 - m_BoundingSphereOverride: {x: 0, y: 0, z: 0, w: 0} - m_UseBoundingSphereOverride: 0 - m_UseViewFrustumForShadowCasterCull: 1 - m_ForceVisible: 0 - m_ShadowRadius: 0 - m_ShadowAngle: 0 - m_LightUnit: 1 - m_LuxAtDistance: 1 - m_EnableSpotReflector: 1 ---- !u!4 &1076564016 -Transform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1076564014} - serializedVersion: 2 - m_LocalRotation: {x: 0.40821788, y: -0.23456968, z: 0.10938163, w: 0.8754261} - m_LocalPosition: {x: 0, y: 3, z: 0} - m_LocalScale: {x: 1, y: 1, z: 1} - m_ConstrainProportionsScale: 0 - m_Children: [] - m_Father: {fileID: 0} - m_LocalEulerAnglesHint: {x: 50, y: -30, z: 0} ---- !u!114 &1076564017 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1076564014} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 474bcb49853aa07438625e644c072ee6, type: 3} - m_Name: - m_EditorClassIdentifier: - m_Version: 3 - m_UsePipelineSettings: 1 - m_AdditionalLightsShadowResolutionTier: 2 - m_LightLayerMask: 1 - m_RenderingLayers: 1 - m_CustomShadowLayers: 0 - m_ShadowLayerMask: 1 - m_ShadowRenderingLayers: 1 - m_LightCookieSize: {x: 1, y: 1} - m_LightCookieOffset: {x: 0, y: 0} - m_SoftShadowQuality: 0 ---- !u!1 &1971180850 -GameObject: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - serializedVersion: 6 - m_Component: - - component: {fileID: 1971180851} - - component: {fileID: 1971180852} - m_Layer: 0 - m_Name: Boot - m_TagString: Untagged - m_Icon: {fileID: 0} - m_NavMeshLayer: 0 - m_StaticEditorFlags: 0 - m_IsActive: 1 ---- !u!4 &1971180851 -Transform: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1971180850} - serializedVersion: 2 - m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} - m_LocalScale: {x: 1, y: 1, z: 1} - m_ConstrainProportionsScale: 0 - m_Children: [] - m_Father: {fileID: 0} - m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0} ---- !u!114 &1971180852 -MonoBehaviour: - m_ObjectHideFlags: 0 - m_CorrespondingSourceObject: {fileID: 0} - m_PrefabInstance: {fileID: 0} - m_PrefabAsset: {fileID: 0} - m_GameObject: {fileID: 1971180850} - m_Enabled: 1 - m_EditorHideFlags: 0 - m_Script: {fileID: 11500000, guid: 4976711299f946a0b306ab626cc9f0c3, type: 3} - m_Name: - m_EditorClassIdentifier: - maxSize: - maxSizeInBytes: 307200 - targetUrl: https://img.cryptokitties.co/0x06012c8cf97bead5deae237070f9587f8e7a266d/1631847.png ---- !u!1660057539 &9223372036854775807 -SceneRoots: - m_ObjectHideFlags: 0 - m_Roots: - - {fileID: 317106669} - - {fileID: 1076564016} - - {fileID: 1971180851} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/RangeBasedWebContentSizes.cs b/Explorer/Assets/DCL/WebRequests/WebContentSizes/RangeBasedWebContentSizes.cs deleted file mode 100644 index 6902c7222a9..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/RangeBasedWebContentSizes.cs +++ /dev/null @@ -1,90 +0,0 @@ -#nullable enable - -using Cysharp.Threading.Tasks; -using DCL.Diagnostics; -using DCL.WebRequests.WebContentSizes.Sizes; -using System; -using System.Linq; -using System.Threading; -using UnityEngine.Networking; - -namespace DCL.WebRequests.WebContentSizes -{ - public class RangeBasedWebContentSizes : IWebContentSizes - { - private readonly IMaxSize maxSize; - private readonly Action reasonLog; - private const ulong TRESS_HOLD_BYTES = 2048; - private const ulong UPPER_LIMIT = TRESS_HOLD_BYTES * 2; - - public RangeBasedWebContentSizes(IMaxSize maxSize) : this( - maxSize, - s => ReportHub.LogWarning(ReportCategory.GENERIC_WEB_REQUEST, s) - ) { } - - public RangeBasedWebContentSizes(IMaxSize maxSize, Action reasonLog) - { - this.maxSize = maxSize; - this.reasonLog = reasonLog; - } - - public async UniTask IsOkSizeAsync(string url, CancellationToken token) - { - using var request = NewRequest(url); - request.SendWebRequest().WithCancellation(token); - - while (token.IsCancellationRequested == false - && request.isDone == false) - { - if (request.downloadedBytes > UPPER_LIMIT) - { - reasonLog($"Seems the remote server doesn't support Range Header, Downloaded bytes {request.downloadedBytes} exceeded upper limit {UPPER_LIMIT}, aborting request"); - reasonLog(ReadableResponseHeaders(request)); - request.Abort(); - return false; - } - - await UniTask.Yield(); - } - - if (IsResultError(request)) - { - reasonLog($"Error while checking size of {url}: {request.error}"); - return false; - } - - if (IsDownloadedTooMuch(request)) - { - reasonLog($"Size of {url} is {request.downloadedBytes} bytes, which is greater than the tress hold of {TRESS_HOLD_BYTES} bytes"); - return false; - } - - return true; - } - - private UnityWebRequest NewRequest(string url) - { - var request = UnityWebRequest.Get(url)!; - ulong max = maxSize.MaxSizeInBytes(); - ulong tressHold = max + TRESS_HOLD_BYTES; - request.SetRequestHeader("Range", $"bytes:{max}-{tressHold}"); - request.SetRequestHeader("Accept-Range", $"bytes:{max}-{tressHold}"); - return request; - } - - private static bool IsDownloadedTooMuch(UnityWebRequest request) => - request.downloadedBytes > TRESS_HOLD_BYTES; - - private static bool IsResultError(UnityWebRequest request) => - request.result - is UnityWebRequest.Result.ConnectionError - or UnityWebRequest.Result.ProtocolError - or UnityWebRequest.Result.DataProcessingError; - - private static string ReadableResponseHeaders(UnityWebRequest request) - { - var list = request.GetResponseHeaders()!.Select(e => $"{e.Key}: {e.Value}"); - return $"Headers of response:\n{string.Join('\n', list)}"; - } - } -} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/SeveralWebContentSizes.cs b/Explorer/Assets/DCL/WebRequests/WebContentSizes/SeveralWebContentSizes.cs deleted file mode 100644 index 0a623ef06a5..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/SeveralWebContentSizes.cs +++ /dev/null @@ -1,34 +0,0 @@ -#nullable enable - -using Cysharp.Threading.Tasks; -using System.Collections.Generic; -using System.Threading; - -namespace DCL.WebRequests.WebContentSizes -{ - public class SeveralWebContentSizes : IWebContentSizes - { - private readonly IReadOnlyList list; - - public SeveralWebContentSizes(params IWebContentSizes[] list) : this(list as IReadOnlyList) { } - - public SeveralWebContentSizes(IReadOnlyList list) - { - this.list = list; - } - - public async UniTask IsOkSizeAsync(string url, CancellationToken cancellationToken) - { - foreach (var webContentSizes in list) - { - if (cancellationToken.IsCancellationRequested) - return false; - - if (await webContentSizes.IsOkSizeAsync(url, cancellationToken)) - return true; - } - - return false; - } - } -} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/SeveralWebContentSizes.cs.meta b/Explorer/Assets/DCL/WebRequests/WebContentSizes/SeveralWebContentSizes.cs.meta deleted file mode 100644 index af5621c9d12..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/SeveralWebContentSizes.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 8f75afcbbde64c11ace0c024af30bb09 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/IMaxSize.cs b/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/IMaxSize.cs deleted file mode 100644 index 5f32705c503..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/IMaxSize.cs +++ /dev/null @@ -1,7 +0,0 @@ -namespace DCL.WebRequests.WebContentSizes.Sizes -{ - public interface IMaxSize - { - ulong MaxSizeInBytes(); - } -} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/IMaxSize.cs.meta b/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/IMaxSize.cs.meta deleted file mode 100644 index f73e4f6b835..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/IMaxSize.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 80f2539d1e4d4c74b6b6da981116b67c -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/ILazyMaxSize.cs b/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/ILazyMaxSize.cs deleted file mode 100644 index 394d1496919..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/ILazyMaxSize.cs +++ /dev/null @@ -1,10 +0,0 @@ -using Cysharp.Threading.Tasks; -using System; - -namespace DCL.WebRequests.WebContentSizes.Sizes.Lazy -{ - public interface ILazyMaxSize : IMaxSize - { - void Initialize(IMaxSize maxSize); - } -} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/ILazyMaxSize.cs.meta b/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/ILazyMaxSize.cs.meta deleted file mode 100644 index a3d1a2d3926..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/ILazyMaxSize.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 2276f0f6228a4aac9d2a2c8c75730d81 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/LazyMaxSize.cs b/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/LazyMaxSize.cs deleted file mode 100644 index 111109e3ead..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/LazyMaxSize.cs +++ /dev/null @@ -1,22 +0,0 @@ -using System; - -namespace DCL.WebRequests.WebContentSizes.Sizes.Lazy -{ - public class LazyMaxSize : ILazyMaxSize - { - private IMaxSize? maxSize; - - public ulong MaxSizeInBytes() - { - if (maxSize == null) - throw new InvalidOperationException("Initialize MaxSize first"); - - return maxSize.MaxSizeInBytes(); - } - - public void Initialize(IMaxSize maxSize) - { - this.maxSize = maxSize; - } - } -} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/LazyMaxSize.cs.meta b/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/LazyMaxSize.cs.meta deleted file mode 100644 index 232a3e7a9f5..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy/LazyMaxSize.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: c2a62208904e46faaafb9f680e61d02b -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/MaxSize.cs b/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/MaxSize.cs deleted file mode 100644 index ad3cb65a5b2..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/MaxSize.cs +++ /dev/null @@ -1,13 +0,0 @@ -using System; - -namespace DCL.WebRequests.WebContentSizes.Sizes -{ - [Serializable] - public class MaxSize : IMaxSize - { - public ulong maxSizeInBytes; - - public ulong MaxSizeInBytes() => - maxSizeInBytes; - } -} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/MaxSize.cs.meta b/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/MaxSize.cs.meta deleted file mode 100644 index d19412f8f57..00000000000 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/MaxSize.cs.meta +++ /dev/null @@ -1,11 +0,0 @@ -fileFormatVersion: 2 -guid: 1e090c9569c548f293cad63469d89bd0 -MonoImporter: - externalObjects: {} - serializedVersion: 2 - defaultReferences: [] - executionOrder: 0 - icon: {instanceID: 0} - userData: - assetBundleName: - assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/.gitattributes b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/.gitattributes new file mode 100644 index 00000000000..50a46583888 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/.gitattributes @@ -0,0 +1,9 @@ +# Denote all files that are truly binary and should not be modified. +*.so binary filter=lfs diff=lfs merge=lfs +*.a binary filter=lfs diff=lfs merge=lfs +*.bundle binary filter=lfs diff=lfs merge=lfs +*.dll binary filter=lfs diff=lfs merge=lfs +*.bc filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.bytes filter=lfs diff=lfs merge=lfs -text +Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/MacOS/ktx_unity filter=lfs diff=lfs merge=lfs -text diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/.github/codecov.yml b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/.github/codecov.yml new file mode 100644 index 00000000000..0f74c0343a6 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/.github/codecov.yml @@ -0,0 +1,36 @@ +codecov: + require_ci_to_pass: false + notify: + wait_for_ci: true + +coverage: + precision: 2 + round: down + range: "50...70" + status: + patch: true + default_rules: + flag_coverage_not_uploaded_behavior: exclude + project: + default: + target: auto + # Threshold used for the PR Check + threshold: 0.5% + base: auto + if_ci_failed: success + informational: false + only_pulls: true + +# PR Comment configuration +comment: + layout: "reach,diff,flags,files" + behavior: default + require_changes: false + require_base: false + require_head: false + # Set this to the number of coverage jobs run in the PR + after_n_builds: 1 + +flag_management: + default_rules: + carryforward: true \ No newline at end of file diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/.signature b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/.signature new file mode 100755 index 00000000000..33e80dcff02 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/.signature @@ -0,0 +1,5 @@ +{ + "timestamp": 1728317404, + "signature": "kCJmdmQF+PSCdhu18uoJbg4vH9Yon8GHdeRNriie6/89G8WyaiTHU6Mi9AHBHV3NYbQVzDN0h1PtA5nyD99RKAi4cxBQQzroGdMaY+520CwO7aAbEUKSpUHVmccWfPoaLyDpEz/tEAVNa7V3+H/f2cKYhM3Eg/ip7cIXx7/A2cUztog5PUd6lgh/T2WrGFzELT0dVWnrFkKrCbzlxaSaZnbRRQJruM303X2fi85/vjNKhvIpjf98irbxiGlALxBLcD6qcuVM9/ZByeh/MtlLxZf/orHqdzUpl3621C3hSLEkSPeHcbDGfunpLvK4jovercNlgeFMW9bfu/jdvRYcrgSRqZDCjfoG6Ky54rwMA8esZP3vP8DkhggXkEUkgfv7SXd3AM6KvmPbgH3DuejC6nVNBpalTk5gWTJ05mLdxuw4zSylSUMZ+pECWNRO/KjM0QN6GF91PT5FyjfLxNILUGaBo8m4qJMGaM/Q5C/DKkiZqu6S8EAKkL/gL/StA8I1", + "publicKey": "LS0tLS1CRUdJTiBQVUJMSUMgS0VZLS0tLS0KTUlJQm9qQU5CZ2txaGtpRzl3MEJBUUVGQUFPQ0FZOEFNSUlCaWdLQ0FZRUFzdUhXYUhsZ0I1cVF4ZEJjTlJKSAordHR4SmoxcVY1NTdvMlZaRE1XaXhYRVBkRTBEMVFkT1JIRXNSS1RscmplUXlERU83ZlNQS0ZwZ1A3MU5TTnJCCkFHM2NFSU45aHNQVDhOVmllZmdWem5QTkVMenFkVmdEbFhpb2VpUnV6OERKWFgvblpmU1JWKytwbk9ySTRibG4KS0twelJlNW14OTc1SjhxZ1FvRktKT0NNRlpHdkJMR2MxSzZZaEIzOHJFODZCZzgzbUovWjBEYkVmQjBxZm13cgo2ZDVFUXFsd0E5Y3JZT1YyV1VpWXprSnBLNmJZNzRZNmM1TmpBcEFKeGNiaTFOaDlRVEhUcU44N0ZtMDF0R1ZwCjVNd1pXSWZuYVRUemEvTGZLelR5U0pka0tldEZMVGdkYXpMYlpzUEE2aHBSK0FJRTJhc0tLTi84UUk1N3UzU2cKL2xyMnZKS1IvU2l5eEN1Q20vQWJkYnJMbXk0WjlSdm1jMGdpclA4T0lLQWxBRWZ2TzV5Z2hSKy8vd1RpTFlzUQp1SllDM0V2UE16ZGdKUzdGR2FscnFLZzlPTCsxVzROY05yNWdveVdSUUJ0cktKaWlTZEJVWmVxb0RvSUY5NHpCCndGbzJJT1JFdXFqcU51M3diMWZIM3p1dGdtalFra3IxVjJhd3hmcExLWlROQWdNQkFBRT0KLS0tLS1FTkQgUFVCTElDIEtFWS0tLS0tCg" +} \ No newline at end of file diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/CHANGELOG.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/CHANGELOG.md new file mode 100644 index 00000000000..2290752a12f --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/CHANGELOG.md @@ -0,0 +1,389 @@ +# Changelog +All notable changes to this project will be documented in this file. + +The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), +and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). + +## [3.4.5] - 2024-10-07 + +### Added +- Root namespace to `Ktx` assembly definition. + +### Fixed +- WebGL build with Chinese Unity versions. +- Prevent crash by not using certain texture creation flags with OpenGL in Unity versions 2022.3.12 and older. + +## [3.4.4] - 2024-09-30 + +### Fixed +- Textures are not initialized and uploaded twice anymore giving improved performance from Unity 2022.1 or newer. +- macOS binary now properly signed, notarized and stapled. + +## [3.4.3] - 2024-09-05 + +### Changed +- Updated macOS binary to version 1.4.1 + +### Fixed +- Code signing error on upload to Mac Apple Store (fixes [#78](https://github.com/atteneder/DracoUnity/issues/78)) + +## [3.4.2] - 2024-08-07 + +### Fixed +- Error on macOS where the binary is not loaded since Apple cannot check it for malicious software. The binary has been code-signed and notarized. + +## [3.4.1] - 2024-05-15 + +### Added +- Added Apple Privacy Manifest documentation. + +## [3.4.0] - 2024-04-17 + +### Added +- Web binaries +- (CI) Code coverage and static analysis. +- Added Apple Privacy Manifest file to `/Plugins` directory. +- Windows ARM64 support +- Apple visionOS support + +### Changed +- Updated binaries to version [1.3.0](https://github.com/Unity-Technologies/ktx-plugin/releases/tag/release-github%2F1.3.0) (contains KTX-Software 4.3.2). +- Unity version-specific web sub-packages are not required anymore and will be removed automatically from the project upon detection (to avoid linker conflicts during web builds). + +### Fixed +- GUID conflict with Draco for Unity (tests only) +- Non-web libraries are properly included/excluded from builds again. +- Apple iOS/tvOS Device/Simulator SDK libraries are correctly included again, even when target SDK is switched during a session. + +## [3.3.0] - 2024-02-28 + +### Added +- Embedded Linux support +- Apple tvOS support +- Android x86 and x86_64 support +- Runtime tests that load KTX 2.0 files + +### Changed +- Moved Editor scripts into namespace `KtxUnity.Editor` +- Updated binaries to version 1.2.1. + +### Fixed +- Code format in markdown files +- Apple iOS device and simulator SDK binaries are properly included/excluded, depending on target SDK. +- Compilation succeeds on non-supported platforms +- `System.EntryPointNotFoundException` for symbols `ktx_get_image_offset` and `ktx_get_image_size` on Windows. +- Using GraphicsFormatUsage (instead of the obsolete FormatUsage) in 2023.2 or newer. +- Crashes and undefined behavior caused by incorrect marshaling when using the IL2CPP scripting. + +## [3.2.2] - 2023-11-14 + +### Fixed +- Fixed CI failing on isolation tests because of the WebGL sub-package import. Now imports the package synchronously in batch mode. + +## [3.2.1] - 2023-11-06 + +### Changed +- Applied consistent code formatting. +- Updated to WebGL sub-packages from 1.0.0 to 1.0.1. + +## [3.2.0] - 2023-09-14 + +### Changed +- Updated binaries to version 1.1.1. +- Updated WebGL sub-packages to version 1.0.0. + +## [3.1.0] - 2023-08-25 + +### Added +- WebGL native libraries are now installed via sub-packages +- Full Apache 2.0 license text + +### Changed +- Extended support back to Unity 2020.3 LTS +- Unexposed `KtxUnity.Tests.PlaceholderEditorTests` + +### Removed +- WebGL native libraries +- Obsolete console error about downgrading package for certain Unity versions +- Native binaries don't contain etcdec anymore + +## [3.0.0] - 2023-03-29 + +### Added +- `TextureBase.Load...` overloads that accepts an explicit transcode target texture format + +### Changed +- [Breaking] Reduced public API to minimum requirement. +- Added missing XML documentation for remaining public API. +- Updated KTX-Software-Unity to [1.1.0](https://github.com/atteneder/KTX-Software-Unity/releases/tag/v1.1.0) + +### Removed +- Utility classes `TextureLoaderBase`, `TextureFileLoader` and `TextureUrlLoader` were moved to KtxUnityDemo project +- `TextureBase.LoadBytesRoutine` (was replaced by `LoadFromBytes` previously) + +## [2.2.3] - 2022-11-18 + +### Fixed +- WebGL build errors (unresolved symbols during linking) due to outdated native library + +## [2.2.2] - 2022-09-29 + +### Changed +- Marked `TextureBase.LoadBytesRoutine` obsolete in favor of `TextureBase.LoadFromBytes` + +### Fixed +- Made `TextureBase.LoadBytesRoutine` public again to preserve API compatibility + +## [2.2.1] - 2022-09-28 + +### Added +- Low-level API that gives finer control over the loading process (alternative to `TextureBase.LoadBytesRoutine`) +- `ManagedNativeArray` wrapper for efficient access of managed `byte[]` from C# Jobs +- Basis Universal texture (.basis) Editor import +- Support for loading any single image/layer/mipmap level of textures of any type (arrays, cubemaps, volumes) +- Support for discarding mipmap level chain (and import just one mipmap level) +- Support for importing Basis Universal texture types 2darray, 3d, video, cubemap (single images only at the moment) +- Many property getters on `KtxTexture` (e.g. `needsTranscoding`,`hasAlpha`,`isCubemap`) +- Experimental support for importing uncompressed KTX 2.0 textures (limited set of formats for now; #47) + +### Changed +- De-prioritized texture formats `RGBA4444` and `BGR565` to avoid incorrect channel usage or low quality. Transcoding to `RGBA32` instead. +- Bumped minimum required Unity version to 2019.4 LTS + +### Fixed +- Textures with alpha channel are shown blended (with checkerboard background) in the inspector now (`alphaIsTransparency` is enabled; #64) +- Avoid extra memcopy of input data by using `ManagedNativeArray` in `LoadFromStreamingAssets` and `LoadFromUrl` +- Improved texture format usage detection (linear vs. sRGB sampling) +- Loading of native library on Linux (thanks [@Blackclaws][Blackclaws] for #60) + +## [2.1.2] - 2022-04-14 + +### Fixed +- Fix undefined variable error when building project +- Compiler error due to C# 7.3 incompatible code + +## [2.1.1] - 2022-04-14 +Ported changes from 1.2.0 + +### Added +- Editor Import via `ScriptableImporter` (thanks @hybridherbst][hybridherbst] for #45) +- Error Codes (in `TextureResult.errorCode`) + +### Changed +- In release builds there's no console logging anymore (use the `errorCode` instead). In Debug builds and the Editor you still get detailed error messages. + +### Fixed +- Will not transcode textures with sizes that are not a multiple of four to incompatible DXT5 or BC7 formats anymore +- Re-compiled macOS native library in release mode (`MinSizeRel`; was `Debug`). Expect improved performance. + +## [2.0.1] - 2021-11-23 + +### Fixed +- Apple Silicon Unity Editor decoding + +## [2.0.0] - 2021-10-28 + +### Changed +- WebGL library is built with Emscripten 2.0.19 now +- Minimum required version is Unity 2021.2 + +## [1.3.2] - 2023-04-11 + +### Fixed +- Apple Silicon Unity Editor decoding + +## [1.3.1] - 2022-11-29 + +### Changed +- Marked `TextureBase.LoadBytesRoutine` obsolete in favor of `TextureBase.LoadFromBytes` + +### Fixed +- Made `TextureBase.LoadBytesRoutine` public again to preserve API compatibility + +## [1.3.0] - 2022-11-28 + +### Added +- Low-level API that gives finer control over the loading process (alternative to `TextureBase.LoadBytesRoutine`) +- `ManagedNativeArray` wrapper for efficient access of managed `byte[]` from C# Jobs +- Basis Universal texture (.basis) Editor import +- Support for loading any single image/layer/mipmap level of textures of any type (arrays, cubemaps, volumes) +- Support for discarding mipmap level chain (and import just one mipmap level) +- Support for importing Basis Universal texture types 2darray, 3d, video, cubemap (single images only at the moment) +- Many property getters on `KtxTexture` (e.g. `needsTranscoding`,`hasAlpha`,`isCubemap`) +- Experimental support for importing uncompressed KTX 2.0 textures (limited set of formats for now; #47) + +### Changed +- De-prioritized texture formats `RGBA4444` and `BGR565` to avoid incorrect channel usage or low quality. Transcoding to `RGBA32` instead. +- Bumped minimum required Unity version to 2019.4 LTS + +### Fixed +- Textures with alpha channel are shown blended (with checkerboard background) in the inspector now (`alphaIsTransparency` is enabled; #64) +- Avoid extra memcopy of input data by using `ManagedNativeArray` in `LoadFromStreamingAssets` and `LoadFromUrl` +- Improved texture format usage detection (linear vs. sRGB sampling) + +## [1.2.3] - 2022-04-14 + +### Fixed +- Fix undefined variable error when building project + +## [1.2.2] - 2022-04-14 + +### Fixed +- Compiler error due to C# 7.3 incompatible code + +## [1.2.1] - 2022-04-14 + +### Added +- Editor Import via `ScriptableImporter` (thanks @hybridherbst][hybridherbst] for #45) +- Error Codes (in `TextureResult.errorCode`) + +### Changed +- In release builds there's no console logging anymore (use the `errorCode` instead). In Debug builds and the Editor you still get detailed error messages. + +### Fixed +- Will not transcode textures with sizes that are not a multiple of four to incompatible DXT5 or BC7 formats anymore +- Re-compiled macOS native library in release mode (`MinSizeRel`; was `Debug`). Expect improved performance. + +## [1.1.2] - 2021-10-27 + +### Added +- Error message when users try to run KtxUnity 1.x Unity >=2021.2 combination targeting WebGL + +## [1.1.1] - 2021-07-16 + +### Changed +- Updated KTX-Software-Unity to [0.4.2](https://github.com/atteneder/KTX-Software-Unity/releases/tag/v0.4.2) (only the relevant iOS binaries) + +### Fixed +- Bitcode is now embed in all iOS binaries (fixes #37) + +## [1.1.0] - 2021-07-02 + +### Added +- Support for Lumin / Magic Leap +- Support for Apple Silicon on macOS via a universal library + +### Changed +- Updated KTX-Software-Unity to [0.4.1](https://github.com/atteneder/KTX-Software-Unity/releases/tag/v0.4.1) + +### Fixed +- Prevent crash during mipmap reverting on recent llvm/emscripten versions +- Not transcoding to ETC1/ETC2/BC1 if resolution is not a multiple of four +- Switched to data-model-independent types in C binding to avoid crashes on certain platforms + +## [1.0.0] - 2021-02-03 + +### Added +- Support for Universal Windows Platform (x64,x86,ARM,ARM64) + +### Changed +- Switched API to `async` calls that return a `TextureResult` directly (instead of onTextureLoaded event) +- Doesn't require a MonoBehaviour for running coroutines anymore +- Raised minimum required version to 2019.2 (the version that switched to scripting runtime version .NET 4.6) +- Updated KTX-Software-Unity native libs to [0.3.0](https://github.com/atteneder/KTX-Software-Unity/releases/tag/v0.3.0) + +## [0.9.1] - 2020-11-12 + +### Changed +- Updated KTX-Software-Unity native libs to [0.2.4](https://github.com/atteneder/KTX-Software-Unity/releases/tag/v0.2.4) + +### Fixed +- Added missing native functions (on Linux) + +## [0.9.0] - 2020-11-04 + +### Added +- Support for Universal Windows Platform (x64) +- Expressive error messages when loading unsupported KTX 1.0 or non-supercompressed KTX 2.0 file + +### Changed +- Updated KTX-Software-Unity native libs to [0.2.2](https://github.com/atteneder/KTX-Software-Unity/releases/tag/v0.2.2) + +### Fixed +- Added missing basis transcoding functions on Windows (fixes #21) +- UASTC mode with alpha channel + +## [0.8.2] - 2020-10-23 +- No changes. Bump release to trick OpenUPM to create package for 0.8.1 + +## [0.8.1] - 2020-10-23 + +### Fixed +- Removed annoying warning about `UnityPackage.meta` file + +## [0.8.0] - 2020-10-23 + +### Added +- Texture orientation is now exposed. This allows users to correct (=flip) them (fixes #18) +- Support for KTX specification 2.0 pr-draft2 (fixes #16) +- Support for Basis Universal UASTC supercompression mode (higher quality) + +### Changed +- Native binary libs are now provided by [KTX-Software-Unity 0.1.0](https://github.com/atteneder/KTX-Software-Unity/releases/tag/v0.1.0) +- The KTX specification changed (from ~draft20 to pr-draft2), thus older KTX files cannot be loaded anymore. +- Unsupported basis file texture types (non 2D Images) raise a proper error now +- Removed support for 32-bit Desktop platforms (Windows, Linux) + +## [0.7.0] - 2020-04-26 + +### Added +- Support for linear sampling +- Support for `ETC1_RGB` with sRGB sampling via `RGB_ETC2_SRGB` +- Support for `ETC2_EAC_R11` and `ETC2_EAC_RG11` (there's no interface yet to explicitly choose one- or two-channel textures) + +## [0.6.0] - 2020-03-01 + +### Added +- Support for mip-map levels + +### Changed +- Updated KTX library (now at KTX 2.0 specification draft 18) + +## [0.5.0] - 2020-02-22 + +### Added +- Support for Universal Windows Platform (not verified/tested myself) + +### Changed +- `TextureBase.LoadBytesRoutine` is public now to allow deeper integration + +### Fixed +- Ensured backwards compatibility with Unity 2018.2 + +## [0.4.0] - 2019-11-10 + +### Changed +- Renamed project to KtxUnity +- Using less memory by freeing up texture after GPU upload + +### Added +- Support for loading KTX 2.0 files with Basis Universal super-compression + +## [0.3.0] - 2019-06-30 + +### Added +- Thread support via Unity Job system +- Support for Android armeabi-v7a and x86 + +## [0.2.0] - 2019-06-25 + +### Added +- Support for Linux 32/64 bit + +## [0.1.0] - 2019-06-23 + +### Added +- Added support for Windows 32/64 bit +- Docs on how to use it + + +### Changed +- Restructured project to be a valid Unity package + +## [0.0.1] - 2019-06-21 + +### Added +- Changelog. All previous work was not versioned. + +[Blackclaws]: https://github.com/Blackclaws +[hybridherbst]: https://github.com/hybridherbst diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.unity.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/CHANGELOG.md.meta similarity index 62% rename from Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.unity.meta rename to Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/CHANGELOG.md.meta index 614e60e374a..ad926cc8622 100644 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.unity.meta +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/CHANGELOG.md.meta @@ -1,6 +1,6 @@ fileFormatVersion: 2 -guid: f27f307e08f2f4d83bca39e60e1cd476 -DefaultImporter: +guid: beaf7fcd7811f4ce1bdc032b1d3bcfb8 +TextScriptImporter: externalObjects: {} userData: assetBundleName: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/Images/ktx-logo.png b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/Images/ktx-logo.png new file mode 100644 index 00000000000..e31e6ec7362 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/Images/ktx-logo.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2ea8b9d805e54d82ecf0347c120d98137ca9285a3d11a1acf3cbcec3a28c9670 +size 7468 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/Original.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/Original.md new file mode 100644 index 00000000000..aa446d3521e --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/Original.md @@ -0,0 +1,14 @@ +# Original KTX/Basis Texture Unity Package + +This package's original identifier was `com.atteneder.ktx` (see [Unity Fork][fork] for details). You can still use/install it with that identifier. + +## Via [OpenUPM][OpenUPM] + +The recommended way to install is to download and open the [Installer Package](https://package-installer.glitch.me/v1/installer/OpenUPM/com.atteneder.ktx?registry=https%3A%2F%2Fpackage.openupm.com&scope=com.atteneder) + +It runs a script that installs *KTX/Basis Texture Unity Package* via the [OpenUPM][OpenUPM] [scoped registry](https://docs.unity3d.com/Manual/upm-scoped.html). + +Afterwards and further, optional packages are listed in the *Package Manager* (under *My Registries*) and can be installed and updated from there. + +[fork]: ./UpgradeGuides#unity-fork +[OpenUPM]: https://openupm.com/ diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/TableOfContents.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/TableOfContents.md new file mode 100644 index 00000000000..4db67436642 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/TableOfContents.md @@ -0,0 +1,9 @@ +* [KTX for Unity](./index.md) + * [Installation](./installation.md) + * [What's new](./whats-new.md) + * [Upgrade guide](./upgrade-guide.md) +* [Get Started](./get-started.md) +* [How To](./how-to.md) +* [Creating Textures](./creating-textures.md) +* [Known Limitations](./known-limitations.md) +* [Apple Privacy Manifest](apple-privacy-manifest.md) diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/apple-privacy-manifest.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/apple-privacy-manifest.md new file mode 100644 index 00000000000..ddcdd867545 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/apple-privacy-manifest.md @@ -0,0 +1,17 @@ +# Apple privacy manifest +To publish applications for iOS, iPadOS, tvOS, and visionOS platforms on the App Store, you must include a [privacy manifest file](https://developer.apple.com/documentation/bundleresources/privacy_manifest_files) in your application as per [Apple’s privacy policy](https://www.apple.com/legal/privacy/en-ww/). + +> [!NOTE] +> **Note**: +For information on creating a privacy manifest file to include in your application, refer to [Apple’s privacy manifest policy requirements](https://docs.unity3d.com/Manual/apple-privacy-manifest-policy.html). + +The PrivacyInfo.xcprivacy manifest file outlines the required information, ensuring transparency in accordance with user privacy practices. This file lists the [types of data](https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_data_use_in_privacy_manifests) that your Unity applications, third-party SDKs, packages, and plug-ins collect, and the reasons for using certain [required reason API](https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_use_of_required_reason_api) (Apple documentation) categories. Apple also requires that certain domains be declared as [tracking](https://developer.apple.com/app-store/user-privacy-and-data-use/) (Apple documentation); these domains might be blocked unless a user provides consent. +> [!WARNING] +> **Important**: If your privacy manifest doesn’t declare the use of the required reason API by you or third-party SDKs, the App Store might reject your application. Read more about the [required reason API](https://developer.apple.com/documentation/bundleresources/privacy_manifest_files/describing_use_of_required_reason_api) in Apple’s documentation. + +The Unity Cloud KTX package does not collect data or engage in any data practices requiring disclosure in a privacy manifest file. + +> [!NOTE] +> Note: The Unity Cloud KTX package is dependent on the following services. Refer to their manifest files for applicable data practices. +> +> * `com.unity.modules.unitywebrequest` diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/creating-textures.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/creating-textures.md new file mode 100644 index 00000000000..f92e18cce8d --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/creating-textures.md @@ -0,0 +1,40 @@ +# Creating Textures + +You can use the command line tools `toktx` (comes with [KTX-Software][ktxsoftware]) to create KTX™ v2.0 files and `basisu` (part of [Basis Universal][basisu]) to create .basis files. + +The default texture orientation of both of those tools (right-down) does not match Unity's orientation (right-up). To counter-act, you can provide a parameter to flip textures in the vertical axis (Y). This is recommended, if you use the textures in Unity only. The parameters are: + +- `--lower_left_maps_to_s0t0` for `toktx` +- `--y_flip` for `basisu` + +Example usage: + +```bash +# For KTX files: +# Create regular KTX file from an input image +toktx --bcmp regular.ktx2 input.png +# Create a y-flipped KTX file, fit for Unity out of the box +toktx --lower_left_maps_to_s0t0 --bcmp unity_flipped.ktx2 input.png + + +# For Basis files: +# Create regular basis file from an input image +basisu -output_file regular.basis input.png +# Create a y-flipped basis file, fit for Unity out of the box +basisu -y_flip -output_file unity_flipped.basis input.png +``` + +If changing the orientation of your texture files is not an option, you can correct it by applying it flipped at run-time (see [How To](./how-to.md)). + +## Trademarks + +*Unity* is a registered trademark of [Unity Technologies][unity]. + +Khronos® and the Khronos Group logo are registered trademarks of the [The Khronos Group Inc][khronos]. + +KTX™ and the KTX logo are trademarks of the [The Khronos Group Inc][khronos]. + +[basisu]: https://github.com/BinomialLLC/basis_universal +[khronos]: https://www.khronos.org +[ktxsoftware]: https://github.com/KhronosGroup/KTX-Software +[unity]: https://unity.com diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/get-started.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/get-started.md new file mode 100644 index 00000000000..d33b7e56b14 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/get-started.md @@ -0,0 +1,38 @@ +# Get started + +This section explains how to start using the *KTX for Unity* package. + +To use the *KTX for Unity* package, do the following: + +1. Verify project settings +2. Install the package +3. Follow the use case examples + +## Verify project settings + +To use the *KTX for Unity* package, you require the following: + +* A Unity Editor version of 2020.1 or later. In the Unity Hub, go to **Installs** > **Official releases** to find the latest Long Term Support version. + +## Install the package + +To install *KTX for Unity* on a new or existing Unity project, install `com.unity.cloud.ktx` package using the [installation instructions](./installation.md). + +## Follow the how to examples + +Follow this guide: + +* [How To](./how-to.md): This guide explains how to load [KTX™ 2.0][ktx] and [Basis Universal][basisu] texture files. + +## Trademarks + +*Unity* is a registered trademark of [Unity Technologies][unity]. + +Khronos® and the Khronos Group logo are registered trademarks of the [The Khronos Group Inc][khronos]. + +KTX™ and the KTX logo are trademarks of the [The Khronos Group Inc][khronos]. + +[basisu]: https://github.com/BinomialLLC/basis_universal +[khronos]: https://www.khronos.org +[ktx]: https://www.khronos.org/ktx/ +[unity]: https://unity.com diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/how-to.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/how-to.md new file mode 100644 index 00000000000..103925682a4 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/how-to.md @@ -0,0 +1,112 @@ + +# How To + +The API provides the loading classes [KtxTexture](xref:KtxUnity.KtxTexture) for [KTX™ 2.0][ktx] files and [BasisUniversalTexture](xref:KtxUnity.BasisUniversalTexture) for [Basis Universal][basisu] files, which both offer the following async loading methods: + +- [LoadFromUrl](xref:KtxUnity.TextureBase.LoadFromUrl*) for loading URLs (including file URLs starting with `file://`) +- [LoadFromStreamingAssets](xref:KtxUnity.TextureBase.LoadFromStreamingAssets*) for loading relative paths in the StreamingAssets folder +- [LoadFromBytes](xref:KtxUnity.TextureBase.LoadFromBytes*) for loading from memory + +## Loading Textures + +```C# +using KtxUnity; +… +async void Start() { + + // Create KTX texture instance + var texture = new KtxTexture(); + + // Linear color sampling. Needed for non-color value textures (e.g. normal maps) + bool linearColor = true; + + // Load file from Streaming Assets folder (relative path) + var result = await texture.LoadFromStreamingAssets("trout.ktx", linearColor); + + // Alternative: Load from URL + // var result = await texture.LoadFromUrl("https://myserver.com/trout.ktx", linearColor); + + // Alternative: Load from memory + // var result = await texture.LoadFromBytes(nativeArray, linearColor); + + if (result != null) { + // Use texture. For example, apply texture to a material + targetMaterial.mainTexture = result.texture; + + // Optional: Support arbitrary texture orientation by flipping the texture if necessary + var scale = targetMaterial.mainTextureScale; + scale.x = result.orientation.IsXFlipped() ? -1 : 1; + scale.y = result.orientation.IsYFlipped() ? -1 : 1; + targetMaterial.mainTextureScale = scale; + } +} +… +``` + +## Using as Sprite + +If you want to use the texture in a UI / Sprite context, this is how you create a Sprite with correct orientation: + +```C# +using KtxUnity; +… +async void Start() { + + // Create a basis universal texture instance + var texture = new BasisUniversalTexture(); + + // Load file from Streaming Assets folder + var result = await texture.LoadFromStreamingAssets("dachstein.basis"); + + if (result != null) { + // Calculate correct size + var pos = new Vector2(0,0); + var size = new Vector2(result.texture.width, result.texture.height); + + // Flip Sprite, if required + if(result.orientation.IsXFlipped()) { + pos.x = size.x; + size.x *= -1; + } + + if(result.orientation.IsYFlipped()) { + pos.y = size.y; + size.y *= -1; + } + + // Create a Sprite and assign it to the Image + GetComponent().sprite = Sprite.Create(result.texture, new Rect(pos, size), Vector2.zero); + + // Preserve aspect ratio: + // Flipping the sprite by making the size x or y negative (above) breaks Image's `Preserve Aspect` feature + // You can/have to calculate the RectTransform size yourself. Example: + + // Calculate correct size and assign it to the RectTransform + const float scale = 0.5f; // Set this to whatever size you need it - best make it a serialized class field + var rt = GetComponent(); + rt.sizeDelta = new Vector2(result.texture.width*scale, result.texture.height*scale); + } +} +… +``` + +> Note: You can still use the `Preserve Aspect` Image option, if you encode your KTX/Basis files with flipped Y axis (see [Creating Textures](./creating-textures.md) ) + +## Advanced + +Developers who want to create advanced loading code should look into classes [KtxTexture](xref:KtxUnity.KtxTexture), [BasisUniversalTexture](xref:KtxUnity.BasisUniversalTexture) and [TextureBase](xref:KtxUnity.TextureBase) directly. + +When loading many textures at once, using the low-level API to get finer control over the loading process can yield great performance gains. Have a look at [Open](xref:KtxUnity.TextureBase.Open*), [LoadTexture2D](xref:KtxUnity.TextureBase.LoadTexture2D*) and [Dispose](xref:KtxUnity.TextureBase.Dispose) for details. + +## Trademarks + +*Unity* is a registered trademark of [Unity Technologies][unity]. + +Khronos® and the Khronos Group logo are registered trademarks of the [The Khronos Group Inc][khronos]. + +KTX™ and the KTX logo are trademarks of the [The Khronos Group Inc][khronos]. + +[basisu]: https://github.com/BinomialLLC/basis_universal +[khronos]: https://www.khronos.org +[ktx]: https://www.khronos.org/ktx/ +[unity]: https://unity.com diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/index.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/index.md new file mode 100644 index 00000000000..4bdfe6074ec --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/index.md @@ -0,0 +1,36 @@ +# KTX for Unity + +[![KTX Logo](Images/ktx-logo.png)][KTX] + +Unity package that allows users to load [KTX™ 2.0][ktx] or [Basis Universal][basisu] texture files. + +> [!NOTE] +> This package can be used in combination with the [com.unity.cloud.gltfast package][glTFast]. By doing so, glTF™ files containing [KTX 2.0][KTXSpec] texture files will be loaded. Only installing the package is required, nothing else. + +## Features + +Supported features include: + +- Run-time loading. +- Editor (design-time) importing. +- [KTX 2.0][KTXSpec] (.ktx2) and [Basis Universal][basisu] (.basis) files. +- Basis Universal super compression modes + - ETC1s (low quality mode) + - UASTC (high quality mode) +- ZStd compression. +- Texture orientation. + +## Trademarks + +*Unity* is a registered trademark of [Unity Technologies][unity]. + +Khronos® and the Khronos Group logo are registered trademarks of the [The Khronos Group Inc][khronos]. + +KTX™ and the KTX logo are trademarks of the [The Khronos Group Inc][khronos]. + +[basisu]: https://github.com/BinomialLLC/basis_universal +[glTFast]: https://github.com/Unity-Technologies/glTFast +[khronos]: https://www.khronos.org +[KTX]: https://www.khronos.org/ktx/ +[KTXSpec]: https://registry.khronos.org/KTX/specs/2.0/ktxspec.v2.html +[unity]: https://unity.com diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/installation.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/installation.md new file mode 100644 index 00000000000..ba8d368f18d --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/installation.md @@ -0,0 +1,47 @@ +# Installation + +Before you install the package, make sure you meet the [system requirement](#system-requirement) and [prerequisites](#prerequisites). + +## Install the *KTX for Unity* package using the Unity Package Manager + +To install *KTX for Unity* package, follow these steps: + +In your Unity project, go to Windows > Package Manager. +On the status bar, select the Add (+) button. +From the Add menu, select Add + package by name. Name and Version fields appear. +In the Name field, enter `com.unity.cloud.ktx`. +Select Add. +The Editor installs the latest available version of the package and any dependent packages. + +## System Requirement + +*KTX for Unity* supports the following platforms: + +- WebGL +- iOS (arm64 and armv7a) +- tvOS +- visionOS +- Android +- Windows (x64 and ARM64) +- Universal Windows Platform (x64, x86, ARM, ARM64) +- MacOS Universal (Apple Silicon and Intel) +- Linux (64 bit) +- Lumin / Magic Leap +- Embedded Linux + +## Prerequisites + +To use the package, you require the following: + +* A Unity version of 2020.1 or later. In the Unity Hub, go to **Installs** > **Official releases** to find the latest Long Term Support version. + +## Trademarks + +*Unity* is a registered trademark of [Unity Technologies][unity]. + +Khronos® and the Khronos Group logo are registered trademarks of the [The Khronos Group Inc][khronos]. + +KTX™ and the KTX logo are trademarks of the [The Khronos Group Inc][khronos]. + +[khronos]: https://www.khronos.org +[unity]: https://unity.com diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/known-limitations.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/known-limitations.md new file mode 100644 index 00000000000..369bf201435 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/known-limitations.md @@ -0,0 +1,18 @@ +# Known limitations + +At the moment known shortcomings: + +- Only limited support for KTX™ with non-supercompressed formats (like uncompressed, DXT, BC7, PVRTC, ETC, … ) +- Only 2D image texture types (no cube-map, videos, 3D texture, 2D arrays) +- Only RGB/RGBA is tested (RG,R untested) + +## Trademarks + +*Unity* is a registered trademark of [Unity Technologies][unity]. + +Khronos® and the Khronos Group logo are registered trademarks of the [The Khronos Group Inc][khronos]. + +KTX™ and the KTX logo are trademarks of the [The Khronos Group Inc][khronos]. + +[khronos]: https://www.khronos.org +[unity]: https://unity.com diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/upgrade-guide.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/upgrade-guide.md new file mode 100644 index 00000000000..9bcbba52e66 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/upgrade-guide.md @@ -0,0 +1,41 @@ +# Upgrade + +These guides will help you upgrade your project to use the latest version of *KTX for Unity*. If you still encounter problems, help us improving this guide and *KTX for Unity* in general by reaching out or by raising an issue. + +## Unity Fork + +With the release of version 3.2.0-pre.1 the package name and identifier were changed to *KTX for Unity* (`com.unity.cloud.ktx`) for the following reasons: + +- Better integration into Unity internal development processes (including quality assurance and support) +- Distribution via the Unity Package Manager (no scoped libraries required anymore) + +For now, both the Unity variant and the original version will receive updates. + +### Transition to *KTX for Unity* + +The C# namespaces are identical between the variants, so all you need to do is: + +- Removed original *KTX/Basis Texture Unity Package* (with package identifier `com.atteneder.ktx`). +- Add *KTX for Unity* (`com.unity.cloud.ktx`). +- Update assembly definition references (if your project had any). +- Update any dependencies in your packages manifest (if your package had any) + +### Keep using the original KTX/Basis Texture Unity Package + +The original *KTX/Basis Texture Unity Package* (`com.atteneder.ktx`) will still receive identical updates for now. You may choose to continue using it. + +If you've installed the packages via the installer script (i.e. via [OpenUPM][OpenUPM] scoped registry - the recommended way), you don't need to change anything. You'll receive updates as usual. + +See [Original *KTX/Basis Texture Unity Package*](./Original.md) for instructions to install the original version from scratch. + +## Trademarks + +*Unity* is a registered trademark of [Unity Technologies][unity]. + +Khronos® and the Khronos Group logo are registered trademarks of the [The Khronos Group Inc][khronos]. + +KTX™ and the KTX logo are trademarks of the [The Khronos Group Inc][khronos]. + +[khronos]: https://www.khronos.org +[OpenUPM]: https://openupm.com/ +[unity]: https://unity.com diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/whats-new.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/whats-new.md new file mode 100644 index 00000000000..8975cc123b2 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Documentation~/whats-new.md @@ -0,0 +1,14 @@ +# What's new + +In future releases, this section will provide information about additions and updates to this package. + +## Trademarks + +*Unity* is a registered trademark of [Unity Technologies][unity]. + +Khronos® and the Khronos Group logo are registered trademarks of the [The Khronos Group Inc][khronos]. + +KTX™ and the KTX logo are trademarks of the [The Khronos Group Inc][khronos]. + +[khronos]: https://www.khronos.org +[unity]: https://unity.com diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor.meta similarity index 77% rename from Explorer/Assets/DCL/WebRequests/WebContentSizes.meta rename to Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor.meta index bcfec72e220..ad159549bc7 100644 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes.meta +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 74ea680690454eaaac75652d16da0256 +guid: 8638cd6d9aa92478e82b15d167969686 folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts.meta similarity index 77% rename from Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy.meta rename to Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts.meta index be966c1c551..ff781262592 100644 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes/Lazy.meta +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 04de4d0f31a84cd1ac2cc5edbeacfe05 +guid: 344f9a9c064344851aa1cfba278cc352 folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AssemblyInfo.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AssemblyInfo.cs new file mode 100644 index 00000000000..c4fa9858547 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AssemblyInfo.cs @@ -0,0 +1,6 @@ +// SPDX-FileCopyrightText: 2024 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + +using System.Runtime.CompilerServices; + +[assembly: InternalsVisibleTo("Ktx.Editor.Tests")] diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AssemblyInfo.cs.meta similarity index 83% rename from Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.cs.meta rename to Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AssemblyInfo.cs.meta index 14d89bcf15d..fa807e722c2 100644 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground/WebContentsSizesPlayground.cs.meta +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AssemblyInfo.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 4976711299f946a0b306ab626cc9f0c3 +guid: 88bb69cd2c20347468b2f6ad1963c35d MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AsyncHelpers.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AsyncHelpers.cs new file mode 100644 index 00000000000..0014d87a125 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AsyncHelpers.cs @@ -0,0 +1,108 @@ +// SPDX-FileCopyrightText: 2024 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + +using System; +using System.Collections.Generic; +using System.Threading; +using System.Threading.Tasks; + +namespace KtxUnity.Editor +{ + // from glTFast : AsyncHelpers + static class AsyncHelpers + { + /// + /// Executes an async Task<T> method which has a T return type synchronously + /// + /// Return Type + /// Task<T> method to execute + /// + public static T RunSync(Func> task) + { + var oldContext = SynchronizationContext.Current; + var sync = new ExclusiveSynchronizationContext(); + SynchronizationContext.SetSynchronizationContext(sync); + var ret = default(T); + // ReSharper disable once AsyncVoidLambda + sync.Post(async _ => + { + try + { + ret = await task(); + } + catch (Exception e) + { + sync.InnerException = e; + throw; + } + finally + { + sync.EndMessageLoop(); + } + }, null); + sync.BeginMessageLoop(); + SynchronizationContext.SetSynchronizationContext(oldContext); + return ret; + } + + class ExclusiveSynchronizationContext : SynchronizationContext + { + bool m_Done; + public Exception InnerException { get; set; } + readonly AutoResetEvent m_WorkItemsWaiting = new AutoResetEvent(false); + readonly Queue> m_Items = + new Queue>(); + + public override void Send(SendOrPostCallback d, object state) + { + throw new NotSupportedException("We cannot send to our same thread"); + } + + public override void Post(SendOrPostCallback d, object state) + { + lock (m_Items) + { + m_Items.Enqueue(Tuple.Create(d, state)); + } + m_WorkItemsWaiting.Set(); + } + + public void EndMessageLoop() + { + Post(_ => m_Done = true, null); + } + + public void BeginMessageLoop() + { + while (!m_Done) + { + Tuple task = null; + lock (m_Items) + { + if (m_Items.Count > 0) + { + task = m_Items.Dequeue(); + } + } + if (task != null) + { + task.Item1(task.Item2); + if (InnerException != null) // the method threw an exception + { + throw new AggregateException("AsyncHelpers.Run method threw an exception.", InnerException); + } + } + else + { + m_WorkItemsWaiting.WaitOne(); + } + } + } + + public override SynchronizationContext CreateCopy() + { + return this; + } + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AsyncHelpers.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AsyncHelpers.cs.meta new file mode 100644 index 00000000000..088c459c564 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/AsyncHelpers.cs.meta @@ -0,0 +1,3 @@ +fileFormatVersion: 2 +guid: 8c3868e4c6034a098277c8e7eadf2b63 +timeCreated: 1708613295 \ No newline at end of file diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BaseImporter.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BaseImporter.cs new file mode 100644 index 00000000000..25644517315 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BaseImporter.cs @@ -0,0 +1,79 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + +using System; +using System.IO; +using System.Threading.Tasks; +using Unity.Collections; +using UnityEngine; +using UnityEngine.Profiling; +#if UNITY_2020_2_OR_NEWER +using UnityEditor.AssetImporters; +#else +using UnityEditor.Experimental.AssetImporters; +#endif + +namespace KtxUnity.Editor +{ + abstract class TextureImporter : ScriptedImporter + { + + /// + /// Texture array layer to import. + /// + public uint layer; + + /// + /// Cubemap face or 3D/volume texture slice to import. + /// + public uint faceSlice; + + /// + /// Lowest mipmap level to import (where 0 is the highest resolution). + /// Lower mipmap levels (of higher resolution) are being discarded. + /// Useful to limit texture resolution. + /// + public uint levelLowerLimit; + + /// + /// If true, a mipmap chain (if present) is imported. + /// + public bool importLevelChain = true; + + /// + /// If true, texture will be sampled + /// in linear color space (sRGB otherwise) + /// + public bool linear; + + // ReSharper disable once NotAccessedField.Local + [SerializeField] + [HideInInspector] + string[] reportItems; + + public override void OnImportAsset(AssetImportContext ctx) + { + Profiler.BeginSample("Import Texture"); + var result = LoadTexture(); + + if (result.errorCode == ErrorCode.Success) + { + result.texture.name = name; + result.texture.alphaIsTransparency = true; + ctx.AddObjectToAsset("result", result.texture); + ctx.SetMainObject(result.texture); + reportItems = new string[] { }; + } + else + { + var errorMessage = ErrorMessage.GetErrorMessage(result.errorCode); + reportItems = new[] { errorMessage }; + Debug.LogError($"Could not load texture file at {assetPath}: {errorMessage}", this); + } + + Profiler.EndSample(); + } + + protected abstract TextureResult LoadTexture(); + } +} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/IWebContentSizes.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BaseImporter.cs.meta similarity index 83% rename from Explorer/Assets/DCL/WebRequests/WebContentSizes/IWebContentSizes.cs.meta rename to Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BaseImporter.cs.meta index 0f4a98db100..cc04f43176f 100644 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/IWebContentSizes.cs.meta +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BaseImporter.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 6e2064dddd1b4f4d83fdd20b690310f1 +guid: c582f5e23e864468c9dd71f9509b7cd6 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BasisImporter.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BasisImporter.cs new file mode 100644 index 00000000000..78ae30bad03 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BasisImporter.cs @@ -0,0 +1,42 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +using System; +using System.IO; +using UnityEngine; +using UnityEngine.Profiling; +#if UNITY_2020_2_OR_NEWER +using UnityEditor.AssetImporters; +#else +using UnityEditor.Experimental.AssetImporters; +#endif + +namespace KtxUnity.Editor +{ + [ScriptedImporter(0, new[] { ".basis" })] + class BasisImporter : TextureImporter + { + protected override TextureResult LoadTexture() + { + Profiler.BeginSample("LoadTexture"); + var texture = new BasisUniversalTexture(); + var result = AsyncHelpers.RunSync(() => + { + using (var alloc = new ManagedNativeArray(File.ReadAllBytes(assetPath))) + { + return texture.LoadFromBytesInternal( + alloc.nativeArray, + linear, + layer, + faceSlice, + levelLowerLimit, + importLevelChain + ); + } + }); + Profiler.EndSample(); + return result; + } + } +} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/ContentLengthBasedWebContentSizes.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BasisImporter.cs.meta similarity index 83% rename from Explorer/Assets/DCL/WebRequests/WebContentSizes/ContentLengthBasedWebContentSizes.cs.meta rename to Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BasisImporter.cs.meta index 6730b6edf96..d384593cdc4 100644 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/ContentLengthBasedWebContentSizes.cs.meta +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BasisImporter.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 6b5aa7caefbb4a1481475ea10a8cec3a +guid: 4fdb2bc2ad4434491b0c7dcf7af270d1 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BuildPreProcessor.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BuildPreProcessor.cs new file mode 100644 index 00000000000..448e225437e --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BuildPreProcessor.cs @@ -0,0 +1,157 @@ +// SPDX-FileCopyrightText: 2024 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + +#if UNITY_2023_3_OR_NEWER || UNITY_2022_3 +#define VISION_OS_SUPPORTED +#endif + +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +using UnityEngine; +using UnityEditor; +using UnityEditor.Build; +using UnityEditor.Build.Reporting; + +namespace KtxUnity.Editor +{ + class BuildPreProcessor : IPreprocessBuildWithReport + { + public const string packagePath = "Packages/com.unity.cloud.ktx/Runtime/Plugins/"; + + internal static readonly Dictionary webAssemblyLibraries = new Dictionary() + { + // Database of WebAssembly library files within folder `Runtime/Plugins/WebGL` + [new GUID("143eb4e0158994750a74465b1c68a52b")] = 2020, // 2020/libktx_read.bc + [new GUID("d5d7736ff60a64272adca7a7c3635175")] = 2020, // 2020/libktx_unity.bc + [new GUID("c2217daa2f255429fac9f7ad37ededb5")] = 2020, // 2020/libobj_basisu_cbind.bc + [new GUID("df97b0e93a9ce4dfea9b19bb84c197aa")] = 2021, // 2021/libktx_read.a + [new GUID("ad44f70cce67349758a1f872354c25be")] = 2021, // 2021/libktx_unity.a + [new GUID("c3d638c4775624a4aa8a0124da084d8c")] = 2021, // 2021/libobj_basisu_cbind.a + [new GUID("1903498fc70cf40f698bc7cb3f3b616f")] = 2022, // 2022/libktx_read.a + [new GUID("39f63d50e71334f7886493189c281dd9")] = 2022, // 2022/libktx_unity.a + [new GUID("56a5eafddecc942128d8c15652750b74")] = 2022, // 2022/libobj_basisu_cbind.a + [new GUID("064f9fdd6ee9346269b838d6b768b3cc")] = 2023, // 2023/libktx_read.a + [new GUID("b8faaa868093c46ddab6e9538d1625e6")] = 2023, // 2023/libktx_unity.a + [new GUID("22f5fcc807c2544dda814ef9d61f68ad")] = 2023, // 2023/libobj_basisu_cbind.a + }; + + public int callbackOrder => 0; + + void IPreprocessBuildWithReport.OnPreprocessBuild(BuildReport report) + { + SetRuntimePluginCopyDelegate(report.summary.platform); + } + + static void SetRuntimePluginCopyDelegate(BuildTarget platform) + { + var allPlugins = PluginImporter.GetImporters(platform); + foreach (var plugin in allPlugins) + { + if (plugin.isNativePlugin + && plugin.assetPath.StartsWith(packagePath) + ) + { + switch (platform) + { + case BuildTarget.iOS: + case BuildTarget.tvOS: +#if VISION_OS_SUPPORTED + case BuildTarget.VisionOS: +#endif + plugin.SetIncludeInBuildDelegate(IncludeAppleLibraryInBuild); + break; + case BuildTarget.WebGL: + if (webAssemblyLibraries.Keys.Any(libGuid => libGuid == AssetDatabase.GUIDFromAssetPath(plugin.assetPath))) + { + plugin.SetIncludeInBuildDelegate(IncludeWebLibraryInBuild); + } + break; + } + } + } + } + + static bool IsSimulatorBuild(BuildTarget platformGroup) + { + switch (platformGroup) + { + case BuildTarget.iOS: + return PlayerSettings.iOS.sdkVersion == iOSSdkVersion.SimulatorSDK; + case BuildTarget.tvOS: + return PlayerSettings.tvOS.sdkVersion == tvOSSdkVersion.Simulator; +#if VISION_OS_SUPPORTED + case BuildTarget.VisionOS: + return PlayerSettings.VisionOS.sdkVersion == VisionOSSdkVersion.Simulator; +#endif + } + + return false; + } + + static bool IncludeAppleLibraryInBuild(string path) + { + var isSimulatorLibrary = IsAppleSimulatorLibrary(path); + var isSimulatorBuild = IsSimulatorBuild(EditorUserBuildSettings.activeBuildTarget); + return isSimulatorLibrary == isSimulatorBuild; + } + + static bool IncludeWebLibraryInBuild(string path) + { + return IsWebAssemblyCompatible(path); + } + + public static bool IsAppleSimulatorLibrary(string assetPath) + { + var parent = new DirectoryInfo(assetPath).Parent; + + switch (parent?.Name) + { + case "Simulator": + return true; + case "Device": + return false; + default: + throw new InvalidDataException( + $@"Could not determine SDK type of library ""{assetPath}"". " + + @"Apple iOS/tvOS/visionOS native libraries have to be placed in a folder named ""Device"" " + + @"or ""Simulator"" for implicit SDK type detection." + ); + } + } + + static bool IsWebAssemblyCompatible(string assetPath) + { + var unityVersion = new UnityVersion(Application.unityVersion); + + var pluginGuid = AssetDatabase.GUIDFromAssetPath(assetPath); + + return IsWebAssemblyCompatible(pluginGuid, unityVersion); + } + + public static bool IsWebAssemblyCompatible(GUID pluginGuid, UnityVersion unityVersion) + { + var wasm2021 = new UnityVersion("2021.2"); + var wasm2022 = new UnityVersion("2022.2"); + var wasm2023 = new UnityVersion("2023.2.0a17"); + + if (webAssemblyLibraries.TryGetValue(pluginGuid, out var majorVersion)) + { + switch (majorVersion) + { + case 2020: + return unityVersion < wasm2021; + case 2021: + return unityVersion >= wasm2021 && unityVersion < wasm2022; + case 2022: + return unityVersion >= wasm2022 && unityVersion < wasm2023; + case 2023: + return unityVersion >= wasm2023; + } + } + + throw new InvalidDataException($"Unknown WebAssembly library at {AssetDatabase.GUIDToAssetPath(pluginGuid)}."); + } + } +} diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/RangeBasedWebContentSizes.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BuildPreProcessor.cs.meta similarity index 83% rename from Explorer/Assets/DCL/WebRequests/WebContentSizes/RangeBasedWebContentSizes.cs.meta rename to Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BuildPreProcessor.cs.meta index 742e4a102b9..9e609ecad12 100644 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/RangeBasedWebContentSizes.cs.meta +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/BuildPreProcessor.cs.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 96715773d3d1417db99694ad73f420d1 +guid: 0843a48c7e4d248a4853bcc7dd79a8c7 MonoImporter: externalObjects: {} serializedVersion: 2 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/Ktx.Editor.asmdef b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/Ktx.Editor.asmdef new file mode 100644 index 00000000000..837f7a8bad4 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/Ktx.Editor.asmdef @@ -0,0 +1,18 @@ +{ + "name": "Ktx.Editor", + "rootNamespace": "KtxUnity.Editor", + "references": [ + "GUID:3d354272d3f2f4c3387dbccbaebd0f60" + ], + "includePlatforms": [ + "Editor" + ], + "excludePlatforms": [], + "allowUnsafeCode": false, + "overrideReferences": false, + "precompiledReferences": [], + "autoReferenced": false, + "defineConstraints": [], + "versionDefines": [], + "noEngineReferences": false +} \ No newline at end of file diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/Ktx.Editor.asmdef.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/Ktx.Editor.asmdef.meta new file mode 100644 index 00000000000..2f67716c5e6 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/Ktx.Editor.asmdef.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 9e5fc1c03a36d4cf9b9ac7232e75f9cd +AssemblyDefinitionImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporter.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporter.cs new file mode 100644 index 00000000000..ac4970850c9 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporter.cs @@ -0,0 +1,41 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + +using System; +using System.IO; +using UnityEngine; +using UnityEngine.Profiling; +#if UNITY_2020_2_OR_NEWER +using UnityEditor.AssetImporters; +#else +using UnityEditor.Experimental.AssetImporters; +#endif + +namespace KtxUnity.Editor +{ + [ScriptedImporter(0, new[] { ".ktx2" })] + class KtxImporter : TextureImporter + { + protected override TextureResult LoadTexture() + { + Profiler.BeginSample("LoadTexture"); + var texture = new KtxTexture(); + var result = AsyncHelpers.RunSync(() => + { + using (var alloc = new ManagedNativeArray(File.ReadAllBytes(assetPath))) + { + return texture.LoadFromBytesInternal( + alloc.nativeArray, + linear, + layer, + faceSlice, + levelLowerLimit, + importLevelChain + ); + } + }); + Profiler.EndSample(); + return result; + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporter.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporter.cs.meta new file mode 100644 index 00000000000..60718afaa6c --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporter.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 02f36c64c6584f14d98cf6b2a30507bc +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporterEditor.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporterEditor.cs new file mode 100644 index 00000000000..aa44b71b166 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporterEditor.cs @@ -0,0 +1,38 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +using UnityEditor; +#if UNITY_2020_2_OR_NEWER +using UnityEditor.AssetImporters; +#else +using UnityEditor.Experimental.AssetImporters; +#endif + +namespace KtxUnity.Editor +{ + [CustomEditor(typeof(KtxImporter))] + class KtxImporterEditor : ScriptedImporterEditor + { + SerializedProperty m_ReportItems; + + public override void OnEnable() + { + base.OnEnable(); + m_ReportItems = serializedObject.FindProperty("reportItems"); + } + + public override void OnInspectorGUI() + { + DrawDefaultInspector(); + + var reportItemCount = m_ReportItems.arraySize; + for (int i = 0; i < reportItemCount; i++) + { + EditorGUILayout.HelpBox(m_ReportItems.GetArrayElementAtIndex(i).stringValue, MessageType.Error); + } + + ApplyRevertGUI(); + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporterEditor.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporterEditor.cs.meta new file mode 100644 index 00000000000..926b07a26f5 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/KtxImporterEditor.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 7a9fc553fcfe3f8478bb969255a5ee99 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/SubPackage.meta similarity index 77% rename from Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes.meta rename to Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/SubPackage.meta index a7e44acf166..c04bb981e3b 100644 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Sizes.meta +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/SubPackage.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 71720795bb8f458b9c14892894fb65bf +guid: ecbe7019f8cb87d4187e3f145319bc54 folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/SubPackage/SubPackageRemover.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/SubPackage/SubPackageRemover.cs new file mode 100644 index 00000000000..7981890ee5c --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/SubPackage/SubPackageRemover.cs @@ -0,0 +1,152 @@ +// SPDX-FileCopyrightText: 2024 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text.RegularExpressions; +using System.Threading; +using System.Threading.Tasks; +using UnityEditor; +using UnityEditor.PackageManager; +using UnityEngine; +using UnityEngine.Assertions; + +using PackageInfo = UnityEditor.PackageManager.PackageInfo; + +namespace SubPackage +{ + static class SubPackageRemover + { + const string k_PackageName = "KTX for Unity"; + const string k_DialogTitle = "Removing Obsolete Packages"; + const string k_CleanupRegex = @"^com\.unity\.cloud\.ktx\.webgl-.*$"; + + static readonly string k_DialogText = $"Obsolete packages where found! Those were needed by previous versions of, and are now in conflict with {k_PackageName}. They will be removed now."; + static readonly string k_ErrorMessage = $"Error removing {k_PackageName} WebGL sub-packages."; + + [InitializeOnLoadMethod] + static async Task TryRemoveObsoleteSubPackagesAsync() + { +#if UNITY_2020 + if (!string.IsNullOrEmpty(Environment.GetEnvironmentVariable("DISABLE_SUB_PACKAGE_LOAD"))) + { + Debug.Log($"{k_PackageName} WebGL sub-package removal: Skipped due to environment variable DISABLE_SUB_PACKAGE_LOAD."); + return; + } +#endif + try + { + var installedPackages = await GetAllInstalledPackagesAsync(); + var subPackages = GetSubPackages(installedPackages); + + if (subPackages.Count > 0) + { + DisplayDialog(); + + var packagesToRemove = subPackages + .Select(p => p.name); + + await RemovePackagesAsync(packagesToRemove); + } + } + catch (Exception e) + { + // Explicit logging is required to avoid silent failures due to this task + // being triggered as fire and forget. + Debug.LogException(e); + } + } + + static async Task RemovePackagesAsync(IEnumerable remove) + { +#if UNITY_2021_2_OR_NEWER + await AddAndRemoveAsync(remove.ToArray()); +#else + foreach (var package in remove) + { + await RemoveAsync(package); + } +#endif + } + +#if UNITY_2021_2_OR_NEWER + static async Task AddAndRemoveAsync(string[] remove) + { + var result = Client.AddAndRemove(new string[] {}, remove); + + while (!result.IsCompleted) + await Yield(); + + if (result.Status != StatusCode.Success) + Debug.LogError(result.Error.message); + } +#else + + static async Task RemoveAsync(string package, double timeout = 60) + { + var startTime = EditorApplication.timeSinceStartup; + var result = Client.Remove(package); + + while (!result.IsCompleted && EditorApplication.timeSinceStartup - startTime <= timeout) + { + await Yield(); + } + + if (!result.IsCompleted || result.Status != StatusCode.Success) + { + Debug.LogError(k_ErrorMessage); + + if (result.Status != StatusCode.Success) + { + Debug.LogError(result.Error.message); + } + } + } +#endif + + static async Task> GetAllInstalledPackagesAsync(double timeout = 60) + { + var startTime = EditorApplication.timeSinceStartup; + var request = Client.List(offlineMode: true, includeIndirectDependencies: false); + + while (!request.IsCompleted && EditorApplication.timeSinceStartup - startTime <= timeout) + { + await Yield(); + } + + if (!request.IsCompleted) + { + throw new TimeoutException(k_ErrorMessage); + } + Assert.AreEqual(StatusCode.Success, request.Status, $"{k_ErrorMessage}. Failed fetching installed packages."); + + return request.Result.ToList(); + } + + static List GetSubPackages(IEnumerable installedPackages) + { + var regex = new Regex(k_CleanupRegex, RegexOptions.CultureInvariant, TimeSpan.FromMinutes(1)); + + return installedPackages + .Where(package => regex.IsMatch(package.name)) + .ToList(); + } + + static void DisplayDialog() + { + if (Application.isBatchMode) + return; + + EditorUtility.DisplayDialog(k_DialogTitle, k_DialogText, "Ok"); + } + + static async Task Yield() + { + if (Application.isBatchMode) + Thread.Sleep(10); + else + await Task.Yield(); + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/SubPackage/SubPackageRemover.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/SubPackage/SubPackageRemover.cs.meta new file mode 100644 index 00000000000..9450e275343 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/SubPackage/SubPackageRemover.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: c7c40ab18781d4c5eb835802b073a67c +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/UnityVersion.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/UnityVersion.cs new file mode 100644 index 00000000000..3213e4b9e77 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/UnityVersion.cs @@ -0,0 +1,136 @@ +// SPDX-FileCopyrightText: 2024 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + +using System; +using System.Text.RegularExpressions; +using UnityEngine; + +namespace KtxUnity.Editor +{ + + readonly struct UnityVersion : IComparable + { + public readonly int Major; + public readonly int Minor; + public readonly int Patch; + public readonly char Type; + public readonly int Sequence; + + + const string k_Pattern = @"^(?\d{1,10})(\.(?\d{1,10}))?(\.(?\d{1,10}))?(?[abf])?(?\d{1,10})?"; + + static readonly Regex k_Regex = new Regex(k_Pattern, RegexOptions.CultureInvariant, TimeSpan.FromMinutes(1)); + + public UnityVersion(string version) + { + var match = k_Regex.Match(version); + + if (!match.Success) + throw new InvalidOperationException($"Failed to parse semantic version {version}"); + + Major = int.Parse(match.Groups["major"].Value); + var minorGroup = match.Groups["minor"]; + Minor = minorGroup.Success + ? int.Parse(minorGroup.Value) + : 0; + var patchGroup = match.Groups["patch"]; + Patch = patchGroup.Success + ? int.Parse(patchGroup.Value) + : 0; + + var typeGroup = match.Groups["type"]; + Type = typeGroup.Success + ? typeGroup.Value[0] + : 'f'; + + var sequenceGroup = match.Groups["sequence"]; + Sequence = sequenceGroup.Success + ? int.Parse(sequenceGroup.Value) + : 1; + } + + public override string ToString() + { + return $"{Major}.{Minor}.{Patch}{Type}{Sequence}"; + } + + public int CompareTo(UnityVersion other) + { + if (Major != other.Major) + { + return Major.CompareTo(other.Major); + } + + if (Minor != other.Minor) + { + return Minor.CompareTo(other.Minor); + } + + if (Patch != other.Patch) + { + return Patch.CompareTo(other.Patch); + } + + if (Type != other.Type) + { + return Type.CompareTo(other.Type); + } + + return Sequence.CompareTo(other.Sequence); + } + + public static bool operator <(UnityVersion left, UnityVersion right) + { + return left.CompareTo(right) < 0; + } + + public static bool operator >(UnityVersion left, UnityVersion right) + { + return left.CompareTo(right) > 0; + } + + public static bool operator <=(UnityVersion left, UnityVersion right) + { + return left.CompareTo(right) <= 0; + } + + public static bool operator >=(UnityVersion left, UnityVersion right) + { + return left.CompareTo(right) >= 0; + } + + public static bool operator ==(UnityVersion left, UnityVersion right) + { + return left.CompareTo(right) == 0; + } + + public static bool operator !=(UnityVersion left, UnityVersion right) + { + return left.CompareTo(right) != 0; + } + + public override bool Equals(object obj) + { + if (obj is UnityVersion other) + { + return CompareTo(other) == 0; + } + + return false; + } + + public override int GetHashCode() + { + unchecked + { + var hash = 17; + hash = hash * 23 + Major.GetHashCode(); + hash = hash * 23 + Minor.GetHashCode(); + hash = hash * 23 + Patch.GetHashCode(); + hash = hash * 23 + Type.GetHashCode(); + hash = hash * 23 + Sequence.GetHashCode(); + return hash; + } + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/UnityVersion.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/UnityVersion.cs.meta new file mode 100644 index 00000000000..cfabb65c644 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Editor/Scripts/UnityVersion.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 2929dc309a6544dce8574a525d726a72 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/LICENSE.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/LICENSE.md new file mode 100644 index 00000000000..f0feff7555d --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/LICENSE.md @@ -0,0 +1,190 @@ +KTX for Unity copyright © 2023 Unity Technologies and the KTX for Unity authors + +Licensed under the Apache License, Version 2.0 (the "License"); you may not +use this file except in compliance with the License. You may obtain a copy +of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +License for the specific language governing permissions and limitations +under the License. + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/LICENSE.md.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/LICENSE.md.meta new file mode 100644 index 00000000000..bf706af784a --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/LICENSE.md.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 0bb2a057b5ad641078a3a93a07c69688 +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Plugins.meta similarity index 77% rename from Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground.meta rename to Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Plugins.meta index 6ff64ad638e..ead39a3fc67 100644 --- a/Explorer/Assets/DCL/WebRequests/WebContentSizes/Playground.meta +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Plugins.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: 2cd32fe278f4417db8daea1d2de2bfc9 +guid: c22b6d7fe2b7a408b9d37213ee20fc22 folderAsset: yes DefaultImporter: externalObjects: {} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Plugins/UnityCloudKtx.xcprivacy b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Plugins/UnityCloudKtx.xcprivacy new file mode 100644 index 00000000000..0c67376ebac --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Plugins/UnityCloudKtx.xcprivacy @@ -0,0 +1,5 @@ + + + + + diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Plugins/UnityCloudKtx.xcprivacy.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Plugins/UnityCloudKtx.xcprivacy.meta new file mode 100644 index 00000000000..c623d6d62a0 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Plugins/UnityCloudKtx.xcprivacy.meta @@ -0,0 +1,93 @@ +fileFormatVersion: 2 +guid: e09a6500039094d23aea3c42d1873b1a +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude Linux64: 0 + Exclude OSXUniversal: 0 + Exclude VisionOS: 0 + Exclude WebGL: 1 + Exclude Win: 0 + Exclude Win64: 0 + Exclude iOS: 0 + Exclude tvOS: 0 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: Win64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + VisionOS: VisionOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: ARM64 + CompileFlags: + FrameworkDependencies: + - first: + iPhone: iOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + - first: + tvOS: tvOS + second: + enabled: 1 + settings: + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/README.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/README.md new file mode 100644 index 00000000000..d25532a9de3 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/README.md @@ -0,0 +1,47 @@ +# KTX for Unity + +[![codecov](https://codecov.unity3d.com/ghe/unity/com.unity.cloud.ktx/graph/badge.svg?token=6OICFLLO21)](https://codecov.unity3d.com/ghe/unity/com.unity.cloud.ktx) + +

+ +

+ +Unity package that allows users to load [KTX™ 2.0][ktx] or [Basis Universal][basisu] texture files. + +## Installing + +[Installation instructions](./Documentation~/installation.md) + +> **NOTE:** This package originally had the identifier `com.atteneder.ktx`. Consult the [upgrade guide](./Documentation~/upgrade-guide.md#unity-fork) to learn how to switch to the Unity version (`com.unity.cloud.ktx`) or [install the original package](./Documentation~/Original.md). + +## Trademarks + +*Unity* is a registered trademark of [Unity Technologies][unity]. + +Khronos® and the Khronos Group logo are registered trademarks of the [The Khronos Group Inc][khronos]. + +KTX™ and the KTX logo are trademarks of the [The Khronos Group Inc][khronos]. + +## License + +Copyright 2023 Unity Technologies and the *KTX for Unity* authors + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use files in this repository except in compliance with the License. +You may obtain a copy of the License at + + + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. + +[basisu]: https://github.com/BinomialLLC/basis_universal +[binomial]: http://www.binomial.info +[khronos]: https://www.khronos.org +[kofi]: https://ko-fi.com/C0C3BW7G +[ktx]: https://www.khronos.org/ktx/ +[ktxsoftware]: https://github.com/KhronosGroup/KTX-Software +[unity]: https://unity.com diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/README.md.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/README.md.meta new file mode 100644 index 00000000000..7d38d823345 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/README.md.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: f7954d42732534776bc9d32e4bd09301 +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime.meta new file mode 100644 index 00000000000..40ff74d806b --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4c22c6b49f56148ab88667e75ae98294 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins.meta new file mode 100644 index 00000000000..f3daa4ff8cf --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 77e5045a33ee741e6b77d086f2098b36 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android.meta new file mode 100644 index 00000000000..b1699091a89 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ae14990b858a44990a646b472e37e635 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs.meta new file mode 100644 index 00000000000..7efd0870644 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 43e5190baac5e47a697e6bf7593f15da +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/arm64-v8a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/arm64-v8a.meta new file mode 100644 index 00000000000..afde52b7b9b --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/arm64-v8a.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ddbe29b93de2e4098a0319609212bfea +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/arm64-v8a/libktx_unity.so b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/arm64-v8a/libktx_unity.so new file mode 100644 index 00000000000..101cdfedc40 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/arm64-v8a/libktx_unity.so @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fa25eed8a481e8e503e778c3eaf074890f06c62324014bf765ee71b31c9be275 +size 9098792 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/arm64-v8a/libktx_unity.so.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/arm64-v8a/libktx_unity.so.meta new file mode 100644 index 00000000000..6854f602aa5 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/arm64-v8a/libktx_unity.so.meta @@ -0,0 +1,99 @@ +fileFormatVersion: 2 +guid: f4ab5185ce27f471fa7869b5b2ea7152 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 0 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude Lumin: 0 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 1 + settings: + CPU: ARM64 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Lumin: Lumin + second: + enabled: 1 + settings: {} + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/armeabi-v7a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/armeabi-v7a.meta new file mode 100644 index 00000000000..e839c937d70 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/armeabi-v7a.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9b0e8bdb2145e40848c028c9b22b11c5 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/armeabi-v7a/libktx_unity.so b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/armeabi-v7a/libktx_unity.so new file mode 100644 index 00000000000..33346c5916a --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/armeabi-v7a/libktx_unity.so @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1addbd12a33ee73f58e03e499df7c0e7a98fff4a351e9561b37d2ca81a8b0a68 +size 7133716 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/armeabi-v7a/libktx_unity.so.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/armeabi-v7a/libktx_unity.so.meta new file mode 100644 index 00000000000..01deecba235 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/armeabi-v7a/libktx_unity.so.meta @@ -0,0 +1,93 @@ +fileFormatVersion: 2 +guid: 423e57854450d490fbdb016dafe74d83 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 0 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 1 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86.meta new file mode 100644 index 00000000000..d4d91be3feb --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 419eae61e6ad74f84a16006d7007f848 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86/libktx_unity.so b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86/libktx_unity.so new file mode 100644 index 00000000000..ad80a0d81a7 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86/libktx_unity.so @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:048666370b5bc71039a0092438899c36bf0b785a60a1ce35b8de1a0b309033fa +size 7438148 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86/libktx_unity.so.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86/libktx_unity.so.meta new file mode 100644 index 00000000000..99563859e44 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86/libktx_unity.so.meta @@ -0,0 +1,90 @@ +fileFormatVersion: 2 +guid: 2e4665f29f26f4c57a3a2074a4860f83 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 0 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + Android: Android + second: + enabled: 1 + settings: + CPU: X86 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + - first: + tvOS: tvOS + second: + enabled: 0 + settings: + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86_64.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86_64.meta new file mode 100644 index 00000000000..9c98a67fabc --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86_64.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c967f2f0c47ee40d6ba3eeec831f23ec +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86_64/libktx_unity.so b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86_64/libktx_unity.so new file mode 100644 index 00000000000..eb3b2208046 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86_64/libktx_unity.so @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e85cac9276e6799a0a52e96f9116c7b561b9ff99bd4e5c9c366fa99edd00187d +size 9537720 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86_64/libktx_unity.so.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86_64/libktx_unity.so.meta new file mode 100644 index 00000000000..45dd5d7aa85 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Android/libs/x86_64/libktx_unity.so.meta @@ -0,0 +1,90 @@ +fileFormatVersion: 2 +guid: 08a96bca3aad54d77aec7ba27929bba4 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 0 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + Android: Android + second: + enabled: 1 + settings: + CPU: X86_64 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + - first: + tvOS: tvOS + second: + enabled: 0 + settings: + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux.meta new file mode 100644 index 00000000000..aa1b01cd1a7 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b525acafcf9f34224b9a88721699e761 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/aarch64.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/aarch64.meta new file mode 100644 index 00000000000..1e855535ead --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/aarch64.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: b14842703f3804f6e831ce3580399787 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/aarch64/libktx_unity.so b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/aarch64/libktx_unity.so new file mode 100755 index 00000000000..c56582c6f23 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/aarch64/libktx_unity.so @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e1362ad96d24d68a274c8418e0e440f5ee91d38e56a20345fc6e5462b9871e04 +size 1565184 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/aarch64/libktx_unity.so.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/aarch64/libktx_unity.so.meta new file mode 100644 index 00000000000..ccbb695a22f --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/aarch64/libktx_unity.so.meta @@ -0,0 +1,70 @@ +fileFormatVersion: 2 +guid: 35fc3687552164bd5a728ddf57d5d680 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude EmbeddedLinux: 0 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude Win: 1 + Exclude Win64: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + EmbeddedLinux: EmbeddedLinux + second: + enabled: 1 + settings: + CPU: Arm64 + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/arm32.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/arm32.meta new file mode 100644 index 00000000000..6325c0527c7 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/arm32.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 2ab966e04daa246ea8918f0803a91f14 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/arm32/libktx_unity.so b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/arm32/libktx_unity.so new file mode 100755 index 00000000000..7a8bfdc6607 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/arm32/libktx_unity.so @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:17f850b1e1a234de8cef0d76a54852f7f0f5d5b75beaf591c1d3a1e3fec12ea5 +size 1909364 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/arm32/libktx_unity.so.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/arm32/libktx_unity.so.meta new file mode 100644 index 00000000000..e9c670751c5 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/arm32/libktx_unity.so.meta @@ -0,0 +1,78 @@ +fileFormatVersion: 2 +guid: 8b51188ac481745aca470fbb243aa240 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude EmbeddedLinux: 0 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude QNX: 1 + Exclude Win: 1 + Exclude Win64: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + EmbeddedLinux: EmbeddedLinux + second: + enabled: 1 + settings: + CPU: Arm32 + - first: + QNX: QNX + second: + enabled: 0 + settings: + CPU: Arm64 + SDK: Neutrino71 + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86.meta new file mode 100644 index 00000000000..a8df08c49b0 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ced06a11793f7477fbc6799b94337db3 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86/libktx_unity.so b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86/libktx_unity.so new file mode 100755 index 00000000000..d0db155a80c --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86/libktx_unity.so @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a0b12fd77f7fb624f2a8b42f78d14af4cf3c788ba25092ce9bbcf70ee1a4bae8 +size 1690300 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86/libktx_unity.so.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86/libktx_unity.so.meta new file mode 100644 index 00000000000..c326d92929f --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86/libktx_unity.so.meta @@ -0,0 +1,78 @@ +fileFormatVersion: 2 +guid: d8650814639be4f86aa5cb2f101b790e +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude EmbeddedLinux: 0 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude QNX: 1 + Exclude Win: 1 + Exclude Win64: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + EmbeddedLinux: EmbeddedLinux + second: + enabled: 1 + settings: + CPU: X86 + - first: + QNX: QNX + second: + enabled: 0 + settings: + CPU: Arm64 + SDK: Neutrino71 + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86_64.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86_64.meta new file mode 100644 index 00000000000..7756dca0b46 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86_64.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 18bf4695b4cca4ef2aee2416007842dd +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86_64/libktx_unity.so b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86_64/libktx_unity.so new file mode 100755 index 00000000000..44f5e189e0e --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86_64/libktx_unity.so @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d3ba0ea8612f7bdb3c8010048b09689640ca9e05a10d92036f3e4590b6f280ad +size 1867056 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86_64/libktx_unity.so.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86_64/libktx_unity.so.meta new file mode 100644 index 00000000000..b01716d2b92 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/EmbeddedLinux/x86_64/libktx_unity.so.meta @@ -0,0 +1,78 @@ +fileFormatVersion: 2 +guid: 76be6c1edd5574322a9fd518a0d25f15 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude EmbeddedLinux: 0 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude QNX: 1 + Exclude Win: 1 + Exclude Win64: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + EmbeddedLinux: EmbeddedLinux + second: + enabled: 1 + settings: + CPU: X64 + - first: + QNX: QNX + second: + enabled: 0 + settings: + CPU: Arm64 + SDK: Neutrino71 + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA.meta new file mode 100644 index 00000000000..e4b4f3f07c4 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6eca49f8e655d436dbc4e6f85ee852a3 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM.meta new file mode 100644 index 00000000000..d6a6404ff6d --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: c2c2d0835da64415190bdd2c4483c9d4 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM/ktx_unity.dll b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM/ktx_unity.dll new file mode 100644 index 00000000000..d38524542e9 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM/ktx_unity.dll @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3c0d7dd92350163135278f17caa3301deb2629388027fdf27c9d4a3df447bc19 +size 928768 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM/ktx_unity.dll.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM/ktx_unity.dll.meta new file mode 100644 index 00000000000..983ea26298c --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM/ktx_unity.dll.meta @@ -0,0 +1,82 @@ +fileFormatVersion: 2 +guid: da619142cd2bc4993a5e8ad05edcae47 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: ARM + DontProcess: false + PlaceholderPath: + SDK: UWP + ScriptingBackend: AnyScriptingBackend + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM64.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM64.meta new file mode 100644 index 00000000000..20bb6d6f680 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM64.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e92cca116f4864d1389246a3ea7599cf +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM64/ktx_unity.dll b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM64/ktx_unity.dll new file mode 100644 index 00000000000..2f2375b6205 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM64/ktx_unity.dll @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0582490e2b2258a978b7cf04ea37fbe0cd6b510b346c451e152acf624299917f +size 1018880 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM64/ktx_unity.dll.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM64/ktx_unity.dll.meta new file mode 100644 index 00000000000..9be20ffbe28 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/ARM64/ktx_unity.dll.meta @@ -0,0 +1,82 @@ +fileFormatVersion: 2 +guid: 459d92ea1694f4b2eb4ebba2aadc16bb +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: ARM64 + DontProcess: false + PlaceholderPath: + SDK: UWP + ScriptingBackend: AnyScriptingBackend + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x64.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x64.meta new file mode 100644 index 00000000000..edd7775a7b8 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x64.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d894c22e6a7ad42d6a0540a5ba1b358f +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x64/ktx_unity.dll b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x64/ktx_unity.dll new file mode 100644 index 00000000000..e6b0a1d2a7c --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x64/ktx_unity.dll @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e47722616c3fe2259c345a8dfad1d24f86556f7e472f164f61e9c4c7d0a19c0f +size 1074176 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x64/ktx_unity.dll.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x64/ktx_unity.dll.meta new file mode 100644 index 00000000000..551c2080ba6 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x64/ktx_unity.dll.meta @@ -0,0 +1,82 @@ +fileFormatVersion: 2 +guid: cdf17b8e9e65c4d64a7638a6803e8602 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: X64 + DontProcess: false + PlaceholderPath: + SDK: UWP + ScriptingBackend: AnyScriptingBackend + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x86.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x86.meta new file mode 100644 index 00000000000..be0fa9f1e71 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x86.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 84ba353bb1b1349d08d3377b515e7dd1 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x86/ktx_unity.dll b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x86/ktx_unity.dll new file mode 100644 index 00000000000..e7188eedcdd --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x86/ktx_unity.dll @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2c5fef46808eb93c80b31fef690cc0077fe2ea4778dba9b5e845b704caa33cf0 +size 976384 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x86/ktx_unity.dll.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x86/ktx_unity.dll.meta new file mode 100644 index 00000000000..950282f1514 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WSA/x86/ktx_unity.dll.meta @@ -0,0 +1,82 @@ +fileFormatVersion: 2 +guid: 9553e4323f00649e4b28acf2ea794452 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude WindowsStoreApps: 0 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 1 + settings: + CPU: X86 + DontProcess: false + PlaceholderPath: + SDK: UWP + ScriptingBackend: AnyScriptingBackend + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL.meta new file mode 100644 index 00000000000..b9e6349e64c --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5771f9b18d1364447be73a8a6682f929 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020.meta new file mode 100644 index 00000000000..a571489ed10 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 4f7e1987db5e846a189263569788dd26 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_read.bc b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_read.bc new file mode 100644 index 00000000000..5d5421ab4d1 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_read.bc @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d1710e4e5bc9421a8712be7d31faf2eb1129c3f57c3d4d6daa740c4db2b1e2a0 +size 3601372 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_read.bc.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_read.bc.meta new file mode 100644 index 00000000000..1af53645811 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_read.bc.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: 143eb4e0158994750a74465b1c68a52b +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_unity.bc b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_unity.bc new file mode 100644 index 00000000000..3cc080dd05d --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_unity.bc @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0ede61e9fd3d9a3abdd54112f5c8b7051c8090cebe12ab85fd888b2910e3bbba +size 11440 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_unity.bc.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_unity.bc.meta new file mode 100644 index 00000000000..7a5b89e6cec --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libktx_unity.bc.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: d5d7736ff60a64272adca7a7c3635175 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libobj_basisu_cbind.bc b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libobj_basisu_cbind.bc new file mode 100644 index 00000000000..548176f1d78 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libobj_basisu_cbind.bc @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6787abda4c7355d53d5faf5d4b61ea07448f10bff65493240565fd66f7a0258b +size 27464 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libobj_basisu_cbind.bc.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libobj_basisu_cbind.bc.meta new file mode 100644 index 00000000000..738b96812b0 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2020/libobj_basisu_cbind.bc.meta @@ -0,0 +1,69 @@ +fileFormatVersion: 2 +guid: c2217daa2f255429fac9f7ad37ededb5 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: x86 + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021.meta new file mode 100644 index 00000000000..77ed4416791 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 6bb7d97e8d1ef4bcd94d2ccdbfe53bea +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_read.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_read.a new file mode 100644 index 00000000000..a6c98704ad2 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_read.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7e5c4118505aac2e4bc3511b5762542c4af12603c89a98e432ef55c91dbbbbf5 +size 1406486 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_read.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_read.a.meta new file mode 100644 index 00000000000..bc8711a63e9 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_read.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: df97b0e93a9ce4dfea9b19bb84c197aa +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_unity.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_unity.a new file mode 100644 index 00000000000..13d87812e33 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_unity.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a87bd3d22a9c2e79b5251017cd014acb9b278583b48c29f96f7579448da9a8da +size 2396 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_unity.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_unity.a.meta new file mode 100644 index 00000000000..a56aee44b0e --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libktx_unity.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: ad44f70cce67349758a1f872354c25be +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libobj_basisu_cbind.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libobj_basisu_cbind.a new file mode 100644 index 00000000000..66ab8b1f92e --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libobj_basisu_cbind.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4130d6a1144840d5f9783b345601821b460597d72ffde0b96cf99ffcad9442ab +size 11642 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libobj_basisu_cbind.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libobj_basisu_cbind.a.meta new file mode 100644 index 00000000000..5a6c5e2d89f --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2021/libobj_basisu_cbind.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: c3d638c4775624a4aa8a0124da084d8c +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022.meta new file mode 100644 index 00000000000..61a1bd42d22 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e7f0c720ae0ba46f4974736d144d29c4 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_read.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_read.a new file mode 100644 index 00000000000..58e6f5c4385 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_read.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e91f1958da30250bd9386cdb3359c6ebfe813208e626460219af25b601a36b2c +size 1412584 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_read.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_read.a.meta new file mode 100644 index 00000000000..f2bc5de9f3f --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_read.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: 1903498fc70cf40f698bc7cb3f3b616f +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_unity.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_unity.a new file mode 100644 index 00000000000..57b36fe0046 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_unity.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:511360ebc0475d9f3d20bc2dd101afec2e9576ffc5013f62d982ae01edc71afb +size 2348 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_unity.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_unity.a.meta new file mode 100644 index 00000000000..39a70886d79 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libktx_unity.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: 39f63d50e71334f7886493189c281dd9 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libobj_basisu_cbind.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libobj_basisu_cbind.a new file mode 100644 index 00000000000..d5014483b2c --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libobj_basisu_cbind.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cabae273b05406a443be75f8cf5b22795b19d0cc1fbf60ce69e2a8881dd280e9 +size 11578 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libobj_basisu_cbind.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libobj_basisu_cbind.a.meta new file mode 100644 index 00000000000..3461d10e928 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2022/libobj_basisu_cbind.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: 56a5eafddecc942128d8c15652750b74 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023.meta new file mode 100644 index 00000000000..71c403169ce --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: f6b13f6397ef045d2a428f2488b0f4e6 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_read.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_read.a new file mode 100644 index 00000000000..19d3e0e37ae --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_read.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:88d444594be8471a59faea871d9db317d902925dc54c4a0d51bb1214b650f640 +size 1472796 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_read.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_read.a.meta new file mode 100644 index 00000000000..dcbd62236a0 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_read.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: 064f9fdd6ee9346269b838d6b768b3cc +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_unity.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_unity.a new file mode 100644 index 00000000000..26b588eabb9 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_unity.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9f2ee1b0543cc69a87807dec2a317d12ddb877f24d5d9858af03702b46557721 +size 2354 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_unity.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_unity.a.meta new file mode 100644 index 00000000000..1ab37c78a1f --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libktx_unity.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: b8faaa868093c46ddab6e9538d1625e6 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libobj_basisu_cbind.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libobj_basisu_cbind.a new file mode 100644 index 00000000000..805346d87ab --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libobj_basisu_cbind.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d36122ed77b466ecb063e2852881562efdb02869c3f2ed80e20fcb67e2410041 +size 7088 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libobj_basisu_cbind.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libobj_basisu_cbind.a.meta new file mode 100644 index 00000000000..63e8cc203e8 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/WebGL/2023/libobj_basisu_cbind.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: 22f5fcc807c2544dda814ef9d61f68ad +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 0 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + WebGL: WebGL + second: + enabled: 1 + settings: {} + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows.meta new file mode 100644 index 00000000000..3c94dd8114a --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 76c10eea9e40340a9a1f3dd30f24f76e +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows/ARM64.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows/ARM64.meta new file mode 100644 index 00000000000..47cfb14459d --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows/ARM64.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 9150a9b38704f4314b0c5eb9ecabf950 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows/ARM64/ktx_unity.dll b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows/ARM64/ktx_unity.dll new file mode 100644 index 00000000000..b633dd92927 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows/ARM64/ktx_unity.dll @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:02222fe76b40e579a72cac2841d8173b40dd74435b7c6275744128f852fa2ff0 +size 1021952 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows/ARM64/ktx_unity.dll.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows/ARM64/ktx_unity.dll.meta new file mode 100644 index 00000000000..f4f04be4654 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/Windows/ARM64/ktx_unity.dll.meta @@ -0,0 +1,63 @@ +fileFormatVersion: 2 +guid: c16b44002583b4f7194982bbe84d49ff +PluginImporter: + externalObjects: {} + serializedVersion: 3 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + Android: + enabled: 0 + settings: + CPU: ARMv7 + Any: + enabled: 0 + settings: + Exclude Editor: 0 + Exclude Linux64: 0 + Exclude OSXUniversal: 0 + Exclude Win: 1 + Exclude Win64: 0 + Editor: + enabled: 1 + settings: + CPU: ARM64 + DefaultValueInitialized: true + OS: Windows + Linux64: + enabled: 1 + settings: + CPU: None + OSXUniversal: + enabled: 1 + settings: + CPU: None + Win: + enabled: 0 + settings: + CPU: None + Win64: + enabled: 1 + settings: + CPU: ARM64 + iOS: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + tvOS: + enabled: 0 + settings: + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS.meta new file mode 100644 index 00000000000..43e947cbecf --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 75eeceda13f4c487c94cc5be0df2e31c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device.meta new file mode 100644 index 00000000000..c079f2f3453 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 07032db81c2d3431bbfa00e503564766 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_read.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_read.a new file mode 100644 index 00000000000..3f404c6f1c4 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_read.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9459827190788c397eb123ef2b1324dc4c3a7fd8d203ab4b4180d5c5a6cb34f9 +size 5228920 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_read.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_read.a.meta new file mode 100644 index 00000000000..75745842bef --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_read.a.meta @@ -0,0 +1,81 @@ +fileFormatVersion: 2 +guid: a867bdb681d774eb38516ac75be5e47d +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 0 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + iPhone: iOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_unity.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_unity.a new file mode 100644 index 00000000000..b18c0e02fad --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_unity.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0dadb2988a64ec591462c0ce8181b75a0be49fb2926d9d49bd00bc04265d81b8 +size 15104 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_unity.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_unity.a.meta new file mode 100644 index 00000000000..f21d3795572 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libktx_unity.a.meta @@ -0,0 +1,93 @@ +fileFormatVersion: 2 +guid: 345c37a26800144d89aba2499ddbc995 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 0 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Facebook: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + iPhone: iOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libobj_basisu_cbind.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libobj_basisu_cbind.a new file mode 100644 index 00000000000..681f09223c0 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libobj_basisu_cbind.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:acfc194f56fe126af898af77b4e772e8043f88fc618c470bc81336a7cbfad0d6 +size 31712 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libobj_basisu_cbind.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libobj_basisu_cbind.a.meta new file mode 100644 index 00000000000..238fb87d009 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Device/libobj_basisu_cbind.a.meta @@ -0,0 +1,81 @@ +fileFormatVersion: 2 +guid: 7fb1865e0d506421980e6ec97c60d691 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 0 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + iPhone: iOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator.meta new file mode 100644 index 00000000000..a64f5f15cc6 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 49406b45659514bb0a552ee0b567336c +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_read.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_read.a new file mode 100644 index 00000000000..235f5e2b60f --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_read.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f2d74534d16c51f0a67e3c28f2214c845976759536dd11144066e60ff2ba5970 +size 10964232 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_read.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_read.a.meta new file mode 100644 index 00000000000..3811d42bcb4 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_read.a.meta @@ -0,0 +1,68 @@ +fileFormatVersion: 2 +guid: b00c34163fb384f0991e7a3d15dbd412 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 0 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: x86 + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_unity.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_unity.a new file mode 100644 index 00000000000..ad7cba36316 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_unity.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:17ee5398724acc4bc43ea7a6e76c6fa6306f005dd76f5a6498e16047f9f93f78 +size 31664 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_unity.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_unity.a.meta new file mode 100644 index 00000000000..27ecf5a83ab --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libktx_unity.a.meta @@ -0,0 +1,68 @@ +fileFormatVersion: 2 +guid: 979fa446342eb47abb6a6f16d397aa31 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 0 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: x86 + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libobj_basisu_cbind.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libobj_basisu_cbind.a new file mode 100644 index 00000000000..a6df7179788 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libobj_basisu_cbind.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f1da3e07d7547f8c5f308d822237526fec892ad3b47bff8173c91e1d83f2a73 +size 66264 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libobj_basisu_cbind.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libobj_basisu_cbind.a.meta new file mode 100644 index 00000000000..15333c9c24b --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/iOS/Simulator/libobj_basisu_cbind.a.meta @@ -0,0 +1,68 @@ +fileFormatVersion: 2 +guid: 76456591896054ec3b23d4e5d71d95ce +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 0 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: x86 + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + iPhone: iOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS.meta new file mode 100644 index 00000000000..151971558dd --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e384ccbf1185a456094bce9443d58f25 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device.meta new file mode 100644 index 00000000000..70e50b69c86 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0b4a7e0fdc77645ccb5a6b3aa48a1ed7 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_read.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_read.a new file mode 100644 index 00000000000..82067a98d02 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_read.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:96119b105770085154bcdc4de4cb19756d7b9e16b85c4c09132a31e9019b8075 +size 5229008 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_read.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_read.a.meta new file mode 100644 index 00000000000..58de8e9a989 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_read.a.meta @@ -0,0 +1,73 @@ +fileFormatVersion: 2 +guid: dc618d1eb75424d758a9f22db0d34ed2 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude EmbeddedLinux: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude QNX: 1 + Exclude VisionOS: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 0 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + tvOS: tvOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_unity.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_unity.a new file mode 100644 index 00000000000..43555480b28 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_unity.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a3b1c7bd68955b92880ee420815162d795890fa6ae6e7827671c090167f47e29 +size 15104 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_unity.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_unity.a.meta new file mode 100644 index 00000000000..195c18e92eb --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libktx_unity.a.meta @@ -0,0 +1,73 @@ +fileFormatVersion: 2 +guid: d5db5b34c159e4e079f3b1aea79c46ea +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude EmbeddedLinux: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude QNX: 1 + Exclude VisionOS: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 0 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + tvOS: tvOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libobj_basisu_cbind.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libobj_basisu_cbind.a new file mode 100644 index 00000000000..fca9aa2830b --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libobj_basisu_cbind.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3675ddaa8134edd7c4a7688f47025505b3bea6fc98be0ea2909116ac353826d0 +size 31712 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libobj_basisu_cbind.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libobj_basisu_cbind.a.meta new file mode 100644 index 00000000000..0640d733028 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Device/libobj_basisu_cbind.a.meta @@ -0,0 +1,73 @@ +fileFormatVersion: 2 +guid: 96c536a1e5af341f6b5f7f37a34b9ba6 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude EmbeddedLinux: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude QNX: 1 + Exclude VisionOS: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 0 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + tvOS: tvOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator.meta new file mode 100644 index 00000000000..e35001b979f --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 5fb8d7422be3948f4bc3f33996c07359 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_read.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_read.a new file mode 100644 index 00000000000..60d3cbc3cb7 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_read.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b0ad8a571eb018e88735fcc50788908e7dd66e7e040ef224ec5e49e18fae1084 +size 10964432 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_read.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_read.a.meta new file mode 100644 index 00000000000..945b6aebf48 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_read.a.meta @@ -0,0 +1,73 @@ +fileFormatVersion: 2 +guid: 477fb30539dca4809a2d01156e8b4b3a +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude EmbeddedLinux: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude QNX: 1 + Exclude VisionOS: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 0 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + tvOS: tvOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_unity.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_unity.a new file mode 100644 index 00000000000..432b40809e2 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_unity.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4a9587d6a8c0f29919287cb38057f4c190f044083979f6250808f367da08d88 +size 31664 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_unity.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_unity.a.meta new file mode 100644 index 00000000000..dfc406e7e9b --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libktx_unity.a.meta @@ -0,0 +1,73 @@ +fileFormatVersion: 2 +guid: d3976fc0f6883455da6777d777ab5a99 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude EmbeddedLinux: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude QNX: 1 + Exclude VisionOS: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 0 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + tvOS: tvOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libobj_basisu_cbind.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libobj_basisu_cbind.a new file mode 100644 index 00000000000..0711fe20049 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libobj_basisu_cbind.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3b6efe656650f89b2d68d6b47c374db4dc0747796bfabd783ea00d2e4d8e0706 +size 66272 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libobj_basisu_cbind.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libobj_basisu_cbind.a.meta new file mode 100644 index 00000000000..31edfbb9b5b --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/tvOS/Simulator/libobj_basisu_cbind.a.meta @@ -0,0 +1,73 @@ +fileFormatVersion: 2 +guid: 47a18d92467574106886bca07c0df0d5 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude EmbeddedLinux: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude QNX: 1 + Exclude VisionOS: 1 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 0 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + DefaultValueInitialized: true + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + tvOS: tvOS + second: + enabled: 1 + settings: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS.meta new file mode 100644 index 00000000000..79b22562026 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: d717c25b2dd0542aba2b1147ab7ad3ee +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device.meta new file mode 100644 index 00000000000..f6a0ceaf688 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: ee6754192ff9c465195638f32be8f056 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_read.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_read.a new file mode 100644 index 00000000000..d439a400017 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_read.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3047a8a7efa993f1e422ea13dcad9b17fabe63c3cd2764eee105b8e1aca7043e +size 4631392 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_read.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_read.a.meta new file mode 100644 index 00000000000..b8fce9a5e65 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_read.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: ce2b99694300a4fb083e36b2f6c100b5 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude VisionOS: 0 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + VisionOS: VisionOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: ARM64 + CompileFlags: + FrameworkDependencies: + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_unity.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_unity.a new file mode 100644 index 00000000000..bbd324f33dc --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_unity.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1a765ed2ac3e1c62c8afae8fdc9695ac76e729008382c463bc5041bd18459d70 +size 13000 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_unity.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_unity.a.meta new file mode 100644 index 00000000000..4099c80e225 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libktx_unity.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: d00b6e604e6654652a466bbada324ffa +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude VisionOS: 0 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + VisionOS: VisionOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: ARM64 + CompileFlags: + FrameworkDependencies: + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libobj_basisu_cbind.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libobj_basisu_cbind.a new file mode 100644 index 00000000000..87f2315f387 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libobj_basisu_cbind.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:631d927509636469ee03a72742fd31dda87cda7c9fb2f6e1296f75636343785e +size 29784 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libobj_basisu_cbind.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libobj_basisu_cbind.a.meta new file mode 100644 index 00000000000..e69b5c9f689 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Device/libobj_basisu_cbind.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: fd93b6ef6d510465886beae87c378983 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude VisionOS: 0 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + VisionOS: VisionOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: ARM64 + CompileFlags: + FrameworkDependencies: + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator.meta new file mode 100644 index 00000000000..c48caed2f78 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: a633df61e6086495b9f1a65bfadb2578 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_read.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_read.a new file mode 100644 index 00000000000..54d3493fc45 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_read.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1efd1f1e8eed1554cef42e376bd39c3660d11aafe12380407692007c4a3b8cbe +size 9675960 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_read.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_read.a.meta new file mode 100644 index 00000000000..7af37e417c9 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_read.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: 9adddcd80ffe848e796c3856d7a6ce80 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude VisionOS: 0 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + VisionOS: VisionOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: ARM64 + CompileFlags: + FrameworkDependencies: + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_unity.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_unity.a new file mode 100644 index 00000000000..9479f92ad1b --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_unity.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:52d66d0b375ed293362dda9400dc449b1376bfb6a406a82c15ee0d35ff38c99d +size 26384 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_unity.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_unity.a.meta new file mode 100644 index 00000000000..bf12eceeb5b --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libktx_unity.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: e8b93040f56e546d38dd1db6fc9a6773 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude VisionOS: 0 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + VisionOS: VisionOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: ARM64 + CompileFlags: + FrameworkDependencies: + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libobj_basisu_cbind.a b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libobj_basisu_cbind.a new file mode 100644 index 00000000000..982c0a03dd4 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libobj_basisu_cbind.a @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bccabd4c6ac31b6d3ca4aebdee5df221ab032dfb38fc8dbd71e76f8c4dce943d +size 60792 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libobj_basisu_cbind.a.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libobj_basisu_cbind.a.meta new file mode 100644 index 00000000000..8c9cd4f537a --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/visionOS/Simulator/libobj_basisu_cbind.a.meta @@ -0,0 +1,86 @@ +fileFormatVersion: 2 +guid: bd5e133cf478b4b68a0c4c31a5626c0d +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 0 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 1 + Exclude Linux64: 1 + Exclude OSXUniversal: 1 + Exclude VisionOS: 0 + Exclude WebGL: 1 + Exclude Win: 1 + Exclude Win64: 1 + Exclude iOS: 1 + Exclude tvOS: 1 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 0 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: AnyOS + - first: + Standalone: Linux64 + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 0 + settings: + CPU: None + - first: + VisionOS: VisionOS + second: + enabled: 1 + settings: + AddToEmbeddedBinaries: false + CPU: ARM64 + CompileFlags: + FrameworkDependencies: + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64.meta new file mode 100644 index 00000000000..bd56cd49d02 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: e0cffd11cf8c84a8ea098653d82f6f95 +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle.meta new file mode 100644 index 00000000000..0e94d0c7a40 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle.meta @@ -0,0 +1,94 @@ +fileFormatVersion: 2 +guid: cc1baad46c2c049f2b1cc4c86988493b +folderAsset: yes +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 0 + Exclude Linux64: 0 + Exclude OSXUniversal: 0 + Exclude WebGL: 1 + Exclude Win: 0 + Exclude Win64: 0 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 1 + settings: + CPU: AnyCPU + DefaultValueInitialized: true + OS: OSX + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Facebook: Win64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: Linux64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: Win + second: + enabled: 1 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/CodeResources b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/CodeResources new file mode 100644 index 00000000000..8612f8c5553 Binary files /dev/null and b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/CodeResources differ diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/Info.plist b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/Info.plist new file mode 100644 index 00000000000..94d75783177 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/Info.plist @@ -0,0 +1,56 @@ + + + + + BuildMachineOSBuild + 20G1427 + CFBundleDevelopmentRegion + English + CFBundleExecutable + ktx_unity + CFBundleGetInfoString + Unity wrapper for KTX-Software + CFBundleIdentifier + com.unity.cloud.ktx-plugin + CFBundleInfoDictionaryVersion + 6.0 + CFBundleLongVersionString + 1.4.1-614bb24 + CFBundleName + KTX for Unity native library + CFBundlePackageType + APPL + CFBundleShortVersionString + 1.4.1 + CFBundleSignature + ???? + CFBundleSupportedPlatforms + + MacOSX + + CFBundleVersion + 614bb24 + CSResourcesFileMapped + + DTCompiler + com.apple.compilers.llvm.clang.1_0 + DTPlatformBuild + 13C100 + DTPlatformName + macosx + DTPlatformVersion + 12.1 + DTSDKBuild + 21C46 + DTSDKName + macosx12.1 + DTXcode + 1321 + DTXcodeBuild + 13C100 + LSMinimumSystemVersion + 11.7 + NSHumanReadableCopyright + + + diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/MacOS/ktx_unity b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/MacOS/ktx_unity new file mode 100755 index 00000000000..8659a8ef9ac --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/MacOS/ktx_unity @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3e4e9f59c7f2980af393a0642e08cf3cb7e48b80e48ebcd92cdef6f21aee7305 +size 3484976 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/_CodeSignature/CodeResources b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/_CodeSignature/CodeResources new file mode 100644 index 00000000000..d5d0fd74412 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.bundle/Contents/_CodeSignature/CodeResources @@ -0,0 +1,115 @@ + + + + + files + + files2 + + rules + + ^Resources/ + + ^Resources/.*\.lproj/ + + optional + + weight + 1000 + + ^Resources/.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Resources/Base\.lproj/ + + weight + 1010 + + ^version.plist$ + + + rules2 + + .*\.dSYM($|/) + + weight + 11 + + ^(.*/)?\.DS_Store$ + + omit + + weight + 2000 + + ^(Frameworks|SharedFrameworks|PlugIns|Plug-ins|XPCServices|Helpers|MacOS|Library/(Automator|Spotlight|LoginItems))/ + + nested + + weight + 10 + + ^.* + + ^Info\.plist$ + + omit + + weight + 20 + + ^PkgInfo$ + + omit + + weight + 20 + + ^Resources/ + + weight + 20 + + ^Resources/.*\.lproj/ + + optional + + weight + 1000 + + ^Resources/.*\.lproj/locversion.plist$ + + omit + + weight + 1100 + + ^Resources/Base\.lproj/ + + weight + 1010 + + ^[^/]+$ + + nested + + weight + 10 + + ^embedded\.provisionprofile$ + + weight + 20 + + ^version\.plist$ + + weight + 20 + + + + diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.dll b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.dll new file mode 100644 index 00000000000..4c852b05389 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.dll @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6f89618a356bc8a8feb1f8c906504977d831056f306abe94f597065b08692e6e +size 1078784 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.dll.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.dll.meta new file mode 100644 index 00000000000..61fde9e4191 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/ktx_unity.dll.meta @@ -0,0 +1,104 @@ +fileFormatVersion: 2 +guid: 85debc512cba9478895f3cc16a58399b +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 0 + Exclude Linux64: 0 + Exclude OSXUniversal: 0 + Exclude WebGL: 1 + Exclude Win: 0 + Exclude Win64: 0 + Exclude WindowsStoreApps: 1 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 1 + settings: + CPU: x86_64 + DefaultValueInitialized: true + OS: Windows + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Facebook: Win64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: Linux64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 1 + settings: + CPU: x86_64 + - first: + Standalone: Win + second: + enabled: 1 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Windows Store Apps: WindowsStoreApps + second: + enabled: 0 + settings: + CPU: X64 + DontProcess: false + PlaceholderPath: + SDK: AnySDK + ScriptingBackend: AnyScriptingBackend + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/libktx_unity.so b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/libktx_unity.so new file mode 100644 index 00000000000..78faa2b5c22 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/libktx_unity.so @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c542344b84cd1b9d58bccba54dce3857b1327a9da1a89dfe120f055b5cda7993 +size 1857280 diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/libktx_unity.so.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/libktx_unity.so.meta new file mode 100644 index 00000000000..57ebbae0e4b --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Plugins/x86_64/libktx_unity.so.meta @@ -0,0 +1,93 @@ +fileFormatVersion: 2 +guid: f595590246c394792b78d024af6de511 +PluginImporter: + externalObjects: {} + serializedVersion: 2 + iconMap: {} + executionOrder: {} + defineConstraints: [] + isPreloaded: 1 + isOverridable: 1 + isExplicitlyReferenced: 0 + validateReferences: 1 + platformData: + - first: + : Any + second: + enabled: 0 + settings: + Exclude Android: 1 + Exclude Editor: 0 + Exclude Linux64: 0 + Exclude OSXUniversal: 1 + Exclude WebGL: 1 + Exclude Win: 0 + Exclude Win64: 0 + Exclude iOS: 1 + - first: + Android: Android + second: + enabled: 0 + settings: + CPU: ARMv7 + - first: + Any: + second: + enabled: 0 + settings: {} + - first: + Editor: Editor + second: + enabled: 1 + settings: + CPU: x86_64 + DefaultValueInitialized: true + OS: Linux + - first: + Facebook: Win + second: + enabled: 0 + settings: + CPU: None + - first: + Facebook: Win64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: Linux64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + Standalone: OSXUniversal + second: + enabled: 0 + settings: + CPU: None + - first: + Standalone: Win + second: + enabled: 1 + settings: + CPU: None + - first: + Standalone: Win64 + second: + enabled: 1 + settings: + CPU: AnyCPU + - first: + iPhone: iOS + second: + enabled: 0 + settings: + AddToEmbeddedBinaries: false + CPU: AnyCPU + CompileFlags: + FrameworkDependencies: + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts.meta new file mode 100644 index 00000000000..e02b480b24d --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts.meta @@ -0,0 +1,8 @@ +fileFormatVersion: 2 +guid: 0893ada546ee14e4bbd0930c09eed76d +folderAsset: yes +DefaultImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/AssemblyInfo.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/AssemblyInfo.cs new file mode 100644 index 00000000000..3824ad62a34 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/AssemblyInfo.cs @@ -0,0 +1,7 @@ +// SPDX-FileCopyrightText: 2024 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + +using System.Runtime.CompilerServices; + +[assembly: InternalsVisibleTo("Ktx.Editor")] +[assembly: InternalsVisibleTo("Ktx.Tests")] diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/AssemblyInfo.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/AssemblyInfo.cs.meta new file mode 100644 index 00000000000..66fc325a4a8 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/AssemblyInfo.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: d7415f6efd443472289692140f48b700 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversal.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversal.cs new file mode 100644 index 00000000000..e0aaed67cc8 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversal.cs @@ -0,0 +1,110 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +// TODO: Re-using transcoders does not work consistently. Fix and enable! +// #define POOL_TRANSCODERS + +using System; +using System.Runtime.InteropServices; +using UnityEngine; +using UnityEngine.Profiling; +using Unity.Jobs; +using Unity.Collections; + +namespace KtxUnity +{ + static class BasisUniversal + { + static bool s_Initialized; + static int s_TranscoderCountAvailable = 8; + +#if POOL_TRANSCODERS + static Stack transcoderPool; +#endif + + static void InitInternal() + { + s_Initialized = true; + TranscodeFormatHelper.Init(); + ktx_basisu_basis_init(); + s_TranscoderCountAvailable = SystemInfo.processorCount; + } + + public static BasisUniversalTranscoderInstance GetTranscoderInstance() + { + if (!s_Initialized) + { + InitInternal(); + } +#if POOL_TRANSCODERS + if(transcoderPool!=null) { + return transcoderPool.Pop(); + } +#endif + if (s_TranscoderCountAvailable > 0) + { + s_TranscoderCountAvailable--; + return new BasisUniversalTranscoderInstance(ktx_basisu_create_basis()); + } + else + { + return null; + } + } + + public static void ReturnTranscoderInstance(BasisUniversalTranscoderInstance transcoder) + { +#if POOL_TRANSCODERS + if(transcoderPool==null) { + transcoderPool = new Stack(); + } + transcoderPool.Push(transcoder); +#endif + s_TranscoderCountAvailable++; + } + + internal static JobHandle LoadBytesJob( + ref BasisUniversalJob job, + BasisUniversalTranscoderInstance basis, + TranscodeFormat transF, + bool mipChain = true + ) + { + + Profiler.BeginSample("BasisU.LoadBytesJob"); + + var numLevels = basis.GetLevelCount(job.layer); + var levelsNeeded = mipChain ? numLevels - job.mipLevel : 1; + var sizes = new NativeArray((int)levelsNeeded, KtxNativeInstance.defaultAllocator); + var offsets = new NativeArray((int)levelsNeeded, KtxNativeInstance.defaultAllocator); + uint totalSize = 0; + for (var i = 0u; i < levelsNeeded; i++) + { + var level = job.mipLevel + i; + offsets[(int)i] = totalSize; + var size = basis.GetImageTranscodedSize(job.layer, level, transF); + sizes[(int)i] = size; + totalSize += size; + } + + job.format = transF; + job.sizes = sizes; + job.offsets = offsets; + job.nativeReference = basis.nativeReference; + + job.textureData = new NativeArray((int)totalSize, KtxNativeInstance.defaultAllocator); + + var jobHandle = job.Schedule(); + + Profiler.EndSample(); + return jobHandle; + } + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern void ktx_basisu_basis_init(); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern IntPtr ktx_basisu_create_basis(); + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversal.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversal.cs.meta new file mode 100644 index 00000000000..ab636b926c6 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversal.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 4fb3828f15fa34986bf4adf6f5b7efb6 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTexture.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTexture.cs new file mode 100644 index 00000000000..e9083b22e2f --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTexture.cs @@ -0,0 +1,225 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +using System.Threading.Tasks; +using UnityEngine; +using UnityEngine.Experimental.Rendering; +using UnityEngine.Profiling; +using Unity.Collections; + +namespace KtxUnity +{ + /// + /// Loads a Basis Universal texture from the StreamingAssets folder, a URL, or a buffer. + /// + public class BasisUniversalTexture : TextureBase + { + + NativeSlice m_InputData; + NativeArray m_TextureData; + MetaData m_MetaData; + TextureOrientation m_Orientation; + + /// + public override ErrorCode Open(NativeSlice data) + { + KtxNativeInstance.CertifySupportedPlatform(); + m_InputData = data; + return ErrorCode.Success; + } + + /// + public override async Task LoadTexture2D( + bool linear = false, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + KtxNativeInstance.CertifySupportedPlatform(); + return await LoadTexture2DInternal( + linear, + layer, + 0, + mipLevel, + mipChain); + } + + /// + public override async Task LoadTexture2D( + GraphicsFormat targetFormat, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + KtxNativeInstance.CertifySupportedPlatform(); + return await LoadTexture2DInternal( + true, + layer, + 0, + mipLevel, + mipChain, + targetFormat); + } + + /// + public override void Dispose() { } + + internal async Task LoadFromBytesInternal( + NativeSlice data, + bool linear = false, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + m_InputData = data; + var result = await LoadTexture2DInternal(linear, layer, faceSlice, mipLevel, mipChain); + Dispose(); + return result; + } + + async Task LoadTexture2DInternal( + bool linear = false, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true, + GraphicsFormat? targetFormat = null + ) + { + var transcoder = BasisUniversal.GetTranscoderInstance(); + + while (transcoder == null) + { + await Task.Yield(); + transcoder = BasisUniversal.GetTranscoderInstance(); + } + + var result = new TextureResult(); + + GraphicsFormat format; + + if (transcoder.Open(m_InputData)) + { + m_MetaData = transcoder.LoadMetaData(); + + var formatTuple = targetFormat.HasValue + ? TranscodeFormatHelper.GetTranscodeFormats(targetFormat.Value) + : GetFormat(m_MetaData, m_MetaData.images[layer].levels[0], linear); + + if (formatTuple.HasValue) + { + var formats = formatTuple.Value; + +#if KTX_VERBOSE + Debug.LogFormat("LoadTexture2D to GraphicsFormat {0} ({1})",formats.format,formats.transcodeFormat); +#endif + + format = formats.format; + result.errorCode = await Transcode( + transcoder, + formats.transcodeFormat, + layer, + mipLevel, + mipChain + ); + } + else + { + BasisUniversal.ReturnTranscoderInstance(transcoder); + result.errorCode = ErrorCode.UnsupportedFormat; + return result; + } + + m_Orientation = TextureOrientation.KtxDefault; + if (!transcoder.GetYFlip()) + { + // Regular basis files (no y_flip) seem to be + m_Orientation |= TextureOrientation.YUp; + } + BasisUniversal.ReturnTranscoderInstance(transcoder); + } + else + { + BasisUniversal.ReturnTranscoderInstance(transcoder); + result.errorCode = ErrorCode.LoadingFailed; + return result; + } + + Profiler.BeginSample("LoadBytesRoutineGpuUpload"); + + m_MetaData.GetSize(out var width, out var height, layer, mipLevel); + var flags = KtxNativeInstance.defaultTextureCreationFlags; + if (mipChain && m_MetaData.images[layer].levels.Length - mipLevel > 1) + { + flags |= TextureCreationFlags.MipChain; + } + + result.texture = new Texture2D((int)width, (int)height, format, flags); + result.orientation = m_Orientation; + +#if KTX_UNITY_GPU_UPLOAD + // TODO: native GPU upload +#else +#endif + + result.texture.LoadRawTextureData(m_TextureData); + result.texture.Apply(false, true); + m_TextureData.Dispose(); + Profiler.EndSample(); + return result; + } + + async Task Transcode( + BasisUniversalTranscoderInstance transcoder, + TranscodeFormat transcodeFormat, + uint layer, + uint mipLevel, + bool mipChain + ) + { + var result = ErrorCode.Success; + + Profiler.BeginSample("BasisUniversalJob"); + var job = new BasisUniversalJob + { + layer = layer, + mipLevel = mipLevel, + result = new NativeArray(1, KtxNativeInstance.defaultAllocator) + }; + + var jobHandle = BasisUniversal.LoadBytesJob( + ref job, + transcoder, + transcodeFormat, + mipChain + ); + + m_TextureData = job.textureData; + Profiler.EndSample(); + + while (!jobHandle.IsCompleted) + { + await Task.Yield(); + } + jobHandle.Complete(); + + if (!job.result[0]) + { + m_TextureData.Dispose(); + result = ErrorCode.TranscodeFailed; + } + job.sizes.Dispose(); + job.offsets.Dispose(); + job.result.Dispose(); + + return result; + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTexture.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTexture.cs.meta new file mode 100644 index 00000000000..bfff9d96861 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTexture.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: a474492a7726b4b70ab8635c5102d744 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTranscoderInstance.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTranscoderInstance.cs new file mode 100644 index 00000000000..7ad5e421536 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTranscoderInstance.cs @@ -0,0 +1,216 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + + +using System.Runtime.InteropServices; +using System; +using UnityEngine; +using Unity.Collections; +using Unity.Collections.LowLevel.Unsafe; +using UnityEngine.Profiling; + + +namespace KtxUnity +{ + + // Source: basisu_transcoder.h -> basist::basis_texture_type + enum BasisUniversalTextureType + { + /// + /// An arbitrary array of 2D RGB or RGBA images with optional mipmaps, + /// array size = # images, each image may have a different resolution + /// and # of mipmap levels + /// + Image2D = 0, + + /// + /// An array of 2D RGB or RGBA images with optional mipmaps, + /// array size = # images, each image has the same resolution and + /// mipmap levels + /// + Image2DArray = 1, + + /// + /// An array of cubemap levels, + /// total # of images must be dividable by 6, + /// in X+, X-, Y+, Y-, Z+, Z- order, with optional mipmaps + /// + CubemapArray = 2, + + /// + /// An array of 2D video frames, with optional mipmaps, + /// # frames = # images, each image has the same resolution and # of + /// mipmap levels + /// + VideoFrames = 3, + + /// + /// A 3D texture with optional mipmaps, Z dimension = # images, + /// each image has the same resolution and # of mipmap levels + /// + Volume = 4, + } + + class BasisUniversalTranscoderInstance + { + public IntPtr nativeReference; + + public BasisUniversalTranscoderInstance(IntPtr nativeReference) + { + this.nativeReference = nativeReference; + } + + public unsafe bool Open(NativeSlice data) + { + void* src = data.GetUnsafeReadOnlyPtr(); + bool success = ktx_basisu_open_basis(nativeReference, src, data.Length); +#if DEBUG + if(!success) { + Debug.LogError("Couldn't validate BasisU header!"); + } +#endif + return success; + } + + public MetaData LoadMetaData() + { + Profiler.BeginSample("LoadMetaData"); + MetaData meta = new MetaData(); + meta.hasAlpha = GetHasAlpha(); + var imageCount = GetImageCount(); + meta.images = new ImageInfo[imageCount]; + for (uint i = 0; i < imageCount; i++) + { + var ii = new ImageInfo(); + var levelCount = GetLevelCount(i); + ii.levels = new LevelInfo[levelCount]; + for (uint l = 0; l < levelCount; l++) + { + var li = new LevelInfo(); + GetImageSize(out li.width, out li.height, i, l); + ii.levels[l] = li; + } + meta.images[i] = ii; + } + Profiler.EndSample(); + return meta; + } + + public void Close() + { + ktx_basisu_close_basis(nativeReference); + } + + public bool GetHasAlpha() + { + return ktx_basisu_getHasAlpha(nativeReference); + } + + public uint GetImageCount() + { + return ktx_basisu_getNumImages(nativeReference); + } + + public uint GetLevelCount(uint imageIndex) + { + return ktx_basisu_getNumLevels(nativeReference, imageIndex); + } + + public void GetImageSize(out uint width, out uint height, uint imageIndex = 0, uint levelIndex = 0) + { + width = ktx_basisu_getImageWidth(nativeReference, imageIndex, levelIndex); + height = ktx_basisu_getImageHeight(nativeReference, imageIndex, levelIndex); + } + + public bool GetYFlip() + { + return !ktx_basisu_get_y_flip(nativeReference); + } + + // public bool GetIsEtc1s() { + // return ktx_basisu_get_is_etc1s(nativeReference); + // } + + public BasisUniversalTextureType GetTextureType() + { + return ktx_basisu_get_texture_type(nativeReference); + } + + public uint GetImageTranscodedSize(uint imageIndex, uint levelIndex, TranscodeFormat format) + { + return ktx_basisu_getImageTranscodedSizeInBytes(nativeReference, imageIndex, levelIndex, (uint)format); + } + + public unsafe bool Transcode(uint imageIndex, uint levelIndex, TranscodeFormat format, out byte[] transcodedData) + { + Profiler.BeginSample("BasisU.Transcode"); + transcodedData = null; + + if (!ktx_basisu_startTranscoding(nativeReference)) + { + Profiler.EndSample(); + return false; + } + + var size = GetImageTranscodedSize(imageIndex, levelIndex, format); + var data = new byte[size]; + + bool result; + fixed (void* dst = &(data[0])) + { + result = ktx_basisu_transcodeImage(nativeReference, dst, size, imageIndex, levelIndex, (uint)format, 0, 0); + } + transcodedData = data; + Profiler.EndSample(); + return result; + } + + ~BasisUniversalTranscoderInstance() + { + ktx_basisu_delete_basis(nativeReference); + } + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern unsafe bool ktx_basisu_open_basis(IntPtr basis, void* data, int length); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern void ktx_basisu_close_basis(IntPtr basis); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern void ktx_basisu_delete_basis(IntPtr basis); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern bool ktx_basisu_getHasAlpha(IntPtr basis); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern uint ktx_basisu_getNumImages(IntPtr basis); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern uint ktx_basisu_getNumLevels(IntPtr basis, uint imageIndex); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern uint ktx_basisu_getImageWidth(IntPtr basis, uint imageIndex, uint levelIndex); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern uint ktx_basisu_getImageHeight(IntPtr basis, uint imageIndex, uint levelIndex); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern bool ktx_basisu_get_y_flip(IntPtr basis); + + // [DllImport(KtxNativeInstance.ktxLibrary)] + // private static extern bool ktx_basisu_get_is_etc1s( IntPtr basis ); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern BasisUniversalTextureType ktx_basisu_get_texture_type(IntPtr basis); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern uint ktx_basisu_getImageTranscodedSizeInBytes(IntPtr basis, uint imageIndex, uint levelIndex, uint format); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern bool ktx_basisu_startTranscoding(IntPtr basis); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern unsafe bool ktx_basisu_transcodeImage(IntPtr basis, void* dst, uint dstSize, uint imageIndex, uint levelIndex, uint format, uint pvrtcWrapAddressing, uint getAlphaForOpaqueFormats); + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTranscoderInstance.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTranscoderInstance.cs.meta new file mode 100644 index 00000000000..cd1a7290930 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/BasisUniversalTranscoderInstance.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 17f02ea40dfb34ccaa0ac5d87a7b566f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ErrorCode.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ErrorCode.cs new file mode 100644 index 00000000000..b72d3e4b179 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ErrorCode.cs @@ -0,0 +1,108 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +using System; +using System.Collections.Generic; + +namespace KtxUnity +{ + + /// + /// Describes an error during the texture import. + /// + public enum ErrorCode + { + /// + /// Texture import was successful. + /// + Success, + /// + /// KTX v1 is not supported. + /// + UnsupportedVersion, + /// + /// The GraphicsFormat is unsupported by KTX Unity. + /// + UnsupportedFormat, + /// + /// The GraphicsFormat is unsupported by the current system. + /// + FormatUnsupportedBySystem, + /// + /// Only super-compressed KTX is supported. + /// + NotSuperCompressed, + /// + /// Loading from URI returned a WebRequest error. + /// + OpenUriFailed, + /// + /// Loading texture data failed. + /// + LoadingFailed, + /// + /// Transcoding to GraphicsFormat failed. + /// + TranscodeFailed, + /// + /// Layer index exceeds layer count. + /// + InvalidLayer, + /// + /// MipMap level exceeds level count. + /// + InvalidLevel, + /// + /// Face slice exceeds face count. + /// + InvalidFace, + /// + /// Face slice exceeds base depth. + /// + InvalidSlice, + } + + + /// + /// Used to generate a message from an . + /// + public static class ErrorMessage + { +#if !DEBUG + const string k_UnknownErrorMessage = "Unknown Error"; +#endif + static readonly Dictionary k_ErrorMessages = new Dictionary() { + { ErrorCode.Success, "OK" }, + { ErrorCode.UnsupportedVersion, "Only KTX 2.0 is supported" }, + { ErrorCode.UnsupportedFormat, "Unsupported format" }, + { ErrorCode.FormatUnsupportedBySystem, "Format not supported by system" }, + { ErrorCode.NotSuperCompressed, "Only super-compressed KTX is supported" }, + { ErrorCode.OpenUriFailed, "Loading URI failed" }, + { ErrorCode.LoadingFailed, "Loading failed" }, + { ErrorCode.TranscodeFailed, "Transcoding failed" }, + { ErrorCode.InvalidLayer, "Invalid ImageIndex" }, + { ErrorCode.InvalidLevel, "Invalid MipMapLevel" }, + { ErrorCode.InvalidFace, "Invalid Face" }, + { ErrorCode.InvalidSlice, "Invalid Slice" }, + }; + + /// + /// Generates a message from an . + /// + /// The to generate a message from. + /// The generated error message. + public static string GetErrorMessage(ErrorCode code) + { + if (k_ErrorMessages.TryGetValue(code, out var message)) + { + return message; + } +#if DEBUG + return $"No Error message for error {code.ToString()}"; +#else + return k_UnknownErrorMessage; +#endif + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ErrorCode.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ErrorCode.cs.meta new file mode 100644 index 00000000000..241b010bd4d --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ErrorCode.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 6fe8b0f45c4ef4f359341ca686313dd2 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/Ktx.asmdef b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/Ktx.asmdef new file mode 100644 index 00000000000..4234898614f --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/Ktx.asmdef @@ -0,0 +1,25 @@ +{ + "name": "Ktx", + "rootNamespace": "KtxUnity", + "references": [], + "includePlatforms": [], + "excludePlatforms": [], + "allowUnsafeCode": true, + "overrideReferences": false, + "precompiledReferences": [], + "autoReferenced": true, + "defineConstraints": [], + "versionDefines": [ + { + "name": "Unity", + "expression": "2022.3.13", + "define": "FAST_TEXTURE_CREATION_FLAGS" + }, + { + "name": "Unity", + "expression": "2022.1", + "define": "FAST_TEXTURE_CREATION_FLAGS_NON_OPENGL" + } + ], + "noEngineReferences": false +} \ No newline at end of file diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/Ktx.asmdef.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/Ktx.asmdef.meta new file mode 100644 index 00000000000..fef5135e4fb --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/Ktx.asmdef.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: 3d354272d3f2f4c3387dbccbaebd0f60 +AssemblyDefinitionImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxEnum.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxEnum.cs new file mode 100644 index 00000000000..58a4170e5de --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxEnum.cs @@ -0,0 +1,335 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +namespace KtxUnity +{ + + enum KtxClassId + { + KtxTexture1 = 1, + KtxTexture2 = 2 + } + + /// + /// KTX error codes (taken from native ktx.h) + /// + enum KtxErrorCode + { + Success = 0, /*!< Operation was successful. */ + FileDataError, /*!< The data in the file is inconsistent with the spec. */ + FileIsPipe, /*!< The file is a pipe or named pipe. */ + FileOpenFailed, /*!< The target file could not be opened. */ + FileOverflow, /*!< The operation would exceed the max file size. */ + FileReadError, /*!< An error occurred while reading from the file. */ + FileSeekError, /*!< An error occurred while seeking in the file. */ + FileUnexpectedEof, /*!< File does not have enough data to satisfy request. */ + FileWriteError, /*!< An error occurred while writing to the file. */ + GLError, /*!< GL operations resulted in an error. */ + InvalidOperation, /*!< The operation is not allowed in the current state. */ + InvalidValue, /*!< A parameter value was not valid */ + NotFound, /*!< Requested key was not found */ + OutOfMemory, /*!< Not enough memory to complete the operation. */ + TranscodeFailed, /*!< Transcoding of block compressed texture failed. */ + UnknownFileFormat, /*!< The file not a KTX file */ + UnsupportedTextureType, /*!< The KTX file specifies an unsupported texture type. */ + UnsupportedFeature, /*!< Feature not included in in-use library or not yet implemented. */ + LibraryNotLinked, /*!< Library dependency (OpenGL or Vulkan) not linked into application. */ + ErrorMaxEnum = LibraryNotLinked /*!< For safety checks. */ + } + + enum KtxSuperCompressionScheme + { + None = 0, /*!< No supercompression. */ + Basis = 1, /*!< Basis Universal supercompression. */ + LZMA = 2, /*!< LZMA supercompression. */ + ZLib = 3, /*!< Zlib supercompression. */ + ZStd = 4, /*!< ZStd supercompression. */ + BeginRange = None, + EndRange = ZStd, + BeginVendorRange = 0x10000, + EndVendorRange = 0x1ffff, + BeginReserved = 0x20000, + } + + /// + /// Source: KTX-Software, vkformat_enum.h + /// + enum VkFormat + { + Undefined = 0, + R4G4UNormPack8 = 1, + R4G4B4A4UNormPack16 = 2, + B4G4R4A4UNormPack16 = 3, + R5G6B5UNormPack16 = 4, + B5G6R5UNormPack16 = 5, + R5G5B5A1UNormPack16 = 6, + B5G5R5A1UNormPack16 = 7, + A1R5G5B5UNormPack16 = 8, + R8UNorm = 9, + R8SNorm = 10, + R8UScaled = 11, + R8SScaled = 12, + R8UInt = 13, + R8SInt = 14, + R8Srgb = 15, + R8G8UNorm = 16, + R8G8SNorm = 17, + R8G8UScaled = 18, + R8G8SScaled = 19, + R8G8UInt = 20, + R8G8SInt = 21, + R8G8Srgb = 22, + R8G8B8UNorm = 23, + R8G8B8SNorm = 24, + R8G8B8UScaled = 25, + R8G8B8SScaled = 26, + R8G8B8UInt = 27, + R8G8B8SInt = 28, + R8G8B8Srgb = 29, + B8G8R8UNorm = 30, + B8G8R8SNorm = 31, + B8G8R8UScaled = 32, + B8G8R8SScaled = 33, + B8G8R8UInt = 34, + B8G8R8SInt = 35, + B8G8R8Srgb = 36, + R8G8B8A8UNorm = 37, + R8G8B8A8SNorm = 38, + R8G8B8A8UScaled = 39, + R8G8B8A8SScaled = 40, + R8G8B8A8UInt = 41, + R8G8B8A8SInt = 42, + R8G8B8A8Srgb = 43, + B8G8R8A8UNorm = 44, + B8G8R8A8SNorm = 45, + B8G8R8A8UScaled = 46, + B8G8R8A8SScaled = 47, + B8G8R8A8UInt = 48, + B8G8R8A8SInt = 49, + B8G8R8A8Srgb = 50, + A8B8G8R8UNormPack32 = 51, + A8B8G8R8SNormPack32 = 52, + A8B8G8R8UScaledPack32 = 53, + A8B8G8R8SScaledPack32 = 54, + A8B8G8R8UIntPack32 = 55, + A8B8G8R8SIntPack32 = 56, + A8B8G8R8SrgbPack32 = 57, + A2R10G10B10UNormPack32 = 58, + A2R10G10B10SNormPack32 = 59, + A2R10G10B10UScaledPack32 = 60, + A2R10G10B10SScaledPack32 = 61, + A2R10G10B10UIntPack32 = 62, + A2R10G10B10SIntPack32 = 63, + A2B10G10R10UNormPack32 = 64, + A2B10G10R10SNormPack32 = 65, + A2B10G10R10UScaledPack32 = 66, + A2B10G10R10SScaledPack32 = 67, + A2B10G10R10UIntPack32 = 68, + A2B10G10R10SIntPack32 = 69, + R16UNorm = 70, + R16SNorm = 71, + R16UScaled = 72, + R16SScaled = 73, + R16UInt = 74, + R16SInt = 75, + R16SFloat = 76, + R16G16UNorm = 77, + R16G16SNorm = 78, + R16G16UScaled = 79, + R16G16SScaled = 80, + R16G16UInt = 81, + R16G16SInt = 82, + R16G16SFloat = 83, + R16G16B16UNorm = 84, + R16G16B16SNorm = 85, + R16G16B16UScaled = 86, + R16G16B16SScaled = 87, + R16G16B16UInt = 88, + R16G16B16SInt = 89, + R16G16B16SFloat = 90, + R16G16B16A16UNorm = 91, + R16G16B16A16SNorm = 92, + R16G16B16A16UScaled = 93, + R16G16B16A16SScaled = 94, + R16G16B16A16UInt = 95, + R16G16B16A16SInt = 96, + R16G16B16A16SFloat = 97, + R32UInt = 98, + R32SInt = 99, + R32SFloat = 100, + R32G32UInt = 101, + R32G32SInt = 102, + R32G32SFloat = 103, + R32G32B32UInt = 104, + R32G32B32SInt = 105, + R32G32B32SFloat = 106, + R32G32B32A32UInt = 107, + R32G32B32A32SInt = 108, + R32G32B32A32SFloat = 109, + R64UInt = 110, + R64SInt = 111, + R64SFloat = 112, + R64G64UInt = 113, + R64G64SInt = 114, + R64G64SFloat = 115, + R64G64B64UInt = 116, + R64G64B64SInt = 117, + R64G64B64SFloat = 118, + R64G64B64A64UInt = 119, + R64G64B64A64SInt = 120, + R64G64B64A64SFloat = 121, + B10G11R11UFloatPack32 = 122, + E5B9G9R9UFloatPack32 = 123, + D16UNorm = 124, + X8D24UNormPack32 = 125, + D32SFloat = 126, + S8UInt = 127, + D16UNormS8UInt = 128, + D24UNormS8UInt = 129, + D32SFloatS8UInt = 130, + BC1RgbUNormBlock = 131, + BC1RGBSrgbBlock = 132, + BC1RgbaUNormBlock = 133, + BC1RGBASrgbBlock = 134, + BC2UNormBlock = 135, + BC2SrgbBlock = 136, + BC3UNormBlock = 137, + BC3SrgbBlock = 138, + BC4UNormBlock = 139, + BC4SNormBlock = 140, + BC5UNormBlock = 141, + BC5SNormBlock = 142, + BC6HUFloatBlock = 143, + BC6HSFloatBlock = 144, + BC7UNormBlock = 145, + BC7SrgbBlock = 146, + ETC2R8G8B8UNormBlock = 147, + ETC2R8G8B8SrgbBlock = 148, + ETC2R8G8B8A1UNormBlock = 149, + ETC2R8G8B8A1SrgbBlock = 150, + ETC2R8G8B8A8UNormBlock = 151, + ETC2R8G8B8A8SrgbBlock = 152, + EACR11UNormBlock = 153, + EACR11SNormBlock = 154, + EACR11G11UNormBlock = 155, + EACR11G11SNormBlock = 156, + Astc4X4UNormBlock = 157, + Astc4X4SrgbBlock = 158, + Astc5X4UNormBlock = 159, + Astc5X4SrgbBlock = 160, + Astc5X5UNormBlock = 161, + Astc5X5SrgbBlock = 162, + Astc6X5UNormBlock = 163, + Astc6X5SrgbBlock = 164, + Astc6X6UNormBlock = 165, + Astc6X6SrgbBlock = 166, + Astc8X5UNormBlock = 167, + Astc8X5SrgbBlock = 168, + Astc8X6UNormBlock = 169, + Astc8X6SrgbBlock = 170, + Astc8X8UNormBlock = 171, + Astc8X8SrgbBlock = 172, + Astc10X5UNormBlock = 173, + Astc10X5SrgbBlock = 174, + Astc10X6UNormBlock = 175, + Astc10X6SrgbBlock = 176, + Astc10X8UNormBlock = 177, + Astc10X8SrgbBlock = 178, + Astc10X10UNormBlock = 179, + Astc10X10SrgbBlock = 180, + Astc12X10UNormBlock = 181, + Astc12X10SrgbBlock = 182, + Astc12X12UNormBlock = 183, + Astc12X12SrgbBlock = 184, + G8B8G8R8422UNorm = 1000156000, + B8G8R8G8422UNorm = 1000156001, + G8B8R83Plane420UNorm = 1000156002, + G8B8R82Plane420UNorm = 1000156003, + G8B8R83Plane422UNorm = 1000156004, + G8B8R82Plane422UNorm = 1000156005, + G8B8R83Plane444UNorm = 1000156006, + R10X6UNormPack16 = 1000156007, + R10X6G10X6UNorm2Pack16 = 1000156008, + R10X6G10X6B10X6A10X6UNorm4Pack16 = 1000156009, + G10X6B10X6G10X6R10X6422UNorm4Pack16 = 1000156010, + B10X6G10X6R10X6G10X6422UNorm4Pack16 = 1000156011, + G10X6B10X6R10X63Plane420UNorm3Pack16 = 1000156012, + G10X6B10X6R10X62Plane420UNorm3Pack16 = 1000156013, + G10X6B10X6R10X63Plane422UNorm3Pack16 = 1000156014, + G10X6B10X6R10X62Plane422UNorm3Pack16 = 1000156015, + G10X6B10X6R10X63Plane444UNorm3Pack16 = 1000156016, + R12X4UNormPack16 = 1000156017, + R12X4G12X4UNorm2Pack16 = 1000156018, + R12X4G12X4B12X4A12X4UNorm4Pack16 = 1000156019, + G12X4B12X4G12X4R12X4422UNorm4Pack16 = 1000156020, + B12X4G12X4R12X4G12X4422UNorm4Pack16 = 1000156021, + G12X4B12X4R12X43Plane420UNorm3Pack16 = 1000156022, + G12X4B12X4R12X42Plane420UNorm3Pack16 = 1000156023, + G12X4B12X4R12X43Plane422UNorm3Pack16 = 1000156024, + G12X4B12X4R12X42Plane422UNorm3Pack16 = 1000156025, + G12X4B12X4R12X43Plane444UNorm3Pack16 = 1000156026, + G16B16G16R16422UNorm = 1000156027, + B16G16R16G16422UNorm = 1000156028, + G16B16R163Plane420UNorm = 1000156029, + G16B16R162Plane420UNorm = 1000156030, + G16B16R163Plane422UNorm = 1000156031, + G16B16R162Plane422UNorm = 1000156032, + G16B16R163Plane444UNorm = 1000156033, + PVRTC12BppUNormBlockImg = 1000054000, + PVRTC14BppUNormBlockImg = 1000054001, + PVRTC22BppUNormBlockImg = 1000054002, + PVRTC24BppUNormBlockImg = 1000054003, + PVRTC12BppSrgbBlockImg = 1000054004, + PVRTC14BppSrgbBlockImg = 1000054005, + PVRTC22BppSrgbBlockImg = 1000054006, + PVRTC24BppSrgbBlockImg = 1000054007, + Astc4X4SFloatBlockExt = 1000066000, + Astc5X4SFloatBlockExt = 1000066001, + Astc5X5SFloatBlockExt = 1000066002, + Astc6X5SFloatBlockExt = 1000066003, + Astc6X6SFloatBlockExt = 1000066004, + Astc8X5SFloatBlockExt = 1000066005, + Astc8X6SFloatBlockExt = 1000066006, + Astc8X8SFloatBlockExt = 1000066007, + Astc10X5SFloatBlockExt = 1000066008, + Astc10X6SFloatBlockExt = 1000066009, + Astc10X8SFloatBlockExt = 1000066010, + Astc10X10SFloatBlockExt = 1000066011, + Astc12X10SFloatBlockExt = 1000066012, + Astc12X12SFloatBlockExt = 1000066013, + Astc3X3X3UNormBlockExt = 1000288000, + Astc3X3X3SrgbBlockExt = 1000288001, + Astc3X3X3SFloatBlockExt = 1000288002, + Astc4X3X3UNormBlockExt = 1000288003, + Astc4X3X3SrgbBlockExt = 1000288004, + Astc4X3X3SFloatBlockExt = 1000288005, + Astc4X4X3UNormBlockExt = 1000288006, + Astc4X4X3SrgbBlockExt = 1000288007, + Astc4X4X3SFloatBlockExt = 1000288008, + Astc4X4X4UNormBlockExt = 1000288009, + Astc4X4X4SrgbBlockExt = 1000288010, + Astc4X4X4SFloatBlockExt = 1000288011, + Astc5X4X4UNormBlockExt = 1000288012, + Astc5X4X4SrgbBlockExt = 1000288013, + Astc5X4X4SFloatBlockExt = 1000288014, + Astc5X5X4UNormBlockExt = 1000288015, + Astc5X5X4SrgbBlockExt = 1000288016, + Astc5X5X4SFloatBlockExt = 1000288017, + Astc5X5X5UNormBlockExt = 1000288018, + Astc5X5X5SrgbBlockExt = 1000288019, + Astc5X5X5SFloatBlockExt = 1000288020, + Astc6X5X5UNormBlockExt = 1000288021, + Astc6X5X5SrgbBlockExt = 1000288022, + Astc6X5X5SFloatBlockExt = 1000288023, + Astc6X6X5UNormBlockExt = 1000288024, + Astc6X6X5SrgbBlockExt = 1000288025, + Astc6X6X5SFloatBlockExt = 1000288026, + Astc6X6X6UNormBlockExt = 1000288027, + Astc6X6X6SrgbBlockExt = 1000288028, + Astc6X6X6SFloatBlockExt = 1000288029, + A4R4G4B4UNormPack16Ext = 1000340000, + A4B4G4R4UNormPack16Ext = 1000340001, + MaxEnum = 0x7FFFFFFF + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxEnum.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxEnum.cs.meta new file mode 100644 index 00000000000..a95a3314f45 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxEnum.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 40a31653d1ebc489689d41d6c6bc8200 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxNativeInstance.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxNativeInstance.cs new file mode 100644 index 00000000000..e1d394568ec --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxNativeInstance.cs @@ -0,0 +1,768 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + +#if UNITY_STANDALONE || UNITY_WEBGL || UNITY_IOS || UNITY_TVOS || UNITY_VISIONOS || UNITY_ANDROID || UNITY_WSA || UNITY_LUMIN || UNITY_EMBEDDED_LINUX +#define KTX_PLATFORM_SUPPORTED +#else +#define KTX_PLATFORM_NOT_SUPPORTED +#endif + +using System; +using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; +using UnityEngine; +using UnityEngine.Experimental.Rendering; +using UnityEngine.Profiling; +using Unity.Collections; +using Unity.Collections.LowLevel.Unsafe; +using Unity.Jobs; +using UnityEngine.Rendering; +using IntPtr = System.IntPtr; + +namespace KtxUnity +{ + class KtxNativeInstance : IMetaData, ILevelInfo + { +#if !UNITY_EDITOR && (UNITY_WEBGL || UNITY_IOS || UNITY_TVOS || UNITY_VISIONOS) + internal const string ktxLibrary = "__Internal"; +#elif UNITY_EDITOR || UNITY_ANDROID || UNITY_STANDALONE || UNITY_WSA || PLATFORM_LUMIN || UNITY_EMBEDDED_LINUX + internal const string ktxLibrary = "ktx_unity"; +#else + // Unsupported platform + internal const string ktxLibrary = "UnsupportedPlatform"; +#endif + + /// + /// Benchmarks have shown that the 4 frame limit until disposal that + /// Allocator.TempJob grants is sometimes not enough, so I chose Persistent. + /// + public const Allocator defaultAllocator = Allocator.Persistent; + + internal static TextureCreationFlags defaultTextureCreationFlags => +#if FAST_TEXTURE_CREATION_FLAGS + TextureCreationFlags.DontUploadUponCreate | TextureCreationFlags.DontInitializePixels; +#elif FAST_TEXTURE_CREATION_FLAGS_NON_OPENGL + // Up until 2022.3.12 those flags cause a crash with OpenGL (Jira UUM-53142) + SystemInfo.graphicsDeviceType == GraphicsDeviceType.OpenGLCore + || SystemInfo.graphicsDeviceType == GraphicsDeviceType.OpenGLES2 + || SystemInfo.graphicsDeviceType == GraphicsDeviceType.OpenGLES3 + ? TextureCreationFlags.None + : TextureCreationFlags.DontUploadUponCreate | TextureCreationFlags.DontInitializePixels; +#else + TextureCreationFlags.None; +#endif + + IntPtr m_NativeReference; + + public bool valid => m_NativeReference != IntPtr.Zero; + + public KtxClassId ktxClass => ktx_get_classId(m_NativeReference); + + public bool needsTranscoding => ktxTexture2_NeedsTranscoding(m_NativeReference); + + public bool hasAlpha => + + // Valid for KTX 2.0 Basis Universal only! + // 1 = greyscale => no alpha + // 2 = RRRA => alpha + // 3 = RGB => no alpha + // 4 = RGBA => alpha + ktxTexture2_GetNumComponents(m_NativeReference) % 2 == 0; + + public bool isPowerOfTwo => LevelInfo.IsPowerOfTwo(baseWidth) && LevelInfo.IsPowerOfTwo(baseHeight); + + public bool isMultipleOfFour => LevelInfo.IsMultipleOfFour(baseWidth) && LevelInfo.IsMultipleOfFour(baseHeight); + + public bool isSquare => baseWidth == baseHeight; + + public uint baseWidth => ktx_get_baseWidth(m_NativeReference); + + public uint baseHeight => ktx_get_baseHeight(m_NativeReference); + + public uint baseDepth => ktx_get_baseDepth(m_NativeReference); + + public uint numLevels => ktx_get_numLevels(m_NativeReference); + + public bool isArray => ktx_get_isArray(m_NativeReference); + + public bool isCubemap => ktx_get_isCubemap(m_NativeReference); + + public bool isCompressed => ktx_get_isCompressed(m_NativeReference); + + public uint numDimensions => ktx_get_numDimensions(m_NativeReference); + + public GraphicsFormat graphicsFormat => GetGraphicsFormat(ktx_get_vkFormat(m_NativeReference)); + + /// + /// Specifies the number of array elements. If the texture is not an array texture, numLayers is 0. + /// + public uint numLayers => ktx_get_numLayers(m_NativeReference); + + /// + /// faceCount specifies the number of cubemap faces. + /// For cube maps and cubemap arrays this is 6. For non cube maps this is 1 + /// + public uint numFaces => ktx_get_numFaces(m_NativeReference); + +#if KTX_UNITY_GPU_UPLOAD + /// + /// Enqueues this texture for GPU upload in the KTX Native Unity Plugin + /// + internal void EnqueueForGpuUpload() { + Profiler.BeginSample("EnqueueForGpuUpload"); + ktx_enqueue_upload(nativeReference); + GL.IssuePluginEvent(GetRenderEventFunc(), 1); + Profiler.EndSample(); + } + + /// + /// Checks if this texture, that was previously equeued for GPU upload + /// was successfully uploaded and creates a + /// from it. + /// Resulting texture or null, in case of errors + /// True if the texture was successfully created + /// Desired graphics format + /// True if the native plugin finished processing the texture, regardless + /// of its success + /// + public bool TryCreateTexture(out Texture2D texture, out bool success, GraphicsFormat graphicsFormat) { + Profiler.BeginSample("TryCreateTexture"); + if (ktx_dequeue_upload(nativeReference,out var nativeTexture, out var error)) { + if (error == 0) { + texture = Texture2D.CreateExternalTexture( + (int)baseWidth, + (int)baseHeight, + GraphicsFormatUtility.GetTextureFormat(graphicsFormat), + numLevels>1, + !GraphicsFormatUtility.IsSRGBFormat(graphicsFormat), + nativeTexture + ); + success = true; + } + else { + texture = null; + success = false; + } + Profiler.EndSample(); + return true; + } + texture = null; + success = false; + Profiler.EndSample(); + return false; + } +#endif // KTX_UNITY_GPU_UPLOAD + + public TextureOrientation orientation => (TextureOrientation)ktx_get_orientation(m_NativeReference); + + /* + KtxClassId classId { + get { + return ktx_get_classId(nativeReference); + } + } + bool isArray { + get { + return ktx_get_isArray(nativeReference); + } + } + bool isCubemap { + get { + return ktx_get_isCubemap(nativeReference); + } + } + bool isCompressed { + get { + return ktx_get_isCompressed(nativeReference); + } + } + uint numDimensions { + get { + return ktx_get_numDimensions(nativeReference); + } + } + + uint numLayers { + get { + return ktx_get_numLayers(nativeReference); + } + } + uint numFaces { + get { + return ktx_get_numFaces(nativeReference); + } + } + uint vkFormat { + get { + return ktx_get_vkFormat(nativeReference); + } + } + KtxSuperCompressionScheme supercompressionScheme { + get { + return ktx_get_supercompressionScheme(nativeReference); + } + } + //*/ + + internal unsafe ErrorCode Load(NativeSlice data) + { + var src = data.GetUnsafeReadOnlyPtr(); + m_NativeReference = ktx_load_ktx(src, (uint)data.Length, out var status); + if (status != KtxErrorCode.Success) + { +#if DEBUG + Debug.LogErrorFormat("KTX error code {0}",status); +#endif + return ErrorCode.LoadingFailed; + } + return ErrorCode.Success; + } + + public JobHandle LoadBytesJob( + ref KtxTranscodeJob job, + TranscodeFormat transF + ) + { + Profiler.BeginSample("Ktx.LoadBytesJob"); + + job.result = new NativeArray(1, defaultAllocator); + job.nativeReference = m_NativeReference; + job.outputFormat = transF; + + var jobHandle = job.Schedule(); + + Profiler.EndSample(); + return jobHandle; + } + + public unsafe Texture2D LoadTextureData( + GraphicsFormat gf, + uint layer = 0, + uint mipLevel = 0, + uint faceSlice = 0, + bool mipChain = true + ) + { + + Profiler.BeginSample("LoadTextureData"); + var levelCount = numLevels; + var levelsNeeded = mipChain ? levelCount - mipLevel : 1; + var mipmap = levelsNeeded > 1; + + var width = baseWidth; + var height = baseHeight; + + if (mipLevel > 0) + { + width = Math.Max(1u, width >> (int)mipLevel); + height = Math.Max(1u, height >> (int)mipLevel); + } + + var flags = defaultTextureCreationFlags; + if (mipmap) + { + flags |= TextureCreationFlags.MipChain; + } + Profiler.BeginSample("CreateTexture2D"); + var texture = new Texture2D( + (int)width, + (int)height, + gf, + flags + ); + Profiler.EndSample(); + + ktx_get_data(m_NativeReference, out var data, out var length); + + if (mipmap) + { + Profiler.BeginSample("MipMapCopy"); + + for (var level = 0u; level < mipLevel; level++) + { + length -= ktx_get_image_size(m_NativeReference, level); + } + + var reorderedData = new NativeArray((int)length, Allocator.Temp); + var reorderedDataPtr = reorderedData.GetUnsafePtr(); + var result = ktx_copy_data_levels_reverted( + m_NativeReference, + mipLevel, + layer, + faceSlice, + reorderedDataPtr, + (uint)reorderedData.Length + ); + if (result != KtxErrorCode.Success) + { + return texture; + } + Profiler.BeginSample("LoadRawTextureData"); + texture.LoadRawTextureData(reorderedData); + Profiler.EndSample(); + reorderedData.Dispose(); + Profiler.EndSample(); + } + else + { + Profiler.BeginSample("LoadRawTextureData"); + if (mipLevel > 0 || levelCount != levelsNeeded || layer > 0 || faceSlice > 0) + { + var result = ktx_get_image_offset( + m_NativeReference, + mipLevel, + layer, + faceSlice, + out var offset + ); + if (result != KtxErrorCode.Success) + { + return null; + } + data += offset; + length = ktx_get_image_size(m_NativeReference, mipLevel); + } + texture.LoadRawTextureData((IntPtr)data, (int)length); + Profiler.EndSample(); + } + texture.Apply( + false, + // TODO: Expose `makeNoLongerReadable` parameter in API. +#if UNITY_VISIONOS + // PolySpatial visionOS needs to able to access raw texture data in order to do the material/texture + // conversion. + false +#else + // Free up texture memory by default. + // DCL: Changed to false so we keep it in memory by default + false +#endif + ); + Profiler.EndSample(); + return texture; + } + + /// + /// Removes the native KTX object and frees up the memory + /// + public void Unload() + { + if (valid) + { + ktx_unload_ktx(m_NativeReference); + m_NativeReference = IntPtr.Zero; + } + } + + ~KtxNativeInstance() + { + Unload(); + } + + static GraphicsFormat GetGraphicsFormat(VkFormat vkFormat) + { + switch (vkFormat) + { + case VkFormat.Astc8X8SrgbBlock: return GraphicsFormat.RGBA_ASTC8X8_SRGB; + case VkFormat.Astc8X8UNormBlock: return GraphicsFormat.RGBA_ASTC8X8_UNorm; + case VkFormat.B10G11R11UFloatPack32: return GraphicsFormat.B10G11R11_UFloatPack32; + case VkFormat.BC2SrgbBlock: return GraphicsFormat.RGBA_DXT3_SRGB; + case VkFormat.BC2UNormBlock: return GraphicsFormat.RGBA_DXT3_UNorm; + case VkFormat.BC3SrgbBlock: return GraphicsFormat.RGBA_DXT5_SRGB; + case VkFormat.BC3UNormBlock: return GraphicsFormat.RGBA_DXT5_UNorm; + case VkFormat.ETC2R8G8B8UNormBlock: return GraphicsFormat.RGB_ETC2_UNorm; + case VkFormat.R16SFloat: return GraphicsFormat.R16_SFloat; + case VkFormat.R16SInt: return GraphicsFormat.R16_SInt; + case VkFormat.R16UInt: return GraphicsFormat.R16_UInt; + case VkFormat.R32SFloat: return GraphicsFormat.R32_SFloat; + case VkFormat.R8G8B8A8SInt: return GraphicsFormat.R8G8B8A8_SInt; + case VkFormat.R8G8B8A8SNorm: return GraphicsFormat.R8G8B8A8_SNorm; + case VkFormat.R8G8B8A8Srgb: return GraphicsFormat.R8G8B8A8_SRGB; + case VkFormat.R8G8B8A8UInt: return GraphicsFormat.R8G8B8A8_UInt; + case VkFormat.R8G8B8A8UNorm: return GraphicsFormat.R8G8B8A8_UNorm; + case VkFormat.R8G8B8Srgb: return GraphicsFormat.R8G8B8_SRGB; + case VkFormat.R8G8B8UNorm: return GraphicsFormat.R8G8B8_UNorm; + case VkFormat.R8G8UNorm: return GraphicsFormat.R8G8_UNorm; + case VkFormat.R8UInt: return GraphicsFormat.R8_UInt; + case VkFormat.R8UNorm: return GraphicsFormat.R8_UNorm; + case VkFormat.A1R5G5B5UNormPack16: + case VkFormat.A2B10G10R10SIntPack32: + case VkFormat.A2B10G10R10SNormPack32: + case VkFormat.A2B10G10R10SScaledPack32: + case VkFormat.A2B10G10R10UIntPack32: + case VkFormat.A2B10G10R10UNormPack32: + case VkFormat.A2B10G10R10UScaledPack32: + case VkFormat.A2R10G10B10SIntPack32: + case VkFormat.A2R10G10B10SNormPack32: + case VkFormat.A2R10G10B10SScaledPack32: + case VkFormat.A2R10G10B10UIntPack32: + case VkFormat.A2R10G10B10UNormPack32: + case VkFormat.A2R10G10B10UScaledPack32: + case VkFormat.A4B4G4R4UNormPack16Ext: + case VkFormat.A4R4G4B4UNormPack16Ext: + case VkFormat.A8B8G8R8SIntPack32: + case VkFormat.A8B8G8R8SNormPack32: + case VkFormat.A8B8G8R8SScaledPack32: + case VkFormat.A8B8G8R8SrgbPack32: + case VkFormat.A8B8G8R8UIntPack32: + case VkFormat.A8B8G8R8UNormPack32: + case VkFormat.A8B8G8R8UScaledPack32: + case VkFormat.Astc10X10SFloatBlockExt: + case VkFormat.Astc10X10SrgbBlock: + case VkFormat.Astc10X10UNormBlock: + case VkFormat.Astc10X5SFloatBlockExt: + case VkFormat.Astc10X5SrgbBlock: + case VkFormat.Astc10X5UNormBlock: + case VkFormat.Astc10X6SFloatBlockExt: + case VkFormat.Astc10X6SrgbBlock: + case VkFormat.Astc10X6UNormBlock: + case VkFormat.Astc10X8SFloatBlockExt: + case VkFormat.Astc10X8SrgbBlock: + case VkFormat.Astc10X8UNormBlock: + case VkFormat.Astc12X10SFloatBlockExt: + case VkFormat.Astc12X10SrgbBlock: + case VkFormat.Astc12X10UNormBlock: + case VkFormat.Astc12X12SFloatBlockExt: + case VkFormat.Astc12X12SrgbBlock: + case VkFormat.Astc12X12UNormBlock: + case VkFormat.Astc3X3X3SFloatBlockExt: + case VkFormat.Astc3X3X3SrgbBlockExt: + case VkFormat.Astc3X3X3UNormBlockExt: + case VkFormat.Astc4X3X3SFloatBlockExt: + case VkFormat.Astc4X3X3SrgbBlockExt: + case VkFormat.Astc4X3X3UNormBlockExt: + case VkFormat.Astc4X4SFloatBlockExt: + case VkFormat.Astc4X4SrgbBlock: + case VkFormat.Astc4X4UNormBlock: + case VkFormat.Astc4X4X3SFloatBlockExt: + case VkFormat.Astc4X4X3SrgbBlockExt: + case VkFormat.Astc4X4X3UNormBlockExt: + case VkFormat.Astc4X4X4SFloatBlockExt: + case VkFormat.Astc4X4X4SrgbBlockExt: + case VkFormat.Astc4X4X4UNormBlockExt: + case VkFormat.Astc5X4SFloatBlockExt: + case VkFormat.Astc5X4SrgbBlock: + case VkFormat.Astc5X4UNormBlock: + case VkFormat.Astc5X4X4SFloatBlockExt: + case VkFormat.Astc5X4X4SrgbBlockExt: + case VkFormat.Astc5X4X4UNormBlockExt: + case VkFormat.Astc5X5SFloatBlockExt: + case VkFormat.Astc5X5SrgbBlock: + case VkFormat.Astc5X5UNormBlock: + case VkFormat.Astc5X5X4SFloatBlockExt: + case VkFormat.Astc5X5X4SrgbBlockExt: + case VkFormat.Astc5X5X4UNormBlockExt: + case VkFormat.Astc5X5X5SFloatBlockExt: + case VkFormat.Astc5X5X5SrgbBlockExt: + case VkFormat.Astc5X5X5UNormBlockExt: + case VkFormat.Astc6X5SFloatBlockExt: + case VkFormat.Astc6X5SrgbBlock: + case VkFormat.Astc6X5UNormBlock: + case VkFormat.Astc6X5X5SFloatBlockExt: + case VkFormat.Astc6X5X5SrgbBlockExt: + case VkFormat.Astc6X5X5UNormBlockExt: + case VkFormat.Astc6X6SFloatBlockExt: + case VkFormat.Astc6X6SrgbBlock: + case VkFormat.Astc6X6UNormBlock: + case VkFormat.Astc6X6X5SFloatBlockExt: + case VkFormat.Astc6X6X5SrgbBlockExt: + case VkFormat.Astc6X6X5UNormBlockExt: + case VkFormat.Astc6X6X6SFloatBlockExt: + case VkFormat.Astc6X6X6SrgbBlockExt: + case VkFormat.Astc6X6X6UNormBlockExt: + case VkFormat.Astc8X5SFloatBlockExt: + case VkFormat.Astc8X5SrgbBlock: + case VkFormat.Astc8X5UNormBlock: + case VkFormat.Astc8X6SFloatBlockExt: + case VkFormat.Astc8X6SrgbBlock: + case VkFormat.Astc8X6UNormBlock: + case VkFormat.Astc8X8SFloatBlockExt: + case VkFormat.B10X6G10X6R10X6G10X6422UNorm4Pack16: + case VkFormat.B12X4G12X4R12X4G12X4422UNorm4Pack16: + case VkFormat.B16G16R16G16422UNorm: + case VkFormat.B4G4R4A4UNormPack16: + case VkFormat.B5G5R5A1UNormPack16: + case VkFormat.B5G6R5UNormPack16: + case VkFormat.B8G8R8A8SInt: + case VkFormat.B8G8R8A8SNorm: + case VkFormat.B8G8R8A8SScaled: + case VkFormat.B8G8R8A8Srgb: + case VkFormat.B8G8R8A8UInt: + case VkFormat.B8G8R8A8UNorm: + case VkFormat.B8G8R8A8UScaled: + case VkFormat.B8G8R8G8422UNorm: + case VkFormat.B8G8R8SInt: + case VkFormat.B8G8R8SNorm: + case VkFormat.B8G8R8SScaled: + case VkFormat.B8G8R8Srgb: + case VkFormat.B8G8R8UInt: + case VkFormat.B8G8R8UNorm: + case VkFormat.B8G8R8UScaled: + case VkFormat.BC1RGBASrgbBlock: + case VkFormat.BC1RGBSrgbBlock: + case VkFormat.BC1RgbUNormBlock: + case VkFormat.BC1RgbaUNormBlock: + case VkFormat.BC4SNormBlock: + case VkFormat.BC4UNormBlock: + case VkFormat.BC5SNormBlock: + case VkFormat.BC5UNormBlock: + case VkFormat.BC6HSFloatBlock: + case VkFormat.BC6HUFloatBlock: + case VkFormat.BC7SrgbBlock: + case VkFormat.BC7UNormBlock: + case VkFormat.D16UNorm: + case VkFormat.D16UNormS8UInt: + case VkFormat.D24UNormS8UInt: + case VkFormat.D32SFloat: + case VkFormat.D32SFloatS8UInt: + case VkFormat.E5B9G9R9UFloatPack32: + case VkFormat.EACR11G11SNormBlock: + case VkFormat.EACR11G11UNormBlock: + case VkFormat.EACR11SNormBlock: + case VkFormat.EACR11UNormBlock: + case VkFormat.ETC2R8G8B8A1SrgbBlock: + case VkFormat.ETC2R8G8B8A1UNormBlock: + case VkFormat.ETC2R8G8B8A8SrgbBlock: + case VkFormat.ETC2R8G8B8A8UNormBlock: + case VkFormat.ETC2R8G8B8SrgbBlock: + case VkFormat.G10X6B10X6G10X6R10X6422UNorm4Pack16: + case VkFormat.G10X6B10X6R10X62Plane420UNorm3Pack16: + case VkFormat.G10X6B10X6R10X62Plane422UNorm3Pack16: + case VkFormat.G10X6B10X6R10X63Plane420UNorm3Pack16: + case VkFormat.G10X6B10X6R10X63Plane422UNorm3Pack16: + case VkFormat.G10X6B10X6R10X63Plane444UNorm3Pack16: + case VkFormat.G12X4B12X4G12X4R12X4422UNorm4Pack16: + case VkFormat.G12X4B12X4R12X42Plane420UNorm3Pack16: + case VkFormat.G12X4B12X4R12X42Plane422UNorm3Pack16: + case VkFormat.G12X4B12X4R12X43Plane420UNorm3Pack16: + case VkFormat.G12X4B12X4R12X43Plane422UNorm3Pack16: + case VkFormat.G12X4B12X4R12X43Plane444UNorm3Pack16: + case VkFormat.G16B16G16R16422UNorm: + case VkFormat.G16B16R162Plane420UNorm: + case VkFormat.G16B16R162Plane422UNorm: + case VkFormat.G16B16R163Plane420UNorm: + case VkFormat.G16B16R163Plane422UNorm: + case VkFormat.G16B16R163Plane444UNorm: + case VkFormat.G8B8G8R8422UNorm: + case VkFormat.G8B8R82Plane420UNorm: + case VkFormat.G8B8R82Plane422UNorm: + case VkFormat.G8B8R83Plane420UNorm: + case VkFormat.G8B8R83Plane422UNorm: + case VkFormat.G8B8R83Plane444UNorm: + case VkFormat.PVRTC12BppSrgbBlockImg: + case VkFormat.PVRTC12BppUNormBlockImg: + case VkFormat.PVRTC14BppSrgbBlockImg: + case VkFormat.PVRTC14BppUNormBlockImg: + case VkFormat.PVRTC22BppSrgbBlockImg: + case VkFormat.PVRTC22BppUNormBlockImg: + case VkFormat.PVRTC24BppSrgbBlockImg: + case VkFormat.PVRTC24BppUNormBlockImg: + case VkFormat.R10X6G10X6B10X6A10X6UNorm4Pack16: + case VkFormat.R10X6G10X6UNorm2Pack16: + case VkFormat.R10X6UNormPack16: + case VkFormat.R12X4G12X4B12X4A12X4UNorm4Pack16: + case VkFormat.R12X4G12X4UNorm2Pack16: + case VkFormat.R12X4UNormPack16: + case VkFormat.R16G16B16A16SFloat: + case VkFormat.R16G16B16A16SInt: + case VkFormat.R16G16B16A16SNorm: + case VkFormat.R16G16B16A16SScaled: + case VkFormat.R16G16B16A16UInt: + case VkFormat.R16G16B16A16UNorm: + case VkFormat.R16G16B16A16UScaled: + case VkFormat.R16G16B16SFloat: + case VkFormat.R16G16B16SInt: + case VkFormat.R16G16B16SNorm: + case VkFormat.R16G16B16SScaled: + case VkFormat.R16G16B16UInt: + case VkFormat.R16G16B16UNorm: + case VkFormat.R16G16B16UScaled: + case VkFormat.R16G16SFloat: + case VkFormat.R16G16SInt: + case VkFormat.R16G16SNorm: + case VkFormat.R16G16SScaled: + case VkFormat.R16G16UInt: + case VkFormat.R16G16UNorm: + case VkFormat.R16G16UScaled: + case VkFormat.R16SNorm: + case VkFormat.R16SScaled: + case VkFormat.R16UNorm: + case VkFormat.R16UScaled: + case VkFormat.R32G32B32A32SFloat: + case VkFormat.R32G32B32A32SInt: + case VkFormat.R32G32B32A32UInt: + case VkFormat.R32G32B32SFloat: + case VkFormat.R32G32B32SInt: + case VkFormat.R32G32B32UInt: + case VkFormat.R32G32SFloat: + case VkFormat.R32G32SInt: + case VkFormat.R32G32UInt: + case VkFormat.R32SInt: + case VkFormat.R32UInt: + case VkFormat.R4G4B4A4UNormPack16: + case VkFormat.R4G4UNormPack8: + case VkFormat.R5G5B5A1UNormPack16: + case VkFormat.R5G6B5UNormPack16: + case VkFormat.R64G64B64A64SFloat: + case VkFormat.R64G64B64A64SInt: + case VkFormat.R64G64B64A64UInt: + case VkFormat.R64G64B64SFloat: + case VkFormat.R64G64B64SInt: + case VkFormat.R64G64B64UInt: + case VkFormat.R64G64SFloat: + case VkFormat.R64G64SInt: + case VkFormat.R64G64UInt: + case VkFormat.R64SFloat: + case VkFormat.R64SInt: + case VkFormat.R64UInt: + case VkFormat.R8G8B8SInt: + case VkFormat.R8G8B8SNorm: + case VkFormat.R8G8B8SScaled: + case VkFormat.R8G8B8UInt: + case VkFormat.R8G8B8UScaled: + case VkFormat.R8G8SInt: + case VkFormat.R8G8SNorm: + case VkFormat.R8G8SScaled: + case VkFormat.R8G8Srgb: + case VkFormat.R8G8UInt: + case VkFormat.R8G8UScaled: + case VkFormat.R8SInt: + case VkFormat.R8SNorm: + case VkFormat.R8SScaled: + case VkFormat.R8Srgb: + case VkFormat.R8UScaled: + case VkFormat.S8UInt: + case VkFormat.X8D24UNormPack32: + case VkFormat.Undefined: + case VkFormat.MaxEnum: + default: +#if DEBUG + Debug.LogError("You're trying to load an untested/unsupported format. Please enter the correct format conversion in `KtxNativeInstance.cs`, test it and make a pull request. Otherwise please open an issue with a sample file."); +#endif + return GraphicsFormat.None; + } + } + +#if !UNITY_EDITOR && KTX_PLATFORM_SUPPORTED + [System.Diagnostics.Conditional("FALSE")] +#endif + internal static void CertifySupportedPlatform() + { +#if KTX_PLATFORM_NOT_SUPPORTED +#if UNITY_EDITOR +#if !KTX_IGNORE_PLATFORM_NOT_SUPPORTED + throw new NotSupportedException("KTX for Unity is not supported on the active build target. This will not work in a build, please switch to a supported platform in the build settings. You can bypass this exception in the Editor by setting the scripting define `KTX_IGNORE_PLATFORM_NOT_SUPPORTED`."); +#endif // !KTX_IGNORE_PLATFORM_NOT_SUPPORTED +#else + // In a build, always throw the exception. + throw new NotSupportedException("KTX for Unity is not supported on this platform."); +#endif +#endif // KTX_PLATFORM_NOT_SUPPORTED + } + + [DllImport(ktxLibrary)] + static extern unsafe IntPtr ktx_load_ktx(void* data, uint length, out KtxErrorCode status); + + [DllImport(ktxLibrary)] + static extern uint ktx_get_baseWidth(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + static extern uint ktx_get_baseHeight(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + static extern uint ktx_get_baseDepth(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + [return: MarshalAs(UnmanagedType.U1)] + static extern bool ktxTexture2_NeedsTranscoding(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + static extern uint ktxTexture2_GetNumComponents(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + public static extern KtxErrorCode ktxTexture2_TranscodeBasis(IntPtr ktxTexture, TranscodeFormat outputFormat, uint transcodeFlags); + + [DllImport(ktxLibrary)] + static extern unsafe void ktx_get_data(IntPtr ktxTexture, out byte* data, out uint length); + + [DllImport(ktxLibrary)] + static extern unsafe KtxErrorCode ktx_copy_data_levels_reverted( + IntPtr ktxTexture, + uint startLevel, + uint layer, + uint faceSlice, + void* destination, + uint destinationLength + ); + + [DllImport(ktxLibrary)] + static extern void ktx_unload_ktx(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + static extern uint ktx_get_numLevels(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + static extern uint ktx_get_orientation(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + static extern KtxClassId ktx_get_classId(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + [return: MarshalAs(UnmanagedType.U1)] + static extern bool ktx_get_isArray(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + [return: MarshalAs(UnmanagedType.U1)] + static extern bool ktx_get_isCubemap(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + [return: MarshalAs(UnmanagedType.U1)] + static extern bool ktx_get_isCompressed(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + static extern uint ktx_get_numDimensions(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + static extern uint ktx_get_numLayers(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + static extern uint ktx_get_numFaces(IntPtr ktxTexture); + + [DllImport(ktxLibrary)] + static extern VkFormat ktx_get_vkFormat(IntPtr ktxTexture); + + /* + + [DllImport(ktxLibrary)] + static extern KtxSuperCompressionScheme ktx_get_supercompressionScheme ( System.IntPtr ktxTexture ); + //*/ + + [DllImport(ktxLibrary)] + static extern KtxErrorCode ktx_get_image_offset( + IntPtr ktxTexture, + uint level, + uint layer, + uint faceSlice, + [MarshalAs(UnmanagedType.SysUInt)] + out uint pOffset + ); + + [DllImport(ktxLibrary)] + static extern uint ktx_get_image_size( + IntPtr ktxTexture, + uint level + ); + +#if KTX_UNITY_GPU_UPLOAD + [DllImport(ktxLibrary)] + static extern void ktx_enqueue_upload(IntPtr ktx); + + [DllImport(ktxLibrary)] + [return: MarshalAs(UnmanagedType.U1)] + static extern bool ktx_dequeue_upload(IntPtr ktx, out IntPtr texture, out uint error); + + [DllImport(ktxLibrary)] + static extern IntPtr GetRenderEventFunc(); +#endif + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxNativeInstance.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxNativeInstance.cs.meta new file mode 100644 index 00000000000..952ff8f9d54 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxNativeInstance.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 4fd7840bd735d4d2f8025502ba197d37 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxTexture.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxTexture.cs new file mode 100644 index 00000000000..ce1ba161993 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxTexture.cs @@ -0,0 +1,383 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +using System.Threading.Tasks; +using UnityEngine; +using UnityEngine.Experimental.Rendering; +using UnityEngine.Profiling; +using Unity.Collections; +using UnityEngine.Assertions; + +namespace KtxUnity +{ + /// + /// Loads a KTX texture from the StreamingAssets folder, a URL, or a buffer. + /// + public class KtxTexture : TextureBase + { + + KtxNativeInstance m_Ktx; + + // ReSharper disable MemberCanBePrivate.Global + + /// + /// Query if the texture is in a transcodable format. + /// + public bool needsTranscoding => m_Ktx.needsTranscoding; + + /// + /// True if the texture has an alpha channel. + /// + public bool hasAlpha => m_Ktx.hasAlpha; + + /// + /// True if both pixel width and height are a power of two. + /// + public bool isPowerOfTwo => m_Ktx.isPowerOfTwo; + + /// + /// True if both pixel width and height are a multiple of four. + /// + public bool isMultipleOfFour => m_Ktx.isMultipleOfFour; + + /// + /// True if texture is square (width equals height) + /// + public bool isSquare => m_Ktx.isSquare; + + /// + /// Width of largest mipmap level in pixels + /// + public uint baseWidth => m_Ktx.baseWidth; + + /// + /// Height of largest mipmap level in pixels + /// + public uint baseHeight => m_Ktx.baseHeight; + + /// + /// Depth of largest mipmap level in pixels + /// + public uint baseDepth => m_Ktx.baseDepth; + + /// + /// Number of levels + /// + public uint numLevels => m_Ktx.numLevels; + + /// + /// True if texture is of type array + /// + public bool isArray => m_Ktx.isArray; + + /// + /// True if texture is of type cube map + /// + public bool isCubemap => m_Ktx.isCubemap; + + /// + /// True if texture is compressed + /// + public bool isCompressed => m_Ktx.isCompressed; + + /// + /// Number of dimensions + /// + public uint numDimensions => m_Ktx.numDimensions; + + /// + /// Number of layers + /// + public uint numLayers => m_Ktx.numLayers; + + /// + /// Number of faces (e.g. six for cube maps) + /// + public uint numFaces => m_Ktx.numFaces; + + /// + /// Texture's orientation + /// + public TextureOrientation orientation => m_Ktx.orientation; + + // ReSharper restore MemberCanBePrivate.Global + + /// + public override ErrorCode Open(NativeSlice data) + { + KtxNativeInstance.CertifySupportedPlatform(); + return OpenInternal(data); + } + + /// + public override async Task LoadTexture2D( + bool linear = false, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + Assert.IsNotNull(m_Ktx, "KtxTexture in invalid state. Open has to be called first."); + return await LoadTexture2DInternal( + linear, + layer, + faceSlice, + mipLevel, + mipChain); + } + + /// + public override async Task LoadTexture2D( + GraphicsFormat targetFormat, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + Assert.IsNotNull(m_Ktx, "KtxTexture in invalid state. Open has to be called first."); + if (!TranscodeFormatHelper.IsFormatSupported(targetFormat)) + { + return new TextureResult(ErrorCode.FormatUnsupportedBySystem); + } + return await LoadTexture2DInternal( + true, + layer, + faceSlice, + mipLevel, + mipChain, + targetFormat); + } + + internal async Task LoadFromBytesInternal( + NativeSlice data, + bool linear = false, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + var result = new TextureResult + { + errorCode = OpenInternal(data) + }; + if (result.errorCode != ErrorCode.Success) return result; + result = await LoadTexture2DInternal(linear, layer, faceSlice, mipLevel, mipChain); + Dispose(); + return result; + } + + + ErrorCode OpenInternal(NativeSlice data) + { + m_Ktx = new KtxNativeInstance(); + return m_Ktx.Load(data); + } + + async Task LoadTexture2DInternal( + bool linear = false, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true, + GraphicsFormat? targetFormat = null + ) + { + var result = new TextureResult(); + var graphicsFormat = GraphicsFormat.None; + if (m_Ktx.valid) + { + if (m_Ktx.ktxClass == KtxClassId.KtxTexture2) + { + if (m_Ktx.needsTranscoding) + { + + TranscodeFormatTuple? formats; + if (targetFormat.HasValue) + { + formats = TranscodeFormatHelper.GetTranscodeFormats(targetFormat.Value); + } + else + { + // TODO: Maybe do this somewhere more central + TranscodeFormatHelper.Init(); + + formats = GetFormat(m_Ktx, m_Ktx, linear); + } + + if (formats.HasValue) + { + graphicsFormat = formats.Value.format; +#if KTX_VERBOSE + Debug.LogFormat( + "Transcode to GraphicsFormat {0} ({1})", + formats.Value.format, + formats.Value.transcodeFormat + ); +#endif + result.errorCode = await TranscodeInternal( + m_Ktx, + formats.Value.transcodeFormat, + layer, + faceSlice, + mipLevel + ); + result.orientation = m_Ktx.orientation; + } + else + { + result.errorCode = ErrorCode.UnsupportedFormat; + } + } + else + { + graphicsFormat = m_Ktx.graphicsFormat; + if (graphicsFormat == GraphicsFormat.None) + { + result.errorCode = ErrorCode.UnsupportedFormat; + } + else + if (!TranscodeFormatHelper.IsFormatSupported(graphicsFormat, linear)) + { + result.errorCode = ErrorCode.FormatUnsupportedBySystem; + } + } + } + else + { + result.errorCode = ErrorCode.UnsupportedVersion; + } + } + else + { + result.errorCode = ErrorCode.LoadingFailed; + } + + if (result.errorCode != ErrorCode.Success) + { + return result; + } + + Assert.IsTrue(m_Ktx.valid); + Profiler.BeginSample("CreateTexture"); + +#if KTX_UNITY_GPU_UPLOAD + if (SystemInfo.graphicsDeviceType == GraphicsDeviceType.OpenGLCore + || SystemInfo.graphicsDeviceType == GraphicsDeviceType.OpenGLES2 + || SystemInfo.graphicsDeviceType == GraphicsDeviceType.OpenGLES3 + ) + { + m_Ktx.EnqueueForGpuUpload(); + + Texture2D texture; + bool success; + while (!m_Ktx.TryCreateTexture(out texture, out success, m_Format)) { + Profiler.EndSample(); + await Task.Yield(); + } + + if (success) { + return new TextureResult { + texture = texture + }; + } + return new TextureResult(ErrorCode.LoadingFailed); + } +#endif + + try + { + var texture = m_Ktx.LoadTextureData( + graphicsFormat, + layer, + mipLevel, + faceSlice, + mipChain + ); + result.texture = texture; + } + catch (UnityException) + { + result.errorCode = ErrorCode.LoadingFailed; + } + + Profiler.EndSample(); + return result; + } + + /// + public override void Dispose() + { + Assert.IsNotNull(m_Ktx, "KtxTexture in invalid state. Open has to be called first."); + m_Ktx.Unload(); + m_Ktx = null; + } + + internal GraphicsFormat GetGraphicsFormat() + { + if (m_Ktx.valid && m_Ktx.ktxClass == KtxClassId.KtxTexture2 && !m_Ktx.needsTranscoding) + { + return m_Ktx.graphicsFormat; + } + + return GraphicsFormat.None; + } + + async Task TranscodeInternal( + KtxNativeInstance ktx, + TranscodeFormat format, + uint layer, + uint faceSlice, + uint mipLevel + ) + { + + if (layer >= (isArray ? numLayers : 1)) + { + return ErrorCode.InvalidLayer; + } + + if (isCubemap && faceSlice >= numFaces) + { + return ErrorCode.InvalidFace; + } + + if (numDimensions > 2 && faceSlice >= baseDepth) + { + return ErrorCode.InvalidSlice; + } + + if (mipLevel >= numLevels) + { + return ErrorCode.InvalidLevel; + } + + var result = ErrorCode.Success; + + Profiler.BeginSample("KtxTranscode"); + + var job = new KtxTranscodeJob(); + + var jobHandle = ktx.LoadBytesJob(ref job, format); + + Profiler.EndSample(); + + while (!jobHandle.IsCompleted) + { + await Task.Yield(); + } + jobHandle.Complete(); + + if (job.result[0] != KtxErrorCode.Success) + { + result = ErrorCode.TranscodeFailed; + } + job.result.Dispose(); + + return result; + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxTexture.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxTexture.cs.meta new file mode 100644 index 00000000000..624e036574a --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/KtxTexture.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 8cb8df1e5e5cc48098e92c90ca68f2ca +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ManagedNativeArray.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ManagedNativeArray.cs new file mode 100644 index 00000000000..dd8221c5b0f --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ManagedNativeArray.cs @@ -0,0 +1,73 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +using System; +using System.Runtime.InteropServices; +using Unity.Collections; +using Unity.Collections.LowLevel.Unsafe; +using UnityEngine; + +namespace KtxUnity +{ + + /// + /// Wraps a managed byte[] in a NativeArray<byte>without copying memory. + /// + public class ManagedNativeArray : IDisposable + { + + NativeArray m_NativeArray; + GCHandle m_BufferHandle; +#if ENABLE_UNITY_COLLECTIONS_CHECKS + AtomicSafetyHandle m_SafetyHandle; +#endif + bool m_Pinned; + + /// + /// Wraps a managed byte[] in a NativeArray<byte>without copying memory. + /// + /// The original byte[] to convert into a NativeArray<byte> + public unsafe ManagedNativeArray(byte[] original) + { + if (original != null) + { + m_BufferHandle = GCHandle.Alloc(original, GCHandleType.Pinned); + fixed (void* bufferAddress = &original[0]) + { + m_NativeArray = NativeArrayUnsafeUtility.ConvertExistingDataToNativeArray(bufferAddress, original.Length, Allocator.None); +#if ENABLE_UNITY_COLLECTIONS_CHECKS + m_SafetyHandle = AtomicSafetyHandle.Create(); + NativeArrayUnsafeUtility.SetAtomicSafetyHandle(array: ref m_NativeArray, m_SafetyHandle); +#endif + } + + m_Pinned = true; + } + else + { + m_NativeArray = new NativeArray(); + } + } + + /// + /// Points to the managed NativeArray<byte>. + /// + public NativeArray nativeArray => m_NativeArray; + + + /// + /// Disposes the managed NativeArray<byte>. + /// + public void Dispose() + { + if (m_Pinned) + { +#if ENABLE_UNITY_COLLECTIONS_CHECKS + AtomicSafetyHandle.Release(m_SafetyHandle); +#endif + m_BufferHandle.Free(); + } + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ManagedNativeArray.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ManagedNativeArray.cs.meta new file mode 100644 index 00000000000..7d4d845e22e --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/ManagedNativeArray.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 5ef690288d96e4b4ba65d86f9ff558ad +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/MetaData.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/MetaData.cs new file mode 100644 index 00000000000..1bedef6e317 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/MetaData.cs @@ -0,0 +1,73 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +namespace KtxUnity +{ + interface IMetaData + { + bool hasAlpha { get; } + } + + interface ILevelInfo + { + bool isPowerOfTwo { get; } + bool isMultipleOfFour { get; } + bool isSquare { get; } + } + + class MetaData : IMetaData + { + public bool hasAlpha { get; set; } + + public ImageInfo[] images; + + public void GetSize(out uint width, out uint height, uint imageIndex = 0, uint levelIndex = 0) + { + var level = images[imageIndex].levels[levelIndex]; + width = level.width; + height = level.height; + } + + public override string ToString() + { + return $"BU images:{images.Length} A:{hasAlpha}"; + } + } + + class ImageInfo + { + public LevelInfo[] levels; + public override string ToString() + { + return $"Image levels:{levels.Length}"; + } + } + + class LevelInfo : ILevelInfo + { + public uint width; + public uint height; + + public static bool IsPowerOfTwo(uint i) + { + return (i & (i - 1)) == 0; + } + + public static bool IsMultipleOfFour(uint i) + { + return (i & 0x3) == 0; + } + + public bool isPowerOfTwo => IsPowerOfTwo(width) && IsPowerOfTwo(height); + + public bool isMultipleOfFour => IsMultipleOfFour(width) && IsMultipleOfFour(height); + + public bool isSquare => width == height; + + public override string ToString() + { + return $"Level size {width} x {height}"; + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/MetaData.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/MetaData.cs.meta new file mode 100644 index 00000000000..d8f0c4bd709 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/MetaData.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: b1ebb68e718c148a08e6167dcf2de772 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureBase.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureBase.cs new file mode 100644 index 00000000000..81e9f465d83 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureBase.cs @@ -0,0 +1,390 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +#if !(UNITY_ANDROID || UNITY_WEBGL) || UNITY_EDITOR +#define LOCAL_LOADING +#endif + +using System.IO; +using System.Threading.Tasks; +using UnityEngine; +using UnityEngine.Experimental.Rendering; +using UnityEngine.Networking; +using Unity.Collections; + +namespace KtxUnity +{ + /// + /// Loads a KTX or Basis Universal texture from the StreamingAssets folder, a URL, or a buffer. + /// + public abstract class TextureBase + { + /// + /// Loads a KTX or Basis Universal texture from the StreamingAssets folder + /// see https://docs.unity3d.com/Manual/StreamingAssets.html + /// + /// Path to the file, relative to StreamingAssets + /// Depicts if texture is sampled in linear or + /// sRGB gamma color space. + /// Texture array layer to import + /// Cubemap face or 3D/volume texture slice to import. + /// Lowest mipmap level to import (where 0 is + /// the highest resolution). Lower mipmap levels (of higher resolution) + /// are being discarded. Useful to limit texture resolution. + /// If true, a mipmap chain (if present) is imported. + /// A that contains an + /// , the resulting texture and its orientation. + /// + public async Task LoadFromStreamingAssets( + string filePath, + bool linear = false, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + var url = GetStreamingAssetsUrl(filePath); + return await LoadFile(url, linear, layer, faceSlice, mipLevel, mipChain); + } + + /// + /// Loads a KTX or Basis Universal texture from the StreamingAssets folder + /// see https://docs.unity3d.com/Manual/StreamingAssets.html + /// + /// Path to the file, relative to StreamingAssets + /// Desired texture format + /// Texture array layer to import + /// Cubemap face or 3D/volume texture slice to import. + /// Lowest mipmap level to import (where 0 is + /// the highest resolution). Lower mipmap levels (of higher resolution) + /// are being discarded. Useful to limit texture resolution. + /// If true, a mipmap chain (if present) is imported. + /// A that contains an + /// , the resulting texture and its orientation. + /// + public async Task LoadFromStreamingAssets( + string filePath, + GraphicsFormat targetFormat, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + var url = GetStreamingAssetsUrl(filePath); + return await LoadFile(url, targetFormat, layer, faceSlice, mipLevel, mipChain); + } + + /// + /// Loads a KTX or Basis Universal texture from a URL + /// + /// URL to the ktx/basis file to load + /// Depicts if texture is sampled in linear or + /// sRGB gamma color space. + /// Texture array layer to import + /// Cubemap face or 3D/volume texture slice to import. + /// Lowest mipmap level to import (where 0 is + /// the highest resolution). Lower mipmap levels (of higher resolution) + /// are being discarded. Useful to limit texture resolution. + /// If true, a mipmap chain (if present) is imported. + /// A that contains an + /// , the resulting texture and its orientation. + /// + public async Task LoadFromUrl( + string url, + bool linear = false, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + return await LoadFile(url, linear, layer, faceSlice, mipLevel, mipChain); + } + + /// + /// Loads a KTX or Basis Universal texture from a URL + /// + /// URL to the ktx/basis file to load + /// Desired texture format + /// Texture array layer to import + /// Cubemap face or 3D/volume texture slice to import. + /// Lowest mipmap level to import (where 0 is + /// the highest resolution). Lower mipmap levels (of higher resolution) + /// are being discarded. Useful to limit texture resolution. + /// If true, a mipmap chain (if present) is imported. + /// A that contains an + /// , the resulting texture and its orientation. + /// + public async Task LoadFromUrl( + string url, + GraphicsFormat targetFormat, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + return await LoadFile(url, targetFormat, layer, faceSlice, mipLevel, mipChain); + } + + /// + /// Loads a KTX or Basis Universal texture from a buffer + /// + /// Native buffer that holds the ktx/basis file + /// Depicts if texture is sampled in linear or + /// sRGB gamma color space. + /// Texture array layer to import + /// Cubemap face or 3D/volume texture slice to import. + /// Lowest mipmap level to import (where 0 is + /// the highest resolution). Lower mipmap levels (of higher resolution) + /// are being discarded. Useful to limit texture resolution. + /// If true, a mipmap chain (if present) is imported. + /// A that contains an + /// , the resulting texture and its orientation. + /// + public async Task LoadFromBytes( + NativeSlice data, + bool linear = false, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + KtxNativeInstance.CertifySupportedPlatform(); + var result = new TextureResult + { + errorCode = Open(data) + }; + if (result.errorCode != ErrorCode.Success) return result; + result = await LoadTexture2D(linear, layer, faceSlice, mipLevel, mipChain); + Dispose(); + return result; + } + + /// + /// Loads a KTX or Basis Universal texture from a buffer + /// + /// Native buffer that holds the ktx/basis file + /// Desired texture format + /// Texture array layer to import + /// Cubemap face or 3D/volume texture slice to import. + /// Lowest mipmap level to import (where 0 is + /// the highest resolution). Lower mipmap levels (of higher resolution) + /// are being discarded. Useful to limit texture resolution. + /// If true, a mipmap chain (if present) is imported. + /// A that contains an + /// , the resulting texture and its orientation. + /// + // ReSharper disable once MemberCanBePrivate.Global + public async Task LoadFromBytes( + NativeSlice data, + GraphicsFormat targetFormat, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + KtxNativeInstance.CertifySupportedPlatform(); + var result = new TextureResult + { + errorCode = Open(data) + }; + if (result.errorCode != ErrorCode.Success) return result; + result = await LoadTexture2D(targetFormat, layer, faceSlice, mipLevel, mipChain); + Dispose(); + return result; + } + + /// + /// Converts a relative sub path within StreamingAssets + /// and creates an absolute URI from it. Useful for loading + /// via UnityWebRequests. + /// + /// Path, relative to StreamingAssets. Example: path/to/file.ktx + /// Platform independent URI that can be loaded via UnityWebRequest + public static string GetStreamingAssetsUrl(string subPath) + { + + var path = Path.Combine(Application.streamingAssetsPath, subPath); + +#if LOCAL_LOADING + path = $"file://{path}"; +#endif + + return path; + } + + #region LowLevelAPI + + /// + /// Loads a texture from memory. + /// Part of the low-level API that provides finer control over the + /// loading process. + /// + /// + /// + /// + /// Input texture data + /// if loading was successful + /// or an error specific code otherwise. + public abstract ErrorCode Open(NativeSlice data); + + /// + /// Creates a from the previously opened + /// texture. + /// Transcodes or decodes the texture into a GPU compatible format + /// (if required) and uploads it to GPU memory. + /// Part of the low-level API that provides finer control over the + /// loading process. + /// + /// + /// + /// Depicts if texture is sampled in linear or + /// sRGB gamma color space. + /// Texture array layer to import + /// Cubemap face or 3D/volume texture slice to import. + /// Lowest mipmap level to import (where 0 is + /// the highest resolution). Lower mipmap levels (of higher resolution) + /// are being discarded. Useful to limit texture resolution. + /// If true, a mipmap chain (if present) is imported. + /// A that contains an + /// , the resulting texture and its orientation. + /// + public abstract Task LoadTexture2D( + bool linear = false, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ); + + /// + /// Creates a from the previously opened + /// texture. + /// Transcodes or decodes the texture into a desired GPU compatible format + /// (if required) and uploads it to GPU memory. + /// Part of the low-level API that provides finer control over the + /// loading process. + /// + /// + /// + /// Desired texture format + /// Texture array layer to import + /// Cubemap face or 3D/volume texture slice to import. + /// Lowest mipmap level to import (where 0 is + /// the highest resolution). Lower mipmap levels (of higher resolution) + /// are being discarded. Useful to limit texture resolution. + /// If true, a mipmap chain (if present) is imported. + /// A that contains an + /// , the resulting texture and its orientation. + /// + public abstract Task LoadTexture2D( + GraphicsFormat targetFormat, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ); + + /// + /// Releases all resources. + /// Part of the low-level API that provides finer control over the + /// loading process. + /// + /// + /// + /// + /// + public abstract void Dispose(); + + #endregion + + async Task LoadFile( + string url, + bool linear = false, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + var webRequest = UnityWebRequest.Get(url); + var asyncOp = webRequest.SendWebRequest(); + while (!asyncOp.isDone) + { + await Task.Yield(); + } + + if (!string.IsNullOrEmpty(webRequest.error)) + { +#if DEBUG + Debug.LogErrorFormat("Error loading {0}: {1}",url,webRequest.error); +#endif + return new TextureResult(ErrorCode.OpenUriFailed); + } + + var buffer = webRequest.downloadHandler.data; + + using (var bufferWrapped = new ManagedNativeArray(buffer)) + { + return await LoadFromBytes( + bufferWrapped.nativeArray, + linear, + layer, + faceSlice, + mipLevel, + mipChain + ); + } + } + + async Task LoadFile( + string url, + GraphicsFormat targetFormat, + uint layer = 0, + uint faceSlice = 0, + uint mipLevel = 0, + bool mipChain = true + ) + { + var webRequest = UnityWebRequest.Get(url); + var asyncOp = webRequest.SendWebRequest(); + while (!asyncOp.isDone) + { + await Task.Yield(); + } + + if (!string.IsNullOrEmpty(webRequest.error)) + { +#if DEBUG + Debug.LogErrorFormat("Error loading {0}: {1}",url,webRequest.error); +#endif + return new TextureResult(ErrorCode.OpenUriFailed); + } + + var buffer = webRequest.downloadHandler.data; + + using (var bufferWrapped = new ManagedNativeArray(buffer)) + { + return await LoadFromBytes( + bufferWrapped.nativeArray, + targetFormat, + layer, + faceSlice, + mipLevel, + mipChain + ); + } + } + + internal static TranscodeFormatTuple? GetFormat(IMetaData meta, ILevelInfo li, bool linear = false) + { + return TranscodeFormatHelper.GetFormatsForImage(meta, li, linear); + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureBase.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureBase.cs.meta new file mode 100644 index 00000000000..b6c27990241 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureBase.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: ae19b72e83f1a49e4a5538ef5d6aba1f +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureOrientation.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureOrientation.cs new file mode 100644 index 00000000000..08a978e9a2e --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureOrientation.cs @@ -0,0 +1,65 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + +namespace KtxUnity +{ + + /// + /// See Section 5.2 in https://registry.khronos.org/KTX/specs/2.0/ktxspec.v2.html#_ktxorientation + /// + [System.Flags] + public enum TextureOrientation + { + /// + /// KTX defaults to X=right Y=down Z=out + /// + KtxDefault = 0x0, + /// + /// If present X=left, else X=right + /// + XLeft = 0x1, + /// + /// If present Y=up, else Y=down + /// + YUp = 0x2, + /// + /// If present Z=in, else Z=out + /// + ZIn = 0x4, // Not used at the moment + /// + /// Unity expects GPU textures to be X=right Y=up + /// + UnityDefault = YUp, + } + + /// + /// Extensions to check if a texture's orientation conforms to Unity's default. + /// + public static class TextureOrientationExtension + { + + /// + /// Evaluates if the texture's horizontal orientation conforms to Unity's default. + /// If it's not aligned (=true; =flipped), the texture has to be applied mirrored horizontally. + /// + /// + /// True if the horizontal orientation is flipped, false otherwise + public static bool IsXFlipped(this TextureOrientation to) + { + // Unity default == X_RIGHT + return (to & TextureOrientation.XLeft) != 0; + } + + /// + /// Evaluates if the texture's vertical orientation conforms to Unity's default. + /// If it's not aligned (=true; =flipped), the texture has to be applied mirrored vertically. + /// + /// + /// True if the vertical orientation is flipped, false otherwise + public static bool IsYFlipped(this TextureOrientation to) + { + // Unity default == Y_UP + return (to & TextureOrientation.YUp) == 0; + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureOrientation.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureOrientation.cs.meta new file mode 100644 index 00000000000..610d95274fa --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureOrientation.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 416210fff7cbe4c8698f2b4f845288d8 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureResult.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureResult.cs new file mode 100644 index 00000000000..d6d584b0b9d --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureResult.cs @@ -0,0 +1,53 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + +using UnityEngine; + +namespace KtxUnity +{ + + /// + /// TextureResult encapsulates result of texture loading. The texture itself and its orientation. + /// + public class TextureResult + { + /// + /// The successfully imported . + /// + public Texture2D texture; + /// + /// The of the imported texture. + /// + public TextureOrientation orientation; + /// + /// The from the failed texture import. + /// + public ErrorCode errorCode = ErrorCode.Success; + + /// + /// Creates an empty . + /// + public TextureResult() { } + + /// + /// Creates an invalid with an . + /// + /// The from the failed texture import. + public TextureResult(ErrorCode errorCode) + { + this.errorCode = errorCode; + } + + /// + /// Creates a successful with a + /// and a . + /// + /// The successfully imported . + /// The of the imported texture. + public TextureResult(Texture2D texture, TextureOrientation orientation) + { + this.texture = texture; + this.orientation = orientation; + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureResult.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureResult.cs.meta new file mode 100644 index 00000000000..a9084776b8b --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TextureResult.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: be50f6bd8e9f54503b19b8dc700df383 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormat.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormat.cs new file mode 100644 index 00000000000..a237e119545 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormat.cs @@ -0,0 +1,52 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +namespace KtxUnity +{ + + // source: C++ enum ktx_transcode_fmt_e; ktx.h + enum TranscodeFormat : uint + { + // Compressed formats + + // ETC1-2 + ETC1_RGB = 0, // Opaque only, returns RGB or alpha data if cDecodeFlagsTranscodeAlphaDataToOpaqueFormats flag is specified + ETC2_RGBA = 1, // Opaque+alpha, ETC2_EAC_A8 block followed by a ETC1 block, alpha channel will be opaque for opaque .basis files + + // BC1-5, BC7 (desktop, some mobile devices) + BC1_RGB = 2, // Opaque only, no punchthrough alpha support yet, transcodes alpha slice if cDecodeFlagsTranscodeAlphaDataToOpaqueFormats flag is specified + BC3_RGBA = 3, // Opaque+alpha, BC4 followed by a BC1 block, alpha channel will be opaque for opaque .basis files + BC4_R = 4, // Red only, alpha slice is transcoded to output if cDecodeFlagsTranscodeAlphaDataToOpaqueFormats flag is specified + BC5_RG = 5, // XY: Two BC4 blocks, X=R and Y=Alpha, .basis file should have alpha data (if not Y will be all 255's) + BC7_RGBA = 6, // !< RGB or RGBA mode 5 for ETC1S, modes 1, 2, 3, 4, 5, 6, 7 for UASTC. + + // PVRTC1 4bpp (mobile, PowerVR devices) + PVRTC1_4_RGB = 8, // Opaque only, RGB or alpha if cDecodeFlagsTranscodeAlphaDataToOpaqueFormats flag is specified, nearly lowest quality of any texture format. + PVRTC1_4_RGBA = 9, // Opaque+alpha, most useful for simple opacity maps. If .basis file doens't have alpha PVRTC1_4_RGB will be used instead. Lowest quality of any supported texture format. + + // ASTC (mobile, Intel devices, hopefully all desktop GPU's one day) + ASTC_4x4_RGBA = 10, // Opaque+alpha, ASTC 4x4, alpha channel will be opaque for opaque .basis files. Transcoder uses RGB/RGBA/L/LA modes, void extent, and up to two ([0,47] and [0,255]) endpoint precisions. + + // ATC (mobile, Adreno devices, this is a niche format) + ATC_RGB = 11, // Opaque, RGB or alpha if cDecodeFlagsTranscodeAlphaDataToOpaqueFormats flag is specified. ATI ATC (GL_ATC_RGB_AMD) + ATC_RGBA = 12, // Opaque+alpha, alpha channel will be opaque for opaque .basis files. ATI ATC (GL_ATC_RGBA_INTERPOLATED_ALPHA_AMD) + + // FXT1 (desktop, Intel devices, this is a super obscure format) + FXT1_RGB = 17, // Opaque only, uses exclusively CC_MIXED blocks. Notable for having a 8x4 block size. GL_3DFX_texture_compression_FXT1 is supported on Intel integrated GPU's (such as HD 630). + // Punch-through alpha is relatively easy to support, but full alpha is harder. This format is only here for completeness so opaque-only is fine for now. + // See the BASISU_USE_ORIGINAL_3DFX_FXT1_ENCODING macro in basisu_transcoder_internal.h. + + PVRTC2_4_RGB = 18, // Opaque-only, almost BC1 quality, much faster to transcode and supports arbitrary texture dimensions (unlike PVRTC1 RGB). + PVRTC2_4_RGBA = 19, // Opaque+alpha, slower to encode than PVRTC2_4_RGB. Premultiplied alpha is highly recommended, otherwise the color channel can leak into the alpha channel on transparent blocks. + + ETC2_EAC_R11 = 20, // R only (ETC2 EAC R11 unsigned) + ETC2_EAC_RG11 = 21, // RG only (ETC2 EAC RG11 unsigned), R=opaque.r, G=alpha - for tangent space normal maps + + // Uncompressed (raw pixel) formats + RGBA32 = 13, // 32bpp RGBA image stored in raster (not block) order in memory, R is first byte, A is last byte. + RGB565 = 14, // 166pp RGB image stored in raster (not block) order in memory, R at bit position 11 + BGR565 = 15, // 16bpp RGB image stored in raster (not block) order in memory, R at bit position 0 + RGBA4444 = 16, // 16bpp RGBA image stored in raster (not block) order in memory, R at bit position 12, A at bit position 0 + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormat.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormat.cs.meta new file mode 100644 index 00000000000..81ec3f0367a --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormat.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 1aef19a254e704b30a9770ae61c38352 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormatHelper.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormatHelper.cs new file mode 100644 index 00000000000..2da14189d85 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormatHelper.cs @@ -0,0 +1,537 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +using System; +using System.Collections.Generic; +using UnityEngine; +using UnityEngine.Experimental.Rendering; +#if KTX_VERBOSE +using System.Text; +using Enum = System.Enum; +#endif + +namespace KtxUnity +{ + + /// + /// Mask of texture features + /// + [Flags] + enum TextureFeatures + { + None = 0x0, + + /// + /// Format with 4 channels (RGB+Alpha) + /// + AlphaChannel = 0x1, + + /// + /// Format supports arbitrary resolutions + /// + NonPowerOfTwo = 0x2, + + /// + /// Format supports arbitrary resolutions + /// + NonMultipleOfFour = 0x4, + + /// + /// Non square resolution + /// + NonSquare = 0x8, + + /// + /// Linear value encoding (not sRGB) + /// + Linear = 0x10 + } + + struct TranscodeFormatTuple + { + public GraphicsFormat format; + public TranscodeFormat transcodeFormat; + + public TranscodeFormatTuple(GraphicsFormat format, TranscodeFormat transcodeFormat) + { + this.format = format; + this.transcodeFormat = transcodeFormat; + } + } + + struct FormatInfo + { + public TextureFeatures features; + public TranscodeFormatTuple formats; + + public FormatInfo(TextureFeatures features, GraphicsFormat format, TranscodeFormat transcodeFormat) + { + this.features = features; + this.formats = new TranscodeFormatTuple(format, transcodeFormat); + } + } + + static class TranscodeFormatHelper + { + static bool s_Initialized; + static Dictionary s_FormatCache; + static List s_AllFormats; + + static void InitInternal() + { + s_Initialized = true; + s_FormatCache = new Dictionary(); + + if (s_AllFormats == null) + { + + s_AllFormats = new List(); + + // Add all formats into the List ordered. First supported match will be used. + // This particular order is based on memory size (1st degree) + // and a combination of quality and transcode speed (2nd degree) + // source + + // Compressed + s_AllFormats.Add(new FormatInfo( + TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare, + GraphicsFormat.RGB_ETC2_SRGB, + TranscodeFormat.ETC1_RGB)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare | TextureFeatures.Linear, + GraphicsFormat.RGB_ETC_UNorm, + TranscodeFormat.ETC1_RGB)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare, +#if UNITY_2018_3_OR_NEWER + GraphicsFormat.RGBA_DXT1_SRGB, +#else + GraphicsFormat.RGB_DXT1_SRGB, +#endif + TranscodeFormat.BC1_RGB)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare | TextureFeatures.Linear, +#if UNITY_2018_3_OR_NEWER + GraphicsFormat.RGBA_DXT1_UNorm, +#else + GraphicsFormat.RGB_DXT1_UNorm, +#endif + TranscodeFormat.BC1_RGB)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.NonMultipleOfFour, + GraphicsFormat.RGB_PVRTC_4Bpp_SRGB, + TranscodeFormat.PVRTC1_4_RGB)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.NonMultipleOfFour, + GraphicsFormat.RGB_PVRTC_4Bpp_UNorm, + TranscodeFormat.PVRTC1_4_RGB)); + + // Compressed with alpha channel + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonMultipleOfFour | TextureFeatures.NonSquare, + GraphicsFormat.RGBA_ASTC4X4_SRGB, + TranscodeFormat.ASTC_4x4_RGBA)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonMultipleOfFour | TextureFeatures.NonSquare | TextureFeatures.Linear, + GraphicsFormat.RGBA_ASTC4X4_UNorm, + TranscodeFormat.ASTC_4x4_RGBA)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare, + GraphicsFormat.RGBA_ETC2_SRGB, + TranscodeFormat.ETC2_RGBA)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare | TextureFeatures.Linear, + GraphicsFormat.RGBA_ETC2_UNorm, + TranscodeFormat.ETC2_RGBA)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare, + GraphicsFormat.RGBA_BC7_SRGB, + TranscodeFormat.BC7_RGBA)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare | TextureFeatures.Linear, + GraphicsFormat.RGBA_BC7_UNorm, + TranscodeFormat.BC7_RGBA)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare, + GraphicsFormat.RGBA_DXT5_SRGB, + TranscodeFormat.BC3_RGBA)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare | TextureFeatures.Linear, + GraphicsFormat.RGBA_DXT5_UNorm, + TranscodeFormat.BC3_RGBA)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonMultipleOfFour, + GraphicsFormat.RGBA_PVRTC_4Bpp_SRGB, + TranscodeFormat.PVRTC1_4_RGBA)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.Linear | TextureFeatures.NonMultipleOfFour, + GraphicsFormat.RGBA_PVRTC_4Bpp_UNorm, + TranscodeFormat.PVRTC1_4_RGBA)); + + // Uncompressed + s_AllFormats.Add(new FormatInfo( + TextureFeatures.NonPowerOfTwo | TextureFeatures.NonMultipleOfFour | TextureFeatures.NonSquare | TextureFeatures.Linear, + GraphicsFormat.R5G6B5_UNormPack16, + TranscodeFormat.RGB565)); + + // Uncompressed with alpha channel + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonMultipleOfFour | TextureFeatures.NonSquare, + GraphicsFormat.R8G8B8A8_SRGB, // Also supports SNorm, UInt, SInt + TranscodeFormat.RGBA32)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonMultipleOfFour | TextureFeatures.NonSquare | TextureFeatures.Linear, + GraphicsFormat.R8G8B8A8_UNorm, // Also supports SNorm, UInt, SInt + TranscodeFormat.RGBA32)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonMultipleOfFour | TextureFeatures.NonSquare | TextureFeatures.Linear, + GraphicsFormat.R4G4B4A4_UNormPack16, + TranscodeFormat.RGBA4444)); + + // Need to extend TextureFeatures to request single/dual channel texture formats. + // Until then, those formats are at the end of the list + s_AllFormats.Add(new FormatInfo( + TextureFeatures.NonPowerOfTwo | TextureFeatures.NonMultipleOfFour | TextureFeatures.NonSquare | TextureFeatures.Linear, + GraphicsFormat.B5G6R5_UNormPack16, + TranscodeFormat.BGR565)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare | TextureFeatures.Linear, + GraphicsFormat.R_EAC_UNorm, // Also supports SNorm + TranscodeFormat.ETC2_EAC_R11)); + + s_AllFormats.Add(new FormatInfo( + TextureFeatures.AlphaChannel | TextureFeatures.NonPowerOfTwo | TextureFeatures.NonSquare | TextureFeatures.Linear, + GraphicsFormat.RG_EAC_UNorm, // Also supports SNorm + TranscodeFormat.ETC2_EAC_RG11)); + + // GraphicsFormat.RGB_A1_ETC2_SRGB,TranscodeFormat.ETC2_RGBA // Does not work; always transcodes 8-bit alpha + // GraphicsFormat.RGBA_ETC2_SRGB,TranscodeFormat.ATC_RGBA // Not sure if this works (maybe compatible) - untested + // GraphicsFormat.RGB_ETC_UNorm,ATC_RGB // Not sure if this works (maybe compatible) - untested + + // Not supported via KTX atm + // GraphicsFormat.R_BC4_UNorm,TranscodeFormat.BC4_R + // GraphicsFormat.RG_BC5_UNorm,TranscodeFormat.BC5_RG + + // Supported by BasisU, but no matching Unity GraphicsFormat + // GraphicsFormat.?,TranscodeFormat.ATC_RGB + // GraphicsFormat.?,TranscodeFormat.ATC_RGBA + // GraphicsFormat.?,TranscodeFormat.FXT1_RGB + // GraphicsFormat.?,TranscodeFormat.PVRTC2_4_RGB + // GraphicsFormat.?,TranscodeFormat.PVRTC2_4_RGBA + } + } + + public static void Init() + { + if (!s_Initialized) + { + InitInternal(); +#if KTX_VERBOSE + CheckTextureSupport(); +#endif + } + } + + internal static TranscodeFormatTuple? GetFormatsForImage( + IMetaData meta, + ILevelInfo li, + bool linear = false + ) + { + var formats = TranscodeFormatHelper.GetPreferredFormat( + meta.hasAlpha, + li.isPowerOfTwo, + li.isMultipleOfFour, + li.isSquare, + linear + ); + + if (!formats.HasValue && meta.hasAlpha) + { + // Fall back to transcode RGB-only to RGBA texture + formats = TranscodeFormatHelper.GetPreferredFormat( + false, + li.isPowerOfTwo, + li.isMultipleOfFour, + li.isSquare, + linear + ); + } + return formats; + } + + public static TranscodeFormatTuple? GetPreferredFormat( + bool hasAlpha, + bool isPowerOfTwo, + bool isMultipleOfFour, + bool isSquare, + bool isLinear = false + ) + { + TextureFeatures features = TextureFeatures.None; + if (hasAlpha) + { + features |= TextureFeatures.AlphaChannel; + } + if (!isPowerOfTwo) + { + features |= TextureFeatures.NonPowerOfTwo; + } + if (!isMultipleOfFour) + { + features |= TextureFeatures.NonMultipleOfFour; + } + if (!isSquare) + { + features |= TextureFeatures.NonSquare; + } + if (isLinear) + { + features |= TextureFeatures.Linear; + } + + if (s_FormatCache.TryGetValue(features, out var formatTuple)) + { + return formatTuple; + } + else + { + foreach (var formatInfo in s_AllFormats) + { + if (!FormatIsMatch(features, formatInfo.features)) + { + continue; + } + var supported = IsFormatSupported(formatInfo.formats.format, isLinear); + if (supported) + { + s_FormatCache[features] = formatInfo.formats; + return formatInfo.formats; + } + } +#if DEBUG + Debug.LogErrorFormat("Could not find transcode texture format! (alpha:{0} Po2:{1} sqr:{2})",hasAlpha,isPowerOfTwo,isSquare); +#endif + return null; + } + } + + /// + /// Takes a desired target format and returns a fitting , if one was found. + /// + /// Desired target texture format + /// A fitting , if one was found. False otherwise. + internal static TranscodeFormatTuple? GetTranscodeFormats(GraphicsFormat graphicsFormat) + { + TranscodeFormat? tf; + switch (graphicsFormat) + { + case GraphicsFormat.RGB_ETC_UNorm: + case GraphicsFormat.RGB_ETC2_SRGB: + case GraphicsFormat.RGB_ETC2_UNorm: + tf = TranscodeFormat.ETC1_RGB; + break; + case GraphicsFormat.RGBA_DXT1_SRGB: + case GraphicsFormat.RGBA_DXT1_UNorm: + tf = TranscodeFormat.BC1_RGB; + break; + case GraphicsFormat.RGBA_DXT5_SRGB: + case GraphicsFormat.RGBA_DXT5_UNorm: + tf = TranscodeFormat.BC3_RGBA; + break; + case GraphicsFormat.RG_BC5_UNorm: + case GraphicsFormat.RG_BC5_SNorm: + tf = TranscodeFormat.BC5_RG; + break; + case GraphicsFormat.R_BC4_UNorm: + case GraphicsFormat.R_BC4_SNorm: + tf = TranscodeFormat.BC4_R; + break; + case GraphicsFormat.RGBA_BC7_SRGB: + case GraphicsFormat.RGBA_BC7_UNorm: + tf = TranscodeFormat.BC7_RGBA; + break; + + // // RGB formats are untested. + // case GraphicsFormat.B8G8R8_SInt: + // case GraphicsFormat.B8G8R8_SNorm: + // case GraphicsFormat.B8G8R8_SRGB: + // case GraphicsFormat.B8G8R8_UInt: + // case GraphicsFormat.B8G8R8_UNorm: + // case GraphicsFormat.R8G8B8_SInt: + // case GraphicsFormat.R8G8B8_SNorm: + // case GraphicsFormat.R8G8B8_SRGB: + // case GraphicsFormat.R8G8B8_UInt: + // case GraphicsFormat.R8G8B8_UNorm: + // tf = TranscodeFormat.RGBA32; + // break; + + case GraphicsFormat.B8G8R8A8_SInt: + case GraphicsFormat.B8G8R8A8_SNorm: + case GraphicsFormat.B8G8R8A8_SRGB: + case GraphicsFormat.B8G8R8A8_UInt: + case GraphicsFormat.B8G8R8A8_UNorm: + case GraphicsFormat.R8G8B8A8_SInt: + case GraphicsFormat.R8G8B8A8_SNorm: + case GraphicsFormat.R8G8B8A8_SRGB: + case GraphicsFormat.R8G8B8A8_UInt: + case GraphicsFormat.R8G8B8A8_UNorm: + tf = TranscodeFormat.RGBA32; + break; + case GraphicsFormat.B5G6R5_UNormPack16: + case GraphicsFormat.R5G6B5_UNormPack16: + tf = TranscodeFormat.BGR565; + break; + case GraphicsFormat.B4G4R4A4_UNormPack16: + case GraphicsFormat.R4G4B4A4_UNormPack16: + tf = TranscodeFormat.RGBA4444; + break; + case GraphicsFormat.RGBA_ASTC4X4_SRGB: +#if UNITY_2020_2_OR_NEWER + case GraphicsFormat.RGBA_ASTC4X4_UFloat: +#endif + case GraphicsFormat.RGBA_ASTC4X4_UNorm: + tf = TranscodeFormat.ASTC_4x4_RGBA; + break; + case GraphicsFormat.RGBA_ETC2_SRGB: + case GraphicsFormat.RGBA_ETC2_UNorm: + tf = TranscodeFormat.ETC2_RGBA; + break; + case GraphicsFormat.RGBA_PVRTC_4Bpp_SRGB: + case GraphicsFormat.RGBA_PVRTC_4Bpp_UNorm: + tf = TranscodeFormat.PVRTC1_4_RGBA; + break; + case GraphicsFormat.RGB_PVRTC_4Bpp_SRGB: + case GraphicsFormat.RGB_PVRTC_4Bpp_UNorm: + tf = TranscodeFormat.PVRTC1_4_RGB; + break; + case GraphicsFormat.R_EAC_SNorm: + case GraphicsFormat.R_EAC_UNorm: + tf = TranscodeFormat.ETC2_EAC_R11; + break; + case GraphicsFormat.RG_EAC_SNorm: + case GraphicsFormat.RG_EAC_UNorm: + tf = TranscodeFormat.ETC2_EAC_RG11; + break; + default: + return null; + } + + return new TranscodeFormatTuple(graphicsFormat, tf.Value); + } + + static bool FormatIsMatch(TextureFeatures required, TextureFeatures provided) + { + return (required & provided) == required; + } + + internal static bool IsFormatSupported(GraphicsFormat graphicsFormat, bool linear = false) + { + return SystemInfo.IsFormatSupported( + graphicsFormat, +#if UNITY_2023_2_OR_NEWER + linear ? GraphicsFormatUsage.Linear : GraphicsFormatUsage.Sample +#else + linear ? FormatUsage.Linear : FormatUsage.Sample +#endif + ); + } + +#if KTX_VERBOSE + // ReSharper disable Unity.PerformanceAnalysis + static void CheckTextureSupport () { + // Dummy call to force logging all supported formats to console + GetSupportedTextureFormats(out _); + } + + static void GetSupportedTextureFormats ( + out List graphicsFormats + ) + { + graphicsFormats = new List(); + + var sb = new StringBuilder(); + foreach(var formatInfo in s_AllFormats) { + var supported = IsFormatSupported(formatInfo.formats.format); + if(supported) { + graphicsFormats.Add(formatInfo.formats); + } + sb.AppendFormat("{0} support: {1}\n",formatInfo.formats.format,supported); + } + + Debug.Log(sb.ToString()); + + sb.Clear(); + + var allGfxFormats = (GraphicsFormat[]) Enum.GetValues(typeof(GraphicsFormat)); + foreach(var format in allGfxFormats) { + sb.Append(format).Append(' '); + var usages = new[] + { +#if UNITY_2023_2_OR_NEWER + GraphicsFormatUsage.Sample, + GraphicsFormatUsage.Blend, + GraphicsFormatUsage.GetPixels, + GraphicsFormatUsage.Linear, + GraphicsFormatUsage.LoadStore, + GraphicsFormatUsage.MSAA2x, + GraphicsFormatUsage.MSAA4x, + GraphicsFormatUsage.MSAA8x, + GraphicsFormatUsage.ReadPixels, + GraphicsFormatUsage.Render, + GraphicsFormatUsage.SetPixels, + GraphicsFormatUsage.SetPixels32, + GraphicsFormatUsage.Sparse, + GraphicsFormatUsage.StencilSampling, +#else + FormatUsage.Sample, + FormatUsage.Blend, + FormatUsage.GetPixels, + FormatUsage.Linear, + FormatUsage.LoadStore, + FormatUsage.MSAA2x, + FormatUsage.MSAA4x, + FormatUsage.MSAA8x, + FormatUsage.ReadPixels, + FormatUsage.Render, + FormatUsage.SetPixels, + FormatUsage.SetPixels32, + FormatUsage.Sparse, + FormatUsage.StencilSampling, +#endif + }; + foreach (var usage in usages) + { + sb + .Append(usage) + .Append(':') + .Append(SystemInfo.IsFormatSupported(format, usage) ? "1" : "0") + .Append(' '); + } + + sb.Append('\n'); + } + + Debug.Log(sb.ToString()); + } +#endif + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormatHelper.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormatHelper.cs.meta new file mode 100644 index 00000000000..a14b48fe255 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeFormatHelper.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 3c02c1c5d0f66432592464f0344feb7c +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeJobs.cs b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeJobs.cs new file mode 100644 index 00000000000..1e55b8afe0a --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeJobs.cs @@ -0,0 +1,100 @@ +// SPDX-FileCopyrightText: 2023 Unity Technologies and the KTX for Unity authors +// SPDX-License-Identifier: Apache-2.0 + + +using System.Runtime.InteropServices; +using Unity.Jobs; +using Unity.Collections; +using Unity.Collections.LowLevel.Unsafe; +using IntPtr = System.IntPtr; + +namespace KtxUnity +{ + unsafe struct BasisUniversalJob : IJob + { + [WriteOnly] + public NativeArray result; + + [ReadOnly] + public TranscodeFormat format; + + [ReadOnly] + public uint mipLevel; + + [ReadOnly] + [NativeDisableUnsafePtrRestriction] + public IntPtr nativeReference; + + [ReadOnly] + public NativeArray sizes; + + [ReadOnly] + public NativeArray offsets; + + [ReadOnly] + public uint layer; + + [WriteOnly] + public NativeArray textureData; + + public void Execute() + { + var success = ktx_basisu_startTranscoding(nativeReference); + var textureDataPtr = textureData.GetUnsafePtr(); + for (uint i = 0; i < offsets.Length; i++) + { + success = success && + ktx_basisu_transcodeImage( + nativeReference, + (byte*)textureDataPtr + offsets[(int)i], + sizes[(int)i], + layer, + mipLevel + i, + (uint)format, + 0, + 0 + ); + if (!success) break; + } + result[0] = success; + } + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern bool ktx_basisu_startTranscoding(IntPtr basis); + + [DllImport(KtxNativeInstance.ktxLibrary)] + static extern bool ktx_basisu_transcodeImage( + IntPtr basis, + void* dst, + uint dstSize, + uint imageIndex, + uint levelIndex, + uint format, + uint pvrtcWrapAddressing, + uint getAlphaForOpaqueFormats + ); + } + + struct KtxTranscodeJob : IJob + { + + [WriteOnly] + public NativeArray result; + + [ReadOnly] + [NativeDisableUnsafePtrRestriction] + public IntPtr nativeReference; + + [ReadOnly] + public TranscodeFormat outputFormat; + + public void Execute() + { + result[0] = KtxNativeInstance.ktxTexture2_TranscodeBasis( + nativeReference, + outputFormat, + 0 // transcodeFlags + ); + } + } +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeJobs.cs.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeJobs.cs.meta new file mode 100644 index 00000000000..17497715699 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/Runtime/Scripts/TranscodeJobs.cs.meta @@ -0,0 +1,11 @@ +fileFormatVersion: 2 +guid: 6a0b11b30fe494f05ace68e12d399bb3 +MonoImporter: + externalObjects: {} + serializedVersion: 2 + defaultReferences: [] + executionOrder: 0 + icon: {instanceID: 0} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/THIRD PARTY NOTICES.md b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/THIRD PARTY NOTICES.md new file mode 100644 index 00000000000..6c8c9965b46 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/THIRD PARTY NOTICES.md @@ -0,0 +1,48 @@ +# Third party notices + +This package contains third-party software components governed by the license(s) indicated below: + +### KTX Software + +Component Name: KTX Software + +License Type: Apache 2.0 + +Copyright © 2023 Khronos Group + +[KTX-Software library](https://github.com/KhronosGroup/KTX-Software) + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. + + +### Basis Universal Transcoder + +Component Name: Basis Universal Transcoder + +License Type: Apache 2.0 + +Copyright © 2022 Khronos Group + +[Basis Universal transcoder](https://github.com/BinomialLLC/basis_universal) + +Licensed under the Apache License, Version 2.0 (the "License"); +you may not use this file except in compliance with the License. +You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + +Unless required by applicable law or agreed to in writing, software +distributed under the License is distributed on an "AS IS" BASIS, +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +See the License for the specific language governing permissions and +limitations under the License. diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/THIRD PARTY NOTICES.md.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/THIRD PARTY NOTICES.md.meta new file mode 100644 index 00000000000..2ba20d28ed5 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/THIRD PARTY NOTICES.md.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: bde51c70783114987828f8f33165a562 +TextScriptImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/package.json b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/package.json new file mode 100644 index 00000000000..07fc0b4bcd0 --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/package.json @@ -0,0 +1,35 @@ +{ + "name": "com.unity.cloud.ktx", + "version": "3.4.5", + "displayName": "KTX for Unity", + "description": "Load KTX 2.0 and Basis Universal textures at runtime and in the Editor.", + "unity": "2020.3", + "dependencies": { + "com.unity.modules.unitywebrequest": "1.0.0" + }, + "keywords": [ + "texture", + "image", + "ktx", + "basis", + "universal", + "transcode", + "compress", + "ETC1s", + "UASTC", + "glTF" + ], + "_upm": { + "changelog": "### Added\n- Root namespace to `Ktx` assembly definition.\n\n### Fixed\n- WebGL build with Chinese Unity versions.\n- Prevent crash by not using certain texture creation flags with OpenGL in Unity versions 2022.3.12 and older." + }, + "upmCi": { + "footprint": "11109636fc579946e3b4fa2cd31ff61bfe43db9f" + }, + "documentationUrl": "https://docs.unity3d.com/Packages/com.unity.cloud.ktx@3.4/manual/index.html", + "repository": { + "url": "https://github.cds.internal.unity3d.com/unity/com.unity.cloud.ktx.git", + "type": "git", + "revision": "e175584564af6f51643bf18b54b3fd637b32ebe2" + }, + "_fingerprint": "9cc7165d9d208f09c537afc1cd114dc01eb1a9cb" +} diff --git a/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/package.json.meta b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/package.json.meta new file mode 100644 index 00000000000..fe2b661aabe --- /dev/null +++ b/Explorer/Packages/com.unity.cloud.ktx@9cc7165d9d20/package.json.meta @@ -0,0 +1,7 @@ +fileFormatVersion: 2 +guid: e4caa79e06dc747729b04f789e2258c9 +PackageManifestImporter: + externalObjects: {} + userData: + assetBundleName: + assetBundleVariant: diff --git a/Explorer/Packages/packages-lock.json b/Explorer/Packages/packages-lock.json index f2211560493..2abbc2920db 100644 --- a/Explorer/Packages/packages-lock.json +++ b/Explorer/Packages/packages-lock.json @@ -182,13 +182,12 @@ "url": "https://packages.unity.com" }, "com.unity.cloud.ktx": { - "version": "3.4.5", + "version": "file:com.unity.cloud.ktx@9cc7165d9d20", "depth": 0, - "source": "registry", + "source": "embedded", "dependencies": { "com.unity.modules.unitywebrequest": "1.0.0" - }, - "url": "https://packages.unity.com" + } }, "com.unity.code-analysis": { "version": "0.1.2-preview",