brutal/Brutal.Ktx/Abstractions/KtxNativeMemory.cs
Rian Drake b578433e37 first
2026-10-15 17:10:50 +13:00

13 lines
452 B
C#

using System.Runtime.InteropServices;
namespace Brutal.KtxApi;
/// <summary>
/// Binds to the native free() used by the KTX library itself, for releasing buffers it allocated
/// with malloc() (e.g. via WriteToMemory/WriteKtx2ToMemory). See KtxNativeBuffer.
/// </summary>
internal static unsafe partial class KtxNativeMemory
{
[LibraryImport("Ktx", EntryPoint = "ktx_FreeWriteToMemoryBuffer1")]
public static partial void Free(void* ptr);
}