diff options
Diffstat (limited to 'meta-oe/recipes-graphics')
53 files changed, 2669 insertions, 0 deletions
diff --git a/meta-oe/recipes-graphics/cairo/cairo-fpu.inc b/meta-oe/recipes-graphics/cairo/cairo-fpu.inc new file mode 100644 index 0000000000..bdaf789799 --- /dev/null +++ b/meta-oe/recipes-graphics/cairo/cairo-fpu.inc @@ -0,0 +1,6 @@ + +def get_cairo_fpu_setting(bb, d): + if bb.data.getVar('TARGET_FPU', d, 1) in [ 'soft' ]: + return "--disable-some-floating-point" + return "" + diff --git a/meta-oe/recipes-graphics/cairo/cairo.inc b/meta-oe/recipes-graphics/cairo/cairo.inc new file mode 100644 index 0000000000..42774e05be --- /dev/null +++ b/meta-oe/recipes-graphics/cairo/cairo.inc @@ -0,0 +1,20 @@ +SECTION = "libs" +PRIORITY = "optional" +DEPENDS = "virtual/libx11 pixman libsm libpng fontconfig libxrender glib-2.0" +DESCRIPTION = "Cairo graphics library" +LICENSE = "MPL LGPL" + +#check for TARGET_FPU=soft and inform configure of the result so it can disable some floating points +require cairo-fpu.inc +EXTRA_OECONF += "${@get_cairo_fpu_setting(bb, d)}" + +inherit autotools pkgconfig + +BBCLASSEXTEND = "native" + +PACKAGES =+ "cairo-trace cairo-trace-dev libcairo-script-interpreter libcairo-gobject" +FILES_libcairo-gobject = "${libdir}/libcairo-gobject.so.*" +FILES_libcairo-script-interpreter = "${libdir}/libcairo-script-interpreter.so.*" +FILES_cairo-trace = "${bindir}/*trace ${libdir}/cairo/libcairo-trace.so.*" +FILES_cairo-trace-dev = "${libdir}/cairo/*" + diff --git a/meta-oe/recipes-graphics/cairo/cairo_1.10.0.bb b/meta-oe/recipes-graphics/cairo/cairo_1.10.0.bb new file mode 100644 index 0000000000..dccb726edb --- /dev/null +++ b/meta-oe/recipes-graphics/cairo/cairo_1.10.0.bb @@ -0,0 +1,12 @@ +require cairo.inc + +LIC_FILES_CHKSUM = "file://COPYING;md5=e73e999e0c72b5ac9012424fa157ad77" + +PR = "r1" + +SRC_URI = "http://cairographics.org/releases/cairo-${PV}.tar.gz;name=cairo \ +" + +SRC_URI[cairo.md5sum] = "70a2ece66cf473d976e2db0f75bf199e" +SRC_URI[cairo.sha256sum] = "0f2ce4cc4615594088d74eb8b5360bad7c3cc3c3da9b61af9bfd979ed1ed94b2" + diff --git a/meta-oe/recipes-graphics/font-update-common/font-update-common/update-fonts b/meta-oe/recipes-graphics/font-update-common/font-update-common/update-fonts new file mode 100644 index 0000000000..19e3157d2f --- /dev/null +++ b/meta-oe/recipes-graphics/font-update-common/font-update-common/update-fonts @@ -0,0 +1,4 @@ +#!/bin/sh +#Author: Rolf Leggewie + +run-parts /etc/update-fonts-common.d/ diff --git a/meta-oe/recipes-graphics/font-update-common/font-update-common_0.1.bb b/meta-oe/recipes-graphics/font-update-common/font-update-common_0.1.bb new file mode 100644 index 0000000000..4a4c714ecb --- /dev/null +++ b/meta-oe/recipes-graphics/font-update-common/font-update-common_0.1.bb @@ -0,0 +1,16 @@ +DESCRIPTION = "Scripts to be called when fonts are installed or removed \ +to make them known to the WM, whether X11 or Opie" +AUTHOR = "Rolf Leggewie <oe-devel@rolf.leggewie.biz" + +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://${POKYBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58" + +SRC_URI = "file://update-fonts" + +do_install() { + install -d ${D}${bindir} + install -d ${D}${sysconfdir}/update-fonts-common.d/ + install -m 0755 ${WORKDIR}/update-fonts ${D}${bindir} +} + +PACKAGE_ARCH = "all" diff --git a/meta-oe/recipes-graphics/jasper/jasper_1.900.1.bb b/meta-oe/recipes-graphics/jasper/jasper_1.900.1.bb new file mode 100644 index 0000000000..ef9ca6fb40 --- /dev/null +++ b/meta-oe/recipes-graphics/jasper/jasper_1.900.1.bb @@ -0,0 +1,14 @@ +DESCRIPTION = "Jpeg 2000 implementation" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://LICENSE;md5=baa697d7510288a9cdcce9bd7edaf9bc" + +PR = "r1" + +SRC_URI = "http://www.ece.uvic.ca/~mdadams/jasper/software/jasper-${PV}.zip" + +inherit autotools lib_package + +EXTRA_OECONF = "--enable-shared" + +SRC_URI[md5sum] = "a342b2b4495b3e1394e161eb5d85d754" +SRC_URI[sha256sum] = "6b905a9c2aca2e275544212666eefc4eb44d95d0a57e4305457b407fe63f9494" diff --git a/meta-oe/recipes-graphics/pango/pango-1.28.3/no-tests.patch b/meta-oe/recipes-graphics/pango/pango-1.28.3/no-tests.patch new file mode 100644 index 0000000000..dafcb20c3b --- /dev/null +++ b/meta-oe/recipes-graphics/pango/pango-1.28.3/no-tests.patch @@ -0,0 +1,10 @@ +--- /tmp/Makefile.am 2007-03-01 13:29:37.000000000 +0100 ++++ pango-1.16.0/Makefile.am 2007-03-01 13:29:52.545251000 +0100 +@@ -1,6 +1,6 @@ + ## Process this file with automake to create Makefile.in. + +-SUBDIRS= pango modules pango-view examples docs tools tests ++SUBDIRS= pango modules pango-view examples docs tools + + EXTRA_DIST = \ + autogen.sh \ diff --git a/meta-oe/recipes-graphics/pango/pango.inc b/meta-oe/recipes-graphics/pango/pango.inc new file mode 100644 index 0000000000..b09869135e --- /dev/null +++ b/meta-oe/recipes-graphics/pango/pango.inc @@ -0,0 +1,53 @@ +DESCRIPTION = "The goal of the Pango project is to provide an \ +Open Source framework for the layout and rendering of \ +internationalized text." +LICENSE = "LGPL" + +inherit gnome +EXTRA_AUTORECONF = "" + +SECTION = "x11/libs" + +DEPENDS = "glib-2.0 fontconfig freetype zlib virtual/libiconv virtual/libx11 libxft gtk-doc cairo" + +DEPENDS_virtclass-native = "glib-2.0-native cairo-native" +BBCLASSEXTEND = "native" + +PACKAGES_DYNAMIC = "pango-module-*" +PACKAGES_DYNAMIC_virtclass-native = "" + +RRECOMMENDS_${PN} = "pango-module-basic-x pango-module-basic-fc" + +INC_PR = "r1" + +# seems to go wrong with default cflags +FULL_OPTIMIZATION_arm = "-O2" + +SRC_URI += "file://no-tests.patch \ + " + +EXTRA_OECONF += "--disable-glibtest \ + --enable-explicit-deps=no \ + --disable-debug" + +LEAD_SONAME = "libpango-1.0*" +LIBV = "1.6.0" + +FILES_${PN} = "/etc ${bindir}/* ${libdir}/libpango*.so.*" +FILES_${PN}-dbg += "${libdir}/pango/${LIBV}/modules/.debug" +FILES_${PN}-dev += "${libdir}/pango/${LIBV}/modules/*.la" + +postinst_prologue() { +if [ "x$D" != "x" ]; then + exit 1 +fi + +} + +python populate_packages_prepend () { + prologue = bb.data.getVar("postinst_prologue", d, 1) + + modules_root = bb.data.expand('${libdir}/pango/${LIBV}/modules', d) + + do_split_packages(d, modules_root, '^pango-(.*)\.so$', 'pango-module-%s', 'Pango module %s', prologue + 'pango-querymodules > /etc/pango/pango.modules') +} diff --git a/meta-oe/recipes-graphics/pango/pango/no-tests.patch b/meta-oe/recipes-graphics/pango/pango/no-tests.patch new file mode 100644 index 0000000000..b382126129 --- /dev/null +++ b/meta-oe/recipes-graphics/pango/pango/no-tests.patch @@ -0,0 +1,15 @@ + +# +# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher +# + +--- pango-1.2.5/Makefile.am~no-tests 2003-01-30 22:43:47.000000000 +0100 ++++ pango-1.2.5/Makefile.am 2004-03-11 11:31:25.000000000 +0100 +@@ -1,6 +1,6 @@ + ## Process this file with automake to create Makefile.in. + +-SUBDIRS= pango modules examples docs tools tests ++SUBDIRS= pango modules examples docs tools + + EXTRA_DIST = \ + pango.pc.in \ diff --git a/meta-oe/recipes-graphics/pango/pango/pkgconfig_fixes.patch b/meta-oe/recipes-graphics/pango/pango/pkgconfig_fixes.patch new file mode 100644 index 0000000000..f021591a91 --- /dev/null +++ b/meta-oe/recipes-graphics/pango/pango/pkgconfig_fixes.patch @@ -0,0 +1,79 @@ +Index: pango-1.18.1/configure.in +=================================================================== +--- pango-1.18.1.orig/configure.in 2007-08-28 00:29:54.000000000 +0000 ++++ pango-1.18.1/configure.in 2007-11-12 19:21:22.000000000 +0000 +@@ -226,13 +226,9 @@ + # + # Checks for FreeType + # +- FREETYPE_LIBS= +- FREETYPE_CFLAGS= +- AC_PATH_PROG(FREETYPE_CONFIG, freetype-config, no) +- if test "x$FREETYPE_CONFIG" != "xno" ; then +- FREETYPE_CFLAGS=`$FREETYPE_CONFIG --cflags` +- FREETYPE_LIBS=`$FREETYPE_CONFIG --libs` ++ PKG_CHECK_MODULES(FREETYPE, freetype2 >= 1.0.1, have_freetype=true, AC_MSG_RESULT([no])) + ++ if $have_freetype ; then + pango_save_ldflags=$LDFLAGS + LDFLAGS="$LDFLAGS $FREETYPE_LIBS" + AC_CHECK_LIB(freetype, FT_Get_Next_Char, have_freetype=true, :) +Index: pango-1.18.1/pangoft2-uninstalled.pc.in +=================================================================== +--- pango-1.18.1.orig/pangoft2-uninstalled.pc.in 2007-07-05 21:30:28.000000000 +0000 ++++ pango-1.18.1/pangoft2-uninstalled.pc.in 2007-11-12 19:23:44.000000000 +0000 +@@ -1,7 +1,7 @@ + Name: Pango FT2 Uninstalled + Description: Freetype 2.0 font support for Pango, Not Installed + Version: @VERSION@ +-Requires: pango +-Libs: ${pc_top_builddir}/${pcfiledir}/pango/libpangoft2-@PANGO_API_VERSION@.la @FREETYPE_LIBS@ +-Cflags: -I${pc_top_builddir}/${pcfiledir}/@srcdir@ @FREETYPE_CFLAGS@ ++Requires: pango freetype2 ++Libs: ${pc_top_builddir}/${pcfiledir}/pango/libpangoft2-@PANGO_API_VERSION@.la ++Cflags: -I${pc_top_builddir}/${pcfiledir}/@srcdir@ + +Index: pango-1.18.1/pangoft2.pc.in +=================================================================== +--- pango-1.18.1.orig/pangoft2.pc.in 2007-07-05 21:30:28.000000000 +0000 ++++ pango-1.18.1/pangoft2.pc.in 2007-11-12 19:27:05.000000000 +0000 +@@ -6,7 +6,7 @@ + Name: Pango FT2 + Description: Freetype 2.0 font support for Pango + Version: @VERSION@ +-Requires: pango +-Libs: -L${libdir} -lpangoft2-@PANGO_API_VERSION@ @PKGCONFIG_FREETYPE_LIBS@ +-Cflags: -I${includedir}/pango-1.0 @FONTCONFIG_CFLAGS@ @FREETYPE_CFLAGS@ ++Requires: pango freetype2 fontconfig ++Libs: -L${libdir} -lpangoft2-@PANGO_API_VERSION@ ++Cflags: -I${includedir}/pango-1.0 + +Index: pango-1.18.1/pangoxft-uninstalled.pc.in +=================================================================== +--- pango-1.18.1.orig/pangoxft-uninstalled.pc.in 2007-07-05 21:30:28.000000000 +0000 ++++ pango-1.18.1/pangoxft-uninstalled.pc.in 2007-11-12 19:22:24.000000000 +0000 +@@ -1,7 +1,7 @@ + Name: Pango Xft Uninstalled + Description: Xft font support for Pango, Not Installed + Version: @VERSION@ +-Requires: pango +-Libs: ${pc_top_builddir}/${pcfiledir}/pango/libpangoxft-@PANGO_API_VERSION@.la @XFT_LIBS@ +-Cflags: -I${pc_top_builddir}/${pcfiledir}/@srcdir@ @X_CFLAGS@ @FREETYPE_CFLAGS@ ++Requires: pango xft ++Libs: ${pc_top_builddir}/${pcfiledir}/pango/libpangoxft-@PANGO_API_VERSION@.la ++Cflags: -I${pc_top_builddir}/${pcfiledir}/@srcdir@ @X_CFLAGS@ + +Index: pango-1.18.1/pangoxft.pc.in +=================================================================== +--- pango-1.18.1.orig/pangoxft.pc.in 2007-07-05 21:30:28.000000000 +0000 ++++ pango-1.18.1/pangoxft.pc.in 2007-11-12 19:21:57.000000000 +0000 +@@ -6,6 +6,6 @@ + Name: Pango Xft + Description: Xft font support for Pango + Version: @VERSION@ +-Requires: pango pangoft2 +-Libs: -L${libdir} -lpangoxft-@PANGO_API_VERSION@ @PKGCONFIG_XFT_LIBS@ +-Cflags: -I${includedir}/pango-1.0 @XFT_CFLAGS@ ++Requires: pango pangoft2 xft ++Libs: -L${libdir} -lpangoxft-@PANGO_API_VERSION@ ++Cflags: -I${includedir}/pango-1.0 diff --git a/meta-oe/recipes-graphics/pango/pango_1.28.3.bb b/meta-oe/recipes-graphics/pango/pango_1.28.3.bb new file mode 100644 index 0000000000..4c875bf339 --- /dev/null +++ b/meta-oe/recipes-graphics/pango/pango_1.28.3.bb @@ -0,0 +1,9 @@ +require pango.inc + +LIC_FILES_CHKSUM = "file://COPYING;md5=3bf50002aefd002f49e7bb854063f7e7" + +SRC_URI[archive.md5sum] = "caa74baea47e7e16bc73c89f9089d522" +SRC_URI[archive.sha256sum] = "5e278bc9430cc7bb00270f183360d262c5006b51248e8b537ea904573f200632" + +PR = "${INC_PR}.0" + diff --git a/meta-oe/recipes-graphics/pango/pangomm_2.26.0.bb b/meta-oe/recipes-graphics/pango/pangomm_2.26.0.bb new file mode 100644 index 0000000000..ecf2dd1ee8 --- /dev/null +++ b/meta-oe/recipes-graphics/pango/pangomm_2.26.0.bb @@ -0,0 +1,22 @@ +DESCRIPTION = "C++ bindings for the pango library." +SECTION = "libs" +PRIORITY = "optional" +LICENSE = "LGPL" +DEPENDS = "mm-common cairomm glibmm" +SHRT_VER = "${@bb.data.getVar('PV',d,1).split('.')[0]}.${@bb.data.getVar('PV',d,1).split('.')[1]}" +PR = "r1" + +SRC_URI = "ftp://ftp.gnome.org/pub/GNOME/sources/pangomm/${SHRT_VER}/pangomm-${PV}.tar.bz2" + +inherit autotools flow-lossage + +FILES_${PN} = "${libdir}/lib*.so.*" +FILES_${PN}-dev += "${libdir}/*/include/" + +EXTRA_OECONF = " --disable-documentation " + +AUTOTOOLS_STAGE_PKGCONFIG = "1" + + +SRC_URI[md5sum] = "37f54dc8e6cb73ed923b22f313352156" +SRC_URI[sha256sum] = "bf26ebe42c12c81e5c32ceca80ff226a01c8d80d4db2a4cc3463d5bf241b095e" diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf-arphic-uming_20080216.bb b/meta-oe/recipes-graphics/ttf-fonts/ttf-arphic-uming_20080216.bb new file mode 100644 index 0000000000..bb259b9181 --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf-arphic-uming_20080216.bb @@ -0,0 +1,18 @@ +DESCRIPTION = "Unicode Mingti (printed) TrueType Font" +HOMEPAGE = "http://www.freedesktop.org/wiki/Software/CJKUnifonts" +LICENSE = "${PN}" +SRC_DISTRIBUTE_LICENSES += "${PN}" +RPROVIDES_${PN} = "virtual-chinese-font" +PR = "r2" + +SRC_URI = \ +"http://archive.ubuntu.com/ubuntu/pool/main/t/ttf-arphic-uming/ttf-arphic-uming_0.2.${PV}.1.orig.tar.gz" +S = "${WORKDIR}" + +require ttf.inc + +FILES_${PN} = "${datadir}" + + +SRC_URI[md5sum] = "d219fcaf953f3eb1889399955a00379f" +SRC_URI[sha256sum] = "8038a6db9e832456d5da5559aff8d15130243be1091bf24f3243503a6f1bda98" diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf-dejavu/30-dejavu-aliases.conf b/meta-oe/recipes-graphics/ttf-fonts/ttf-dejavu/30-dejavu-aliases.conf new file mode 100644 index 0000000000..9c6e56bf7c --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf-dejavu/30-dejavu-aliases.conf @@ -0,0 +1,16 @@ +<?xml version="1.0"?> +<!DOCTYPE fontconfig SYSTEM "fonts.dtd"> +<fontconfig> + <alias> + <family>DejaVu Serif</family> + <default><family>serif</family></default> + </alias> + <alias> + <family>DejaVu Sans</family> + <default><family>sans-serif</family></default> + </alias> + <alias> + <family>DejaVu Sans Mono</family> + <default><family>monospace</family></default> + </alias> +</fontconfig> diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf-dejavu_2.23.bb b/meta-oe/recipes-graphics/ttf-fonts/ttf-dejavu_2.23.bb new file mode 100644 index 0000000000..f852cbffd6 --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf-dejavu_2.23.bb @@ -0,0 +1,44 @@ +require ttf.inc + +DESCRIPTION = "DejaVu font - TTF Edition" +HOMEPAGE = "http://dejavu.sourceforge.net/wiki/" +LICENSE = "Bitstream Vera" +LIC_FILES_CHKSUM = "file://${WORKDIR}/dejavu-fonts-ttf-${PV}/LICENSE;md5=9f867da7a73fad2715291348e80d0763" + +# all subpackages except ${PN}-dbg and ${PN}-common itself rdepends on ${PN}-common +RDEPENDS_${PN}-sans = "${PN}-common" +RDEPENDS_${PN}-sans-mono = "${PN}-common" +RDEPENDS_${PN}-sans-condensed = "${PN}-common" +RDEPENDS_${PN}-serif = "${PN}-common" +RDEPENDS_${PN}-serif-condensed = "${PN}-common" +RDEPENDS_${PN}-common = "" +PR = "r3" + +SRC_URI = "${SOURCEFORGE_MIRROR}/dejavu/dejavu-fonts-ttf-${PV}.tar.bz2 \ + file://30-dejavu-aliases.conf" + +S = "${WORKDIR}/dejavu-fonts-ttf-${PV}/ttf" + +do_install_append () { + install -d ${D}${sysconfdir}/fonts/conf.d/ + install -m 0644 ${WORKDIR}/30-dejavu-aliases.conf ${D}${sysconfdir}/fonts/conf.d/ +} + +PACKAGES = "${PN}-dbg \ + ${PN}-sans \ + ${PN}-sans-mono \ + ${PN}-sans-condensed \ + ${PN}-serif \ + ${PN}-serif-condensed \ + ${PN}-common" +RRECOMMENDS_${PN}-dbg = "" + +FILES_${PN}-sans = "${datadir}/fonts/truetype/DejaVuSans.ttf ${datadir}/fonts/truetype/DejaVuSans-*.ttf" +FILES_${PN}-sans-mono = "${datadir}/fonts/truetype/DejaVuSansMono*.ttf" +FILES_${PN}-sans-condensed = "${datadir}/fonts/truetype/DejaVuSansCondensed*.ttf" +FILES_${PN}-serif = "${datadir}/fonts/truetype/DejaVuSerif.ttf ${datadir}/fonts/truetype/DejaVuSerif-*.ttf" +FILES_${PN}-serif-condensed = "${datadir}/fonts/truetype/DejaVuSerifCondensed*.ttf" +FILES_${PN}-common = "${sysconfdir}" + +SRC_URI[md5sum] = "ff871dff0b3e8a11cd5c54478f11073f" +SRC_URI[sha256sum] = "243642a1c3f4b6fd00125f5772ac5c8e4d0bb6586f5abb05829ead4b83ad5233" diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf-droid_git.bb b/meta-oe/recipes-graphics/ttf-fonts/ttf-droid_git.bb new file mode 100644 index 0000000000..3fa04abf5d --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf-droid_git.bb @@ -0,0 +1,28 @@ +require ttf.inc + +DESCRIPTION = "Droid fonts - TTF Edition" +HOMEPAGE = "http://www.droidfonts.com/" +LICENSE = "Apache-2.0" +PR = "r0" +# git magic below - SRCREV is an ID of /data/fonts subtree +# (so we don't need to fetch full platform/frameworks/base.git) +SRCREV = "31f255e44e618ff3b923f332e8fcb83403fd39f5" +PV = "0.0+${PR}+gitr${SRCREV}" + +SRC_URI = "git://android.git.kernel.org/platform/frameworks/base.git;protocol=git;branch=master" + +S = "${WORKDIR}/git" + +do_install_prepend() { + rm ${S}/Ahem.ttf # we're not packaging it +} + +PACKAGES = "${PN}-dbg ttf-droid-sans ttf-droid-sans-mono \ + ttf-droid-sans-fallback ttf-droid-sans-japanese ttf-droid-serif" +RRECOMMENDS_${PN}-dbg = "" + +FILES_ttf-droid-sans = "${datadir}/fonts/truetype/DroidSans.ttf ${datadir}/fonts/truetype/DroidSans-Bold.ttf" +FILES_ttf-droid-sans-mono = "${datadir}/fonts/truetype/DroidSansMono.ttf" +FILES_ttf-droid-sans-fallback = "${datadir}/fonts/truetype/DroidSansFallback.ttf" +FILES_ttf-droid-sans-japanese = "${datadir}/fonts/truetype/DroidSansJapanese.ttf" +FILES_ttf-droid-serif = "${datadir}/fonts/truetype/DroidSerif*.ttf" diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf-gentium/OFL.gz b/meta-oe/recipes-graphics/ttf-fonts/ttf-gentium/OFL.gz Binary files differnew file mode 100644 index 0000000000..7ebada7572 --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf-gentium/OFL.gz diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf-gentium_1.02.bb b/meta-oe/recipes-graphics/ttf-fonts/ttf-gentium_1.02.bb new file mode 100644 index 0000000000..698b2edf89 --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf-gentium_1.02.bb @@ -0,0 +1,135 @@ +require ttf.inc + +DESCRIPTION = "Gentium fonts - TTF Version" +HOMEPAGE = "http://scripts.sil.org/gentium" +LICENSE = "SIL Open Font License" +LICENSE_URL = "http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&item_id=OFL" +PR = "r3" + +SRC_URI = "${DEBIAN_MIRROR}/main/t/ttf-gentium/ttf-gentium_${PV}.orig.tar.gz \ + file://OFL.gz" + +S = "${WORKDIR}/ttf-sil-gentium-${PV}" + +do_install_append() { + + install -d ${D}${datadir}/doc/ttf-gentium/ + install -d ${D}${datadir}/doc/ttf-gentium-alt/ + + install -m 0644 ${WORKDIR}/OFL ${D}${datadir}/doc/ttf-gentium/ + install -m 0644 ${WORKDIR}/OFL ${D}${datadir}/doc/ttf-gentium-alt/ + +} + +PACKAGES = "${PN}-dbg ${PN} ${PN}-alt" + +FILES_ttf-gentium-alt = "${datadir}/fonts/truetype/GenAI*.ttf \ + ${datadir}/fonts/truetype/GenAR*.ttf \ + ${datadir}/doc/ttf-gentium-alt/*" + +FILES_${PN} = "${datadir}/fonts/truetype/GenI*.ttf \ + ${datadir}/fonts/truetype/GenR*.ttf \ + ${datadir}/doc/ttf-gentium/*" + +# +# License +# +# Gentium is released under the SIL Open Font License - please read it carefully +# and do not download the fonts unless you agree to the terms of the license: +# +# This Font Software is Copyright (c) 2003-2005, SIL International +# (http://scripts.sil.org/). All Rights Reserved. +# +# "Gentium" is a Reserved Font Name for this Font Software. "SIL" is a Reserved +# Font Name for this Font Software. +# +# This Font Software is licensed under the SIL Open Font License, Version 1.0. No +# modification of the license is permitted, only verbatim copy is allowed. This +# license is copied below, and is also available with a FAQ +# at:http://scripts.sil.org/OFL SIL OPEN FONT LICENSE +# +# Version 1.0 - 22 November 2005 +# +# PREAMBLE +# +# The goals of the Open Font License (OFL) are to stimulate worldwide development +# of cooperative font projects, to support the font creation efforts of academic +# and linguistic communities, and to provide an open framework in which fonts may +# be shared and improved in partnership with others. +# +# The OFL allows the licensed fonts to be used, studied, modified and +# redistributed freely as long as they are not sold by themselves. The fonts, +# including any derivative works, can be bundled, embedded, redistributed and +# sold with any software provided that the font names of derivative works are +# changed. The fonts and derivatives, however, cannot be released under any other +# type of license. +# +# DEFINITIONS +# +# "Font Software" refers to any and all of the following: +# +# * font files data files source code build scripts documentation +# +# "Reserved Font Name" refers to the Font Software name as seen by users and any +# other names as specified after the copyright statement. +# +# "Standard Version" refers to the collection of Font Software components as +# distributed by the Copyright Holder. +# +# "Modified Version" refers to any derivative font software made by adding to, +# deleting, or substituting -- in part or in whole -- any of the components of +# the Standard Version, by changing formats or by porting the Font Software to a +# new environment. +# +# "Author" refers to any designer, engineer, programmer, technical writer or +# other person who contributed to the Font Software. +# +# PERMISSION & CONDITIONS +# +# Permission is hereby granted, free of charge, to any person obtaining a copy of +# the Font Software, to use, study, copy, merge, embed, modify, redistribute, and +# sell modified and unmodified copies of the Font Software, subject to the +# following conditions: +# +# 1) Neither the Font Software nor any of its individual components, in Standard +# or Modified Versions, may be sold by itself. +# +# 2) Standard or Modified Versions of the Font Software may be bundled, +# redistributed and sold with any software, provided that each copy contains the +# above copyright notice and this license. These can be included either as +# stand-alone text files, human-readable headers or in the appropriate +# machine-readable metadata fields within text or binary files as long as those +# fields can be easily viewed by the user. +# +# 3) No Modified Version of the Font Software may use the Reserved Font Name(s), +# in part or in whole, unless explicit written permission is granted by the +# Copyright Holder. This restriction applies to all references stored in the Font +# Software, such as the font menu name and other font description fields, which +# are used to differentiate the font from others. +# +# 4) The name(s) of the Copyright Holder or the Author(s) of the Font Software +# shall not be used to promote, endorse or advertise any Modified Version, except +# to acknowledge the contribution(s) of the Copyright Holder and the Author(s) or +# with their explicit written permission. +# +# 5) The Font Software, modified or unmodified, in part or in whole, must be +# distributed using this license, and may not be distributed under any other +# license. +# +# TERMINATION +# +# This license becomes null and void if any of the above conditions are not met. +# +# DISCLAIMER +# +# THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +# IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF MERCHANTABILITY, +# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF COPYRIGHT, PATENT, +# TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE FOR +# ANY CLAIM, DAMAGES OR OTHER LIABILITY, INCLUDING ANY GENERAL, SPECIAL, +# INDIRECT, INCIDENTAL, OR CONSEQUENTIAL DAMAGES, WHETHER IN AN ACTION OF +# CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF THE USE OR INABILITY TO USE +# THE FONT SOFTWARE OR FROM OTHER DEALINGS IN THE FONT SOFTWARE. + +SRC_URI[md5sum] = "4c3e6ae586be277537ebb68f2a45b883" +SRC_URI[sha256sum] = "4746c04c9a4ad9e0788a38e0a2f81919a630d8070ceabc89f156b6d41d8ceb37" diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf-hunkyfonts_0.3.0.bb b/meta-oe/recipes-graphics/ttf-fonts/ttf-hunkyfonts_0.3.0.bb new file mode 100644 index 0000000000..3984f868a5 --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf-hunkyfonts_0.3.0.bb @@ -0,0 +1,18 @@ +require ttf.inc + +DESCRIPTION = "Hunky fonts - TTF Version" +HOMEPAGE = "http://sourceforge.net/projects/hunkyfonts" +LICENSE = "LGPL" +PR = "r3" + +SRC_URI = "${SOURCEFORGE_MIRROR}/hunkyfonts/hunkyfonts-${PV}.tar.bz2" + +S = "${WORKDIR}/hunkyfonts-${PV}/TTF/" + +PACKAGES = "${PN}-dbg ttf-hunky-sans ttf-hunky-serif" +RRECOMMENDS_${PN}-dbg = "" +FILES_ttf-hunky-sans = "${datadir}/fonts/truetype/HunkySans*.ttf" +FILES_ttf-hunky-serif = "${datadir}/fonts/truetype/HunkySerif*.ttf" + +SRC_URI[md5sum] = "36444795a356fb8a56c63b2840729bab" +SRC_URI[sha256sum] = "e0b1849c545b6af276407d93025c73094dd74fc259b07c1d91594fdbb9a0b829" diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf-mplus_027.bb b/meta-oe/recipes-graphics/ttf-fonts/ttf-mplus_027.bb new file mode 100644 index 0000000000..a6f885b8dd --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf-mplus_027.bb @@ -0,0 +1,22 @@ +require ttf.inc + +DESCRIPTION = "MPlus font - TTF Edition" +HOMEPAGE = "http://dejavu.sourceforge.net/wiki/" +LICENSE = "${PN}" +PR = "r0" + +SRC_URI = "http://osdn.dl.sourceforge.jp/mplus-fonts/6650/mplus-TESTFLIGHT-${PV}.tar.gz" +S = "${WORKDIR}/mplus-TESTFLIGHT-${PV}" + +python populate_packages_prepend() { + plugindir = bb.data.expand('${datadir}/fonts/ttf-mplus/', d) + do_split_packages(d, plugindir, '^(.*)\.ttf$', 'ttf-%s', 'TTF Font %s', extra_depends = "ttf-common") +} + +do_install() { + install -d ${D}${datadir}/fonts/ttf-mplus + install -m 0644 *.ttf ${D}${datadir}/fonts/ttf-mplus/ +} + +SRC_URI[md5sum] = "d1400184b51b3871e8d2fca6c50e18ae" +SRC_URI[sha256sum] = "a20b9b9b03c2a6fb1e2137d29e8a6ce06406ba1e008906ea3c474dc048dc06a6" diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf-sazanami_20040629.bb b/meta-oe/recipes-graphics/ttf-fonts/ttf-sazanami_20040629.bb new file mode 100644 index 0000000000..1b9a01b2a1 --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf-sazanami_20040629.bb @@ -0,0 +1,33 @@ +require ttf.inc + +DESCRIPTION = "Sazanami Gothic/Mincho Japanese TrueType fonts" +DESCRIPTION_ttf-sazanami-gothic = "Sazanami Gothic Japanese TrueType font" +DESCRIPTION_ttf-sazanami-mincho = "Sazanami Mincho Japanese TrueType font" +AUTHOR = "Electronic Font Open Laboratory (/efont/)" +HOMEPAGE = "http://sourceforge.jp/projects/efont/" +LICENSE = "${PN}" +SRC_DISTRIBUTE_LICENSES += "${PN}" +RPROVIDES_${PN} = "virtual-japanese-font" +PR = "r5" + +SRC_URI = "http://osdn.dl.sourceforge.jp/efont/10087/sazanami-20040629.tar.bz2" +S = "${WORKDIR}/sazanami-20040629" + +PACKAGES = "${PN}-dbg ttf-sazanami-gothic ttf-sazanami-mincho" +RRECOMMENDS_${PN}-dbg = "" +FILES_ttf-sazanami-gothic = "${datadir}/fonts/truetype/sazanami-gothic.ttf \ + ${datadir}/doc/ttf-sazanami-gothic/README" +FILES_ttf-sazanami-mincho = "${datadir}/fonts/truetype/sazanami-mincho.ttf \ + ${datadir}/doc/ttf-sazanami-mincho/README" + +do_install_append() { + # README contains the redistribution license + install -d ${D}${datadir}/doc/ + install -d ${D}${datadir}/doc/ttf-sazanami-gothic + install -d ${D}${datadir}/doc/ttf-sazanami-mincho + install -m 0644 ${S}/README ${D}${datadir}/doc/ttf-sazanami-gothic + install -m 0644 ${S}/README ${D}${datadir}/doc/ttf-sazanami-mincho +} + +SRC_URI[md5sum] = "ceef10579a75c92483171f3bd7f77df2" +SRC_URI[sha256sum] = "3467ce2f70a9a3fbbf8d4d97355a2f334a6351baa6722251403637a8cbebf6b7" diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf-ubuntu-font-family_0.69.bb b/meta-oe/recipes-graphics/ttf-fonts/ttf-ubuntu-font-family_0.69.bb new file mode 100644 index 0000000000..cc8d2e4cb3 --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf-ubuntu-font-family_0.69.bb @@ -0,0 +1,18 @@ +require ttf.inc + +DESCRIPTION = "Ubuntu Font Family - TTF Version" +HOMEPAGE = "http://font.ubuntu.com" +LICENSE = "UFL" +PR = "r0" + +SRC_URI = "http://font.ubuntu.com/download/ubuntu-font-family-${PV}+ufl.zip" +SRC_URI[md5sum] = "2c3287ea72f81ce025095f7a6d68af28" +SRC_URI[sha256sum] = "23206a306d92ec57404ab3bc75610b6d8cfed0b8ddcfbe51b99fb48519a4855b" +S = "${WORKDIR}/ubuntu-font-family-0.69+ufl" + +PACKAGES = "${PN}-dbg ttf-ubuntu-mono ttf-ubuntu-sans ttf-ubuntu-serif" +RRECOMMENDS_${PN}-dbg = "" + +FILES_ttf-ubuntu-mono = "${datadir}/fonts/truetype/*Mono*" +FILES_ttf-ubuntu-sans = "${datadir}/fonts/truetype/Ubuntu-*" +FILES_ttf-ubuntu-serif = "${datadir}/fonts/truetype/*Serif*" diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf-wqy-zenhei_0.6.26.bb b/meta-oe/recipes-graphics/ttf-fonts/ttf-wqy-zenhei_0.6.26.bb new file mode 100644 index 0000000000..2d1d23e12a --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf-wqy-zenhei_0.6.26.bb @@ -0,0 +1,22 @@ +require ttf.inc + +DESCRIPTION = "WenQuanYi Zen Hei - A Hei-Ti Style Chinese font" +AUTHOR = "Qianqian Fang and The WenQuanYi Project Contributors" +HOMEPAGE = "http://wqy.sourceforge.net/en/" +LICENSE = "GPLv2" + +SRC_URI = "${SOURCEFORGE_MIRROR}/wqy/wqy-zenhei-${PV}-0.tar.gz" +S = "${WORKDIR}/wqy-zenhei" + +do_install_append () { + install -d ${D}${sysconfdir}/fonts/conf.d/ + install -m 0644 ${S}/44-wqy-zenhei.conf ${D}${sysconfdir}/fonts/conf.d/ + install -m 0644 ${S}/66-wqy-zenhei-sharp.conf ${D}${sysconfdir}/fonts/conf.d/ +} + +PACKAGES = "${PN}" + +FILES_${PN} = "${datadir}/fonts ${sysconfdir}" + +SRC_URI[md5sum] = "bf2c1cb512606d995873bada27c777da" +SRC_URI[sha256sum] = "47355b6ec84bb309614b6d657ddfda993b96ed0be569264f82e523b254f945b2" diff --git a/meta-oe/recipes-graphics/ttf-fonts/ttf.inc b/meta-oe/recipes-graphics/ttf-fonts/ttf.inc new file mode 100644 index 0000000000..af3f278536 --- /dev/null +++ b/meta-oe/recipes-graphics/ttf-fonts/ttf.inc @@ -0,0 +1,23 @@ +DESCRIPTION ?= "TrueType font package ${PN}" +SECTION = "fonts" +PRIORITY = "optional" +# don't use RRECOMMENDS_${PN} here because sometimes each font is packaged to separate package and each one needs this dep to call update-fonts +RRECOMMENDS += "font-update-common" + +# we don't need a compiler nor a c library for these fonts +INHIBIT_DEFAULT_DEPS = "1" + +do_install() { + install -d ${D}${datadir}/fonts/truetype/ + find ./ -name '*.tt[cf]' -exec install -m 0644 {} ${D}${datadir}/fonts/truetype/ \; +} + +pkg_postinst_append() { + update-fonts +} + +pkg_postrm_append() { + update-fonts +} + +PACKAGE_ARCH = "all" diff --git a/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb/0001-blacklist-tv-out.patch b/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb/0001-blacklist-tv-out.patch new file mode 100644 index 0000000000..5ac3b7ae9e --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb/0001-blacklist-tv-out.patch @@ -0,0 +1,28 @@ +From 05efb061f1945425d214ff6b6050883e6d8633bf Mon Sep 17 00:00:00 2001 +From: Koen Kooi <koen@dominion.thruhere.net> +Date: Wed, 26 Jan 2011 13:21:12 +0100 +Subject: [PATCH 1/3] blacklist tv out + +Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> +--- + src/omapfb-output-dss.c | 4 ++++ + 1 files changed, 4 insertions(+), 0 deletions(-) + +diff --git a/src/omapfb-output-dss.c b/src/omapfb-output-dss.c +index 6cc52de..83cb711 100644 +--- a/src/omapfb-output-dss.c ++++ b/src/omapfb-output-dss.c +@@ -205,6 +205,10 @@ OMAPFBDSSOutputDetect (xf86OutputPtr output) + if(ofb->timings[idx][0] == '\0') + return XF86OutputStatusDisconnected; + ++ // Hack to disable the tv out ++ if (strncmp(output->name, "tv", 2) == 0) ++ return XF86OutputStatusDisconnected; ++ + return XF86OutputStatusConnected; + } + +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb/0002-Revert-Set-virtual-size-when-configuring-framebuffer.patch b/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb/0002-Revert-Set-virtual-size-when-configuring-framebuffer.patch new file mode 100644 index 0000000000..41d5f131a6 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb/0002-Revert-Set-virtual-size-when-configuring-framebuffer.patch @@ -0,0 +1,26 @@ +From 316f31253902eb3567ef62faf52b3f0a5d6b0c93 Mon Sep 17 00:00:00 2001 +From: Koen Kooi <koen@dominion.thruhere.net> +Date: Wed, 26 Jan 2011 13:27:20 +0100 +Subject: [PATCH 2/3] Revert "Set virtual size when configuring framebuffer" + +This reverts commit 2653ef07883fbd1a5e7025f9300cf89b79ba429a. +--- + src/omapfb-crtc.c | 2 -- + 1 files changed, 0 insertions(+), 2 deletions(-) + +diff --git a/src/omapfb-crtc.c b/src/omapfb-crtc.c +index 9aaa52f..d321a5a 100644 +--- a/src/omapfb-crtc.c ++++ b/src/omapfb-crtc.c +@@ -98,8 +98,6 @@ OMAPFBCrtcCommitChangeMode (xf86CrtcPtr crtc) + v = ofb->state_info; + v.xres = mode->HDisplay; + v.yres = mode->VDisplay; +- v.xres_virtual = crtc->scrn->virtualX; +- v.yres_virtual = crtc->scrn->virtualY; + v.activate = FB_ACTIVATE_NOW; + v.pixclock = KHZ2PICOS(mode->Clock ? mode->Clock : 56000); + v.left_margin = mode->HTotal - mode->HSyncEnd; +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb/0003-force-plain-mode.patch b/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb/0003-force-plain-mode.patch new file mode 100644 index 0000000000..06eeca9d26 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb/0003-force-plain-mode.patch @@ -0,0 +1,26 @@ +From b7acfade1ac15332ebfd24d4bf02b466858c8cf8 Mon Sep 17 00:00:00 2001 +From: Koen Kooi <koen@dominion.thruhere.net> +Date: Wed, 26 Jan 2011 13:20:20 +0100 +Subject: [PATCH 3/3] force 'plain' mode + +Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> +--- + src/omapfb-driver.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/src/omapfb-driver.c b/src/omapfb-driver.c +index 018e040..48aa09c 100644 +--- a/src/omapfb-driver.c ++++ b/src/omapfb-driver.c +@@ -326,7 +326,7 @@ OMAPFBPreInit(ScrnInfoPtr pScrn, int flags) + OMAPFBProbeController(ofb->ctrl_name); + + /* Do we have the DSS kernel API? */ +- if (stat(SYSFS_DSS_DIR, &st) == 0) { ++ if (0) { //stat(SYSFS_DSS_DIR, &st) == 0) { + ofb->dss = TRUE; + } else { + ofb->dss = FALSE; +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb_git.bb b/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb_git.bb new file mode 100644 index 0000000000..85b68b17c6 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-driver/xf86-video-omapfb_git.bb @@ -0,0 +1,29 @@ +require recipes-graphics/xorg-driver/xf86-driver-common.inc + +INC_PR ?= "r15" + +DESCRIPTION = "X.Org X server -- OMAP display driver" +PE = "1" +PV = "0.1.1+${PR}+gitr${SRCREV}" +PR = "${INC_PR}.2" + +LICENSE = "MIT-X" +LIC_FILES_CHKSUM = "file://src/omapfb-driver.c;beginline=1;endline=30;md5=a44c2a37e04d1c2c5f0313afb493f833" + +SRC_URI = "git://git.pingu.fi/xf86-video-omapfb.git;protocol=http \ + file://0001-blacklist-tv-out.patch \ + file://0002-Revert-Set-virtual-size-when-configuring-framebuffer.patch \ + file://0003-force-plain-mode.patch \ + " + +SRCREV_pn-${PN} = "044617665d6737f4909aab96f91b06261dff05d2" +S = "${WORKDIR}/git" + +EXTRA_OECONF_armv7a = " --enable-neon " + +# Use overlay 2 on omap3 to enable other apps to use overlay 1 (e.g. dmai or omapfbplay) +do_compile_prepend_armv7a () { + sed -i -e s:fb1:fb2:g ${S}/src/omapfb-xv.c +} + +CFLAGS += " -I${STAGING_INCDIR}/xorg " diff --git a/meta-oe/recipes-graphics/xorg-lib/libxext_1.2.0.bb b/meta-oe/recipes-graphics/xorg-lib/libxext_1.2.0.bb new file mode 100644 index 0000000000..3d18d62882 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/libxext_1.2.0.bb @@ -0,0 +1,18 @@ +DESCRIPTION = "X11 miscellaneous extension library" + +require xorg-lib-common.inc + +LICENSE = "MIT-style" +LIC_FILES_CHKSUM = "file://COPYING;md5=0542b0321c1c9a7a20b23a1b9fa45f91" + +DEPENDS += "xproto virtual/libx11 xextproto libxau libxdmcp" +PROVIDES = "xext" + +PR = "r0" +PE = "1" + +XORG_PN = "libXext" + + +SRC_URI[md5sum] = "9bb236ff0193e9fc1c1fb504dd840331" +SRC_URI[sha256sum] = "4aed3e211e41c47908c293515580e731c26048f61a1212bf0888d1f456de6ff7" diff --git a/meta-oe/recipes-graphics/xorg-lib/libxrender_0.9.6.bb b/meta-oe/recipes-graphics/xorg-lib/libxrender_0.9.6.bb new file mode 100644 index 0000000000..c1bb045f86 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/libxrender_0.9.6.bb @@ -0,0 +1,17 @@ +DESCRIPTION = "X11 Rendering Extension client library" + +require xorg-lib-common.inc + +LICENSE = "MIT-style" +LIC_FILES_CHKSUM = "file://COPYING;md5=0db75cc842842b36f097fdae571b4b70" + +DEPENDS += "virtual/libx11 renderproto xproto xdmcp" + +PR = "r0" +PE = "1" + +XORG_PN = "libXrender" + + +SRC_URI[md5sum] = "3b3b7d076c2384b6c600c0b5f4ba971f" +SRC_URI[sha256sum] = "7f58b1e263109e0a873eef8423aa14733a5499befbe645053aa622ed1f3ea668" diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0000-Add-pixman_bits_override_accessors.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0000-Add-pixman_bits_override_accessors.patch new file mode 100644 index 0000000000..43cd44268e --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0000-Add-pixman_bits_override_accessors.patch @@ -0,0 +1,77 @@ +From 38aabb3be87ea68e37f34256c778d07f62680ec6 Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Thu, 10 Dec 2009 00:51:50 +0200 +Subject: [PATCH 1/9] add _pixman_bits_override_accessors + +* from patch ARM: HACK: added NEON optimizations for fetch/store r5g6b5 scanline +* used in + 0005-ARM-added-NEON-optimizations-for-fetch-store-r5g6b5-.patch + 0006-ARM-added-NEON-optimizations-for-fetch-store-a8-scan.patch + 0007-ARM-added-NEON-optimizations-for-fetching-x8r8g8b8-s.patch + + +--- + pixman/pixman-access.c | 23 ++++++++++++++++++++++- + pixman/pixman-private.h | 5 +++++ + 4 files changed, 87 insertions(+), 1 deletions(-) + +diff --git a/pixman/pixman-access.c b/pixman/pixman-access.c +index f1ce0ba..b33da29 100644 +--- a/pixman/pixman-access.c ++++ b/pixman/pixman-access.c +@@ -2836,7 +2836,7 @@ typedef struct + store_scanline_ ## format, store_scanline_generic_64 \ + } + +-static const format_info_t accessors[] = ++static format_info_t accessors[] = + { + /* 32 bpp formats */ + FORMAT_INFO (a8r8g8b8), +@@ -2978,6 +2978,27 @@ _pixman_bits_image_setup_accessors (bits_image_t *image) + setup_accessors (image); + } + ++void ++_pixman_bits_override_accessors (pixman_format_code_t format, ++ fetch_scanline_t fetch_func, ++ store_scanline_t store_func) ++{ ++ format_info_t *info = accessors; ++ ++ while (info->format != PIXMAN_null) ++ { ++ if (info->format == format) ++ { ++ if (fetch_func) ++ info->fetch_scanline_32 = fetch_func; ++ if (store_func) ++ info->store_scanline_32 = store_func; ++ return; ++ } ++ info++; ++ } ++} ++ + #else + + void +diff --git a/pixman/pixman-private.h b/pixman/pixman-private.h +index d85868f..564f8f0 100644 +--- a/pixman/pixman-private.h ++++ b/pixman/pixman-private.h +@@ -206,6 +206,11 @@ void + _pixman_bits_image_setup_accessors (bits_image_t *image); + + void ++_pixman_bits_override_accessors (pixman_format_code_t format, ++ fetch_scanline_t fetch_func, ++ store_scanline_t store_func); ++ ++void + _pixman_image_get_scanline_generic_64 (pixman_image_t *image, + int x, + int y, +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0001-Generic-C-implementation-of-pixman_blt-with-overlapp.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0001-Generic-C-implementation-of-pixman_blt-with-overlapp.patch new file mode 100644 index 0000000000..795cce5bad --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0001-Generic-C-implementation-of-pixman_blt-with-overlapp.patch @@ -0,0 +1,114 @@ +From 97b2bb933455f222b392b5c60a8bde82d7d6329f Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Tue, 16 Mar 2010 16:55:28 +0100 +Subject: [PATCH 1/8] Generic C implementation of pixman_blt with overlapping support + +Uses memcpy/memmove functions to copy pixels, can handle the +case when both source and destination areas are in the same +image (this is useful for scrolling). + +It is assumed that copying direction is only important when +using the same image for both source and destination (and +src_stride == dst_stride). Copying direction is undefined +for the images with different source and destination stride +which happen to be in the overlapped areas (but this is an +unrealistic case anyway). +--- + pixman/pixman-general.c | 21 ++++++++++++++++++--- + pixman/pixman-private.h | 43 +++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 61 insertions(+), 3 deletions(-) + +diff --git a/pixman/pixman-general.c b/pixman/pixman-general.c +index 4d234a0..c4d2c14 100644 +--- a/pixman/pixman-general.c ++++ b/pixman/pixman-general.c +@@ -280,9 +280,24 @@ general_blt (pixman_implementation_t *imp, + int width, + int height) + { +- /* We can't blit unless we have sse2 or mmx */ +- +- return FALSE; ++ uint8_t *dst_bytes = (uint8_t *)dst_bits; ++ uint8_t *src_bytes = (uint8_t *)src_bits; ++ int bpp; ++ ++ if (src_bpp != dst_bpp || src_bpp & 7) ++ return FALSE; ++ ++ bpp = src_bpp >> 3; ++ width *= bpp; ++ src_stride *= 4; ++ dst_stride *= 4; ++ pixman_blt_helper (src_bytes + src_y * src_stride + src_x * bpp, ++ dst_bytes + dst_y * dst_stride + dst_x * bpp, ++ src_stride, ++ dst_stride, ++ width, ++ height); ++ return TRUE; + } + + static pixman_bool_t +diff --git a/pixman/pixman-private.h b/pixman/pixman-private.h +index c43172b..f980454 100644 +--- a/pixman/pixman-private.h ++++ b/pixman/pixman-private.h +@@ -10,6 +10,7 @@ + + #include "pixman.h" + #include <time.h> ++#include <string.h> + #include <assert.h> + #include <stdio.h> + #include <string.h> +@@ -873,4 +874,46 @@ void pixman_timer_register (pixman_timer_t *timer); + + #endif /* PIXMAN_TIMERS */ + ++/* a helper function, can blit 8-bit images with src/dst overlapping support */ ++static inline void ++pixman_blt_helper (uint8_t *src_bytes, ++ uint8_t *dst_bytes, ++ int src_stride, ++ int dst_stride, ++ int width, ++ int height) ++{ ++ /* ++ * The second part of this check is not strictly needed, but it prevents ++ * unnecessary upside-down processing of areas which belong to different ++ * images. Upside-down processing can be slower with fixed-distance-ahead ++ * prefetch and perceived as having more tearing. ++ */ ++ if (src_bytes < dst_bytes + width && ++ src_bytes + src_stride * height > dst_bytes) ++ { ++ src_bytes += src_stride * height - src_stride; ++ dst_bytes += dst_stride * height - dst_stride; ++ dst_stride = -dst_stride; ++ src_stride = -src_stride; ++ /* Horizontal scrolling to the left needs memmove */ ++ if (src_bytes + width > dst_bytes) ++ { ++ while (--height >= 0) ++ { ++ memmove (dst_bytes, src_bytes, width); ++ dst_bytes += dst_stride; ++ src_bytes += src_stride; ++ } ++ return; ++ } ++ } ++ while (--height >= 0) ++ { ++ memcpy (dst_bytes, src_bytes, width); ++ dst_bytes += dst_stride; ++ src_bytes += src_stride; ++ } ++} ++ + #endif /* PIXMAN_PRIVATE_H */ +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0002-Support-of-overlapping-src-dst-for-pixman_blt_mmx.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0002-Support-of-overlapping-src-dst-for-pixman_blt_mmx.patch new file mode 100644 index 0000000000..6e2d492aaf --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0002-Support-of-overlapping-src-dst-for-pixman_blt_mmx.patch @@ -0,0 +1,91 @@ +From 47b31f936641da07431093ede340465625bfcb3d Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Thu, 22 Oct 2009 05:45:47 +0300 +Subject: [PATCH 2/8] Support of overlapping src/dst for pixman_blt_mmx + +--- + pixman/pixman-mmx.c | 55 +++++++++++++++++++++++++++++--------------------- + 1 files changed, 32 insertions(+), 23 deletions(-) + +diff --git a/pixman/pixman-mmx.c b/pixman/pixman-mmx.c +index e936c4c..2413197 100644 +--- a/pixman/pixman-mmx.c ++++ b/pixman/pixman-mmx.c +@@ -2996,34 +2996,43 @@ pixman_blt_mmx (uint32_t *src_bits, + { + uint8_t * src_bytes; + uint8_t * dst_bytes; +- int byte_width; ++ int bpp; + +- if (src_bpp != dst_bpp) ++ if (src_bpp != dst_bpp || src_bpp & 7) + return FALSE; + +- if (src_bpp == 16) +- { +- src_stride = src_stride * (int) sizeof (uint32_t) / 2; +- dst_stride = dst_stride * (int) sizeof (uint32_t) / 2; +- src_bytes = (uint8_t *)(((uint16_t *)src_bits) + src_stride * (src_y) + (src_x)); +- dst_bytes = (uint8_t *)(((uint16_t *)dst_bits) + dst_stride * (dst_y) + (dst_x)); +- byte_width = 2 * width; +- src_stride *= 2; +- dst_stride *= 2; +- } +- else if (src_bpp == 32) ++ bpp = src_bpp >> 3; ++ width *= bpp; ++ src_stride *= 4; ++ dst_stride *= 4; ++ src_bytes = (uint8_t *)src_bits + src_y * src_stride + src_x * bpp; ++ dst_bytes = (uint8_t *)dst_bits + dst_y * dst_stride + dst_x * bpp; ++ ++ if (src_bpp != 16 && src_bpp != 32) + { +- src_stride = src_stride * (int) sizeof (uint32_t) / 4; +- dst_stride = dst_stride * (int) sizeof (uint32_t) / 4; +- src_bytes = (uint8_t *)(((uint32_t *)src_bits) + src_stride * (src_y) + (src_x)); +- dst_bytes = (uint8_t *)(((uint32_t *)dst_bits) + dst_stride * (dst_y) + (dst_x)); +- byte_width = 4 * width; +- src_stride *= 4; +- dst_stride *= 4; ++ pixman_blt_helper (src_bytes, dst_bytes, src_stride, dst_stride, ++ width, height); ++ return TRUE; + } +- else ++ ++ if (src_bytes < dst_bytes && src_bytes + src_stride * height > dst_bytes) + { +- return FALSE; ++ src_bytes += src_stride * height - src_stride; ++ dst_bytes += dst_stride * height - dst_stride; ++ dst_stride = -dst_stride; ++ src_stride = -src_stride; ++ ++ if (src_bytes + width > dst_bytes) ++ { ++ /* TODO: reverse scanline copy using MMX */ ++ while (--height >= 0) ++ { ++ memmove (dst_bytes, src_bytes, width); ++ dst_bytes += dst_stride; ++ src_bytes += src_stride; ++ } ++ return TRUE; ++ } + } + + while (height--) +@@ -3033,7 +3042,7 @@ pixman_blt_mmx (uint32_t *src_bits, + uint8_t *d = dst_bytes; + src_bytes += src_stride; + dst_bytes += dst_stride; +- w = byte_width; ++ w = width; + + while (w >= 2 && ((unsigned long)d & 3)) + { +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0003-Support-of-overlapping-src-dst-for-pixman_blt_sse2.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0003-Support-of-overlapping-src-dst-for-pixman_blt_sse2.patch new file mode 100644 index 0000000000..910f62e6dd --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0003-Support-of-overlapping-src-dst-for-pixman_blt_sse2.patch @@ -0,0 +1,91 @@ +From 13be027637602fffda3b3cb6e171d8d6a67b3b4b Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Thu, 22 Oct 2009 05:45:54 +0300 +Subject: [PATCH 3/8] Support of overlapping src/dst for pixman_blt_sse2 + +--- + pixman/pixman-sse2.c | 55 +++++++++++++++++++++++++++++-------------------- + 1 files changed, 32 insertions(+), 23 deletions(-) + +diff --git a/pixman/pixman-sse2.c b/pixman/pixman-sse2.c +index 5907de0..25015ae 100644 +--- a/pixman/pixman-sse2.c ++++ b/pixman/pixman-sse2.c +@@ -5027,34 +5027,43 @@ pixman_blt_sse2 (uint32_t *src_bits, + { + uint8_t * src_bytes; + uint8_t * dst_bytes; +- int byte_width; ++ int bpp; + +- if (src_bpp != dst_bpp) ++ if (src_bpp != dst_bpp || src_bpp & 7) + return FALSE; + +- if (src_bpp == 16) +- { +- src_stride = src_stride * (int) sizeof (uint32_t) / 2; +- dst_stride = dst_stride * (int) sizeof (uint32_t) / 2; +- src_bytes =(uint8_t *)(((uint16_t *)src_bits) + src_stride * (src_y) + (src_x)); +- dst_bytes = (uint8_t *)(((uint16_t *)dst_bits) + dst_stride * (dst_y) + (dst_x)); +- byte_width = 2 * width; +- src_stride *= 2; +- dst_stride *= 2; +- } +- else if (src_bpp == 32) ++ bpp = src_bpp >> 3; ++ width *= bpp; ++ src_stride *= 4; ++ dst_stride *= 4; ++ src_bytes = (uint8_t *)src_bits + src_y * src_stride + src_x * bpp; ++ dst_bytes = (uint8_t *)dst_bits + dst_y * dst_stride + dst_x * bpp; ++ ++ if (src_bpp != 16 && src_bpp != 32) + { +- src_stride = src_stride * (int) sizeof (uint32_t) / 4; +- dst_stride = dst_stride * (int) sizeof (uint32_t) / 4; +- src_bytes = (uint8_t *)(((uint32_t *)src_bits) + src_stride * (src_y) + (src_x)); +- dst_bytes = (uint8_t *)(((uint32_t *)dst_bits) + dst_stride * (dst_y) + (dst_x)); +- byte_width = 4 * width; +- src_stride *= 4; +- dst_stride *= 4; ++ pixman_blt_helper (src_bytes, dst_bytes, src_stride, dst_stride, ++ width, height); ++ return TRUE; + } +- else ++ ++ if (src_bytes < dst_bytes && src_bytes + src_stride * height > dst_bytes) + { +- return FALSE; ++ src_bytes += src_stride * height - src_stride; ++ dst_bytes += dst_stride * height - dst_stride; ++ dst_stride = -dst_stride; ++ src_stride = -src_stride; ++ ++ if (src_bytes + width > dst_bytes) ++ { ++ /* TODO: reverse scanline copy using SSE2 */ ++ while (--height >= 0) ++ { ++ memmove (dst_bytes, src_bytes, width); ++ dst_bytes += dst_stride; ++ src_bytes += src_stride; ++ } ++ return TRUE; ++ } + } + + while (height--) +@@ -5064,7 +5073,7 @@ pixman_blt_sse2 (uint32_t *src_bits, + uint8_t *d = dst_bytes; + src_bytes += src_stride; + dst_bytes += dst_stride; +- w = byte_width; ++ w = width; + + while (w >= 2 && ((unsigned long)d & 3)) + { +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0004-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0004-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch new file mode 100644 index 0000000000..f6aa9792b8 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0004-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch @@ -0,0 +1,94 @@ +From a913cc05a1a1c5a813cf06d248334edede9caab7 Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Wed, 18 Nov 2009 06:08:48 +0200 +Subject: [PATCH 4/8] Support of overlapping src/dst for pixman_blt_neon + +--- + pixman/pixman-arm-neon.c | 62 +++++++++++++++++++++++++++++++++++++-------- + 1 files changed, 51 insertions(+), 11 deletions(-) + +diff --git a/pixman/pixman-arm-neon.c b/pixman/pixman-arm-neon.c +index be5d403..cbfd7cf 100644 +--- a/pixman/pixman-arm-neon.c ++++ b/pixman/pixman-arm-neon.c +@@ -176,26 +176,66 @@ pixman_blt_neon (uint32_t *src_bits, + int width, + int height) + { +- if (src_bpp != dst_bpp) ++ uint8_t * src_bytes; ++ uint8_t * dst_bytes; ++ int bpp; ++ ++ if (src_bpp != dst_bpp || src_bpp & 7) + return FALSE; + ++ bpp = src_bpp >> 3; ++ width *= bpp; ++ src_stride *= 4; ++ dst_stride *= 4; ++ src_bytes = (uint8_t *)src_bits + src_y * src_stride + src_x * bpp; ++ dst_bytes = (uint8_t *)dst_bits + dst_y * dst_stride + dst_x * bpp; ++ ++ if (src_bpp != 16 && src_bpp != 32) ++ { ++ pixman_blt_helper (src_bytes, dst_bytes, src_stride, dst_stride, ++ width, height); ++ return TRUE; ++ } ++ ++ if (src_bytes < dst_bytes && src_bytes + src_stride * height > dst_bytes) ++ { ++ src_bytes += src_stride * height - src_stride; ++ dst_bytes += dst_stride * height - dst_stride; ++ dst_stride = -dst_stride; ++ src_stride = -src_stride; ++ ++ if (src_bytes + width > dst_bytes) ++ { ++ /* TODO: reverse scanline copy using NEON */ ++ while (--height >= 0) ++ { ++ memmove (dst_bytes, src_bytes, width); ++ dst_bytes += dst_stride; ++ src_bytes += src_stride; ++ } ++ return TRUE; ++ } ++ } ++ + switch (src_bpp) + { + case 16: + pixman_composite_src_0565_0565_asm_neon ( +- width, height, +- (uint16_t *)(((char *) dst_bits) + +- dst_y * dst_stride * 4 + dst_x * 2), dst_stride * 2, +- (uint16_t *)(((char *) src_bits) + +- src_y * src_stride * 4 + src_x * 2), src_stride * 2); ++ width >> 1, ++ height, ++ (uint16_t *) dst_bytes, ++ dst_stride >> 1, ++ (uint16_t *) src_bytes, ++ src_stride >> 1); + return TRUE; + case 32: + pixman_composite_src_8888_8888_asm_neon ( +- width, height, +- (uint32_t *)(((char *) dst_bits) + +- dst_y * dst_stride * 4 + dst_x * 4), dst_stride, +- (uint32_t *)(((char *) src_bits) + +- src_y * src_stride * 4 + src_x * 4), src_stride); ++ width >> 2, ++ height, ++ (uint32_t *) dst_bytes, ++ dst_stride >> 2, ++ (uint32_t *) src_bytes, ++ src_stride >> 2); + return TRUE; + default: + return FALSE; +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0005-ARM-added-NEON-optimizations-for-fetch-store-r5g6b5-.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0005-ARM-added-NEON-optimizations-for-fetch-store-r5g6b5-.patch new file mode 100644 index 0000000000..dbe98b38ce --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0005-ARM-added-NEON-optimizations-for-fetch-store-r5g6b5-.patch @@ -0,0 +1,109 @@ +From f75e9d1868e21dd75ff3a2ca3561546d23877ddb Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Thu, 10 Dec 2009 00:51:50 +0200 +Subject: [PATCH 5/8] ARM: added NEON optimizations for fetch/store r5g6b5 scanline + +--- + pixman/pixman-arm-neon-asm.S | 20 ++++++++++++++++++++ + pixman/pixman-arm-neon.c | 40 ++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 60 insertions(+), 0 deletions(-) + +diff --git a/pixman/pixman-arm-neon-asm.S b/pixman/pixman-arm-neon-asm.S +index e4db5cd..c79ba81 100644 +--- a/pixman/pixman-arm-neon-asm.S ++++ b/pixman/pixman-arm-neon-asm.S +@@ -459,6 +459,16 @@ generate_composite_function \ + pixman_composite_src_8888_0565_process_pixblock_tail, \ + pixman_composite_src_8888_0565_process_pixblock_tail_head + ++generate_composite_function_single_scanline \ ++ pixman_store_scanline_r5g6b5_asm_neon, 32, 0, 16, \ ++ FLAG_DST_WRITEONLY | FLAG_DEINTERLEAVE_32BPP, \ ++ 8, /* number of pixels, processed in a single block */ \ ++ default_init, \ ++ default_cleanup, \ ++ pixman_composite_src_8888_0565_process_pixblock_head, \ ++ pixman_composite_src_8888_0565_process_pixblock_tail, \ ++ pixman_composite_src_8888_0565_process_pixblock_tail_head ++ + /******************************************************************************/ + + .macro pixman_composite_src_0565_8888_process_pixblock_head +@@ -494,6 +504,16 @@ generate_composite_function \ + pixman_composite_src_0565_8888_process_pixblock_tail, \ + pixman_composite_src_0565_8888_process_pixblock_tail_head + ++generate_composite_function_single_scanline \ ++ pixman_fetch_scanline_r5g6b5_asm_neon, 16, 0, 32, \ ++ FLAG_DST_WRITEONLY | FLAG_DEINTERLEAVE_32BPP, \ ++ 8, /* number of pixels, processed in a single block */ \ ++ default_init, \ ++ default_cleanup, \ ++ pixman_composite_src_0565_8888_process_pixblock_head, \ ++ pixman_composite_src_0565_8888_process_pixblock_tail, \ ++ pixman_composite_src_0565_8888_process_pixblock_tail_head ++ + /******************************************************************************/ + + .macro pixman_composite_add_8_8_process_pixblock_head +diff --git a/pixman/pixman-arm-neon.c b/pixman/pixman-arm-neon.c +index cbfd7cf..f88c8f8 100644 +--- a/pixman/pixman-arm-neon.c ++++ b/pixman/pixman-arm-neon.c +@@ -392,6 +392,42 @@ BIND_COMBINE_U (over) + BIND_COMBINE_U (add) + BIND_COMBINE_U (out_reverse) + ++void ++pixman_fetch_scanline_r5g6b5_asm_neon (int width, ++ uint32_t *buffer, ++ const uint16_t *pixel); ++void ++pixman_store_scanline_r5g6b5_asm_neon (int width, ++ uint16_t *pixel, ++ const uint32_t *values); ++ ++static void ++neon_fetch_scanline_r5g6b5 (pixman_image_t *image, ++ int x, ++ int y, ++ int width, ++ uint32_t * buffer, ++ const uint32_t *mask) ++{ ++ const uint32_t *bits = image->bits.bits + y * image->bits.rowstride; ++ const uint16_t *pixel = (const uint16_t *)bits + x; ++ ++ pixman_fetch_scanline_r5g6b5_asm_neon (width, buffer, pixel); ++} ++ ++static void ++neon_store_scanline_r5g6b5 (bits_image_t * image, ++ int x, ++ int y, ++ int width, ++ const uint32_t *values) ++{ ++ uint32_t *bits = image->bits + image->rowstride * y; ++ uint16_t *pixel = ((uint16_t *) bits) + x; ++ ++ pixman_store_scanline_r5g6b5_asm_neon (width, pixel, values); ++} ++ + pixman_implementation_t * + _pixman_implementation_create_arm_neon (void) + { +@@ -407,6 +443,10 @@ _pixman_implementation_create_arm_neon (void) + imp->combine_32[PIXMAN_OP_ADD] = neon_combine_add_u; + imp->combine_32[PIXMAN_OP_OUT_REVERSE] = neon_combine_out_reverse_u; + ++ _pixman_bits_override_accessors (PIXMAN_r5g6b5, ++ neon_fetch_scanline_r5g6b5, ++ neon_store_scanline_r5g6b5); ++ + imp->blt = arm_neon_blt; + imp->fill = arm_neon_fill; + +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0006-ARM-added-NEON-optimizations-for-fetch-store-a8-scan.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0006-ARM-added-NEON-optimizations-for-fetch-store-a8-scan.patch new file mode 100644 index 0000000000..d050646fa7 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0006-ARM-added-NEON-optimizations-for-fetch-store-a8-scan.patch @@ -0,0 +1,148 @@ +From a1cd695c5e22f0f4a2b7272fab675a3cc510bacb Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Thu, 23 Sep 2010 21:10:56 +0300 +Subject: [PATCH 6/8] ARM: added NEON optimizations for fetch/store a8 scanline + +--- + pixman/pixman-arm-neon-asm.S | 64 ++++++++++++++++++++++++++++++++++++++++++ + pixman/pixman-arm-neon.c | 42 +++++++++++++++++++++++++++ + 2 files changed, 106 insertions(+), 0 deletions(-) + +diff --git a/pixman/pixman-arm-neon-asm.S b/pixman/pixman-arm-neon-asm.S +index c79ba81..ca0825c 100644 +--- a/pixman/pixman-arm-neon-asm.S ++++ b/pixman/pixman-arm-neon-asm.S +@@ -418,6 +418,70 @@ generate_composite_function \ + + /******************************************************************************/ + ++.macro pixman_composite_src_8_8888_process_pixblock_head ++ /* This is tricky part: we can't set these values just once in 'init' macro ++ * because leading/trailing pixels handling part uses VZIP.8 instructions, ++ * and they operate on values in-place and destroy original registers ++ * content. Think about it like VST4.8 instruction corrupting NEON ++ * registers after write in 'tail_head' macro. Except that 'tail_head' ++ * macro itself actually does not need these extra VMOVs because it uses ++ * real VST4.8 instruction. ++ */ ++ vmov.u8 q0, #0 ++ vmov.u8 d2, #0 ++.endm ++ ++.macro pixman_composite_src_8_8888_process_pixblock_tail ++.endm ++ ++.macro pixman_composite_src_8_8888_process_pixblock_tail_head ++ vst4.8 {d0, d1, d2, d3}, [DST_W, :128]! ++ vld1.8 {d3}, [SRC]! ++.endm ++ ++generate_composite_function_single_scanline \ ++ pixman_fetch_scanline_a8_asm_neon, 8, 0, 32, \ ++ FLAG_DST_WRITEONLY | FLAG_DEINTERLEAVE_32BPP, \ ++ 8, /* number of pixels, processed in a single block */ \ ++ default_init, \ ++ default_cleanup, \ ++ pixman_composite_src_8_8888_process_pixblock_head, \ ++ pixman_composite_src_8_8888_process_pixblock_tail, \ ++ pixman_composite_src_8_8888_process_pixblock_tail_head, \ ++ 0, /* dst_w_basereg */ \ ++ 0, /* dst_r_basereg */ \ ++ 3, /* src_basereg */ \ ++ 0 /* mask_basereg */ ++ ++/******************************************************************************/ ++ ++.macro pixman_composite_src_8888_8_process_pixblock_head ++.endm ++ ++.macro pixman_composite_src_8888_8_process_pixblock_tail ++.endm ++ ++.macro pixman_composite_src_8888_8_process_pixblock_tail_head ++ vst1.8 {d3}, [DST_W, :64]! ++ vld4.8 {d0, d1, d2, d3}, [SRC]! ++.endm ++ ++generate_composite_function_single_scanline \ ++ pixman_store_scanline_a8_asm_neon, 32, 0, 8, \ ++ FLAG_DST_WRITEONLY | FLAG_DEINTERLEAVE_32BPP, \ ++ 8, /* number of pixels, processed in a single block */ \ ++ default_init, \ ++ default_cleanup, \ ++ pixman_composite_src_8888_8_process_pixblock_head, \ ++ pixman_composite_src_8888_8_process_pixblock_tail, \ ++ pixman_composite_src_8888_8_process_pixblock_tail_head, \ ++ 3, /* dst_w_basereg */ \ ++ 0, /* dst_r_basereg */ \ ++ 0, /* src_basereg */ \ ++ 0 /* mask_basereg */ ++ ++/******************************************************************************/ ++ + .macro pixman_composite_src_8888_0565_process_pixblock_head + vshll.u8 q8, d1, #8 + vshll.u8 q14, d2, #8 +diff --git a/pixman/pixman-arm-neon.c b/pixman/pixman-arm-neon.c +index f88c8f8..43091d2 100644 +--- a/pixman/pixman-arm-neon.c ++++ b/pixman/pixman-arm-neon.c +@@ -428,6 +428,45 @@ neon_store_scanline_r5g6b5 (bits_image_t * image, + pixman_store_scanline_r5g6b5_asm_neon (width, pixel, values); + } + ++void ++pixman_fetch_scanline_a8_asm_neon (int width, ++ uint32_t *buffer, ++ const uint8_t *pixel); ++ ++ ++void ++pixman_store_scanline_a8_asm_neon (int width, ++ uint8_t *pixel, ++ const uint32_t *values); ++ ++static void ++neon_fetch_scanline_a8 (pixman_image_t *image, ++ int x, ++ int y, ++ int width, ++ uint32_t * buffer, ++ const uint32_t *mask) ++{ ++ const uint32_t *bits = image->bits.bits + y * image->bits.rowstride; ++ const uint8_t *pixel = (const uint8_t *) bits + x; ++ ++ pixman_fetch_scanline_a8_asm_neon (width, buffer, pixel); ++} ++ ++static void ++neon_store_scanline_a8 (bits_image_t * image, ++ int x, ++ int y, ++ int width, ++ const uint32_t *values) ++{ ++ uint32_t *bits = image->bits + image->rowstride * y; ++ uint8_t *pixel = (uint8_t *) bits + x; ++ ++ pixman_store_scanline_a8_asm_neon (width, pixel, values); ++} ++ ++ + pixman_implementation_t * + _pixman_implementation_create_arm_neon (void) + { +@@ -446,6 +485,9 @@ _pixman_implementation_create_arm_neon (void) + _pixman_bits_override_accessors (PIXMAN_r5g6b5, + neon_fetch_scanline_r5g6b5, + neon_store_scanline_r5g6b5); ++ _pixman_bits_override_accessors (PIXMAN_a8, ++ neon_fetch_scanline_a8, ++ neon_store_scanline_a8); + + imp->blt = arm_neon_blt; + imp->fill = arm_neon_fill; +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0007-ARM-added-NEON-optimizations-for-fetching-x8r8g8b8-s.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0007-ARM-added-NEON-optimizations-for-fetching-x8r8g8b8-s.patch new file mode 100644 index 0000000000..7f28f47cff --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0007-ARM-added-NEON-optimizations-for-fetching-x8r8g8b8-s.patch @@ -0,0 +1,77 @@ +From d6ae7da60cc797900b5eff0786536c4a11ab0f50 Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Fri, 24 Sep 2010 18:22:44 +0300 +Subject: [PATCH 7/8] ARM: added NEON optimizations for fetching x8r8g8b8 scanline + +--- + pixman/pixman-arm-neon-asm.S | 14 ++++++++++++++ + pixman/pixman-arm-neon.c | 21 +++++++++++++++++++++ + 2 files changed, 35 insertions(+), 0 deletions(-) + +diff --git a/pixman/pixman-arm-neon-asm.S b/pixman/pixman-arm-neon-asm.S +index ca0825c..ffd0b83 100644 +--- a/pixman/pixman-arm-neon-asm.S ++++ b/pixman/pixman-arm-neon-asm.S +@@ -1206,6 +1206,20 @@ generate_composite_function \ + 0, /* src_basereg */ \ + 0 /* mask_basereg */ + ++generate_composite_function_single_scanline \ ++ pixman_fetch_scanline_x888_asm_neon, 32, 0, 32, \ ++ FLAG_DST_WRITEONLY, \ ++ 8, /* number of pixels, processed in a single block */ \ ++ pixman_composite_src_x888_8888_init, \ ++ default_cleanup, \ ++ pixman_composite_src_x888_8888_process_pixblock_head, \ ++ pixman_composite_src_x888_8888_process_pixblock_tail, \ ++ pixman_composite_src_x888_8888_process_pixblock_tail_head, \ ++ 0, /* dst_w_basereg */ \ ++ 0, /* dst_r_basereg */ \ ++ 0, /* src_basereg */ \ ++ 0 /* mask_basereg */ ++ + /******************************************************************************/ + + .macro pixman_composite_over_n_8_8888_process_pixblock_head +diff --git a/pixman/pixman-arm-neon.c b/pixman/pixman-arm-neon.c +index 43091d2..f84b5e6 100644 +--- a/pixman/pixman-arm-neon.c ++++ b/pixman/pixman-arm-neon.c +@@ -466,6 +466,24 @@ neon_store_scanline_a8 (bits_image_t * image, + pixman_store_scanline_a8_asm_neon (width, pixel, values); + } + ++void ++pixman_fetch_scanline_x888_asm_neon (int width, ++ uint32_t *buffer, ++ const uint32_t *pixel); ++ ++static void ++neon_fetch_scanline_x888 (pixman_image_t *image, ++ int x, ++ int y, ++ int width, ++ uint32_t * buffer, ++ const uint32_t *mask) ++{ ++ const uint32_t *bits = image->bits.bits + y * image->bits.rowstride; ++ const uint32_t *pixel = (const uint32_t *) bits + x; ++ ++ pixman_fetch_scanline_x888_asm_neon (width, buffer, pixel); ++} + + pixman_implementation_t * + _pixman_implementation_create_arm_neon (void) +@@ -488,6 +506,9 @@ _pixman_implementation_create_arm_neon (void) + _pixman_bits_override_accessors (PIXMAN_a8, + neon_fetch_scanline_a8, + neon_store_scanline_a8); ++ _pixman_bits_override_accessors (PIXMAN_x8r8g8b8, ++ neon_fetch_scanline_x888, ++ NULL); + + imp->blt = arm_neon_blt; + imp->fill = arm_neon_fill; +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0008-ARM-optimization-for-scaled-src_0565_0565-operation-.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0008-ARM-optimization-for-scaled-src_0565_0565-operation-.patch new file mode 100644 index 0000000000..6efdb621ad --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.20.0/0008-ARM-optimization-for-scaled-src_0565_0565-operation-.patch @@ -0,0 +1,172 @@ +From e1191ad6563a1fb02a45982b1c4d7fed3c655e97 Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Mon, 4 Oct 2010 01:56:59 +0300 +Subject: [PATCH 8/8] ARM optimization for scaled src_0565_0565 operation with nearest filter + +The code actually uses only armv4t instructions. + +Benchmark from ARM11: + + == before == + op=1, src_fmt=10020565, dst_fmt=10020565, speed=34.86 MPix/s + + == after == + op=1, src_fmt=10020565, dst_fmt=10020565, speed=36.62 MPix/s + +Benchmark from ARM Cortex-A8: + + == before == + op=1, src_fmt=10020565, dst_fmt=10020565, speed=89.55 MPix/s + + == after == + op=1, src_fmt=10020565, dst_fmt=10020565, speed=94.91 MPix/s +--- + pixman/pixman-arm-simd-asm.S | 66 ++++++++++++++++++++++++++++++++++++++++++ + pixman/pixman-arm-simd.c | 37 +++++++++++++++++++++++ + 2 files changed, 103 insertions(+), 0 deletions(-) + +diff --git a/pixman/pixman-arm-simd-asm.S b/pixman/pixman-arm-simd-asm.S +index a3d2d40..b6f69db 100644 +--- a/pixman/pixman-arm-simd-asm.S ++++ b/pixman/pixman-arm-simd-asm.S +@@ -1,5 +1,6 @@ + /* + * Copyright © 2008 Mozilla Corporation ++ * Copyright © 2010 Nokia Corporation + * + * Permission to use, copy, modify, distribute, and sell this software and its + * documentation for any purpose is hereby granted without fee, provided that +@@ -328,3 +329,68 @@ pixman_asm_function pixman_composite_over_n_8_8888_asm_armv6 + pop {r4, r5, r6, r7, r8, r9, r10, r11} + bx lr + .endfunc ++ ++/* ++ * Note: This function is actually primarily optimized for ARM Cortex-A8 ++ * pipeline. In order to get good performance on ARM9/ARM11 cores (which ++ * don't have efficient write combining), it needs to be changed to use ++ * 16-byte aligned writes using STM instruction. ++ */ ++pixman_asm_function pixman_scaled_nearest_scanline_565_565_SRC_asm_armv6 ++ DST .req r0 ++ SRC .req r1 ++ W .req r2 ++ VX .req r3 ++ UNIT_X .req r12 ++ TMP1 .req r4 ++ TMP2 .req r5 ++ MASK .req r6 ++ ldr UNIT_X, [sp] ++ push {r4, r5, r6, r7} ++ mvn MASK, #1 ++ ++ /* define helper macro */ ++ .macro scale_2_pixels ++ ldrh TMP1, [SRC, TMP1] ++ and TMP2, MASK, VX, lsr #15 ++ add VX, VX, UNIT_X ++ strh TMP1, [DST], #2 ++ ++ ldrh TMP2, [SRC, TMP2] ++ and TMP1, MASK, VX, lsr #15 ++ add VX, VX, UNIT_X ++ strh TMP2, [DST], #2 ++ .endm ++ ++ /* now do the scaling */ ++ and TMP1, MASK, VX, lsr #15 ++ add VX, VX, UNIT_X ++ subs W, #4 ++ blt 2f ++1: /* main loop, process 4 pixels per iteration */ ++ scale_2_pixels ++ scale_2_pixels ++ subs W, W, #4 ++ bge 1b ++2: ++ tst W, #2 ++ beq 2f ++ scale_2_pixels ++2: ++ tst W, #1 ++ ldrneh TMP1, [SRC, TMP1] ++ strneh TMP1, [DST], #2 ++ /* cleanup helper macro */ ++ .purgem scale_2_pixels ++ .unreq DST ++ .unreq SRC ++ .unreq W ++ .unreq VX ++ .unreq UNIT_X ++ .unreq TMP1 ++ .unreq TMP2 ++ .unreq MASK ++ /* return */ ++ pop {r4, r5, r6, r7} ++ bx lr ++.endfunc +diff --git a/pixman/pixman-arm-simd.c b/pixman/pixman-arm-simd.c +index d466a31..f6f464c 100644 +--- a/pixman/pixman-arm-simd.c ++++ b/pixman/pixman-arm-simd.c +@@ -29,6 +29,7 @@ + + #include "pixman-private.h" + #include "pixman-arm-common.h" ++#include "pixman-fast-path.h" + + #if 0 /* This code was moved to 'pixman-arm-simd-asm.S' */ + +@@ -375,6 +376,35 @@ pixman_composite_over_n_8_8888_asm_armv6 (int32_t width, + + #endif + ++void ++pixman_scaled_nearest_scanline_565_565_SRC_asm_armv6 (uint16_t * dst, ++ uint16_t * src, ++ int32_t w, ++ pixman_fixed_t vx, ++ pixman_fixed_t unit_x); ++ ++static force_inline void ++scaled_nearest_scanline_armv6_565_565_SRC (uint16_t * dst, ++ uint16_t * src, ++ int32_t w, ++ pixman_fixed_t vx, ++ pixman_fixed_t unit_x, ++ pixman_fixed_t max_vx) ++{ ++ pixman_scaled_nearest_scanline_565_565_SRC_asm_armv6 (dst, src, w, ++ vx, unit_x); ++} ++ ++FAST_NEAREST_MAINLOOP (armv6_565_565_cover_SRC, ++ scaled_nearest_scanline_armv6_565_565_SRC, ++ uint16_t, uint16_t, COVER); ++FAST_NEAREST_MAINLOOP (armv6_565_565_none_SRC, ++ scaled_nearest_scanline_armv6_565_565_SRC, ++ uint16_t, uint16_t, NONE); ++FAST_NEAREST_MAINLOOP (armv6_565_565_pad_SRC, ++ scaled_nearest_scanline_armv6_565_565_SRC, ++ uint16_t, uint16_t, PAD); ++ + PIXMAN_ARM_BIND_FAST_PATH_SRC_DST (armv6, add_8_8, + uint8_t, 1, uint8_t, 1) + PIXMAN_ARM_BIND_FAST_PATH_SRC_DST (armv6, over_8888_8888, +@@ -404,6 +434,13 @@ static const pixman_fast_path_t arm_simd_fast_paths[] = + PIXMAN_STD_FAST_PATH (OVER, solid, a8, a8b8g8r8, armv6_composite_over_n_8_8888), + PIXMAN_STD_FAST_PATH (OVER, solid, a8, x8b8g8r8, armv6_composite_over_n_8_8888), + ++ SIMPLE_NEAREST_FAST_PATH_COVER (SRC, r5g6b5, r5g6b5, armv6_565_565), ++ SIMPLE_NEAREST_FAST_PATH_COVER (SRC, b5g6r5, b5g6r5, armv6_565_565), ++ SIMPLE_NEAREST_FAST_PATH_NONE (SRC, r5g6b5, r5g6b5, armv6_565_565), ++ SIMPLE_NEAREST_FAST_PATH_NONE (SRC, b5g6r5, b5g6r5, armv6_565_565), ++ SIMPLE_NEAREST_FAST_PATH_PAD (SRC, r5g6b5, r5g6b5, armv6_565_565), ++ SIMPLE_NEAREST_FAST_PATH_PAD (SRC, b5g6r5, b5g6r5, armv6_565_565), ++ + { PIXMAN_OP_NONE }, + }; + +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0017-add-_pixman_bits_override_accessors.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0017-add-_pixman_bits_override_accessors.patch new file mode 100644 index 0000000000..b7983b2081 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0017-add-_pixman_bits_override_accessors.patch @@ -0,0 +1,75 @@ +From 6593d86679fde724e49efa96b16ca22d9521b288 Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Thu, 10 Dec 2009 00:51:50 +0200 +Subject: [PATCH 17/24] add _pixman_bits_override_accessors + +* from patch ARM: HACK: added NEON optimizations for fetch/store r5g6b5 scanline +* used in + 0005-ARM-added-NEON-optimizations-for-fetch-store-r5g6b5-.patch + 0006-ARM-added-NEON-optimizations-for-fetch-store-a8-scan.patch + 0007-ARM-added-NEON-optimizations-for-fetching-x8r8g8b8-s.patch +--- + pixman/pixman-access.c | 23 ++++++++++++++++++++++- + pixman/pixman-private.h | 5 +++++ + 2 files changed, 27 insertions(+), 1 deletions(-) + +diff --git a/pixman/pixman-access.c b/pixman/pixman-access.c +index f1ce0ba..b33da29 100644 +--- a/pixman/pixman-access.c ++++ b/pixman/pixman-access.c +@@ -2836,7 +2836,7 @@ typedef struct + store_scanline_ ## format, store_scanline_generic_64 \ + } + +-static const format_info_t accessors[] = ++static format_info_t accessors[] = + { + /* 32 bpp formats */ + FORMAT_INFO (a8r8g8b8), +@@ -2978,6 +2978,27 @@ _pixman_bits_image_setup_accessors (bits_image_t *image) + setup_accessors (image); + } + ++void ++_pixman_bits_override_accessors (pixman_format_code_t format, ++ fetch_scanline_t fetch_func, ++ store_scanline_t store_func) ++{ ++ format_info_t *info = accessors; ++ ++ while (info->format != PIXMAN_null) ++ { ++ if (info->format == format) ++ { ++ if (fetch_func) ++ info->fetch_scanline_32 = fetch_func; ++ if (store_func) ++ info->store_scanline_32 = store_func; ++ return; ++ } ++ info++; ++ } ++} ++ + #else + + void +diff --git a/pixman/pixman-private.h b/pixman/pixman-private.h +index 1662d2c..c0f9af4 100644 +--- a/pixman/pixman-private.h ++++ b/pixman/pixman-private.h +@@ -256,6 +256,11 @@ _pixman_conical_gradient_iter_init (pixman_image_t *image, + int x, int y, int width, int height, + uint8_t *buffer, iter_flags_t flags); + ++void ++_pixman_bits_override_accessors (pixman_format_code_t format, ++ fetch_scanline_t fetch_func, ++ store_scanline_t store_func); ++ + pixman_image_t * + _pixman_image_allocate (void); + +-- +1.7.4.rc2 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0018-Generic-C-implementation-of-pixman_blt-with-overlapp.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0018-Generic-C-implementation-of-pixman_blt-with-overlapp.patch new file mode 100644 index 0000000000..5b1c1089ed --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0018-Generic-C-implementation-of-pixman_blt-with-overlapp.patch @@ -0,0 +1,114 @@ +From 8e8b2809b505486001dc213becab0d50bfd96c1b Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Tue, 16 Mar 2010 16:55:28 +0100 +Subject: [PATCH 18/24] Generic C implementation of pixman_blt with overlapping support + +Uses memcpy/memmove functions to copy pixels, can handle the +case when both source and destination areas are in the same +image (this is useful for scrolling). + +It is assumed that copying direction is only important when +using the same image for both source and destination (and +src_stride == dst_stride). Copying direction is undefined +for the images with different source and destination stride +which happen to be in the overlapped areas (but this is an +unrealistic case anyway). +--- + pixman/pixman-general.c | 21 ++++++++++++++++++--- + pixman/pixman-private.h | 43 +++++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 61 insertions(+), 3 deletions(-) + +diff --git a/pixman/pixman-general.c b/pixman/pixman-general.c +index 4d234a0..c4d2c14 100644 +--- a/pixman/pixman-general.c ++++ b/pixman/pixman-general.c +@@ -280,9 +280,24 @@ general_blt (pixman_implementation_t *imp, + int width, + int height) + { +- /* We can't blit unless we have sse2 or mmx */ +- +- return FALSE; ++ uint8_t *dst_bytes = (uint8_t *)dst_bits; ++ uint8_t *src_bytes = (uint8_t *)src_bits; ++ int bpp; ++ ++ if (src_bpp != dst_bpp || src_bpp & 7) ++ return FALSE; ++ ++ bpp = src_bpp >> 3; ++ width *= bpp; ++ src_stride *= 4; ++ dst_stride *= 4; ++ pixman_blt_helper (src_bytes + src_y * src_stride + src_x * bpp, ++ dst_bytes + dst_y * dst_stride + dst_x * bpp, ++ src_stride, ++ dst_stride, ++ width, ++ height); ++ return TRUE; + } + + static pixman_bool_t +diff --git a/pixman/pixman-private.h b/pixman/pixman-private.h +index 969dfab..352bceb 100644 +--- a/pixman/pixman-private.h ++++ b/pixman/pixman-private.h +@@ -10,6 +10,7 @@ + + #include "pixman.h" + #include <time.h> ++#include <string.h> + #include <assert.h> + #include <stdio.h> + #include <string.h> +@@ -869,4 +870,46 @@ void pixman_timer_register (pixman_timer_t *timer); + + #endif /* PIXMAN_TIMERS */ + ++/* a helper function, can blit 8-bit images with src/dst overlapping support */ ++static inline void ++pixman_blt_helper (uint8_t *src_bytes, ++ uint8_t *dst_bytes, ++ int src_stride, ++ int dst_stride, ++ int width, ++ int height) ++{ ++ /* ++ * The second part of this check is not strictly needed, but it prevents ++ * unnecessary upside-down processing of areas which belong to different ++ * images. Upside-down processing can be slower with fixed-distance-ahead ++ * prefetch and perceived as having more tearing. ++ */ ++ if (src_bytes < dst_bytes + width && ++ src_bytes + src_stride * height > dst_bytes) ++ { ++ src_bytes += src_stride * height - src_stride; ++ dst_bytes += dst_stride * height - dst_stride; ++ dst_stride = -dst_stride; ++ src_stride = -src_stride; ++ /* Horizontal scrolling to the left needs memmove */ ++ if (src_bytes + width > dst_bytes) ++ { ++ while (--height >= 0) ++ { ++ memmove (dst_bytes, src_bytes, width); ++ dst_bytes += dst_stride; ++ src_bytes += src_stride; ++ } ++ return; ++ } ++ } ++ while (--height >= 0) ++ { ++ memcpy (dst_bytes, src_bytes, width); ++ dst_bytes += dst_stride; ++ src_bytes += src_stride; ++ } ++} ++ + #endif /* PIXMAN_PRIVATE_H */ +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0019-Support-of-overlapping-src-dst-for-pixman_blt_mmx.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0019-Support-of-overlapping-src-dst-for-pixman_blt_mmx.patch new file mode 100644 index 0000000000..5193d38f74 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0019-Support-of-overlapping-src-dst-for-pixman_blt_mmx.patch @@ -0,0 +1,91 @@ +From f5a54f7d5eb1169bc79f0e445e2998e98080ef13 Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Thu, 22 Oct 2009 05:45:47 +0300 +Subject: [PATCH 19/24] Support of overlapping src/dst for pixman_blt_mmx + +--- + pixman/pixman-mmx.c | 55 +++++++++++++++++++++++++++++--------------------- + 1 files changed, 32 insertions(+), 23 deletions(-) + +diff --git a/pixman/pixman-mmx.c b/pixman/pixman-mmx.c +index 34637a4..f9dd473 100644 +--- a/pixman/pixman-mmx.c ++++ b/pixman/pixman-mmx.c +@@ -2996,34 +2996,43 @@ pixman_blt_mmx (uint32_t *src_bits, + { + uint8_t * src_bytes; + uint8_t * dst_bytes; +- int byte_width; ++ int bpp; + +- if (src_bpp != dst_bpp) ++ if (src_bpp != dst_bpp || src_bpp & 7) + return FALSE; + +- if (src_bpp == 16) +- { +- src_stride = src_stride * (int) sizeof (uint32_t) / 2; +- dst_stride = dst_stride * (int) sizeof (uint32_t) / 2; +- src_bytes = (uint8_t *)(((uint16_t *)src_bits) + src_stride * (src_y) + (src_x)); +- dst_bytes = (uint8_t *)(((uint16_t *)dst_bits) + dst_stride * (dst_y) + (dst_x)); +- byte_width = 2 * width; +- src_stride *= 2; +- dst_stride *= 2; +- } +- else if (src_bpp == 32) ++ bpp = src_bpp >> 3; ++ width *= bpp; ++ src_stride *= 4; ++ dst_stride *= 4; ++ src_bytes = (uint8_t *)src_bits + src_y * src_stride + src_x * bpp; ++ dst_bytes = (uint8_t *)dst_bits + dst_y * dst_stride + dst_x * bpp; ++ ++ if (src_bpp != 16 && src_bpp != 32) + { +- src_stride = src_stride * (int) sizeof (uint32_t) / 4; +- dst_stride = dst_stride * (int) sizeof (uint32_t) / 4; +- src_bytes = (uint8_t *)(((uint32_t *)src_bits) + src_stride * (src_y) + (src_x)); +- dst_bytes = (uint8_t *)(((uint32_t *)dst_bits) + dst_stride * (dst_y) + (dst_x)); +- byte_width = 4 * width; +- src_stride *= 4; +- dst_stride *= 4; ++ pixman_blt_helper (src_bytes, dst_bytes, src_stride, dst_stride, ++ width, height); ++ return TRUE; + } +- else ++ ++ if (src_bytes < dst_bytes && src_bytes + src_stride * height > dst_bytes) + { +- return FALSE; ++ src_bytes += src_stride * height - src_stride; ++ dst_bytes += dst_stride * height - dst_stride; ++ dst_stride = -dst_stride; ++ src_stride = -src_stride; ++ ++ if (src_bytes + width > dst_bytes) ++ { ++ /* TODO: reverse scanline copy using MMX */ ++ while (--height >= 0) ++ { ++ memmove (dst_bytes, src_bytes, width); ++ dst_bytes += dst_stride; ++ src_bytes += src_stride; ++ } ++ return TRUE; ++ } + } + + while (height--) +@@ -3033,7 +3042,7 @@ pixman_blt_mmx (uint32_t *src_bits, + uint8_t *d = dst_bytes; + src_bytes += src_stride; + dst_bytes += dst_stride; +- w = byte_width; ++ w = width; + + while (w >= 2 && ((unsigned long)d & 3)) + { +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0020-Support-of-overlapping-src-dst-for-pixman_blt_sse2.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0020-Support-of-overlapping-src-dst-for-pixman_blt_sse2.patch new file mode 100644 index 0000000000..f5c0e12f24 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0020-Support-of-overlapping-src-dst-for-pixman_blt_sse2.patch @@ -0,0 +1,91 @@ +From c8755294fa9ea396f7113370230b17c424a93be1 Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Thu, 22 Oct 2009 05:45:54 +0300 +Subject: [PATCH 20/24] Support of overlapping src/dst for pixman_blt_sse2 + +--- + pixman/pixman-sse2.c | 55 +++++++++++++++++++++++++++++-------------------- + 1 files changed, 32 insertions(+), 23 deletions(-) + +diff --git a/pixman/pixman-sse2.c b/pixman/pixman-sse2.c +index 5907de0..25015ae 100644 +--- a/pixman/pixman-sse2.c ++++ b/pixman/pixman-sse2.c +@@ -5027,34 +5027,43 @@ pixman_blt_sse2 (uint32_t *src_bits, + { + uint8_t * src_bytes; + uint8_t * dst_bytes; +- int byte_width; ++ int bpp; + +- if (src_bpp != dst_bpp) ++ if (src_bpp != dst_bpp || src_bpp & 7) + return FALSE; + +- if (src_bpp == 16) +- { +- src_stride = src_stride * (int) sizeof (uint32_t) / 2; +- dst_stride = dst_stride * (int) sizeof (uint32_t) / 2; +- src_bytes =(uint8_t *)(((uint16_t *)src_bits) + src_stride * (src_y) + (src_x)); +- dst_bytes = (uint8_t *)(((uint16_t *)dst_bits) + dst_stride * (dst_y) + (dst_x)); +- byte_width = 2 * width; +- src_stride *= 2; +- dst_stride *= 2; +- } +- else if (src_bpp == 32) ++ bpp = src_bpp >> 3; ++ width *= bpp; ++ src_stride *= 4; ++ dst_stride *= 4; ++ src_bytes = (uint8_t *)src_bits + src_y * src_stride + src_x * bpp; ++ dst_bytes = (uint8_t *)dst_bits + dst_y * dst_stride + dst_x * bpp; ++ ++ if (src_bpp != 16 && src_bpp != 32) + { +- src_stride = src_stride * (int) sizeof (uint32_t) / 4; +- dst_stride = dst_stride * (int) sizeof (uint32_t) / 4; +- src_bytes = (uint8_t *)(((uint32_t *)src_bits) + src_stride * (src_y) + (src_x)); +- dst_bytes = (uint8_t *)(((uint32_t *)dst_bits) + dst_stride * (dst_y) + (dst_x)); +- byte_width = 4 * width; +- src_stride *= 4; +- dst_stride *= 4; ++ pixman_blt_helper (src_bytes, dst_bytes, src_stride, dst_stride, ++ width, height); ++ return TRUE; + } +- else ++ ++ if (src_bytes < dst_bytes && src_bytes + src_stride * height > dst_bytes) + { +- return FALSE; ++ src_bytes += src_stride * height - src_stride; ++ dst_bytes += dst_stride * height - dst_stride; ++ dst_stride = -dst_stride; ++ src_stride = -src_stride; ++ ++ if (src_bytes + width > dst_bytes) ++ { ++ /* TODO: reverse scanline copy using SSE2 */ ++ while (--height >= 0) ++ { ++ memmove (dst_bytes, src_bytes, width); ++ dst_bytes += dst_stride; ++ src_bytes += src_stride; ++ } ++ return TRUE; ++ } + } + + while (height--) +@@ -5064,7 +5073,7 @@ pixman_blt_sse2 (uint32_t *src_bits, + uint8_t *d = dst_bytes; + src_bytes += src_stride; + dst_bytes += dst_stride; +- w = byte_width; ++ w = width; + + while (w >= 2 && ((unsigned long)d & 3)) + { +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0021-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0021-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch new file mode 100644 index 0000000000..0eb9d88eba --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0021-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch @@ -0,0 +1,94 @@ +From 86c8198598ef6d639e656c04644015795cc249aa Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Wed, 18 Nov 2009 06:08:48 +0200 +Subject: [PATCH 21/24] Support of overlapping src/dst for pixman_blt_neon + +--- + pixman/pixman-arm-neon.c | 62 +++++++++++++++++++++++++++++++++++++-------- + 1 files changed, 51 insertions(+), 11 deletions(-) + +diff --git a/pixman/pixman-arm-neon.c b/pixman/pixman-arm-neon.c +index e3eca2b..74316a8 100644 +--- a/pixman/pixman-arm-neon.c ++++ b/pixman/pixman-arm-neon.c +@@ -199,26 +199,66 @@ pixman_blt_neon (uint32_t *src_bits, + int width, + int height) + { +- if (src_bpp != dst_bpp) ++ uint8_t * src_bytes; ++ uint8_t * dst_bytes; ++ int bpp; ++ ++ if (src_bpp != dst_bpp || src_bpp & 7) + return FALSE; + ++ bpp = src_bpp >> 3; ++ width *= bpp; ++ src_stride *= 4; ++ dst_stride *= 4; ++ src_bytes = (uint8_t *)src_bits + src_y * src_stride + src_x * bpp; ++ dst_bytes = (uint8_t *)dst_bits + dst_y * dst_stride + dst_x * bpp; ++ ++ if (src_bpp != 16 && src_bpp != 32) ++ { ++ pixman_blt_helper (src_bytes, dst_bytes, src_stride, dst_stride, ++ width, height); ++ return TRUE; ++ } ++ ++ if (src_bytes < dst_bytes && src_bytes + src_stride * height > dst_bytes) ++ { ++ src_bytes += src_stride * height - src_stride; ++ dst_bytes += dst_stride * height - dst_stride; ++ dst_stride = -dst_stride; ++ src_stride = -src_stride; ++ ++ if (src_bytes + width > dst_bytes) ++ { ++ /* TODO: reverse scanline copy using NEON */ ++ while (--height >= 0) ++ { ++ memmove (dst_bytes, src_bytes, width); ++ dst_bytes += dst_stride; ++ src_bytes += src_stride; ++ } ++ return TRUE; ++ } ++ } ++ + switch (src_bpp) + { + case 16: + pixman_composite_src_0565_0565_asm_neon ( +- width, height, +- (uint16_t *)(((char *) dst_bits) + +- dst_y * dst_stride * 4 + dst_x * 2), dst_stride * 2, +- (uint16_t *)(((char *) src_bits) + +- src_y * src_stride * 4 + src_x * 2), src_stride * 2); ++ width >> 1, ++ height, ++ (uint16_t *) dst_bytes, ++ dst_stride >> 1, ++ (uint16_t *) src_bytes, ++ src_stride >> 1); + return TRUE; + case 32: + pixman_composite_src_8888_8888_asm_neon ( +- width, height, +- (uint32_t *)(((char *) dst_bits) + +- dst_y * dst_stride * 4 + dst_x * 4), dst_stride, +- (uint32_t *)(((char *) src_bits) + +- src_y * src_stride * 4 + src_x * 4), src_stride); ++ width >> 2, ++ height, ++ (uint32_t *) dst_bytes, ++ dst_stride >> 2, ++ (uint32_t *) src_bytes, ++ src_stride >> 2); + return TRUE; + default: + return FALSE; +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0022-ARM-added-NEON-optimizations-for-fetch-store-r5g6b5-.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0022-ARM-added-NEON-optimizations-for-fetch-store-r5g6b5-.patch new file mode 100644 index 0000000000..129c1f1bb6 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0022-ARM-added-NEON-optimizations-for-fetch-store-r5g6b5-.patch @@ -0,0 +1,109 @@ +From 60d972afbae8613d700d3a6b3cb107429d7e11c6 Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Thu, 10 Dec 2009 00:51:50 +0200 +Subject: [PATCH 22/24] ARM: added NEON optimizations for fetch/store r5g6b5 scanline + +--- + pixman/pixman-arm-neon-asm.S | 20 ++++++++++++++++++++ + pixman/pixman-arm-neon.c | 40 ++++++++++++++++++++++++++++++++++++++++ + 2 files changed, 60 insertions(+), 0 deletions(-) + +diff --git a/pixman/pixman-arm-neon-asm.S b/pixman/pixman-arm-neon-asm.S +index cf014fa..25f7bf0 100644 +--- a/pixman/pixman-arm-neon-asm.S ++++ b/pixman/pixman-arm-neon-asm.S +@@ -459,6 +459,16 @@ generate_composite_function \ + pixman_composite_src_8888_0565_process_pixblock_tail, \ + pixman_composite_src_8888_0565_process_pixblock_tail_head + ++generate_composite_function_single_scanline \ ++ pixman_store_scanline_r5g6b5_asm_neon, 32, 0, 16, \ ++ FLAG_DST_WRITEONLY | FLAG_DEINTERLEAVE_32BPP, \ ++ 8, /* number of pixels, processed in a single block */ \ ++ default_init, \ ++ default_cleanup, \ ++ pixman_composite_src_8888_0565_process_pixblock_head, \ ++ pixman_composite_src_8888_0565_process_pixblock_tail, \ ++ pixman_composite_src_8888_0565_process_pixblock_tail_head ++ + /******************************************************************************/ + + .macro pixman_composite_src_0565_8888_process_pixblock_head +@@ -494,6 +504,16 @@ generate_composite_function \ + pixman_composite_src_0565_8888_process_pixblock_tail, \ + pixman_composite_src_0565_8888_process_pixblock_tail_head + ++generate_composite_function_single_scanline \ ++ pixman_fetch_scanline_r5g6b5_asm_neon, 16, 0, 32, \ ++ FLAG_DST_WRITEONLY | FLAG_DEINTERLEAVE_32BPP, \ ++ 8, /* number of pixels, processed in a single block */ \ ++ default_init, \ ++ default_cleanup, \ ++ pixman_composite_src_0565_8888_process_pixblock_head, \ ++ pixman_composite_src_0565_8888_process_pixblock_tail, \ ++ pixman_composite_src_0565_8888_process_pixblock_tail_head ++ + /******************************************************************************/ + + .macro pixman_composite_add_8_8_process_pixblock_head +diff --git a/pixman/pixman-arm-neon.c b/pixman/pixman-arm-neon.c +index 74316a8..f773e92 100644 +--- a/pixman/pixman-arm-neon.c ++++ b/pixman/pixman-arm-neon.c +@@ -448,6 +448,42 @@ BIND_COMBINE_U (over) + BIND_COMBINE_U (add) + BIND_COMBINE_U (out_reverse) + ++void ++pixman_fetch_scanline_r5g6b5_asm_neon (int width, ++ uint32_t *buffer, ++ const uint16_t *pixel); ++void ++pixman_store_scanline_r5g6b5_asm_neon (int width, ++ uint16_t *pixel, ++ const uint32_t *values); ++ ++static void ++neon_fetch_scanline_r5g6b5 (pixman_image_t *image, ++ int x, ++ int y, ++ int width, ++ uint32_t * buffer, ++ const uint32_t *mask) ++{ ++ const uint32_t *bits = image->bits.bits + y * image->bits.rowstride; ++ const uint16_t *pixel = (const uint16_t *)bits + x; ++ ++ pixman_fetch_scanline_r5g6b5_asm_neon (width, buffer, pixel); ++} ++ ++static void ++neon_store_scanline_r5g6b5 (bits_image_t * image, ++ int x, ++ int y, ++ int width, ++ const uint32_t *values) ++{ ++ uint32_t *bits = image->bits + image->rowstride * y; ++ uint16_t *pixel = ((uint16_t *) bits) + x; ++ ++ pixman_store_scanline_r5g6b5_asm_neon (width, pixel, values); ++} ++ + pixman_implementation_t * + _pixman_implementation_create_arm_neon (void) + { +@@ -463,6 +499,10 @@ _pixman_implementation_create_arm_neon (void) + imp->combine_32[PIXMAN_OP_ADD] = neon_combine_add_u; + imp->combine_32[PIXMAN_OP_OUT_REVERSE] = neon_combine_out_reverse_u; + ++ _pixman_bits_override_accessors (PIXMAN_r5g6b5, ++ neon_fetch_scanline_r5g6b5, ++ neon_store_scanline_r5g6b5); ++ + imp->blt = arm_neon_blt; + imp->fill = arm_neon_fill; + +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0023-ARM-added-NEON-optimizations-for-fetch-store-a8-scan.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0023-ARM-added-NEON-optimizations-for-fetch-store-a8-scan.patch new file mode 100644 index 0000000000..7724f5433e --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0023-ARM-added-NEON-optimizations-for-fetch-store-a8-scan.patch @@ -0,0 +1,148 @@ +From cc99d8d6fcbabd7f9f3ed99e65c78a2fb71792fa Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Thu, 23 Sep 2010 21:10:56 +0300 +Subject: [PATCH 23/24] ARM: added NEON optimizations for fetch/store a8 scanline + +--- + pixman/pixman-arm-neon-asm.S | 64 ++++++++++++++++++++++++++++++++++++++++++ + pixman/pixman-arm-neon.c | 42 +++++++++++++++++++++++++++ + 2 files changed, 106 insertions(+), 0 deletions(-) + +diff --git a/pixman/pixman-arm-neon-asm.S b/pixman/pixman-arm-neon-asm.S +index 25f7bf0..439b06b 100644 +--- a/pixman/pixman-arm-neon-asm.S ++++ b/pixman/pixman-arm-neon-asm.S +@@ -418,6 +418,70 @@ generate_composite_function \ + + /******************************************************************************/ + ++.macro pixman_composite_src_8_8888_process_pixblock_head ++ /* This is tricky part: we can't set these values just once in 'init' macro ++ * because leading/trailing pixels handling part uses VZIP.8 instructions, ++ * and they operate on values in-place and destroy original registers ++ * content. Think about it like VST4.8 instruction corrupting NEON ++ * registers after write in 'tail_head' macro. Except that 'tail_head' ++ * macro itself actually does not need these extra VMOVs because it uses ++ * real VST4.8 instruction. ++ */ ++ vmov.u8 q0, #0 ++ vmov.u8 d2, #0 ++.endm ++ ++.macro pixman_composite_src_8_8888_process_pixblock_tail ++.endm ++ ++.macro pixman_composite_src_8_8888_process_pixblock_tail_head ++ vst4.8 {d0, d1, d2, d3}, [DST_W, :128]! ++ vld1.8 {d3}, [SRC]! ++.endm ++ ++generate_composite_function_single_scanline \ ++ pixman_fetch_scanline_a8_asm_neon, 8, 0, 32, \ ++ FLAG_DST_WRITEONLY | FLAG_DEINTERLEAVE_32BPP, \ ++ 8, /* number of pixels, processed in a single block */ \ ++ default_init, \ ++ default_cleanup, \ ++ pixman_composite_src_8_8888_process_pixblock_head, \ ++ pixman_composite_src_8_8888_process_pixblock_tail, \ ++ pixman_composite_src_8_8888_process_pixblock_tail_head, \ ++ 0, /* dst_w_basereg */ \ ++ 0, /* dst_r_basereg */ \ ++ 3, /* src_basereg */ \ ++ 0 /* mask_basereg */ ++ ++/******************************************************************************/ ++ ++.macro pixman_composite_src_8888_8_process_pixblock_head ++.endm ++ ++.macro pixman_composite_src_8888_8_process_pixblock_tail ++.endm ++ ++.macro pixman_composite_src_8888_8_process_pixblock_tail_head ++ vst1.8 {d3}, [DST_W, :64]! ++ vld4.8 {d0, d1, d2, d3}, [SRC]! ++.endm ++ ++generate_composite_function_single_scanline \ ++ pixman_store_scanline_a8_asm_neon, 32, 0, 8, \ ++ FLAG_DST_WRITEONLY | FLAG_DEINTERLEAVE_32BPP, \ ++ 8, /* number of pixels, processed in a single block */ \ ++ default_init, \ ++ default_cleanup, \ ++ pixman_composite_src_8888_8_process_pixblock_head, \ ++ pixman_composite_src_8888_8_process_pixblock_tail, \ ++ pixman_composite_src_8888_8_process_pixblock_tail_head, \ ++ 3, /* dst_w_basereg */ \ ++ 0, /* dst_r_basereg */ \ ++ 0, /* src_basereg */ \ ++ 0 /* mask_basereg */ ++ ++/******************************************************************************/ ++ + .macro pixman_composite_src_8888_0565_process_pixblock_head + vshll.u8 q8, d1, #8 + vshll.u8 q14, d2, #8 +diff --git a/pixman/pixman-arm-neon.c b/pixman/pixman-arm-neon.c +index f773e92..55219b3 100644 +--- a/pixman/pixman-arm-neon.c ++++ b/pixman/pixman-arm-neon.c +@@ -484,6 +484,45 @@ neon_store_scanline_r5g6b5 (bits_image_t * image, + pixman_store_scanline_r5g6b5_asm_neon (width, pixel, values); + } + ++void ++pixman_fetch_scanline_a8_asm_neon (int width, ++ uint32_t *buffer, ++ const uint8_t *pixel); ++ ++ ++void ++pixman_store_scanline_a8_asm_neon (int width, ++ uint8_t *pixel, ++ const uint32_t *values); ++ ++static void ++neon_fetch_scanline_a8 (pixman_image_t *image, ++ int x, ++ int y, ++ int width, ++ uint32_t * buffer, ++ const uint32_t *mask) ++{ ++ const uint32_t *bits = image->bits.bits + y * image->bits.rowstride; ++ const uint8_t *pixel = (const uint8_t *) bits + x; ++ ++ pixman_fetch_scanline_a8_asm_neon (width, buffer, pixel); ++} ++ ++static void ++neon_store_scanline_a8 (bits_image_t * image, ++ int x, ++ int y, ++ int width, ++ const uint32_t *values) ++{ ++ uint32_t *bits = image->bits + image->rowstride * y; ++ uint8_t *pixel = (uint8_t *) bits + x; ++ ++ pixman_store_scanline_a8_asm_neon (width, pixel, values); ++} ++ ++ + pixman_implementation_t * + _pixman_implementation_create_arm_neon (void) + { +@@ -502,6 +541,9 @@ _pixman_implementation_create_arm_neon (void) + _pixman_bits_override_accessors (PIXMAN_r5g6b5, + neon_fetch_scanline_r5g6b5, + neon_store_scanline_r5g6b5); ++ _pixman_bits_override_accessors (PIXMAN_a8, ++ neon_fetch_scanline_a8, ++ neon_store_scanline_a8); + + imp->blt = arm_neon_blt; + imp->fill = arm_neon_fill; +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0024-ARM-added-NEON-optimizations-for-fetching-x8r8g8b8-s.patch b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0024-ARM-added-NEON-optimizations-for-fetching-x8r8g8b8-s.patch new file mode 100644 index 0000000000..8253f41b8f --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman-0.21.4/0024-ARM-added-NEON-optimizations-for-fetching-x8r8g8b8-s.patch @@ -0,0 +1,77 @@ +From cf3b8fdc53144ff62c4054996559d3a1a4d62b75 Mon Sep 17 00:00:00 2001 +From: Siarhei Siamashka <siarhei.siamashka@nokia.com> +Date: Fri, 24 Sep 2010 18:22:44 +0300 +Subject: [PATCH 24/24] ARM: added NEON optimizations for fetching x8r8g8b8 scanline + +--- + pixman/pixman-arm-neon-asm.S | 14 ++++++++++++++ + pixman/pixman-arm-neon.c | 21 +++++++++++++++++++++ + 2 files changed, 35 insertions(+), 0 deletions(-) + +diff --git a/pixman/pixman-arm-neon-asm.S b/pixman/pixman-arm-neon-asm.S +index 439b06b..3e0dcfe 100644 +--- a/pixman/pixman-arm-neon-asm.S ++++ b/pixman/pixman-arm-neon-asm.S +@@ -1257,6 +1257,20 @@ generate_composite_function \ + 0, /* src_basereg */ \ + 0 /* mask_basereg */ + ++generate_composite_function_single_scanline \ ++ pixman_fetch_scanline_x888_asm_neon, 32, 0, 32, \ ++ FLAG_DST_WRITEONLY, \ ++ 8, /* number of pixels, processed in a single block */ \ ++ pixman_composite_src_x888_8888_init, \ ++ default_cleanup, \ ++ pixman_composite_src_x888_8888_process_pixblock_head, \ ++ pixman_composite_src_x888_8888_process_pixblock_tail, \ ++ pixman_composite_src_x888_8888_process_pixblock_tail_head, \ ++ 0, /* dst_w_basereg */ \ ++ 0, /* dst_r_basereg */ \ ++ 0, /* src_basereg */ \ ++ 0 /* mask_basereg */ ++ + /******************************************************************************/ + + .macro pixman_composite_over_n_8_8888_process_pixblock_head +diff --git a/pixman/pixman-arm-neon.c b/pixman/pixman-arm-neon.c +index 55219b3..8cef414 100644 +--- a/pixman/pixman-arm-neon.c ++++ b/pixman/pixman-arm-neon.c +@@ -522,6 +522,24 @@ neon_store_scanline_a8 (bits_image_t * image, + pixman_store_scanline_a8_asm_neon (width, pixel, values); + } + ++void ++pixman_fetch_scanline_x888_asm_neon (int width, ++ uint32_t *buffer, ++ const uint32_t *pixel); ++ ++static void ++neon_fetch_scanline_x888 (pixman_image_t *image, ++ int x, ++ int y, ++ int width, ++ uint32_t * buffer, ++ const uint32_t *mask) ++{ ++ const uint32_t *bits = image->bits.bits + y * image->bits.rowstride; ++ const uint32_t *pixel = (const uint32_t *) bits + x; ++ ++ pixman_fetch_scanline_x888_asm_neon (width, buffer, pixel); ++} + + pixman_implementation_t * + _pixman_implementation_create_arm_neon (void) +@@ -544,6 +562,9 @@ _pixman_implementation_create_arm_neon (void) + _pixman_bits_override_accessors (PIXMAN_a8, + neon_fetch_scanline_a8, + neon_store_scanline_a8); ++ _pixman_bits_override_accessors (PIXMAN_x8r8g8b8, ++ neon_fetch_scanline_x888, ++ NULL); + + imp->blt = arm_neon_blt; + imp->fill = arm_neon_fill; +-- +1.6.6.1 + diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman.inc b/meta-oe/recipes-graphics/xorg-lib/pixman.inc new file mode 100644 index 0000000000..539a33a888 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman.inc @@ -0,0 +1,14 @@ +SECTION = "libs" +PRIORITY = "optional" +DESCRIPTION = "Low-level pixel manipulation library." +LICENSE = "X11" + +DEPENDS = "perl-native" + +BBCLASSEXTEND = "native" + +SRC_URI = "http://cairographics.org/releases/${BPN}-${PV}.tar.gz;name=archive " + +INC_PR = "r5" + +inherit autotools pkgconfig diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman_0.20.0.bb b/meta-oe/recipes-graphics/xorg-lib/pixman_0.20.0.bb new file mode 100644 index 0000000000..b3fbd4f155 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman_0.20.0.bb @@ -0,0 +1,23 @@ +require pixman.inc + +SRC_URI[archive.md5sum] = "c1a31d5cedfa97c5af7148a2d1fd4356" +SRC_URI[archive.sha256sum] = "9c02c22c6cc3f28f3633d02ef6f0cac130518f621edb011ebbbf08cd1a81251a" + +PR = "${INC_PR}.0" + +SRC_URI += "\ + file://0000-Add-pixman_bits_override_accessors.patch \ + file://0001-Generic-C-implementation-of-pixman_blt-with-overlapp.patch \ + file://0002-Support-of-overlapping-src-dst-for-pixman_blt_mmx.patch \ + file://0003-Support-of-overlapping-src-dst-for-pixman_blt_sse2.patch \ + file://0004-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch \ + file://0005-ARM-added-NEON-optimizations-for-fetch-store-r5g6b5-.patch \ + file://0006-ARM-added-NEON-optimizations-for-fetch-store-a8-scan.patch \ + file://0007-ARM-added-NEON-optimizations-for-fetching-x8r8g8b8-s.patch \ + file://0008-ARM-optimization-for-scaled-src_0565_0565-operation-.patch \ +" + +NEON = " --disable-arm-neon " +NEON_armv7a = " " + +EXTRA_OECONF = "${NEON} --disable-gtk" diff --git a/meta-oe/recipes-graphics/xorg-lib/pixman_0.21.4.bb b/meta-oe/recipes-graphics/xorg-lib/pixman_0.21.4.bb new file mode 100644 index 0000000000..f0e9e388b1 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/pixman_0.21.4.bb @@ -0,0 +1,28 @@ +require pixman.inc + +SRC_URI[archive.md5sum] = "e50975ace979cd416a505827c15191b4" +SRC_URI[archive.sha256sum] = "57783330ee2f96121dc267b7f25b98356fd09fe9de185cd39e72e906b6444013" + +LICENSE = "MIT & MIT-style & Public Domain" +LIC_FILES_CHKSUM = "file://COPYING;md5=14096c769ae0cbb5fcb94ec468be11b3\ + file://pixman/pixman-matrix.c;endline=25;md5=ba6e8769bfaaee2c41698755af04c4be \ + file://pixman/pixman-arm-neon-asm.h;endline=24;md5=9a9cc1e51abbf1da58f4d9528ec9d49b \ + file://pixman/pixman-x64-mmx-emulation.h;beginline=4;endline=9;md5=4e32716f2efaa6c4659222667c339bb8" + +PR = "${INC_PR}.0" + +SRC_URI += "\ + file://0017-add-_pixman_bits_override_accessors.patch \ + file://0018-Generic-C-implementation-of-pixman_blt-with-overlapp.patch \ + file://0019-Support-of-overlapping-src-dst-for-pixman_blt_mmx.patch \ + file://0020-Support-of-overlapping-src-dst-for-pixman_blt_sse2.patch \ + file://0021-Support-of-overlapping-src-dst-for-pixman_blt_neon.patch \ + file://0022-ARM-added-NEON-optimizations-for-fetch-store-r5g6b5-.patch \ + file://0023-ARM-added-NEON-optimizations-for-fetch-store-a8-scan.patch \ + file://0024-ARM-added-NEON-optimizations-for-fetching-x8r8g8b8-s.patch \ +" + +NEON = " --disable-arm-neon " +NEON_armv7a = " " + +EXTRA_OECONF = "${NEON} --disable-gtk" diff --git a/meta-oe/recipes-graphics/xorg-lib/xorg-lib-common.inc b/meta-oe/recipes-graphics/xorg-lib/xorg-lib-common.inc new file mode 100644 index 0000000000..93212c591f --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-lib/xorg-lib-common.inc @@ -0,0 +1,19 @@ +HOMEPAGE = "http://www.x.org" +BUGTRACKER = "https://bugs.freedesktop.org/enter_bug.cgi?product=xorg" + +SECTION = "x11/libs" +LICENSE = "MIT-X" +DEPENDS = "util-macros" + +XORG_PN = "${BPN}" +INC_PR = "r9" + +SRC_URI = "${XORG_MIRROR}/individual/lib/${XORG_PN}-${PV}.tar.bz2" + +S = "${WORKDIR}/${XORG_PN}-${PV}" + +inherit autotools pkgconfig + +EXTRA_OECONF = "--enable-malloc0returnsnull" + +BBCLASSEXTEND = "native nativesdk" diff --git a/meta-oe/recipes-graphics/xorg-proto/renderproto_0.11.1.bb b/meta-oe/recipes-graphics/xorg-proto/renderproto_0.11.1.bb new file mode 100644 index 0000000000..7e3844847a --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-proto/renderproto_0.11.1.bb @@ -0,0 +1,15 @@ +require xorg-proto-common.inc + +LICENSE = "MIT-style" +LIC_FILES_CHKSUM = "file://COPYING;md5=f826d99765196352e6122a406cf0d024 \ + file://renderproto.h;beginline=4;endline=24;md5=3e5e2851dad240b0a3a27c4776b4fd1f" + +CONFLICTS = "renderext" +PR = "r0" +PE = "1" + +BBCLASSEXTEND = "native nativesdk" + +SRC_URI[md5sum] = "a914ccc1de66ddeb4b611c6b0686e274" +SRC_URI[sha256sum] = "06735a5b92b20759204e4751ecd6064a2ad8a6246bb65b3078b862a00def2537" + diff --git a/meta-oe/recipes-graphics/xorg-proto/xorg-proto-common.inc b/meta-oe/recipes-graphics/xorg-proto/xorg-proto-common.inc new file mode 100644 index 0000000000..3e7c701c79 --- /dev/null +++ b/meta-oe/recipes-graphics/xorg-proto/xorg-proto-common.inc @@ -0,0 +1,17 @@ +DESCRIPTION = "X protocol headers: ${BPN}" +HOMEPAGE = "http://www.x.org" +SECTION = "x11/libs" +LICENSE = "MIT-X" + +DEPENDS = "util-macros" + +ALLOW_EMPTY = "1" + +INC_PR = "r2" + +SRC_URI = "${XORG_MIRROR}/individual/proto/${BPN}-${PV}.tar.bz2;name=archive" + +S = "${WORKDIR}/${BPN}-${PV}" + +inherit autotools pkgconfig + |