Function at 0x545680
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
push edi
mov edi, ecx
push esi
push ebx
sub esp, 0x22c
lea ebx, [esp + 0x11b]
mov dword [esp + 4], 0x5b90b9
mov dword [esp], ebx
call sub.msvcrt.dll_strcpy
mov dword [esp], ebx
mov byte [esp + 0x21f], 0
call sub.msvcrt.dll_strlen
lea edx, [eax + 7]
cmp edx, 0x103
jbe 0x5456d0
add esp, 0x22c
pop ebx
pop esi
pop edi
pop ebp
ret
add eax, ebx
mov dword [eax], 0x2e6c6473
mov dword [eax + 4], 0x747874
cmp byte [esp + 0x21f], 0
jne 0x5456be
mov dword [esp], ebx
mov dword [esp + 4], 0x5ab629
call sub.msvcrt.dll_fopen
mov ebx, eax
test eax, eax
je 0x5456be
mov dword [esp + 4], str._Seven_Kingdoms_2.15.6__n
xor esi, esi
mov dword [esp], eax
call fcn.00584d80
call sub.SDL2.dll_SDL_GetPlatform
mov dword [esp + 4], str.Platform:__s_n
mov dword [esp + 8], eax
mov dword [esp], ebx
call fcn.00584d80
mov dword [esp + 4], str.Little_endian_n
mov dword [esp], ebx
call fcn.00584d80
call sub.SDL2.dll_SDL_GetCurrentVideoDriver
mov dword [esp + 4], str.Current_SDL_video_driver:__s_n
mov dword [esp + 8], eax
mov dword [esp], ebx
call fcn.00584d80
lea eax, [esp + 0x59]
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetVersion
movzx eax, byte [esp + 0x5b]
mov dword [esp + 4], str.SDL_version:__d._d._d_n
mov dword [esp], ebx
mov dword [esp + 0x10], eax
movzx eax, byte [esp + 0x5a]
mov dword [esp + 0xc], eax
movzx eax, byte [esp + 0x59]
mov dword [esp + 8], eax
call fcn.00584d80
mov dword [esp + 0x10], 2
mov ecx, 0x1a02
mov dword [esp + 0xc], 0x1a
mov dword [esp + 8], 2
mov dword [esp + 4], str.Compiled_SDL_version:__d._d._d_n_n
mov dword [esp], ebx
mov word [esp + 0x59], cx
mov byte [esp + 0x5b], 2
call fcn.00584d80
mov dword [esp + 4], str.___Video_drivers____n
mov dword [esp], ebx
call fcn.00584d80
call sub.SDL2.dll_SDL_GetNumVideoDrivers
mov ebp, eax
test eax, eax
jle 0x545807
lea esi, [esi]
mov dword [esp], esi
call sub.SDL2.dll_SDL_GetVideoDriver
mov dword [esp + 8], esi
add esi, 1
mov dword [esp + 0xc], eax
mov dword [esp + 4], str._d:__s_n
mov dword [esp], ebx
call fcn.00584d80
cmp ebp, esi
jne 0x5457e0
mov dword [esp + 4], 0x5ab6d6
mov dword [esp], ebx
call fcn.00584d80
mov eax, dword [edi]
test eax, eax
je 0x545b4c
mov dword [esp], eax
mov ebp, 0x5ab5f4
mov dword [esp + 0x68], 0
call sub.SDL2.dll_SDL_GetRenderer
mov dword [esp + 4], str.___Current_window____n
mov dword [esp], ebx
mov dword [esp + 0x38], eax
call fcn.00584d80
mov eax, dword [edi]
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetWindowDisplayIndex
mov dword [esp + 4], str.Active_on_display:__d_n
mov dword [esp + 8], eax
mov dword [esp], ebx
call fcn.00584d80
lea eax, [esp + 0x60]
mov dword [esp + 8], eax
lea eax, [esp + 0x5c]
mov dword [esp + 4], eax
mov eax, dword [edi]
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetWindowPosition
lea ecx, [esp + 0x64]
lea eax, [esp + 0x68]
mov dword [esp + 4], ecx
mov dword [esp + 0x40], eax
mov dword [esp + 8], eax
mov eax, dword [edi]
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetWindowSize
mov eax, dword [esp + 0x60]
mov dword [esp + 4], str.Geometry:__dx_d_____d___d__n
mov dword [esp], ebx
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x5c]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x68]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x64]
mov dword [esp + 8], eax
call fcn.00584d80
mov eax, dword [edi]
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetWindowPixelFormat
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetPixelFormatName
mov dword [esp + 4], str.Pixel_format:__s_n
mov dword [esp + 8], eax
mov dword [esp], ebx
call fcn.00584d80
mov eax, dword [edi]
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetWindowFlags
mov dword [esp + 4], str.Full_screen:__s_n
test eax, 0x1001
mov eax, 0x5ab5f8
mov dword [esp], ebx
cmovne eax, ebp
mov dword [esp + 8], eax
call fcn.00584d80
mov eax, dword [edi]
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetWindowGrab
mov dword [esp + 4], str.Input_grabbed:__s_n_n
test eax, eax
mov eax, 0x5ab5f8
mov dword [esp], ebx
cmovne eax, ebp
mov dword [esp + 8], eax
call fcn.00584d80
mov edx, dword [esp + 0x38]
test edx, edx
je 0x545b4c
lea esi, [esp + 0xc4]
mov dword [esp], edx
mov dword [esp + 4], esi
call sub.SDL2.dll_SDL_GetRendererInfo
lea ecx, [esp + 0x70]
mov dword [esp + 4], ecx
lea ecx, [esp + 0x6c]
mov dword [esp], ecx
mov ecx, edi
call fcn.00544c00
sub esp, 8
lea ecx, [esp + 0xb4]
mov dword [esp + 4], ecx
mov eax, dword [edi + 4]
mov dword [esp], eax
call sub.SDL2.dll_SDL_RenderGetViewport
mov eax, dword [esp + 0x40]
mov dword [esp + 8], eax
lea eax, [esp + 0x64]
mov dword [esp + 4], eax
mov eax, dword [edi + 4]
mov dword [esp], eax
call sub.SDL2.dll_SDL_RenderGetLogicalSize
mov eax, dword [esp + 0xc4]
mov dword [esp + 4], str.___Current_renderer:__s____n
mov dword [esp], ebx
mov dword [esp + 8], eax
call fcn.00584d80
mov eax, dword [esp + 0xc0]
mov dword [esp + 4], str.Viewport:_x_d_y_d_w_d_h_d_n
mov dword [esp], ebx
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0xbc]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0xb8]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0xb4]
mov dword [esp + 8], eax
call fcn.00584d80
fld dword [esp + 0x70]
mov dword [esp + 4], str.Scale:_xscale_f_yscale_f_n
mov dword [esp], ebx
fstp dword [esp + 0x74]
fld dword [esp + 0x74]
fstp qword [esp + 0x88]
fld dword [esp + 0x6c]
fstp dword [esp + 0x78]
fld dword [esp + 0x78]
fstp qword [esp + 0x90]
fld qword [esp + 0x88]
fstp qword [esp + 0x10]
fld qword [esp + 0x90]
fstp qword [esp + 8]
call fcn.00584d80
mov eax, dword [esp + 0x68]
mov dword [esp + 4], str.Logical_size:_w_d__h_d_n
mov dword [esp], ebx
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x64]
mov dword [esp + 8], eax
call fcn.00584d80
test byte [esp + 0xc8], 2
mov dword [esp], ebx
mov edx, str.software_fallback
mov eax, str.hardware_accelerated
mov dword [esp + 4], str.Capabilities:__s_n
cmove eax, edx
mov dword [esp + 8], eax
call fcn.00584d80
mov edx, 0x5ab625
mov dword [esp], ebx
test byte [esp + 0xc8], 4
mov eax, 0x5ab622
mov dword [esp + 4], str.V_sync:__s_n
cmove eax, edx
mov dword [esp + 8], eax
call fcn.00584d80
test byte [esp + 0xc8], 8
mov eax, 0x5ab5f8
mov dword [esp], ebx
cmove ebp, eax
mov dword [esp + 4], str.Rendering_to_texture_supported:__s_n
mov dword [esp + 8], ebp
call fcn.00584d80
mov eax, dword [esp + 0x110]
mov edx, dword [esp + 0x114]
mov ecx, eax
or ecx, edx
jne 0x546009
mov dword [esp + 4], str.Pixel_formats:_n
xor ebp, ebp
mov dword [esp], ebx
call fcn.00584d80
mov edx, dword [esp + 0xcc]
test edx, edx
je 0x545b4c
mov eax, dword [esi + ebp*4 + 0xc]
add ebp, 1
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetPixelFormatName
mov dword [esp + 4], str._t_s_n
mov dword [esp + 8], eax
mov dword [esp], ebx
call fcn.00584d80
cmp dword [esp + 0xcc], ebp
ja 0x545b20
mov dword [esp + 4], 0x5ab6d6
mov dword [esp], ebx
call fcn.00584d80
mov eax, dword [edi + 8]
test eax, eax
je 0x545bfe
lea ecx, [esp + 0xb4]
lea esi, [esp + 0xc4]
mov dword [esp], eax
mov dword [esp + 0xc], ecx
lea ecx, [esp + 0x70]
mov dword [esp + 4], ecx
mov dword [esp + 0x10], esi
mov dword [esp + 8], 0
mov dword [esp + 0x70], 0
mov dword [esp + 0xc4], 0
call sub.SDL2.dll_SDL_QueryTexture
mov dword [esp + 4], str.___Streaming_texture____n
mov dword [esp], ebx
call fcn.00584d80
mov eax, dword [esp + 0xc4]
mov dword [esp + 4], str.Size:__dx_d_n
mov dword [esp], ebx
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0xb4]
mov dword [esp + 8], eax
call fcn.00584d80
mov eax, dword [esp + 0x70]
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetPixelFormatName
mov dword [esp + 4], str.Pixel_format:__s_n_n
mov dword [esp + 8], eax
mov dword [esp], ebx
call fcn.00584d80
call sub.SDL2.dll_SDL_GetNumVideoDisplays
mov dword [esp + 0x44], eax
test eax, eax
jle 0x545d8d
lea eax, [esp + 0x68]
xor esi, esi
mov dword [esp + 0x40], eax
lea eax, [esp + 0x70]
mov dword [esp + 0x4c], eax
lea eax, [esp + 0x6c]
mov dword [esp + 0x48], eax
lea eax, [esp + 0xb4]
mov dword [esp + 0x3c], eax
lea esi, [esi]
mov dword [esp], esi
xor ebp, ebp
call sub.SDL2.dll_SDL_GetNumDisplayModes
mov dword [esp + 4], 0
mov dword [esp], esi
mov edi, eax
call sub.SDL2.dll_SDL_GetCurrentDisplayMode
mov dword [esp + 8], esi
mov dword [esp + 0xc], eax
mov dword [esp + 4], str.___Display__d_using_mode__d___n
mov dword [esp], ebx
call fcn.00584d80
test edi, edi
jle 0x545d18
mov dword [esp + 0x38], ebx
jmp 0x545c8b
add ebp, 1
cmp edi, ebp
je 0x545d14
lea eax, [esp + 0xc4]
mov dword [esp + 4], ebp
mov dword [esp + 8], eax
mov dword [esp], esi
call sub.SDL2.dll_SDL_GetDisplayMode
test eax, eax
jne 0x545c80
mov eax, dword [esp + 0xc4]
mov ebx, dword [esp + 0xd4]
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetPixelFormatName
mov dword [esp + 8], ebp
add ebp, 1
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0xd0]
mov dword [esp + 0x20], ebx
mov dword [esp + 0x18], eax
movzx eax, byte [esp + 0xc5]
mov dword [esp + 4], str.Mode__d:__dx_dx_ubpp__dHz_format_s_driver_p_n
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0xcc]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0xc8]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x38]
mov dword [esp], eax
call fcn.00584d80
cmp edi, ebp
jne 0x545c8b
mov ebx, dword [esp + 0x38]
mov eax, dword [esp + 0x4c]
mov dword [esp], esi
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x48]
mov dword [esp + 8], eax
mov eax, dword [esp + 0x40]
mov dword [esp + 4], eax
call sub.SDL2.dll_SDL_GetDisplayDPI
test eax, eax
je 0x545f00
mov eax, dword [esp + 0x3c]
mov dword [esp], esi
mov dword [esp + 4], eax
call sub.SDL2.dll_SDL_GetDisplayBounds
test eax, eax
je 0x545fc8
mov eax, dword [esp + 0x3c]
mov dword [esp], esi
mov dword [esp + 4], eax
call sub.SDL2.dll_SDL_GetDisplayUsableBounds
test eax, eax
je 0x545f80
mov dword [esp + 4], 0x5ab6d6
add esi, 1
mov dword [esp], ebx
call fcn.00584d80
cmp dword [esp + 0x44], esi
jne 0x545c38
call sub.SDL2.dll_SDL_GetNumRenderDrivers
xor edi, edi
lea esi, [esp + 0xc4]
mov dword [esp + 0x38], eax
test eax, eax
jle 0x545ee9
lea esi, [esi]
nop
mov dword [esp + 4], esi
mov dword [esp], edi
call sub.SDL2.dll_SDL_GetRenderDriverInfo
mov eax, dword [esp + 0xc4]
mov dword [esp + 0xc], edi
mov dword [esp + 4], str.___Renderer__s___d_____n
mov dword [esp + 8], eax
mov dword [esp], ebx
call fcn.00584d80
mov ecx, str.hardware_accelerated
mov dword [esp], ebx
test byte [esp + 0xc8], 2
mov eax, str.software_fallback
mov dword [esp + 4], str.Capabilities:__s_n
cmovne eax, ecx
mov dword [esp + 8], eax
call fcn.00584d80
test byte [esp + 0xc8], 4
mov dword [esp], ebx
mov edx, 0x5ab625
mov eax, 0x5ab622
mov dword [esp + 4], str.V_sync_capable:__s_n
cmove eax, edx
mov dword [esp + 8], eax
call fcn.00584d80
test byte [esp + 0xc8], 8
mov dword [esp], ebx
mov edx, 0x5ab5f8
mov eax, 0x5ab5f4
mov dword [esp + 4], str.Rendering_to_texture_supported:__s_n
cmove eax, edx
mov dword [esp + 8], eax
call fcn.00584d80
mov eax, dword [esp + 0x110]
mov edx, dword [esp + 0x114]
mov ecx, eax
or ecx, edx
je 0x545e82
mov dword [esp + 0xc], edx
mov dword [esp + 8], eax
mov dword [esp + 4], str.Maximum_texture_size:__dx_d_n
mov dword [esp], ebx
call fcn.00584d80
mov dword [esp + 4], str.Pixel_formats:_n
xor ebp, ebp
mov dword [esp], ebx
call fcn.00584d80
mov eax, dword [esp + 0xcc]
test eax, eax
je 0x545ecc
nop
mov eax, dword [esi + ebp*4 + 0xc]
add ebp, 1
mov dword [esp], eax
call sub.SDL2.dll_SDL_GetPixelFormatName
mov dword [esp + 4], str._t_s_n
mov dword [esp + 8], eax
mov dword [esp], ebx
call fcn.00584d80
cmp dword [esp + 0xcc], ebp
ja 0x545ea0
mov dword [esp + 4], 0x5ab6d6
add edi, 1
mov dword [esp], ebx
call fcn.00584d80
cmp dword [esp + 0x38], edi
jne 0x545db0
mov dword [esp], ebx
call sub.msvcrt.dll_fclose
add esp, 0x22c
pop ebx
pop esi
pop edi
pop ebp
ret
fld dword [esp + 0x70]
mov dword [esp + 4], str.DPI:_diag_f_horiz_f_vert_f_n
mov dword [esp], ebx
fstp dword [esp + 0x7c]
fld dword [esp + 0x7c]
fstp qword [esp + 0x98]
fld dword [esp + 0x6c]
fstp dword [esp + 0x80]
fld dword [esp + 0x80]
fstp qword [esp + 0xa0]
fld dword [esp + 0x68]
fstp dword [esp + 0x84]
fld dword [esp + 0x84]
fstp qword [esp + 0xa8]
fld qword [esp + 0x98]
fstp qword [esp + 0x18]
fld qword [esp + 0xa0]
fstp qword [esp + 0x10]
fld qword [esp + 0xa8]
fstp qword [esp + 8]
call fcn.00584d80
jmp 0x545d40
mov eax, dword [esp + 0xc0]
mov dword [esp + 4], str.Usable_bounds:_x_d_y_d_w_d_h_d_n
mov dword [esp], ebx
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0xbc]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0xb8]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0xb4]
mov dword [esp + 8], eax
call fcn.00584d80
jmp 0x545d70
mov eax, dword [esp + 0xc0]
mov dword [esp + 4], str.Bounds:_x_d_y_d_w_d_h_d_n
mov dword [esp], ebx
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0xbc]
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0xb8]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0xb4]
mov dword [esp + 8], eax
call fcn.00584d80
jmp 0x545d58
mov dword [esp + 0xc], edx
mov dword [esp + 8], eax
mov dword [esp + 4], str.Maximum_texture_size:__dx_d_n
mov dword [esp], ebx
call fcn.00584d80
jmp 0x545b03