Synced
ITextureTargetCompiler.CompileKtxAsync
Section titled “ITextureTargetCompiler.CompileKtxAsync”
- Compiles one source texture into an uncompressed KTX artifact with a complete mip chain.
Required contracts
Section titled “Required contracts”API: engine
Project: Inno.Rendering.Assets.Authoring
Declaration
Section titled “Declaration”System.Threading.Tasks.ValueTask<byte[]> Inno.Rendering.Assets.Authoring.ITextureTargetCompiler.CompileKtxAsync(System.IO.Stream source, Inno.Rendering.Assets.TextureColorSpace colorSpace, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))Parameters
Section titled “Parameters”Parameter source: Borrowed encoded image stream retained by the caller until compilation completes.
Parameter colorSpace: Sampling color-space contract.
Parameter cancellationToken: Cancellation for the offline compiler process.
Returns
Section titled “Returns”An operation producing complete KTX bytes suitable for a backend-neutral texture container upload.
Exceptions
Section titled “Exceptions”Exception T:System.InvalidOperationException: Thrown when the target compiler rejects the source.