From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <gentoo-commits+bounces-863485-garchives=archives.gentoo.org@lists.gentoo.org> Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id B3C5A138010 for <garchives@archives.gentoo.org>; Mon, 15 Feb 2016 14:51:37 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 55B73E07FE; Mon, 15 Feb 2016 14:51:37 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id DF67FE07FE for <gentoo-commits@lists.gentoo.org>; Mon, 15 Feb 2016 14:51:36 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id C9F48340997 for <gentoo-commits@lists.gentoo.org>; Mon, 15 Feb 2016 14:51:35 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 3A331CFF for <gentoo-commits@lists.gentoo.org>; Mon, 15 Feb 2016 14:51:26 +0000 (UTC) From: "Alexis Ballier" <aballier@gentoo.org> To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Alexis Ballier" <aballier@gentoo.org> Message-ID: <1455547879.4b87a5769cd1d0b3d8d1dbf637d6a0d32d40e785.aballier@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: sci-libs/ViSP/, sci-libs/ViSP/files/ X-VCS-Repository: repo/gentoo X-VCS-Files: sci-libs/ViSP/ViSP-3.0.0.ebuild sci-libs/ViSP/files/ViSP-3.0.0-ffmpeg3.patch X-VCS-Directories: sci-libs/ViSP/files/ sci-libs/ViSP/ X-VCS-Committer: aballier X-VCS-Committer-Name: Alexis Ballier X-VCS-Revision: 4b87a5769cd1d0b3d8d1dbf637d6a0d32d40e785 X-VCS-Branch: master Date: Mon, 15 Feb 2016 14:51:26 +0000 (UTC) Precedence: bulk List-Post: <mailto:gentoo-commits@lists.gentoo.org> List-Help: <mailto:gentoo-commits+help@lists.gentoo.org> List-Unsubscribe: <mailto:gentoo-commits+unsubscribe@lists.gentoo.org> List-Subscribe: <mailto:gentoo-commits+subscribe@lists.gentoo.org> List-Id: Gentoo Linux mail <gentoo-commits.gentoo.org> X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 02915261-3eac-4ede-8a17-c9e5f2712f34 X-Archives-Hash: 19451d3acda96f3da2e12af4013b0c7f commit: 4b87a5769cd1d0b3d8d1dbf637d6a0d32d40e785 Author: Alexis Ballier <aballier <AT> gentoo <DOT> org> AuthorDate: Mon Feb 15 14:50:19 2016 +0000 Commit: Alexis Ballier <aballier <AT> gentoo <DOT> org> CommitDate: Mon Feb 15 14:51:19 2016 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4b87a576 sci-libs/ViSP: fix build with ffmpeg3. Package-Manager: portage-2.2.27 Signed-off-by: Alexis Ballier <aballier <AT> gentoo.org> sci-libs/ViSP/ViSP-3.0.0.ebuild | 2 +- sci-libs/ViSP/files/ViSP-3.0.0-ffmpeg3.patch | 78 ++++++++++++++++++++++++++++ 2 files changed, 79 insertions(+), 1 deletion(-) diff --git a/sci-libs/ViSP/ViSP-3.0.0.ebuild b/sci-libs/ViSP/ViSP-3.0.0.ebuild index 0f25727..da5a12e 100644 --- a/sci-libs/ViSP/ViSP-3.0.0.ebuild +++ b/sci-libs/ViSP/ViSP-3.0.0.ebuild @@ -53,7 +53,7 @@ REQUIRED_USE=" " S="${WORKDIR}/visp-${PV}" -PATCHES=( "${FILESDIR}/${P}-opencv.patch" ) +PATCHES=( "${FILESDIR}/${P}-opencv.patch" "${FILESDIR}/${P}-ffmpeg3.patch" ) src_configure() { local mycmakeargs=( diff --git a/sci-libs/ViSP/files/ViSP-3.0.0-ffmpeg3.patch b/sci-libs/ViSP/files/ViSP-3.0.0-ffmpeg3.patch new file mode 100644 index 0000000..8fd3c8b --- /dev/null +++ b/sci-libs/ViSP/files/ViSP-3.0.0-ffmpeg3.patch @@ -0,0 +1,78 @@ +Index: visp-3.0.0/modules/io/src/video/vpFFMPEG.cpp +=================================================================== +--- visp-3.0.0.orig/modules/io/src/video/vpFFMPEG.cpp ++++ visp-3.0.0/modules/io/src/video/vpFFMPEG.cpp +@@ -180,7 +180,7 @@ bool vpFFMPEG::openStream(const char *fi + if (pFrameRGB == NULL) + return false; + +- numBytes = avpicture_get_size (PIX_FMT_RGB24,pCodecCtx->width,pCodecCtx->height); ++ numBytes = avpicture_get_size (AV_PIX_FMT_RGB24,pCodecCtx->width,pCodecCtx->height); + } + + else if (color_type == vpFFMPEG::GRAY_SCALED) +@@ -194,7 +194,7 @@ bool vpFFMPEG::openStream(const char *fi + if (pFrameGRAY == NULL) + return false; + +- numBytes = avpicture_get_size (PIX_FMT_GRAY8,pCodecCtx->width,pCodecCtx->height); ++ numBytes = avpicture_get_size (AV_PIX_FMT_GRAY8,pCodecCtx->width,pCodecCtx->height); + } + + /* +@@ -211,10 +211,10 @@ bool vpFFMPEG::openStream(const char *fi + } + + if (color_type == vpFFMPEG::COLORED) +- avpicture_fill((AVPicture *)pFrameRGB, buffer, PIX_FMT_RGB24, pCodecCtx->width, pCodecCtx->height); ++ avpicture_fill((AVPicture *)pFrameRGB, buffer, AV_PIX_FMT_RGB24, pCodecCtx->width, pCodecCtx->height); + + else if (color_type == vpFFMPEG::GRAY_SCALED) +- avpicture_fill((AVPicture *)pFrameGRAY, buffer, PIX_FMT_GRAY8, pCodecCtx->width, pCodecCtx->height); ++ avpicture_fill((AVPicture *)pFrameGRAY, buffer, AV_PIX_FMT_GRAY8, pCodecCtx->width, pCodecCtx->height); + + streamWasOpen = true; + +@@ -231,10 +231,10 @@ bool vpFFMPEG::openStream(const char *fi + bool vpFFMPEG::initStream() + { + if (color_type == vpFFMPEG::COLORED) +- img_convert_ctx= sws_getContext(pCodecCtx->width, pCodecCtx->height, pCodecCtx->pix_fmt, pCodecCtx->width,pCodecCtx->height,PIX_FMT_RGB24, SWS_BICUBIC, NULL, NULL, NULL); ++ img_convert_ctx= sws_getContext(pCodecCtx->width, pCodecCtx->height, pCodecCtx->pix_fmt, pCodecCtx->width,pCodecCtx->height,AV_PIX_FMT_RGB24, SWS_BICUBIC, NULL, NULL, NULL); + + else if (color_type == vpFFMPEG::GRAY_SCALED) +- img_convert_ctx= sws_getContext(pCodecCtx->width, pCodecCtx->height, pCodecCtx->pix_fmt, pCodecCtx->width,pCodecCtx->height,PIX_FMT_GRAY8, SWS_BICUBIC, NULL, NULL, NULL); ++ img_convert_ctx= sws_getContext(pCodecCtx->width, pCodecCtx->height, pCodecCtx->pix_fmt, pCodecCtx->width,pCodecCtx->height,AV_PIX_FMT_GRAY8, SWS_BICUBIC, NULL, NULL, NULL); + + int ret = av_seek_frame(pFormatCtx, (int)videoStream, 0, AVSEEK_FLAG_ANY) ; + if (ret < 0 ) +@@ -703,7 +703,7 @@ bool vpFFMPEG::openEncoder(const char *f + pCodecCtx->time_base.den = framerate_encoder; + pCodecCtx->gop_size = 10; /* emit one intra frame every ten frames */ + pCodecCtx->max_b_frames=1; +- pCodecCtx->pix_fmt = PIX_FMT_YUV420P; ++ pCodecCtx->pix_fmt = AV_PIX_FMT_YUV420P; + + /* open it */ + #if LIBAVCODEC_VERSION_INT < AV_VERSION_INT(53,35,0) // libavcodec 53.35.0 +@@ -726,15 +726,15 @@ bool vpFFMPEG::openEncoder(const char *f + outbuf_size = 100000; + outbuf = new uint8_t[outbuf_size]; + +- numBytes = avpicture_get_size (PIX_FMT_YUV420P,pCodecCtx->width,pCodecCtx->height); ++ numBytes = avpicture_get_size (AV_PIX_FMT_YUV420P,pCodecCtx->width,pCodecCtx->height); + picture_buf = new uint8_t[numBytes]; +- avpicture_fill((AVPicture *)pFrame, picture_buf, PIX_FMT_YUV420P, pCodecCtx->width, pCodecCtx->height); ++ avpicture_fill((AVPicture *)pFrame, picture_buf, AV_PIX_FMT_YUV420P, pCodecCtx->width, pCodecCtx->height); + +- numBytes = avpicture_get_size (PIX_FMT_RGB24,pCodecCtx->width,pCodecCtx->height); ++ numBytes = avpicture_get_size (AV_PIX_FMT_RGB24,pCodecCtx->width,pCodecCtx->height); + buffer = new uint8_t[numBytes]; +- avpicture_fill((AVPicture *)pFrameRGB, buffer, PIX_FMT_RGB24, pCodecCtx->width, pCodecCtx->height); ++ avpicture_fill((AVPicture *)pFrameRGB, buffer, AV_PIX_FMT_RGB24, pCodecCtx->width, pCodecCtx->height); + +- img_convert_ctx= sws_getContext(pCodecCtx->width, pCodecCtx->height, PIX_FMT_RGB24, pCodecCtx->width,pCodecCtx->height,PIX_FMT_YUV420P, SWS_BICUBIC, NULL, NULL, NULL); ++ img_convert_ctx= sws_getContext(pCodecCtx->width, pCodecCtx->height, AV_PIX_FMT_RGB24, pCodecCtx->width,pCodecCtx->height,AV_PIX_FMT_YUV420P, SWS_BICUBIC, NULL, NULL, NULL); + + encoderWasOpened = true; +