summaryrefslogtreecommitdiff
path: root/multimedia
diff options
context:
space:
mode:
authorPav Lucistnik <pav@FreeBSD.org>2004-03-26 09:03:07 +0000
committerPav Lucistnik <pav@FreeBSD.org>2004-03-26 09:03:07 +0000
commit52c7725b318e9a50e75db7afcdfb157af86c9c2e (patch)
tree06e5cbd4fd8506960ec8ca472afa3b2bd1104a0c /multimedia
parentmark FORBIDDEN: http://people.freebsd.org/~eik/portaudit/c551ae17-7f00-11d8-8... (diff)
Add y4mscaler, a general-purpose video scaler which operates on YUV4MPEG2
streams, as produced and consumed by the MJPEGtools such as lav2yuv and mpeg2enc(1). y4mscaler is meant to be used in a pipeline. Thus, input is from stdin, and output is to stdout. The essential function of y4mscaler is to scale a specified "active" region of the input stream (the source) into a specified active region of the output stream (the target). Pixels outside of the active region of the source are ignored; pixels outside of the active region of the target are filled with a background color. The source may additionally have a matte applied to it; pixels outside the source matte are set to a separately specified background color. y4mscaler correctly handles chroma sampling, and thus it can also perform chroma subsampling conversions. The YUV4MPEG2 stream format currently only supports 4:2:0 subsampling, although y4mscaler can process 4:1:1, 4:2:2, and 4:4:4 modes by abusing the YUV4MPEG2 format a bit. Includes preset parameters for popular output streams: DVD, SVCD, VCD, DV, CVD, and SVCD/VCD still images. PR: ports/63962 Submitted by: michael johnson <ahze@ahze.net>
Notes
Notes: svn path=/head/; revision=105310
Diffstat (limited to 'multimedia')
-rw-r--r--multimedia/Makefile1
-rw-r--r--multimedia/y4mscaler/Makefile53
-rw-r--r--multimedia/y4mscaler/distinfo2
-rw-r--r--multimedia/y4mscaler/pkg-descr24
4 files changed, 80 insertions, 0 deletions
diff --git a/multimedia/Makefile b/multimedia/Makefile
index 4b7e6d398f4f..17eda078f804 100644
--- a/multimedia/Makefile
+++ b/multimedia/Makefile
@@ -123,5 +123,6 @@
SUBDIR += xmps-win32-plugin
SUBDIR += xtheater
SUBDIR += xvid
+ SUBDIR += y4mscaler
.include <bsd.port.subdir.mk>
diff --git a/multimedia/y4mscaler/Makefile b/multimedia/y4mscaler/Makefile
new file mode 100644
index 000000000000..aa0eb1854783
--- /dev/null
+++ b/multimedia/y4mscaler/Makefile
@@ -0,0 +1,53 @@
+# New ports collection makefile for: y4mscaler
+# Date created: Mon Mar 8 21:36:23 EST 2004
+# Whom: michael johnson <ahze@ahze.net>
+#
+# $FreeBSD$
+#
+
+PORTNAME= y4mscaler
+PORTVERSION= 0.6.1
+CATEGORIES= multimedia
+MASTER_SITES= http://www.mir.com/DMG/Software/
+DISTNAME= ${PKGNAME}-src
+EXTRACT_SUFX= .tgz
+
+MAINTAINER= ahze@ahze.net
+COMMENT= Y4mscaler scales, crops, and shifts Y'CbCr video
+
+LIB_DEPENDS= lavjpeg-1.6.1:${PORTSDIR}/multimedia/mjpegtools
+
+USE_REINPLACE= yes
+USE_GMAKE= yes
+
+WRKSRC= ${WRKDIR}/${PKGNAME}
+
+PORTDOCS= COPYING ChangeLog INSTALL README TODO
+MAN1= y4mscaler.1
+PLIST_FILES= bin/y4mscaler
+
+.include <bsd.port.pre.mk>
+
+post-patch:
+ @${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|' \
+ ${WRKSRC}/Makefile
+ @${REINPLACE_CMD} -e 's|-march=i686 -mcpu=i686|${CFLAGS}|' \
+ ${WRKSRC}/Makefile
+ @${REINPLACE_CMD} -e 's|COPT = -O2|#|' \
+ ${WRKSRC}/Makefile
+.if ${OSVERSION} < 500000
+ @${REINPLACE_CMD} -e 's|#define HAVE_STDINT_H 1|#undef HAVE_STDINT_H 1|' \
+ ${WRKSRC}/y4m-config.h
+.endif
+
+do-install:
+ @${INSTALL_PROGRAM} ${WRKSRC}/y4mscaler ${PREFIX}/bin/y4mscaler
+ @${INSTALL_MAN} ${WRKSRC}/y4mscaler.1 ${MANPREFIX}/man/man1/
+.if !defined(NOPORTDOCS)
+ @${MKDIR} ${DOCSDIR}
+.for docfile in ${PORTDOCS}
+ @${INSTALL_DATA} ${WRKSRC}/${docfile} ${DOCSDIR}
+.endfor
+.endif
+
+.include <bsd.port.post.mk>
diff --git a/multimedia/y4mscaler/distinfo b/multimedia/y4mscaler/distinfo
new file mode 100644
index 000000000000..9c3e0998b1be
--- /dev/null
+++ b/multimedia/y4mscaler/distinfo
@@ -0,0 +1,2 @@
+MD5 (y4mscaler-0.6.1-src.tgz) = 4f5d1451065f940c80624269ee3cc872
+SIZE (y4mscaler-0.6.1-src.tgz) = 49966
diff --git a/multimedia/y4mscaler/pkg-descr b/multimedia/y4mscaler/pkg-descr
new file mode 100644
index 000000000000..1513542ce801
--- /dev/null
+++ b/multimedia/y4mscaler/pkg-descr
@@ -0,0 +1,24 @@
+From y4msclaer(1):
+
+y4mscaler is a general-purpose video scaler which operates on YUV4MPEG2
+streams, as produced and consumed by the MJPEGtools such as lav2yuv and
+mpeg2enc(1).
+
+y4mscaler is meant to be used in a pipeline. Thus, input is from stdin, and
+output is to stdout. The essential function of y4mscaler is to scale a
+specified "active" region of the input stream (the source) into a specified
+active region of the output stream (the target). Pixels outside of the active
+region of the source are ignored; pixels outside of the active region of
+the target are filled with a background color. The source may additionally
+have a matte applied to it; pixels outside the source matte are set to a
+separately specified background color.
+
+y4mscaler correctly handles chroma sampling, and thus it can also perform
+chroma subsampling conversions. The YUV4MPEG2 stream format currently only
+supports 4:2:0 subsampling, although y4mscaler can process 4:1:1, 4:2:2, and
+4:4:4 modes by abusing the YUV4MPEG2 format a bit.
+
+Includes preset parameters for popular output streams: DVD, SVCD, VCD, DV,
+CVD, and SVCD/VCD still images.
+
+WWW: http://www.mir.com/DMG/y4mscaler.html