	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vtenc_send_frame
_vtenc_send_frame:                      ## @vtenc_send_frame
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r13
	movq	%rsi, %r14
	movq	%rdi, %r15
	movq	$0, -48(%rbp)
	leaq	-48(%rbp), %rdx
	movq	%r13, %rsi
	callq	_create_cv_pixel_buffer
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_16
## %bb.1:
	leaq	-56(%rbp), %rsi
	movq	%r13, %rdi
	callq	_create_encoder_dict_h264
	testl	%eax, %eax
	je	LBB0_3
## %bb.2:
	movl	%eax, %ebx
	movq	-48(%rbp), %rdi
	callq	_CFRelease
	jmp	LBB0_16
LBB0_3:
	movq	_AV_FRAME_DATA_A53_CC@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_av_frame_get_side_data
	xorl	%r12d, %r12d
	cmpq	$0, 8(%r14)
	je	LBB0_11
## %bb.4:
	testq	%rax, %rax
	je	LBB0_11
## %bb.5:
	cmpq	$0, (%rax)
	je	LBB0_10
## %bb.6:
	movl	$8, %edi
	callq	_av_mallocz
	testq	%rax, %rax
	je	LBB0_7
## %bb.8:
	movq	%rax, %r12
	movq	%rax, %rdx
	addq	$4, %rdx
	movq	%r13, %rdi
	xorl	%esi, %esi
	movq	%rax, %rcx
	callq	_ff_alloc_a53_sei
	testl	%eax, %eax
	jns	LBB0_11
## %bb.9:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r15, %rdi
	xorl	%eax, %eax
	callq	_av_log
	movq	%r12, %rdi
	callq	_av_free
LBB0_10:
	xorl	%r12d, %r12d
	jmp	LBB0_11
LBB0_7:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	xorl	%r12d, %r12d
	movq	%r15, %rdi
	xorl	%eax, %eax
	callq	_av_log
LBB0_11:
	movl	(%r15), %edi
	movl	4(%r15), %esi
	imull	(%r13), %edi
	callq	_CMTimeMake
	movl	(%r14), %edi
	movq	-48(%rbp), %rsi
	movq	_kCMTimeInvalid@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	-56(%rbp), %r8
	movq	$0, (%rsp)
	movl	%eax, %edx
	movq	%r12, %r9
	callq	_VTCompressionSessionEncodeFrame
	movl	%eax, %ebx
	movq	-56(%rbp), %rdi
	testq	%rdi, %rdi
	je	LBB0_13
## %bb.12:
	callq	_CFRelease
LBB0_13:
	movq	-48(%rbp), %rdi
	callq	_CFRelease
	testl	%ebx, %ebx
	je	LBB0_14
## %bb.15:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	movq	%r15, %rdi
	movl	%ebx, %ecx
	xorl	%eax, %eax
	callq	_av_log
	movq	_AVERROR_EXTERNAL@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_16
LBB0_14:
	xorl	%ebx, %ebx
LBB0_16:
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_FRAME_DATA_A53_CC,4,2       ## @AV_FRAME_DATA_A53_CC
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Not enough memory for closed captions, skipping\n"

	.comm	_kCMTimeInvalid,4,2             ## @kCMTimeInvalid
L_.str.1:                               ## @.str.1
	.asciz	"Error: cannot encode frame: %d\n"

	.comm	_AVERROR_EXTERNAL,4,2           ## @AVERROR_EXTERNAL
	.no_dead_strip	_vtenc_send_frame
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vtenc_send_frame
_vtenc_send_frame:                      ; @vtenc_send_frame
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #80
	.cfi_def_cfa_offset 80
	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
	mov	x21, x2
	mov	x20, x1
	mov	x19, x0
	str	xzr, [sp, #16]
	add	x2, sp, #16
	mov	x1, x21
	bl	_create_cv_pixel_buffer
	mov	x22, x0
	cbnz	w0, LBB0_16
; %bb.1:
	add	x1, sp, #24
	mov	x0, x21
	bl	_create_encoder_dict_h264
	cbz	w0, LBB0_3
; %bb.2:
	mov	x22, x0
	ldr	x0, [sp, #16]
	bl	_CFRelease
	b	LBB0_16
LBB0_3:
Lloh0:
	adrp	x8, _AV_FRAME_DATA_A53_CC@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AV_FRAME_DATA_A53_CC@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	x0, x21
	bl	_av_frame_get_side_data
	mov	x22, #0
	ldr	x8, [x20, #8]
	cbz	x8, LBB0_11
; %bb.4:
	cbz	x0, LBB0_11
; %bb.5:
	ldr	x8, [x0]
	cbz	x8, LBB0_9
; %bb.6:
	mov	w0, #8
	bl	_av_mallocz
	mov	x22, x0
	cbz	x0, LBB0_10
; %bb.7:
	add	x2, x22, #4
	mov	x0, x21
	mov	w1, #0
	mov	x3, x22
	bl	_ff_alloc_a53_sei
	tbz	w0, #31, LBB0_11
; %bb.8:
Lloh3:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
Lloh6:
	adrp	x2, l_.str@PAGE
Lloh7:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_av_log
	mov	x0, x22
	bl	_av_free
LBB0_9:
	mov	x22, #0
	b	LBB0_11
LBB0_10:
Lloh8:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh9:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
Lloh11:
	adrp	x2, l_.str@PAGE
Lloh12:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_av_log
LBB0_11:
	ldr	w8, [x21]
	ldp	w9, w1, [x19]
	mul	w0, w9, w8
	bl	_CMTimeMake
	mov	x2, x0
	ldr	w0, [x20]
	ldp	x1, x4, [sp, #16]
Lloh13:
	adrp	x8, _kCMTimeInvalid@GOTPAGE
Lloh14:
	ldr	x8, [x8, _kCMTimeInvalid@GOTPAGEOFF]
Lloh15:
	ldr	w3, [x8]
	mov	x5, x22
	mov	x6, #0
	bl	_VTCompressionSessionEncodeFrame
	mov	x20, x0
	ldr	x0, [sp, #24]
	cbz	x0, LBB0_13
; %bb.12:
	bl	_CFRelease
LBB0_13:
	ldr	x0, [sp, #16]
	bl	_CFRelease
	cbz	w20, LBB0_15
; %bb.14:
Lloh16:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh17:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh18:
	ldr	w1, [x8]
	str	x20, [sp]
Lloh19:
	adrp	x2, l_.str.1@PAGE
Lloh20:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_av_log
Lloh21:
	adrp	x8, _AVERROR_EXTERNAL@GOTPAGE
Lloh22:
	ldr	x8, [x8, _AVERROR_EXTERNAL@GOTPAGEOFF]
Lloh23:
	ldr	w22, [x8]
	b	LBB0_16
LBB0_15:
	mov	w22, #0
LBB0_16:
	mov	x0, x22
	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
	add	sp, sp, #80
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpAdd	Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_FRAME_DATA_A53_CC,4,2       ; @AV_FRAME_DATA_A53_CC
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Not enough memory for closed captions, skipping\n"

	.comm	_kCMTimeInvalid,4,2             ; @kCMTimeInvalid
l_.str.1:                               ; @.str.1
	.asciz	"Error: cannot encode frame: %d\n"

	.comm	_AVERROR_EXTERNAL,4,2           ; @AVERROR_EXTERNAL
	.no_dead_strip	_vtenc_send_frame
.subsections_via_symbols
