	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function vtenc_create_encoder
_vtenc_create_encoder:                  ## @vtenc_create_encoder
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r15
	movq	%rdx, -88(%rbp)                 ## 8-byte Spill
	movl	%esi, %ecx
	movq	%rdi, %r13
	movq	16(%rbp), %rax
	movq	___stack_chk_guard@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	movq	%rdx, -48(%rbp)
	movq	32(%rdi), %r12
	movl	(%rdi), %edx
	movl	%edx, -92(%rbp)
	movl	4(%rdi), %r14d
	movl	$0, -72(%rbp)
	movl	$0, -68(%rbp)
	movq	_kCFAllocatorDefault@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edi
	movl	24(%r13), %edx
	movq	_vtenc_output_callback@GOTPCREL(%rip), %rsi
	movl	(%rsi), %ebx
	movl	28(%r13), %esi
	pushq	%rax
	pushq	%r13
	pushq	%rbx
	pushq	%rdi
	callq	_VTCompressionSessionCreate
	addq	$32, %rsp
	testl	%eax, %eax
	je	LBB0_3
LBB0_1:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r13, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
	cmpl	$0, 80(%r12)
	jne	LBB0_8
## %bb.2:
	movl	(%rbx), %esi
	leaq	L_.str.1(%rip), %rdx
	movq	%r13, %rdi
	xorl	%eax, %eax
	callq	_av_log
	jmp	LBB0_8
LBB0_3:
	cmpl	$0, 16(%r12)
	je	LBB0_1
## %bb.4:
	movq	_kCFAllocatorDefault@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_kCFNumberSInt32Type@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-92(%rbp), %rdx
	callq	_CFNumberCreate
	testq	%rax, %rax
	je	LBB0_74
## %bb.5:
	movq	%rax, %rbx
	movq	%r15, -104(%rbp)                ## 8-byte Spill
	movl	16(%r12), %edi
	movq	_kVTCompressionPropertyKey_AverageBitRate@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdx
	callq	_VTSessionSetProperty
	movq	%r12, %r15
	movl	%eax, %r12d
	movq	%rbx, %rdi
	callq	_CFRelease
	testl	%r12d, %r12d
	je	LBB0_11
## %bb.6:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.2(%rip), %rdx
	movq	%r13, %rdi
	movl	%r12d, %ecx
LBB0_7:
	xorl	%eax, %eax
	callq	_av_log
LBB0_8:
	movq	_AVERROR_EXTERNAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_9:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-48(%rbp), %rcx
	jne	LBB0_79
## %bb.10:
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	movq	(%r15), %rax
	movq	_AV_CODEC_ID_H264@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	%rcx, %rax
	movq	%r15, %r12
	jne	LBB0_21
## %bb.12:
	testl	%r14d, %r14d
	jle	LBB0_21
## %bb.13:
	movq	%r12, -80(%rbp)                 ## 8-byte Spill
	shrl	$3, %r14d
	movl	%r14d, -72(%rbp)
	movq	_kCFAllocatorDefault@GOTPCREL(%rip), %r14
	movl	(%r14), %edi
	movq	_kCFNumberSInt64Type@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	leaq	-72(%rbp), %rdx
	callq	_CFNumberCreate
	testq	%rax, %rax
	je	LBB0_74
## %bb.14:
	movq	%rax, %r12
	movl	$1, -68(%rbp)
	movl	(%r14), %edi
	movl	(%rbx), %esi
	leaq	-68(%rbp), %rdx
	callq	_CFNumberCreate
	testq	%rax, %rax
	je	LBB0_18
## %bb.15:
	movq	%rax, %rbx
	movq	%r12, -64(%rbp)
	movq	%rax, -56(%rbp)
	movl	(%r14), %edi
	movq	_kCFTypeArrayCallBacks@GOTPCREL(%rip), %rcx
	leaq	-64(%rbp), %rsi
	movl	$2, %edx
	callq	_CFArrayCreate
	testq	%rax, %rax
	je	LBB0_19
## %bb.16:
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movl	16(%rcx), %edi
	movq	_kVTCompressionPropertyKey_DataRateLimits@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movq	%rax, %r14
	movq	%rax, %rdx
	callq	_VTSessionSetProperty
	movl	%eax, %r15d
	movq	%r12, %rdi
	callq	_CFRelease
	movq	%rbx, %rdi
	callq	_CFRelease
	movq	%r14, %rdi
	callq	_CFRelease
	testl	%r15d, %r15d
	je	LBB0_20
## %bb.17:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.3(%rip), %rdx
	jmp	LBB0_29
LBB0_18:
	movq	%r12, %rdi
	jmp	LBB0_73
LBB0_19:
	movq	%r12, %rdi
	callq	_CFRelease
	movq	%rbx, %rdi
	jmp	LBB0_73
LBB0_20:
	movq	-80(%rbp), %r12                 ## 8-byte Reload
	movq	(%r12), %rax
	movq	_AV_CODEC_ID_H264@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
LBB0_21:
	movq	-88(%rbp), %rdx                 ## 8-byte Reload
	testq	%rdx, %rdx
	je	LBB0_25
## %bb.22:
	cmpq	%rcx, %rax
	jne	LBB0_25
## %bb.23:
	movl	16(%r12), %edi
	movq	_kVTCompressionPropertyKey_ProfileLevel@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_VTSessionSetProperty
	testl	%eax, %eax
	je	LBB0_25
## %bb.24:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.4(%rip), %rdx
	movq	%r13, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
LBB0_25:
	cmpq	$0, 8(%r13)
	movq	_kCFAllocatorDefault@GOTPCREL(%rip), %r14
	jle	LBB0_30
## %bb.26:
	leaq	8(%r13), %rdx
	movl	(%r14), %edi
	movq	_kCFNumberIntType@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_CFNumberCreate
	testq	%rax, %rax
	je	LBB0_74
## %bb.27:
	movq	%rax, %rbx
	movl	16(%r12), %edi
	movq	_kVTCompressionPropertyKey_MaxKeyFrameInterval@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdx
	callq	_VTSessionSetProperty
	movl	%eax, %r15d
	movq	%rbx, %rdi
	callq	_CFRelease
	testl	%r15d, %r15d
	je	LBB0_30
## %bb.28:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.5(%rip), %rdx
LBB0_29:
	movq	%r13, %rdi
	movl	%r15d, %ecx
	jmp	LBB0_7
LBB0_30:
	cmpq	$0, 72(%r12)
	movq	-104(%rbp), %rbx                ## 8-byte Reload
	je	LBB0_35
