From owner-svn-ports-all@freebsd.org Fri Apr 27 10:39:32 2018 Return-Path: Delivered-To: svn-ports-all@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 52856FA4745; Fri, 27 Apr 2018 10:39:32 +0000 (UTC) (envelope-from jbeich@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 0569C72019; Fri, 27 Apr 2018 10:39:32 +0000 (UTC) (envelope-from jbeich@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id F3E732550E; Fri, 27 Apr 2018 10:39:31 +0000 (UTC) (envelope-from jbeich@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w3RAdVUt015551; Fri, 27 Apr 2018 10:39:31 GMT (envelope-from jbeich@FreeBSD.org) Received: (from jbeich@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w3RAdVho015550; Fri, 27 Apr 2018 10:39:31 GMT (envelope-from jbeich@FreeBSD.org) Message-Id: <201804271039.w3RAdVho015550@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: jbeich set sender to jbeich@FreeBSD.org using -f From: Jan Beich Date: Fri, 27 Apr 2018 10:39:31 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r468418 - head/graphics/blender/files X-SVN-Group: ports-head X-SVN-Commit-Author: jbeich X-SVN-Commit-Paths: head/graphics/blender/files X-SVN-Commit-Revision: 468418 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Apr 2018 10:39:32 -0000 Author: jbeich Date: Fri Apr 27 10:39:31 2018 New Revision: 468418 URL: https://svnweb.freebsd.org/changeset/ports/468418 Log: graphics/blender: unbreak with ffmpeg 4.0 intern/audaspace/ffmpeg/AUD_FFMPEGReader.cpp:267:49: error: use of undeclared identifier 'FF_MIN_BUFFER_SIZE' m_membuf = reinterpret_cast(av_malloc(FF_MIN_BUFFER_SIZE + FF_INPUT_BUFFER_PADDING_SIZE)); ^ intern/audaspace/ffmpeg/AUD_FFMPEGReader.cpp:267:70: error: use of undeclared identifier 'FF_INPUT_BUFFER_PADDING_SIZE' m_membuf = reinterpret_cast(av_malloc(FF_MIN_BUFFER_SIZE + FF_INPUT_BUFFER_PADDING_SIZE)); ^ intern/audaspace/ffmpeg/AUD_FFMPEGReader.cpp:269:47: error: use of undeclared identifier 'FF_MIN_BUFFER_SIZE' m_aviocontext = avio_alloc_context(m_membuf, FF_MIN_BUFFER_SIZE, 0, this, ^ PR: 227726 Obtained from: Arch Linux Added: head/graphics/blender/files/patch-ffmpeg4 (contents, props changed) Added: head/graphics/blender/files/patch-ffmpeg4 ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/graphics/blender/files/patch-ffmpeg4 Fri Apr 27 10:39:31 2018 (r468418) @@ -0,0 +1,107 @@ +https://git.archlinux.org/svntogit/community.git/tree/trunk/ffmpeg4.0.patch?h=packages/blender&id=059566c3ec72 + +--- intern/audaspace/ffmpeg/AUD_FFMPEGReader.cpp.orig 2017-09-12 03:44:17 UTC ++++ intern/audaspace/ffmpeg/AUD_FFMPEGReader.cpp +@@ -264,9 +264,9 @@ AUD_FFMPEGReader::AUD_FFMPEGReader(boost::shared_ptr(av_malloc(FF_MIN_BUFFER_SIZE + FF_INPUT_BUFFER_PADDING_SIZE)); ++ m_membuf = reinterpret_cast(av_malloc(AV_INPUT_BUFFER_MIN_SIZE + AV_INPUT_BUFFER_PADDING_SIZE)); + +- m_aviocontext = avio_alloc_context(m_membuf, FF_MIN_BUFFER_SIZE, 0, this, ++ m_aviocontext = avio_alloc_context(m_membuf, AV_INPUT_BUFFER_MIN_SIZE, 0, this, + read_packet, NULL, seek_packet); + + if(!m_aviocontext) +--- intern/audaspace/ffmpeg/AUD_FFMPEGWriter.cpp.orig 2017-09-12 03:44:17 UTC ++++ intern/audaspace/ffmpeg/AUD_FFMPEGWriter.cpp +@@ -163,7 +163,7 @@ AUD_FFMPEGWriter::AUD_FFMPEGWriter(std::string filenam + try + { + if(m_formatCtx->oformat->flags & AVFMT_GLOBALHEADER) +- m_codecCtx->flags |= CODEC_FLAG_GLOBAL_HEADER; ++ m_codecCtx->flags |= AV_CODEC_FLAG_GLOBAL_HEADER; + + AVCodec* codec = avcodec_find_encoder(m_codecCtx->codec_id); + if(!codec) +@@ -185,11 +185,11 @@ AUD_FFMPEGWriter::AUD_FFMPEGWriter(std::string filenam + if(avcodec_open2(m_codecCtx, codec, NULL)) + AUD_THROW(AUD_ERROR_FFMPEG, codec_error); + +- m_output_buffer.resize(FF_MIN_BUFFER_SIZE); ++ m_output_buffer.resize(AV_INPUT_BUFFER_MIN_SIZE); + int samplesize = AUD_MAX(AUD_SAMPLE_SIZE(m_specs), AUD_DEVICE_SAMPLE_SIZE(m_specs)); + + if(m_codecCtx->frame_size <= 1) { +- m_input_size = FF_MIN_BUFFER_SIZE * 8 / m_codecCtx->bits_per_coded_sample / m_codecCtx->channels; ++ m_input_size = AV_INPUT_BUFFER_MIN_SIZE * 8 / m_codecCtx->bits_per_coded_sample / m_codecCtx->channels; + m_input_buffer.resize(m_input_size * samplesize); + } + else +--- source/blender/blenkernel/intern/writeffmpeg.c.orig 2017-09-12 03:44:17 UTC ++++ source/blender/blenkernel/intern/writeffmpeg.c +@@ -605,8 +605,6 @@ static AVStream *alloc_video_stream(FFMpegContext *con + c->rc_buffer_aggressivity = 1.0; + #endif + +- c->me_method = ME_EPZS; +- + codec = avcodec_find_encoder(c->codec_id); + if (!codec) + return NULL; +@@ -668,14 +666,14 @@ static AVStream *alloc_video_stream(FFMpegContext *con + ) + { + PRINT("Using global header\n"); +- c->flags |= CODEC_FLAG_GLOBAL_HEADER; ++ c->flags |= AV_CODEC_FLAG_GLOBAL_HEADER; + } + + /* Determine whether we are encoding interlaced material or not */ + if (rd->mode & R_FIELDS) { + PRINT("Encoding interlaced video\n"); +- c->flags |= CODEC_FLAG_INTERLACED_DCT; +- c->flags |= CODEC_FLAG_INTERLACED_ME; ++ c->flags |= AV_CODEC_FLAG_INTERLACED_DCT; ++ c->flags |= AV_CODEC_FLAG_INTERLACED_ME; + } + + /* xasp & yasp got float lately... */ +@@ -764,7 +762,7 @@ static AVStream *alloc_audio_stream(FFMpegContext *con + } + + if (of->oformat->flags & AVFMT_GLOBALHEADER) { +- c->flags |= CODEC_FLAG_GLOBAL_HEADER; ++ c->flags |= AV_CODEC_FLAG_GLOBAL_HEADER; + } + + set_ffmpeg_properties(rd, c, "audio", &opts); +@@ -783,14 +781,14 @@ static AVStream *alloc_audio_stream(FFMpegContext *con + st->codec->time_base.den = st->codec->sample_rate; + + #ifndef FFMPEG_HAVE_ENCODE_AUDIO2 +- context->audio_outbuf_size = FF_MIN_BUFFER_SIZE; ++ context->audio_outbuf_size = AV_INPUT_BUFFER_MIN_SIZE; + #endif + + if (c->frame_size == 0) + // used to be if ((c->codec_id >= CODEC_ID_PCM_S16LE) && (c->codec_id <= CODEC_ID_PCM_DVD)) + // not sure if that is needed anymore, so let's try out if there are any + // complaints regarding some ffmpeg versions users might have +- context->audio_input_samples = FF_MIN_BUFFER_SIZE * 8 / c->bits_per_coded_sample / c->channels; ++ context->audio_input_samples = AV_INPUT_BUFFER_MIN_SIZE * 8 / c->bits_per_coded_sample / c->channels; + else { + context->audio_input_samples = c->frame_size; + #ifndef FFMPEG_HAVE_ENCODE_AUDIO2 +--- source/blender/imbuf/intern/indexer.c.orig 2017-09-11 04:34:59 UTC ++++ source/blender/imbuf/intern/indexer.c +@@ -537,7 +537,7 @@ static struct proxy_output_ctx *alloc_proxy_output_ffm + av_opt_set_int(rv->c, "qmax", ffmpeg_quality, 0); + + if (rv->of->flags & AVFMT_GLOBALHEADER) { +- rv->c->flags |= CODEC_FLAG_GLOBAL_HEADER; ++ rv->c->flags |= AV_CODEC_FLAG_GLOBAL_HEADER; + } + + if (avio_open(&rv->of->pb, fname, AVIO_FLAG_WRITE) < 0) {