Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • mesa/demos
  • skirk/demos
  • inequation/demos
  • kusma/mesa-demos
  • ajax/demos
  • ofourdan/demos
  • austriancoder/demos
  • eric/demos
  • jakogut/demos
  • frohlich/demos
  • dbaker/demos
  • challenzhou/demos
  • jrfonseca/demos
  • orbea/demos
  • mupuf/demos
  • xantares/demos
  • kevinoid/demos
  • theozzhh79/demos
  • EthanHsieh/demos
  • tantan/demos
  • baryluk/demos
  • siyueyinghua/demos
  • hch12907/mesa-demos
  • jljusten/mesa-demos
  • ydirson/demos
  • birdspider/demos
  • alex.kanavin/demos
  • airlied/demos
  • alanc/demos
  • lygstate/demos
  • vsyrjala/mesa-demos
  • stolk/demos
  • qyliss/demos
  • antonino/demos
  • ccawley2011/mesa-demos
  • psykose1/demos
  • dh/demos
  • robertfoss/demos
  • yselkowitz1/mesa-demos
  • Robin329/demos
  • blaztinn/demos
  • ella/demos
  • sima/mesa-demos
  • mstoeckl/demos
  • mildsunrise/mesa-demos
  • duncan.hopkins/demos
  • lucmann/demos
  • pleasurefish/demos
  • mattst88/demos
  • emendoz/mesa-demos
  • LDVSOFT/demos
  • zmike/demos
  • DDoSQc/demos
  • jadahl/mesa-demos
  • wujiansun/demos