## %bb.31:
	movl	16(%r12), %edi
	movq	_kVTCompressionPropertyKey_MoreFramesBeforeStart@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_kCFBooleanTrue@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	callq	_VTSessionSetProperty
	movq	_kVTPropertyNotSupportedErr@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_33
## %bb.32:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.6(%rip), %rdx
	movq	%r13, %rdi
	xorl	%eax, %eax
	callq	_av_log
	jmp	LBB0_35
LBB0_33:
	testl	%eax, %eax
	je	LBB0_35
## %bb.34:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.7(%rip), %rdx
	movq	%r13, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
LBB0_35:
	cmpq	$0, 64(%r12)
	je	LBB0_40
## %bb.36:
	movl	16(%r12), %edi
	movq	_kVTCompressionPropertyKey_MoreFramesAfterEnd@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_kCFBooleanTrue@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	callq	_VTSessionSetProperty
	movq	_kVTPropertyNotSupportedErr@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_38
## %bb.37:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.8(%rip), %rdx
	movq	%r13, %rdi
	xorl	%eax, %eax
	callq	_av_log
	jmp	LBB0_40
LBB0_38:
	testl	%eax, %eax
	je	LBB0_40
## %bb.39:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.9(%rip), %rdx
	movq	%r13, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
LBB0_40:
	movl	16(%r13), %edx
	testl	%edx, %edx
	je	LBB0_46
## %bb.41:
	movq	%r12, -80(%rbp)                 ## 8-byte Spill
	leaq	16(%r13), %rbx
	leaq	20(%r13), %r15
	movl	20(%r13), %ecx
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movl	$-1, %r8d
	callq	_av_reduce
	movl	(%r14), %edi
	movq	_kCFNumberIntType@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	movq	%rbx, %rdx
	callq	_CFNumberCreate
	movl	(%r14), %edi
	movl	(%r12), %esi
	movq	%rax, %r12
	movq	%r15, %rdx
	callq	_CFNumberCreate
	movq	%rax, %r15
	movl	(%r14), %edi
	movq	_kCFCopyStringDictionaryKeyCallBacks@GOTPCREL(%rip), %rdx
	movq	_kCFTypeDictionaryValueCallBacks@GOTPCREL(%rip), %rcx
	movl	$2, %esi
	callq	_CFDictionaryCreateMutable
	movq	%rax, %rbx
	testq	%rax, %rax
	je	LBB0_67
## %bb.42:
	testq	%r12, %r12
	je	LBB0_67
## %bb.43:
	testq	%r15, %r15
	je	LBB0_67
## %bb.44:
	movq	_kCMFormatDescriptionKey_PixelAspectRatioHorizontalSpacing@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movq	%r12, %rdx
	callq	_CFDictionarySetValue
	movq	_kCMFormatDescriptionKey_PixelAspectRatioVerticalSpacing@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	movq	%r15, %rdx
	callq	_CFDictionarySetValue
	movq	-80(%rbp), %r14                 ## 8-byte Reload
	movl	16(%r14), %edi
	movq	_kVTCompressionPropertyKey_PixelAspectRatio@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdx
	callq	_VTSessionSetProperty
	movl	%eax, -88(%rbp)                 ## 4-byte Spill
	movq	%rbx, %rdi
	callq	_CFRelease
	movq	%r12, %rdi
	movq	%r14, %r12
	callq	_CFRelease
	movq	%r15, %rdi
	callq	_CFRelease
	movl	-88(%rbp), %r9d                 ## 4-byte Reload
	testl	%r9d, %r9d
	movq	-104(%rbp), %rbx                ## 8-byte Reload
	je	LBB0_46
## %bb.45:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	16(%r13), %ecx
	movl	20(%r13), %r8d
	leaq	L_.str.10(%rip), %rdx
	movq	%r13, %rdi
	xorl	%eax, %eax
	callq	_av_log
	jmp	LBB0_8
LBB0_46:
	movq	56(%r12), %rdx
	testq	%rdx, %rdx
	je	LBB0_49
## %bb.47:
	movl	16(%r12), %edi
	movq	_kVTCompressionPropertyKey_TransferFunction@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_VTSessionSetProperty
	testl	%eax, %eax
	je	LBB0_49
## %bb.48:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.11(%rip), %rdx
	movq	%r13, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
LBB0_49:
	movq	48(%r12), %rdx
	testq	%rdx, %rdx
	je	LBB0_52
## %bb.50:
	movl	16(%r12), %edi
	movq	_kVTCompressionPropertyKey_YCbCrMatrix@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_VTSessionSetProperty
	testl	%eax, %eax
	je	LBB0_52
## %bb.51:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.12(%rip), %rdx
	movq	%r13, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
LBB0_52:
	movq	40(%r12), %rdx
	testq	%rdx, %rdx
	je	LBB0_55
## %bb.53:
	movl	16(%r12), %edi
	movq	_kVTCompressionPropertyKey_ColorPrimaries@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_VTSessionSetProperty
	testl	%eax, %eax
	je	LBB0_55
## %bb.54:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.13(%rip), %rdx
	movq	%r13, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
LBB0_55:
	testq	%rbx, %rbx
	je	LBB0_58
## %bb.56:
	movl	16(%r12), %edi
	movq	_kCVImageBufferGammaLevelKey@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdx
	callq	_VTSessionSetProperty
	testl	%eax, %eax
	je	LBB0_58
## %bb.57:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.14(%rip), %rdx
	movq	%r13, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
LBB0_58:
	cmpl	$0, 32(%r12)
	je	LBB0_75
LBB0_59:
	movq	8(%r12), %rax
	movq	_VT_ENTROPY_NOT_SET@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	je	LBB0_62
## %bb.60:
	movq	_VT_CABAC@GOTPCREL(%rip), %rcx
	xorl	%edx, %edx
	cmpq	(%rcx), %rax
	sete	%dl
	movq	_compat_keys@GOTPCREL(%rip), %rax
	movq	8(%rax,%rdx,8), %rdx
	movl	16(%r12), %edi
	movl	4(%rax), %esi
	callq	_VTSessionSetProperty
	testl	%eax, %eax
	je	LBB0_62
## %bb.61:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.16(%rip), %rdx
	movq	%r13, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
LBB0_62:
	cmpq	$0, 24(%r12)
	je	LBB0_65
## %bb.63:
	movl	16(%r12), %edi
	movq	_compat_keys@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_kCFBooleanTrue@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	callq	_VTSessionSetProperty
	testl	%eax, %eax
	je	LBB0_65
