arcan: add patch for ffmpeg-4.0.1.
This commit is contained in:
parent
7ab5b3a1e5
commit
ef38878c26
2 changed files with 63 additions and 1 deletions
62
srcpkgs/arcan/patches/ffmpeg4.patch
Normal file
62
srcpkgs/arcan/patches/ffmpeg4.patch
Normal file
|
@ -0,0 +1,62 @@
|
|||
--- src/frameserver/encode/default/encode.c 2018-04-15 11:19:51.000000000 +0200
|
||||
+++ src/frameserver/encode/default/encode.c 2018-04-15 11:19:51.000000000 +0200
|
||||
@@ -285,8 +285,8 @@
|
||||
/*
|
||||
* for the flush case, we may have a little bit of buffers left, both in the
|
||||
* encoder and the resampler,
|
||||
- * CODEC_CAP_DELAY = pframe can be NULL and encode audio is used to flush
|
||||
- * CODEC_CAP_SMALL_LAST_FRAME or CODEC_CAP_VARIABLE_FRAME_SIZE =
|
||||
+ * AV_CODEC_CAP_DELAY = pframe can be NULL and encode audio is used to flush
|
||||
+ * AV_CODEC_CAP_SMALL_LAST_FRAME or AV_CODEC_CAP_VARIABLE_FRAME_SIZE =
|
||||
* we can the last few buffer bytes can be stored as well otherwise those
|
||||
* will be discarded
|
||||
*/
|
||||
@@ -298,8 +298,8 @@
|
||||
* and then re-use the encode / conversion code
|
||||
*/
|
||||
if (!forcetog &&
|
||||
- ((ctx->flags & CODEC_CAP_SMALL_LAST_FRAME) > 0 ||
|
||||
- (ctx->flags & CODEC_CAP_VARIABLE_FRAME_SIZE) > 0)){
|
||||
+ ((ctx->flags & AV_CODEC_CAP_SMALL_LAST_FRAME) > 0 ||
|
||||
+ (ctx->flags & AV_CODEC_CAP_VARIABLE_FRAME_SIZE) > 0)){
|
||||
recctx.aframe_insz = recctx.encabuf_ofs;
|
||||
recctx.aframe_smplcnt = recctx.aframe_insz >> 2;
|
||||
frame = av_frame_alloc();
|
||||
@@ -309,7 +309,7 @@
|
||||
goto forceencode;
|
||||
}
|
||||
|
||||
- if ( (ctx->flags & CODEC_CAP_DELAY) > 0 ){
|
||||
+ if ( (ctx->flags & AV_CODEC_CAP_DELAY) > 0 ){
|
||||
int gotpkt;
|
||||
do {
|
||||
AVPacket flushpkt = {0};
|
||||
@@ -638,7 +638,7 @@
|
||||
* for float conversion, we need to double afterwards
|
||||
*/
|
||||
|
||||
- if ( (recctx.acodec->capabilities & CODEC_CAP_VARIABLE_FRAME_SIZE) > 0){
|
||||
+ if ( (recctx.acodec->capabilities & AV_CODEC_CAP_VARIABLE_FRAME_SIZE) > 0){
|
||||
recctx.aframe_smplcnt = recctx.acontext->frame_size ?
|
||||
recctx.acontext->frame_size : round( samplerate / fps );
|
||||
}
|
||||
--- src/frameserver/encode/default/encode_presets.c 2018-04-15 11:19:51.000000000 +0200
|
||||
+++ src/frameserver/encode/default/encode_presets.c 2018-04-15 11:19:51.000000000 +0200
|
||||
@@ -379,7 +379,7 @@
|
||||
|
||||
a.storage.video.context = avcodec_alloc_context3( a.storage.video.codec );
|
||||
if (flags & AVFMT_GLOBALHEADER)
|
||||
- a.storage.video.context->flags |= CODEC_FLAG_GLOBAL_HEADER;
|
||||
+ a.storage.video.context->flags |= AV_CODEC_FLAG_GLOBAL_HEADER;
|
||||
|
||||
return a;
|
||||
}
|
||||
@@ -397,7 +397,7 @@
|
||||
|
||||
res.storage.audio.context = avcodec_alloc_context3( res.storage.audio.codec);
|
||||
if ( (flags & AVFMT_GLOBALHEADER) > 0){
|
||||
- res.storage.audio.context->flags |= CODEC_FLAG_GLOBAL_HEADER;
|
||||
+ res.storage.audio.context->flags |= AV_CODEC_FLAG_GLOBAL_HEADER;
|
||||
}
|
||||
|
||||
return res;
|
|
@ -1,7 +1,7 @@
|
|||
# Template file for 'arcan'
|
||||
pkgname=arcan
|
||||
version=0.5.4.6
|
||||
revision=2
|
||||
revision=3
|
||||
build_style=cmake
|
||||
build_wrksrc=src
|
||||
short_desc="Combined display server, multimedia framework and game engine"
|
||||
|
|
Loading…
Reference in a new issue