Function at 0x431660
Capabilities:
Link many functions at runtime
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x8bc
mov eax, dword [0x4b7014]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov edi, dword [0x4ba84c]
push 0
mov dword [ebp - 0x8ac], edi
mov dword [ebp - 0x8bc], 1
mov dword [ebp - 0x8b8], 0
mov dword [ebp - 0x8b4], 0
mov dword [ebp - 0x8b0], 0
call dword [sym.imp.ole32.dll_CoInitialize]
cmp dword [0x4b9a00], 0
jne 0x4316ec
push 0
lea eax, [ebp - 0x8bc]
push eax
push 0x4b9a00
call dword [sym.imp.gdiplus.dll_GdiplusStartup]
test eax, eax
je 0x4316ec
push 0x30
push str.Error
push str.Error_loading_Gdi
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
jmp 0x4320e8
lea esi, [edi + 0x2c]
push esi
push 0x48b540
push 1
push 0
push 0x48b520
call dword [sym.imp.ole32.dll_CoCreateInstance]
mov ebx, dword [sym.imp.USER32.dll_MessageBoxA]
test eax, eax
jns 0x431719
mov dword [esi], 0
jmp 0x431907
mov eax, dword [esi]
lea edx, [edi + 0x98]
push edx
push 2
push 0x48b530
push dword [0x4b9a4c]
mov ecx, dword [eax]
push dword [0x4b9a48]
push eax
call dword [ecx + 0x44]
test eax, eax
jns 0x43175c
push eax
mov ecx, eax
mov dword [edi + 0x98], 0
call fcn.00435170
push eax
push str.Error_creating_webcam_bitmap_n_s___x_
jmp 0x4318e1
lea esi, [edi + 0x28]
push esi
push 0
push 0x4b00a4
push 0
call dword [sym.imp.d2d1.dll_Ordinal_1]
test eax, eax
jns 0x43178c
push eax
mov ecx, eax
mov dword [esi], 0
call fcn.00435170
push eax
push str.Error_loading_D2D_n_s___x_
jmp 0x4318e1
mov ecx, dword [esi]
lea edx, [edi + 0x30]
mov dword [ebp - 0x89c], 0
lea esi, [edi + 0x9c]
mov dword [ebp - 0x8a8], 0
mov dword [ebp - 0x8a4], 0x57
mov dword [ebp - 0x8a0], 1
movups xmm0, xmmword [ebp - 0x8a8]
mov dword [ebp - 0x898], 0
mov dword [ebp - 0x894], 2
movups xmmword [edx], xmm0
mov dword [ebp - 0x89c], 0
movq xmm0, qword [ebp - 0x898]
movq qword [edx + 0x10], xmm0
mov dword [ebp - 0x8a8], 0
mov dword [ebp - 0x8a4], 0
mov dword [ebp - 0x8a0], 0
movups xmm0, xmmword [ebp - 0x8a8]
mov dword [ebp - 0x898], 0
mov dword [ebp - 0x894], 0
movups xmmword [edi + 0x4c], xmm0
mov dword [ebp - 0x880], 0
movq xmm0, qword [ebp - 0x898]
movq qword [edi + 0x5c], xmm0
movss xmm0, dword [ebp - 0x880]
movss dword [ebp - 0x89c], xmm0
mov dword [ebp - 0x87c], 0
movss xmm0, dword [ebp - 0x87c]
movss dword [ebp - 0x898], xmm0
mov dword [ebp - 0x894], 0x42c00000
mov dword [ebp - 0x890], 0x42c00000
movups xmm0, xmmword [ebp - 0x89c]
push esi
mov dword [edi + 0x64], 0
movups xmmword [edi + 0x68], xmm0
push edx
push dword [edi + 0x98]
mov dword [edx + 0x18], 0
mov dword [edi + 0x50], 0x57
mov dword [edi + 0x54], 3
mov dword [edi + 0x68], 0x57
mov dword [edi + 0x6c], 3
mov eax, dword [ecx]
push ecx
call dword [eax + 0x34]
test eax, eax
jns 0x43191b
push eax
mov ecx, eax
mov dword [esi], 0
call fcn.00435170
push eax
push str.Error_creating_webcam_render_target_n_s___x_
lea eax, [ebp - 0x108]
push 0x100
push eax
call fcn.0042dcd0
add esp, 0x14
lea eax, [ebp - 0x108]
push 0x30
push str.Error
push eax
push 0
call ebx
mov dword [0x4b9a78], 1
mov dword [edi + 0xa0], 1
mov esi, dword [sym.imp.KERNEL32.dll_CreateMutexA]
push 0
push 0
push 0
call esi
push 0
push 0
push 0
mov dword [0x4b99d8], eax
call esi
cmp dword [0x4b99d8], 0
mov dword [0x4b99fc], eax
je 0x4320ab
test eax, eax
je 0x4320ab
mov esi, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
push str.avcodec_58.dll
call esi
mov dword [0x4b99f4], eax
test eax, eax
je 0x431b0e
push str.avutil_56.dll
call esi
push str.swscale_5.dll
mov dword [0x4b99e0], eax
call esi
mov ecx, dword [0x4b99f4]
mov dword [0x4b99f8], eax
test ecx, ecx
je 0x431b0e
cmp dword [0x4b99e0], 0
je 0x431b0e
test eax, eax
je 0x431b0e
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.avcodec_find_decoder
push ecx
mov dword [ebp - 0x884], 1
call esi
push str.avcodec_find_decoder_by_name
push dword [0x4b99f4]
mov dword [0x4b9a14], eax
call esi
push str.avcodec_alloc_context3
push dword [0x4b99f4]
call esi
push str.avcodec_open2
push dword [0x4b99f4]
mov dword [0x4b9a28], eax
call esi
push str.avcodec_close
push dword [0x4b99f4]
mov dword [0x4b9a20], eax
call esi
push str.avcodec_send_packet
push dword [0x4b99f4]
mov dword [0x4b9a34], eax
call esi
push str.avcodec_receive_frame
push dword [0x4b99f4]
mov dword [0x4b9a2c], eax
call esi
push str.av_init_packet
push dword [0x4b99f4]
mov dword [0x4b9a30], eax
call esi
push str.av_packet_alloc
push dword [0x4b99f4]
mov dword [0x4b9a0c], eax
call esi
push str.av_packet_free
push dword [0x4b99f4]
mov dword [0x4b9a3c], eax
call esi
push str.av_packet_unref
push dword [0x4b99f4]
mov dword [0x4b9a1c], eax
call esi
push str.avcodec_get_hw_config
push dword [0x4b99f4]
call esi
push str.av_hwdevice_ctx_create
push dword [0x4b99e0]
call esi
push str.av_hwframe_transfer_data
push dword [0x4b99e0]
call esi
push str.av_frame_alloc
push dword [0x4b99e0]
call esi
push str.av_buffer_ref
push dword [0x4b99e0]
mov dword [0x4b9a08], eax
call esi
push str.av_buffer_unref
push dword [0x4b99e0]
call esi
push str.av_freep
push dword [0x4b99e0]
mov dword [0x4b9a38], eax
call esi
push str.sws_scale
push dword [0x4b99f8]
mov dword [0x4b9a10], eax
call esi
push str.sws_freeContext
push dword [0x4b99f8]
mov dword [0x4b9a18], eax
call esi
push str.sws_getContext
push dword [0x4b99f8]
mov dword [0x4b9a04], eax
call esi
mov dword [0x4b9a24], eax
jmp 0x431b18
mov dword [ebp - 0x884], 0
lea eax, [edi + 0xac]
mov dword [ebp - 0x888], 0
mov ecx, eax
mov dword [ebp - 0x87c], eax
mov eax, dword [ecx]
mov ebx, dword [eax + 0x158]
lea esi, [ebx + 0x2b0]
mov dword [ebx + 0x8c0], 0
push esi
mov dword [ebx + 0x6a8], 0
lea edi, [ebx + 0x100]
mov dword [ebx + 0x6b0], 0
mov dword [ebx + 0x6ac], 0
call fcn.0043d500
add esp, 4
mov dword [edi], eax
mov dword [ebx + 0x2b8], 0x432bb0
mov dword [esi], 0x432bf0
mov dword [ebx + 0x10c], ebx
push 0x1b0
push 0x3e
push edi
call fcn.0043ce20
add esp, 0xc
cmp dword [ebx + 0x6a8], 0
jne 0x432093
lea eax, [ebx + 0x33c]
push eax
call fcn.0041a452
add esp, 4
push 1
call 0x41ae9f
add esp, 4
push eax
call fcn.00419fe4
add esp, 4
mov dword [ebx + 0x338], eax
lea ecx, [ebx + 0x360]
push ecx
push 3
push eax
call fcn.0041a290
add esp, 0xc
cmp dword [ebp - 0x884], 0
je 0x431c76
push 0x1b
call dword [0x4b9a14]
add esp, 4
mov dword [ebx + 0xac], eax
test eax, eax
je 0x431c76
push eax
call dword [0x4b9a28]
add esp, 4
mov dword [ebx + 0xa8], eax
push 0
push dword [ebx + 0xac]
push eax
call dword [0x4b9a20]
add esp, 0xc
test eax, eax
jns 0x431c38
mov dword [ebx + 0xac], 0
jmp 0x431c76
mov eax, dword [ebx + 0xa8]
or dword [eax + 0x3c], 0x80000
mov eax, dword [ebx + 0xa8]
or dword [eax + 0x40], 1
mov eax, dword [ebx + 0xa8]
or dword [eax + 0x40], 0x8000
mov eax, dword [ebx + 0xa8]
mov dword [eax + 0x2b4], 2
mov dword [ebx + 0x6ac], 1
cmp dword [0x4b9aa0], 1
je 0x431ca4
mov eax, dword [ebp - 0x888]
mov ecx, dword [ebp - 0x87c]
inc eax
add ecx, 4
mov dword [ebp - 0x888], eax
mov dword [ebp - 0x87c], ecx
cmp eax, 3
jl 0x431b30
push str.GlobalDroidCam_vcd_write
push 1
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
mov ebx, dword [ebp - 0x8ac]
mov edi, str.Undefined_Error
mov esi, 0x4bba88
mov dword [ebx + 0x14], eax
test eax, eax
jne 0x431d03
push eax
push 0xff
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0
push 0x1000
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push 0x30
test eax, eax
mov ecx, edi
push str.Video_sync_object_error__image_may_flicker.
cmovne ecx, esi
mov esi, dword [sym.imp.USER32.dll_MessageBoxA]
push ecx
push 0
call esi
jmp 0x431d09
mov esi, dword [sym.imp.USER32.dll_MessageBoxA]
push str.GlobalDroidCam_vcd_src2
push 1
push 1
push 0
call dword [sym.imp.KERNEL32.dll_CreateEventA]
push str.GlobalDroidCam_vcd_src3
push 1
push 1
push 0
mov dword [ebx + 0x18], eax
call dword [sym.imp.KERNEL32.dll_CreateEventA]
push str.DroidCam_vcd_mmap
push 0x5eec00
push 0
push 4
push 0
push 0xffffffffffffffff
mov dword [ebx + 0x1c], eax
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov dword [ebx + 4], eax
test eax, eax
jne 0x431d55
mov dword [ebx + 0xc], eax
jmp 0x431d7b
push 0
push 0
push 0
push 2
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebx + 0xc], eax
test eax, eax
jne 0x431dba
push dword [ebx + 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebx + 4], 0
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
push 0
push 0xff
push 0x4bba88
push 0
call eax
push eax
mov eax, dword [sym.imp.KERNEL32.dll_FormatMessageA]
push 0
push 0x1000
call eax
test eax, eax
mov eax, 0x4bba88
push 0x30
push str.Video_Mapping_Error
cmovne edi, eax
push edi
push 0
call esi
jmp 0x4320e8
push str.DroidCam_vad_mmap
push 0x2000
push 0
push 4
push 0
push 0xffffffffffffffff
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov dword [ebx + 8], eax
test eax, eax
jne 0x431dde
mov dword [ebx + 0x10], eax
jmp 0x431e04
push 0
push 0
push 0
push 2
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebx + 0x10], eax
test eax, eax
jne 0x431e63
push dword [ebx + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebx + 8], 0
mov eax, dword [sym.imp.KERNEL32.dll_GetLastError]
push 0
push 0xff
push 0x4bba88
push 0
call eax
push eax
mov eax, dword [sym.imp.KERNEL32.dll_FormatMessageA]
push 0
push 0x1000
call eax
test eax, eax
mov eax, 0x4bba88
push 0x30
push str.Audio_Mapping_Error
cmovne edi, eax
push edi
push 0
call esi
push dword [ebx + 0xc]
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
push dword [ebx + 4]
mov dword [ebx + 0xc], 0
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebx + 4], 0
jmp 0x4320e8
mov dword [ebx + 0x24], eax
lea ecx, [ebx + 0x14]
mov eax, dword [ebx + 0xc]
mov dword [ebx + 0x20], eax
mov eax, dword [ebx + 0xac]
mov eax, dword [eax + 0x158]
mov dword [eax], ecx
mov ecx, dword [ebx + 0xac]
mov ecx, dword [ecx + 0x158]
call fcn.00434c50
mov edx, 0x4b0ed4
mov ecx, str.droidcam_client_options_v2
call fcn.0043bca0
mov ebx, eax
test ebx, ebx
jne 0x431ffb
mov edx, 0x4b0ed4
mov ecx, str.droidcam_client_options_v1
call fcn.0043bca0
mov ebx, eax
test ebx, ebx
je 0x43207b
push 0x324
lea eax, [ebp - 0x550]
push 0
push eax
call fcn.004581b0
mov eax, dword [0x4bba68]
add esp, 0xc
mov dword [0x4bba6c], eax
lea eax, [ebp - 0x228]
push ebx
push 1
push 0x120
push eax
call fcn.00462fe4
add esp, 0x10
cmp eax, 1
jne 0x432072
lea eax, [ebp - 0x228]
push eax
lea eax, [ebp - 0x550]
push 0x100
push eax
call fcn.00462ac5
mov eax, dword [ebp - 0x128]
add esp, 0xc
mov dword [ebp - 0x450], eax
mov eax, dword [ebp - 0x124]
mov dword [ebp - 0x44c], eax
mov eax, dword [ebp - 0x120]
mov dword [ebp - 0x448], eax
mov eax, dword [ebp - 0x11c]
mov dword [ebp - 0x444], eax
mov eax, dword [ebp - 0x118]
mov dword [ebp - 0x440], eax
mov eax, dword [ebp - 0x114]
mov dword [ebp - 0x43c], eax
mov eax, dword [ebp - 0x110]
mov dword [ebp - 0x434], eax
mov eax, dword [ebp - 0x10c]
mov dword [ebp - 0x430], eax
mov eax, dword [0x4bba6c]
mov dword [ebp - 0x438], 0x32
cmp dword [0x4bba70], eax
je 0x431fad
mov ecx, 0xc9
lea esi, [ebp - 0x550]
mov edi, eax
rep movsd dword es:[edi], dword [esi]
add dword [0x4bba6c], 0x324
jmp 0x431fba
lea ecx, [ebp - 0x550]
push ecx
push eax
call fcn.00430f50
push ebx
push 1
lea eax, [ebp - 0x228]
push 0x120
push eax
call fcn.00462fe4
add esp, 0x10
cmp eax, 1
je 0x431f00
push ebx
call fcn.0045d801
add esp, 4
mov eax, 1
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004555d3
mov esp, ebp
pop ebp
ret 8
mov eax, dword [0x4bba68]
push ebx
push 1
mov dword [0x4bba6c], eax
lea eax, [ebp - 0x878]
push 0x324
push eax
call fcn.00462fe4
add esp, 0x10
cmp eax, 1
jne 0x432072
mov eax, dword [0x4bba6c]
cmp dword [0x4bba70], eax
je 0x432049
mov ecx, 0xc9
lea esi, [ebp - 0x878]
mov edi, eax
rep movsd dword es:[edi], dword [esi]
add dword [0x4bba6c], 0x324
jmp 0x432056
lea ecx, [ebp - 0x878]
push ecx
push eax
call fcn.00430f50
push ebx
push 1
lea eax, [ebp - 0x878]
push 0x324
push eax
call fcn.00462fe4
add esp, 0x10
cmp eax, 1
je 0x432021
push ebx
call fcn.0045d801
add esp, 4
mov eax, 1
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004555d3
mov esp, ebp
pop ebp
ret 8
mov esi, dword [sym.imp.USER32.dll_MessageBoxA]
push 0x30
push str.Error
push str.Client_Initialize_Error
push 0
call esi
jmp 0x4320e8
push 0
push 0xff
push 0x4bba88
push 0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0
push 0x1000
call dword [sym.imp.KERNEL32.dll_FormatMessageA]
push 0x30
test eax, eax
mov edx, 0x4bba88
mov ecx, str.Undefined_Error
push str.Error_making_IPC_sync_lock
cmovne ecx, edx
push ecx
push 0
call ebx
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004555d3
mov esp, ebp
pop ebp
ret 8