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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x5e3a98
mov eax, dword fs:[0]
push eax
sub esp, 0x88
push ebx
push esi
push edi
mov eax, dword [0x680f10]
xor eax, esp
push eax
lea eax, [esp + 0x98]
mov dword fs:[0], eax
mov ebx, ecx
mov eax, dword [ebx + 4]
xor edi, edi
cmp eax, edi
je 0x4222e4
mov eax, dword [eax + 0xc]
cmp eax, edi
je 0x4222c7
mov ecx, eax
call fcn.00464950
mov ecx, dword [eax]
cmp ecx, 2
je 0x4222b7
cmp ecx, 1
jne 0x4222e4
cmp byte [eax + 0x5c], 0
jne 0x4222e4
mov eax, dword [eax + 0x10]
shr eax, 2
and al, 1
jne 0x4222e4
mov eax, 2
mov ecx, dword [esp + 0x98]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
mov eax, dword [ebx + 0x60]
cmp eax, edi
je 0x4227f3
mov ecx, dword [ebx + 8]
push eax
push edi
push ecx
push edi
call dword [sym.imp.GDI32.dll_CreateDCW]
mov esi, eax
cmp esi, edi
mov dword [esp + 0x1c], esi
je 0x4227f3
call fcn.00424120
mov edx, dword [ebx]
mov dword [esp + 0x44], eax
mov eax, dword [ebp + 8]
mov dword [esp + 0x84], eax
mov eax, dword [edx + 0x8c]
mov ecx, ebx
mov dword [esp + 0x80], 0x14
mov dword [esp + 0x88], edi
mov dword [esp + 0x90], edi
mov dword [esp + 0x8c], edi
mov dword [esp + 0x18], edi
call eax
cmp eax, edi
mov dword [esp + 0x20], eax
je 0x4227a1
lea ecx, [esp + 0x80]
push ecx
push esi
call dword [sym.imp.GDI32.dll_StartDocW]
test eax, eax
jle 0x4227a1
mov ecx, dword [ebp + 0xc]
cmp ecx, edi
mov edx, dword [ebx + 0x74]
mov eax, dword [ebx + 0x78]
mov dword [esp + 0x6c], edi
mov dword [esp + 0x68], edi
mov dword [esp + 0x64], edi
mov dword [esp + 0x60], edi
mov dword [esp + 0x50], edx
mov dword [esp + 0x54], eax
je 0x4223a1
mov eax, dword [esp + 0x20]
mov edx, dword [ecx]
mov edx, dword [edx]
push eax
push edi
call edx
cmp dword [esp + 0x20], edi
jbe 0x42278e
jmp 0x4223b0
mov edx, dword [esp + 0x18]
lea edi, [esp + 0x60]
mov eax, ebx
call fcn.00423f40
mov ax, word [esp + 0x50]
cmp ax, word [ebx + 0x7c]
jne 0x4223f1
mov cx, word [esp + 0x52]
cmp cx, word [ebx + 0x7e]
jne 0x4223f1
mov dx, word [esp + 0x54]
cmp dx, word [ebx + 0x80]
jne 0x4223f1
mov ax, word [esp + 0x56]
cmp ax, word [ebx + 0x82]
je 0x422435
mov ecx, dword [ebx + 0x7c]
mov edx, dword [ebx + 0x80]
mov eax, dword [ebx + 0x60]
mov esi, dword [esp + 0x1c]
mov word [eax + 0x4e], cx
mov eax, dword [ebx + 0x60]
mov dword [esp + 0x50], ecx
shr ecx, 0x10
mov word [eax + 0x52], cx
mov eax, dword [ebx + 0x60]
mov word [eax + 0x50], dx
mov eax, dword [ebx + 0x60]
mov dword [esp + 0x54], edx
shr edx, 0x10
mov word [eax + 0x4c], dx
mov eax, dword [ebx + 0x60]
push eax
push esi
call dword [sym.imp.GDI32.dll_ResetDCW]
jmp 0x422439
mov esi, dword [esp + 0x1c]
push esi
call dword [sym.imp.GDI32.dll_StartPage]
test eax, eax
jle 0x422759
lea ecx, [esp + 0x24]
push ecx
xor edi, edi
push esi
mov dword [esp + 0x2c], edi
call sub.gdiplus.dll_GdipCreateFromHDC
mov dword [esp + 0x4c], eax
mov eax, dword [esp + 0x24]
mov dword [esp + 0x48], eax
push 3
push eax
mov dword [esp + 0xa8], edi
call sub.gdiplus.dll_GdipSetPageUnit
cmp eax, edi
je 0x42247c
mov dword [esp + 0x4c], eax
xor ecx, ecx
xor edx, edx
cmp byte [ebx + 0x44], cl
mov dword [esp + 0x64], ecx
mov dword [esp + 0x60], edx
je 0x4226bc
mov eax, dword [esp + 0x48]
lea edx, [esp + 0x28]
push edx
push eax
call sub.gdiplus.dll_GdipGetDpiY
cmp eax, edi
je 0x4224a8
mov dword [esp + 0x4c], eax
fld dword [esp + 0x28]
fnstcw word [esp + 0x14]
movzx eax, word [esp + 0x14]
or eax, 0xc00
mov dword [esp + 0x2c], eax
fldcw word [esp + 0x2c]
fistp qword [esp + 0x2c]
mov ecx, dword [esp + 0x2c]
imul ecx, dword [esp + 0x6c]
fldcw word [esp + 0x14]
test ecx, ecx
mov dword [esp + 0x2c], ecx
fild dword [esp + 0x2c]
jge 0x4224e5
fadd qword [0x659f10]
fdiv qword [0x659f08]
lea edx, [esp + 0x38]
push edx
fnstcw word [esp + 0x18]
movzx eax, word [esp + 0x18]
or eax, 0xc00
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x4c]
push eax
fldcw word [esp + 0x34]
fistp qword [esp + 0x34]
mov edi, dword [esp + 0x34]
fldcw word [esp + 0x1c]
call sub.gdiplus.dll_GdipGetDpiX
test eax, eax
je 0x422524
mov dword [esp + 0x4c], eax
fld dword [esp + 0x38]
mov esi, dword [esp + 0x68]
fnstcw word [esp + 0x14]
movzx eax, word [esp + 0x14]
or eax, 0xc00
mov dword [esp + 0x2c], eax
fldcw word [esp + 0x2c]
fistp qword [esp + 0x2c]
mov ecx, dword [esp + 0x2c]
fldcw word [esp + 0x14]
imul ecx, esi
test ecx, ecx
mov dword [esp + 0x2c], ecx
fild dword [esp + 0x2c]
jge 0x422563
fadd qword [0x659f10]
fdiv qword [0x659f08]
lea edx, [esp + 0x14]
push edx
push 0
push 0x26200a
push 0
push edi
mov dword [esp + 0x84], vtable.Gdiplus::Bitmap.0
fnstcw word [esp + 0x28]
movzx eax, word [esp + 0x28]
or eax, 0xc00
mov dword [esp + 0x40], eax
fldcw word [esp + 0x40]
fistp qword [esp + 0x40]
mov eax, dword [esp + 0x40]
push eax
fldcw word [esp + 0x2c]
mov dword [esp + 0x2c], 0
call sub.gdiplus.dll_GdipCreateBitmapFromScan0
mov edi, dword [esp + 0x14]
mov dword [esp + 0x78], eax
mov dword [esp + 0x74], edi
mov ecx, dword [esp + 0x48]
lea eax, [esp + 0x3c]
push eax
push ecx
call sub.gdiplus.dll_GdipGetDpiY
test eax, eax
je 0x4225d6
mov dword [esp + 0x4c], eax
mov eax, dword [esp + 0x48]
fld dword [esp + 0x3c]
lea edx, [esp + 0x40]
fstp dword [esp + 0x2c]
push edx
push eax
call sub.gdiplus.dll_GdipGetDpiX
test eax, eax
je 0x4225f5
mov dword [esp + 0x4c], eax
fld dword [esp + 0x2c]
sub esp, 8
fstp dword [esp + 4]
fld dword [esp + 0x48]
fstp dword [esp]
push edi
call sub.gdiplus.dll_GdipBitmapSetResolution
test eax, eax
je 0x422615
mov dword [esp + 0x78], eax
lea ecx, [esp + 0x14]
push ecx
push edi
mov dword [esp + 0x1c], 0
call sub.gdiplus.dll_GdipGetImageGraphicsContext
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x14]
mov dword [esp + 0x58], eax
push 3
push eax
mov byte [esp + 0xa8], 2
call sub.gdiplus.dll_GdipSetPageUnit
test eax, eax
je 0x42264c
mov dword [esp + 0x5c], eax
mov edx, dword [esp + 0x60]
mov ecx, dword [esp + 0x64]
sub esp, 0x10
mov eax, esp
mov dword [eax], edx
mov edx, dword [esp + 0x7c]
mov dword [eax + 4], ecx
push 0
mov dword [eax + 8], esi
mov esi, dword [esp + 0x2c]
push 0
mov dword [eax + 0xc], edx
lea eax, [esp + 0x70]
push eax
push esi
push ebx
call fcn.00423680
mov ecx, dword [esp + 0x58]
add esi, 1
push ecx
mov dword [esp + 0x1c], esi
call sub.gdiplus.dll_GdipDeleteGraphics
lea edx, [esp + 0x60]
push edx
lea eax, [esp + 0x74]
push eax
lea ecx, [esp + 0x50]
call fcn.00408ce0
mov byte [esp + 0xa0], 0
push edi
mov dword [esp + 0x74], vtable.Gdiplus::Image.0
call sub.gdiplus.dll_GdipDisposeImage
mov esi, dword [esp + 0x1c]
jmp 0x422713
mov edi, dword [esp + 0x44]
test edi, edi
je 0x4226d2
mov eax, dword [ebx + 4]
mov eax, dword [eax + 0xc]
test eax, eax
je 0x4226d2
or dword [eax + 0x34], 0x11
sub esp, 0x10
mov eax, esp
mov dword [eax], edx
mov edx, dword [esp + 0x7c]
mov dword [eax + 4], ecx
mov ecx, dword [esp + 0x78]
push 0
mov dword [eax + 8], ecx
mov ecx, dword [esp + 0x2c]
push 0
mov dword [eax + 0xc], edx
lea eax, [esp + 0x60]
push eax
push ecx
push ebx
call fcn.00423680
add dword [esp + 0x18], 1
test edi, edi
je 0x422713
mov eax, dword [ebx + 4]
mov edx, dword [eax + 0xc]
mov eax, dword [eax + 0x18]
mov dword [edx + 0x34], eax
push esi
call dword [sym.imp.GDI32.dll_EndPage]
test eax, eax
jle 0x42273d
mov ecx, dword [ebp + 0xc]
test ecx, ecx
je 0x422739
mov eax, dword [esp + 0x20]
mov edx, dword [ecx]
mov edx, dword [edx]
push eax
mov eax, dword [esp + 0x1c]
push eax
call edx
test al, al
je 0x422772
xor edi, edi
jmp 0x422742
mov edi, 3
mov dword [esp + 0xa0], 0xffffffff
mov eax, dword [esp + 0x48]
push eax
call sub.gdiplus.dll_GdipDeleteGraphics
jmp 0x42275e
mov edi, 3
mov ecx, dword [esp + 0x20]
cmp dword [esp + 0x18], ecx
jb 0x4223b0
mov esi, dword [esp + 0x1c]
jmp 0x422792
push esi
call dword [sym.imp.GDI32.dll_AbortDoc]
mov edx, dword [esp + 0x48]
push edx
mov edi, 1
call sub.gdiplus.dll_GdipDeleteGraphics
mov esi, dword [esp + 0x1c]
jmp 0x4227a6
mov edi, dword [esp + 0x44]
test edi, edi
jne 0x4227a6
push esi
call dword [sym.imp.GDI32.dll_EndDoc]
test eax, eax
jg 0x4227a6
mov edi, 3
push esi
call dword [sym.imp.GDI32.dll_DeleteDC]
movzx ecx, word [ebx + 0x74]
mov eax, dword [ebx + 0x60]
mov word [eax + 0x4e], cx
mov edx, dword [ebx + 0x60]
mov ax, word [ebx + 0x76]
mov word [edx + 0x52], ax
mov ecx, dword [ebx + 0x60]
mov dx, word [ebx + 0x78]
mov word [ecx + 0x50], dx
movzx ecx, word [ebx + 0x7a]
mov eax, dword [ebx + 0x60]
mov word [eax + 0x4c], cx
mov eax, edi
mov ecx, dword [esp + 0x98]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
mov eax, 3
mov ecx, dword [esp + 0x98]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8