	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vc_container_bitmapinfoheader_to_es_format ## -- Begin function vc_container_bitmapinfoheader_to_es_format
	.p2align	4, 0x90
_vc_container_bitmapinfoheader_to_es_format: ## @vc_container_bitmapinfoheader_to_es_format
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_VC_CONTAINER_ERROR_INVALID_ARGUMENT@GOTPCREL(%rip), %rax
	testq	%rdi, %rdi
	je	LBB0_9
## %bb.1:
	movl	%esi, %ebx
	movq	_BITMAPINFOHEADER_SIZE_MAX@GOTPCREL(%rip), %r13
	cmpl	%esi, (%r13)
	ja	LBB0_9
## %bb.2:
	movq	%r8, %r12
	movq	%rcx, %r14
	movq	%rdx, %r15
	movq	%rdi, %rsi
	movl	28(%rdi), %eax
	shll	$24, %eax
	movl	20(%rdi), %ecx
	movl	24(%rdi), %edx
	shll	$16, %edx
	orl	%eax, %edx
	shll	$8, %ecx
	orl	%edx, %ecx
	orl	16(%rdi), %ecx
	movq	16(%r8), %rax
	movl	%ecx, (%rax)
	movl	44(%rdi), %ecx
	shll	$24, %ecx
	movl	36(%rdi), %edx
	movl	40(%rdi), %edi
	shll	$16, %edi
	orl	%ecx, %edi
	shll	$8, %edx
	orl	%edi, %edx
	orl	32(%rsi), %edx
	movl	%edx, 4(%rax)
	addq	$64, %rsi
	leaq	-48(%rbp), %rdi
	movl	$4, %edx
	callq	_memcpy
	movq	_VC_CONTAINER_ES_TYPE_VIDEO@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 8(%r12)
	movq	-48(%rbp), %rdi
	callq	_vfw_fourcc_to_codec
	movq	%rax, (%r12)
	cmpq	-48(%rbp), %rax
	jne	LBB0_5
## %bb.3:
	movq	%rax, %rdi
	callq	_fourcc_to_codec
	movq	_VC_CONTAINER_CODEC_UNKNOWN@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_5
## %bb.4:
	movq	%rax, (%r12)
LBB0_5:
	testq	%r15, %r15
	je	LBB0_7
## %bb.6:
	movl	(%r13), %eax
	movl	%eax, (%r15)
LBB0_7:
	movq	_VC_CONTAINER_SUCCESS@GOTPCREL(%rip), %rax
	testq	%r14, %r14
	je	LBB0_9
## %bb.8:
	xorl	%ecx, %ecx
	subl	(%r13), %ebx
	cmovbl	%ecx, %ebx
	movl	%ebx, (%r14)
LBB0_9:
	movl	(%rax), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BITMAPINFOHEADER_SIZE_MAX,4,2  ## @BITMAPINFOHEADER_SIZE_MAX
	.comm	_VC_CONTAINER_ERROR_INVALID_ARGUMENT,4,2 ## @VC_CONTAINER_ERROR_INVALID_ARGUMENT
	.comm	_VC_CONTAINER_ES_TYPE_VIDEO,4,2 ## @VC_CONTAINER_ES_TYPE_VIDEO
	.comm	_VC_CONTAINER_CODEC_UNKNOWN,8,3 ## @VC_CONTAINER_CODEC_UNKNOWN
	.comm	_VC_CONTAINER_SUCCESS,4,2       ## @VC_CONTAINER_SUCCESS
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_vc_container_bitmapinfoheader_to_es_format ; -- Begin function vc_container_bitmapinfoheader_to_es_format
	.p2align	2
_vc_container_bitmapinfoheader_to_es_format: ; @vc_container_bitmapinfoheader_to_es_format
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
Lloh0:
	adrp	x8, _VC_CONTAINER_ERROR_INVALID_ARGUMENT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _VC_CONTAINER_ERROR_INVALID_ARGUMENT@GOTPAGEOFF]
	cbz	x0, LBB0_10
; %bb.1:
	mov	x20, x1
Lloh2:
	adrp	x23, _BITMAPINFOHEADER_SIZE_MAX@GOTPAGE
Lloh3:
	ldr	x23, [x23, _BITMAPINFOHEADER_SIZE_MAX@GOTPAGEOFF]
	ldr	w9, [x23]
	cmp	w9, w1
	b.hi	LBB0_10
; %bb.2:
	mov	x22, x4
	mov	x19, x3
	mov	x21, x2
	ldp	w9, w8, [x0, #24]
	lsl	w9, w9, #16
	orr	w8, w9, w8, lsl #24
	ldp	w10, w9, [x0, #16]
	orr	w8, w8, w9, lsl #8
	orr	w8, w8, w10
	ldr	x9, [x4, #16]
	str	w8, [x9]
	ldp	w10, w8, [x0, #40]
	lsl	w10, w10, #16
	orr	w8, w10, w8, lsl #24
	ldp	w11, w10, [x0, #32]
	orr	w8, w8, w10, lsl #8
	orr	w8, w8, w11
	str	w8, [x9, #4]
	add	x1, x0, #64
	add	x0, sp, #8
	mov	w2, #4
	bl	_memcpy
Lloh4:
	adrp	x8, _VC_CONTAINER_ES_TYPE_VIDEO@GOTPAGE
Lloh5:
	ldr	x8, [x8, _VC_CONTAINER_ES_TYPE_VIDEO@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	str	w8, [x22, #8]
	ldr	x0, [sp, #8]
	bl	_vfw_fourcc_to_codec
	str	x0, [x22]
	ldr	x8, [sp, #8]
	cmp	x0, x8
	b.ne	LBB0_5
; %bb.3:
	bl	_fourcc_to_codec
Lloh7:
	adrp	x8, _VC_CONTAINER_CODEC_UNKNOWN@GOTPAGE
Lloh8:
	ldr	x8, [x8, _VC_CONTAINER_CODEC_UNKNOWN@GOTPAGEOFF]
Lloh9:
	ldr	x8, [x8]
	cmp	x0, x8
	b.eq	LBB0_5
; %bb.4:
	str	x0, [x22]
LBB0_5:
	cbz	x21, LBB0_7
; %bb.6:
	ldr	w8, [x23]
	str	w8, [x21]
LBB0_7:
	cbz	x19, LBB0_9
; %bb.8:
	ldr	w8, [x23]
	subs	w8, w20, w8
	csel	w8, wzr, w8, lo
	str	w8, [x19]
LBB0_9:
Lloh10:
	adrp	x8, _VC_CONTAINER_SUCCESS@GOTPAGE
Lloh11:
	ldr	x8, [x8, _VC_CONTAINER_SUCCESS@GOTPAGEOFF]
LBB0_10:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #80
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_BITMAPINFOHEADER_SIZE_MAX,4,2  ; @BITMAPINFOHEADER_SIZE_MAX
	.comm	_VC_CONTAINER_ERROR_INVALID_ARGUMENT,4,2 ; @VC_CONTAINER_ERROR_INVALID_ARGUMENT
	.comm	_VC_CONTAINER_ES_TYPE_VIDEO,4,2 ; @VC_CONTAINER_ES_TYPE_VIDEO
	.comm	_VC_CONTAINER_CODEC_UNKNOWN,8,3 ; @VC_CONTAINER_CODEC_UNKNOWN
	.comm	_VC_CONTAINER_SUCCESS,4,2       ; @VC_CONTAINER_SUCCESS
.subsections_via_symbols