55 results
Show changes
Commits on Source (113)
...@@ -15,6 +15,6 @@ indent_style = space ...@@ -15,6 +15,6 @@ indent_style = space
indent_size = 3 indent_size = 3
indent_style = space indent_style = space
[{CMakeLists.txt,*.am,*.cmake,*.sh}] [*.sh]
indent_size = 8 indent_size = 8
indent_style = tab indent_style = tab
.*.sw?
*.a
*.bz2
*.dmg
*.la
*.lo
*.o
*.obj
*.os
*.pc
*.pdb
*.pyc *.pyc
*.pyo *.pyo
*.so
*.zip
*~
.deps
.libs
CMakeCache.txt
CMakeFiles
CPackConfig.cmake
CPackSourceConfig.cmake
Makefile
Makefile.in
_CPack_Packages/
aclocal.m4
autom4te.cache
build build
cmake_install.cmake
compile
config.guess
config.log
config.status
config.sub
configure
configure.lineno
core
cscope*
depcomp
depend
depend.bak
install-sh
install_manifest.txt
libtool
libtool.m4
ltmain.sh
ltoptions.m4
ltsugar.m4
ltversion.m4
lt~obsolete.m4
missing
wayland-xdg-shell-client-protocol.h
wayland-xdg-shell-protocol.c
...@@ -35,19 +35,15 @@ x86_build: ...@@ -35,19 +35,15 @@ x86_build:
# No need to pull the whole repo to build the container image # No need to pull the whole repo to build the container image
GIT_STRATEGY: none GIT_STRATEGY: none
# /!\ Bump the TAG when modifying the DEBS # /!\ Bump the TAG when modifying the DEBS
FDO_DISTRIBUTION_TAG: &x86_build "2022-04-30" FDO_DISTRIBUTION_TAG: &x86_build "2022-05-16"
FDO_DISTRIBUTION_PACKAGES: >- FDO_DISTRIBUTION_PACKAGES: >-
build-essential build-essential
autoconf meson
automake
libtool
make
pkg-config pkg-config
cmake
ninja-build ninja-build
mingw-w64 mingw-w64
wine
extra-cmake-modules
freeglut3-dev freeglut3-dev
libdrm-dev libdrm-dev
libegl-dev libegl-dev
...@@ -59,6 +55,7 @@ x86_build: ...@@ -59,6 +55,7 @@ x86_build:
libx11-dev libx11-dev
libxcb1-dev libxcb1-dev
wayland-protocols wayland-protocols
libosmesa6-dev
.use-x86_build: .use-x86_build:
variables: variables:
...@@ -76,40 +73,29 @@ x86_build: ...@@ -76,40 +73,29 @@ x86_build:
- .ci-run-policy - .ci-run-policy
variables: variables:
GIT_DEPTH: 10 GIT_DEPTH: 10
.cmake-build:
extends:
- .build
script: script:
- cmake -S . -B _build - meson _build
-DCMAKE_INSTALL_PREFIX=$PWD/install --prefix $PWD/install
-DCMAKE_BUILD_TYPE=Debug --buildtype debug
-G Ninja ${EXTRA_OPTION}
- ninja -C _build -j4 - ninja -C _build -j4
- ninja -C _build install - ninja -C _build install
.autotools-build: build:
extends:
- .build
script:
- ./autogen.sh
- make -j4
- make check
- DESTDIR=$PWD/install make install
cmake:
extends:
- .use-x86_build
- .cmake-build
cmake-mingw:
extends: extends:
- .use-x86_build - .use-x86_build
- .build - .build
script: variables:
- .gitlab-ci/build-mingw.sh EXTRA_OPTION: >
-Dauto_features=enabled
autotools: build-mingw:
extends: extends:
- .use-x86_build - .use-x86_build
- .autotools-build - .build
before_script:
- .gitlab-ci/prepare-glut-mingw.sh
variables:
EXTRA_OPTION: >
--cross-file=.gitlab-ci/x86_64-w64-mingw32
-Dwith-glut=/tmp/freeglut-mingw
set (CMAKE_SYSTEM_NAME Windows)
set (CMAKE_C_COMPILER i686-w64-mingw32-gcc)
set (CMAKE_CXX_COMPILER i686-w64-mingw32-g++)
set (CMAKE_RC_COMPILER i686-w64-mingw32-windres)
set (CMAKE_FIND_ROOT_PATH /usr/i686-w64-mingw32)
set (CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
set (CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
set (CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
#!/bin/bash #!/bin/bash
if [ -d /usr/lib/ccache ]
then
export PATH="/usr/lib/ccache:$PATH"
fi
set -e -x -u set -e -x -u
GLUT_INCLUDE_DIR="$PWD/external/freeglut/include" GLUT_INCLUDE_DIR="/tmp/freeglut-mingw/include"
GLUT_LIBRARY="$PWD/external/freeglut/lib/libfreeglut.a" GLUT_LIBRARY="/tmp/freeglut-mingw/lib/libglut.a"
if [ ! -f "$GLUT_INCLUDE_DIR/GL/glut.h" ] if [ ! -f "$GLUT_INCLUDE_DIR/GL/glut.h" ]
then then
mkdir -p "$GLUT_INCLUDE_DIR/GL" mkdir -p "$GLUT_INCLUDE_DIR/GL"
...@@ -19,22 +14,6 @@ then ...@@ -19,22 +14,6 @@ then
fi fi
if [ ! -f "$GLUT_LIBRARY" ] if [ ! -f "$GLUT_LIBRARY" ]
then then
mkdir -p external/freeglut/lib mkdir -p /tmp/freeglut-mingw/lib
i686-w64-mingw32-dlltool --kill-at --def .gitlab-ci/freeglut.def --output-lib "$GLUT_LIBRARY" i686-w64-mingw32-dlltool --kill-at --def .gitlab-ci/freeglut.def --output-lib "$GLUT_LIBRARY"
fi fi
cmake \
-S . \
-B build/mingw32 \
-G "Ninja" \
-DCMAKE_TOOLCHAIN_FILE=.gitlab-ci/mingw32.cmake \
-DCMAKE_BUILD_TYPE=Debug \
-DCMAKE_INSTALL_PREFIX=publish/mingw32 \
-DGLUT_INCLUDE_DIR="$GLUT_INCLUDE_DIR" \
-DGLUT_glut_LIBRARY="$GLUT_LIBRARY" \
-DGLUT_glut_LIBRARY_DEBUG="$GLUT_LIBRARY" \
-DGLUT_glut_LIBRARY_RELEASE="$GLUT_LIBRARY"
cmake --build build/mingw32
cmake --build build/mingw32 --target install
[binaries]
c = ['ccache', 'i686-w64-mingw32-gcc']
cpp = ['ccache', 'i686-w64-mingw32-g++']
ar = 'i686-w64-mingw32-ar'
strip = 'i686-w64-mingw32-strip'
pkgconfig = 'i686-w64-mingw32-pkg-config'
windres = 'i686-w64-mingw32-windres'
exe_wrapper = ['wine32']
[properties]
needs_exe_wrapper = True
sys_root = '/usr/i686-w64-mingw32/'
[host_machine]
system = 'windows'
cpu_family = 'x86'
cpu = 'i686'
endian = 'little'
cmake_minimum_required (VERSION 2.8.12)
project (mesademos)
include (FindPkgConfig)
include (CheckCCompilerFlag)
include (CheckSymbolExists)
find_package (OpenGL REQUIRED)
find_package (GLUT)
find_package (X11)
if (NOT GLUT_FOUND)
message (WARNING "GLUT was not found, only platform specific demos will be built")
endif ()
set (GLAD_INCLUDE_DIR ${CMAKE_SOURCE_DIR}/src/glad/include)
if (PKG_CONFIG_FOUND AND NOT WIN32)
find_package (ECM NO_MODULE)
if (ECM_FOUND)
set (CMAKE_MODULE_PATH ${ECM_FIND_MODULE_DIR})
find_package (Wayland)
find_package (WaylandProtocols)
find_package (WaylandScanner)
if (Wayland_FOUND AND WaylandProtocols_FOUND AND WaylandScanner_FOUND)
set(BUILD_WAYLAND ON)
endif ()
endif ()
pkg_check_modules (EGL egl)
pkg_check_modules (GLESV1 glesv1_cm)
pkg_check_modules (GLESV2 glesv2)
pkg_check_modules (OSMESA osmesa)
endif ()
# Check for FreeGLUT 2.6 or later
set (CMAKE_REQUIRED_INCLUDES "${GLUT_INCLUDE_DIR}")
set (CMAKE_REQUIRED_LIBRARIES "${GLUT_glut_LIBRARY}")
check_symbol_exists ("glutInitContextProfile" "GL/glut.h;GL/freeglut.h" HAVE_FREEGLUT)
if (HAVE_FREEGLUT)
add_definitions (-DHAVE_FREEGLUT)
endif ()
if (UNIX)
link_libraries(m)
endif (UNIX)
# On Mac OS X, GLX is provided as a separate OpenGL implementation, different
# from the standard OpenGL framework which provides support for GLUT and native
# Mac OS X applications.
if (X11_FOUND)
if (APPLE)
find_path (X11_GL_INCLUDE_PATH GL/glx.h ${X11_INC_SEARCH_PATH})
if (NOT X11_GL_INCLUDE_PATH)
message (WARNING "Could not find GL/glx.h")
set (X11_FOUND FALSE)
endif (NOT X11_GL_INCLUDE_PATH)
set (X11_INCLUDE_DIR ${X11_INCLUDE_DIR} ${X11_GL_INCLUDE_PATH})
find_library (X11_GL_LIB GL ${X11_LIB_SEARCH_PATH})
if (NOT X11_GL_LIB)
message (WARNING "Could not find libGL.dylib")
set (X11_FOUND FALSE)
endif (NOT X11_GL_LIB)
find_library (X11_GLU_LIB GLU ${X11_LIB_SEARCH_PATH})
if (NOT X11_GLU_LIB)
message (WARNING "Could not find libGLU.dylib")
set (X11_FOUND FALSE)
endif (NOT X11_GLU_LIB)
else ()
set (X11_INCLUDE_DIR ${X11_INCLUDE_DIR} ${OPENGL_INCLUDE_DIR})
set (X11_GL_LIB ${OPENGL_gl_LIBRARY})
set (X11_GLU_LIB ${OPENGL_glu_LIBRARY})
endif ()
endif (X11_FOUND)
if (CMAKE_COMPILER_IS_GNUCC)
add_definitions(
-Wall
-Wpointer-arith
-Wmissing-declarations
-fno-strict-aliasing
#-Wold-style-definition
#-Wdeclaration-after-statement
)
set (CMAKE_C_FLAGS "-Wmissing-prototypes -Wnested-externs -Wbad-function-cast ${CMAKE_CXX_FLAGS}")
endif ()
if (WIN32)
# Don't define min/max macros
add_definitions (-DNOMINMAX)
link_libraries (winmm)
endif (WIN32)
if (MSVC)
message (WARNING "MSVC builds are unmainted. MinGW-w64 is recommended.")
# Enable math constants defines
add_definitions (-D_USE_MATH_DEFINES)
# Silence several MSVC pedantic warnings
add_definitions (-D_CRT_SECURE_NO_DEPRECATE -D_CRT_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_WARNINGS)
add_definitions (-D_SCL_SECURE_NO_DEPRECATE -D_SCL_SECURE_NO_WARNINGS)
add_definitions (-wd4018) # signed/unsigned mismatch
add_definitions (-wd4244) # conversion' conversion from 'type1' to 'type2', possible loss of data
add_definitions (-wd4305) # truncation from 'type1' to 'type2'
# Use static runtime
# http://www.cmake.org/Wiki/CMake_FAQ#How_can_I_build_my_MSVC_application_with_a_static_runtime.3F
foreach (flag_var
CMAKE_C_FLAGS CMAKE_C_FLAGS_DEBUG CMAKE_C_FLAGS_RELEASE CMAKE_C_FLAGS_MINSIZEREL CMAKE_C_FLAGS_RELWITHDEBINFO
CMAKE_CXX_FLAGS CMAKE_CXX_FLAGS_DEBUG CMAKE_CXX_FLAGS_RELEASE CMAKE_CXX_FLAGS_MINSIZEREL CMAKE_CXX_FLAGS_RELWITHDEBINFO
)
if (${flag_var} MATCHES "/MD")
string (REGEX REPLACE "/MD" "/MT" ${flag_var} "${${flag_var}}")
endif ()
endforeach (flag_var)
endif (MSVC)
if (MINGW)
# Avoid depending on MinGW runtime DLLs
check_c_compiler_flag (-static-libgcc HAVE_STATIC_LIBGCC_FLAG)
if (HAVE_STATIC_LIBGCC_FLAG)
set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -static-libgcc")
set (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -static-libgcc")
set (CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -static-libgcc")
endif ()
check_c_compiler_flag (-static-libstdc++ HAVE_STATIC_LIBSTDCXX_FLAG)
if (HAVE_STATIC_LIBSTDCXX_FLAG)
set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -static-libstdc++")
set (CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -static-libstdc++")
set (CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} -static-libstdc++")
endif ()
endif ()
if (APPLE)
# Silence deprecated function warnings (we rely on GLUT which is now
# declared as deprecated)
add_definitions (-Wno-deprecated-declarations)
endif ()
add_definitions(-DDEMOS_DATA_DIR=\"../data/\")
if (BUILD_SHARED_LIBS AND NOT DEFINED LIBDIR)
set(LIBDIR lib)
endif (BUILD_SHARED_LIBS AND NOT DEFINED LIBDIR)
add_subdirectory (src)
install (FILES index.html DESTINATION doc)
set (CPACK_PACKAGE_NAME "mesa-demos")
set (CPACK_PACKAGE_VERSION_MAJOR "8")
set (CPACK_PACKAGE_VERSION_MINOR "4")
set (CPACK_PACKAGE_VERSION_PATCH "0")
if (WIN32)
set (CPACK_GENERATOR "ZIP")
elseif (APPLE)
set (CPACK_GENERATOR "DragNDrop")
set (CPACK_DMG_FORMAT "UDBZ")
else ()
set (CPACK_GENERATOR "TBZ2")
endif ()
include(CPack)
# Copyright © 2009 Intel Corporation
#
# 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 (including the next
# paragraph) 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
# THE AUTHORS OR COPYRIGHT HOLDERS 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.
#
# Authors:
# Eric Anholt <eric@anholt.net>
AUTOMAKE_OPTIONS = foreign
ACLOCAL_AMFLAGS = -I m4
SUBDIRS = src
Mesa Demos
==========
Introduction
------------
The Mesa Demos package contains a large number of OpenGL demonstration
and test programs.
These programs were previously distributed as the MesaDemos-x.y.z.tar.gz
package released in conjunction with the MesaLib-x.y.z.tar.gz package.
The demos are separated now since they don't change often and
aren't tied to a particular version of Mesa.
Note that the Mesa demos should be usable with any OpenGL implementation;
not just Mesa.
Latest Release
--------------
The latest version of the Mesa demos can be found on the `mesa3d.org
archives <https://archive.mesa3d.org/demos/>`_ site.
Git Repository
--------------
The Mesa demos git repository can be obtained with:
.. code-block:: sh
$ git clone https://gitlab.freedesktop.org/mesa/demos.git
Building
--------
The Mesa demos can be built with `Meson <https://mesonbuild.com/>`_.
Prerequisites
^^^^^^^^^^^^^
You'll need GLUT or `FreeGLUT <http://freeglut.sourceforge.net/>`_
(runtime libraries and header files).
If you're using an RPM-based Linux distro you can install these items
with:
.. code-block:: sh
$ yum install freeglut freeglut-devel
And if you're using a Debian based Linux distro you can install these
items with:
.. code-block:: sh
$ apt-get install freeglut3-dev
For `Wayland <https://wayland.freedesktop.org/>`_ support,
`wayland-protocols <https://gitlab.freedesktop.org/wayland/wayland-protocols>`_
and
`wayland-scanner <https://gitlab.freedesktop.org/wayland/wayland>`_
must be available.
Meson
^^^^^
Run **meson configure** to see the options available for building
the demos.
Otherwise, just run **meson build-dir; meson compile -C build-dir** to
build the demos.
See the `Meson documentation <https://mesonbuild.com/>`_ for more
information about Meson.
MinGW cross-compilation
"""""""""""""""""""""""
Create a **cross-file** file containing:
.. code-block:: ini
[binaries]
c = '/usr/bin/x86_64-w64-mingw32-gcc'
cpp = '/usr/bin/x86_64-w64-mingw32-g++'
ar = '/usr/bin/x86_64-w64-mingw32-ar'
strip = '/usr/bin/x86_64-w64-mingw32-strip'
pkgconfig = 'x86_64-w64-mingw32-pkg-config'
exe_wrapper = 'wine'
[host_machine]
system = 'windows'
cpu_family = 'x86_64'
cpu = 'i686'
endian = 'little'
Then do:
.. code-block:: sh
$ meson --prefix=/path/to/install --cross-file /path/to/cross-file build-dir
$ meson compile -C build-dir
$ meson install -C build-dir
The Demos
---------
Look in the **src/** directory for these sub-directories, among others:
- **demos**: the original Mesa demos, such as gears, gloss, etc.
- **redbook**: the OpenGL Programming Guide demos
- **samples**: original SGI OpenGL demos
- **glsl**: OpenGL Shading Language demos
- **gs**: Geometry shader demos
- **xdemos**: GLX-based demos
- **egl**: EGL-based demos
- **wgl**: WGL-based demos
- **fp**: fragment program tests
- **vp**: vertex program tests
- **data**: data files used by the demos
- **perf**: performance tests
- **tests**: assorted test programs
- **objviewer**: program to view .obj modes with a skybox
Getting Help
------------
If you have trouble building or using the Mesa demos, you can post
to the `Mesa users <http://lists.freedesktop.org/mailman/listinfo/mesa-users>`_
mailing list.
If your question is especially technical, you can try the
to the `Mesa dev <http://lists.freedesktop.org/mailman/listinfo/mesa-dev>`_
mailing list.
Reporting Bugs
--------------
Bugs in the demos can be reported to the
`Mesa demos issue tracker <https://gitlab.freedesktop.org/mesa/demos/-/issues>`_.
#! /bin/sh
srcdir=`dirname "$0"`
test -z "$srcdir" && srcdir=.
ORIGDIR=`pwd`
MAKEFLAGS=""
cd $srcdir
autoreconf -v --install || exit 1
cd $ORIGDIR || exit $?
if test -z "$NOCONFIGURE"; then
"$srcdir"/configure "$@"
fi
# Copyright © 2009 Intel Corporation
#
# 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 (including the next
# paragraph) 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
# THE AUTHORS OR COPYRIGHT HOLDERS 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.
#
# Authors:
# Eric Anholt <eric@anholt.net>
dnl Process this file with autoconf to create configure.
AC_PREREQ([2.59])
AC_INIT([mesa-demos], [8.4.0],
[https://gitlab.freedesktop.org/mesa/demos/-/issues])
AC_CANONICAL_HOST
AM_INIT_AUTOMAKE([dist-bzip2])
dnl Check for progs
AC_PROG_CPP
AC_PROG_CC
AC_PROG_CXX
AC_PROG_LIBTOOL
AM_PROG_CC_C_O
AC_CONFIG_MACRO_DIR([m4])
# Enable quiet compiles on automake 1.11.
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
dnl Make sure the pkg-config macros are defined
m4_ifndef([PKG_PROG_PKG_CONFIG],
[m4_fatal([Could not locate the pkg-config autoconf macros.
These are usually located in /usr/share/aclocal/pkg.m4. If your macros
are in a different location, try setting the environment variable
ACLOCAL="aclocal -I/other/macro/dir" before running autoreconf.])])
PKG_PROG_PKG_CONFIG()
dnl Get the pkg-config definitions for libGL. We include a fallback
dnl path for GL implementation that don't provide a .pc file
PKG_CHECK_MODULES(GL, [gl], [], [
AC_CHECK_HEADER([GL/gl.h],
[],
AC_MSG_ERROR([GL not found]))
AC_CHECK_LIB([GL],
[glBegin],
[GL_LIBS=-lGL],
AC_MSG_ERROR([GL required]))
])
DEMO_CFLAGS="$DEMO_CFLAGS $GL_CFLAGS"
DEMO_LIBS="$DEMO_LIBS $GL_LIBS"
dnl Check for GLUT
glut_enabled=yes
AC_ARG_WITH([glut],
[AS_HELP_STRING([--with-glut=DIR],
[glut install directory])],
[GLUT_CFLAGS="-I$withval/include"
GLUT_LIBS="-L$withval/lib -lglut"],
[GLUT_CFLAGS=""
GLUT_LIBS="-lglut"]
)
AS_IF([test "x$with_glut" != xno],
[AC_CHECK_HEADER([GL/glut.h],
[],
[glut_enabled=no])
AC_CHECK_LIB([glut],
[glutInit],
[],
[glut_enabled=no])],
[glut_enabled=no])
dnl Check for FreeGLUT 2.6 or later
AC_EGREP_HEADER([glutInitContextProfile],
[GL/freeglut.h],
[AC_DEFINE(HAVE_FREEGLUT)],
[])
# LIBS was set by AC_CHECK_LIB above
LIBS=""
PKG_CHECK_MODULES(GLU, [glu], [],
[AC_CHECK_HEADER([GL/glu.h],
[],
AC_MSG_ERROR([GLU not found]))
AC_CHECK_LIB([GLU],
[gluBeginCurve],
[GLU_LIBS=-lGLU],
AC_MSG_ERROR([GLU required])) ])
DEMO_CFLAGS="$DEMO_CFLAGS $GLU_CFLAGS"
DEMO_LIBS="$DEMO_LIBS $GLU_LIBS"
AC_ARG_ENABLE([egl],
[AS_HELP_STRING([--enable-egl],
[enable EGL library @<:@default=auto@:>@])],
[egl_enabled="$enableval"],
[egl_enabled=auto])
if test "x$egl_enabled" != "xno"; then
PKG_CHECK_MODULES(EGL, [egl], [egl_enabled=yes], [egl_enabled=no])
fi
AC_ARG_ENABLE([gles1],
[AS_HELP_STRING([--enable-gles1],
[enable support for OpenGL ES 1.x API @<:@default=auto@:>@])],
[glesv1_enabled="$enableval"],
[glesv1_enabled=auto])
if test "x$glesv1_enabled" != "xno"; then
PKG_CHECK_MODULES(GLESV1, [glesv1_cm], [glesv1_enabled=yes], [glesv1_enabled=no])
fi
AC_ARG_ENABLE([gles2],
[AS_HELP_STRING([--enable-gles2],
[enable support for OpenGL ES 2.x API @<:@default=auto@:>@])],
[glesv2_enabled="$enableval"],
[glesv2_enabled=auto])
if test "x$glesv2_enabled" != "xno"; then
PKG_CHECK_MODULES(GLESV2, [glesv2], [glesv2_enabled=yes], [glesv2_enabled=no])
fi
AC_ARG_ENABLE([osmesa],
[AS_HELP_STRING([--enable-osmesa],
[enable OSMesa library @<:@default=auto@:>@])],
[osmesa_enabled="$enableval"],
[osmesa_enabled=auto])
if test "x$osmesa_enabled" != "xno"; then
PKG_CHECK_MODULES(OSMESA, [osmesa], [osmesa_enabled=yes], [osmesa_enabled=no])
fi
AC_ARG_ENABLE([libdrm],
[AS_HELP_STRING([--enable-libdrm],
[enable support for libdrm @<:@default=auto@:>@])],
[drm_enabled="$enableval"],
[drm_enabled=auto])
if test "x$drm_enabled" != "xno"; then
PKG_CHECK_MODULES(DRM, [libdrm], [drm_enabled=yes], [drm_enabled=no])
fi
dnl The OSMesa .pc uses OSMesa32, while we want to build with other versions
dnl too.
OSMESA32_LIBS=$OSMESA_LIBS
OSMESA16_LIBS=`echo $OSMESA_LIBS | sed 's|32|16|g'`
OSMESA_LIBS=`echo $OSMESA_LIBS | sed 's|32||g'`
dnl Compiler macros
case "$host_os" in
linux*|*-gnu*|gnu*)
DEMO_CFLAGS="$DEMO_CFLAGS -D_GNU_SOURCE -DPTHREADS"
;;
solaris*)
DEMO_CFLAGS="$DEFINES -DPTHREADS -DSVR4"
;;
cygwin*)
DEMO_CFLAGS="$DEFINES -DPTHREADS"
;;
esac
dnl Set up C warning flags. Copy of XORG_CWARNFLAGS.
if test "x$GCC" = xyes ; then
CWARNFLAGS="-Wall -Wpointer-arith -Wmissing-prototypes \
-Wmissing-declarations -Wnested-externs -fno-strict-aliasing \
-Wbad-function-cast"
case `$CC -dumpversion` in
3.4.* | 4.*)
CWARNFLAGS="$CWARNFLAGS -Wold-style-definition -Wdeclaration-after-statement"
;;
esac
else
AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"])
if test "x$SUNCC" = "xyes"; then
CWARNFLAGS="-v"
fi
fi
DEMO_CFLAGS="$DEMO_CFLAGS $CWARNFLAGS"
AC_ARG_ENABLE([x11],
[AS_HELP_STRING([--enable-x11],
[enable support for X11 @<:@default=auto@:>@])],
[x11_enabled="$enableval"],
[x11_enabled=auto])
if test "x$x11_enabled" != "xno"; then
PKG_CHECK_MODULES(X11, [x11 xext], [x11_enabled=yes], [x11_enabled=no])
fi
AC_ARG_ENABLE([wayland],
[AS_HELP_STRING([--enable-wayland],
[enable support for wayland @<:@default=auto@:>@])],
[wayland_enabled="$enableval"],
[wayland_enabled=auto])
if test "x$wayland_enabled" != "xno"; then
PKG_CHECK_MODULES(WAYLAND,
[wayland-client wayland-egl wayland-protocols],
[wayland_enabled=yes],
[wayland_enabled=no])
fi
if test "x$wayland_enabled" != "xno"; then
ac_wayland_scanner=`"$PKG_CONFIG" --variable=wayland_scanner wayland-scanner`
ac_wayland_protocols_pkgdatadir=`"$PKG_CONFIG" --variable=pkgdatadir wayland-protocols`
fi
AC_SUBST(WAYLAND_PROTOCOLS_DATADIR, $ac_wayland_protocols_pkgdatadir)
AC_SUBST(WAYLAND_SCANNER, $ac_wayland_scanner)
dnl GBM is needed for EGL on KMS
AC_ARG_ENABLE([gbm],
[AS_HELP_STRING([--enable-gbm],
[enable support for GBM @<:@default=auto@:>@])],
[gbm_enabled="$enableval"],
[gbm_enabled=auto])
if test "x$gbm_enabled" != "xno"; then
PKG_CHECK_MODULES(GBM, [gbm], [gbm_enabled=yes], [gbm_enabled=no])
fi
use_system_data=no
AC_ARG_WITH([system-data-files],
[AS_HELP_STRING([--with-system-data-files],
[Use system data files for demos (default: no)])],
[use_system_data=yes], [])
if test "x$use_system_data" = xyes; then
demos_data_dir="${datadir}/${PACKAGE}/"
else
demos_data_dir="../data/"
fi
AC_DEFINE_DIR(DEMOS_DATA_DIR, demos_data_dir, [Data dir for demos])
AC_DEFINE_UNQUOTED([DEMOS_DATA_DIR], "$DEMOS_DATA_DIR",
[Directory for demos data files])
dnl
dnl Program library dependencies
dnl Only libm is added here if necessary as the libraries should
dnl be pulled in by the linker
dnl
case "$host_os" in
solaris*)
DEMO_LIBS="$DEMO_LIBS -lX11 -lsocket -lnsl -lm"
;;
cygwin*)
DEMO_LIBS="$DEMO_LIBS -lX11"
;;
*)
DEMO_LIBS="$DEMO_LIBS -lm"
;;
esac
AC_SUBST([DEMO_CFLAGS])
AC_SUBST([DEMO_LIBS])
AC_SUBST([EGL_CFLAGS])
AC_SUBST([EGL_LIBS])
AC_SUBST([GLESV1_CFLAGS])
AC_SUBST([GLESV1_LIBS])
AC_SUBST([GLESV2_CFLAGS])
AC_SUBST([GLESV2_LIBS])
AC_SUBST([GLUT_CFLAGS])
AC_SUBST([GLUT_LIBS])
AC_SUBST([X11_CFLAGS])
AC_SUBST([X11_LIBS])
AC_SUBST([OSMESA_CFLAGS])
AC_SUBST([OSMESA_LIBS])
AC_SUBST([OSMESA16_LIBS])
AC_SUBST([OSMESA32_LIBS])
AC_SUBST([WAYLAND_CFLAGS])
AC_SUBST([WAYLAND_LIBS])
AM_CONDITIONAL(HAVE_EGL, test "x$egl_enabled" = "xyes")
AM_CONDITIONAL(HAVE_GLESV1, test "x$glesv1_enabled" = "xyes")
AM_CONDITIONAL(HAVE_GLESV2, test "x$glesv2_enabled" = "xyes")
AM_CONDITIONAL(HAVE_GLUT, test "x$glut_enabled" = "xyes")
AM_CONDITIONAL(HAVE_X11, test "x$x11_enabled" = "xyes")
AM_CONDITIONAL(HAVE_GBM, test "x$gbm_enabled" = "xyes")
AM_CONDITIONAL(HAVE_OSMESA, test "x$osmesa_enabled" = "xyes")
AM_CONDITIONAL(HAVE_DRM, test "x$drm_enabled" = "xyes")
AM_CONDITIONAL(HAVE_WAYLAND, test "x$wayland_enabled" = "xyes")
AC_OUTPUT([
Makefile
src/Makefile
src/demos/Makefile
src/egl/Makefile
src/egl/eglut/Makefile
src/egl/opengl/Makefile
src/egl/opengles1/Makefile
src/egl/opengles2/Makefile
src/fp/Makefile
src/fpglsl/Makefile
src/glad/Makefile
src/glsl/Makefile
src/gs/Makefile
src/data/Makefile
src/objviewer/Makefile
src/osdemos/Makefile
src/perf/Makefile
src/redbook/Makefile
src/samples/Makefile
src/tests/Makefile
src/tools/Makefile
src/trivial/Makefile
src/util/Makefile
src/vp/Makefile
src/vpglsl/Makefile
src/wgl/Makefile
src/xdemos/Makefile
])
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html lang="en">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<title>Mesa Demos Distribution</title>
<style type="text/css">
<!--
pre { background: #cccccc; }
-->
</style>
</head>
<body>
<h1>Introduction</h1>
<p>
The Mesa Demos package contains a large number of OpenGL demonstration
and test programs.
</p>
<p>
These programs were previously distributed as the MesaDemos-x.y.z.tar.gz
package released in conjunction with the MesaLib-x.y.z.tar.gz package.
The demos are separated now since they don't change often and
aren't tied to a particular version of Mesa.
</p>
<p>
Note that the Mesa demos should be usable with any OpenGL implementation;
not just Mesa.
</p>
<h1>FTP site</h1>
<p>
The latest version of the Mesa demos can be found on the
<a href="https://archive.mesa3d.org/demos/">mesa3d.org archives</a>
site.
</p>
<h1>Git Repository</h1>
<p>
The Mesa demos git repository can be obtained with:
</p>
<pre>
git clone https://gitlab.freedesktop.org/mesa/demos.git
</pre>
<h1>Building</h1>
<p>
The Mesa demos can be built with autoconf or <a href="http://www.cmake.org/">CMake</a>.
</p>
<h2>Prerequisites</h2>
<p>
You'll need glut or <a href="http://freeglut.sourceforge.net/">freeglut</a> (runtime libraries and header files).
</p>
<p>
If you're using an RPM-based Linux distro you can install these items with:
</p>
<pre>
yum install freeglut freeglut-devel
</pre>
<p>
And if you're using a Debian based Linux distro you can install these items with:
</p>
<pre>
apt-get install freeglut3-dev
</pre>
<p>
For <a href="https://wayland.freedesktop.org/">Wayland</a> support,
<a href="https://gitlab.freedesktop.org/wayland/wayland-protocols">wayland-protocols</a>
and
<a href="https://gitlab.freedesktop.org/wayland/wayland">wayland-scanner</a>
must be available. Additionally, to build for Wayland using CMake,
<a href="https://invent.kde.org/frameworks/extra-cmake-modules">Extra CMake
Modules</a> must be available.
</p>
<h2>Autoconf</h2>
<p>
Run <b>./configure --help</b> to see the options available for building
the demos.
</p>
<p>
Otherwise, just run <b>./configure ; make</b> to build the demos.
</p>
<h2>CMake</h2>
<p>
See the <a href="http://www.cmake.org/cmake/help/documentation.html">CMake documentation</a> for more information about CMake.
</p>
<h3>Unix</h3>
<p>
Run:
</p>
<pre>
cmake .
make
</pre>
<h3>MSVC</h3>
<ul>
<li>Start the CMake GUI.</li>
<li>Specify where this source is and where to build the binaries.</li>
<li>Click <i>Configure</i>.</li>
<li>Specify where GLUT headers and libraries are; specifically via the
<b>GLUT_INCLUDE_DIR</b>, and <b>GLUT_glut_LIBRARY</b> variables.</li>
<li>Click <i>Generate</i>.</li>
<li>Open the generated <b>mesademos.sln</b> Visual Studio solution file and build the target <b>ALL</b>.
</ul>
<h3>MinGW cross-compilation</h3>
<p>
Create a <b>Toolchain.cmake</b> file containing:
</p>
<pre>
# the name of the target operating system
set (CMAKE_SYSTEM_NAME Windows)
# which compilers to use for C and C++
set (CMAKE_C_COMPILER i586-mingw32msvc-gcc)
set (CMAKE_CXX_COMPILER i586-mingw32msvc-g++)
set (CMAKE_RC_COMPILER i586-mingw32msvc-windres)
# here is the target environment located
set (CMAKE_FIND_ROOT_PATH /usr/i586-mingw32msvc)
# adjust the default behaviour of the FIND_XXX() commands:
# search headers and libraries in the target environment, search
# programs in the host environment
set (CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
set (CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
set (CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
</pre>
<p>
Create a <b>Cache.cmake</b> file containing:
</p>
<pre>
set (GLUT_INCLUDE_DIR "/path/to/glut/include" CACHE PATH "" FORCE)
set (GLUT_glut_LIBRARY "/path/to/glut/lib/libglut32.a" CACHE FILEPATH "" FORCE)
</pre>
<p>
Then do:
</p>
<pre>
cmake -G "Unix Makefiles" -DCMAKE_INSTALL_PREFIX=/path/to/install -DCMAKE_BUILD_TYPE=MinSizeRel -DCMAKE_TOOLCHAIN_FILE=/path/to/Toolchain.cmake -C /path/to/Cache.cmake
make
make install
</pre>
<p>
Read <a href="http://www.vtk.org/Wiki/CmakeMingw">this</a> for more information about CMake and MinGW cross compilation.
</p>
<h1>The Demos</h1>
<p>
Look in the <b>src/</b> directory for these sub-directories, among others:
</p>
<ul>
<li>demos - the original Mesa demos, such as gears, gloss, etc.</li>
<li>redbook - the OpenGL Programming Guide demos</li>
<li>samples- original SGI OpenGL demos</li>
<li>glsl - OpenGL Shading Language demos</li>
<li>gs - Geometry shader demos</li>
<li>xdemos - GLX-based demos</li>
<li>egl - EGL-based demos</li>
<li>wgl - WGL-based demos</li>
<li>fp - fragment program tests</li>
<li>vp - vertex program tests</li>
<li>data - data files used by the demos</li>
<li>perf - performance tests</li>
<li>tests - assorted test programs</li>
<li>objviewer - program to view .obj modes with a skybox</li>
</ul>
<h1>Getting Help</h1>
<p>
If you have trouble building or using the Mesa demos, you can post
to the<a href="http://lists.freedesktop.org/mailman/listinfo/mesa-users">
Mesa users</a> mailing list.
</p>
<p>
If your question is especially technical, you can try the
to the<a href="http://lists.freedesktop.org/mailman/listinfo/mesa-dev">
Mesa dev</a> mailing list.
</p>
<h1>Reporting Bugs</h1>
<p>
Bugs in the demos can be reported to the
<a href="https://gitlab.freedesktop.org/mesa/demos/-/issues">
Mesa demos issue tracker</a>.
</p>
</body>
</html>
# ===========================================================================
# http://autoconf-archive.cryp.to/ac_define_dir.html
# ===========================================================================
#
# SYNOPSIS
#
# AC_DEFINE_DIR(VARNAME, DIR [, DESCRIPTION])
#
# DESCRIPTION
#
# This macro sets VARNAME to the expansion of the DIR variable, taking
# care of fixing up ${prefix} and such.
#
# VARNAME is then offered as both an output variable and a C preprocessor
# symbol.
#
# Example:
#
# AC_DEFINE_DIR([DATADIR], [datadir], [Where data are placed to.])
#
# LAST MODIFICATION
#
# 2008-04-12
#
# COPYLEFT
#
# Copyright (c) 2008 Stepan Kasal <kasal@ucw.cz>
# Copyright (c) 2008 Andreas Schwab <schwab@suse.de>
# Copyright (c) 2008 Guido U. Draheim <guidod@gmx.de>
# Copyright (c) 2008 Alexandre Oliva
#
# Copying and distribution of this file, with or without modification, are
# permitted in any medium without royalty provided the copyright notice
# and this notice are preserved.
AC_DEFUN([AC_DEFINE_DIR], [
prefix_NONE=
exec_prefix_NONE=
test "x$prefix" = xNONE && prefix_NONE=yes && prefix=$ac_default_prefix
test "x$exec_prefix" = xNONE && exec_prefix_NONE=yes && exec_prefix=$prefix
dnl In Autoconf 2.60, ${datadir} refers to ${datarootdir}, which in turn
dnl refers to ${prefix}. Thus we have to use `eval' twice.
eval ac_define_dir="\"[$]$2\""
eval ac_define_dir="\"$ac_define_dir\""
AC_SUBST($1, "$ac_define_dir")
AC_DEFINE_UNQUOTED($1, "$ac_define_dir", [$3])
test "$prefix_NONE" && prefix=NONE
test "$exec_prefix_NONE" && exec_prefix=NONE
])
# Copyright © 2022 Collabora Ltd
# 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 THE
# AUTHORS OR COPYRIGHT HOLDERS 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.
project('mesa-demos', 'c', 'cpp',
version : '8.5.0',
meson_version : '>= 0.53')
cc = meson.get_compiler('c')
cpp = meson.get_compiler('cpp')
null_dep = dependency('', required : false)
demos_data_dir = '../data/'
if get_option('with-system-data-files')
demos_data_dir = get_option('prefix') / get_option('datadir') / 'mesa-demos/'
endif
add_project_arguments(
'-DDEMOS_DATA_DIR="@0@"'.format(demos_data_dir),
language: 'c')
dep_m = cc.find_library('m', required : false)
dep_winmm = cc.find_library('winmm', required : false)
dep_gl = dependency('gl')
dep_gles1 = dependency('glesv1_cm', required : get_option('gles1'))
dep_gles2 = dependency('glesv2', required : get_option('gles2'))
dep_osmesa = dependency('osmesa', required : get_option('osmesa'))
dep_egl = dependency('egl', required : get_option('egl'))
dep_drm = dependency('libdrm',
required : get_option('libdrm'),
disabler : true
)
dep_x11 = dependency('x11, xext',
required : get_option('x11'),
disabler : true
)
dep_wayland = dependency('wayland-client, wayland-egl',
required : get_option('wayland'),
disabler : true
)
if dep_wayland.found()
dep_wl_scanner = dependency('wayland-scanner', native: true)
prog_wl_scanner = find_program(dep_wl_scanner.get_variable(pkgconfig : 'wayland_scanner'))
if dep_wl_scanner.version().version_compare('>= 1.15')
wl_scanner_arg = 'private-code'
else
wl_scanner_arg = 'code'
endif
dep_wl_protocols = dependency('wayland-protocols', version : '>= 1.12')
wayland_xdg_shell_xml = join_paths(
dep_wl_protocols.get_variable(pkgconfig : 'pkgdatadir'), 'stable',
'xdg-shell', 'xdg-shell.xml'
)
endif
dep_threads = dependency('threads')
dep_glu = dependency('glu', required : dep_x11.found())
if not dep_glu.found()
_glu_name = 'GLU'
if host_machine.system() == 'windows'
_glu_name = 'glu32'
endif
dep_glu = cc.find_library(_glu_name, has_headers: 'GL/glu.h')
endif
# GBM is needed for EGL on KMS
dep_gbm = dependency('gbm', required : false, disabler : true)
dep_dl = null_dep
if not cc.has_function('dlopen')
dep_dl = cc.find_library('dl', required : host_machine.system() != 'windows')
endif
glut_libdir = []
glut_incdir = []
with_glut = get_option('with-glut')
if with_glut != ''
glut_libdir = with_glut / 'lib'
glut_incdir = include_directories(with_glut / 'include', is_system: true)
_libglut = cc.find_library(
'glut',
dirs: glut_libdir,
has_headers: 'GL/glut.h',
header_include_directories: glut_incdir)
dep_glut = declare_dependency(
dependencies: _libglut,
include_directories: glut_incdir
)
else
dep_glut = cc.find_library(
'glut',
has_headers: 'GL/glut.h',
required: false
)
endif
if dep_glut.found() and cc.has_function('glutInitContextProfile',
include_directories: glut_incdir,
prefix : '#include <GL/freeglut.h>')
add_project_arguments('-DHAVE_FREEGLUT', language : ['c', 'cpp'])
endif
if host_machine.system() == 'darwin'
add_project_arguments('-DGL_SILENCE_DEPRECATION', language: 'c')
endif
if cc.get_id() == 'msvc'
c_args = [ '-D_CRT_SECURE_NO_WARNINGS' ]
c_args += cc.get_supported_arguments([
'/wd4100', # 'var': unreferenced formal parameter
'/wd4244', # conversion from 'type1' to 'type2', possible loss of data
'/wd4305', # trancation from 'type1' to 'type2'
'/wd4459', # declaration of 'var' hides global declaration
])
add_project_arguments(c_args, language: 'c')
endif
subdir('src')
option('with-glut', type : 'string')
option('egl', type : 'feature')
option('gles1', type : 'feature')
option('gles2', type : 'feature')
option('osmesa', type : 'feature')
option('libdrm', type : 'feature')
option('x11', type : 'feature')
option('wayland', type : 'feature')
option('with-system-data-files', type : 'boolean', value : false)
*.dSYM
add_subdirectory (glad)
if (GLUT_FOUND)
add_subdirectory (util)
add_subdirectory (demos)
add_subdirectory (tests)
add_subdirectory (trivial)
add_subdirectory (redbook)
add_subdirectory (samples)
add_subdirectory (perf)
add_subdirectory (objviewer)
add_subdirectory (glsl)
add_subdirectory (fp)
add_subdirectory (fpglsl)
add_subdirectory (vp)
add_subdirectory (vpglsl)
add_subdirectory (gs)
add_subdirectory (tools)
endif ()
if (EGL_FOUND)
add_subdirectory(egl)
endif ()
if (X11_FOUND)
add_subdirectory (xdemos)
endif (X11_FOUND)
if (OSMESA_FOUND)
add_subdirectory (osdemos)
endif (OSMESA_FOUND)
if (WIN32)
add_subdirectory (wgl)
endif (WIN32)
add_subdirectory (data)
# Copyright © 2009 Intel Corporation
#
# 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 (including the next
# paragraph) 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
# THE AUTHORS OR COPYRIGHT HOLDERS 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.
#
# Authors:
# Eric Anholt <eric@anholt.net>
SUBDIRS = \
glad \
util \
data \
demos \
egl \
fp \
fpglsl \
glsl \
gs \
objviewer \
osdemos \
perf \
redbook \
samples \
tests \
tools \
trivial \
vp \
vpglsl \
wgl \
xdemos
file (GLOB data *.rgb *.rgba *.dat)
install (FILES ${data} DESTINATION data)
# Copyright © 2010 Intel Corporation
#
# 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 (including the next
# paragraph) 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
# THE AUTHORS OR COPYRIGHT HOLDERS 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.
#
# Authors:
# Eric Anholt <eric@anholt.net>
demosdatadir=$(datadir)/$(PACKAGE)/
dist_demosdata_DATA= \
arch.rgb \
bw.rgb \
girl2.rgb \
girl.rgb \
reflect.rgb \
s128.rgb \
tile.rgb \
tree2.rgba \
tree3.rgb \
wrs_logo.rgb \
\
geartrain.dat \
isosurf.dat \
terrain.dat