## %bb.64:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.17(%rip), %rdx
	movq	%r13, %rdi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
LBB0_65:
	movl	16(%r12), %edi
	callq	_VTCompressionSessionPrepareToEncodeFrames
	testl	%eax, %eax
	je	LBB0_78
## %bb.66:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.18(%rip), %rdx
	jmp	LBB0_77
LBB0_67:
	testq	%rbx, %rbx
	je	LBB0_69
## %bb.68:
	movq	%rbx, %rdi
	callq	_CFRelease
LBB0_69:
	testq	%r12, %r12
	je	LBB0_71
## %bb.70:
	movq	%r12, %rdi
	callq	_CFRelease
LBB0_71:
	testq	%r15, %r15
	je	LBB0_74
## %bb.72:
	movq	%r15, %rdi
LBB0_73:
	callq	_CFRelease
LBB0_74:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
	jmp	LBB0_9
LBB0_75:
	movl	16(%r12), %edi
	movq	_kVTCompressionPropertyKey_AllowFrameReordering@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_kCFBooleanFalse@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	callq	_VTSessionSetProperty
	testl	%eax, %eax
	je	LBB0_59
## %bb.76:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	leaq	L_.str.15(%rip), %rdx
LBB0_77:
	movq	%r13, %rdi
	movl	%eax, %ecx
	jmp	LBB0_7
LBB0_78:
	xorl	%eax, %eax
	jmp	LBB0_9
LBB0_79:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_kCFAllocatorDefault,4,2        ## @kCFAllocatorDefault
	.comm	_vtenc_output_callback,4,2      ## @vtenc_output_callback
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Error: cannot create compression session: %d\n"

L_.str.1:                               ## @.str.1
	.asciz	"Try -allow_sw 1. The hardware encoder may be busy, or not supported.\n"

	.comm	_AVERROR_EXTERNAL,4,2           ## @AVERROR_EXTERNAL
	.comm	_kCFNumberSInt32Type,4,2        ## @kCFNumberSInt32Type
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_kVTCompressionPropertyKey_AverageBitRate,4,2 ## @kVTCompressionPropertyKey_AverageBitRate
L_.str.2:                               ## @.str.2
	.asciz	"Error setting bitrate property: %d\n"

	.comm	_AV_CODEC_ID_H264,8,3           ## @AV_CODEC_ID_H264
	.comm	_kCFNumberSInt64Type,4,2        ## @kCFNumberSInt64Type
	.comm	_kCFTypeArrayCallBacks,4,2      ## @kCFTypeArrayCallBacks
	.comm	_kVTCompressionPropertyKey_DataRateLimits,4,2 ## @kVTCompressionPropertyKey_DataRateLimits
L_.str.3:                               ## @.str.3
	.asciz	"Error setting max bitrate property: %d\n"

	.comm	_kVTCompressionPropertyKey_ProfileLevel,4,2 ## @kVTCompressionPropertyKey_ProfileLevel
L_.str.4:                               ## @.str.4
	.asciz	"Error setting profile/level property: %d. Output will be encoded using a supported profile/level combination.\n"

	.comm	_kCFNumberIntType,4,2           ## @kCFNumberIntType
	.comm	_kVTCompressionPropertyKey_MaxKeyFrameInterval,4,2 ## @kVTCompressionPropertyKey_MaxKeyFrameInterval
L_.str.5:                               ## @.str.5
	.asciz	"Error setting 'max key-frame interval' property: %d\n"

	.comm	_kVTCompressionPropertyKey_MoreFramesBeforeStart,4,2 ## @kVTCompressionPropertyKey_MoreFramesBeforeStart
	.comm	_kCFBooleanTrue,8,3             ## @kCFBooleanTrue
	.comm	_kVTPropertyNotSupportedErr,4,2 ## @kVTPropertyNotSupportedErr
	.comm	_AV_LOG_WARNING,4,2             ## @AV_LOG_WARNING
L_.str.6:                               ## @.str.6
	.asciz	"frames_before property is not supported on this device. Ignoring.\n"

L_.str.7:                               ## @.str.7
	.asciz	"Error setting frames_before property: %d\n"

	.comm	_kVTCompressionPropertyKey_MoreFramesAfterEnd,4,2 ## @kVTCompressionPropertyKey_MoreFramesAfterEnd
L_.str.8:                               ## @.str.8
	.asciz	"frames_after property is not supported on this device. Ignoring.\n"

L_.str.9:                               ## @.str.9
	.asciz	"Error setting frames_after property: %d\n"

	.comm	_kCFCopyStringDictionaryKeyCallBacks,4,2 ## @kCFCopyStringDictionaryKeyCallBacks
	.comm	_kCFTypeDictionaryValueCallBacks,4,2 ## @kCFTypeDictionaryValueCallBacks
	.comm	_kCMFormatDescriptionKey_PixelAspectRatioHorizontalSpacing,4,2 ## @kCMFormatDescriptionKey_PixelAspectRatioHorizontalSpacing
	.comm	_kCMFormatDescriptionKey_PixelAspectRatioVerticalSpacing,4,2 ## @kCMFormatDescriptionKey_PixelAspectRatioVerticalSpacing
	.comm	_kVTCompressionPropertyKey_PixelAspectRatio,4,2 ## @kVTCompressionPropertyKey_PixelAspectRatio
L_.str.10:                              ## @.str.10
	.asciz	"Error setting pixel aspect ratio to %d:%d: %d.\n"

	.comm	_kVTCompressionPropertyKey_TransferFunction,4,2 ## @kVTCompressionPropertyKey_TransferFunction
L_.str.11:                              ## @.str.11
	.asciz	"Could not set transfer function: %d\n"

	.comm	_kVTCompressionPropertyKey_YCbCrMatrix,4,2 ## @kVTCompressionPropertyKey_YCbCrMatrix
L_.str.12:                              ## @.str.12
	.asciz	"Could not set ycbcr matrix: %d\n"

	.comm	_kVTCompressionPropertyKey_ColorPrimaries,4,2 ## @kVTCompressionPropertyKey_ColorPrimaries
L_.str.13:                              ## @.str.13
	.asciz	"Could not set color primaries: %d\n"

	.comm	_kCVImageBufferGammaLevelKey,4,2 ## @kCVImageBufferGammaLevelKey
L_.str.14:                              ## @.str.14
	.asciz	"Could not set gamma level: %d\n"

	.comm	_kVTCompressionPropertyKey_AllowFrameReordering,4,2 ## @kVTCompressionPropertyKey_AllowFrameReordering
	.comm	_kCFBooleanFalse,8,3            ## @kCFBooleanFalse
