[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] [SCM] Gnash branch, openvg, updated. 155611ce1b08eaf73311
From: |
Rob Savoye |
Subject: |
[Gnash-commit] [SCM] Gnash branch, openvg, updated. 155611ce1b08eaf733112743baa5256eeb5a2be2 |
Date: |
Sat, 18 Dec 2010 05:03:30 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Gnash".
The branch, openvg has been updated
via 155611ce1b08eaf733112743baa5256eeb5a2be2 (commit)
via 9bf68d5d761fd064456952078ec7fb2108788ab9 (commit)
via 678490531711a7395de2fba2f01900e724e92413 (commit)
via d2050a59c01522ed55954a7637057544511a58e1 (commit)
via 8a59f7c269dae70e7b860a8fdeffc38082cd0b69 (commit)
via 7f1495a82f2be911556711cd0aaeb70358814eda (commit)
via 97f6df2212de072616155705b263d8298bec9a42 (commit)
from a22b5e0a78c4222ce93573f09ccde06cad9b6adc (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit//commit/?id=155611ce1b08eaf733112743baa5256eeb5a2be2
commit 155611ce1b08eaf733112743baa5256eeb5a2be2
Author: Rob Savoye <address@hidden>
Date: Fri Dec 17 21:45:25 2010 -0700
tweak x11 device config
diff --git a/configure.ac b/configure.ac
index 6c4e199..7098b34 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1107,11 +1107,11 @@ dnl instead of the OGL (OpenGL) one.
build_vaapi_device=no
build_openmax_device=no
build_directfb_device=no
-build_x11_device=no
+build_x11_device=yes
build_egl_device=yes
build_rawfb_device=yes
-device_list="EGL RawFB"
-ndevice=2
+device_list="EGL RawFB X11"
+ndevice=3
AC_ARG_ENABLE(device,
AC_HELP_STRING([--enable-device], [Specify which hardware abstraction to use
to support to enable (none,openmax,egl,directfb,rawfb,x11,vaapi)]),
if test -z ${enableval}; then
@@ -1157,9 +1157,9 @@ AC_ARG_ENABLE(device,
ndevice=$((ndevice+1))
;;
all|ALL)
- device_list="OpenMax EGL DirectFB X11 VAAPI"
- build_openmax_device=yes
- build_vaapi_device=yes
+ device_list="EGL DirectFB X11"
+ build_openmax_device=no
+ build_vaapi_device=no
build_egl_device=yes
build_rawfb_device=yes
build_directfb_device=yes
@@ -1984,7 +1984,7 @@ GNASH_PATH_X11
AC_CHECK_LIB(Xi, XInput_find_display)
AC_CHECK_LIB(X11, XDisableAccessControl)
dnl fi
-AM_CONDITIONAL(HAVE_X11, [test x$has_x11 = xyes])
+AM_CONDITIONAL(HAVE_X11, [test x$has_x11x = xyes])
if test x$has_x11 = xyes; then
AC_DEFINE(BUILD_X11_DEVICE, [1], [Build the X11 device])
fi
@@ -2465,7 +2465,7 @@ AM_CONDITIONAL(BUILD_VAAPI_DEVICE, [test x"${use_libva}"
= xyes])
AM_CONDITIONAL(BUILD_EGL_DEVICE, [test x"${build_egl_device}" = xyes])
AM_CONDITIONAL(BUILD_DIRECTFB_DEVICE, [ test x${build_directfb_device} = xyes])
AM_CONDITIONAL(BUILD_RAWFB_DEVICE, [ test x${build_rawfb_device} = xyes])
-AM_CONDITIONAL(BUILD_X11_DEVICE, [test x$build_x11_device = xyes])
+AM_CONDITIONAL(BUILD_X11_DEVICE, [test x${build_x11_device} = xyes])
if test x"${build_ovg}" = xyes; then
GNASH_PATH_OPENVG
http://git.savannah.gnu.org/cgit//commit/?id=9bf68d5d761fd064456952078ec7fb2108788ab9
commit 9bf68d5d761fd064456952078ec7fb2108788ab9
Author: Rob Savoye <address@hidden>
Date: Fri Dec 17 21:21:00 2010 -0700
fix OPENVG_CFLAGS for the two version, 1.0.1 with libMesa, 1.1.2 with ltib.
diff --git a/macros/openvg.m4 b/macros/openvg.m4
index beeba30..49a6f31 100644
--- a/macros/openvg.m4
+++ b/macros/openvg.m4
@@ -36,13 +36,18 @@ AC_DEFUN([GNASH_PATH_OPENVG],
if test -f $i/VG/openvg.h; then
dnl We have the libMesa version of OpenVG 1.0.1
if test -f $i/VG/vgext.h; then
+ AC_DEFINE(HAVE_VG_VGEXT_H, 1, [Have LibMESA OpenVG])
mesavg=yes
+ else
+ if test -f $i/VG/ext.h; then
+ AC_DEFINE(HAVE_VG_EXT_H, 1, [Have Freescale OpenVG])
+ fi
fi
if test x"$i" != x"/usr/include"; then
ac_cv_path_openvg_includes="-I$i"
break
else
- ac_cv_path_openvg_includes="default"
+ ac_cv_path_openvg_includes=""
break
fi
fi
@@ -53,20 +58,10 @@ AC_DEFUN([GNASH_PATH_OPENVG],
AC_CHECK_HEADERS([VG/open.h], [ac_cv_path_openvg_includes=""])
fi
- if test x"${ac_cv_path_openvg_includes}" != x; then
- if test x$mesavg = xyes; then
- OPENVG_CFLAGS="${ac_cv_path_openvg_includes}"
- AC_DEFINE(HAVE_VG_VGEXT_H, 1, [Have LibMESA OpenVG])
- else
- OPENVG_CFLAGS="-DOPENVG_STATIC_LIBRARY ${ac_cv_path_openvg_includes}"
- AC_DEFINE(HAVE_VG_EXT_H, 1, [Have Freescale OpenVG])
- fi
+ if test x"${mesavg}" = xyes; then
+ OPENVG_CFLAGS="${ac_cv_path_openvg_includes}"
else
- if test x$mesavg = xyes; then
- OPENVG_CFLAGS=""
- else
- OPENVG_CFLAGS="-DOPENVG_STATIC_LIBRARY"
- fi
+ OPENVG_CFLAGS="-DOPENVG_STATIC_LIBRARY ${ac_cv_path_openvg_includes}"
fi
AC_MSG_RESULT(${ac_cv_path_openvg_includes})
http://git.savannah.gnu.org/cgit//commit/?id=678490531711a7395de2fba2f01900e724e92413
commit 678490531711a7395de2fba2f01900e724e92413
Author: Rob Savoye <address@hidden>
Date: Fri Dec 17 21:19:21 2010 -0700
InputDevice.h is now in libdevice/events
diff --git a/gui/fb/fbsup.h b/gui/fb/fbsup.h
index 815fb82..08b46fe 100644
--- a/gui/fb/fbsup.h
+++ b/gui/fb/fbsup.h
@@ -31,7 +31,7 @@
#include <linux/fb.h>
#include "gui.h"
-#include "InputDevice.h"
+#include "events/InputDevice.h"
#include "Renderer.h"
#define PIXELFORMAT_LUT8
http://git.savannah.gnu.org/cgit//commit/?id=d2050a59c01522ed55954a7637057544511a58e1
commit d2050a59c01522ed55954a7637057544511a58e1
Author: Rob Savoye <address@hidden>
Date: Fri Dec 17 21:10:33 2010 -0700
add more include paths as some of the input events need them for deeply
included headers bu other headers
diff --git a/libdevice/Makefile.am b/libdevice/Makefile.am
index c3d4fec..9c68cf9 100644
--- a/libdevice/Makefile.am
+++ b/libdevice/Makefile.am
@@ -32,7 +32,10 @@ AM_CPPFLAGS = -I.. \
-I$(top_srcdir)/libbase \
-I$(top_srcdir)/librender \
-I$(top_srcdir)/libcore \
+ -I$(top_srcdir)/libcore/vm \
+ -I$(top_srcdir)/libcore/parser \
-I$(top_srcdir)/libcore/swf \
+ -I$(top_srcdir)/gui \
$(PTHREAD_CFLAGS) \
$(SDL_CFLAGS) \
$(PANGO_CFLAGS) \
http://git.savannah.gnu.org/cgit//commit/?id=8a59f7c269dae70e7b860a8fdeffc38082cd0b69
commit 8a59f7c269dae70e7b860a8fdeffc38082cd0b69
Author: Rob Savoye <address@hidden>
Date: Fri Dec 17 20:48:45 2010 -0700
fix test
diff --git a/macros/openvg.m4 b/macros/openvg.m4
index c0d3b3e..beeba30 100644
--- a/macros/openvg.m4
+++ b/macros/openvg.m4
@@ -53,7 +53,7 @@ AC_DEFUN([GNASH_PATH_OPENVG],
AC_CHECK_HEADERS([VG/open.h], [ac_cv_path_openvg_includes=""])
fi
- if test x"${ac_cv_path_openvg_includes}" != x -a
x"${ac_cv_path_openvg_includes}" != x"default"; then
+ if test x"${ac_cv_path_openvg_includes}" != x; then
if test x$mesavg = xyes; then
OPENVG_CFLAGS="${ac_cv_path_openvg_includes}"
AC_DEFINE(HAVE_VG_VGEXT_H, 1, [Have LibMESA OpenVG])
http://git.savannah.gnu.org/cgit//commit/?id=7f1495a82f2be911556711cd0aaeb70358814eda
commit 7f1495a82f2be911556711cd0aaeb70358814eda
Author: Rob Savoye <address@hidden>
Date: Fri Dec 17 20:12:17 2010 -0700
move most of the target code to makefile fragments to be more readable.
diff --git a/libdevice/Makefile.am b/libdevice/Makefile.am
index d784e60..c3d4fec 100644
--- a/libdevice/Makefile.am
+++ b/libdevice/Makefile.am
@@ -73,38 +73,14 @@ libgnashdevice_la_LIBADD = \
libgnashdevice_la_LDFLAGS = -release $(VERSION)
libgnashdevice_la_SOURCES =
-if BUILD_EGL_DEVICE
-libgnashdevice_la_CPPFLAGS += $(EGL_CFLAGS)
-libgnashdevice_la_SOURCES += \
- egl/eglDevice.cpp \
- egl/eglDevice.h
-libgnashdevice_la_LIBADD += $(EGL_LIBS)
-endif
-
-if BUILD_DIRECTFB_DEVICE
-libgnashdevice_la_CPPFLAGS += $(DIRECTFB_CFLAGS)
+if BUILD_X11_DEVICE
+libgnashdevice_la_CPPFLAGS += $(X11_CFLAGS)
libgnashdevice_la_SOURCES += \
- directfb/DirectFBDevice.cpp \
- directfb/DirectFBDevice.h
-libgnashdevice_la_LIBADD += $(DIRECTFB_LIBS)
+ x11/X11Device.cpp \
+ x11/X11Device.h
+libgnashdevice_la_LIBADD += $(X11_LIBS)
endif
-if BUILD_VAAPI_DEVICE
-libgnashdevice_la_CPPFLAGS += $(VAAPI_CFLAGS)
-libgnashdevice_la_SOURCES += \
- vaapi/VaapiDevice.cpp \
- vaapi/VaapiDevice.h
-libgnashdevice_la_LIBADD += $(VAAPI_LIBS)
-endif
-
-# if BUILD_X11_DEVICE
-# libgnashdevice_la_CPPFLAGS += $(X11_CFLAGS)
-# libgnashdevice_la_SOURCES += \
-# x11/X11Device.cpp \
-# x11/X11Device.h
-# libgnashdevice_la_LIBADD += $(X11_LIBS)
-# endif
-
# Rebuild with GCC 4.x Mudflap support
mudflap:
@echo "Rebuilding with GCC Mudflap support"
@@ -124,55 +100,29 @@ if BUILD_RAWFB_DEVICE
include rawfb/rawfb.am
endif
-if BUILD_EGL_DEVICE
-bin_PROGRAMS += eglinfo
-eglinfo_SOURCES = egl/eglinfo.c
-eglinfo_CPPFLAGS = $(AM_CPPFLAGS)
-eglinfo_LDADD = \
- $(EXTRA_EGL_LIBS) \
- $(EGL_LIBS)
-
-check_PROGRAMS += test_egl
-# this tests the low level EGL interface, used by OpenVG, OpenGLES1,
-# and OpenGLES2.
-test_egl_SOURCES = egl/test_egl.cpp
-test_egl_CPPFLAGS = $(AM_CPPFLAGS)
-test_egl_LDADD = \
- libgnashdevice.la \
- $(EXTRA_EGL_LIBS) \
- $(CURL_LIBS) \
- $(EGL_LIBS) \
- $(GNASH_LIBS)
+# This is for Linux Input Event support
+if ENABLE_INPUT_EVENTS
+include events/events.am
endif
-if BUILD_VAAPI_DEVICE
-check_PROGRAMS += test_vaapi
-test_vaapi_SOURCES = vaapi/test_vaapi.cpp
-test_vaapi_CPPFLAGS = $(AM_CPPFLAGS) $(VAAPI_CFLAGS)
-test_vaapi_LDADD = \
- libgnashdevice.la \
- $(VAAPI_LIBS) \
- $(GNASH_LIBS)
+if BUILD_EGL_DEVICE
+include egl/egl.am
endif
if BUILD_DIRECTFB_DEVICE
-check_PROGRAMS += test_dfb
-test_dfb_SOURCES = directfb/test_dfb.cpp
-test_dfb_CPPFLAGS = $(AM_CPPFLAGS) $(DIRECTFB_CFLAGS)
-test_dfb_LDADD = \
+include directfb/directfb.am
+endif
+
+if BUILD_X11_DEVICE
+check_PROGRAMS += test_x11
+test_x11_SOURCES = x11/test_x11.cpp
+test_x11_CPPFLAGS = $(AM_CPPFLAGS) $(X11_CFLAGS)
+test_x11_LDADD = \
libgnashdevice.la \
- $(DIRECTFB_LIBS) \
+ $(X11_LIBS) \
$(GNASH_LIBS)
endif
-# if BUILD_X11_DEVICE
-# bin_PROGRAMS += test_x11
-# test_x11_SOURCES = x11/test_x11.cpp
-# test_x11_CPPFLAGS = $(AM_CPPFLAGS) $(X11_CFLAGS)
-# test_x11_LDADD = \
-# libgnashdevice.la \
-# $(X11_LIBS) \
-# $(GNASH_LIBS)
-# endif
-
+if BUILD_VAAPI_DEVICE
include vaapi/vaapi.am
+endif
\ No newline at end of file
diff --git a/libdevice/directfb/directfb.am b/libdevice/directfb/directfb.am
new file mode 100644
index 0000000..28141fb
--- /dev/null
+++ b/libdevice/directfb/directfb.am
@@ -0,0 +1,31 @@
+#
+# Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+#
+
+libgnashdevice_la_CPPFLAGS += $(DIRECTFB_CFLAGS)
+libgnashdevice_la_SOURCES += \
+ directfb/DirectFBDevice.cpp \
+ directfb/DirectFBDevice.h
+libgnashdevice_la_LIBADD += $(DIRECTFB_LIBS)
+
+check_PROGRAMS += test_dfb
+test_dfb_SOURCES = directfb/test_dfb.cpp
+test_dfb_CPPFLAGS = $(AM_CPPFLAGS) $(DIRECTFB_CFLAGS)
+test_dfb_LDADD = \
+ libgnashdevice.la \
+ $(DIRECTFB_LIBS) \
+ $(GNASH_LIBS)
diff --git a/libdevice/egl/egl.am b/libdevice/egl/egl.am
new file mode 100644
index 0000000..9bfa9c1
--- /dev/null
+++ b/libdevice/egl/egl.am
@@ -0,0 +1,43 @@
+#
+# Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+#
+
+# eglinfo is a utility program that isn't always available. Since it's useful
+# when bring up Gnash on a new target, it's included here.
+bin_PROGRAMS += eglinfo
+eglinfo_SOURCES = egl/eglinfo.c
+eglinfo_CPPFLAGS = $(AM_CPPFLAGS)
+eglinfo_LDADD = \
+ $(EXTRA_EGL_LIBS) \
+ $(EGL_LIBS)
+
+# this tests the low level EGL interface, used by OpenVG, OpenGLES1, and
OpenGLES2.
+check_PROGRAMS += test_egl
+test_egl_SOURCES = egl/test_egl.cpp
+test_egl_CPPFLAGS = $(AM_CPPFLAGS)
+test_egl_LDADD = \
+ libgnashdevice.la \
+ $(EXTRA_EGL_LIBS) \
+ $(CURL_LIBS) \
+ $(EGL_LIBS) \
+ $(GNASH_LIBS)
+
+libgnashdevice_la_CPPFLAGS += $(EGL_CFLAGS)
+libgnashdevice_la_SOURCES += \
+ egl/eglDevice.cpp \
+ egl/eglDevice.h
+libgnashdevice_la_LIBADD += $(EGL_LIBS)
diff --git a/libdevice/events/events.am b/libdevice/events/events.am
new file mode 100644
index 0000000..86fd37d
--- /dev/null
+++ b/libdevice/events/events.am
@@ -0,0 +1,39 @@
+#
+# Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Free Software Foundation,
Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+#
+
+# These are used to handle input events from a keyboard, mouse, or
+# touchscreen. These are only used by the Framebuffer GUI, as without
+# X11, it has no event handling. We do it this way so the optionally
+# built source files still get included in the source tarball.
+DEVICES =
+if ENABLE_INPUT_DEVICES
+DEVICES += fb/InputDevice.cpp fb/InputDevice.h
+
+# Touchscreen
+if ENABLE_TSLIB
+libgnashdevice_la_SOURCES += fb/TouchDevice.cpp
+endif
+# PS/2 Mouse
+if ENABLE_MOUSE
+libgnashdevice_la_SOURCES += fb/MouseDevice.cpp
+endif
+# Linux input events
+if ENABLE_INPUT_EVENTS
+libgnashdevice_la_SOURCES += fb/EventDevice.cpp
+endif
+endif
http://git.savannah.gnu.org/cgit//commit/?id=97f6df2212de072616155705b263d8298bec9a42
commit 97f6df2212de072616155705b263d8298bec9a42
Author: Rob Savoye <address@hidden>
Date: Fri Dec 17 19:56:10 2010 -0700
add eglinfo so we have a version for our target
diff --git a/configure.ac b/configure.ac
index b025e3c..6c4e199 100644
--- a/configure.ac
+++ b/configure.ac
@@ -36,6 +36,7 @@ AM_COMPILER_LIB
AC_C_BIGENDIAN
AC_C_CONST
AC_C_INLINE
+AM_PROG_CC_C_O
dnl Set the default values for Flash Version. These are converted into
dnl various strings to make JavaScript or ActionScript detectors
@@ -1145,7 +1146,7 @@ AC_ARG_ENABLE(device,
build_x11_device=yes
ndevice=$((ndevice+1))
;;
- di*|Di*|DI*)
+ di*|Di*|DI*|dfb)
device_list="${device_list} DirectFB"
build_directfb_device=yes
ndevice=$((ndevice+1))
diff --git a/libdevice/Makefile.am b/libdevice/Makefile.am
index d59a7e6..d784e60 100644
--- a/libdevice/Makefile.am
+++ b/libdevice/Makefile.am
@@ -118,13 +118,21 @@ AM_CXXFLAGS = $(PCH_FLAGS)
endif
bin_PROGRAMS =
+check_PROGRAMS =
if BUILD_RAWFB_DEVICE
include rawfb/rawfb.am
endif
if BUILD_EGL_DEVICE
-bin_PROGRAMS += test_egl
+bin_PROGRAMS += eglinfo
+eglinfo_SOURCES = egl/eglinfo.c
+eglinfo_CPPFLAGS = $(AM_CPPFLAGS)
+eglinfo_LDADD = \
+ $(EXTRA_EGL_LIBS) \
+ $(EGL_LIBS)
+
+check_PROGRAMS += test_egl
# this tests the low level EGL interface, used by OpenVG, OpenGLES1,
# and OpenGLES2.
test_egl_SOURCES = egl/test_egl.cpp
@@ -138,7 +146,7 @@ test_egl_LDADD = \
endif
if BUILD_VAAPI_DEVICE
-bin_PROGRAMS += test_vaapi
+check_PROGRAMS += test_vaapi
test_vaapi_SOURCES = vaapi/test_vaapi.cpp
test_vaapi_CPPFLAGS = $(AM_CPPFLAGS) $(VAAPI_CFLAGS)
test_vaapi_LDADD = \
@@ -148,7 +156,7 @@ test_vaapi_LDADD = \
endif
if BUILD_DIRECTFB_DEVICE
-bin_PROGRAMS += test_dfb
+check_PROGRAMS += test_dfb
test_dfb_SOURCES = directfb/test_dfb.cpp
test_dfb_CPPFLAGS = $(AM_CPPFLAGS) $(DIRECTFB_CFLAGS)
test_dfb_LDADD = \
diff --git a/libdevice/egl/eglinfo.c b/libdevice/egl/eglinfo.c
new file mode 100644
index 0000000..14620a9
--- /dev/null
+++ b/libdevice/egl/eglinfo.c
@@ -0,0 +1,172 @@
+/*
+ * eglinfo - like glxinfo but for EGL
+ *
+ * Brian Paul
+ * 11 March 2005
+ *
+ * Copyright (C) 2005 Brian Paul All Rights Reserved.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a
+ * copy of this software and associated documentation files (the "Software"),
+ * to deal in the Software without restriction, including without limitation
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense,
+ * and/or sell copies of the Software, and to permit persons to whom the
+ * Software is furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included
+ * in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
+ * BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
+ * AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
+ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+ */
+
+
+#include <EGL/egl.h>
+#include <assert.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+#define MAX_CONFIGS 1000
+#define MAX_MODES 1000
+#define MAX_SCREENS 10
+
+
+/**
+ * Print table of all available configurations.
+ */
+static void
+PrintConfigs(EGLDisplay d)
+{
+ EGLConfig configs[MAX_CONFIGS];
+ EGLint numConfigs, i;
+
+ eglGetConfigs(d, configs, MAX_CONFIGS, &numConfigs);
+
+ printf("Configurations:\n");
+ printf(" bf lv d st colorbuffer dp st ms vis supported\n");
+ printf(" id sz l b ro r g b a th cl ns b id surfaces \n");
+ printf("--------------------------------------------------------\n");
+ for (i = 0; i < numConfigs; i++) {
+ EGLint id, size, level;
+ EGLint red, green, blue, alpha;
+ EGLint depth, stencil;
+ EGLint surfaces;
+ EGLint doubleBuf = 1, stereo = 0;
+ EGLint vid;
+ EGLint samples, sampleBuffers;
+ char surfString[100] = "";
+
+ eglGetConfigAttrib(d, configs[i], EGL_CONFIG_ID, &id);
+ eglGetConfigAttrib(d, configs[i], EGL_BUFFER_SIZE, &size);
+ eglGetConfigAttrib(d, configs[i], EGL_LEVEL, &level);
+
+ eglGetConfigAttrib(d, configs[i], EGL_RED_SIZE, &red);
+ eglGetConfigAttrib(d, configs[i], EGL_GREEN_SIZE, &green);
+ eglGetConfigAttrib(d, configs[i], EGL_BLUE_SIZE, &blue);
+ eglGetConfigAttrib(d, configs[i], EGL_ALPHA_SIZE, &alpha);
+ eglGetConfigAttrib(d, configs[i], EGL_DEPTH_SIZE, &depth);
+ eglGetConfigAttrib(d, configs[i], EGL_STENCIL_SIZE, &stencil);
+ eglGetConfigAttrib(d, configs[i], EGL_NATIVE_VISUAL_ID, &vid);
+ eglGetConfigAttrib(d, configs[i], EGL_SURFACE_TYPE, &surfaces);
+
+ eglGetConfigAttrib(d, configs[i], EGL_SAMPLES, &samples);
+ eglGetConfigAttrib(d, configs[i], EGL_SAMPLE_BUFFERS, &sampleBuffers);
+
+ if (surfaces & EGL_WINDOW_BIT)
+ strcat(surfString, "win,");
+ if (surfaces & EGL_PBUFFER_BIT)
+ strcat(surfString, "pb,");
+ if (surfaces & EGL_PIXMAP_BIT)
+ strcat(surfString, "pix,");
+#ifdef EGL_MESA_screen_surface
+ if (surfaces & EGL_SCREEN_BIT_MESA)
+ strcat(surfString, "scrn,");
+#endif
+ if (strlen(surfString) > 0)
+ surfString[strlen(surfString) - 1] = 0;
+
+ printf("0x%02x %2d %2d %c %c %2d %2d %2d %2d %2d %2d %2d%2d 0x%02x
%-12s\n",
+ id, size, level,
+ doubleBuf ? 'y' : '.',
+ stereo ? 'y' : '.',
+ red, green, blue, alpha,
+ depth, stencil,
+ samples, sampleBuffers, vid, surfString);
+ }
+}
+
+
+/**
+ * Print table of all available configurations.
+ */
+static void
+PrintModes(EGLDisplay d)
+{
+#ifdef EGL_MESA_screen_surface
+ const char *extensions = eglQueryString(d, EGL_EXTENSIONS);
+ if (strstr(extensions, "EGL_MESA_screen_surface")) {
+ EGLScreenMESA screens[MAX_SCREENS];
+ EGLint numScreens = 1, scrn;
+ EGLModeMESA modes[MAX_MODES];
+
+ eglGetScreensMESA(d, screens, MAX_SCREENS, &numScreens);
+ printf("Number of Screens: %d\n\n", numScreens);
+
+ for (scrn = 0; scrn < numScreens; scrn++) {
+ EGLint numModes, i;
+
+ eglGetModesMESA(d, screens[scrn], modes, MAX_MODES, &numModes);
+
+ printf("Screen %d Modes:\n", scrn);
+ printf(" id width height refresh name\n");
+ printf("-----------------------------------------\n");
+ for (i = 0; i < numModes; i++) {
+ EGLint id, w, h, r;
+ const char *str;
+ eglGetModeAttribMESA(d, modes[i], EGL_MODE_ID_MESA, &id);
+ eglGetModeAttribMESA(d, modes[i], EGL_WIDTH, &w);
+ eglGetModeAttribMESA(d, modes[i], EGL_HEIGHT, &h);
+ eglGetModeAttribMESA(d, modes[i], EGL_REFRESH_RATE_MESA, &r);
+ str = eglQueryModeStringMESA(d, modes[i]);
+ printf("0x%02x %5d %5d %.3f %s\n", id, w, h, r / 1000.0, str);
+ }
+ }
+ }
+#endif
+}
+
+
+
+int
+main(int argc, char *argv[])
+{
+ int maj, min;
+ EGLDisplay d = eglGetDisplay(EGL_DEFAULT_DISPLAY);
+
+ if (!eglInitialize(d, &maj, &min)) {
+ printf("eglinfo: eglInitialize failed\n");
+ exit(1);
+ }
+
+ printf("EGL API version: %d.%d\n", maj, min);
+ printf("EGL vendor string: %s\n", eglQueryString(d, EGL_VENDOR));
+ printf("EGL version string: %s\n", eglQueryString(d, EGL_VERSION));
+#ifdef EGL_VERSION_1_2
+ printf("EGL client APIs: %s\n", eglQueryString(d, EGL_CLIENT_APIS));
+#endif
+ printf("EGL extensions string:\n");
+ printf(" %s\n", eglQueryString(d, EGL_EXTENSIONS));
+
+ PrintConfigs(d);
+
+ PrintModes(d);
+
+ eglTerminate(d);
+
+ return 0;
+}
-----------------------------------------------------------------------
Summary of changes:
configure.ac | 19 ++-
gui/fb/fbsup.h | 2 +-
libdevice/Makefile.am | 89 +++--------
.../Makefile.am => libdevice/directfb/directfb.am | 17 ++-
packaging/doc/Makefile.am => libdevice/egl/egl.am | 30 +++-
libdevice/egl/eglinfo.c | 172 ++++++++++++++++++++
.../doc/Makefile.am => libdevice/events/events.am | 26 +++-
macros/openvg.m4 | 23 +--
8 files changed, 275 insertions(+), 103 deletions(-)
copy cygnal/testsuite/Makefile.am => libdevice/directfb/directfb.am (68%)
copy packaging/doc/Makefile.am => libdevice/egl/egl.am (52%)
create mode 100644 libdevice/egl/eglinfo.c
copy packaging/doc/Makefile.am => libdevice/events/events.am (56%)
hooks/post-receive
--
Gnash
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Gnash-commit] [SCM] Gnash branch, openvg, updated. 155611ce1b08eaf733112743baa5256eeb5a2be2,
Rob Savoye <=