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

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], r8
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0xd0
movsxd rdi, ecx
lea rcx, [rsp + 0x28]
mov rbp, r8
mov rsi, rdx
xor r14d, r14d
call qword [sym.imp.USER32.dll_CopyRect]
lea rcx, [rsp + 0x28]
call qword [sym.imp.USER32.dll_IsRectEmpty]
cmp eax, r14d
je 0x140038661
mov eax, 0x80070057
jmp 0x140038c65
mov rbx, rdi
lea r13, [0x14010b1f0]
lea rdx, [rsp + 0x28]
imul rbx, rbx, 0x70
lea r12, [rbx + r13 + 0x50]
mov qword [rsp + 0xa8], rbx
mov rcx, r12
mov qword [rsp + 0xc0], r12
call qword [sym.imp.USER32.dll_EqualRect]
cmp eax, r14d
je 0x1400386ac
mov rax, qword [rbx + r13 + 0x48]
cmp rax, r14
je 0x1400386ac
mov qword [rbp], rax
xor eax, eax
jmp 0x140038c65
mov ecx, dword [r12 + 8]
mov eax, dword [rsp + 0x30]
mov edx, dword [rsp + 0x28]
sub ecx, dword [r12]
sub eax, edx
cmp ecx, eax
jne 0x140038709
mov ecx, dword [r12 + 0xc]
mov eax, dword [rsp + 0x34]
mov r8d, dword [rsp + 0x2c]
sub ecx, dword [r12 + 4]
sub eax, r8d
cmp ecx, eax
jne 0x140038709
mov rcx, qword [rbx + r13 + 0x48]
cmp rcx, r14
je 0x140038709
sub r8d, dword [rbx + r13 + 0x54]
sub edx, dword [r12]
call qword [sym.imp.GDI32.dll_OffsetRgn]
mov rax, qword [rbx + r13 + 0x48]
movdqu xmm5, xmmword [rsp + 0x28]
movdqu xmmword [r12], xmm5
jmp 0x1400386a1
mov rcx, qword [rbx + r13 + 0x48]
cmp rcx, r14
je 0x14003871e
call qword [sym.imp.GDI32.dll_DeleteObject]
mov qword [rbx + r13 + 0x48], r14
mov ecx, edi
call fcn.14003837c
cmp eax, r14d
je 0x140038754
mov dword [rsp + 0x80], r14d
mov dword [rsp + 0x84], r14d
mov dword [rsp + 0x88], r14d
mov dword [rsp + 0x8c], r14d
movaps xmm0, xmmword [rsp + 0x80]
jmp 0x14003875b
movdqu xmm0, xmmword [rbx + r13 + 0x28]
lea rdx, [rsp + 0x60]
lea rcx, [rsp + 0x38]
movdqa xmmword [rsp + 0x60], xmm0
call qword [sym.imp.USER32.dll_CopyRect]
mov ecx, edi
call fcn.14003831c
mov ecx, edi
mov r15d, eax
call fcn.1400382bc
mov edx, dword [rbx + r13 + 0x10]
mov ecx, edi
mov ebp, eax
mov dword [rsp + 0x50], eax
call fcn.1400385a8
mov dword [rsp + 0xa4], eax
cmp r15d, r14d
je 0x140038c60
cmp ebp, r14d
je 0x140038c60
mov ecx, dword [rsp + 0x34]
mov edx, r15d
sub ecx, dword [rsp + 0x2c]
cmp r15d, ecx
je 0x1400387c9
mov edx, dword [rsp + 0x3c]
mov ecx, dword [rsp + 0x44]
lea edx, [rcx + rdx + 1]
movsxd rcx, edx
add rcx, 2
shl rcx, 4
call fcn.1400eb808
mov r13, rax
mov qword [rsp + 0xb0], rax
cmp rax, r14
jne 0x1400387f3
mov eax, 0x8007000e
jmp 0x140038c65
mov dword [rax], 0x20
mov dword [rax + 4], 1
or eax, 0xffffffff
mov ecx, edi
mov dword [rsp + 0x80], eax
mov dword [rsp + 0x88], eax
call fcn.140038504
xor ebp, ebp
mov r14, rax
mov qword [rsp + 0xb8], rax
mov eax, 0x8000ffff
test r14, r14
cmove ebp, eax
xor edi, edi
mov dword [rsp + 0x20], edi
mov dword [rsp + 0xa0], ebp
test ebp, ebp
js 0x140038bb2
lea rcx, [rsp + 0x60]
mov rdx, rsi
call qword [sym.imp.USER32.dll_CopyRect]
mov eax, dword [rsp + 0x3c]
mov r11d, dword [rsp + 0x68]
add dword [rsp + 0x64], eax
sub r11d, dword [rsp + 0x40]
mov eax, dword [rsp + 0x44]
sub dword [rsp + 0x6c], eax
mov r9d, dword [rsp + 0x38]
mov rcx, qword [r14 + 0x10]
mov edx, dword [r14 + 0x20]
mov r10d, dword [rsp + 0x50]
add dword [rsp + 0x60], r9d
and qword [rsp + 0x48], rdi
mov eax, r10d
xor r14d, r14d
sub eax, dword [rsp + 0x40]
mov dword [rsp + 0x128], r11d
mov dword [rsp + 0x68], r11d
mov dword [rsp + 0x90], r9d
mov qword [rsp + 0xc8], rcx
mov dword [rsp + 0x54], edx
mov dword [rsp + 0x94], eax
test r15d, r15d
jle 0x140038bb2
mov ebx, dword [rsp + 0x80]
mov ebp, dword [rsp + 0x88]
lea rax, [r13 + 0x20]
mov r13, qword [rsp + 0x48]
mov qword [rsp + 0x98], rax
add rax, 0xfffffffffffffff0
mov qword [rsp + 0x70], rax
mov r12d, edi
mov eax, dword [rsp + 0xa4]
or edi, 0xffffffff
add eax, r14d
or esi, edi
imul eax, edx
cdqe
lea rcx, [rax + rcx + 3]
mov rax, qword [rsp + 0xb8]
cmp dword [rax + 0x24], 0x20
je 0x14003891e
xor edi, edi
lea esi, [r10 - 1]
jmp 0x14003894a
xor eax, eax
test r10d, r10d
jle 0x140038b6c
cmp byte [rcx], 0
je 0x140038936
cmp edi, 0xffffffff
mov esi, eax
cmove edi, eax
inc eax
add rcx, 4
cmp eax, r10d
jl 0x140038929
cmp edi, 0xffffffff
je 0x140038b6c
mov edx, dword [rsp + 0x30]
mov r8d, dword [rsp + 0x28]
mov eax, edx
sub eax, r8d
cmp eax, r10d
je 0x140038a19
mov eax, r10d
sub eax, dword [rsp + 0x40]
cmp edi, eax
jl 0x140038978
mov eax, edx
sub eax, r10d
sub eax, r8d
add edi, eax
jmp 0x1400389c5
cmp edi, r9d
jl 0x1400389c5
mov r8d, dword [rsp + 0x94]
sub r11d, dword [rsp + 0x60]
sub edi, r9d
sub r8d, dword [rsp + 0x90]
lea ecx, [rdi + 1]
mov edx, r11d
call qword [sym.imp.KERNEL32.dll_MulDiv]
mov r9d, dword [rsp + 0x38]
mov r11d, dword [rsp + 0x68]
mov edx, dword [rsp + 0x30]
mov r8d, dword [rsp + 0x28]
mov r10d, dword [rsp + 0x50]
lea edi, [r9 + rax]
mov dword [rsp + 0x128], r11d
mov ecx, r10d
sub ecx, dword [rsp + 0x40]
cmp esi, ecx
jl 0x1400389da
sub edx, r10d
sub edx, r8d
add esi, edx
jmp 0x140038a19
cmp esi, r9d
jl 0x140038a19
mov r8d, dword [rsp + 0x94]
sub r11d, dword [rsp + 0x60]
sub esi, r9d
sub r8d, dword [rsp + 0x90]
lea ecx, [rsi + 1]
mov edx, r11d
call qword [sym.imp.KERNEL32.dll_MulDiv]
mov r10d, dword [rsp + 0x50]
mov esi, eax
mov eax, dword [rsp + 0x68]
add esi, dword [rsp + 0x38]
mov dword [rsp + 0x128], eax
inc esi
cmp ebx, 0xffffffff
je 0x140038a24
cmp edi, ebx
jge 0x140038a2d
mov ebx, edi
mov dword [rsp + 0x80], ebx
cmp ebp, 0xffffffff
je 0x140038a36
cmp esi, ebp
jle 0x140038a3f
mov ebp, esi
mov dword [rsp + 0x88], esi
mov edx, dword [rsp + 0x34]
mov r8d, dword [rsp + 0x2c]
mov eax, edx
sub eax, r8d
cmp eax, r15d
je 0x140038ae5
cmp r14d, dword [rsp + 0x3c]
jl 0x140038ae5
mov eax, r15d
sub eax, dword [rsp + 0x44]
cmp r14d, eax
jg 0x140038ae5
mov r11, qword [rsp + 0x70]
test r13, r13
jle 0x140038a91
cmp dword [r11], edi
jne 0x140038a91
cmp dword [r11 + 8], esi
jne 0x140038a91
sub edx, dword [rsp + 0x44]
sub edx, r8d
inc edx
mov dword [r11 + 0xc], edx
jmp 0x140038adb
mov rdx, qword [rsp + 0x98]
mov r8, qword [rsp + 0x48]
add r11, 0x10
mov dword [rdx], edi
mov dword [rdx + 8], esi
mov dword [rdx + 4], r14d
mov eax, dword [rsp + 0x34]
inc r8
inc r12d
sub eax, dword [rsp + 0x44]
mov qword [rsp + 0x48], r8
mov qword [rsp + 0x70], r11
sub eax, dword [rsp + 0x2c]
mov r13, r8
inc eax
add rdx, 0x10
mov dword [rdx - 4], eax
mov qword [rsp + 0x98], rdx
mov r14d, r15d
sub r14d, dword [rsp + 0x44]
jmp 0x140038b5b
mov eax, r15d
mov ecx, r14d
sub eax, dword [rsp + 0x44]
cmp r14d, eax
jl 0x140038aff
mov ecx, edx
sub ecx, r15d
sub ecx, r8d
add ecx, r14d
mov r8, qword [rsp + 0x48]
mov r11, qword [rsp + 0x70]
test r8, r8
jle 0x140038b22
cmp dword [r11], edi
jne 0x140038b22
cmp dword [r11 + 8], esi
jne 0x140038b22
lea eax, [rcx + 1]
mov dword [r11 + 0xc], eax
jmp 0x140038b58
mov rdx, qword [rsp + 0x98]
inc r8
add r11, 0x10
lea eax, [rcx + 1]
inc r12d
mov dword [rdx], edi
mov dword [rdx + 8], esi
mov dword [rdx + 4], ecx
mov dword [rdx + 0xc], eax
add rdx, 0x10
mov qword [rsp + 0x48], r8
mov qword [rsp + 0x70], r11
mov qword [rsp + 0x98], rdx
mov r13, r8
mov r9d, dword [rsp + 0x38]
mov r11d, dword [rsp + 0x128]
mov edx, dword [rsp + 0x54]
mov rcx, qword [rsp + 0xc8]
inc r14d
cmp r14d, r15d
jl 0x1400388ef
mov rbx, qword [rsp + 0xa8]
mov ebp, dword [rsp + 0xa0]
mov r13, qword [rsp + 0xb0]
mov dword [rsp + 0x20], r12d
mov dword [rsp + 0x20], r12d
test r12d, r12d
mov edi, dword [rsp + 0x20]
mov r12, qword [rsp + 0xc0]
jne 0x140038bb7
mov ebp, 0x80004005
mov eax, dword [r13 + 0x24]
mov dword [rsp + 0x84], eax
movsxd rax, edi
add rax, rax
mov eax, dword [r13 + rax*8 + 0x1c]
mov dword [rsp + 0x8c], eax
test ebp, ebp
js 0x140038c54
movdqu xmm0, xmmword [rsp + 0x80]
lea edx, [rdi + 2]
mov eax, edi
shl eax, 4
lea rsi, [0x14010b1f0]
mov r8, r13
shl edx, 4
xor ecx, ecx
movdqu xmmword [rbx + rsi + 0x60], xmm0
mov dword [r13 + 8], edi
mov dword [r13 + 0xc], eax
movdqu xmmword [r13 + 0x10], xmm0
call qword [sym.imp.GDI32.dll_ExtCreateRegion]
mov rcx, rax
mov qword [rbx + rsi + 0x48], rax
mov eax, 0x8007000e
test rcx, rcx
cmove ebp, eax
test ebp, ebp
js 0x140038c54
mov r8d, dword [rsp + 0x2c]
mov edx, dword [rsp + 0x28]
call qword [sym.imp.GDI32.dll_OffsetRgn]
mov rax, qword [rsp + 0x120]
mov rcx, qword [rbx + rsi + 0x48]
movdqu xmm5, xmmword [rsp + 0x28]
movdqu xmmword [r12], xmm5
mov qword [rax], rcx
mov rcx, r13
call fcn.1400eb814
mov eax, ebp
jmp 0x140038c65
mov eax, 0x8000ffff
mov rbx, qword [rsp + 0x110]
add rsp, 0xd0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret