Files
AetherBags/KamiToolKit/Nodes/Basic/TextureImageNode.cs
T
KnackAtNite 8db4ce6094
Debug Build and Test / Build against Latest Dalamud (push) Has been cancelled
Debug Build and Test / Build against Staging Dalamud (push) Has been cancelled
Initial commit: AetherBags + KamiToolKit for FC Gitea
Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-08 14:46:31 -05:00

27 lines
901 B
C#

using FFXIVClientStructs.FFXIV.Client.Graphics.Kernel;
using FFXIVClientStructs.FFXIV.Component.GUI;
namespace KamiToolKit.Nodes;
/// <summary>
/// WARNING: This is a non-owning texture image node.
/// This node is meant to reference a texture that is owned elsewhere.
/// </summary>
public unsafe class TextureImageNode : SimpleImageNode {
public void SetTexture(Texture* texture) {
var asset = PartsList[0]->UldAsset;
asset->AtkTexture.KernelTexture = texture;
asset->AtkTexture.TextureType = TextureType.KernelTexture;
}
protected override void Dispose(bool disposing, bool isNativeDestructor) {
if (disposing) {
var asset = PartsList[0]->UldAsset;
asset->AtkTexture.KernelTexture = null;
asset->AtkTexture.TextureType = 0;
base.Dispose(disposing, isNativeDestructor);
}
}
}