L_.str.15:                              ## @.str.15
	.asciz	"Error setting 'allow frame reordering' property: %d\n"

	.comm	_VT_ENTROPY_NOT_SET,8,3         ## @VT_ENTROPY_NOT_SET
	.comm	_VT_CABAC,8,3                   ## @VT_CABAC
	.comm	_compat_keys,24,3               ## @compat_keys
L_.str.16:                              ## @.str.16
	.asciz	"Error setting entropy property: %d\n"

L_.str.17:                              ## @.str.17
	.asciz	"Error setting realtime property: %d\n"

L_.str.18:                              ## @.str.18
	.asciz	"Error: cannot prepare encoder: %d\n"

	.no_dead_strip	_vtenc_create_encoder
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function vtenc_create_encoder
_vtenc_create_encoder:                  ; @vtenc_create_encoder
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #160
	.cfi_def_cfa_offset 160
	stp	x28, x27, [sp, #64]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #80]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #96]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #112]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #128]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #144]            ; 16-byte Folded Spill
	add	x29, sp, #144
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x20, x3
	mov	x21, x2
	mov	x3, x1
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #56]
	ldr	x26, [x0, #32]
	ldp	w8, w24, [x0]
	stp	wzr, w8, [sp, #32]
	str	wzr, [sp, #28]
Lloh3:
	adrp	x27, _kCFAllocatorDefault@GOTPAGE
Lloh4:
	ldr	x27, [x27, _kCFAllocatorDefault@GOTPAGEOFF]
	ldr	w0, [x27]
	ldp	w2, w1, [x19, #24]
Lloh5:
	adrp	x8, _vtenc_output_callback@GOTPAGE
Lloh6:
	ldr	x8, [x8, _vtenc_output_callback@GOTPAGEOFF]
Lloh7:
	ldr	w7, [x8]
	stp	x19, x6, [sp]
	mov	x6, x0
	bl	_VTCompressionSessionCreate
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_3
LBB0_1:
Lloh8:
	adrp	x20, _AV_LOG_ERROR@GOTPAGE
Lloh9:
	ldr	x20, [x20, _AV_LOG_ERROR@GOTPAGEOFF]
	ldr	w1, [x20]
	str	x0, [sp]
Lloh10:
	adrp	x2, l_.str@PAGE
Lloh11:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_av_log
	ldr	w8, [x26, #80]
	cbnz	w8, LBB0_8
; %bb.2:
	ldr	w1, [x20]
Lloh12:
	adrp	x2, l_.str.1@PAGE
Lloh13:
	add	x2, x2, l_.str.1@PAGEOFF
	b	LBB0_7
LBB0_3:
	ldr	w8, [x26, #16]
	cbz	w8, LBB0_1
; %bb.4:
	ldr	w0, [x27]
Lloh14:
	adrp	x8, _kCFNumberSInt32Type@GOTPAGE
Lloh15:
	ldr	x8, [x8, _kCFNumberSInt32Type@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	add	x2, sp, #36
	bl	_CFNumberCreate
	cbz	x0, LBB0_75
; %bb.5:
	mov	x22, x0
	ldr	w0, [x26, #16]
Lloh17:
	adrp	x8, _kVTCompressionPropertyKey_AverageBitRate@GOTPAGE
Lloh18:
	ldr	x8, [x8, _kVTCompressionPropertyKey_AverageBitRate@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	mov	x2, x22
	bl	_VTSessionSetProperty
	mov	x23, x0
	mov	x0, x22
	bl	_CFRelease
	cbz	w23, LBB0_11
; %bb.6:
Lloh20:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh21:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	str	x23, [sp]
Lloh23:
	adrp	x2, l_.str.2@PAGE
Lloh24:
	add	x2, x2, l_.str.2@PAGEOFF
LBB0_7:
	mov	x0, x19
	bl	_av_log
LBB0_8:
Lloh25:
	adrp	x8, _AVERROR_EXTERNAL@GOTPAGE
Lloh26:
	ldr	x8, [x8, _AVERROR_EXTERNAL@GOTPAGEOFF]
Lloh27:
	ldr	w0, [x8]
LBB0_9:
	ldr	x8, [sp, #56]
Lloh28:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh29:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh30:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_78
; %bb.10:
	ldp	x29, x30, [sp, #144]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #128]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #112]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #96]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #80]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #160
	ret
LBB0_11:
	ldr	x8, [x26]
Lloh31:
	adrp	x28, _AV_CODEC_ID_H264@GOTPAGE
Lloh32:
	ldr	x28, [x28, _AV_CODEC_ID_H264@GOTPAGEOFF]
	ldr	x9, [x28]
	cmp	x8, x9
	b.ne	LBB0_21
; %bb.12:
	cmp	w24, #1
	b.lt	LBB0_21
; %bb.13:
	lsr	w8, w24, #3
	str	w8, [sp, #32]
	ldr	w0, [x27]
Lloh33:
	adrp	x23, _kCFNumberSInt64Type@GOTPAGE
Lloh34:
	ldr	x23, [x23, _kCFNumberSInt64Type@GOTPAGEOFF]
	ldr	w1, [x23]
	add	x2, sp, #32
	bl	_CFNumberCreate
	cbz	x0, LBB0_75
; %bb.14:
	mov	x22, x0
	mov	w8, #1
	str	w8, [sp, #28]
	ldr	w0, [x27]
	ldr	w1, [x23]
	add	x2, sp, #28
	bl	_CFNumberCreate
	cbz	x0, LBB0_18
; %bb.15:
	mov	x23, x0
	stp	x22, x0, [sp, #40]
	ldr	w0, [x27]
Lloh35:
	adrp	x3, _kCFTypeArrayCallBacks@GOTPAGE
Lloh36:
	ldr	x3, [x3, _kCFTypeArrayCallBacks@GOTPAGEOFF]
	add	x1, sp, #40
	mov	w2, #2
	bl	_CFArrayCreate
	cbz	x0, LBB0_19
; %bb.16:
	mov	x24, x0
	ldr	w0, [x26, #16]
Lloh37:
	adrp	x8, _kVTCompressionPropertyKey_DataRateLimits@GOTPAGE
Lloh38:
	ldr	x8, [x8, _kVTCompressionPropertyKey_DataRateLimits@GOTPAGEOFF]
Lloh39:
	ldr	w1, [x8]
	mov	x2, x24
	bl	_VTSessionSetProperty
	mov	x25, x0
	mov	x0, x22
	bl	_CFRelease
	mov	x0, x23
	bl	_CFRelease
	mov	x0, x24
	bl	_CFRelease
	cbz	w25, LBB0_20
; %bb.17:
Lloh40:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh41:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh42:
	ldr	w1, [x8]
	str	x25, [sp]
Lloh43:
	adrp	x2, l_.str.3@PAGE
Lloh44:
	add	x2, x2, l_.str.3@PAGEOFF
	b	LBB0_7
LBB0_18:
	mov	x0, x22
	b	LBB0_74
LBB0_19:
	mov	x0, x22
	bl	_CFRelease
	mov	x0, x23
	b	LBB0_74
LBB0_20:
	ldr	x8, [x26]
	ldr	x9, [x28]
LBB0_21:
	cbz	x21, LBB0_25
; %bb.22:
	cmp	x8, x9
	b.ne	LBB0_25
; %bb.23:
	ldr	w0, [x26, #16]
Lloh45:
	adrp	x8, _kVTCompressionPropertyKey_ProfileLevel@GOTPAGE
Lloh46:
	ldr	x8, [x8, _kVTCompressionPropertyKey_ProfileLevel@GOTPAGEOFF]
Lloh47:
	ldr	w1, [x8]
	mov	x2, x21
	bl	_VTSessionSetProperty
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_25
; %bb.24:
Lloh48:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh49:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh50:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh51:
	adrp	x2, l_.str.4@PAGE
Lloh52:
	add	x2, x2, l_.str.4@PAGEOFF
	mov	x0, x19
	bl	_av_log
LBB0_25:
	mov	x2, x19
	ldr	x8, [x2, #8]!
	cmp	x8, #1
	b.lt	LBB0_29
; %bb.26:
	ldr	w0, [x27]
Lloh53:
	adrp	x8, _kCFNumberIntType@GOTPAGE
Lloh54:
	ldr	x8, [x8, _kCFNumberIntType@GOTPAGEOFF]
Lloh55:
	ldr	w1, [x8]
	bl	_CFNumberCreate
	cbz	x0, LBB0_75
; %bb.27:
	mov	x21, x0
	ldr	w0, [x26, #16]
Lloh56:
	adrp	x8, _kVTCompressionPropertyKey_MaxKeyFrameInterval@GOTPAGE
Lloh57:
	ldr	x8, [x8, _kVTCompressionPropertyKey_MaxKeyFrameInterval@GOTPAGEOFF]
Lloh58:
	ldr	w1, [x8]
	mov	x2, x21
	bl	_VTSessionSetProperty
	mov	x22, x0
	mov	x0, x21
	bl	_CFRelease
	cbz	w22, LBB0_29
; %bb.28:
Lloh59:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh60:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh61:
	ldr	w1, [x8]
	str	x22, [sp]
Lloh62:
	adrp	x2, l_.str.5@PAGE
Lloh63:
	add	x2, x2, l_.str.5@PAGEOFF
	b	LBB0_7
LBB0_29:
	ldr	x8, [x26, #72]
Lloh64:
	adrp	x25, _kCFBooleanTrue@GOTPAGE
Lloh65:
	ldr	x25, [x25, _kCFBooleanTrue@GOTPAGEOFF]
Lloh66:
	adrp	x21, _kVTPropertyNotSupportedErr@GOTPAGE
Lloh67:
	ldr	x21, [x21, _kVTPropertyNotSupportedErr@GOTPAGEOFF]
	cbz	x8, LBB0_35
; %bb.30:
	ldr	w0, [x26, #16]
Lloh68:
	adrp	x8, _kVTCompressionPropertyKey_MoreFramesBeforeStart@GOTPAGE
Lloh69:
	ldr	x8, [x8, _kVTCompressionPropertyKey_MoreFramesBeforeStart@GOTPAGEOFF]
Lloh70:
	ldr	w1, [x8]
	ldr	x2, [x25]
	bl	_VTSessionSetProperty
                                        ; kill: def $w0 killed $w0 def $x0
	ldr	w8, [x21]
	cmp	w0, w8
	b.ne	LBB0_32
; %bb.31:
Lloh71:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh72:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh73:
	ldr	w1, [x8]
Lloh74:
	adrp	x2, l_.str.6@PAGE
Lloh75:
	add	x2, x2, l_.str.6@PAGEOFF
	b	LBB0_34
LBB0_32:
	cbz	w0, LBB0_35
; %bb.33:
Lloh76:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh77:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh78:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh79:
	adrp	x2, l_.str.7@PAGE
Lloh80:
	add	x2, x2, l_.str.7@PAGEOFF
LBB0_34:
	mov	x0, x19
	bl	_av_log
LBB0_35:
	ldr	x8, [x26, #64]
	cbz	x8, LBB0_41
; %bb.36:
	ldr	w0, [x26, #16]
Lloh81:
	adrp	x8, _kVTCompressionPropertyKey_MoreFramesAfterEnd@GOTPAGE
Lloh82:
	ldr	x8, [x8, _kVTCompressionPropertyKey_MoreFramesAfterEnd@GOTPAGEOFF]
Lloh83:
	ldr	w1, [x8]
	ldr	x2, [x25]
	bl	_VTSessionSetProperty
                                        ; kill: def $w0 killed $w0 def $x0
	ldr	w8, [x21]
	cmp	w0, w8
	b.ne	LBB0_38
; %bb.37:
Lloh84:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh85:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh86:
	ldr	w1, [x8]
Lloh87:
	adrp	x2, l_.str.8@PAGE
Lloh88:
	add	x2, x2, l_.str.8@PAGEOFF
	b	LBB0_40
LBB0_38:
	cbz	w0, LBB0_41
; %bb.39:
Lloh89:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh90:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh91:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh92:
	adrp	x2, l_.str.9@PAGE
Lloh93:
	add	x2, x2, l_.str.9@PAGEOFF
LBB0_40:
	mov	x0, x19
	bl	_av_log
LBB0_41:
	mov	x21, x19
	ldr	w2, [x21, #16]!
	cbz	w2, LBB0_47
; %bb.42:
	mov	x23, x19
	ldr	w3, [x23, #20]!
	mov	x0, x21
	mov	x1, x23
	mov	w4, #-1
	bl	_av_reduce
	ldr	w0, [x27]
Lloh94:
	adrp	x24, _kCFNumberIntType@GOTPAGE
Lloh95:
	ldr	x24, [x24, _kCFNumberIntType@GOTPAGEOFF]
	ldr	w1, [x24]
	mov	x2, x21
	bl	_CFNumberCreate
	mov	x22, x0
	ldr	w0, [x27]
	ldr	w1, [x24]
	mov	x2, x23
	bl	_CFNumberCreate
	mov	x21, x0
	ldr	w0, [x27]
Lloh96:
	adrp	x2, _kCFCopyStringDictionaryKeyCallBacks@GOTPAGE
Lloh97:
	ldr	x2, [x2, _kCFCopyStringDictionaryKeyCallBacks@GOTPAGEOFF]
Lloh98:
	adrp	x3, _kCFTypeDictionaryValueCallBacks@GOTPAGE
Lloh99:
	ldr	x3, [x3, _kCFTypeDictionaryValueCallBacks@GOTPAGEOFF]
	mov	w1, #2
	bl	_CFDictionaryCreateMutable
	mov	x23, x0
	cbz	x0, LBB0_68
; %bb.43:
	cbz	x22, LBB0_68
; %bb.44:
	cbz	x21, LBB0_68
; %bb.45:
Lloh100:
	adrp	x8, _kCMFormatDescriptionKey_PixelAspectRatioHorizontalSpacing@GOTPAGE
Lloh101:
	ldr	x8, [x8, _kCMFormatDescriptionKey_PixelAspectRatioHorizontalSpacing@GOTPAGEOFF]
Lloh102:
	ldr	w1, [x8]
	mov	x0, x23
	mov	x2, x22
	bl	_CFDictionarySetValue
Lloh103:
	adrp	x8, _kCMFormatDescriptionKey_PixelAspectRatioVerticalSpacing@GOTPAGE
Lloh104:
	ldr	x8, [x8, _kCMFormatDescriptionKey_PixelAspectRatioVerticalSpacing@GOTPAGEOFF]
Lloh105:
	ldr	w1, [x8]
	mov	x0, x23
	mov	x2, x21
	bl	_CFDictionarySetValue
	ldr	w0, [x26, #16]
Lloh106:
	adrp	x8, _kVTCompressionPropertyKey_PixelAspectRatio@GOTPAGE
Lloh107:
	ldr	x8, [x8, _kVTCompressionPropertyKey_PixelAspectRatio@GOTPAGEOFF]
Lloh108:
	ldr	w1, [x8]
	mov	x2, x23
	bl	_VTSessionSetProperty
	mov	x24, x0
	mov	x0, x23
	bl	_CFRelease
	mov	x0, x22
	bl	_CFRelease
	mov	x0, x21
	bl	_CFRelease
	cbz	w24, LBB0_47
; %bb.46:
Lloh109:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh110:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh111:
	ldr	w1, [x8]
	ldp	w8, w9, [x19, #16]
	stp	x9, x24, [sp, #8]
	str	x8, [sp]
Lloh112:
	adrp	x2, l_.str.10@PAGE
Lloh113:
	add	x2, x2, l_.str.10@PAGEOFF
	b	LBB0_7
LBB0_47:
	ldr	x2, [x26, #56]
	cbz	x2, LBB0_50
; %bb.48:
	ldr	w0, [x26, #16]
Lloh114:
	adrp	x8, _kVTCompressionPropertyKey_TransferFunction@GOTPAGE
Lloh115:
	ldr	x8, [x8, _kVTCompressionPropertyKey_TransferFunction@GOTPAGEOFF]
Lloh116:
	ldr	w1, [x8]
	bl	_VTSessionSetProperty
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_50
; %bb.49:
Lloh117:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh118:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh119:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh120:
	adrp	x2, l_.str.11@PAGE
Lloh121:
	add	x2, x2, l_.str.11@PAGEOFF
	mov	x0, x19
	bl	_av_log
LBB0_50:
	ldr	x2, [x26, #48]
	cbz	x2, LBB0_53
; %bb.51:
	ldr	w0, [x26, #16]
Lloh122:
	adrp	x8, _kVTCompressionPropertyKey_YCbCrMatrix@GOTPAGE
Lloh123:
	ldr	x8, [x8, _kVTCompressionPropertyKey_YCbCrMatrix@GOTPAGEOFF]
Lloh124:
	ldr	w1, [x8]
	bl	_VTSessionSetProperty
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_53
; %bb.52:
Lloh125:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh126:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh127:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh128:
	adrp	x2, l_.str.12@PAGE
Lloh129:
	add	x2, x2, l_.str.12@PAGEOFF
	mov	x0, x19
	bl	_av_log
LBB0_53:
	ldr	x2, [x26, #40]
	cbz	x2, LBB0_56
; %bb.54:
	ldr	w0, [x26, #16]
Lloh130:
	adrp	x8, _kVTCompressionPropertyKey_ColorPrimaries@GOTPAGE
Lloh131:
	ldr	x8, [x8, _kVTCompressionPropertyKey_ColorPrimaries@GOTPAGEOFF]
Lloh132:
	ldr	w1, [x8]
	bl	_VTSessionSetProperty
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_56
; %bb.55:
Lloh133:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh134:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh135:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh136:
	adrp	x2, l_.str.13@PAGE
Lloh137:
	add	x2, x2, l_.str.13@PAGEOFF
	mov	x0, x19
	bl	_av_log
LBB0_56:
	cbz	x20, LBB0_59
; %bb.57:
	ldr	w0, [x26, #16]
Lloh138:
	adrp	x8, _kCVImageBufferGammaLevelKey@GOTPAGE
Lloh139:
	ldr	x8, [x8, _kCVImageBufferGammaLevelKey@GOTPAGEOFF]
Lloh140:
	ldr	w1, [x8]
	mov	x2, x20
	bl	_VTSessionSetProperty
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_59
; %bb.58:
Lloh141:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh142:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh143:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh144:
	adrp	x2, l_.str.14@PAGE
Lloh145:
	add	x2, x2, l_.str.14@PAGEOFF
	mov	x0, x19
	bl	_av_log
LBB0_59:
	ldr	w8, [x26, #32]
	cbz	w8, LBB0_76
LBB0_60:
	ldr	x8, [x26, #8]
Lloh146:
	adrp	x9, _VT_ENTROPY_NOT_SET@GOTPAGE
Lloh147:
	ldr	x9, [x9, _VT_ENTROPY_NOT_SET@GOTPAGEOFF]
Lloh148:
	ldr	x9, [x9]
Lloh149:
	adrp	x20, _compat_keys@GOTPAGE
Lloh150:
	ldr	x20, [x20, _compat_keys@GOTPAGEOFF]
	cmp	x8, x9
	b.eq	LBB0_63
; %bb.61:
Lloh151:
	adrp	x9, _VT_CABAC@GOTPAGE
Lloh152:
	ldr	x9, [x9, _VT_CABAC@GOTPAGEOFF]
Lloh153:
	ldr	x9, [x9]
	add	x10, x20, #16
	add	x11, x20, #8
	cmp	x8, x9
	csel	x8, x10, x11, eq
	ldr	x2, [x8]
	ldr	w0, [x26, #16]
	ldr	w1, [x20, #4]
	bl	_VTSessionSetProperty
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_63
; %bb.62:
Lloh154:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh155:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh156:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh157:
	adrp	x2, l_.str.16@PAGE
Lloh158:
	add	x2, x2, l_.str.16@PAGEOFF
	mov	x0, x19
	bl	_av_log
LBB0_63:
	ldr	x8, [x26, #24]
	cbz	x8, LBB0_66
; %bb.64:
	ldr	w0, [x26, #16]
	ldr	w1, [x20]
	ldr	x2, [x25]
	bl	_VTSessionSetProperty
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_66
; %bb.65:
Lloh159:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh160:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh161:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh162:
	adrp	x2, l_.str.17@PAGE
Lloh163:
	add	x2, x2, l_.str.17@PAGEOFF
	mov	x0, x19
	bl	_av_log
LBB0_66:
	ldr	w0, [x26, #16]
	bl	_VTCompressionSessionPrepareToEncodeFrames
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_9
; %bb.67:
Lloh164:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh165:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh166:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh167:
	adrp	x2, l_.str.18@PAGE
Lloh168:
	add	x2, x2, l_.str.18@PAGEOFF
	b	LBB0_7
LBB0_68:
	cbz	x23, LBB0_70
; %bb.69:
	mov	x0, x23
	bl	_CFRelease
LBB0_70:
	cbz	x22, LBB0_72
; %bb.71:
	mov	x0, x22
	bl	_CFRelease
LBB0_72:
	cbz	x21, LBB0_75
; %bb.73:
	mov	x0, x21
LBB0_74:
	bl	_CFRelease
LBB0_75:
Lloh169:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh170:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh171:
	ldr	w0, [x8]
	bl	_AVERROR
	b	LBB0_9
LBB0_76:
	ldr	w0, [x26, #16]
Lloh172:
	adrp	x8, _kVTCompressionPropertyKey_AllowFrameReordering@GOTPAGE
Lloh173:
	ldr	x8, [x8, _kVTCompressionPropertyKey_AllowFrameReordering@GOTPAGEOFF]
Lloh174:
	ldr	w1, [x8]
Lloh175:
	adrp	x8, _kCFBooleanFalse@GOTPAGE
Lloh176:
	ldr	x8, [x8, _kCFBooleanFalse@GOTPAGEOFF]
Lloh177:
	ldr	x2, [x8]
	bl	_VTSessionSetProperty
                                        ; kill: def $w0 killed $w0 def $x0
	cbz	w0, LBB0_60
; %bb.77:
Lloh178:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh179:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh180:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh181:
	adrp	x2, l_.str.15@PAGE
Lloh182:
	add	x2, x2, l_.str.15@PAGEOFF
	b	LBB0_7
LBB0_78:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpAdd	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh33, Lloh34
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpAdd	Lloh43, Lloh44
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh45, Lloh46, Lloh47
	.loh AdrpAdd	Lloh51, Lloh52
	.loh AdrpLdrGotLdr	Lloh48, Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh53, Lloh54, Lloh55
	.loh AdrpLdrGotLdr	Lloh56, Lloh57, Lloh58
	.loh AdrpAdd	Lloh62, Lloh63
	.loh AdrpLdrGotLdr	Lloh59, Lloh60, Lloh61
	.loh AdrpLdrGot	Lloh66, Lloh67
	.loh AdrpLdrGot	Lloh64, Lloh65
	.loh AdrpLdrGotLdr	Lloh68, Lloh69, Lloh70
	.loh AdrpAdd	Lloh74, Lloh75
	.loh AdrpLdrGotLdr	Lloh71, Lloh72, Lloh73
	.loh AdrpAdd	Lloh79, Lloh80
	.loh AdrpLdrGotLdr	Lloh76, Lloh77, Lloh78
	.loh AdrpLdrGotLdr	Lloh81, Lloh82, Lloh83
	.loh AdrpAdd	Lloh87, Lloh88
	.loh AdrpLdrGotLdr	Lloh84, Lloh85, Lloh86
	.loh AdrpAdd	Lloh92, Lloh93
	.loh AdrpLdrGotLdr	Lloh89, Lloh90, Lloh91
	.loh AdrpLdrGot	Lloh98, Lloh99
	.loh AdrpLdrGot	Lloh96, Lloh97
	.loh AdrpLdrGot	Lloh94, Lloh95
	.loh AdrpLdrGotLdr	Lloh106, Lloh107, Lloh108
	.loh AdrpLdrGotLdr	Lloh103, Lloh104, Lloh105
	.loh AdrpLdrGotLdr	Lloh100, Lloh101, Lloh102
	.loh AdrpAdd	Lloh112, Lloh113
	.loh AdrpLdrGotLdr	Lloh109, Lloh110, Lloh111
	.loh AdrpLdrGotLdr	Lloh114, Lloh115, Lloh116
	.loh AdrpAdd	Lloh120, Lloh121
	.loh AdrpLdrGotLdr	Lloh117, Lloh118, Lloh119
	.loh AdrpLdrGotLdr	Lloh122, Lloh123, Lloh124
	.loh AdrpAdd	Lloh128, Lloh129
	.loh AdrpLdrGotLdr	Lloh125, Lloh126, Lloh127
	.loh AdrpLdrGotLdr	Lloh130, Lloh131, Lloh132
	.loh AdrpAdd	Lloh136, Lloh137
	.loh AdrpLdrGotLdr	Lloh133, Lloh134, Lloh135
	.loh AdrpLdrGotLdr	Lloh138, Lloh139, Lloh140
	.loh AdrpAdd	Lloh144, Lloh145
	.loh AdrpLdrGotLdr	Lloh141, Lloh142, Lloh143
	.loh AdrpLdrGot	Lloh149, Lloh150
	.loh AdrpLdrGotLdr	Lloh146, Lloh147, Lloh148
	.loh AdrpLdrGotLdr	Lloh151, Lloh152, Lloh153
	.loh AdrpAdd	Lloh157, Lloh158
	.loh AdrpLdrGotLdr	Lloh154, Lloh155, Lloh156
	.loh AdrpAdd	Lloh162, Lloh163
	.loh AdrpLdrGotLdr	Lloh159, Lloh160, Lloh161
	.loh AdrpAdd	Lloh167, Lloh168
	.loh AdrpLdrGotLdr	Lloh164, Lloh165, Lloh166
	.loh AdrpLdrGotLdr	Lloh169, Lloh170, Lloh171
	.loh AdrpLdrGotLdr	Lloh175, Lloh176, Lloh177
	.loh AdrpLdrGotLdr	Lloh172, Lloh173, Lloh174
	.loh AdrpAdd	Lloh181, Lloh182
	.loh AdrpLdrGotLdr	Lloh178, Lloh179, Lloh180
	.cfi_endproc
                                        ; -- End function
	.comm	_kCFAllocatorDefault,4,2        ; @kCFAllocatorDefault
	.comm	_vtenc_output_callback,4,2      ; @vtenc_output_callback
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Error: cannot create compression session: %d\n"

l_.str.1:                               ; @.str.1
	.asciz	"Try -allow_sw 1. The hardware encoder may be busy, or not supported.\n"

	.comm	_AVERROR_EXTERNAL,4,2           ; @AVERROR_EXTERNAL
	.comm	_kCFNumberSInt32Type,4,2        ; @kCFNumberSInt32Type
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_kVTCompressionPropertyKey_AverageBitRate,4,2 ; @kVTCompressionPropertyKey_AverageBitRate
l_.str.2:                               ; @.str.2
	.asciz	"Error setting bitrate property: %d\n"

	.comm	_AV_CODEC_ID_H264,8,3           ; @AV_CODEC_ID_H264
	.comm	_kCFNumberSInt64Type,4,2        ; @kCFNumberSInt64Type
	.comm	_kCFTypeArrayCallBacks,4,2      ; @kCFTypeArrayCallBacks
	.comm	_kVTCompressionPropertyKey_DataRateLimits,4,2 ; @kVTCompressionPropertyKey_DataRateLimits
l_.str.3:                               ; @.str.3
	.asciz	"Error setting max bitrate property: %d\n"

	.comm	_kVTCompressionPropertyKey_ProfileLevel,4,2 ; @kVTCompressionPropertyKey_ProfileLevel
l_.str.4:                               ; @.str.4
	.asciz	"Error setting profile/level property: %d. Output will be encoded using a supported profile/level combination.\n"

	.comm	_kCFNumberIntType,4,2           ; @kCFNumberIntType
	.comm	_kVTCompressionPropertyKey_MaxKeyFrameInterval,4,2 ; @kVTCompressionPropertyKey_MaxKeyFrameInterval
l_.str.5:                               ; @.str.5
	.asciz	"Error setting 'max key-frame interval' property: %d\n"

	.comm	_kVTCompressionPropertyKey_MoreFramesBeforeStart,4,2 ; @kVTCompressionPropertyKey_MoreFramesBeforeStart
	.comm	_kCFBooleanTrue,8,3             ; @kCFBooleanTrue
	.comm	_kVTPropertyNotSupportedErr,4,2 ; @kVTPropertyNotSupportedErr
	.comm	_AV_LOG_WARNING,4,2             ; @AV_LOG_WARNING
l_.str.6:                               ; @.str.6
	.asciz	"frames_before property is not supported on this device. Ignoring.\n"

l_.str.7:                               ; @.str.7
	.asciz	"Error setting frames_before property: %d\n"

	.comm	_kVTCompressionPropertyKey_MoreFramesAfterEnd,4,2 ; @kVTCompressionPropertyKey_MoreFramesAfterEnd
l_.str.8:                               ; @.str.8
	.asciz	"frames_after property is not supported on this device. Ignoring.\n"

l_.str.9:                               ; @.str.9
	.asciz	"Error setting frames_after property: %d\n"

	.comm	_kCFCopyStringDictionaryKeyCallBacks,4,2 ; @kCFCopyStringDictionaryKeyCallBacks
	.comm	_kCFTypeDictionaryValueCallBacks,4,2 ; @kCFTypeDictionaryValueCallBacks
	.comm	_kCMFormatDescriptionKey_PixelAspectRatioHorizontalSpacing,4,2 ; @kCMFormatDescriptionKey_PixelAspectRatioHorizontalSpacing
	.comm	_kCMFormatDescriptionKey_PixelAspectRatioVerticalSpacing,4,2 ; @kCMFormatDescriptionKey_PixelAspectRatioVerticalSpacing
	.comm	_kVTCompressionPropertyKey_PixelAspectRatio,4,2 ; @kVTCompressionPropertyKey_PixelAspectRatio
l_.str.10:                              ; @.str.10
	.asciz	"Error setting pixel aspect ratio to %d:%d: %d.\n"

	.comm	_kVTCompressionPropertyKey_TransferFunction,4,2 ; @kVTCompressionPropertyKey_TransferFunction
l_.str.11:                              ; @.str.11
	.asciz	"Could not set transfer function: %d\n"

	.comm	_kVTCompressionPropertyKey_YCbCrMatrix,4,2 ; @kVTCompressionPropertyKey_YCbCrMatrix
l_.str.12:                              ; @.str.12
	.asciz	"Could not set ycbcr matrix: %d\n"

	.comm	_kVTCompressionPropertyKey_ColorPrimaries,4,2 ; @kVTCompressionPropertyKey_ColorPrimaries
l_.str.13:                              ; @.str.13
	.asciz	"Could not set color primaries: %d\n"

	.comm	_kCVImageBufferGammaLevelKey,4,2 ; @kCVImageBufferGammaLevelKey
l_.str.14:                              ; @.str.14
	.asciz	"Could not set gamma level: %d\n"

	.comm	_kVTCompressionPropertyKey_AllowFrameReordering,4,2 ; @kVTCompressionPropertyKey_AllowFrameReordering
	.comm	_kCFBooleanFalse,8,3            ; @kCFBooleanFalse
l_.str.15:                              ; @.str.15
	.asciz	"Error setting 'allow frame reordering' property: %d\n"

	.comm	_VT_ENTROPY_NOT_SET,8,3         ; @VT_ENTROPY_NOT_SET
	.comm	_VT_CABAC,8,3                   ; @VT_CABAC
	.comm	_compat_keys,24,3               ; @compat_keys
l_.str.16:                              ; @.str.16
	.asciz	"Error setting entropy property: %d\n"

l_.str.17:                              ; @.str.17
	.asciz	"Error setting realtime property: %d\n"

l_.str.18:                              ; @.str.18
	.asciz	"Error: cannot prepare encoder: %d\n"

	.no_dead_strip	_vtenc_create_encoder
.subsections_via_symbols
