Function at 0x4505f8
Capabilities:
Capture screenshot

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
push esi
mov esi, ecx
push edi
cmp dword [esi + 0x68], 0
jne 0x450614
push 0
call dword [sym.imp.USER32.dll_GetDC]
mov dword [esi + 0x68], eax
mov eax, dword [esi + 0x68]
test eax, eax
jne 0x450641
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x14]
push str.GetDC_NULL__ERROR_d
push eax
call fcn.00430892
add esp, 0xc
lea eax, [ebp - 0x14]
push 0x49c754
push eax
call sub.MSVCRT.dll__CxxThrowException
push eax
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
test eax, eax
mov dword [esi + 0x64], eax
jne 0x450675
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x14]
push str.CreateCompatibleDC___ERROR_d
push eax
call fcn.00430892
add esp, 0xc
lea eax, [ebp - 0x14]
push 0x49c754
push eax
call sub.MSVCRT.dll__CxxThrowException
mov edi, dword [sym.imp.GDI32.dll_GetDeviceCaps]
push 0x26
push dword [esi + 0x68]
call edi
test al, 1
jne 0x4506a4
lea eax, [ebp - 0x14]
push str.ERROR:_root_device_doesnt_support_BitBlt
push eax
call fcn.00430892
pop ecx
lea eax, [ebp - 0x14]
pop ecx
push 0x49c754
push eax
call sub.MSVCRT.dll__CxxThrowException
push 0x26
push dword [esi + 0x64]
call edi
test al, al
js 0x4506cd
lea eax, [ebp - 0x14]
push str.ERROR:_memory_device_doesnt_support_GetDIBits
push eax
call fcn.00430892
pop ecx
lea eax, [ebp - 0x14]
pop ecx
push 0x49c754
push eax
call sub.MSVCRT.dll__CxxThrowException
push dword [esi + 0xc]
push dword [esi + 8]
push dword [esi + 0x68]
call dword [sym.imp.GDI32.dll_CreateCompatibleBitmap]
test eax, eax
mov dword [esi + 0x4b4], eax
jne 0x45070c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x14]
push str.CreateCompatibleBitmap___ERROR_d
push eax
call fcn.00430892
add esp, 0xc
lea eax, [ebp - 0x14]
push 0x49c754
push eax
call sub.MSVCRT.dll__CxxThrowException
push str.created_memory_bitmap
push str.S:Ammyy_sources_targetTrDesktopCapture.cpp
mov ebx, 0x4c2700
push 2
push ebx
call fcn.00420f3e
lea eax, [esi + 0x70]
push 0x2c
push 0
push eax
call sub.MSVCRT.dll_memset
add esp, 0x1c
xor ecx, ecx
lea eax, [esi + 0x70]
push ecx
push eax
push ecx
push 1
push ecx
mov dword [eax], 0x28
push dword [esi + 0x4b4]
push dword [esi + 0x64]
call dword [sym.imp.GDI32.dll_GetDIBits]
test eax, eax
jne 0x45077d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x14]
push str.GetDIBits__1_ERROR_d
push eax
call fcn.00430892
add esp, 0xc
lea eax, [ebp - 0x14]
push 0x49c754
push eax
call sub.MSVCRT.dll__CxxThrowException
xor ecx, ecx
lea eax, [esi + 0x70]
push ecx
push eax
push ecx
push 1
push ecx
push dword [esi + 0x4b4]
push dword [esi + 0x64]
call dword [sym.imp.GDI32.dll_GetDIBits]
test eax, eax
jne 0x4507c1
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x14]
push str.GetDIBits__2_ERROR_d
push eax
call fcn.00430892
add esp, 0xc
lea eax, [ebp - 0x14]
push 0x49c754
push eax
call sub.MSVCRT.dll__CxxThrowException
push 0xe
push dword [esi + 0x64]
call edi
push 0xe
mov dword [ebp - 4], eax
push dword [esi + 0x68]
call edi
push dword [ebp - 4]
mov dword [ebp - 8], eax
push str.DBG:memory_context_has__d_planes_
push str.S:Ammyy_sources_targetTrDesktopCapture.cpp
push 2
push ebx
call fcn.00420f3e
push dword [ebp - 8]
push str.DBG:display_context_has__d_planes_
push str.S:Ammyy_sources_targetTrDesktopCapture.cpp
push 2
push ebx
call fcn.00420f3e
add esp, 0x28
cmp dword [ebp - 4], 1
je 0x450826
lea eax, [ebp - 0x14]
push str.ERROR:_current_display_is_PLANAR__not_CHUNKY
push eax
call fcn.00430892
pop ecx
lea eax, [ebp - 0x14]
pop ecx
push 0x49c754
push eax
call sub.MSVCRT.dll__CxxThrowException
push dword [esi + 0x78]
call sub.MSVCRT.dll_abs
pop ecx
push 0x26
push dword [esi + 0x64]
neg eax
mov dword [esi + 0x78], eax
call edi
not eax
shr eax, 8
and eax, 1
pop edi
mov dword [esi + 0x6c], eax
pop esi
pop ebx
leave
ret