mirror of
https://github.com/xivdev/Penumbra.git
synced 2025-12-30 12:23:41 +01:00
Add debug display for ResidentResources.
This commit is contained in:
parent
ad55d178d4
commit
98b4b29ff5
8 changed files with 59 additions and 102 deletions
|
|
@ -327,6 +327,36 @@ public partial class SettingsInterface
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
public unsafe void DrawDebugResidentResources()
|
||||
{
|
||||
if( !ImGui.CollapsingHeader( "Resident Resources##Debug" ) )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if( Penumbra.ResidentResources.Address == null || Penumbra.ResidentResources.Address->NumResources == 0 )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
if( !ImGui.BeginTable( "##Resident ResourcesDebugList", 2, ImGuiTableFlags.RowBg | ImGuiTableFlags.SizingFixedFit, -Vector2.UnitX ) )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
using var end = ImGuiRaii.DeferredEnd( ImGui.EndTable );
|
||||
|
||||
for( var i = 0; i < Penumbra.ResidentResources.Address->NumResources; ++i )
|
||||
{
|
||||
var resource = Penumbra.ResidentResources.Address->ResourceList[ i ];
|
||||
ImGui.TableNextColumn();
|
||||
ImGui.Text( $"0x{( ulong )resource:X}" );
|
||||
ImGui.TableNextColumn();
|
||||
ImGuiNative.igTextUnformatted( resource->FileName(), resource->FileName() + resource->FileNameLength );
|
||||
}
|
||||
}
|
||||
|
||||
private unsafe void DrawPathResolverDebug()
|
||||
{
|
||||
if( !ImGui.CollapsingHeader( "Path Resolver##Debug" ) )
|
||||
|
|
@ -404,6 +434,8 @@ public partial class SettingsInterface
|
|||
ImGui.NewLine();
|
||||
DrawDebugCharacterUtility();
|
||||
ImGui.NewLine();
|
||||
DrawDebugResidentResources();
|
||||
ImGui.NewLine();
|
||||
DrawDebugTabRedraw();
|
||||
ImGui.NewLine();
|
||||
DrawDebugTabIpc();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue