	.file	"extr_vaapi_transcode.c_dec_enc.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"Error during decoding. Error code: %s\n"
	.align 8
.LC1:
	.string	"Error while decoding. Error code: %s\n"
	.align 8
.LC2:
	.string	"Failed to open encode codec. Error code: %s\n"
	.align 8
.LC3:
	.string	"Failed to allocate stream for output format.\n"
	.align 8
.LC4:
	.string	"Failed to copy the stream parameters. Error code: %s\n"
	.align 8
.LC5:
	.string	"Error while writing stream header. Error code: %s\n"
	.align 8
.LC6:
	.string	"Error during encoding and writing.\n"
	.text
	.p2align 4
	.type	dec_enc, @function
dec_enc:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	mov	rbp, rsi
	mov	rsi, rdi
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	sub	rsp, 16
	.cfi_def_cfa_offset 48
	mov	rdi, QWORD PTR decoder_ctx[rip]
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 8[rsp], rax
	xor	eax, eax
	mov	rbx, rsp
	call	avcodec_send_packet@PLT
	test	eax, eax
	js	.L23
	.p2align 4,,10
	.p2align 3
.L2:
	xor	eax, eax
	call	av_frame_alloc@PLT
	mov	QWORD PTR [rsp], rax
	mov	rsi, rax
	test	rax, rax
	je	.L24
	mov	rdi, QWORD PTR decoder_ctx[rip]
	call	avcodec_receive_frame@PLT
	mov	edi, DWORD PTR EAGAIN[rip]
	mov	r12d, eax
	call	AVERROR@PLT
	cmp	eax, r12d
	je	.L5
	cmp	DWORD PTR AVERROR_EOF[rip], r12d
	je	.L5
	test	r12d, r12d
	js	.L25
	mov	edx, DWORD PTR initialized[rip]
	test	edx, edx
	jne	.L8
	mov	rax, QWORD PTR decoder_ctx[rip]
	mov	r12, QWORD PTR encoder_ctx[rip]
	mov	edi, DWORD PTR 12[rax]
	call	av_buffer_ref@PLT
	mov	DWORD PTR 16[r12], eax
	mov	r12, QWORD PTR encoder_ctx[rip]
	mov	eax, DWORD PTR 16[r12]
	test	eax, eax
	je	.L21
	mov	rax, QWORD PTR decoder_ctx[rip]
	mov	edi, DWORD PTR 8[rax]
	call	av_inv_q@PLT
	mov	rdi, QWORD PTR encoder_ctx[rip]
	mov	rsi, rbp
	mov	DWORD PTR [r12], eax
	mov	eax, DWORD PTR AV_PIX_FMT_VAAPI[rip]
	mov	DWORD PTR 12[rdi], eax
	mov	rax, QWORD PTR decoder_ctx[rip]
	mov	edx, DWORD PTR 4[rax]
	mov	eax, DWORD PTR [rax]
	mov	DWORD PTR 8[rdi], edx
	xor	edx, edx
	mov	DWORD PTR 4[rdi], eax
	call	avcodec_open2@PLT
	mov	r12d, eax
	test	eax, eax
	js	.L26
	mov	edi, DWORD PTR ofmt_ctx[rip]
	mov	rsi, rbp
	call	avformat_new_stream@PLT
	mov	QWORD PTR ost[rip], rax
	test	rax, rax
	je	.L27
	mov	rsi, QWORD PTR encoder_ctx[rip]
	mov	edi, DWORD PTR [rax]
	mov	edx, DWORD PTR [rsi]
	mov	DWORD PTR 4[rax], edx
	call	avcodec_parameters_from_context@PLT
	mov	r12d, eax
	test	eax, eax
	js	.L28
	mov	edi, DWORD PTR ofmt_ctx[rip]
	xor	esi, esi
	call	avformat_write_header@PLT
	mov	r12d, eax
	test	eax, eax
	js	.L29
	mov	DWORD PTR initialized[rip], 1
	.p2align 4,,10
	.p2align 3
.L8:
	mov	rdi, QWORD PTR [rsp]
	call	encode_write@PLT
	mov	r12d, eax
	test	eax, eax
	js	.L30
	mov	rdi, rbx
	call	av_frame_free@PLT
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L27:
	mov	edi, DWORD PTR stderr[rip]
	lea	rsi, .LC3[rip]
	call	fprintf@PLT
.L21:
.L10:
	endbr64
	mov	edi, DWORD PTR ENOMEM[rip]
	call	AVERROR@PLT
	mov	rdi, rbx
	mov	r12d, eax
	call	av_frame_free@PLT
	test	r12d, r12d
	jns	.L2
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L25:
	mov	edi, r12d
	call	av_err2str@PLT
	mov	edi, DWORD PTR stderr[rip]
	lea	rsi, .LC1[rip]
	mov	rdx, rax
	xor	eax, eax
	call	fprintf@PLT
	mov	rdi, rsp
	call	av_frame_free@PLT
.L1:
	mov	rax, QWORD PTR 8[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L31
	add	rsp, 16
	.cfi_remember_state
	.cfi_def_cfa_offset 32
	mov	eax, r12d
	pop	rbx
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L30:
	.cfi_restore_state
	mov	edi, DWORD PTR stderr[rip]
	lea	rsi, .LC6[rip]
	xor	eax, eax
	call	fprintf@PLT
.L12:
	mov	rdi, rsp
	call	av_frame_free@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L26:
	mov	edi, eax
	call	av_err2str@PLT
	mov	edi, DWORD PTR stderr[rip]
	lea	rsi, .LC2[rip]
	mov	rdx, rax
	xor	eax, eax
	call	fprintf@PLT
	jmp	.L12
	.p2align 4,,10
	.p2align 3
.L5:
	mov	rdi, rsp
	xor	r12d, r12d
	call	av_frame_free@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L28:
	mov	edi, eax
	call	av_err2str@PLT
	mov	edi, DWORD PTR stderr[rip]
	lea	rsi, .LC4[rip]
	mov	rdx, rax
	xor	eax, eax
	call	fprintf@PLT
	jmp	.L12
	.p2align 4,,10
	.p2align 3
.L24:
	mov	edi, DWORD PTR ENOMEM[rip]
	call	AVERROR@PLT
	mov	r12d, eax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L23:
	mov	edi, eax
	mov	r12d, eax
	call	av_err2str@PLT
	mov	edi, DWORD PTR stderr[rip]
	lea	rsi, .LC0[rip]
	mov	rdx, rax
	xor	eax, eax
	call	fprintf@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L29:
	mov	edi, eax
	call	av_err2str@PLT
	mov	edi, DWORD PTR stderr[rip]
	lea	rsi, .LC5[rip]
	mov	rdx, rax
	xor	eax, eax
	call	fprintf@PLT
	jmp	.L12
.L31:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	dec_enc, .-dec_enc
	.comm	stderr,4,4
	.comm	ost,8,8
	.comm	ofmt_ctx,4,4
	.comm	initialized,4,4
	.comm	encoder_ctx,8,8
	.comm	decoder_ctx,8,8
	.comm	ENOMEM,4,4
	.comm	EAGAIN,4,4
	.comm	AV_PIX_FMT_VAAPI,4,4
	.comm	AVERROR_EOF,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_vaapi_transcode.c_dec_enc.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Error during decoding. Error code: %s\012\000"
	.align	2
.LC1:
	.ascii	"Error while decoding. Error code: %s\012\000"
	.align	2
.LC2:
	.ascii	"Failed to open encode codec. Error code: %s\012\000"
	.align	2
.LC3:
	.ascii	"Failed to allocate stream for output format.\012\000"
	.align	2
.LC4:
	.ascii	"Failed to copy the stream parameters. Error code: %"
	.ascii	"s\012\000"
	.align	2
.LC5:
	.ascii	"Error while writing stream header. Error code: %s\012"
	.ascii	"\000"
	.align	2
.LC6:
	.ascii	"Error during encoding and writing.\012\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC7:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	dec_enc, %function
dec_enc:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	ldr	r4, .L32
	ldr	r3, .L32+4
	sub	sp, sp, #20
	mov	r10, r1
	mov	r1, r0
	ldr	r0, [r4]
	ldr	r3, [r3]
	str	r3, [sp, #12]
	mov	r3,#0
	bl	avcodec_send_packet
	subs	fp, r0, #0
	blt	.L20
	ldr	r7, .L32+8
	ldr	r8, .L32+12
	ldr	r9, .L32+16
	ldr	r6, .L32+20
.L2:
	bl	av_frame_alloc
	cmp	r0, #0
	mov	r1, r0
	str	r0, [sp, #8]
	beq	.L24
	ldr	r0, [r4]
	bl	avcodec_receive_frame
	mov	fp, r0
	ldr	r0, [r7]
	bl	AVERROR
	cmp	r0, fp
	beq	.L5
	ldr	r2, [r8]
	cmp	r2, fp
	beq	.L5
	cmp	fp, #0
	blt	.L25
	ldr	r5, [r9]
	cmp	r5, #0
	bne	.L8
	ldr	r2, [r4]
	ldr	r3, [r6]
	ldr	r0, [r2, #12]
	str	r3, [sp, #4]
	bl	av_buffer_ref
	ldr	r3, [sp, #4]
	ldr	fp, [r6]
	str	r0, [r3, #16]
	ldr	r3, [fp, #16]
	cmp	r3, #0
	beq	.L22
	ldr	r3, [r4]
	ldr	r0, [r3, #8]
	bl	av_inv_q
	ldr	r1, [r4]
	ldr	r2, .L32+24
	ldr	r3, [r6]
	ldr	r2, [r2]
	str	r0, [fp]
	ldr	r0, [r1, #4]
	ldr	r1, [r1]
	str	r0, [r3, #8]
	str	r1, [r3, #4]
	str	r2, [r3, #12]
	mov	r0, r3
	mov	r2, r5
	mov	r1, r10
	bl	avcodec_open2
	subs	fp, r0, #0
	blt	.L26
	ldr	r3, .L32+28
	mov	r1, r10
	ldr	r0, [r3]
	bl	avformat_new_stream
	ldr	r2, .L32+32
	cmp	r0, #0
	mov	r3, r0
	str	r0, [r2]
	beq	.L27
	ldr	r1, [r6]
	ldr	r0, [r0]
	ldr	r2, [r1]
	str	r2, [r3, #4]
	bl	avcodec_parameters_from_context
	subs	fp, r0, #0
	blt	.L28
	ldr	r3, .L32+28
	mov	r1, r5
	ldr	r0, [r3]
	bl	avformat_write_header
	subs	fp, r0, #0
	blt	.L29
	mov	r3, #1
	str	r3, [r9]
.L8:
	ldr	r0, [sp, #8]
	bl	encode_write
	subs	fp, r0, #0
	blt	.L30
	add	r0, sp, #8
	bl	av_frame_free
	b	.L2
.L27:
	ldr	r3, .L32+36
	ldr	r1, .L32+40
	ldr	r0, [r3]
	bl	fprintf
.L22:
.L10:
	ldr	r3, .L32+44
	ldr	r0, [r3]
	bl	AVERROR
	mov	fp, r0
	add	r0, sp, #8
	bl	av_frame_free
	cmp	fp, #0
	bge	.L2
	b	.L1
.L25:
	ldr	r2, .L32+36
	mov	r0, fp
	ldr	r4, [r2]
	bl	av_err2str
	ldr	r1, .L32+48
	mov	r2, r0
	mov	r0, r4
	bl	fprintf
	add	r0, sp, #8
	bl	av_frame_free
.L1:
	ldr	r3, .L32+4
	ldr	r2, [r3]
	ldr	r3, [sp, #12]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L31
	mov	r0, fp
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L30:
	ldr	r2, .L32+36
	ldr	r1, .L32+52
	ldr	r0, [r2]
	bl	fprintf
.L12:
	add	r0, sp, #8
	bl	av_frame_free
	b	.L1
.L26:
	ldr	r2, .L32+36
	ldr	r4, [r2]
	bl	av_err2str
	ldr	r1, .L32+56
	mov	r2, r0
	mov	r0, r4
	bl	fprintf
	b	.L12
.L5:
	add	r0, sp, #8
	bl	av_frame_free
	mov	fp, #0
	b	.L1
.L28:
	ldr	r2, .L32+36
	ldr	r4, [r2]
	bl	av_err2str
	ldr	r1, .L32+60
	mov	r2, r0
	mov	r0, r4
	bl	fprintf
	b	.L12
.L24:
	ldr	r3, .L32+44
	ldr	r0, [r3]
	bl	AVERROR
	mov	fp, r0
	b	.L1
.L20:
	ldr	r2, .L32+36
	ldr	r4, [r2]
	bl	av_err2str
	ldr	r1, .L32+64
	mov	r2, r0
	mov	r0, r4
	bl	fprintf
	b	.L1
.L29:
	ldr	r2, .L32+36
	mov	r0, fp
	ldr	r4, [r2]
	bl	av_err2str
	ldr	r1, .L32+68
	mov	r2, r0
	mov	r0, r4
	bl	fprintf
	b	.L12
.L31:
	bl	__stack_chk_fail
.L33:
	.align	2
.L32:
	.word	decoder_ctx
	.word	.LC7
	.word	EAGAIN
	.word	AVERROR_EOF
	.word	initialized
	.word	encoder_ctx
	.word	AV_PIX_FMT_VAAPI
	.word	ofmt_ctx
	.word	ost
	.word	stderr
	.word	.LC3
	.word	ENOMEM
	.word	.LC1
	.word	.LC6
	.word	.LC2
	.word	.LC4
	.word	.LC0
	.word	.LC5
	.size	dec_enc, .-dec_enc
	.comm	stderr,4,4
	.comm	ost,4,4
	.comm	ofmt_ctx,4,4
	.comm	initialized,4,4
	.comm	encoder_ctx,4,4
	.comm	decoder_ctx,4,4
	.comm	ENOMEM,4,4
	.comm	EAGAIN,4,4
	.comm	AV_PIX_FMT_VAAPI,4,4
	.comm	AVERROR_EOF,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
