Compare commits
6 Commits
intel_2009
...
mesa_7_1
Author | SHA1 | Date | |
---|---|---|---|
|
6d9b25e522 | ||
|
31bad23f0f | ||
|
29b9b25e72 | ||
|
e794f496c6 | ||
|
68067c66d3 | ||
|
ad5474e995 |
30
Makefile
30
Makefile
@@ -174,11 +174,10 @@ ultrix-gcc:
|
||||
|
||||
# Rules for making release tarballs
|
||||
|
||||
VERSION=7.4-rc2
|
||||
DIRECTORY = Mesa-$(VERSION)
|
||||
LIB_NAME = MesaLib-$(VERSION)
|
||||
DEMO_NAME = MesaDemos-$(VERSION)
|
||||
GLUT_NAME = MesaGLUT-$(VERSION)
|
||||
DIRECTORY = Mesa-7.1
|
||||
LIB_NAME = MesaLib-7.1
|
||||
DEMO_NAME = MesaDemos-7.1
|
||||
GLUT_NAME = MesaGLUT-7.1
|
||||
|
||||
MAIN_FILES = \
|
||||
$(DIRECTORY)/Makefile* \
|
||||
@@ -201,7 +200,9 @@ MAIN_FILES = \
|
||||
$(DIRECTORY)/docs/RELNOTES* \
|
||||
$(DIRECTORY)/docs/*.spec \
|
||||
$(DIRECTORY)/include/GL/internal/glcore.h \
|
||||
$(DIRECTORY)/include/GL/amesa.h \
|
||||
$(DIRECTORY)/include/GL/dmesa.h \
|
||||
$(DIRECTORY)/include/GL/fxmesa.h \
|
||||
$(DIRECTORY)/include/GL/ggimesa.h \
|
||||
$(DIRECTORY)/include/GL/gl.h \
|
||||
$(DIRECTORY)/include/GL/glext.h \
|
||||
@@ -216,15 +217,19 @@ MAIN_FILES = \
|
||||
$(DIRECTORY)/include/GL/mglmesa.h \
|
||||
$(DIRECTORY)/include/GL/osmesa.h \
|
||||
$(DIRECTORY)/include/GL/svgamesa.h \
|
||||
$(DIRECTORY)/include/GL/ugl*.h \
|
||||
$(DIRECTORY)/include/GL/vms_x_fix.h \
|
||||
$(DIRECTORY)/include/GL/wmesa.h \
|
||||
$(DIRECTORY)/include/GL/xmesa.h \
|
||||
$(DIRECTORY)/include/GL/xmesa_x.h \
|
||||
$(DIRECTORY)/include/GL/xmesa_xf86.h \
|
||||
$(DIRECTORY)/include/GLView.h \
|
||||
$(DIRECTORY)/src/Makefile \
|
||||
$(DIRECTORY)/src/descrip.mms \
|
||||
$(DIRECTORY)/src/mesa/Makefile* \
|
||||
$(DIRECTORY)/src/mesa/sources \
|
||||
$(DIRECTORY)/src/mesa/descrip.mms \
|
||||
$(DIRECTORY)/src/mesa/gl.pc.in \
|
||||
$(DIRECTORY)/src/mesa/osmesa.pc.in \
|
||||
$(DIRECTORY)/src/mesa/depend \
|
||||
$(DIRECTORY)/src/mesa/main/*.[chS] \
|
||||
$(DIRECTORY)/src/mesa/main/descrip.mms \
|
||||
@@ -282,8 +287,6 @@ MAIN_FILES = \
|
||||
$(DIRECTORY)/src/mesa/drivers/x11/Makefile \
|
||||
$(DIRECTORY)/src/mesa/drivers/x11/descrip.mms \
|
||||
$(DIRECTORY)/src/mesa/drivers/x11/*.[ch] \
|
||||
$(DIRECTORY)/src/mesa/drivers/glslcompiler/Makefile \
|
||||
$(DIRECTORY)/src/mesa/drivers/glslcompiler/glslcompiler.c \
|
||||
$(DIRECTORY)/src/mesa/ppc/*.[ch] \
|
||||
$(DIRECTORY)/src/mesa/sparc/*.[chS] \
|
||||
$(DIRECTORY)/src/mesa/x86/Makefile \
|
||||
@@ -299,12 +302,19 @@ MAIN_FILES = \
|
||||
$(DIRECTORY)/vms/analyze_map.com \
|
||||
$(DIRECTORY)/vms/xlib.opt \
|
||||
$(DIRECTORY)/vms/xlib_share.opt \
|
||||
$(DIRECTORY)/windows/VC8/
|
||||
$(DIRECTORY)/windows/VC8/mesa/mesa.sln \
|
||||
$(DIRECTORY)/windows/VC8/mesa/gdi/gdi.vcproj \
|
||||
$(DIRECTORY)/windows/VC8/mesa/glu/glu.vcproj \
|
||||
$(DIRECTORY)/windows/VC8/mesa/mesa/mesa.vcproj \
|
||||
$(DIRECTORY)/windows/VC8/mesa/osmesa/osmesa.vcproj \
|
||||
$(DIRECTORY)/windows/VC8/progs/progs.sln \
|
||||
$(DIRECTORY)/windows/VC8/progs/demos/gears.vcproj \
|
||||
$(DIRECTORY)/windows/VC8/progs/glut/glut.vcproj
|
||||
|
||||
|
||||
DRI_FILES = \
|
||||
$(DIRECTORY)/include/GL/internal/dri_interface.h \
|
||||
$(DIRECTORY)/include/GL/internal/glcore.h \
|
||||
$(DIRECTORY)/include/GL/internal/dri_sarea.h \
|
||||
$(DIRECTORY)/include/GL/internal/sarea.h \
|
||||
$(DIRECTORY)/src/glx/Makefile \
|
||||
$(DIRECTORY)/src/glx/x11/Makefile \
|
||||
|
52
bin/mklib
52
bin/mklib
@@ -260,31 +260,9 @@ case $ARCH in
|
||||
OPTS=${ALTOPTS}
|
||||
fi
|
||||
rm -f ${LIBNAME}
|
||||
|
||||
# expand any .a objects into constituent .o files.
|
||||
NEWOBJECTS=""
|
||||
DELETIA=""
|
||||
for OBJ in ${OBJECTS} ; do
|
||||
if [ `expr match $OBJ '.*\.a'` -gt 0 ] ; then
|
||||
# extract the .o files from this .a archive
|
||||
FILES=`ar t $OBJ`
|
||||
ar x $OBJ
|
||||
NEWOBJECTS="$NEWOBJECTS $FILES"
|
||||
# keep track of temporary .o files and delete them below
|
||||
DELETIA="$DELETIA $FILES"
|
||||
else
|
||||
# ordinary .o file
|
||||
NEWOBJECTS="$NEWOBJECTS $OBJ"
|
||||
fi
|
||||
done
|
||||
|
||||
# make lib
|
||||
${LINK} ${OPTS} ${LIBNAME} ${NEWOBJECTS}
|
||||
${LINK} ${OPTS} ${LIBNAME} ${OBJECTS}
|
||||
ranlib ${LIBNAME}
|
||||
|
||||
# remove temporary extracted .o files
|
||||
rm -f ${DELETIA}
|
||||
|
||||
# finish up
|
||||
FINAL_LIBS=${LIBNAME}
|
||||
else
|
||||
@@ -394,30 +372,6 @@ case $ARCH in
|
||||
fi
|
||||
fi
|
||||
|
||||
# If using Sun C++ compiler, need to tell it not to add runpaths
|
||||
# that are specific to the build machine
|
||||
if [ ${LINK} = "CC" ] ; then
|
||||
OPTS="${OPTS} -norunpath"
|
||||
fi
|
||||
|
||||
# Solaris linker requires explicitly listing the Standard C & C++
|
||||
# libraries in the link path when building shared objects
|
||||
if [ ${LINK} = "CC" ] ; then
|
||||
DEPS="${DEPS} -lCrun"
|
||||
fi
|
||||
DEPS="${DEPS} -lc"
|
||||
|
||||
if [ $EXPORTS ] ; then
|
||||
# Make the 'mapfile.scope' linker mapfile
|
||||
echo "{" > mapfile.scope
|
||||
echo "global:" >> mapfile.scope
|
||||
sed 's/$/;/' ${EXPORTS} >> mapfile.scope
|
||||
echo "local:" >> mapfile.scope
|
||||
echo " *;" >> mapfile.scope
|
||||
echo "};" >> mapfile.scope
|
||||
OPTS="${OPTS} -Wl,-Mmapfile.scope"
|
||||
fi
|
||||
|
||||
# Check if objects are SPARC v9
|
||||
# file says: ELF 64-bit MSB relocatable SPARCV9 Version 1
|
||||
set ${OBJECTS}
|
||||
@@ -430,19 +384,17 @@ case $ARCH in
|
||||
if [ "${ALTOPTS}" ] ; then
|
||||
OPTS=${ALTOPTS}
|
||||
fi
|
||||
|
||||
# for debug:
|
||||
#echo "mklib: linker is" ${LINK} ${OPTS}
|
||||
if [ $NOPREFIX = 1 ] ; then
|
||||
rm -f ${LIBNAME}
|
||||
${LINK} ${OPTS} ${LDFLAGS} -o ${LIBNAME} ${OBJECTS} ${DEPS}
|
||||
FINAL_LIBS="${LIBNAME}"
|
||||
else
|
||||
rm -f ${LIBNAME}.${MAJOR} ${LIBNAME}
|
||||
${LINK} ${OPTS} ${LDFLAGS} -o ${LIBNAME}.${MAJOR} -h ${LIBNAME}.${MAJOR} ${OBJECTS} ${DEPS}
|
||||
ln -s ${LIBNAME}.${MAJOR} ${LIBNAME}
|
||||
FINAL_LIBS="${LIBNAME}.${MAJOR} ${LIBNAME}"
|
||||
fi
|
||||
FINAL_LIBS="${LIBNAME}.${MAJOR} ${LIBNAME}"
|
||||
fi
|
||||
;;
|
||||
|
||||
|
@@ -105,21 +105,3 @@ DRI_DRIVER_INSTALL_DIR = @DRI_DRIVER_INSTALL_DIR@
|
||||
|
||||
# Where libGL will look for DRI hardware drivers
|
||||
DRI_DRIVER_SEARCH_DIR = $(DRI_DRIVER_INSTALL_DIR)
|
||||
|
||||
# pkg-config substitutions
|
||||
GL_PC_REQ_PRIV = @GL_PC_REQ_PRIV@
|
||||
GL_PC_LIB_PRIV = @GL_PC_LIB_PRIV@
|
||||
GL_PC_CFLAGS = @GL_PC_CFLAGS@
|
||||
DRI_PC_REQ_PRIV = @DRI_PC_REQ_PRIV@
|
||||
GLU_PC_REQ = @GLU_PC_REQ@
|
||||
GLU_PC_REQ_PRIV = @GLU_PC_REQ_PRIV@
|
||||
GLU_PC_LIB_PRIV = @GLU_PC_LIB_PRIV@
|
||||
GLU_PC_CFLAGS = @GLU_PC_CFLAGS@
|
||||
GLUT_PC_REQ_PRIV = @GLUT_PC_REQ_PRIV@
|
||||
GLUT_PC_LIB_PRIV = @GLUT_PC_LIB_PRIV@
|
||||
GLUT_PC_CFLAGS = @GLUT_PC_CFLAGS@
|
||||
GLW_PC_REQ_PRIV = @GLW_PC_REQ_PRIV@
|
||||
GLW_PC_LIB_PRIV = @GLW_PC_LIB_PRIV@
|
||||
GLW_PC_CFLAGS = @GLW_PC_CFLAGS@
|
||||
OSMESA_PC_REQ = @OSMESA_PC_REQ@
|
||||
OSMESA_PC_LIB_PRIV = @OSMESA_PC_LIB_PRIV@
|
||||
|
@@ -12,17 +12,17 @@ CXX = gcc
|
||||
PIC_FLAGS = -fPIC
|
||||
DEFINES = -D_DARWIN_C_SOURCE -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L \
|
||||
-D_BSD_SOURCE -D_SVID_SOURCE -D_GNU_SOURCE -DPTHREADS \
|
||||
-DGLX_ALIAS_UNSUPPORTED -DGLX_INDIRECT_RENDERING
|
||||
-DGLX_INDIRECT_RENDERING \
|
||||
-DGLX_ALIAS_UNSUPPORTED
|
||||
|
||||
# -DGLX_DIRECT_RENDERING - pulls in libdrm stuff in glx/x11
|
||||
# -DGLX_USE_APPLEGL - supposed to be used with GLX_DIRECT_RENDERING to use AGL rather than DRM, but doesn't compile
|
||||
# -DIN_DRI_DRIVER
|
||||
|
||||
ARCH_FLAGS += $(RC_CFLAGS)
|
||||
|
||||
CFLAGS = -ggdb3 -Os -Wall -Wmissing-prototypes -std=c99 -ffast-math -fno-strict-aliasing \
|
||||
CFLAGS = -g -O2 -Wall -Wmissing-prototypes -std=c99 -ffast-math -fno-strict-aliasing \
|
||||
-I$(INSTALL_DIR)/include $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(ASM_FLAGS) $(DEFINES)
|
||||
CXXFLAGS = -ggdb3 -Os -Wall -fno-strict-aliasing \
|
||||
CXXFLAGS = -g -O2 -Wall -fno-strict-aliasing \
|
||||
-I$(INSTALL_DIR)/include $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(ASM_FLAGS) $(DEFINES)
|
||||
|
||||
# Library names (actual file names)
|
||||
@@ -47,7 +47,7 @@ GLW_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -L$(INSTALL_DIR)/$(LIB_DIR) -lX11
|
||||
APP_LIB_DEPS = -L$(TOP)/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L$(INSTALL_DIR)/$(LIB_DIR) -lX11 -lXmu -lXt -lXi -lm
|
||||
|
||||
# omit glw lib for now:
|
||||
SRC_DIRS = glx/x11 mesa glu glut/glx
|
||||
SRC_DIRS = glx/x11 mesa glu glw glut/glx
|
||||
GLU_DIRS = sgi
|
||||
DRIVER_DIRS = osmesa
|
||||
#DRIVER_DIRS = dri
|
||||
|
@@ -9,7 +9,7 @@ CONFIG_NAME = default
|
||||
|
||||
# Version info
|
||||
MESA_MAJOR=7
|
||||
MESA_MINOR=3
|
||||
MESA_MINOR=1
|
||||
MESA_TINY=0
|
||||
MESA_VERSION = $(MESA_MAJOR).$(MESA_MINOR).$(MESA_TINY)
|
||||
|
||||
@@ -100,20 +100,3 @@ DRI_DRIVER_INSTALL_DIR = $(INSTALL_LIB_DIR)/dri
|
||||
# Where libGL will look for DRI hardware drivers
|
||||
DRI_DRIVER_SEARCH_DIR = $(DRI_DRIVER_INSTALL_DIR)
|
||||
|
||||
# pkg-config substitutions
|
||||
GL_PC_REQ_PRIV =
|
||||
GL_PC_LIB_PRIV =
|
||||
GL_PC_CFLAGS =
|
||||
DRI_PC_REQ_PRIV =
|
||||
GLU_PC_REQ = gl
|
||||
GLU_PC_REQ_PRIV =
|
||||
GLU_PC_LIB_PRIV =
|
||||
GLU_PC_CFLAGS =
|
||||
GLUT_PC_REQ_PRIV =
|
||||
GLUT_PC_LIB_PRIV =
|
||||
GLUT_PC_CFLAGS =
|
||||
GLW_PC_REQ_PRIV =
|
||||
GLW_PC_LIB_PRIV =
|
||||
GLW_PC_CFLAGS =
|
||||
OSMESA_PC_REQ =
|
||||
OSMESA_PC_LIB_PRIV =
|
||||
|
118
configure.ac
118
configure.ac
@@ -22,8 +22,8 @@ AC_CONFIG_AUX_DIR([bin])
|
||||
AC_CANONICAL_HOST
|
||||
|
||||
dnl Versions for external dependencies
|
||||
LIBDRM_REQUIRED=2.4.3
|
||||
DRI2PROTO_REQUIRED=1.99.3
|
||||
LIBDRM_REQUIRED=2.3.1
|
||||
DRI2PROTO_REQUIRED=1.1
|
||||
|
||||
dnl Check for progs
|
||||
AC_PROG_CPP
|
||||
@@ -46,14 +46,10 @@ esac
|
||||
MKDEP_OPTIONS=-fdepend
|
||||
dnl Ask gcc where it's keeping its secret headers
|
||||
if test "x$GCC" = xyes; then
|
||||
for dir in include include-fixed; do
|
||||
GCC_INCLUDES=`$CC -print-file-name=$dir`
|
||||
if test "x$GCC_INCLUDES" != x && \
|
||||
test "$GCC_INCLUDES" != "$dir" && \
|
||||
test -d "$GCC_INCLUDES"; then
|
||||
MKDEP_OPTIONS="$MKDEP_OPTIONS -I$GCC_INCLUDES"
|
||||
fi
|
||||
done
|
||||
GCC_INCLUDES=`$CC -print-file-name=include`
|
||||
if test "x$GCC_INCLUDES" != x; then
|
||||
MKDEP_OPTIONS="$MKDEP_OPTIONS -I$GCC_INCLUDES"
|
||||
fi
|
||||
fi
|
||||
AC_SUBST([MKDEP_OPTIONS])
|
||||
|
||||
@@ -87,8 +83,11 @@ dnl Compiler macros
|
||||
DEFINES=""
|
||||
AC_SUBST([DEFINES])
|
||||
case "$host_os" in
|
||||
linux*|*-gnu*)
|
||||
DEFINES="$DEFINES -D_GNU_SOURCE -DPTHREADS"
|
||||
linux*)
|
||||
if test "x$GCC" = xyes; then
|
||||
DEFINES="$DEFINES -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_BSD_SOURCE"
|
||||
fi
|
||||
DEFINES="$DEFINES -D_SVID_SOURCE -D_GNU_SOURCE -DPTHREADS"
|
||||
;;
|
||||
solaris*)
|
||||
DEFINES="$DEFINES -DPTHREADS -DSVR4"
|
||||
@@ -272,14 +271,14 @@ if test "x$enable_asm" = xyes; then
|
||||
case "$host_cpu" in
|
||||
i?86)
|
||||
case "$host_os" in
|
||||
linux* | *freebsd* | dragonfly*)
|
||||
linux* | freebsd* | dragonfly*)
|
||||
test "x$enable_64bit" = xyes && asm_arch=x86_64 || asm_arch=x86
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
x86_64)
|
||||
case "$host_os" in
|
||||
linux* | *freebsd* | dragonfly*)
|
||||
linux* | freebsd* | dragonfly*)
|
||||
test "x$enable_32bit" = xyes && asm_arch=x86 || asm_arch=x86_64
|
||||
;;
|
||||
esac
|
||||
@@ -346,6 +345,17 @@ if test "x$enable_selinux" = "xyes"; then
|
||||
DEFINES="$DEFINES -DMESA_SELINUX"
|
||||
fi
|
||||
|
||||
dnl OS-specific libraries
|
||||
OS_LIBS=""
|
||||
case "$host_os" in
|
||||
solaris*)
|
||||
OS_LIBS="-lc"
|
||||
if test "x$GXX" != xyes; then
|
||||
OS_CPLUSPLUS_LIBS="-lCrun $OS_LIBS"
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
||||
dnl
|
||||
dnl Driver configuration. Options are xlib, dri and osmesa right now.
|
||||
dnl More later: directfb, fbdev, ...
|
||||
@@ -355,10 +365,10 @@ default_driver="xlib"
|
||||
case "$host_os" in
|
||||
linux*)
|
||||
case "$host_cpu" in
|
||||
i*86|x86_64|powerpc*|sparc*) default_driver="dri";;
|
||||
i*86|x86_64|powerpc*) default_driver="dri";;
|
||||
esac
|
||||
;;
|
||||
*freebsd* | dragonfly*)
|
||||
freebsd* | dragonfly*)
|
||||
case "$host_cpu" in
|
||||
i*86|x86_64) default_driver="dri";;
|
||||
esac
|
||||
@@ -497,18 +507,14 @@ case "$mesa_driver" in
|
||||
xlib)
|
||||
if test "$x11_pkgconfig" = yes; then
|
||||
PKG_CHECK_MODULES([XLIBGL], [x11 xext])
|
||||
GL_PC_REQ_PRIV="x11 xext"
|
||||
X11_INCLUDES="$X11_INCLUDES $XLIBGL_CFLAGS"
|
||||
GL_LIB_DEPS="$XLIBGL_LIBS"
|
||||
else
|
||||
# should check these...
|
||||
X11_INCLUDES="$X11_INCLUDES $X_CFLAGS"
|
||||
GL_LIB_DEPS="$X_LIBS -lX11 -lXext"
|
||||
GL_PC_LIB_PRIV="$GL_LIB_DEPS"
|
||||
GL_PC_CFLAGS="$X11_INCLUDES"
|
||||
fi
|
||||
GL_LIB_DEPS="$GL_LIB_DEPS $SELINUX_LIBS -lm -lpthread"
|
||||
GL_PC_LIB_PRIV="$GL_PC_LIB_PRIV $SELINUX_LIBS -lm -lpthread"
|
||||
GL_LIB_DEPS="$GL_LIB_DEPS $SELINUX_LIBS -lm -lpthread $OS_LIBS"
|
||||
|
||||
# if static, move the external libraries to the programs
|
||||
# and empty the libraries for libGL
|
||||
@@ -526,8 +532,6 @@ dri)
|
||||
# Check for libdrm
|
||||
PKG_CHECK_MODULES([LIBDRM], [libdrm >= $LIBDRM_REQUIRED])
|
||||
PKG_CHECK_MODULES([DRI2PROTO], [dri2proto >= $DRI2PROTO_REQUIRED])
|
||||
GL_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED dri2proto >= $DRI2PROTO_REQUIRED"
|
||||
DRI_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED"
|
||||
|
||||
# find the DRI deps for libGL
|
||||
if test "$x11_pkgconfig" = yes; then
|
||||
@@ -538,39 +542,30 @@ dri)
|
||||
fi
|
||||
|
||||
PKG_CHECK_MODULES([DRIGL], [$dri_modules])
|
||||
GL_PC_REQ_PRIV="$GL_PC_REQ_PRIV $dri_modules"
|
||||
X11_INCLUDES="$X11_INCLUDES $DRIGL_CFLAGS"
|
||||
GL_LIB_DEPS="$DRIGL_LIBS"
|
||||
else
|
||||
# should check these...
|
||||
X11_INCLUDES="$X11_INCLUDES $X_CFLAGS"
|
||||
GL_LIB_DEPS="$X_LIBS -lX11 -lXext -lXxf86vm -lXdamage -lXfixes"
|
||||
GL_PC_LIB_PRIV="$GL_LIB_DEPS"
|
||||
GL_PC_CFLAGS="$X11_INCLUDES"
|
||||
|
||||
# XCB can only be used from pkg-config
|
||||
if test "$enable_xcb" = yes; then
|
||||
PKG_CHECK_MODULES([XCB],[x11-xcb xcb-glx])
|
||||
GL_PC_REQ_PRIV="$GL_PC_REQ_PRIV x11-xcb xcb-glx"
|
||||
X11_INCLUDES="$X11_INCLUDES $XCB_CFLAGS"
|
||||
GL_LIB_DEPS="$GL_LIB_DEPS $XCB_LIBS"
|
||||
fi
|
||||
fi
|
||||
|
||||
# need DRM libs, -lpthread, etc.
|
||||
GL_LIB_DEPS="$GL_LIB_DEPS $LIBDRM_LIBS -lm -lpthread $DLOPEN_LIBS"
|
||||
GL_PC_LIB_PRIV="-lm -lpthread $DLOPEN_LIBS"
|
||||
GL_LIB_DEPS="$GL_LIB_DEPS $LIBDRM_LIBS -lm -lpthread $DLOPEN_LIBS $OS_LIBS"
|
||||
;;
|
||||
osmesa)
|
||||
# No libGL for osmesa
|
||||
GL_LIB_DEPS=""
|
||||
GL_LIB_DEPS="$OS_LIBS"
|
||||
;;
|
||||
esac
|
||||
AC_SUBST([GL_LIB_DEPS])
|
||||
AC_SUBST([GL_PC_REQ_PRIV])
|
||||
AC_SUBST([GL_PC_LIB_PRIV])
|
||||
AC_SUBST([GL_PC_CFLAGS])
|
||||
AC_SUBST([DRI_PC_REQ_PRIV])
|
||||
|
||||
dnl
|
||||
dnl More X11 setup
|
||||
@@ -600,6 +595,20 @@ AC_ARG_ENABLE([driglx-direct],
|
||||
[enable direct rendering in GLX for DRI @<:@default=enabled@:>@])],
|
||||
[driglx_direct="$enableval"],
|
||||
[driglx_direct="yes"])
|
||||
dnl ttm support
|
||||
AC_ARG_ENABLE([ttm-api],
|
||||
[AS_HELP_STRING([--enable-ttm-api],
|
||||
[enable TTM API users @<:@default=disabled@:>@])],
|
||||
[ttmapi="$enableval"],
|
||||
[ttmapi="no"])
|
||||
|
||||
if test "x$ttmapi" = "xyes"; then
|
||||
save_CFLAGS=$CFLAGS
|
||||
CFLAGS=$LIBDRM_CFLAGS
|
||||
AC_CHECK_HEADERS([xf86mm.h],[],[AC_MSG_ERROR([xf86mm.h required for TTM.])],[#include "stdint.h"\n#include "drm.h"])
|
||||
CFLAGS=$save_CFLAGS
|
||||
fi
|
||||
|
||||
dnl Which drivers to build - default is chosen by platform
|
||||
AC_ARG_WITH([dri-drivers],
|
||||
[AS_HELP_STRING([--with-dri-drivers@<:@=DIRS...@:>@],
|
||||
@@ -641,6 +650,10 @@ if test "$mesa_driver" = dri; then
|
||||
DEFINES="$DEFINES -DGLX_USE_TLS -DPTHREADS"
|
||||
fi
|
||||
|
||||
if test "x$ttmapi" = xyes; then
|
||||
DEFINES="$DEFINES -DTTM_API"
|
||||
fi
|
||||
|
||||
if test "x$USING_EGL" = x1; then
|
||||
PROGRAM_DIRS="egl"
|
||||
fi
|
||||
@@ -791,7 +804,6 @@ osmesa)
|
||||
OSMESA_LIB_DEPS=""
|
||||
fi
|
||||
OSMESA_MESA_DEPS=""
|
||||
OSMESA_PC_LIB_PRIV="-lm -lpthread $SELINUX_LIBS"
|
||||
;;
|
||||
*)
|
||||
# Link OSMesa to libGL otherwise
|
||||
@@ -802,17 +814,13 @@ osmesa)
|
||||
else
|
||||
OSMESA_MESA_DEPS=""
|
||||
fi
|
||||
OSMESA_PC_REQ="gl"
|
||||
;;
|
||||
esac
|
||||
if test "$enable_static" = no; then
|
||||
OSMESA_LIB_DEPS="$OSMESA_LIB_DEPS"
|
||||
OSMESA_LIB_DEPS="$OSMESA_LIB_DEPS $OS_LIBS"
|
||||
fi
|
||||
OSMESA_PC_LIB_PRIV="$OSMESA_PC_LIB_PRIV"
|
||||
AC_SUBST([OSMESA_LIB_DEPS])
|
||||
AC_SUBST([OSMESA_MESA_DEPS])
|
||||
AC_SUBST([OSMESA_PC_REQ])
|
||||
AC_SUBST([OSMESA_PC_LIB_PRIV])
|
||||
|
||||
dnl
|
||||
dnl GLU configuration
|
||||
@@ -835,7 +843,6 @@ if test "x$enable_glu" = xyes; then
|
||||
|
||||
# Link libGLU to libOSMesa instead of libGL
|
||||
GLU_LIB_DEPS=""
|
||||
GLU_PC_REQ="osmesa"
|
||||
if test "$enable_static" = no; then
|
||||
GLU_MESA_DEPS='-l$(OSMESA_LIB)'
|
||||
else
|
||||
@@ -844,8 +851,6 @@ if test "x$enable_glu" = xyes; then
|
||||
;;
|
||||
*)
|
||||
# If static, empty GLU_LIB_DEPS and add libs for programs to link
|
||||
GLU_PC_REQ="gl"
|
||||
GLU_PC_LIB_PRIV="-lm"
|
||||
if test "$enable_static" = no; then
|
||||
GLU_LIB_DEPS="-lm"
|
||||
GLU_MESA_DEPS='-l$(GL_LIB)'
|
||||
@@ -860,13 +865,8 @@ fi
|
||||
if test "$enable_static" = no; then
|
||||
GLU_LIB_DEPS="$GLU_LIB_DEPS $OS_CPLUSPLUS_LIBS"
|
||||
fi
|
||||
GLU_PC_LIB_PRIV="$GLU_PC_LIB_PRIV $OS_CPLUSPLUS_LIBS"
|
||||
AC_SUBST([GLU_LIB_DEPS])
|
||||
AC_SUBST([GLU_MESA_DEPS])
|
||||
AC_SUBST([GLU_PC_REQ])
|
||||
AC_SUBST([GLU_PC_REQ_PRIV])
|
||||
AC_SUBST([GLU_PC_LIB_PRIV])
|
||||
AC_SUBST([GLU_PC_CFLAGS])
|
||||
|
||||
dnl
|
||||
dnl GLw configuration
|
||||
@@ -891,13 +891,10 @@ if test "x$enable_glw" = xyes; then
|
||||
SRC_DIRS="$SRC_DIRS glw"
|
||||
if test "$x11_pkgconfig" = yes; then
|
||||
PKG_CHECK_MODULES([GLW],[x11 xt])
|
||||
GLW_PC_REQ_PRIV="x11 xt"
|
||||
GLW_LIB_DEPS="$GLW_LIBS"
|
||||
else
|
||||
# should check these...
|
||||
GLW_LIB_DEPS="$X_LIBS -lXt -lX11"
|
||||
GLW_PC_LIB_PRIV="$GLW_LIB_DEPS"
|
||||
GLW_PC_CFLAGS="$X11_INCLUDES"
|
||||
fi
|
||||
|
||||
GLW_SOURCES="GLwDrawA.c"
|
||||
@@ -916,15 +913,12 @@ if test "x$enable_glw" = xyes; then
|
||||
fi
|
||||
# MOTIF_LIBS is prepended to GLW_LIB_DEPS since Xm needs Xt/X11
|
||||
GLW_LIB_DEPS="$MOTIF_LIBS $GLW_LIB_DEPS"
|
||||
GLW_PC_LIB_PRIV="$MOTIF_LIBS $GLW_PC_LIB_PRIV"
|
||||
GLW_PC_CFLAGS="$MOTIF_CFLAGS $GLW_PC_CFLAGS"
|
||||
fi
|
||||
|
||||
# If static, empty GLW_LIB_DEPS and add libs for programs to link
|
||||
GLW_PC_LIB_PRIV="$GLW_PC_LIB_PRIV"
|
||||
if test "$enable_static" = no; then
|
||||
GLW_MESA_DEPS='-l$(GL_LIB)'
|
||||
GLW_LIB_DEPS="$GLW_LIB_DEPS"
|
||||
GLW_LIB_DEPS="$GLW_LIB_DEPS $OS_LIBS"
|
||||
else
|
||||
APP_LIB_DEPS="$APP_LIB_DEPS $GLW_LIB_DEPS"
|
||||
GLW_LIB_DEPS=""
|
||||
@@ -935,9 +929,6 @@ AC_SUBST([GLW_LIB_DEPS])
|
||||
AC_SUBST([GLW_MESA_DEPS])
|
||||
AC_SUBST([GLW_SOURCES])
|
||||
AC_SUBST([MOTIF_CFLAGS])
|
||||
AC_SUBST([GLW_PC_REQ_PRIV])
|
||||
AC_SUBST([GLW_PC_LIB_PRIV])
|
||||
AC_SUBST([GLW_PC_CFLAGS])
|
||||
|
||||
dnl
|
||||
dnl GLUT configuration
|
||||
@@ -972,16 +963,12 @@ if test "x$enable_glut" = xyes; then
|
||||
fi
|
||||
if test "$x11_pkgconfig" = yes; then
|
||||
PKG_CHECK_MODULES([GLUT],[x11 xmu xi])
|
||||
GLUT_PC_REQ_PRIV="x11 xmu xi"
|
||||
GLUT_LIB_DEPS="$GLUT_LIBS"
|
||||
else
|
||||
# should check these...
|
||||
GLUT_LIB_DEPS="$X_LIBS -lX11 -lXmu -lXi"
|
||||
GLUT_PC_LIB_PRIV="$GLUT_LIB_DEPS"
|
||||
GLUT_PC_CFLAGS="$X11_INCLUDES"
|
||||
fi
|
||||
GLUT_LIB_DEPS="$GLUT_LIB_DEPS -lm"
|
||||
GLUT_PC_LIB_PRIV="$GLUT_PC_LIB_PRIV -lm"
|
||||
GLUT_LIB_DEPS="$GLUT_LIB_DEPS -lm $OS_LIBS"
|
||||
|
||||
# If glut is available, we can build most programs
|
||||
if test "$with_demos" = yes; then
|
||||
@@ -1000,9 +987,6 @@ fi
|
||||
AC_SUBST([GLUT_LIB_DEPS])
|
||||
AC_SUBST([GLUT_MESA_DEPS])
|
||||
AC_SUBST([GLUT_CFLAGS])
|
||||
AC_SUBST([GLUT_PC_REQ_PRIV])
|
||||
AC_SUBST([GLUT_PC_LIB_PRIV])
|
||||
AC_SUBST([GLUT_PC_CFLAGS])
|
||||
|
||||
dnl
|
||||
dnl Program library dependencies
|
||||
@@ -1066,8 +1050,8 @@ else
|
||||
echo " DRI drivers: $dri_dirs"
|
||||
fi
|
||||
echo " DRI driver dir: $DRI_DRIVER_INSTALL_DIR"
|
||||
echo " TTM API support: $ttmapi"
|
||||
fi
|
||||
echo " Use XCB: $enable_xcb"
|
||||
|
||||
dnl Libraries
|
||||
echo ""
|
||||
|
@@ -16,7 +16,7 @@ Status
|
||||
|
||||
Version
|
||||
|
||||
Last Modified Date: 12 January 2009
|
||||
Last Modified Date: 8 June 2000
|
||||
|
||||
Number
|
||||
|
||||
@@ -69,12 +69,6 @@ Additions to Chapter 3 of the GLX 1.3 Specification (Functions and Errors)
|
||||
<width> and <height> indicate the size in pixels. Coordinate (0,0)
|
||||
corresponds to the lower-left pixel of the window, like glReadPixels.
|
||||
|
||||
If dpy and drawable are the display and drawable for the calling
|
||||
thread's current context, glXCopySubBufferMESA performs an
|
||||
implicit glFlush before it returns. Subsequent OpenGL commands
|
||||
may be issued immediately after calling glXCopySubBufferMESA, but
|
||||
are not executed until the copy is completed.
|
||||
|
||||
GLX Protocol
|
||||
|
||||
None at this time. The extension is implemented in terms of ordinary
|
||||
@@ -90,7 +84,5 @@ New State
|
||||
|
||||
Revision History
|
||||
|
||||
12 January 2009 Ian Romanick - Added language about implicit flush
|
||||
and command completion.
|
||||
8 June 2000 Brian Paul - initial specification
|
||||
8 June 2000 - initial specification
|
||||
|
||||
|
@@ -16,6 +16,7 @@ Status
|
||||
|
||||
Version
|
||||
|
||||
$Id: MESA_resize_buffers.spec,v 1.3 2004/03/25 01:42:42 brianp Exp $
|
||||
|
||||
Number
|
||||
|
||||
|
@@ -19,6 +19,7 @@ Version
|
||||
|
||||
Last Modified Date: July 30, 2006
|
||||
Author Revision: 0.2
|
||||
$Date: 2006/07/30 14:28:38 $ $Revision: 1.2 $
|
||||
|
||||
Number
|
||||
|
||||
|
@@ -20,6 +20,7 @@ Status
|
||||
|
||||
Version
|
||||
|
||||
$Date: 2007/05/16$ $Revision: 0.4$
|
||||
|
||||
Number
|
||||
|
||||
|
@@ -16,6 +16,7 @@ Status
|
||||
|
||||
Version
|
||||
|
||||
$Id: MESA_window_pos.spec,v 1.4 2004/03/25 01:42:42 brianp Exp $
|
||||
|
||||
Number
|
||||
|
||||
|
@@ -17,6 +17,7 @@ Status
|
||||
|
||||
Version
|
||||
|
||||
$Id: MESA_packed_depth_stencil.spec,v 1.2 2003/09/19 14:58:21 brianp Exp $
|
||||
|
||||
Number
|
||||
|
||||
|
@@ -18,6 +18,7 @@ Version
|
||||
|
||||
Last Modified Date: July 20, 2003
|
||||
Author Revision: 1.0
|
||||
$Date: 2004/03/25 01:42:41 $ $Revision: 1.4 $
|
||||
|
||||
Number
|
||||
|
||||
|
@@ -16,6 +16,7 @@ Status
|
||||
|
||||
Version
|
||||
|
||||
$Id: MESA_sprite_point.spec,v 1.2 2003/09/19 14:58:21 brianp Exp $
|
||||
|
||||
Number
|
||||
|
||||
|
@@ -17,6 +17,7 @@ Status
|
||||
|
||||
Version
|
||||
|
||||
$Id: MESA_trace.spec,v 1.4 2004/03/25 01:42:42 brianp Exp $
|
||||
|
||||
Number
|
||||
|
||||
|
@@ -134,3 +134,4 @@ as of February, 1999.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: README.BEOS,v 1.12 2004/10/13 00:35:55 phoudoin Exp $
|
||||
|
@@ -205,3 +205,4 @@ http://www.linuxgames.com/quake2/
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: README.QUAKE,v 1.3 1998/08/23 15:26:26 brianp Exp $
|
||||
|
@@ -143,3 +143,4 @@ code). Anyone want to help?
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-3.1,v 1.2 2000/04/07 17:08:06 brianp Exp $
|
||||
|
@@ -9,3 +9,4 @@ have been added. For a list of bug fixes please read the VERSIONS file.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-3.2,v 1.2 2000/04/07 17:08:06 brianp Exp $
|
||||
|
@@ -29,3 +29,4 @@ GLU library.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-3.2.1,v 1.2 2000/07/21 16:32:33 brianp Exp $
|
||||
|
@@ -268,3 +268,4 @@ image convolution. This will (hopefully) be done for Mesa 3.5/3.6.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-3.3,v 1.8 2000/07/21 16:26:41 brianp Exp $
|
||||
|
@@ -19,3 +19,4 @@ see the VERSIONS file.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-3.4,v 1.2 2002/03/23 02:37:17 brianp Exp $
|
||||
|
@@ -19,3 +19,4 @@ the Mesa 3.4 release. For details, see the VERSIONS file.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-3.4.1,v 1.2 2001/05/23 14:45:01 brianp Exp $
|
||||
|
@@ -19,3 +19,4 @@ the Mesa 3.4.1 release. For details, see the VERSIONS file.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-3.4.2,v 1.2 2001/05/23 14:45:01 brianp Exp $
|
||||
|
@@ -225,3 +225,4 @@ In the future I hope to implement support for 32-bit, floating point
|
||||
color channels.
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-3.5,v 1.14 2001/06/20 19:02:48 brianp Exp $
|
||||
|
@@ -160,3 +160,4 @@ See the VERSIONS file for more details about bug fixes, etc. in Mesa 4.0.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-4.0,v 3.2 2001/10/17 14:59:21 brianp Exp $
|
||||
|
@@ -19,3 +19,4 @@ Mesa 4.0.1 only contains bug fixes since version 4.0.
|
||||
See the docs/VERSIONS file for the list of bug fixes.
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-4.0.1,v 1.2 2001/12/18 14:08:23 brianp Exp $
|
||||
|
@@ -47,3 +47,4 @@ D3D needs updating
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-4.0.2,v 1.2 2002/03/23 02:38:39 brianp Exp $
|
||||
|
@@ -49,3 +49,4 @@ D3D needs updating
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-4.0.3,v 1.2 2002/06/26 02:36:34 brianp Exp $
|
||||
|
@@ -305,3 +305,4 @@ are some things to change:
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-4.1,v 1.22 2002/10/29 15:06:37 brianp Exp $
|
||||
|
@@ -82,3 +82,4 @@ driver call the _mesa_enable_1_4_extensions() function.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-5.0,v 3.2 2002/11/13 15:33:51 brianp Exp $
|
||||
|
@@ -43,3 +43,4 @@ driver call the _mesa_enable_1_4_extensions() function.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-5.0.1,v 3.1 2003/03/30 16:17:54 brianp Exp $
|
||||
|
@@ -43,3 +43,4 @@ driver call the _mesa_enable_1_4_extensions() function.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-5.0.2,v 1.1 2003/09/04 23:10:38 brianp Exp $
|
||||
|
@@ -84,3 +84,4 @@ See the VERSIONS file for more details about bug fixes, etc. in Mesa 6.0.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.0,v 1.3 2004/01/15 15:47:57 brianp Exp $
|
||||
|
@@ -47,3 +47,4 @@ D3D needs updating
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.0.1,v 3.1 2004/04/02 23:37:02 brianp Exp $
|
||||
|
@@ -109,3 +109,4 @@ See the VERSIONS file for more details about bug fixes, etc. in Mesa 6.1.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.1,v 3.5 2004/08/17 22:58:23 brianp Exp $
|
||||
|
@@ -49,3 +49,4 @@ D3D needs updating
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.2,v 3.4 2004/10/02 15:43:14 brianp Exp $
|
||||
|
@@ -47,3 +47,4 @@ D3D needs updating
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.2.1,v 3.1 2004/12/09 23:21:36 brianp Exp $
|
||||
|
@@ -112,3 +112,4 @@ D3D needs updating
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.3,v 3.13 2005/07/21 15:57:29 brianp Exp $
|
||||
|
@@ -46,3 +46,4 @@ D3D needs updating
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.3.1,v 3.1 2005/07/21 18:45:54 brianp Exp $
|
||||
|
@@ -34,3 +34,4 @@ D3D needs updating
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.3.2,v 3.2 2005/08/19 16:57:50 brianp Exp $
|
||||
|
@@ -47,3 +47,4 @@ in Mesa 6.3.
|
||||
|
||||
|
||||
----------------------------------------------------------------------
|
||||
$Id: RELNOTES-6.4,v 3.1 2005/10/24 23:33:27 brianp Exp $
|
||||
|
@@ -6,7 +6,7 @@
|
||||
|
||||
<BODY>
|
||||
|
||||
<H1>Mesa/Gallium Cell Driver</H1>
|
||||
<H1>Mesa Cell Driver</H1>
|
||||
|
||||
<p>
|
||||
The Mesa
|
||||
@@ -23,19 +23,18 @@ Two phases are planned.
|
||||
First, to implement the framework for parallel rasterization using the Cell
|
||||
SPEs, including texture mapping.
|
||||
Second, to implement a full-featured OpenGL driver with support for GLSL, etc.
|
||||
The second phase is now underway.
|
||||
</p>
|
||||
|
||||
|
||||
<H2>Source Code</H2>
|
||||
|
||||
<p>
|
||||
The latest Cell driver source code is on the <code>gallium-0.2</code> branch
|
||||
of the Mesa git repository.
|
||||
The Cell driver source code is on the <code>gallium-0.1</code> branch of the
|
||||
git repository.
|
||||
After you've cloned the repository, check out the branch with:
|
||||
</p>
|
||||
<pre>
|
||||
git-checkout -b gallium-0.2 origin/gallium-0.2
|
||||
git-checkout -b gallium-0.1 origin/gallium-0.1
|
||||
</pre>
|
||||
<p>
|
||||
To build the driver you'll need the IBM Cell SDK (version 2.1 or 3.0).
|
||||
@@ -44,13 +43,12 @@ or the Cell Simulator (untested, though).
|
||||
</p>
|
||||
|
||||
<p>
|
||||
If using Cell SDK 2.1, see the configs/linux-cell file for some
|
||||
special changes.
|
||||
If using Cell SDK 3.0, first edit configs/linux-cell and add
|
||||
<code>-DSPU_MAIN_PARAM_LONG_LONG</code> to the SPU_CFLAGS.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
To compile the code, run <code>make linux-cell</code>.
|
||||
To build in debug mode, run <code>make linux-cell-debug</code>.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
@@ -62,7 +60,7 @@ directory that contains <code>libGL.so</code>.
|
||||
Verify that the Cell driver is being used by running <code>glxinfo</code>
|
||||
and looking for:
|
||||
<pre>
|
||||
OpenGL renderer string: Gallium 0.2, Cell on Xlib
|
||||
OpenGL renderer string: Gallium 0.1, Cell on Xlib
|
||||
</pre>
|
||||
|
||||
|
||||
@@ -79,61 +77,21 @@ SPU local store as needed.
|
||||
Similarly, textures are tiled and brought into local store as needed.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
More recently, vertex transformation has been parallelized across the SPUs
|
||||
as well.
|
||||
</p>
|
||||
|
||||
|
||||
<H2>Status</H2>
|
||||
|
||||
<p>
|
||||
As of October 2008, the driver runs quite a few OpenGL demos.
|
||||
Features that work include:
|
||||
As of February 2008 the driver supports smooth/flat shaded triangle rendering
|
||||
with Z testing and simple texture mapping.
|
||||
Simple demos like gears run successfully.
|
||||
To test texture mapping, try progs/demos/texcyl (press right mouse button for
|
||||
rendering options).
|
||||
</p>
|
||||
<ul>
|
||||
<li>Point/line/triangle rendering, glDrawPixels
|
||||
<li>2D, NPOT and cube texture maps with nearest/linear/mipmap filtering
|
||||
<li>Dynamic SPU code generation for fragment shaders, but not complete
|
||||
<li>Dynamic SPU code generation for fragment ops (blend, Z-test, etc), but not complete
|
||||
<li>Dynamic PPU/PPC code generation for vertex shaders, but not complete
|
||||
</ul>
|
||||
<p>
|
||||
Performance has recently improved with the addition of PPC code generation
|
||||
for vertex shaders, but the code quality isn't too great yet.
|
||||
</p>
|
||||
<p>
|
||||
Another bottleneck is SwapBuffers. It may be the limiting factor for
|
||||
many simple GL tests.
|
||||
</p>
|
||||
|
||||
|
||||
|
||||
<H2>Debug Options</H2>
|
||||
|
||||
<p>
|
||||
The CELL_DEBUG env var can be set to a comma-separated list of one or
|
||||
more of the following debug options:
|
||||
</p>
|
||||
<ul>
|
||||
<li><b>checker</b> - use a different background clear color for each SPU.
|
||||
This lets you see which SPU is rendering which screen tiles.
|
||||
<li><b>sync</b> - wait/synchronize after each DMA transfer
|
||||
<li><b>asm</b> - print generated SPU assembly code to stdout
|
||||
<li><b>fragops</b> - emit fragment ops debug messages
|
||||
<li><b>fragopfallback</b> - don't use codegen for fragment ops
|
||||
<li><b>cmd</b> - print SPU commands as their received
|
||||
<li><b>cache</b> - print texture cache statistics when program exits
|
||||
</ul>
|
||||
<p>
|
||||
Note that some of these options may only work for linux-cell-debug builds.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
If the GALLIUM_NOPPC env var is set, PPC code generation will not be used
|
||||
and vertex shaders will be run with the TGSI interpreter.
|
||||
</p>
|
||||
<p>
|
||||
If the GALLIUM_NOCELL env var is set, the softpipe driver will be used
|
||||
intead of the Cell driver.
|
||||
This is useful for comparison/validation.
|
||||
</p>
|
||||
|
||||
|
||||
|
||||
<H2>Contributing</H2>
|
||||
|
@@ -37,8 +37,8 @@ a:visited {
|
||||
|
||||
<b>Download / Install</b>
|
||||
<ul>
|
||||
<li><a href="download.html" target="MainFrame">Downloading / Unpacking</a>
|
||||
<li><a href="install.html" target="MainFrame">Compiling / Installing</a>
|
||||
<li><a href="download.html" target="MainFrame">Downloading/Unpacking</a>
|
||||
<li><a href="install.html" target="MainFrame">Compilation/Installation</a>
|
||||
<li><a href="glu.html" target="MainFrame">SGI's GLU</a>
|
||||
<li><a href="precompiled.html" target="MainFrame">Precompiled Libraries</a>
|
||||
</ul>
|
||||
@@ -48,7 +48,7 @@ a:visited {
|
||||
<li><a href="lists.html" target="MainFrame">Mailing Lists</a>
|
||||
<li><a href="bugs.html" target="MainFrame">Bug Database</a>
|
||||
<li><a href="webmaster.html" target="MainFrame">Webmaster</a>
|
||||
<li><a href="http://dri.freedesktop.org/" target="_parent">Mesa/DRI Wiki</a>
|
||||
<li><a href="http://dri.freedesktop.org/" target="MainFrame">Wiki</a>
|
||||
</ul>
|
||||
|
||||
<b>User Topics</b>
|
||||
|
@@ -9,9 +9,9 @@
|
||||
<H1>Downloading</H1>
|
||||
|
||||
<p>
|
||||
Current stable release: <b>7.4</b>
|
||||
Current development release: <b>7.1</b>
|
||||
<br>
|
||||
Last unstable/development release: <b>7.3</b>
|
||||
Last stable release: <b>7.0.4</b>
|
||||
</p>
|
||||
|
||||
<p>
|
||||
|
@@ -29,7 +29,7 @@ Setting this variable automatically sets the MESA_TEX_PROG variable as well.
|
||||
|
||||
<p>
|
||||
The following are only applicable to the Xlib software driver.
|
||||
See the <A HREF="xlibdriver.html">Xlib software driver page</A> for details.
|
||||
See <A HREF="README.X11">README.X11</A> for details.
|
||||
</p>
|
||||
<ul>
|
||||
<li>MESA_RGB_VISUAL - specifies the X visual and depth for RGB mode
|
||||
|
@@ -15,40 +15,17 @@ Here are some specific ideas and areas where help would be appreciated:
|
||||
|
||||
<ol>
|
||||
<li>
|
||||
<b>Driver patching and testing.</b>
|
||||
Patches are often posted to the mesa3d-dev mailing list, but aren't
|
||||
immediately checked into git because not enough people are testing them.
|
||||
Just applying patches, testing and reporting back is helpful.
|
||||
<li>
|
||||
<b>Driver debugging.</b>
|
||||
There are plenty of open bugs in the bug database.
|
||||
<li>
|
||||
<b>Remove aliasing warnings.</b>
|
||||
Enable gcc -Wstrict-aliasing=2 -fstrict-aliasing and track down aliasing
|
||||
Enable -Wstrict-aliasing=2 -fstrict-aliasing and track down aliasing
|
||||
issues in the code.
|
||||
<li>
|
||||
<b>Windows driver building, testing and maintenance.</b>
|
||||
The Visual Studio project files aren't always updated in a timely manner
|
||||
when new source files are added or old ones are removed.
|
||||
Fixing these tends to delay new Mesa releases.
|
||||
Windows 98/NT driver building, maintenance and testing
|
||||
<li>
|
||||
<b>Maintenance and testing of lesser-used drivers.</b>
|
||||
Drivers such as DOS/DJGPP, GGI, etc that aren't being maintained are being
|
||||
deprecated starting in Mesa 7.3.
|
||||
<li>
|
||||
<b>Contribute more tests to
|
||||
<a href="http://glean.sourceforge.net/" target="_parent">glean</a>.</b>
|
||||
<li>
|
||||
<b>Automatic testing.
|
||||
</b>
|
||||
It would be great if someone would set up an automated system for grabbing
|
||||
the latest Mesa code and run tests (such as glean) then report issues to
|
||||
the mailing list.
|
||||
Maintenance and testing of lesser-used drivers, such as DOS/DJGPP, GGI, etc.
|
||||
</ol>
|
||||
|
||||
|
||||
<p>
|
||||
If you want to do something new in Mesa, first join the Mesa developer's
|
||||
If you want to help with Mesa, first join the Mesa developer's
|
||||
mailing list.
|
||||
Then post a message to propose what you want to do, just to make sure
|
||||
there's no issues.
|
||||
|
@@ -1,73 +1,58 @@
|
||||
<HTML>
|
||||
|
||||
<TITLE>Compiling and Installing</TITLE>
|
||||
<TITLE>Compilation and Installation</TITLE>
|
||||
|
||||
<link rel="stylesheet" type="text/css" href="mesa.css"></head>
|
||||
|
||||
<BODY>
|
||||
|
||||
|
||||
<H1>Compiling and Installing</H1>
|
||||
<H1>Compilation and Installation</H1>
|
||||
|
||||
<ol>
|
||||
<li><a href="#unix-x11">Unix / X11</a>
|
||||
<ul>
|
||||
<li><a href="#prereq">Prerequisites for DRI and hardware acceleration</a>
|
||||
<li><a href="#autoconf">Building with autoconf</a>
|
||||
<li><a href="#traditional">Building with traditional Makefiles</a>
|
||||
<li><a href="#libs">The Libraries</a>
|
||||
<li><a href="#demos">Running the demos
|
||||
<li><a href="#install">Installing the header and library files
|
||||
<li><a href="#pkg-config">Building OpenGL programs with pkg-config
|
||||
</ul>
|
||||
<li><a href="#windows">Windows</a>
|
||||
<li><a href="#vms">VMS</a>
|
||||
<li><a href="#other">Other</a>
|
||||
</ol>
|
||||
<br>
|
||||
|
||||
|
||||
|
||||
<a name="unix-x11">
|
||||
<H2>1. Unix/X11 Compilation and Installation</H1>
|
||||
|
||||
|
||||
<a name="prereq">
|
||||
<h3>1.1 Prerequisites for DRI and hardware acceleration</h3>
|
||||
<h3>1.1 Prerequisites for DRI and Hardware Acceleration</h3>
|
||||
|
||||
<p>
|
||||
The following are required for DRI-based hardware acceleration with Mesa 7.3:
|
||||
To build Mesa 7.1 with DRI-based hardware acceleration you must first have
|
||||
the <a href="http://dri.freedesktop.org/libdrm/" target="_parent">DRM version 2.3.1</a>.
|
||||
</p>
|
||||
|
||||
<ul>
|
||||
<li><a href="http://xorg.freedesktop.org/releases/individual/proto/">dri2proto</a> version 1.99.3 or later
|
||||
<li>Linux 2.6.28
|
||||
<li><a href="http://dri.freedesktop.org/libdrm/" target="_parent">libDRM</a>
|
||||
version 2.4.3 or later
|
||||
<li>Xorg server version 1.5 or later
|
||||
</ul>
|
||||
<p>
|
||||
You should also be using the Xorg server version 1.4 or 1.5.
|
||||
</p>
|
||||
|
||||
|
||||
<a name="autoconf">
|
||||
<h3>1.2 Building with Autoconf</h3>
|
||||
|
||||
<h3>1.2 Autoconf Compilation</h3>
|
||||
|
||||
<p>
|
||||
Mesa may be <a href="autoconf.html">built using autoconf</a>.
|
||||
This should work well on most GNU-based systems.
|
||||
If that fails the traditional Mesa build system is available.
|
||||
When that fails, the traditional Mesa build system is available.
|
||||
|
||||
|
||||
|
||||
<a name="traditional">
|
||||
<h3>1.3 Building with traditional Makefiles</h3>
|
||||
<h3>1.3 Traditional Compilation</h3>
|
||||
|
||||
<p>
|
||||
The traditional Mesa build system is based on a collection of pre-defined
|
||||
system configurations.
|
||||
</p>
|
||||
<p>
|
||||
To see the list of configurations, just type <code>make</code>.
|
||||
Then choose a configuration from the list and type <code>make</code>
|
||||
<em>configname</em>.
|
||||
To see the list of configurations, type <b>make</b> alone.
|
||||
Then choose a configuration from the list and type <b>make configname</b>.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
@@ -81,7 +66,7 @@ allow you to run OpenGL/GLX applications on any X server (regardless of
|
||||
whether it supports the GLX X server extension).
|
||||
You will <em>not</em> be able to use hardware 3D acceleration.
|
||||
<p>
|
||||
To compile stand-alone Mesa type <code>make</code> in the top-level directory.
|
||||
To compile stand-alone Mesa type <b>make</b> in the top-level directory.
|
||||
You'll see a list of supported system configurations.
|
||||
Choose one from the list (such as linux-x86), and type:
|
||||
</p>
|
||||
@@ -124,7 +109,6 @@ Later, if you want to rebuild for a different configuration run
|
||||
</p>
|
||||
|
||||
|
||||
<a name="libs">
|
||||
<h3>1.4 The libraries</h3>
|
||||
|
||||
<p>
|
||||
@@ -185,7 +169,6 @@ If you built the DRI hardware drivers, you'll also see the DRI drivers:
|
||||
</pre>
|
||||
|
||||
|
||||
<a name="demos">
|
||||
<h3>1.5 Running the demos</h3>
|
||||
|
||||
<p>
|
||||
@@ -261,7 +244,6 @@ Retrace your steps if this doesn't look right.
|
||||
</p>
|
||||
|
||||
|
||||
<a name="install">
|
||||
<H3>1.6 Installing the header and library files</H3>
|
||||
|
||||
<p>
|
||||
@@ -302,8 +284,7 @@ This is a handy way to compare multiple OpenGL implementations.
|
||||
</p>
|
||||
|
||||
|
||||
<a name="pkg-config">
|
||||
<H3>1.7 Building OpenGL programs with pkg-config</H3>
|
||||
<H3>1.7 Building OpenGL Programs With pkg-config</H3>
|
||||
|
||||
<p>
|
||||
Running <code>make install</code> will install package configuration files
|
||||
@@ -333,15 +314,25 @@ Please see the <a href="README.WIN32">README.WIN32</a> file.
|
||||
|
||||
|
||||
|
||||
|
||||
<a name="vms">
|
||||
<H2>3. VMS Compilation and Installation</H1>
|
||||
|
||||
<p>
|
||||
Please see the <a href="README.VMS">README.VMS</a> file.
|
||||
</p>
|
||||
|
||||
|
||||
|
||||
|
||||
<a name="other">
|
||||
<H2>3. Other systems</H1>
|
||||
<H2>4. Other systems</H1>
|
||||
|
||||
<p>
|
||||
Documentation for other environments (some may be very out of date):
|
||||
</p>
|
||||
|
||||
<UL>
|
||||
<li><A HREF="README.VMS">README.VMS</A> - VMS
|
||||
<LI><A HREF="README.GGI">README.GGI</A> - GGI
|
||||
<LI><A HREF="README.3DFX">README.3DFX</A> - 3Dfx/Glide driver
|
||||
<LI><A HREF="README.AMIWIN">README.AMIWIN</A> - Amiga Amiwin
|
||||
|
@@ -11,28 +11,6 @@
|
||||
<H1>News</H1>
|
||||
|
||||
|
||||
<h2>March ??, 2009</h2>
|
||||
<p>
|
||||
<a href="relnotes-7.4.html">Mesa 7.4</a> is released.
|
||||
This is a stable release fixing bugs since the 7.3 release.
|
||||
</p>
|
||||
|
||||
|
||||
<h2>January 22, 2009</h2>
|
||||
<p>
|
||||
<a href="relnotes-7.3.html">Mesa 7.3</a> is released.
|
||||
This is a new development release.
|
||||
Mesa 7.4 will follow and will have bug fixes relative to 7.3.
|
||||
</p>
|
||||
|
||||
|
||||
<h2>September 20, 2008</h2>
|
||||
<p>
|
||||
<a href="relnotes-7.2.html">Mesa 7.2</a> is released.
|
||||
This is a stable, bug-fix release.
|
||||
</p>
|
||||
|
||||
|
||||
<h2>August 26, 2008</h2>
|
||||
<p>
|
||||
<a href="relnotes-7.1.html">Mesa 7.1</a> is released.
|
||||
@@ -1202,5 +1180,6 @@ source code</a>.</p>
|
||||
|
||||
|
||||
<hr>
|
||||
$Id: news.html,v 3.33 2006/12/02 18:18:41 brianp Exp $
|
||||
</body>
|
||||
</html>
|
||||
|
@@ -28,15 +28,7 @@ DRM version 2.3.1 should be used with Mesa 7.1
|
||||
|
||||
<h2>MD5 checksums</h2>
|
||||
<pre>
|
||||
971c2fe6e6949dc5ba200a6f97a6dc81 MesaLib-7.1.tar.gz
|
||||
6bff7f532d16f90f944a400c8bd7074d MesaLib-7.1.tar.bz2
|
||||
d48224bf9d54c3da6776adb4869ba024 MesaLib-7.1.zip
|
||||
3de268420efca43e9a19ab506cdfc993 MesaDemos-7.1.tar.gz
|
||||
abfc9775e1462363af8ec160d1feb01f MesaDemos-7.1.tar.bz2
|
||||
f7b3623387c4036e9895cd9ac0dfad99 MesaDemos-7.1.zip
|
||||
fdf348f78cd09304b6ff801ef8acc8eb MesaGLUT-7.1.tar.gz
|
||||
f6d88a4eeb02e98c7e92f1c895d3c76b MesaGLUT-7.1.tar.bz2
|
||||
4dc102a5ca51e1c41dde87d3f8c7b22a MesaGLUT-7.1.zip
|
||||
TBD
|
||||
</pre>
|
||||
|
||||
|
||||
|
@@ -1,104 +0,0 @@
|
||||
<HTML>
|
||||
|
||||
<TITLE>Mesa Release Notes</TITLE>
|
||||
|
||||
<head><link rel="stylesheet" type="text/css" href="mesa.css"></head>
|
||||
|
||||
<BODY>
|
||||
|
||||
<body bgcolor="#eeeeee">
|
||||
|
||||
<H1>Mesa 7.2 Release Notes / 20 September 2008</H1>
|
||||
|
||||
<p>
|
||||
Mesa 7.2 is a stable release fixing bugs found in 7.1, which was a
|
||||
new development release.
|
||||
</p>
|
||||
<p>
|
||||
Mesa 7.2 implements the OpenGL 2.1 API, but the version reported by
|
||||
glGetString(GL_VERSION) depends on the particular driver being used.
|
||||
Some drivers don't support all the features required in OpenGL 2.1.
|
||||
</p>
|
||||
<p>
|
||||
Note that this version of Mesa does not use the GEM memory manager.
|
||||
The master branch of git uses GEM.
|
||||
The prototype DRI2 code that was in 7.1 has also been removed.
|
||||
</p>
|
||||
<p>
|
||||
DRM version 2.3.1 should be used with Mesa 7.2
|
||||
</p>
|
||||
|
||||
|
||||
<h2>MD5 checksums</h2>
|
||||
<pre>
|
||||
81a2a4b7cbfce7553f7ad8d924edbe2f MesaLib-7.2.tar.gz
|
||||
04d379292e023df0b0266825cb0dbde5 MesaLib-7.2.tar.bz2
|
||||
8bc497a37977a55e987a4d1fabc3d882 MesaLib-7.2.zip
|
||||
10c762e39486df395838af1d7b57e69c MesaDemos-7.2.tar.gz
|
||||
22e03dc4038cd63f32c21eb60994892b MesaDemos-7.2.tar.bz2
|
||||
1197bc4eb3bf44e291c14d4eb2e19381 MesaDemos-7.2.zip
|
||||
42e3c6c6d156cd9dc545dbef72407354 MesaGLUT-7.2.tar.gz
|
||||
f67daf93e12c4a459703bbf3e4004e31 MesaGLUT-7.2.tar.bz2
|
||||
0390567eb2c2d12fbf82e8523fd77e2b MesaGLUT-7.2.zip
|
||||
</pre>
|
||||
|
||||
|
||||
<h2>New features</h2>
|
||||
<ul>
|
||||
<li>i965 driver: added support for G41 chipset (Intel)
|
||||
</ul>
|
||||
|
||||
|
||||
<h2>Bug fixes</h2>
|
||||
<ul>
|
||||
<li>Fixed display list bug involving primitives split across lists (bug 17564)
|
||||
<li>Fixed some issues with glBindAttribLocation()
|
||||
<li>Fixed crash in _tnl_InvalidateState() found with Amira (bug 15834)
|
||||
<li>Assorted bug fixes for Ming build
|
||||
<li>Fixed some vertex/pixel buffer object reference counting bugs
|
||||
<li>Fixed depth/stencil bug in i915/945 driver
|
||||
<li>Fixed some shader flow control bugs in i965 driver
|
||||
<li>Fixed a few tdfx driver bugs which prevented driver from working
|
||||
<li>Fixed multisample enable/disable bug
|
||||
</ul>
|
||||
|
||||
<h2>Changes</h2>
|
||||
<ul>
|
||||
<li>Updated SGI header files with new license terms.
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
<h2>To Do (someday) items</h2>
|
||||
<ul>
|
||||
<li>Remove the MEMCPY() and _mesa_memcpy() wrappers and just use memcpy().
|
||||
Probably do the same for malloc, calloc, etc.
|
||||
The wrappers were useful in the past for memory debugging but now we
|
||||
have valgrind. Not worried about SunOS 4 support anymore either...
|
||||
<li>Switch to freeglut
|
||||
<li>Fix linux-glide target/driver.
|
||||
<li>Improved lambda and derivative calculation for frag progs.
|
||||
</ul>
|
||||
|
||||
|
||||
<h2>Driver Status</h2>
|
||||
|
||||
<pre>
|
||||
Driver Status
|
||||
---------------------- ----------------------
|
||||
DRI drivers varies with the driver
|
||||
XMesa/GLX (on Xlib) implements OpenGL 2.1
|
||||
OSMesa (off-screen) implements OpenGL 2.1
|
||||
Windows/Win32 implements OpenGL 2.1
|
||||
Glide (3dfx Voodoo1/2) implements OpenGL 1.3
|
||||
SVGA unsupported
|
||||
Wind River UGL unsupported
|
||||
DJGPP unsupported
|
||||
GGI unsupported
|
||||
BeOS unsupported
|
||||
Allegro unsupported
|
||||
D3D unsupported
|
||||
</pre>
|
||||
|
||||
</body>
|
||||
</html>
|
@@ -1,93 +0,0 @@
|
||||
<HTML>
|
||||
|
||||
<TITLE>Mesa Release Notes</TITLE>
|
||||
|
||||
<head><link rel="stylesheet" type="text/css" href="mesa.css"></head>
|
||||
|
||||
<BODY>
|
||||
|
||||
<body bgcolor="#eeeeee">
|
||||
|
||||
<H1>Mesa 7.3 Release Notes / 22 January 2009</H1>
|
||||
|
||||
<p>
|
||||
Mesa 7.3 is a new development release.
|
||||
Users especially concerned with stability should stick with latest
|
||||
stable release: version 7.2.
|
||||
</p>
|
||||
<p>
|
||||
Mesa 7.3 implements the OpenGL 2.1 API, but the version reported by
|
||||
glGetString(GL_VERSION) depends on the particular driver being used.
|
||||
Some drivers don't support all the features required in OpenGL 2.1.
|
||||
</p>
|
||||
<p>
|
||||
See the <a href="install.html">Compiling/Installing page</a> for prerequisites
|
||||
for DRI hardware acceleration.
|
||||
</p>
|
||||
|
||||
|
||||
<h2>MD5 checksums</h2>
|
||||
<pre>
|
||||
8ed03191432b22d118d88d6db497f304 MesaLib-7.3.tar.gz
|
||||
781e7811a6ed5c97b2b8defefc8ffbc9 MesaLib-7.3.tar.bz2
|
||||
3ccba9a1734ed6d4b3389e1535d90fbf MesaLib-7.3.zip
|
||||
d312e974b31043b13b61bac5fbf00b87 MesaDemos-7.3.tar.gz
|
||||
3f0741394069bdf2329565a387396cda MesaDemos-7.3.tar.bz2
|
||||
4d0887fd4c66a824295cdd619f6d34cb MesaDemos-7.3.zip
|
||||
2d7661b66022bcb8878728f3d5bd33ab MesaGLUT-7.3.tar.gz
|
||||
abe8036a724c1a483bdad6b5a55ddc1a MesaGLUT-7.3.tar.bz2
|
||||
5f247819b47e2a7c62d07a6afe5262fb MesaGLUT-7.3.zip
|
||||
</pre>
|
||||
|
||||
|
||||
<h2>New features</h2>
|
||||
<ul>
|
||||
<li>Support for GLSL 1.20
|
||||
<li>Intel DRI drivers now use GEM and DRI2
|
||||
</ul>
|
||||
|
||||
|
||||
<h2>Bug fixes</h2>
|
||||
<ul>
|
||||
<li>Assorted GLSL bug fixes
|
||||
<li>Assorted i965 driver fixes
|
||||
<li>Fix for wglCreateLayerContext() in WGL/Windows driver
|
||||
<li>Build fixes for OpenBSD and gcc 2.95
|
||||
<li>GLSL preprocessor handles #pragma now
|
||||
<li>Fix incorrect transformation of GL_SPOT_DIRECTION
|
||||
<li>Fixed several bugs (#18367 and #19625) in glXMakeContextCurrent()
|
||||
<li>Assorted Windows build fixes
|
||||
</ul>
|
||||
|
||||
<h2>Changes</h2>
|
||||
<ul>
|
||||
<li>Deprecated the "XMesa" interface (include/GL/xmesa*.h files)
|
||||
<li>Deprecated the "FXMesa" interface (include/GL/fxmesa.h file)
|
||||
<li>Deprecated the "Allegro" interface (include/GL/amesa.h file)
|
||||
<li>Removed include/GL/uglmesa.h header
|
||||
<li>Removed include/GLView.h header for BeOS
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
<h2>Driver Status</h2>
|
||||
|
||||
<pre>
|
||||
Driver Status
|
||||
---------------------- ----------------------
|
||||
DRI drivers varies with the driver
|
||||
XMesa/GLX (on Xlib) implements OpenGL 2.1
|
||||
OSMesa (off-screen) implements OpenGL 2.1
|
||||
Windows/Win32 implements OpenGL 2.1
|
||||
Glide (3dfx Voodoo1/2) implements OpenGL 1.3
|
||||
SVGA unsupported
|
||||
Wind River UGL unsupported
|
||||
DJGPP unsupported
|
||||
GGI unsupported
|
||||
BeOS unsupported
|
||||
Allegro unsupported
|
||||
D3D unsupported
|
||||
</pre>
|
||||
|
||||
</body>
|
||||
</html>
|
@@ -1,81 +0,0 @@
|
||||
<HTML>
|
||||
|
||||
<TITLE>Mesa Release Notes</TITLE>
|
||||
|
||||
<head><link rel="stylesheet" type="text/css" href="mesa.css"></head>
|
||||
|
||||
<BODY>
|
||||
|
||||
<body bgcolor="#eeeeee">
|
||||
|
||||
<H1>Mesa 7.4 Release Notes / date TBD</H1>
|
||||
|
||||
<p>
|
||||
Mesa 7.4 is a stable development release fixing bugs since the 7.3 release.
|
||||
</p>
|
||||
<p>
|
||||
Mesa 7.4 implements the OpenGL 2.1 API, but the version reported by
|
||||
glGetString(GL_VERSION) depends on the particular driver being used.
|
||||
Some drivers don't support all the features required in OpenGL 2.1.
|
||||
</p>
|
||||
<p>
|
||||
See the <a href="install.html">Compiling/Installing page</a> for prerequisites
|
||||
for DRI ardware acceleration.
|
||||
</p>
|
||||
|
||||
|
||||
<h2>MD5 checksums</h2>
|
||||
<pre>
|
||||
tbd
|
||||
</pre>
|
||||
|
||||
|
||||
<h2>New features</h2>
|
||||
<ul>
|
||||
<li>Added MESA_GLX_FORCE_DIRECT env var for Xlib/software driver
|
||||
<li>GLSL version 1.20 is returnd by the GL_SHADING_LANGUAGE_VERSION query
|
||||
</ul>
|
||||
|
||||
|
||||
<h2>Bug fixes</h2>
|
||||
<ul>
|
||||
<li>glGetActiveUniform() returned wrong size for some array types
|
||||
<li>Fixed some error checking in glUniform()
|
||||
<li>Fixed a potential glTexImage('proxy target') segfault
|
||||
<li>Fixed bad reference counting for 1D/2D texture arrays
|
||||
<li>Fixed VBO + glPush/PopClientAttrib() bug #19835
|
||||
<li>Assorted i965 driver bug fixes
|
||||
<li>Fixed a Windows compilation failure in s_triangle.c
|
||||
<li>Fixed a GLSL array indexing bug
|
||||
<li>Fixes for building on Haiku
|
||||
</ul>
|
||||
|
||||
<h2>Changes</h2>
|
||||
<ul>
|
||||
<li>Updated GL/glxext.h to version 48
|
||||
<li>Assorted updates for building on Solaris
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
<h2>Driver Status</h2>
|
||||
|
||||
<pre>
|
||||
Driver Status
|
||||
---------------------- ----------------------
|
||||
DRI drivers varies with the driver
|
||||
XMesa/GLX (on Xlib) implements OpenGL 2.1
|
||||
OSMesa (off-screen) implements OpenGL 2.1
|
||||
Windows/Win32 implements OpenGL 2.1
|
||||
Glide (3dfx Voodoo1/2) implements OpenGL 1.3
|
||||
SVGA unsupported
|
||||
Wind River UGL unsupported
|
||||
DJGPP unsupported
|
||||
GGI unsupported
|
||||
BeOS unsupported
|
||||
Allegro unsupported
|
||||
D3D unsupported
|
||||
</pre>
|
||||
|
||||
</body>
|
||||
</html>
|
@@ -20,9 +20,6 @@ The release notes summarize what's new or changed in each Mesa release.
|
||||
</p>
|
||||
|
||||
<UL>
|
||||
<LI><A HREF="relnotes-7.4.html">7.4 release notes</A>
|
||||
<LI><A HREF="relnotes-7.3.html">7.3 release notes</A>
|
||||
<LI><A HREF="relnotes-7.2.html">7.2 release notes</A>
|
||||
<LI><A HREF="relnotes-7.1.html">7.1 release notes</A>
|
||||
<LI><A HREF="relnotes-7.0.4.html">7.0.4 release notes</A>
|
||||
<LI><A HREF="relnotes-7.0.3.html">7.0.3 release notes</A>
|
||||
|
@@ -15,46 +15,23 @@ OpenGL Shading Language</a>.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Last updated on 15 December 2008.
|
||||
Last updated on 28 March 2007.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Contents
|
||||
</p>
|
||||
<ul>
|
||||
<li><a href="#120">GLSL 1.20 support</a>
|
||||
<li><a href="#unsup">Unsupported Features</a>
|
||||
<li><a href="#notes">Implementation Notes</a>
|
||||
<li><a href="#hints">Programming Hints</a>
|
||||
<li><a href="#standalone">Stand-alone GLSL Compiler</a>
|
||||
<li><a href="#implementation">Compiler Implementation</a>
|
||||
<li><a href="#validation">Compiler Validation</a>
|
||||
<li><a href="#120">GLSL 1.20 support</a>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
<a name="120">
|
||||
<h2>GLSL 1.20 support</h2>
|
||||
|
||||
<p>
|
||||
GLSL version 1.20 is supported in Mesa 7.3.
|
||||
Among the features/differences of GLSL 1.20 are:
|
||||
<ul>
|
||||
<li><code>mat2x3, mat2x4</code>, etc. types and functions
|
||||
<li><code>transpose(), outerProduct(), matrixCompMult()</code> functions
|
||||
(but untested)
|
||||
<li>precision qualifiers (lowp, mediump, highp)
|
||||
<li><code>invariant</code> qualifier
|
||||
<li><code>array.length()</code> method
|
||||
<li><code>float[5] a;</code> array syntax
|
||||
<li><code>centroid</code> qualifier
|
||||
<li>unsized array constructors
|
||||
<li>initializers for uniforms
|
||||
<li>const initializers calling built-in functions
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
<a name="unsup">
|
||||
<h2>Unsupported Features</h2>
|
||||
|
||||
@@ -64,10 +41,15 @@ in Mesa:
|
||||
</p>
|
||||
|
||||
<ul>
|
||||
<li>Dereferencing arrays with non-constant indexes
|
||||
<li>Comparison of user-defined structs
|
||||
<li>Linking of multiple shaders is not supported
|
||||
<li>gl_ClipVertex
|
||||
<li>The derivative functions such as dFdx() are not implemented
|
||||
<li>The inverse trig functions asin(), acos(), and atan() are not implemented
|
||||
<li>The gl_Color and gl_SecondaryColor varying vars are interpolated
|
||||
without perspective correction
|
||||
<li>Floating point literal suffixes 'f' and 'F' aren't allowed.
|
||||
</ul>
|
||||
|
||||
<p>
|
||||
@@ -322,11 +304,11 @@ Extra NOP instructions will also be inserted.
|
||||
<h2>Compiler Validation</h2>
|
||||
|
||||
<p>
|
||||
A <a href="http://glean.sf.net" target="_parent">Glean</a> test has
|
||||
A new <a href="http://glean.sf.net" target="_parent">Glean</a> test has
|
||||
been create to exercise the GLSL compiler.
|
||||
</p>
|
||||
<p>
|
||||
The <em>glsl1</em> test runs over 170 sub-tests to check that the language
|
||||
The <em>glsl1</em> test runs over 150 sub-tests to check that the language
|
||||
features and built-in functions work properly.
|
||||
This test should be run frequently while working on the compiler to catch
|
||||
regressions.
|
||||
@@ -337,5 +319,39 @@ should be added.
|
||||
</p>
|
||||
|
||||
|
||||
|
||||
<a name="120">
|
||||
<h2>GLSL 1.20 support</h2>
|
||||
|
||||
<p>
|
||||
Support for GLSL version 1.20 is underway. Status as follows.
|
||||
</p>
|
||||
|
||||
<h3>Supported</h3>
|
||||
<ul>
|
||||
<li><code>mat2x3, mat2x4</code>, etc. types and functions
|
||||
<li><code>transpose(), outerProduct(), matrixCompMult()</code> functions
|
||||
(but untested)
|
||||
<li>precision qualifiers (lowp, mediump, highp)
|
||||
</ul>
|
||||
|
||||
<h3>Partially Complete</h3>
|
||||
<ul>
|
||||
<li><code>invariant</code> qualifier
|
||||
</ul>
|
||||
|
||||
<h3>Not Completed</h3>
|
||||
<ul>
|
||||
<li><code>array.length()</code> method
|
||||
<li><code>float[5] a;</code> array syntax
|
||||
<li><code>centroid</code> qualifier
|
||||
<li>unsized array constructors
|
||||
<li>initializers for uniforms
|
||||
<li>const initializers calling built-in functions
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
</BODY>
|
||||
</HTML>
|
||||
|
@@ -27,27 +27,16 @@ the Amiga, Apple Macintosh, BeOS, NeXT, OS/2, MS-DOS, VMS, Windows
|
||||
</p>
|
||||
|
||||
<p>
|
||||
Details about particular drivers follows:
|
||||
Details about particular drivers follows.
|
||||
Be warned that some drivers may be out of date and no longer function.
|
||||
</p>
|
||||
|
||||
<UL>
|
||||
<li><a href="http://dri.freedesktop.org/" target="_parent"> DRI hardware
|
||||
drivers</a> for the X Window System
|
||||
<LI><a href="xlibdriver.html">Xlib software driver</a> for the X Window System
|
||||
and Unix-like operating systems
|
||||
<LI><a href="xlibdriver.html">Xlib driver</a> for the X Window System
|
||||
<li><a href="http://dri.freedesktop.org/" target="_parent">
|
||||
DRI hardware drivers</a> for the X window system
|
||||
<LI>Microsoft Windows <A HREF="README.WIN32">(README.WIN32)</A>
|
||||
<LI>DEC VMS <A HREF="README.VMS">(README.VMS)</A>
|
||||
</UL>
|
||||
|
||||
|
||||
<h2>Deprecated Systems</h2>
|
||||
|
||||
<p>
|
||||
These drivers have not been maintained and are being deprecated.
|
||||
They can be saved if someone steps up to help.
|
||||
</p>
|
||||
|
||||
<UL>
|
||||
<LI>3dfx/Glide <A HREF="README.3DFX">(README.3DFX)</A>
|
||||
<LI>GGI <A HREF="README.GGI">(README.GGI)</A>
|
||||
<LI>Amiga Amiwin <A HREF="README.AMIWIN">(README.AMIWIN)</A>
|
||||
@@ -60,10 +49,6 @@ They can be saved if someone steps up to help.
|
||||
<LI>OpenStep <A HREF="README.OpenStep">(README.OpenStep)</A>
|
||||
<LI>OS/2 <A HREF="README.OS2">(README.OS2)</A>
|
||||
<LI>WindML <A HREF="README.WINDML">(README.WINDML)</A>
|
||||
</UL>
|
||||
|
||||
And for historical reference:
|
||||
<UL>
|
||||
<LI><a href="http://utah-glx.sourceforge.net/" target="_parent">Utah GLX drivers</a>
|
||||
</UL>
|
||||
|
||||
|
@@ -11,7 +11,7 @@
|
||||
<p>
|
||||
If you have problems, edits or additions for this website send them
|
||||
to Brian
|
||||
(<em>b</em><em>r</em><em>i</em><em>a</em><em>n</em><em>.</em><em>e</em><em>.</em><em>p</em><em>a</em><em>u</em><em>l</em><em> </em><em>g</em><em>m</em><em>a</em><em>i</em><em>l</em><em>.</em><em>c</em><em>o</em><em>m</em>)</a>.
|
||||
(<em>b</em><em>r</em><em>i</em><em>a</em><em>n</em><em>_</em><em>e</em><em>_</em><em>p</em><em>a</em><em>u</em><em>l</em><em>@</em><em>y</em><em>a</em><em>h</em><em>o</em><em>o</em><em>.</em><em>c</em><em>o</em><em>m</em>)</a>.
|
||||
</p>
|
||||
|
||||
<p>
|
||||
@@ -21,4 +21,4 @@ Brian's modified it a lot since then.
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
@@ -169,20 +169,6 @@ the Gamma FAQ</a>
|
||||
</p>
|
||||
|
||||
|
||||
<H2>Direct Rendering Flag</H2>
|
||||
<p>
|
||||
Some applications won't run with indirect rendering contexts (which is
|
||||
what the Xlib driver supports).
|
||||
To force the glXIsDirect() query to return True, set the MESA_GLX_FORCE_DIRECT
|
||||
environment variable.
|
||||
For example:
|
||||
</p>
|
||||
<pre>
|
||||
$ export MESA_GLX_FORCE_DIRECT=1
|
||||
</pre>
|
||||
|
||||
|
||||
|
||||
<H2>Overlay Planes</H2>
|
||||
<p>
|
||||
Hardware overlay planes are supported by the Xlib driver. To
|
||||
@@ -282,8 +268,6 @@ This extension was added in Mesa 2.6
|
||||
MESA_BACK_BUFFER - specifies how to implement the back color buffer (X only)
|
||||
MESA_PRIVATE_CMAP - force aux/tk libraries to use private colormaps (X only)
|
||||
MESA_GAMMA - gamma correction coefficients (X only)
|
||||
MESA_GLX_FORCE_DIRECT - report that the driver is direct rendering, even
|
||||
though it's not.
|
||||
</pre>
|
||||
|
||||
|
||||
|
@@ -2,12 +2,17 @@
|
||||
|
||||
GLincludedir = $(includedir)/GL
|
||||
|
||||
INC_FX = fxmesa.h
|
||||
INC_GGI = ggimesa.h
|
||||
INC_OSMESA = osmesa.h
|
||||
INC_SVGA = svgamesa.h
|
||||
INC_X11 = glx.h glxext.h glx_mangle.h
|
||||
INC_X11 = glx.h glxext.h glx_mangle.h xmesa.h xmesa_x.h xmesa_xf86.h
|
||||
INC_GLUT = glut.h glutf90.h
|
||||
|
||||
if HAVE_FX
|
||||
sel_inc_fx = $(INC_FX)
|
||||
endif
|
||||
|
||||
if HAVE_GGI
|
||||
sel_inc_ggi = $(INC_GGI)
|
||||
endif
|
||||
@@ -30,9 +35,9 @@ endif
|
||||
|
||||
EXTRA_HEADERS = amesa.h dosmesa.h foomesa.h glut_h.dja mesa_wgl.h mglmesa.h \
|
||||
vms_x_fix.h wmesa.h \
|
||||
$(INC_GGI) $(INC_OSMESA) $(INC_SVGA) $(INC_X11) $(INC_GLUT)
|
||||
$(INC_FX) $(INC_GGI) $(INC_OSMESA) $(INC_SVGA) $(INC_X11) $(INC_GLUT)
|
||||
|
||||
GLinclude_HEADERS = gl.h glext.h gl_mangle.h glu.h glu_mangle.h \
|
||||
$(sel_inc_ggi) $(sel_inc_osmesa) $(sel_inc_svga) \
|
||||
$(sel_inc_fx) $(sel_inc_ggi) $(sel_inc_osmesa) $(sel_inc_svga) \
|
||||
$(sel_inc_x11) $(sel_inc_glut)
|
||||
include $(top_srcdir)/common_rules.make
|
||||
|
@@ -1,6 +1,6 @@
|
||||
/*
|
||||
* Mesa 3-D graphics library
|
||||
* Version: 7.4
|
||||
* Version: 6.5.1
|
||||
*
|
||||
* Copyright (C) 1999-2006 Brian Paul All Rights Reserved.
|
||||
*
|
||||
|
@@ -48,49 +48,34 @@
|
||||
#define glAsyncMarkerSGIX MANGLE(AsyncMarkerSGIX)
|
||||
#define glAttachObjectARB MANGLE(AttachObjectARB)
|
||||
#define glAttachShader MANGLE(AttachShader)
|
||||
#define glBeginConditionalRender MANGLE(BeginConditionalRender)
|
||||
#define glBeginConditionalRenderNV MANGLE(BeginConditionalRenderNV)
|
||||
#define glBeginFragmentShaderATI MANGLE(BeginFragmentShaderATI)
|
||||
#define glBegin MANGLE(Begin)
|
||||
#define glBeginOcclusionQueryNV MANGLE(BeginOcclusionQueryNV)
|
||||
#define glBeginQueryARB MANGLE(BeginQueryARB)
|
||||
#define glBeginQuery MANGLE(BeginQuery)
|
||||
#define glBeginTransformFeedbackEXT MANGLE(BeginTransformFeedbackEXT)
|
||||
#define glBeginTransformFeedback MANGLE(BeginTransformFeedback)
|
||||
#define glBeginTransformFeedbackNV MANGLE(BeginTransformFeedbackNV)
|
||||
#define glBeginVertexShaderEXT MANGLE(BeginVertexShaderEXT)
|
||||
#define glBindAttribLocationARB MANGLE(BindAttribLocationARB)
|
||||
#define glBindAttribLocation MANGLE(BindAttribLocation)
|
||||
#define glBindBufferARB MANGLE(BindBufferARB)
|
||||
#define glBindBufferBaseEXT MANGLE(BindBufferBaseEXT)
|
||||
#define glBindBufferBase MANGLE(BindBufferBase)
|
||||
#define glBindBufferBaseNV MANGLE(BindBufferBaseNV)
|
||||
#define glBindBuffer MANGLE(BindBuffer)
|
||||
#define glBindBufferOffsetEXT MANGLE(BindBufferOffsetEXT)
|
||||
#define glBindBufferOffsetNV MANGLE(BindBufferOffsetNV)
|
||||
#define glBindBufferRangeEXT MANGLE(BindBufferRangeEXT)
|
||||
#define glBindBufferRange MANGLE(BindBufferRange)
|
||||
#define glBindBufferRangeNV MANGLE(BindBufferRangeNV)
|
||||
#define glBindFragDataLocationEXT MANGLE(BindFragDataLocationEXT)
|
||||
#define glBindFragDataLocation MANGLE(BindFragDataLocation)
|
||||
#define glBindFragmentShaderATI MANGLE(BindFragmentShaderATI)
|
||||
#define glBindFramebufferEXT MANGLE(BindFramebufferEXT)
|
||||
#define glBindFramebuffer MANGLE(BindFramebuffer)
|
||||
#define glBindLightParameterEXT MANGLE(BindLightParameterEXT)
|
||||
#define glBindMaterialParameterEXT MANGLE(BindMaterialParameterEXT)
|
||||
#define glBindMultiTextureEXT MANGLE(BindMultiTextureEXT)
|
||||
#define glBindParameterEXT MANGLE(BindParameterEXT)
|
||||
#define glBindProgramARB MANGLE(BindProgramARB)
|
||||
#define glBindProgramNV MANGLE(BindProgramNV)
|
||||
#define glBindRenderbufferEXT MANGLE(BindRenderbufferEXT)
|
||||
#define glBindRenderbuffer MANGLE(BindRenderbuffer)
|
||||
#define glBindTexGenParameterEXT MANGLE(BindTexGenParameterEXT)
|
||||
#define glBindTextureEXT MANGLE(BindTextureEXT)
|
||||
#define glBindTexture MANGLE(BindTexture)
|
||||
#define glBindTextureUnitParameterEXT MANGLE(BindTextureUnitParameterEXT)
|
||||
#define glBindTransformFeedbackNV MANGLE(BindTransformFeedbackNV)
|
||||
#define glBindVertexArrayAPPLE MANGLE(BindVertexArrayAPPLE)
|
||||
#define glBindVertexArray MANGLE(BindVertexArray)
|
||||
#define glBindVertexShaderEXT MANGLE(BindVertexShaderEXT)
|
||||
#define glBinormal3bEXT MANGLE(Binormal3bEXT)
|
||||
#define glBinormal3bvEXT MANGLE(Binormal3bvEXT)
|
||||
@@ -116,7 +101,6 @@
|
||||
#define glBlendFuncSeparateINGR MANGLE(BlendFuncSeparateINGR)
|
||||
#define glBlendFuncSeparate MANGLE(BlendFuncSeparate)
|
||||
#define glBlitFramebufferEXT MANGLE(BlitFramebufferEXT)
|
||||
#define glBlitFramebuffer MANGLE(BlitFramebuffer)
|
||||
#define glBufferDataARB MANGLE(BufferDataARB)
|
||||
#define glBufferData MANGLE(BufferData)
|
||||
#define glBufferParameteriAPPLE MANGLE(BufferParameteriAPPLE)
|
||||
@@ -125,15 +109,8 @@
|
||||
#define glCallList MANGLE(CallList)
|
||||
#define glCallLists MANGLE(CallLists)
|
||||
#define glCheckFramebufferStatusEXT MANGLE(CheckFramebufferStatusEXT)
|
||||
#define glCheckFramebufferStatus MANGLE(CheckFramebufferStatus)
|
||||
#define glCheckNamedFramebufferStatusEXT MANGLE(CheckNamedFramebufferStatusEXT)
|
||||
#define glClampColorARB MANGLE(ClampColorARB)
|
||||
#define glClampColor MANGLE(ClampColor)
|
||||
#define glClearAccum MANGLE(ClearAccum)
|
||||
#define glClearBufferfi MANGLE(ClearBufferfi)
|
||||
#define glClearBufferfv MANGLE(ClearBufferfv)
|
||||
#define glClearBufferiv MANGLE(ClearBufferiv)
|
||||
#define glClearBufferuiv MANGLE(ClearBufferuiv)
|
||||
#define glClearColorIiEXT MANGLE(ClearColorIiEXT)
|
||||
#define glClearColorIuiEXT MANGLE(ClearColorIuiEXT)
|
||||
#define glClearColor MANGLE(ClearColor)
|
||||
@@ -146,7 +123,6 @@
|
||||
#define glClientActiveTextureARB MANGLE(ClientActiveTextureARB)
|
||||
#define glClientActiveTexture MANGLE(ClientActiveTexture)
|
||||
#define glClientActiveVertexStreamATI MANGLE(ClientActiveVertexStreamATI)
|
||||
#define glClientAttribDefaultEXT MANGLE(ClientAttribDefaultEXT)
|
||||
#define glClipPlane MANGLE(ClipPlane)
|
||||
#define glColor3b MANGLE(Color3b)
|
||||
#define glColor3bv MANGLE(Color3bv)
|
||||
@@ -195,7 +171,6 @@
|
||||
#define glColorFragmentOp1ATI MANGLE(ColorFragmentOp1ATI)
|
||||
#define glColorFragmentOp2ATI MANGLE(ColorFragmentOp2ATI)
|
||||
#define glColorFragmentOp3ATI MANGLE(ColorFragmentOp3ATI)
|
||||
#define glColorMaski MANGLE(ColorMaski)
|
||||
#define glColorMaskIndexedEXT MANGLE(ColorMaskIndexedEXT)
|
||||
#define glColorMask MANGLE(ColorMask)
|
||||
#define glColorMaterial MANGLE(ColorMaterial)
|
||||
@@ -221,12 +196,6 @@
|
||||
#define glCombinerStageParameterfvNV MANGLE(CombinerStageParameterfvNV)
|
||||
#define glCompileShaderARB MANGLE(CompileShaderARB)
|
||||
#define glCompileShader MANGLE(CompileShader)
|
||||
#define glCompressedMultiTexImage1DEXT MANGLE(CompressedMultiTexImage1DEXT)
|
||||
#define glCompressedMultiTexImage2DEXT MANGLE(CompressedMultiTexImage2DEXT)
|
||||
#define glCompressedMultiTexImage3DEXT MANGLE(CompressedMultiTexImage3DEXT)
|
||||
#define glCompressedMultiTexSubImage1DEXT MANGLE(CompressedMultiTexSubImage1DEXT)
|
||||
#define glCompressedMultiTexSubImage2DEXT MANGLE(CompressedMultiTexSubImage2DEXT)
|
||||
#define glCompressedMultiTexSubImage3DEXT MANGLE(CompressedMultiTexSubImage3DEXT)
|
||||
#define glCompressedTexImage1DARB MANGLE(CompressedTexImage1DARB)
|
||||
#define glCompressedTexImage1D MANGLE(CompressedTexImage1D)
|
||||
#define glCompressedTexImage2DARB MANGLE(CompressedTexImage2DARB)
|
||||
@@ -239,12 +208,6 @@
|
||||
#define glCompressedTexSubImage2D MANGLE(CompressedTexSubImage2D)
|
||||
#define glCompressedTexSubImage3DARB MANGLE(CompressedTexSubImage3DARB)
|
||||
#define glCompressedTexSubImage3D MANGLE(CompressedTexSubImage3D)
|
||||
#define glCompressedTextureImage1DEXT MANGLE(CompressedTextureImage1DEXT)
|
||||
#define glCompressedTextureImage2DEXT MANGLE(CompressedTextureImage2DEXT)
|
||||
#define glCompressedTextureImage3DEXT MANGLE(CompressedTextureImage3DEXT)
|
||||
#define glCompressedTextureSubImage1DEXT MANGLE(CompressedTextureSubImage1DEXT)
|
||||
#define glCompressedTextureSubImage2DEXT MANGLE(CompressedTextureSubImage2DEXT)
|
||||
#define glCompressedTextureSubImage3DEXT MANGLE(CompressedTextureSubImage3DEXT)
|
||||
#define glConvolutionFilter1DEXT MANGLE(ConvolutionFilter1DEXT)
|
||||
#define glConvolutionFilter1D MANGLE(ConvolutionFilter1D)
|
||||
#define glConvolutionFilter2DEXT MANGLE(ConvolutionFilter2DEXT)
|
||||
@@ -265,11 +228,6 @@
|
||||
#define glCopyConvolutionFilter1D MANGLE(CopyConvolutionFilter1D)
|
||||
#define glCopyConvolutionFilter2DEXT MANGLE(CopyConvolutionFilter2DEXT)
|
||||
#define glCopyConvolutionFilter2D MANGLE(CopyConvolutionFilter2D)
|
||||
#define glCopyMultiTexImage1DEXT MANGLE(CopyMultiTexImage1DEXT)
|
||||
#define glCopyMultiTexImage2DEXT MANGLE(CopyMultiTexImage2DEXT)
|
||||
#define glCopyMultiTexSubImage1DEXT MANGLE(CopyMultiTexSubImage1DEXT)
|
||||
#define glCopyMultiTexSubImage2DEXT MANGLE(CopyMultiTexSubImage2DEXT)
|
||||
#define glCopyMultiTexSubImage3DEXT MANGLE(CopyMultiTexSubImage3DEXT)
|
||||
#define glCopyPixels MANGLE(CopyPixels)
|
||||
#define glCopyTexImage1DEXT MANGLE(CopyTexImage1DEXT)
|
||||
#define glCopyTexImage1D MANGLE(CopyTexImage1D)
|
||||
@@ -281,11 +239,6 @@
|
||||
#define glCopyTexSubImage2D MANGLE(CopyTexSubImage2D)
|
||||
#define glCopyTexSubImage3DEXT MANGLE(CopyTexSubImage3DEXT)
|
||||
#define glCopyTexSubImage3D MANGLE(CopyTexSubImage3D)
|
||||
#define glCopyTextureImage1DEXT MANGLE(CopyTextureImage1DEXT)
|
||||
#define glCopyTextureImage2DEXT MANGLE(CopyTextureImage2DEXT)
|
||||
#define glCopyTextureSubImage1DEXT MANGLE(CopyTextureSubImage1DEXT)
|
||||
#define glCopyTextureSubImage2DEXT MANGLE(CopyTextureSubImage2DEXT)
|
||||
#define glCopyTextureSubImage3DEXT MANGLE(CopyTextureSubImage3DEXT)
|
||||
#define glCreateDebugObjectMESA MANGLE(CreateDebugObjectMESA)
|
||||
#define glCreateProgram MANGLE(CreateProgram)
|
||||
#define glCreateProgramObjectARB MANGLE(CreateProgramObjectARB)
|
||||
@@ -305,7 +258,6 @@
|
||||
#define glDeleteFencesNV MANGLE(DeleteFencesNV)
|
||||
#define glDeleteFragmentShaderATI MANGLE(DeleteFragmentShaderATI)
|
||||
#define glDeleteFramebuffersEXT MANGLE(DeleteFramebuffersEXT)
|
||||
#define glDeleteFramebuffers MANGLE(DeleteFramebuffers)
|
||||
#define glDeleteLists MANGLE(DeleteLists)
|
||||
#define glDeleteObjectARB MANGLE(DeleteObjectARB)
|
||||
#define glDeleteOcclusionQueriesNV MANGLE(DeleteOcclusionQueriesNV)
|
||||
@@ -315,13 +267,10 @@
|
||||
#define glDeleteQueriesARB MANGLE(DeleteQueriesARB)
|
||||
#define glDeleteQueries MANGLE(DeleteQueries)
|
||||
#define glDeleteRenderbuffersEXT MANGLE(DeleteRenderbuffersEXT)
|
||||
#define glDeleteRenderbuffers MANGLE(DeleteRenderbuffers)
|
||||
#define glDeleteShader MANGLE(DeleteShader)
|
||||
#define glDeleteTexturesEXT MANGLE(DeleteTexturesEXT)
|
||||
#define glDeleteTextures MANGLE(DeleteTextures)
|
||||
#define glDeleteTransformFeedbacksNV MANGLE(DeleteTransformFeedbacksNV)
|
||||
#define glDeleteVertexArraysAPPLE MANGLE(DeleteVertexArraysAPPLE)
|
||||
#define glDeleteVertexArrays MANGLE(DeleteVertexArrays)
|
||||
#define glDeleteVertexShaderEXT MANGLE(DeleteVertexShaderEXT)
|
||||
#define glDepthBoundsdNV MANGLE(DepthBoundsdNV)
|
||||
#define glDepthBoundsEXT MANGLE(DepthBoundsEXT)
|
||||
@@ -332,16 +281,13 @@
|
||||
#define glDetachObjectARB MANGLE(DetachObjectARB)
|
||||
#define glDetachShader MANGLE(DetachShader)
|
||||
#define glDetailTexFuncSGIS MANGLE(DetailTexFuncSGIS)
|
||||
#define glDisableClientStateIndexedEXT MANGLE(DisableClientStateIndexedEXT)
|
||||
#define glDisableClientState MANGLE(DisableClientState)
|
||||
#define glDisablei MANGLE(Disablei)
|
||||
#define glDisableIndexedEXT MANGLE(DisableIndexedEXT)
|
||||
#define glDisable MANGLE(Disable)
|
||||
#define glDisableVariantClientStateEXT MANGLE(DisableVariantClientStateEXT)
|
||||
#define glDisableVertexAttribArrayARB MANGLE(DisableVertexAttribArrayARB)
|
||||
#define glDisableVertexAttribArray MANGLE(DisableVertexAttribArray)
|
||||
#define glDrawArraysEXT MANGLE(DrawArraysEXT)
|
||||
#define glDrawArraysInstancedARB MANGLE(DrawArraysInstancedARB)
|
||||
#define glDrawArraysInstancedEXT MANGLE(DrawArraysInstancedEXT)
|
||||
#define glDrawArrays MANGLE(DrawArrays)
|
||||
#define glDrawBuffer MANGLE(DrawBuffer)
|
||||
@@ -350,7 +296,6 @@
|
||||
#define glDrawBuffers MANGLE(DrawBuffers)
|
||||
#define glDrawElementArrayAPPLE MANGLE(DrawElementArrayAPPLE)
|
||||
#define glDrawElementArrayATI MANGLE(DrawElementArrayATI)
|
||||
#define glDrawElementsInstancedARB MANGLE(DrawElementsInstancedARB)
|
||||
#define glDrawElementsInstancedEXT MANGLE(DrawElementsInstancedEXT)
|
||||
#define glDrawElements MANGLE(DrawElements)
|
||||
#define glDrawMeshArraysSUN MANGLE(DrawMeshArraysSUN)
|
||||
@@ -359,7 +304,6 @@
|
||||
#define glDrawRangeElementArrayATI MANGLE(DrawRangeElementArrayATI)
|
||||
#define glDrawRangeElementsEXT MANGLE(DrawRangeElementsEXT)
|
||||
#define glDrawRangeElements MANGLE(DrawRangeElements)
|
||||
#define glDrawTransformFeedbackNV MANGLE(DrawTransformFeedbackNV)
|
||||
#define glEdgeFlag MANGLE(EdgeFlag)
|
||||
#define glEdgeFlagPointerEXT MANGLE(EdgeFlagPointerEXT)
|
||||
#define glEdgeFlagPointerListIBM MANGLE(EdgeFlagPointerListIBM)
|
||||
@@ -367,24 +311,18 @@
|
||||
#define glEdgeFlagv MANGLE(EdgeFlagv)
|
||||
#define glElementPointerAPPLE MANGLE(ElementPointerAPPLE)
|
||||
#define glElementPointerATI MANGLE(ElementPointerATI)
|
||||
#define glEnableClientStateIndexedEXT MANGLE(EnableClientStateIndexedEXT)
|
||||
#define glEnableClientState MANGLE(EnableClientState)
|
||||
#define glEnablei MANGLE(Enablei)
|
||||
#define glEnableIndexedEXT MANGLE(EnableIndexedEXT)
|
||||
#define glEnable MANGLE(Enable)
|
||||
#define glEnableVariantClientStateEXT MANGLE(EnableVariantClientStateEXT)
|
||||
#define glEnableVertexAttribArrayARB MANGLE(EnableVertexAttribArrayARB)
|
||||
#define glEnableVertexAttribArray MANGLE(EnableVertexAttribArray)
|
||||
#define glEndConditionalRender MANGLE(EndConditionalRender)
|
||||
#define glEndConditionalRenderNV MANGLE(EndConditionalRenderNV)
|
||||
#define glEndFragmentShaderATI MANGLE(EndFragmentShaderATI)
|
||||
#define glEndList MANGLE(EndList)
|
||||
#define glEnd MANGLE(End)
|
||||
#define glEndOcclusionQueryNV MANGLE(EndOcclusionQueryNV)
|
||||
#define glEndQueryARB MANGLE(EndQueryARB)
|
||||
#define glEndQuery MANGLE(EndQuery)
|
||||
#define glEndTransformFeedbackEXT MANGLE(EndTransformFeedbackEXT)
|
||||
#define glEndTransformFeedback MANGLE(EndTransformFeedback)
|
||||
#define glEndTransformFeedbackNV MANGLE(EndTransformFeedbackNV)
|
||||
#define glEndVertexShaderEXT MANGLE(EndVertexShaderEXT)
|
||||
#define glEvalCoord1d MANGLE(EvalCoord1d)
|
||||
@@ -412,7 +350,6 @@
|
||||
#define glFinishTextureSUNX MANGLE(FinishTextureSUNX)
|
||||
#define glFlush MANGLE(Flush)
|
||||
#define glFlushMappedBufferRangeAPPLE MANGLE(FlushMappedBufferRangeAPPLE)
|
||||
#define glFlushMappedBufferRange MANGLE(FlushMappedBufferRange)
|
||||
#define glFlushPixelDataRangeNV MANGLE(FlushPixelDataRangeNV)
|
||||
#define glFlushRasterSGIX MANGLE(FlushRasterSGIX)
|
||||
#define glFlushVertexArrayRangeAPPLE MANGLE(FlushVertexArrayRangeAPPLE)
|
||||
@@ -448,25 +385,13 @@
|
||||
#define glFragmentMaterialfvSGIX MANGLE(FragmentMaterialfvSGIX)
|
||||
#define glFragmentMaterialiSGIX MANGLE(FragmentMaterialiSGIX)
|
||||
#define glFragmentMaterialivSGIX MANGLE(FragmentMaterialivSGIX)
|
||||
#define glFramebufferDrawBufferEXT MANGLE(FramebufferDrawBufferEXT)
|
||||
#define glFramebufferDrawBuffersEXT MANGLE(FramebufferDrawBuffersEXT)
|
||||
#define glFramebufferReadBufferEXT MANGLE(FramebufferReadBufferEXT)
|
||||
#define glFramebufferRenderbufferEXT MANGLE(FramebufferRenderbufferEXT)
|
||||
#define glFramebufferRenderbuffer MANGLE(FramebufferRenderbuffer)
|
||||
#define glFramebufferTexture1DEXT MANGLE(FramebufferTexture1DEXT)
|
||||
#define glFramebufferTexture1D MANGLE(FramebufferTexture1D)
|
||||
#define glFramebufferTexture2DEXT MANGLE(FramebufferTexture2DEXT)
|
||||
#define glFramebufferTexture2D MANGLE(FramebufferTexture2D)
|
||||
#define glFramebufferTexture3DEXT MANGLE(FramebufferTexture3DEXT)
|
||||
#define glFramebufferTexture3D MANGLE(FramebufferTexture3D)
|
||||
#define glFramebufferTextureARB MANGLE(FramebufferTextureARB)
|
||||
#define glFramebufferTextureEXT MANGLE(FramebufferTextureEXT)
|
||||
#define glFramebufferTextureFaceARB MANGLE(FramebufferTextureFaceARB)
|
||||
#define glFramebufferTextureFaceEXT MANGLE(FramebufferTextureFaceEXT)
|
||||
#define glFramebufferTextureLayerARB MANGLE(FramebufferTextureLayerARB)
|
||||
#define glFramebufferTextureLayerEXT MANGLE(FramebufferTextureLayerEXT)
|
||||
#define glFramebufferTextureLayer MANGLE(FramebufferTextureLayer)
|
||||
#define glFrameTerminatorGREMEDY MANGLE(FrameTerminatorGREMEDY)
|
||||
#define glFrameZoomSGIX MANGLE(FrameZoomSGIX)
|
||||
#define glFreeObjectBufferATI MANGLE(FreeObjectBufferATI)
|
||||
#define glFrontFace MANGLE(FrontFace)
|
||||
@@ -475,14 +400,10 @@
|
||||
#define glGenBuffersARB MANGLE(GenBuffersARB)
|
||||
#define glGenBuffers MANGLE(GenBuffers)
|
||||
#define glGenerateMipmapEXT MANGLE(GenerateMipmapEXT)
|
||||
#define glGenerateMipmap MANGLE(GenerateMipmap)
|
||||
#define glGenerateMultiTexMipmapEXT MANGLE(GenerateMultiTexMipmapEXT)
|
||||
#define glGenerateTextureMipmapEXT MANGLE(GenerateTextureMipmapEXT)
|
||||
#define glGenFencesAPPLE MANGLE(GenFencesAPPLE)
|
||||
#define glGenFencesNV MANGLE(GenFencesNV)
|
||||
#define glGenFragmentShadersATI MANGLE(GenFragmentShadersATI)
|
||||
#define glGenFramebuffersEXT MANGLE(GenFramebuffersEXT)
|
||||
#define glGenFramebuffers MANGLE(GenFramebuffers)
|
||||
#define glGenLists MANGLE(GenLists)
|
||||
#define glGenOcclusionQueriesNV MANGLE(GenOcclusionQueriesNV)
|
||||
#define glGenProgramsARB MANGLE(GenProgramsARB)
|
||||
@@ -490,13 +411,10 @@
|
||||
#define glGenQueriesARB MANGLE(GenQueriesARB)
|
||||
#define glGenQueries MANGLE(GenQueries)
|
||||
#define glGenRenderbuffersEXT MANGLE(GenRenderbuffersEXT)
|
||||
#define glGenRenderbuffers MANGLE(GenRenderbuffers)
|
||||
#define glGenSymbolsEXT MANGLE(GenSymbolsEXT)
|
||||
#define glGenTexturesEXT MANGLE(GenTexturesEXT)
|
||||
#define glGenTextures MANGLE(GenTextures)
|
||||
#define glGenTransformFeedbacksNV MANGLE(GenTransformFeedbacksNV)
|
||||
#define glGenVertexArraysAPPLE MANGLE(GenVertexArraysAPPLE)
|
||||
#define glGenVertexArrays MANGLE(GenVertexArrays)
|
||||
#define glGenVertexShadersEXT MANGLE(GenVertexShadersEXT)
|
||||
#define glGetActiveAttribARB MANGLE(GetActiveAttribARB)
|
||||
#define glGetActiveAttrib MANGLE(GetActiveAttrib)
|
||||
@@ -510,7 +428,6 @@
|
||||
#define glGetAttribLocationARB MANGLE(GetAttribLocationARB)
|
||||
#define glGetAttribLocation MANGLE(GetAttribLocation)
|
||||
#define glGetBooleanIndexedvEXT MANGLE(GetBooleanIndexedvEXT)
|
||||
#define glGetBooleani_v MANGLE(GetBooleani_v)
|
||||
#define glGetBooleanv MANGLE(GetBooleanv)
|
||||
#define glGetBufferParameterivARB MANGLE(GetBufferParameterivARB)
|
||||
#define glGetBufferParameteriv MANGLE(GetBufferParameteriv)
|
||||
@@ -533,10 +450,8 @@
|
||||
#define glGetCombinerOutputParameterfvNV MANGLE(GetCombinerOutputParameterfvNV)
|
||||
#define glGetCombinerOutputParameterivNV MANGLE(GetCombinerOutputParameterivNV)
|
||||
#define glGetCombinerStageParameterfvNV MANGLE(GetCombinerStageParameterfvNV)
|
||||
#define glGetCompressedMultiTexImageEXT MANGLE(GetCompressedMultiTexImageEXT)
|
||||
#define glGetCompressedTexImageARB MANGLE(GetCompressedTexImageARB)
|
||||
#define glGetCompressedTexImage MANGLE(GetCompressedTexImage)
|
||||
#define glGetCompressedTextureImageEXT MANGLE(GetCompressedTextureImageEXT)
|
||||
#define glGetConvolutionFilterEXT MANGLE(GetConvolutionFilterEXT)
|
||||
#define glGetConvolutionFilter MANGLE(GetConvolutionFilter)
|
||||
#define glGetConvolutionParameterfvEXT MANGLE(GetConvolutionParameterfvEXT)
|
||||
@@ -546,24 +461,19 @@
|
||||
#define glGetDebugLogLengthMESA MANGLE(GetDebugLogLengthMESA)
|
||||
#define glGetDebugLogMESA MANGLE(GetDebugLogMESA)
|
||||
#define glGetDetailTexFuncSGIS MANGLE(GetDetailTexFuncSGIS)
|
||||
#define glGetDoubleIndexedvEXT MANGLE(GetDoubleIndexedvEXT)
|
||||
#define glGetDoublev MANGLE(GetDoublev)
|
||||
#define glGetError MANGLE(GetError)
|
||||
#define glGetFenceivNV MANGLE(GetFenceivNV)
|
||||
#define glGetFinalCombinerInputParameterfvNV MANGLE(GetFinalCombinerInputParameterfvNV)
|
||||
#define glGetFinalCombinerInputParameterivNV MANGLE(GetFinalCombinerInputParameterivNV)
|
||||
#define glGetFloatIndexedvEXT MANGLE(GetFloatIndexedvEXT)
|
||||
#define glGetFloatv MANGLE(GetFloatv)
|
||||
#define glGetFogFuncSGIS MANGLE(GetFogFuncSGIS)
|
||||
#define glGetFragDataLocationEXT MANGLE(GetFragDataLocationEXT)
|
||||
#define glGetFragDataLocation MANGLE(GetFragDataLocation)
|
||||
#define glGetFragmentLightfvSGIX MANGLE(GetFragmentLightfvSGIX)
|
||||
#define glGetFragmentLightivSGIX MANGLE(GetFragmentLightivSGIX)
|
||||
#define glGetFragmentMaterialfvSGIX MANGLE(GetFragmentMaterialfvSGIX)
|
||||
#define glGetFragmentMaterialivSGIX MANGLE(GetFragmentMaterialivSGIX)
|
||||
#define glGetFramebufferAttachmentParameterivEXT MANGLE(GetFramebufferAttachmentParameterivEXT)
|
||||
#define glGetFramebufferAttachmentParameteriv MANGLE(GetFramebufferAttachmentParameteriv)
|
||||
#define glGetFramebufferParameterivEXT MANGLE(GetFramebufferParameterivEXT)
|
||||
#define glGetHandleARB MANGLE(GetHandleARB)
|
||||
#define glGetHistogramEXT MANGLE(GetHistogramEXT)
|
||||
#define glGetHistogram MANGLE(GetHistogram)
|
||||
@@ -576,7 +486,6 @@
|
||||
#define glGetInfoLogARB MANGLE(GetInfoLogARB)
|
||||
#define glGetInstrumentsSGIX MANGLE(GetInstrumentsSGIX)
|
||||
#define glGetIntegerIndexedvEXT MANGLE(GetIntegerIndexedvEXT)
|
||||
#define glGetIntegeri_v MANGLE(GetIntegeri_v)
|
||||
#define glGetIntegerv MANGLE(GetIntegerv)
|
||||
#define glGetInvariantBooleanvEXT MANGLE(GetInvariantBooleanvEXT)
|
||||
#define glGetInvariantFloatvEXT MANGLE(GetInvariantFloatvEXT)
|
||||
@@ -604,30 +513,6 @@
|
||||
#define glGetMinmaxParameterfv MANGLE(GetMinmaxParameterfv)
|
||||
#define glGetMinmaxParameterivEXT MANGLE(GetMinmaxParameterivEXT)
|
||||
#define glGetMinmaxParameteriv MANGLE(GetMinmaxParameteriv)
|
||||
#define glGetMultisamplefvNV MANGLE(GetMultisamplefvNV)
|
||||
#define glGetMultiTexEnvfvEXT MANGLE(GetMultiTexEnvfvEXT)
|
||||
#define glGetMultiTexEnvivEXT MANGLE(GetMultiTexEnvivEXT)
|
||||
#define glGetMultiTexGendvEXT MANGLE(GetMultiTexGendvEXT)
|
||||
#define glGetMultiTexGenfvEXT MANGLE(GetMultiTexGenfvEXT)
|
||||
#define glGetMultiTexGenivEXT MANGLE(GetMultiTexGenivEXT)
|
||||
#define glGetMultiTexImageEXT MANGLE(GetMultiTexImageEXT)
|
||||
#define glGetMultiTexLevelParameterfvEXT MANGLE(GetMultiTexLevelParameterfvEXT)
|
||||
#define glGetMultiTexLevelParameterivEXT MANGLE(GetMultiTexLevelParameterivEXT)
|
||||
#define glGetMultiTexParameterfvEXT MANGLE(GetMultiTexParameterfvEXT)
|
||||
#define glGetMultiTexParameterIivEXT MANGLE(GetMultiTexParameterIivEXT)
|
||||
#define glGetMultiTexParameterIuivEXT MANGLE(GetMultiTexParameterIuivEXT)
|
||||
#define glGetMultiTexParameterivEXT MANGLE(GetMultiTexParameterivEXT)
|
||||
#define glGetNamedBufferParameterivEXT MANGLE(GetNamedBufferParameterivEXT)
|
||||
#define glGetNamedBufferPointervEXT MANGLE(GetNamedBufferPointervEXT)
|
||||
#define glGetNamedBufferSubDataEXT MANGLE(GetNamedBufferSubDataEXT)
|
||||
#define glGetNamedFramebufferAttachmentParameterivEXT MANGLE(GetNamedFramebufferAttachmentParameterivEXT)
|
||||
#define glGetNamedProgramivEXT MANGLE(GetNamedProgramivEXT)
|
||||
#define glGetNamedProgramLocalParameterdvEXT MANGLE(GetNamedProgramLocalParameterdvEXT)
|
||||
#define glGetNamedProgramLocalParameterfvEXT MANGLE(GetNamedProgramLocalParameterfvEXT)
|
||||
#define glGetNamedProgramLocalParameterIivEXT MANGLE(GetNamedProgramLocalParameterIivEXT)
|
||||
#define glGetNamedProgramLocalParameterIuivEXT MANGLE(GetNamedProgramLocalParameterIuivEXT)
|
||||
#define glGetNamedProgramStringEXT MANGLE(GetNamedProgramStringEXT)
|
||||
#define glGetNamedRenderbufferParameterivEXT MANGLE(GetNamedRenderbufferParameterivEXT)
|
||||
#define glGetObjectBufferfvATI MANGLE(GetObjectBufferfvATI)
|
||||
#define glGetObjectBufferivATI MANGLE(GetObjectBufferivATI)
|
||||
#define glGetObjectParameterfvARB MANGLE(GetObjectParameterfvARB)
|
||||
@@ -639,7 +524,6 @@
|
||||
#define glGetPixelMapusv MANGLE(GetPixelMapusv)
|
||||
#define glGetPixelTexGenParameterfvSGIS MANGLE(GetPixelTexGenParameterfvSGIS)
|
||||
#define glGetPixelTexGenParameterivSGIS MANGLE(GetPixelTexGenParameterivSGIS)
|
||||
#define glGetPointerIndexedvEXT MANGLE(GetPointerIndexedvEXT)
|
||||
#define glGetPointervEXT MANGLE(GetPointervEXT)
|
||||
#define glGetPointerv MANGLE(GetPointerv)
|
||||
#define glGetPolygonStipple MANGLE(GetPolygonStipple)
|
||||
@@ -671,7 +555,6 @@
|
||||
#define glGetQueryObjectuivARB MANGLE(GetQueryObjectuivARB)
|
||||
#define glGetQueryObjectuiv MANGLE(GetQueryObjectuiv)
|
||||
#define glGetRenderbufferParameterivEXT MANGLE(GetRenderbufferParameterivEXT)
|
||||
#define glGetRenderbufferParameteriv MANGLE(GetRenderbufferParameteriv)
|
||||
#define glGetSeparableFilterEXT MANGLE(GetSeparableFilterEXT)
|
||||
#define glGetSeparableFilter MANGLE(GetSeparableFilter)
|
||||
#define glGetShaderInfoLog MANGLE(GetShaderInfoLog)
|
||||
@@ -679,7 +562,6 @@
|
||||
#define glGetShaderSourceARB MANGLE(GetShaderSourceARB)
|
||||
#define glGetShaderSource MANGLE(GetShaderSource)
|
||||
#define glGetSharpenTexFuncSGIS MANGLE(GetSharpenTexFuncSGIS)
|
||||
#define glGetStringi MANGLE(GetStringi)
|
||||
#define glGetString MANGLE(GetString)
|
||||
#define glGetTexBumpParameterfvATI MANGLE(GetTexBumpParameterfvATI)
|
||||
#define glGetTexBumpParameterivATI MANGLE(GetTexBumpParameterivATI)
|
||||
@@ -694,20 +576,9 @@
|
||||
#define glGetTexLevelParameteriv MANGLE(GetTexLevelParameteriv)
|
||||
#define glGetTexParameterfv MANGLE(GetTexParameterfv)
|
||||
#define glGetTexParameterIivEXT MANGLE(GetTexParameterIivEXT)
|
||||
#define glGetTexParameterIiv MANGLE(GetTexParameterIiv)
|
||||
#define glGetTexParameterIuivEXT MANGLE(GetTexParameterIuivEXT)
|
||||
#define glGetTexParameterIuiv MANGLE(GetTexParameterIuiv)
|
||||
#define glGetTexParameteriv MANGLE(GetTexParameteriv)
|
||||
#define glGetTextureImageEXT MANGLE(GetTextureImageEXT)
|
||||
#define glGetTextureLevelParameterfvEXT MANGLE(GetTextureLevelParameterfvEXT)
|
||||
#define glGetTextureLevelParameterivEXT MANGLE(GetTextureLevelParameterivEXT)
|
||||
#define glGetTextureParameterfvEXT MANGLE(GetTextureParameterfvEXT)
|
||||
#define glGetTextureParameterIivEXT MANGLE(GetTextureParameterIivEXT)
|
||||
#define glGetTextureParameterIuivEXT MANGLE(GetTextureParameterIuivEXT)
|
||||
#define glGetTextureParameterivEXT MANGLE(GetTextureParameterivEXT)
|
||||
#define glGetTrackMatrixivNV MANGLE(GetTrackMatrixivNV)
|
||||
#define glGetTransformFeedbackVaryingEXT MANGLE(GetTransformFeedbackVaryingEXT)
|
||||
#define glGetTransformFeedbackVarying MANGLE(GetTransformFeedbackVarying)
|
||||
#define glGetTransformFeedbackVaryingNV MANGLE(GetTransformFeedbackVaryingNV)
|
||||
#define glGetUniformBufferSizeEXT MANGLE(GetUniformBufferSizeEXT)
|
||||
#define glGetUniformfvARB MANGLE(GetUniformfvARB)
|
||||
@@ -718,7 +589,6 @@
|
||||
#define glGetUniformLocation MANGLE(GetUniformLocation)
|
||||
#define glGetUniformOffsetEXT MANGLE(GetUniformOffsetEXT)
|
||||
#define glGetUniformuivEXT MANGLE(GetUniformuivEXT)
|
||||
#define glGetUniformuiv MANGLE(GetUniformuiv)
|
||||
#define glGetVariantArrayObjectfvATI MANGLE(GetVariantArrayObjectfvATI)
|
||||
#define glGetVariantArrayObjectivATI MANGLE(GetVariantArrayObjectivATI)
|
||||
#define glGetVariantBooleanvEXT MANGLE(GetVariantBooleanvEXT)
|
||||
@@ -735,9 +605,7 @@
|
||||
#define glGetVertexAttribfv MANGLE(GetVertexAttribfv)
|
||||
#define glGetVertexAttribfvNV MANGLE(GetVertexAttribfvNV)
|
||||
#define glGetVertexAttribIivEXT MANGLE(GetVertexAttribIivEXT)
|
||||
#define glGetVertexAttribIiv MANGLE(GetVertexAttribIiv)
|
||||
#define glGetVertexAttribIuivEXT MANGLE(GetVertexAttribIuivEXT)
|
||||
#define glGetVertexAttribIuiv MANGLE(GetVertexAttribIuiv)
|
||||
#define glGetVertexAttribivARB MANGLE(GetVertexAttribivARB)
|
||||
#define glGetVertexAttribiv MANGLE(GetVertexAttribiv)
|
||||
#define glGetVertexAttribivNV MANGLE(GetVertexAttribivNV)
|
||||
@@ -784,13 +652,11 @@
|
||||
#define glIsAsyncMarkerSGIX MANGLE(IsAsyncMarkerSGIX)
|
||||
#define glIsBufferARB MANGLE(IsBufferARB)
|
||||
#define glIsBuffer MANGLE(IsBuffer)
|
||||
#define glIsEnabledi MANGLE(IsEnabledi)
|
||||
#define glIsEnabledIndexedEXT MANGLE(IsEnabledIndexedEXT)
|
||||
#define glIsEnabled MANGLE(IsEnabled)
|
||||
#define glIsFenceAPPLE MANGLE(IsFenceAPPLE)
|
||||
#define glIsFenceNV MANGLE(IsFenceNV)
|
||||
#define glIsFramebufferEXT MANGLE(IsFramebufferEXT)
|
||||
#define glIsFramebuffer MANGLE(IsFramebuffer)
|
||||
#define glIsList MANGLE(IsList)
|
||||
#define glIsObjectBufferATI MANGLE(IsObjectBufferATI)
|
||||
#define glIsOcclusionQueryNV MANGLE(IsOcclusionQueryNV)
|
||||
@@ -800,14 +666,11 @@
|
||||
#define glIsQueryARB MANGLE(IsQueryARB)
|
||||
#define glIsQuery MANGLE(IsQuery)
|
||||
#define glIsRenderbufferEXT MANGLE(IsRenderbufferEXT)
|
||||
#define glIsRenderbuffer MANGLE(IsRenderbuffer)
|
||||
#define glIsShader MANGLE(IsShader)
|
||||
#define glIsTextureEXT MANGLE(IsTextureEXT)
|
||||
#define glIsTexture MANGLE(IsTexture)
|
||||
#define glIsTransformFeedbackNV MANGLE(IsTransformFeedbackNV)
|
||||
#define glIsVariantEnabledEXT MANGLE(IsVariantEnabledEXT)
|
||||
#define glIsVertexArrayAPPLE MANGLE(IsVertexArrayAPPLE)
|
||||
#define glIsVertexArray MANGLE(IsVertexArray)
|
||||
#define glLightEnviSGIX MANGLE(LightEnviSGIX)
|
||||
#define glLightf MANGLE(Lightf)
|
||||
#define glLightfv MANGLE(Lightfv)
|
||||
@@ -844,13 +707,11 @@
|
||||
#define glMap2f MANGLE(Map2f)
|
||||
#define glMapBufferARB MANGLE(MapBufferARB)
|
||||
#define glMapBuffer MANGLE(MapBuffer)
|
||||
#define glMapBufferRange MANGLE(MapBufferRange)
|
||||
#define glMapControlPointsNV MANGLE(MapControlPointsNV)
|
||||
#define glMapGrid1d MANGLE(MapGrid1d)
|
||||
#define glMapGrid1f MANGLE(MapGrid1f)
|
||||
#define glMapGrid2d MANGLE(MapGrid2d)
|
||||
#define glMapGrid2f MANGLE(MapGrid2f)
|
||||
#define glMapNamedBufferEXT MANGLE(MapNamedBufferEXT)
|
||||
#define glMapObjectBufferATI MANGLE(MapObjectBufferATI)
|
||||
#define glMapParameterfvNV MANGLE(MapParameterfvNV)
|
||||
#define glMapParameterivNV MANGLE(MapParameterivNV)
|
||||
@@ -858,30 +719,11 @@
|
||||
#define glMaterialfv MANGLE(Materialfv)
|
||||
#define glMateriali MANGLE(Materiali)
|
||||
#define glMaterialiv MANGLE(Materialiv)
|
||||
#define glMatrixFrustumEXT MANGLE(MatrixFrustumEXT)
|
||||
#define glMatrixIndexPointerARB MANGLE(MatrixIndexPointerARB)
|
||||
#define glMatrixIndexubvARB MANGLE(MatrixIndexubvARB)
|
||||
#define glMatrixIndexuivARB MANGLE(MatrixIndexuivARB)
|
||||
#define glMatrixIndexusvARB MANGLE(MatrixIndexusvARB)
|
||||
#define glMatrixLoaddEXT MANGLE(MatrixLoaddEXT)
|
||||
#define glMatrixLoadfEXT MANGLE(MatrixLoadfEXT)
|
||||
#define glMatrixLoadIdentityEXT MANGLE(MatrixLoadIdentityEXT)
|
||||
#define glMatrixLoadTransposedEXT MANGLE(MatrixLoadTransposedEXT)
|
||||
#define glMatrixLoadTransposefEXT MANGLE(MatrixLoadTransposefEXT)
|
||||
#define glMatrixMode MANGLE(MatrixMode)
|
||||
#define glMatrixMultdEXT MANGLE(MatrixMultdEXT)
|
||||
#define glMatrixMultfEXT MANGLE(MatrixMultfEXT)
|
||||
#define glMatrixMultTransposedEXT MANGLE(MatrixMultTransposedEXT)
|
||||
#define glMatrixMultTransposefEXT MANGLE(MatrixMultTransposefEXT)
|
||||
#define glMatrixOrthoEXT MANGLE(MatrixOrthoEXT)
|
||||
#define glMatrixPopEXT MANGLE(MatrixPopEXT)
|
||||
#define glMatrixPushEXT MANGLE(MatrixPushEXT)
|
||||
#define glMatrixRotatedEXT MANGLE(MatrixRotatedEXT)
|
||||
#define glMatrixRotatefEXT MANGLE(MatrixRotatefEXT)
|
||||
#define glMatrixScaledEXT MANGLE(MatrixScaledEXT)
|
||||
#define glMatrixScalefEXT MANGLE(MatrixScalefEXT)
|
||||
#define glMatrixTranslatedEXT MANGLE(MatrixTranslatedEXT)
|
||||
#define glMatrixTranslatefEXT MANGLE(MatrixTranslatefEXT)
|
||||
#define glMinmaxEXT MANGLE(MinmaxEXT)
|
||||
#define glMinmax MANGLE(Minmax)
|
||||
#define glMultiDrawArraysEXT MANGLE(MultiDrawArraysEXT)
|
||||
@@ -892,7 +734,6 @@
|
||||
#define glMultiDrawRangeElementArrayAPPLE MANGLE(MultiDrawRangeElementArrayAPPLE)
|
||||
#define glMultiModeDrawArraysIBM MANGLE(MultiModeDrawArraysIBM)
|
||||
#define glMultiModeDrawElementsIBM MANGLE(MultiModeDrawElementsIBM)
|
||||
#define glMultiTexBufferEXT MANGLE(MultiTexBufferEXT)
|
||||
#define glMultiTexCoord1dARB MANGLE(MultiTexCoord1dARB)
|
||||
#define glMultiTexCoord1d MANGLE(MultiTexCoord1d)
|
||||
#define glMultiTexCoord1dvARB MANGLE(MultiTexCoord1dvARB)
|
||||
@@ -965,60 +806,12 @@
|
||||
#define glMultiTexCoord4s MANGLE(MultiTexCoord4s)
|
||||
#define glMultiTexCoord4svARB MANGLE(MultiTexCoord4svARB)
|
||||
#define glMultiTexCoord4sv MANGLE(MultiTexCoord4sv)
|
||||
#define glMultiTexCoordPointerEXT MANGLE(MultiTexCoordPointerEXT)
|
||||
#define glMultiTexEnvfEXT MANGLE(MultiTexEnvfEXT)
|
||||
#define glMultiTexEnvfvEXT MANGLE(MultiTexEnvfvEXT)
|
||||
#define glMultiTexEnviEXT MANGLE(MultiTexEnviEXT)
|
||||
#define glMultiTexEnvivEXT MANGLE(MultiTexEnvivEXT)
|
||||
#define glMultiTexGendEXT MANGLE(MultiTexGendEXT)
|
||||
#define glMultiTexGendvEXT MANGLE(MultiTexGendvEXT)
|
||||
#define glMultiTexGenfEXT MANGLE(MultiTexGenfEXT)
|
||||
#define glMultiTexGenfvEXT MANGLE(MultiTexGenfvEXT)
|
||||
#define glMultiTexGeniEXT MANGLE(MultiTexGeniEXT)
|
||||
#define glMultiTexGenivEXT MANGLE(MultiTexGenivEXT)
|
||||
#define glMultiTexImage1DEXT MANGLE(MultiTexImage1DEXT)
|
||||
#define glMultiTexImage2DEXT MANGLE(MultiTexImage2DEXT)
|
||||
#define glMultiTexImage3DEXT MANGLE(MultiTexImage3DEXT)
|
||||
#define glMultiTexParameterfEXT MANGLE(MultiTexParameterfEXT)
|
||||
#define glMultiTexParameterfvEXT MANGLE(MultiTexParameterfvEXT)
|
||||
#define glMultiTexParameteriEXT MANGLE(MultiTexParameteriEXT)
|
||||
#define glMultiTexParameterIivEXT MANGLE(MultiTexParameterIivEXT)
|
||||
#define glMultiTexParameterIuivEXT MANGLE(MultiTexParameterIuivEXT)
|
||||
#define glMultiTexParameterivEXT MANGLE(MultiTexParameterivEXT)
|
||||
#define glMultiTexRenderbufferEXT MANGLE(MultiTexRenderbufferEXT)
|
||||
#define glMultiTexSubImage1DEXT MANGLE(MultiTexSubImage1DEXT)
|
||||
#define glMultiTexSubImage2DEXT MANGLE(MultiTexSubImage2DEXT)
|
||||
#define glMultiTexSubImage3DEXT MANGLE(MultiTexSubImage3DEXT)
|
||||
#define glMultMatrixd MANGLE(MultMatrixd)
|
||||
#define glMultMatrixf MANGLE(MultMatrixf)
|
||||
#define glMultTransposeMatrixdARB MANGLE(MultTransposeMatrixdARB)
|
||||
#define glMultTransposeMatrixd MANGLE(MultTransposeMatrixd)
|
||||
#define glMultTransposeMatrixfARB MANGLE(MultTransposeMatrixfARB)
|
||||
#define glMultTransposeMatrixf MANGLE(MultTransposeMatrixf)
|
||||
#define glNamedBufferDataEXT MANGLE(NamedBufferDataEXT)
|
||||
#define glNamedBufferSubDataEXT MANGLE(NamedBufferSubDataEXT)
|
||||
#define glNamedFramebufferRenderbufferEXT MANGLE(NamedFramebufferRenderbufferEXT)
|
||||
#define glNamedFramebufferTexture1DEXT MANGLE(NamedFramebufferTexture1DEXT)
|
||||
#define glNamedFramebufferTexture2DEXT MANGLE(NamedFramebufferTexture2DEXT)
|
||||
#define glNamedFramebufferTexture3DEXT MANGLE(NamedFramebufferTexture3DEXT)
|
||||
#define glNamedFramebufferTextureEXT MANGLE(NamedFramebufferTextureEXT)
|
||||
#define glNamedFramebufferTextureFaceEXT MANGLE(NamedFramebufferTextureFaceEXT)
|
||||
#define glNamedFramebufferTextureLayerEXT MANGLE(NamedFramebufferTextureLayerEXT)
|
||||
#define glNamedProgramLocalParameter4dEXT MANGLE(NamedProgramLocalParameter4dEXT)
|
||||
#define glNamedProgramLocalParameter4dvEXT MANGLE(NamedProgramLocalParameter4dvEXT)
|
||||
#define glNamedProgramLocalParameter4fEXT MANGLE(NamedProgramLocalParameter4fEXT)
|
||||
#define glNamedProgramLocalParameter4fvEXT MANGLE(NamedProgramLocalParameter4fvEXT)
|
||||
#define glNamedProgramLocalParameterI4iEXT MANGLE(NamedProgramLocalParameterI4iEXT)
|
||||
#define glNamedProgramLocalParameterI4ivEXT MANGLE(NamedProgramLocalParameterI4ivEXT)
|
||||
#define glNamedProgramLocalParameterI4uiEXT MANGLE(NamedProgramLocalParameterI4uiEXT)
|
||||
#define glNamedProgramLocalParameterI4uivEXT MANGLE(NamedProgramLocalParameterI4uivEXT)
|
||||
#define glNamedProgramLocalParameters4fvEXT MANGLE(NamedProgramLocalParameters4fvEXT)
|
||||
#define glNamedProgramLocalParametersI4ivEXT MANGLE(NamedProgramLocalParametersI4ivEXT)
|
||||
#define glNamedProgramLocalParametersI4uivEXT MANGLE(NamedProgramLocalParametersI4uivEXT)
|
||||
#define glNamedProgramStringEXT MANGLE(NamedProgramStringEXT)
|
||||
#define glNamedRenderbufferStorageEXT MANGLE(NamedRenderbufferStorageEXT)
|
||||
#define glNamedRenderbufferStorageMultisampleCoverageEXT MANGLE(NamedRenderbufferStorageMultisampleCoverageEXT)
|
||||
#define glNamedRenderbufferStorageMultisampleEXT MANGLE(NamedRenderbufferStorageMultisampleEXT)
|
||||
#define glNewList MANGLE(NewList)
|
||||
#define glNewObjectBufferATI MANGLE(NewObjectBufferATI)
|
||||
#define glNormal3b MANGLE(Normal3b)
|
||||
@@ -1052,7 +845,6 @@
|
||||
#define glOrtho MANGLE(Ortho)
|
||||
#define glPassTexCoordATI MANGLE(PassTexCoordATI)
|
||||
#define glPassThrough MANGLE(PassThrough)
|
||||
#define glPauseTransformFeedbackNV MANGLE(PauseTransformFeedbackNV)
|
||||
#define glPixelDataRangeNV MANGLE(PixelDataRangeNV)
|
||||
#define glPixelMapfv MANGLE(PixelMapfv)
|
||||
#define glPixelMapuiv MANGLE(PixelMapuiv)
|
||||
@@ -1134,47 +926,12 @@
|
||||
#define glProgramParameter4dvNV MANGLE(ProgramParameter4dvNV)
|
||||
#define glProgramParameter4fNV MANGLE(ProgramParameter4fNV)
|
||||
#define glProgramParameter4fvNV MANGLE(ProgramParameter4fvNV)
|
||||
#define glProgramParameteriARB MANGLE(ProgramParameteriARB)
|
||||
#define glProgramParameteriEXT MANGLE(ProgramParameteriEXT)
|
||||
#define glProgramParameters4dvNV MANGLE(ProgramParameters4dvNV)
|
||||
#define glProgramParameters4fvNV MANGLE(ProgramParameters4fvNV)
|
||||
#define glProgramStringARB MANGLE(ProgramStringARB)
|
||||
#define glProgramUniform1fEXT MANGLE(ProgramUniform1fEXT)
|
||||
#define glProgramUniform1fvEXT MANGLE(ProgramUniform1fvEXT)
|
||||
#define glProgramUniform1iEXT MANGLE(ProgramUniform1iEXT)
|
||||
#define glProgramUniform1ivEXT MANGLE(ProgramUniform1ivEXT)
|
||||
#define glProgramUniform1uiEXT MANGLE(ProgramUniform1uiEXT)
|
||||
#define glProgramUniform1uivEXT MANGLE(ProgramUniform1uivEXT)
|
||||
#define glProgramUniform2fEXT MANGLE(ProgramUniform2fEXT)
|
||||
#define glProgramUniform2fvEXT MANGLE(ProgramUniform2fvEXT)
|
||||
#define glProgramUniform2iEXT MANGLE(ProgramUniform2iEXT)
|
||||
#define glProgramUniform2ivEXT MANGLE(ProgramUniform2ivEXT)
|
||||
#define glProgramUniform2uiEXT MANGLE(ProgramUniform2uiEXT)
|
||||
#define glProgramUniform2uivEXT MANGLE(ProgramUniform2uivEXT)
|
||||
#define glProgramUniform3fEXT MANGLE(ProgramUniform3fEXT)
|
||||
#define glProgramUniform3fvEXT MANGLE(ProgramUniform3fvEXT)
|
||||
#define glProgramUniform3iEXT MANGLE(ProgramUniform3iEXT)
|
||||
#define glProgramUniform3ivEXT MANGLE(ProgramUniform3ivEXT)
|
||||
#define glProgramUniform3uiEXT MANGLE(ProgramUniform3uiEXT)
|
||||
#define glProgramUniform3uivEXT MANGLE(ProgramUniform3uivEXT)
|
||||
#define glProgramUniform4fEXT MANGLE(ProgramUniform4fEXT)
|
||||
#define glProgramUniform4fvEXT MANGLE(ProgramUniform4fvEXT)
|
||||
#define glProgramUniform4iEXT MANGLE(ProgramUniform4iEXT)
|
||||
#define glProgramUniform4ivEXT MANGLE(ProgramUniform4ivEXT)
|
||||
#define glProgramUniform4uiEXT MANGLE(ProgramUniform4uiEXT)
|
||||
#define glProgramUniform4uivEXT MANGLE(ProgramUniform4uivEXT)
|
||||
#define glProgramUniformMatrix2fvEXT MANGLE(ProgramUniformMatrix2fvEXT)
|
||||
#define glProgramUniformMatrix2x3fvEXT MANGLE(ProgramUniformMatrix2x3fvEXT)
|
||||
#define glProgramUniformMatrix2x4fvEXT MANGLE(ProgramUniformMatrix2x4fvEXT)
|
||||
#define glProgramUniformMatrix3fvEXT MANGLE(ProgramUniformMatrix3fvEXT)
|
||||
#define glProgramUniformMatrix3x2fvEXT MANGLE(ProgramUniformMatrix3x2fvEXT)
|
||||
#define glProgramUniformMatrix3x4fvEXT MANGLE(ProgramUniformMatrix3x4fvEXT)
|
||||
#define glProgramUniformMatrix4fvEXT MANGLE(ProgramUniformMatrix4fvEXT)
|
||||
#define glProgramUniformMatrix4x2fvEXT MANGLE(ProgramUniformMatrix4x2fvEXT)
|
||||
#define glProgramUniformMatrix4x3fvEXT MANGLE(ProgramUniformMatrix4x3fvEXT)
|
||||
#define glProgramVertexLimitNV MANGLE(ProgramVertexLimitNV)
|
||||
#define glPushAttrib MANGLE(PushAttrib)
|
||||
#define glPushClientAttribDefaultEXT MANGLE(PushClientAttribDefaultEXT)
|
||||
#define glPushClientAttrib MANGLE(PushClientAttrib)
|
||||
#define glPushMatrix MANGLE(PushMatrix)
|
||||
#define glPushName MANGLE(PushName)
|
||||
@@ -1215,10 +972,8 @@
|
||||
#define glRectsv MANGLE(Rectsv)
|
||||
#define glReferencePlaneSGIX MANGLE(ReferencePlaneSGIX)
|
||||
#define glRenderbufferStorageEXT MANGLE(RenderbufferStorageEXT)
|
||||
#define glRenderbufferStorage MANGLE(RenderbufferStorage)
|
||||
#define glRenderbufferStorageMultisampleCoverageNV MANGLE(RenderbufferStorageMultisampleCoverageNV)
|
||||
#define glRenderbufferStorageMultisampleEXT MANGLE(RenderbufferStorageMultisampleEXT)
|
||||
#define glRenderbufferStorageMultisample MANGLE(RenderbufferStorageMultisample)
|
||||
#define glRenderMode MANGLE(RenderMode)
|
||||
#define glReplacementCodePointerSUN MANGLE(ReplacementCodePointerSUN)
|
||||
#define glReplacementCodeubSUN MANGLE(ReplacementCodeubSUN)
|
||||
@@ -1249,14 +1004,12 @@
|
||||
#define glResetMinmaxEXT MANGLE(ResetMinmaxEXT)
|
||||
#define glResetMinmax MANGLE(ResetMinmax)
|
||||
#define glResizeBuffersMESA MANGLE(ResizeBuffersMESA)
|
||||
#define glResumeTransformFeedbackNV MANGLE(ResumeTransformFeedbackNV)
|
||||
#define glRotated MANGLE(Rotated)
|
||||
#define glRotatef MANGLE(Rotatef)
|
||||
#define glSampleCoverageARB MANGLE(SampleCoverageARB)
|
||||
#define glSampleCoverage MANGLE(SampleCoverage)
|
||||
#define glSampleMapATI MANGLE(SampleMapATI)
|
||||
#define glSampleMaskEXT MANGLE(SampleMaskEXT)
|
||||
#define glSampleMaskIndexedNV MANGLE(SampleMaskIndexedNV)
|
||||
#define glSampleMaskSGIS MANGLE(SampleMaskSGIS)
|
||||
#define glSamplePatternEXT MANGLE(SamplePatternEXT)
|
||||
#define glSamplePatternSGIS MANGLE(SamplePatternSGIS)
|
||||
@@ -1348,7 +1101,6 @@
|
||||
#define glTestFenceAPPLE MANGLE(TestFenceAPPLE)
|
||||
#define glTestFenceNV MANGLE(TestFenceNV)
|
||||
#define glTestObjectAPPLE MANGLE(TestObjectAPPLE)
|
||||
#define glTexBufferARB MANGLE(TexBufferARB)
|
||||
#define glTexBufferEXT MANGLE(TexBufferEXT)
|
||||
#define glTexBumpParameterfvATI MANGLE(TexBumpParameterfvATI)
|
||||
#define glTexBumpParameterivATI MANGLE(TexBumpParameterivATI)
|
||||
@@ -1429,12 +1181,9 @@
|
||||
#define glTexParameterf MANGLE(TexParameterf)
|
||||
#define glTexParameterfv MANGLE(TexParameterfv)
|
||||
#define glTexParameterIivEXT MANGLE(TexParameterIivEXT)
|
||||
#define glTexParameterIiv MANGLE(TexParameterIiv)
|
||||
#define glTexParameteri MANGLE(TexParameteri)
|
||||
#define glTexParameterIuivEXT MANGLE(TexParameterIuivEXT)
|
||||
#define glTexParameterIuiv MANGLE(TexParameterIuiv)
|
||||
#define glTexParameteriv MANGLE(TexParameteriv)
|
||||
#define glTexRenderbufferNV MANGLE(TexRenderbufferNV)
|
||||
#define glTexSubImage1DEXT MANGLE(TexSubImage1DEXT)
|
||||
#define glTexSubImage1D MANGLE(TexSubImage1D)
|
||||
#define glTexSubImage2DEXT MANGLE(TexSubImage2DEXT)
|
||||
@@ -1442,28 +1191,12 @@
|
||||
#define glTexSubImage3DEXT MANGLE(TexSubImage3DEXT)
|
||||
#define glTexSubImage3D MANGLE(TexSubImage3D)
|
||||
#define glTexSubImage4DSGIS MANGLE(TexSubImage4DSGIS)
|
||||
#define glTextureBufferEXT MANGLE(TextureBufferEXT)
|
||||
#define glTextureColorMaskSGIS MANGLE(TextureColorMaskSGIS)
|
||||
#define glTextureImage1DEXT MANGLE(TextureImage1DEXT)
|
||||
#define glTextureImage2DEXT MANGLE(TextureImage2DEXT)
|
||||
#define glTextureImage3DEXT MANGLE(TextureImage3DEXT)
|
||||
#define glTextureLightEXT MANGLE(TextureLightEXT)
|
||||
#define glTextureMaterialEXT MANGLE(TextureMaterialEXT)
|
||||
#define glTextureNormalEXT MANGLE(TextureNormalEXT)
|
||||
#define glTextureParameterfEXT MANGLE(TextureParameterfEXT)
|
||||
#define glTextureParameterfvEXT MANGLE(TextureParameterfvEXT)
|
||||
#define glTextureParameteriEXT MANGLE(TextureParameteriEXT)
|
||||
#define glTextureParameterIivEXT MANGLE(TextureParameterIivEXT)
|
||||
#define glTextureParameterIuivEXT MANGLE(TextureParameterIuivEXT)
|
||||
#define glTextureParameterivEXT MANGLE(TextureParameterivEXT)
|
||||
#define glTextureRenderbufferEXT MANGLE(TextureRenderbufferEXT)
|
||||
#define glTextureSubImage1DEXT MANGLE(TextureSubImage1DEXT)
|
||||
#define glTextureSubImage2DEXT MANGLE(TextureSubImage2DEXT)
|
||||
#define glTextureSubImage3DEXT MANGLE(TextureSubImage3DEXT)
|
||||
#define glTrackMatrixNV MANGLE(TrackMatrixNV)
|
||||
#define glTransformFeedbackAttribsNV MANGLE(TransformFeedbackAttribsNV)
|
||||
#define glTransformFeedbackVaryingsEXT MANGLE(TransformFeedbackVaryingsEXT)
|
||||
#define glTransformFeedbackVaryings MANGLE(TransformFeedbackVaryings)
|
||||
#define glTransformFeedbackVaryingsNV MANGLE(TransformFeedbackVaryingsNV)
|
||||
#define glTranslated MANGLE(Translated)
|
||||
#define glTranslatef MANGLE(Translatef)
|
||||
@@ -1476,9 +1209,7 @@
|
||||
#define glUniform1ivARB MANGLE(Uniform1ivARB)
|
||||
#define glUniform1iv MANGLE(Uniform1iv)
|
||||
#define glUniform1uiEXT MANGLE(Uniform1uiEXT)
|
||||
#define glUniform1ui MANGLE(Uniform1ui)
|
||||
#define glUniform1uivEXT MANGLE(Uniform1uivEXT)
|
||||
#define glUniform1uiv MANGLE(Uniform1uiv)
|
||||
#define glUniform2fARB MANGLE(Uniform2fARB)
|
||||
#define glUniform2f MANGLE(Uniform2f)
|
||||
#define glUniform2fvARB MANGLE(Uniform2fvARB)
|
||||
@@ -1488,9 +1219,7 @@
|
||||
#define glUniform2ivARB MANGLE(Uniform2ivARB)
|
||||
#define glUniform2iv MANGLE(Uniform2iv)
|
||||
#define glUniform2uiEXT MANGLE(Uniform2uiEXT)
|
||||
#define glUniform2ui MANGLE(Uniform2ui)
|
||||
#define glUniform2uivEXT MANGLE(Uniform2uivEXT)
|
||||
#define glUniform2uiv MANGLE(Uniform2uiv)
|
||||
#define glUniform3fARB MANGLE(Uniform3fARB)
|
||||
#define glUniform3f MANGLE(Uniform3f)
|
||||
#define glUniform3fvARB MANGLE(Uniform3fvARB)
|
||||
@@ -1500,9 +1229,7 @@
|
||||
#define glUniform3ivARB MANGLE(Uniform3ivARB)
|
||||
#define glUniform3iv MANGLE(Uniform3iv)
|
||||
#define glUniform3uiEXT MANGLE(Uniform3uiEXT)
|
||||
#define glUniform3ui MANGLE(Uniform3ui)
|
||||
#define glUniform3uivEXT MANGLE(Uniform3uivEXT)
|
||||
#define glUniform3uiv MANGLE(Uniform3uiv)
|
||||
#define glUniform4fARB MANGLE(Uniform4fARB)
|
||||
#define glUniform4f MANGLE(Uniform4f)
|
||||
#define glUniform4fvARB MANGLE(Uniform4fvARB)
|
||||
@@ -1512,9 +1239,7 @@
|
||||
#define glUniform4ivARB MANGLE(Uniform4ivARB)
|
||||
#define glUniform4iv MANGLE(Uniform4iv)
|
||||
#define glUniform4uiEXT MANGLE(Uniform4uiEXT)
|
||||
#define glUniform4ui MANGLE(Uniform4ui)
|
||||
#define glUniform4uivEXT MANGLE(Uniform4uivEXT)
|
||||
#define glUniform4uiv MANGLE(Uniform4uiv)
|
||||
#define glUniformBufferEXT MANGLE(UniformBufferEXT)
|
||||
#define glUniformMatrix2fvARB MANGLE(UniformMatrix2fvARB)
|
||||
#define glUniformMatrix2fv MANGLE(UniformMatrix2fv)
|
||||
@@ -1531,7 +1256,6 @@
|
||||
#define glUnlockArraysEXT MANGLE(UnlockArraysEXT)
|
||||
#define glUnmapBufferARB MANGLE(UnmapBufferARB)
|
||||
#define glUnmapBuffer MANGLE(UnmapBuffer)
|
||||
#define glUnmapNamedBufferEXT MANGLE(UnmapNamedBufferEXT)
|
||||
#define glUnmapObjectBufferATI MANGLE(UnmapObjectBufferATI)
|
||||
#define glUpdateObjectBufferATI MANGLE(UpdateObjectBufferATI)
|
||||
#define glUseProgram MANGLE(UseProgram)
|
||||
@@ -1688,49 +1412,27 @@
|
||||
#define glVertexAttrib4usvARB MANGLE(VertexAttrib4usvARB)
|
||||
#define glVertexAttrib4usv MANGLE(VertexAttrib4usv)
|
||||
#define glVertexAttribArrayObjectATI MANGLE(VertexAttribArrayObjectATI)
|
||||
#define glVertexAttribDivisor MANGLE(VertexAttribDivisor)
|
||||
#define glVertexAttribI1iEXT MANGLE(VertexAttribI1iEXT)
|
||||
#define glVertexAttribI1i MANGLE(VertexAttribI1i)
|
||||
#define glVertexAttribI1ivEXT MANGLE(VertexAttribI1ivEXT)
|
||||
#define glVertexAttribI1iv MANGLE(VertexAttribI1iv)
|
||||
#define glVertexAttribI1uiEXT MANGLE(VertexAttribI1uiEXT)
|
||||
#define glVertexAttribI1ui MANGLE(VertexAttribI1ui)
|
||||
#define glVertexAttribI1uivEXT MANGLE(VertexAttribI1uivEXT)
|
||||
#define glVertexAttribI1uiv MANGLE(VertexAttribI1uiv)
|
||||
#define glVertexAttribI2iEXT MANGLE(VertexAttribI2iEXT)
|
||||
#define glVertexAttribI2i MANGLE(VertexAttribI2i)
|
||||
#define glVertexAttribI2ivEXT MANGLE(VertexAttribI2ivEXT)
|
||||
#define glVertexAttribI2iv MANGLE(VertexAttribI2iv)
|
||||
#define glVertexAttribI2uiEXT MANGLE(VertexAttribI2uiEXT)
|
||||
#define glVertexAttribI2ui MANGLE(VertexAttribI2ui)
|
||||
#define glVertexAttribI2uivEXT MANGLE(VertexAttribI2uivEXT)
|
||||
#define glVertexAttribI2uiv MANGLE(VertexAttribI2uiv)
|
||||
#define glVertexAttribI3iEXT MANGLE(VertexAttribI3iEXT)
|
||||
#define glVertexAttribI3i MANGLE(VertexAttribI3i)
|
||||
#define glVertexAttribI3ivEXT MANGLE(VertexAttribI3ivEXT)
|
||||
#define glVertexAttribI3iv MANGLE(VertexAttribI3iv)
|
||||
#define glVertexAttribI3uiEXT MANGLE(VertexAttribI3uiEXT)
|
||||
#define glVertexAttribI3ui MANGLE(VertexAttribI3ui)
|
||||
#define glVertexAttribI3uivEXT MANGLE(VertexAttribI3uivEXT)
|
||||
#define glVertexAttribI3uiv MANGLE(VertexAttribI3uiv)
|
||||
#define glVertexAttribI4bvEXT MANGLE(VertexAttribI4bvEXT)
|
||||
#define glVertexAttribI4bv MANGLE(VertexAttribI4bv)
|
||||
#define glVertexAttribI4iEXT MANGLE(VertexAttribI4iEXT)
|
||||
#define glVertexAttribI4i MANGLE(VertexAttribI4i)
|
||||
#define glVertexAttribI4ivEXT MANGLE(VertexAttribI4ivEXT)
|
||||
#define glVertexAttribI4iv MANGLE(VertexAttribI4iv)
|
||||
#define glVertexAttribI4svEXT MANGLE(VertexAttribI4svEXT)
|
||||
#define glVertexAttribI4sv MANGLE(VertexAttribI4sv)
|
||||
#define glVertexAttribI4ubvEXT MANGLE(VertexAttribI4ubvEXT)
|
||||
#define glVertexAttribI4ubv MANGLE(VertexAttribI4ubv)
|
||||
#define glVertexAttribI4uiEXT MANGLE(VertexAttribI4uiEXT)
|
||||
#define glVertexAttribI4ui MANGLE(VertexAttribI4ui)
|
||||
#define glVertexAttribI4uivEXT MANGLE(VertexAttribI4uivEXT)
|
||||
#define glVertexAttribI4uiv MANGLE(VertexAttribI4uiv)
|
||||
#define glVertexAttribI4usvEXT MANGLE(VertexAttribI4usvEXT)
|
||||
#define glVertexAttribI4usv MANGLE(VertexAttribI4usv)
|
||||
#define glVertexAttribIPointerEXT MANGLE(VertexAttribIPointerEXT)
|
||||
#define glVertexAttribIPointer MANGLE(VertexAttribIPointer)
|
||||
#define glVertexAttribPointerARB MANGLE(VertexAttribPointerARB)
|
||||
#define glVertexAttribPointer MANGLE(VertexAttribPointer)
|
||||
#define glVertexAttribPointerNV MANGLE(VertexAttribPointerNV)
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -1,32 +1,31 @@
|
||||
/*
|
||||
* SGI FREE SOFTWARE LICENSE B (Version 2.0, Sept. 18, 2008)
|
||||
* Copyright (C) 1991-2000 Silicon Graphics, Inc. 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 including the dates of first publication and
|
||||
* either this permission notice or a reference to
|
||||
* http://oss.sgi.com/projects/FreeB/
|
||||
* 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
|
||||
* SILICON GRAPHICS, INC. 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.
|
||||
*
|
||||
* Except as contained in this notice, the name of Silicon Graphics, Inc.
|
||||
* shall not be used in advertising or otherwise to promote the sale, use or
|
||||
* other dealings in this Software without prior written authorization from
|
||||
* Silicon Graphics, Inc.
|
||||
*/
|
||||
** License Applicability. Except to the extent portions of this file are
|
||||
** made subject to an alternative license as permitted in the SGI Free
|
||||
** Software License B, Version 1.1 (the "License"), the contents of this
|
||||
** file are subject only to the provisions of the License. You may not use
|
||||
** this file except in compliance with the License. You may obtain a copy
|
||||
** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
|
||||
** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
|
||||
**
|
||||
** http://oss.sgi.com/projects/FreeB
|
||||
**
|
||||
** Note that, as provided in the License, the Software is distributed on an
|
||||
** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
|
||||
** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
|
||||
** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
|
||||
** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
|
||||
**
|
||||
** Original Code. The Original Code is: OpenGL Sample Implementation,
|
||||
** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
|
||||
** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
|
||||
** Copyright in any portions created by third parties is as indicated
|
||||
** elsewhere herein. All Rights Reserved.
|
||||
**
|
||||
** Additional Notice Provisions: This software was created using the
|
||||
** OpenGL(R) version 1.2.1 Sample Implementation published by SGI, but has
|
||||
** not been independently verified as being compliant with the OpenGL(R)
|
||||
** version 1.2.1 Specification.
|
||||
*/
|
||||
|
||||
#ifndef __glu_h__
|
||||
#define __glu_h__
|
||||
@@ -38,12 +37,8 @@
|
||||
#include <GL/gl.h>
|
||||
|
||||
#ifndef GLAPIENTRY
|
||||
#if defined(_MSC_VER) || defined(__MINGW32__)
|
||||
#define GLAPIENTRY __stdcall
|
||||
#else
|
||||
#define GLAPIENTRY
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifndef GLAPIENTRYP
|
||||
#define GLAPIENTRYP GLAPIENTRY *
|
||||
|
@@ -290,25 +290,17 @@ extern void glXSelectEvent( Display *dpy, GLXDrawable drawable,
|
||||
extern void glXGetSelectedEvent( Display *dpy, GLXDrawable drawable,
|
||||
unsigned long *mask );
|
||||
|
||||
/* GLX 1.3 function pointer typedefs */
|
||||
typedef GLXFBConfig * (* PFNGLXGETFBCONFIGSPROC) (Display *dpy, int screen, int *nelements);
|
||||
typedef GLXFBConfig * (* PFNGLXCHOOSEFBCONFIGPROC) (Display *dpy, int screen, const int *attrib_list, int *nelements);
|
||||
typedef int (* PFNGLXGETFBCONFIGATTRIBPROC) (Display *dpy, GLXFBConfig config, int attribute, int *value);
|
||||
typedef XVisualInfo * (* PFNGLXGETVISUALFROMFBCONFIGPROC) (Display *dpy, GLXFBConfig config);
|
||||
typedef GLXWindow (* PFNGLXCREATEWINDOWPROC) (Display *dpy, GLXFBConfig config, Window win, const int *attrib_list);
|
||||
typedef void (* PFNGLXDESTROYWINDOWPROC) (Display *dpy, GLXWindow win);
|
||||
typedef GLXPixmap (* PFNGLXCREATEPIXMAPPROC) (Display *dpy, GLXFBConfig config, Pixmap pixmap, const int *attrib_list);
|
||||
typedef void (* PFNGLXDESTROYPIXMAPPROC) (Display *dpy, GLXPixmap pixmap);
|
||||
typedef GLXPbuffer (* PFNGLXCREATEPBUFFERPROC) (Display *dpy, GLXFBConfig config, const int *attrib_list);
|
||||
typedef void (* PFNGLXDESTROYPBUFFERPROC) (Display *dpy, GLXPbuffer pbuf);
|
||||
typedef void (* PFNGLXQUERYDRAWABLEPROC) (Display *dpy, GLXDrawable draw, int attribute, unsigned int *value);
|
||||
typedef GLXContext (* PFNGLXCREATENEWCONTEXTPROC) (Display *dpy, GLXFBConfig config, int render_type, GLXContext share_list, Bool direct);
|
||||
typedef Bool (* PFNGLXMAKECONTEXTCURRENTPROC) (Display *dpy, GLXDrawable draw, GLXDrawable read, GLXContext ctx);
|
||||
typedef GLXDrawable (* PFNGLXGETCURRENTREADDRAWABLEPROC) (void);
|
||||
typedef Display * (* PFNGLXGETCURRENTDISPLAYPROC) (void);
|
||||
typedef int (* PFNGLXQUERYCONTEXTPROC) (Display *dpy, GLXContext ctx, int attribute, int *value);
|
||||
typedef void (* PFNGLXSELECTEVENTPROC) (Display *dpy, GLXDrawable draw, unsigned long event_mask);
|
||||
typedef void (* PFNGLXGETSELECTEDEVENTPROC) (Display *dpy, GLXDrawable draw, unsigned long *event_mask);
|
||||
|
||||
/* GLX 1.4 and later */
|
||||
extern void (*glXGetProcAddress(const GLubyte *procname))( void );
|
||||
|
||||
|
||||
#ifndef GLX_GLXEXT_LEGACY
|
||||
|
||||
#include <GL/glxext.h>
|
||||
|
||||
#else
|
||||
|
||||
|
||||
|
||||
/*
|
||||
@@ -324,17 +316,6 @@ extern __GLXextFuncPtr glXGetProcAddressARB (const GLubyte *);
|
||||
|
||||
|
||||
|
||||
/* GLX 1.4 and later */
|
||||
extern void (*glXGetProcAddress(const GLubyte *procname))( void );
|
||||
|
||||
/* GLX 1.4 function pointer typedefs */
|
||||
typedef __GLXextFuncPtr (* PFNGLXGETPROCADDRESSPROC) (const GLubyte *procName);
|
||||
|
||||
|
||||
#ifndef GLX_GLXEXT_LEGACY
|
||||
|
||||
#include <GL/glxext.h>
|
||||
|
||||
#endif /* GLX_GLXEXT_LEGACY */
|
||||
|
||||
|
||||
|
@@ -46,9 +46,9 @@ extern "C" {
|
||||
/*************************************************************/
|
||||
|
||||
/* Header file version number, required by OpenGL ABI for Linux */
|
||||
/* glxext.h last updated 2008/10/22 */
|
||||
/* glxext.h last updated 2008/08/10 */
|
||||
/* Current version at http://www.opengl.org/registry/ */
|
||||
#define GLX_GLXEXT_VERSION 21
|
||||
#define GLX_GLXEXT_VERSION 20
|
||||
|
||||
#ifndef GLX_VERSION_1_3
|
||||
#define GLX_WINDOW_BIT 0x00000001
|
||||
@@ -127,14 +127,6 @@ extern "C" {
|
||||
#define GLX_RGBA_FLOAT_BIT_ARB 0x00000004
|
||||
#endif
|
||||
|
||||
#ifndef GLX_ARB_create_context
|
||||
#define GLX_CONTEXT_DEBUG_BIT_ARB 0x00000001
|
||||
#define GLX_CONTEXT_FORWARD_COMPATIBLE_BIT_ARB 0x00000002
|
||||
#define GLX_CONTEXT_MAJOR_VERSION_ARB 0x2091
|
||||
#define GLX_CONTEXT_MINOR_VERSION_ARB 0x2092
|
||||
#define GLX_CONTEXT_FLAGS_ARB 0x2094
|
||||
#endif
|
||||
|
||||
#ifndef GLX_SGIS_multisample
|
||||
#define GLX_SAMPLE_BUFFERS_SGIS 100000
|
||||
#define GLX_SAMPLES_SGIS 100001
|
||||
@@ -355,20 +347,20 @@ extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef GLX_NV_present_video
|
||||
#define GLX_NUM_VIDEO_SLOTS_NV 0x20F0
|
||||
#define GLX_GLX_NUM_VIDEO_SLOTS_NV 0x20F0
|
||||
#endif
|
||||
|
||||
#ifndef GLX_NV_video_out
|
||||
#define GLX_VIDEO_OUT_COLOR_NV 0x20C3
|
||||
#define GLX_VIDEO_OUT_ALPHA_NV 0x20C4
|
||||
#define GLX_VIDEO_OUT_DEPTH_NV 0x20C5
|
||||
#define GLX_VIDEO_OUT_COLOR_AND_ALPHA_NV 0x20C6
|
||||
#define GLX_VIDEO_OUT_COLOR_AND_DEPTH_NV 0x20C7
|
||||
#define GLX_VIDEO_OUT_FRAME_NV 0x20C8
|
||||
#define GLX_VIDEO_OUT_FIELD_1_NV 0x20C9
|
||||
#define GLX_VIDEO_OUT_FIELD_2_NV 0x20CA
|
||||
#define GLX_VIDEO_OUT_STACKED_FIELDS_1_2_NV 0x20CB
|
||||
#define GLX_VIDEO_OUT_STACKED_FIELDS_2_1_NV 0x20CC
|
||||
#define GLX_GLX_VIDEO_OUT_COLOR_NV 0x20C3
|
||||
#define GLX_GLX_VIDEO_OUT_ALPHA_NV 0x20C4
|
||||
#define GLX_GLX_VIDEO_OUT_DEPTH_NV 0x20C5
|
||||
#define GLX_GLX_VIDEO_OUT_COLOR_AND_ALPHA_NV 0x20C6
|
||||
#define GLX_GLX_VIDEO_OUT_COLOR_AND_DEPTH_NV 0x20C7
|
||||
#define GLX_GLX_VIDEO_OUT_FRAME_NV 0x20C8
|
||||
#define GLX_GLX_VIDEO_OUT_FIELD_1_NV 0x20C9
|
||||
#define GLX_GLX_VIDEO_OUT_FIELD_2_NV 0x20CA
|
||||
#define GLX_GLX_VIDEO_OUT_STACKED_FIELDS_1_2_NV 0x20CB
|
||||
#define GLX_GLX_VIDEO_OUT_STACKED_FIELDS_2_1_NV 0x20CC
|
||||
#endif
|
||||
|
||||
#ifndef GLX_NV_swap_group
|
||||
@@ -510,14 +502,6 @@ typedef __GLXextFuncPtr ( * PFNGLXGETPROCADDRESSARBPROC) (const GLubyte *procNam
|
||||
#define GLX_ARB_fbconfig_float 1
|
||||
#endif
|
||||
|
||||
#ifndef GLX_ARB_create_context
|
||||
#define GLX_ARB_create_context 1
|
||||
#ifdef GLX_GLXEXT_PROTOTYPES
|
||||
extern GLXContext glXCreateContextAttribsARB (Display *, GLXFBConfig, GLXContext, Bool, const int *);
|
||||
#endif /* GLX_GLXEXT_PROTOTYPES */
|
||||
typedef GLXContext ( * PFNGLXCREATECONTEXTATTRIBSARBPROC) (Display *dpy, GLXFBConfig config, GLXContext share_context, Bool direct, const int *attrib_list);
|
||||
#endif
|
||||
|
||||
#ifndef GLX_SGIS_multisample
|
||||
#define GLX_SGIS_multisample 1
|
||||
#endif
|
||||
|
@@ -40,8 +40,8 @@
|
||||
#ifndef DRI_INTERFACE_H
|
||||
#define DRI_INTERFACE_H
|
||||
|
||||
/* For archs with no drm.h */
|
||||
#if !defined(__APPLE__) && !defined(__CYGWIN__)
|
||||
/* Make this something other than __APPLE__ for other arcs with no drm.h */
|
||||
#ifndef __APPLE__
|
||||
#include <drm.h>
|
||||
#else
|
||||
typedef unsigned int drm_context_t;
|
||||
@@ -75,10 +75,6 @@ typedef struct __DRItexOffsetExtensionRec __DRItexOffsetExtension;
|
||||
typedef struct __DRItexBufferExtensionRec __DRItexBufferExtension;
|
||||
typedef struct __DRIlegacyExtensionRec __DRIlegacyExtension;
|
||||
typedef struct __DRIswrastExtensionRec __DRIswrastExtension;
|
||||
typedef struct __DRIbufferRec __DRIbuffer;
|
||||
typedef struct __DRIdri2ExtensionRec __DRIdri2Extension;
|
||||
typedef struct __DRIdri2LoaderExtensionRec __DRIdri2LoaderExtension;
|
||||
|
||||
/*@}*/
|
||||
|
||||
|
||||
@@ -347,6 +343,29 @@ struct __DRIdamageExtensionRec {
|
||||
void *loaderPrivate);
|
||||
};
|
||||
|
||||
/**
|
||||
* DRI2 Loader extension. This extension describes the basic
|
||||
* functionality the loader needs to provide for the DRI driver.
|
||||
*/
|
||||
#define __DRI_LOADER "DRI_Loader"
|
||||
#define __DRI_LOADER_VERSION 1
|
||||
struct __DRIloaderExtensionRec {
|
||||
__DRIextension base;
|
||||
|
||||
/**
|
||||
* Ping the windowing system to get it to reemit info for the
|
||||
* specified drawable in the DRI2 event buffer.
|
||||
*
|
||||
* \param draw the drawable for which to request info
|
||||
* \param tail the new event buffer tail pointer
|
||||
*/
|
||||
void (*reemitDrawableInfo)(__DRIdrawable *draw, unsigned int *tail,
|
||||
void *loaderPrivate);
|
||||
|
||||
void (*postDamage)(__DRIdrawable *draw, struct drm_clip_rect *rects,
|
||||
int num_rects, void *loaderPrivate);
|
||||
};
|
||||
|
||||
#define __DRI_SWRAST_IMAGE_OP_DRAW 1
|
||||
#define __DRI_SWRAST_IMAGE_OP_CLEAR 2
|
||||
#define __DRI_SWRAST_IMAGE_OP_SWAP 3
|
||||
@@ -614,62 +633,4 @@ struct __DRIswrastExtensionRec {
|
||||
void *loaderPrivate);
|
||||
};
|
||||
|
||||
/**
|
||||
* DRI2 Loader extension.
|
||||
*/
|
||||
#define __DRI_BUFFER_FRONT_LEFT 0
|
||||
#define __DRI_BUFFER_BACK_LEFT 1
|
||||
#define __DRI_BUFFER_FRONT_RIGHT 2
|
||||
#define __DRI_BUFFER_BACK_RIGHT 3
|
||||
#define __DRI_BUFFER_DEPTH 4
|
||||
#define __DRI_BUFFER_STENCIL 5
|
||||
#define __DRI_BUFFER_ACCUM 6
|
||||
#define __DRI_BUFFER_FAKE_FRONT_LEFT 7
|
||||
#define __DRI_BUFFER_FAKE_FRONT_RIGHT 8
|
||||
|
||||
struct __DRIbufferRec {
|
||||
unsigned int attachment;
|
||||
unsigned int name;
|
||||
unsigned int pitch;
|
||||
unsigned int cpp;
|
||||
unsigned int flags;
|
||||
};
|
||||
|
||||
#define __DRI_DRI2_LOADER "DRI_DRI2Loader"
|
||||
#define __DRI_DRI2_LOADER_VERSION 1
|
||||
struct __DRIdri2LoaderExtensionRec {
|
||||
__DRIextension base;
|
||||
|
||||
__DRIbuffer *(*getBuffers)(__DRIdrawable *driDrawable,
|
||||
int *width, int *height,
|
||||
unsigned int *attachments, int count,
|
||||
int *out_count, void *loaderPrivate);
|
||||
};
|
||||
|
||||
/**
|
||||
* This extension provides alternative screen, drawable and context
|
||||
* constructors for DRI2.
|
||||
*/
|
||||
#define __DRI_DRI2 "DRI_DRI2"
|
||||
#define __DRI_DRI2_VERSION 1
|
||||
|
||||
struct __DRIdri2ExtensionRec {
|
||||
__DRIextension base;
|
||||
|
||||
__DRIscreen *(*createNewScreen)(int screen, int fd,
|
||||
const __DRIextension **extensions,
|
||||
const __DRIconfig ***driver_configs,
|
||||
void *loaderPrivate);
|
||||
|
||||
__DRIdrawable *(*createNewDrawable)(__DRIscreen *screen,
|
||||
const __DRIconfig *config,
|
||||
void *loaderPrivate);
|
||||
|
||||
__DRIcontext *(*createNewContext)(__DRIscreen *screen,
|
||||
const __DRIconfig *config,
|
||||
__DRIcontext *shared,
|
||||
void *loaderPrivate);
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
134
include/GL/internal/dri_sarea.h
Normal file
134
include/GL/internal/dri_sarea.h
Normal file
@@ -0,0 +1,134 @@
|
||||
/*
|
||||
* Copyright 2007 Red Hat, Inc
|
||||
* 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
|
||||
* on the rights to use, copy, modify, merge, publish, distribute, sub
|
||||
* license, 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 NON-INFRINGEMENT. IN NO EVENT SHALL
|
||||
* THE COPYRIGHT HOLDERS AND/OR THEIR SUPPLIERS 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.
|
||||
*/
|
||||
|
||||
#ifndef DRI_SAREA_H
|
||||
#define DRI_SAREA_H
|
||||
|
||||
#include <drm.h>
|
||||
|
||||
/* The DRI2 SAREA holds a list of self-describing blocks. Each block
|
||||
* is 8 byte aligned and has a common 32-bit header word. The upper
|
||||
* 16 bits describe the type of the block and the lower 16 bits the
|
||||
* size. DRI2 only defines a couple of blocks and allows drivers to
|
||||
* define driver specific blocks using type codes from 0x8000 and up.
|
||||
* The type code 0x0000 defines the end of the sarea. */
|
||||
|
||||
#define DRI2_SAREA_BLOCK_HEADER(type, size) (((type) << 16) | (size))
|
||||
#define DRI2_SAREA_BLOCK_TYPE(b) ((b) >> 16)
|
||||
#define DRI2_SAREA_BLOCK_SIZE(b) ((b) & 0xffff)
|
||||
#define DRI2_SAREA_BLOCK_NEXT(p) \
|
||||
((void *) ((unsigned char *) (p) + \
|
||||
DRI2_SAREA_BLOCK_SIZE(*(unsigned int *) p)))
|
||||
|
||||
#define DRI2_SAREA_BLOCK_END 0x0000
|
||||
#define DRI2_SAREA_BLOCK_LOCK 0x0001
|
||||
#define DRI2_SAREA_BLOCK_EVENT_BUFFER 0x0002
|
||||
|
||||
/* Chipset specific blocks start at 0x8000, 0xffff is reserved. */
|
||||
|
||||
typedef struct __DRILock __DRILock;
|
||||
typedef struct __DRIEventBuffer __DRIEventBuffer;
|
||||
typedef struct __DRIDrawableBuffer __DRIDrawableBuffer;
|
||||
typedef struct __DRIDrawableConfigEvent __DRIDrawableConfigEvent;
|
||||
typedef struct __DRIBufferAttachEvent __DRIBufferAttachEvent;
|
||||
|
||||
struct __DRILock {
|
||||
unsigned int block_header;
|
||||
drm_hw_lock_t lock;
|
||||
|
||||
/* We use this with DRM_CAS to allocate lock IDs for the real lock.*/
|
||||
unsigned int next_id;
|
||||
};
|
||||
|
||||
struct __DRIEventBuffer {
|
||||
unsigned int block_header;
|
||||
unsigned int head; /* last valid event */
|
||||
unsigned int prealloc; /* event currently being written */
|
||||
unsigned int size; /* size of data */
|
||||
unsigned char data[0];
|
||||
};
|
||||
|
||||
enum {
|
||||
/* the four standard color buffers */
|
||||
DRI_DRAWABLE_BUFFER_FRONT_LEFT = 0,
|
||||
DRI_DRAWABLE_BUFFER_BACK_LEFT = 1,
|
||||
DRI_DRAWABLE_BUFFER_FRONT_RIGHT = 2,
|
||||
DRI_DRAWABLE_BUFFER_BACK_RIGHT = 3,
|
||||
/* optional aux buffer */
|
||||
DRI_DRAWABLE_BUFFER_AUX0 = 4,
|
||||
DRI_DRAWABLE_BUFFER_AUX1 = 5,
|
||||
DRI_DRAWABLE_BUFFER_AUX2 = 6,
|
||||
DRI_DRAWABLE_BUFFER_AUX3 = 7,
|
||||
DRI_DRAWABLE_BUFFER_DEPTH = 8,
|
||||
DRI_DRAWABLE_BUFFER_STENCIL = 9,
|
||||
DRI_DRAWABLE_BUFFER_ACCUM = 10,
|
||||
/* generic renderbuffers */
|
||||
DRI_DRAWABLE_BUFFER_COLOR0 = 11,
|
||||
DRI_DRAWABLE_BUFFER_COLOR1 = 12,
|
||||
DRI_DRAWABLE_BUFFER_COLOR2 = 13,
|
||||
DRI_DRAWABLE_BUFFER_COLOR3 = 14,
|
||||
DRI_DRAWABLE_BUFFER_COLOR4 = 15,
|
||||
DRI_DRAWABLE_BUFFER_COLOR5 = 16,
|
||||
DRI_DRAWABLE_BUFFER_COLOR6 = 17,
|
||||
DRI_DRAWABLE_BUFFER_COLOR7 = 18,
|
||||
DRI_DRAWABLE_BUFFER_COUNT = 19
|
||||
};
|
||||
|
||||
struct __DRIDrawableBuffer {
|
||||
unsigned int attachment;
|
||||
unsigned int handle;
|
||||
unsigned int pitch;
|
||||
unsigned short cpp;
|
||||
|
||||
/* Upper 8 bits are driver specific, lower 8 bits generic. The
|
||||
* bits can inidicate buffer properties such as tiled, swizzled etc. */
|
||||
unsigned short flags;
|
||||
};
|
||||
|
||||
#define DRI2_EVENT_HEADER(type, size) (((type) << 16) | (size))
|
||||
#define DRI2_EVENT_TYPE(b) ((b) >> 16)
|
||||
#define DRI2_EVENT_SIZE(b) ((b) & 0xffff)
|
||||
|
||||
#define DRI2_EVENT_PAD 0x0000
|
||||
#define DRI2_EVENT_DRAWABLE_CONFIG 0x0001
|
||||
#define DRI2_EVENT_BUFFER_ATTACH 0x0002
|
||||
|
||||
struct __DRIDrawableConfigEvent {
|
||||
unsigned int event_header;
|
||||
unsigned int drawable;
|
||||
short x;
|
||||
short y;
|
||||
unsigned int width;
|
||||
unsigned int height;
|
||||
unsigned int num_rects;
|
||||
struct drm_clip_rect rects[0];
|
||||
};
|
||||
|
||||
struct __DRIBufferAttachEvent {
|
||||
unsigned int event_header;
|
||||
unsigned int drawable;
|
||||
__DRIDrawableBuffer buffer;
|
||||
};
|
||||
|
||||
#endif /* DRI_SAREA_H */
|
@@ -2,34 +2,39 @@
|
||||
#define __gl_core_h_
|
||||
|
||||
/*
|
||||
* SGI FREE SOFTWARE LICENSE B (Version 2.0, Sept. 18, 2008)
|
||||
* Copyright (C) 1991-2000 Silicon Graphics, Inc. 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 including the dates of first publication and
|
||||
* either this permission notice or a reference to
|
||||
* http://oss.sgi.com/projects/FreeB/
|
||||
* 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
|
||||
* SILICON GRAPHICS, INC. 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.
|
||||
*
|
||||
* Except as contained in this notice, the name of Silicon Graphics, Inc.
|
||||
* shall not be used in advertising or otherwise to promote the sale, use or
|
||||
* other dealings in this Software without prior written authorization from
|
||||
* Silicon Graphics, Inc.
|
||||
*/
|
||||
** License Applicability. Except to the extent portions of this file are
|
||||
** made subject to an alternative license as permitted in the SGI Free
|
||||
** Software License B, Version 1.1 (the "License"), the contents of this
|
||||
** file are subject only to the provisions of the License. You may not use
|
||||
** this file except in compliance with the License. You may obtain a copy
|
||||
** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
|
||||
** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
|
||||
**
|
||||
** http://oss.sgi.com/projects/FreeB
|
||||
**
|
||||
** Note that, as provided in the License, the Software is distributed on an
|
||||
** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
|
||||
** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
|
||||
** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
|
||||
** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
|
||||
**
|
||||
** Original Code. The Original Code is: OpenGL Sample Implementation,
|
||||
** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
|
||||
** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
|
||||
** Copyright in any portions created by third parties is as indicated
|
||||
** elsewhere herein. All Rights Reserved.
|
||||
**
|
||||
** Additional Notice Provisions: The application programming interfaces
|
||||
** established by SGI in conjunction with the Original Code are The
|
||||
** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
|
||||
** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
|
||||
** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
|
||||
** Window System(R) (Version 1.3), released October 19, 1998. This software
|
||||
** was created using the OpenGL(R) version 1.2.1 Sample Implementation
|
||||
** published by SGI, but has not been independently verified as being
|
||||
** compliant with the OpenGL(R) version 1.2.1 Specification.
|
||||
**
|
||||
*/
|
||||
|
||||
#include <sys/types.h>
|
||||
|
||||
|
@@ -1,3 +1,4 @@
|
||||
/* $XFree86: xc/programs/Xserver/GL/dri/sarea.h,v 1.11 2002/10/30 12:52:03 alanh Exp $ */
|
||||
/**
|
||||
* \file sarea.h
|
||||
* SAREA definitions.
|
||||
@@ -33,6 +34,7 @@
|
||||
* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $XFree86: xc/programs/Xserver/GL/dri/sarea.h,v 1.11 2002/10/30 12:52:03 alanh Exp $ */
|
||||
|
||||
#ifndef _SAREA_H_
|
||||
#define _SAREA_H_
|
||||
|
45
include/GL/uglglutshapes.h
Normal file
45
include/GL/uglglutshapes.h
Normal file
@@ -0,0 +1,45 @@
|
||||
/* uglglutshapes.h - Public header GLUT Shapes */
|
||||
|
||||
/* Copyright (c) Mark J. Kilgard, 1994, 1995, 1996, 1998. */
|
||||
|
||||
/* This program is freely distributable without licensing fees and is
|
||||
provided without guarantee or warrantee expressed or implied. This
|
||||
program is -not- in the public domain. */
|
||||
|
||||
#ifndef GLUTSHAPES_H
|
||||
#define GLUTSHAPES_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include <GL/gl.h>
|
||||
|
||||
void glutWireSphere (GLdouble radius, GLint slices, GLint stacks);
|
||||
void glutSolidSphere (GLdouble radius, GLint slices, GLint stacks);
|
||||
void glutWireCone (GLdouble base, GLdouble height,
|
||||
GLint slices, GLint stacks);
|
||||
void glutSolidCone (GLdouble base, GLdouble height,
|
||||
GLint slices, GLint stacks);
|
||||
void glutWireCube (GLdouble size);
|
||||
void glutSolidCube (GLdouble size);
|
||||
void glutWireTorus (GLdouble innerRadius, GLdouble outerRadius,
|
||||
GLint sides, GLint rings);
|
||||
void glutSolidTorus (GLdouble innerRadius, GLdouble outerRadius,
|
||||
GLint sides, GLint rings);
|
||||
void glutWireDodecahedron (void);
|
||||
void glutSolidDodecahedron (void);
|
||||
void glutWireOctahedron (void);
|
||||
void glutSolidOctahedron (void);
|
||||
void glutWireTetrahedron (void);
|
||||
void glutSolidTetrahedron (void);
|
||||
void glutWireIcosahedron (void);
|
||||
void glutSolidIcosahedron (void);
|
||||
void glutWireTeapot (GLdouble size);
|
||||
void glutSolidTeapot (GLdouble size);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif
|
155
include/GL/uglmesa.h
Normal file
155
include/GL/uglmesa.h
Normal file
@@ -0,0 +1,155 @@
|
||||
/* uglmesa.h - Public header UGL/Mesa */
|
||||
|
||||
/* Copyright (C) 2001 by Wind River Systems, Inc */
|
||||
|
||||
/*
|
||||
* Mesa 3-D graphics library
|
||||
* Version: 4.0
|
||||
*
|
||||
* The MIT License
|
||||
* 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 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.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Author:
|
||||
* Stephane Raimbault <stephane.raimbault@windriver.com>
|
||||
*/
|
||||
|
||||
#ifndef UGLMESA_H
|
||||
#define UGLMESA_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define UGL_MESA_MAJOR_VERSION 4
|
||||
#define UGL_MESA_MINOR_VERSION 0
|
||||
|
||||
#include <GL/gl.h>
|
||||
#include <ugl/ugl.h>
|
||||
|
||||
/*
|
||||
* Values for display mode of uglMesaCreateContext ()
|
||||
*/
|
||||
|
||||
/*
|
||||
* With these mask values, it's possible to test double buffer mode
|
||||
* with UGL_MESA_DOUBLE mask
|
||||
*
|
||||
* SINGLE 0000 0001
|
||||
* DOUBLE 0000 0110
|
||||
* - SOFT 0000 0010
|
||||
* - HARD 0000 0100
|
||||
* WINDML 0001 0000
|
||||
*
|
||||
*
|
||||
*/
|
||||
#define UGL_MESA_SINGLE 0x01
|
||||
#define UGL_MESA_DOUBLE 0x06
|
||||
#define UGL_MESA_DOUBLE_SOFTWARE 0x02
|
||||
#define UGL_MESA_DOUBLE_HARDWARE 0x04
|
||||
|
||||
#define UGL_MESA_WINDML_EXCLUSIVE 0x10
|
||||
|
||||
#define UGL_MESA_FULLSCREEN_WIDTH 0x0
|
||||
#define UGL_MESA_FULLSCREEN_HEIGHT 0x0
|
||||
|
||||
/*
|
||||
* uglMesaPixelStore() parameters:
|
||||
*/
|
||||
|
||||
#define UGL_MESA_ROW_LENGTH 0x20
|
||||
#define UGL_MESA_Y_UP 0x21
|
||||
|
||||
/*
|
||||
* Accepted by uglMesaGetIntegerv:
|
||||
*/
|
||||
|
||||
#define UGL_MESA_LEFT_X 0x01
|
||||
#define UGL_MESA_TOP_Y 0x02
|
||||
#define UGL_MESA_WIDTH 0x03
|
||||
#define UGL_MESA_HEIGHT 0x04
|
||||
#define UGL_MESA_DISPLAY_WIDTH 0x05
|
||||
#define UGL_MESA_DISPLAY_HEIGHT 0x06
|
||||
#define UGL_MESA_COLOR_FORMAT 0x07
|
||||
#define UGL_MESA_COLOR_MODEL 0x08
|
||||
#define UGL_MESA_PIXEL_FORMAT 0x09
|
||||
#define UGL_MESA_TYPE 0x0A
|
||||
#define UGL_MESA_RGB 0x0B
|
||||
#define UGL_MESA_COLOR_INDEXED 0x0C
|
||||
#define UGL_MESA_SINGLE_BUFFER 0x0D
|
||||
#define UGL_MESA_DOUBLE_BUFFER 0x0E
|
||||
#define UGL_MESA_DOUBLE_BUFFER_SOFTWARE 0x0F
|
||||
#define UGL_MESA_DOUBLE_BUFFER_HARDWARE 0x10
|
||||
|
||||
/*
|
||||
* typedefs
|
||||
*/
|
||||
|
||||
typedef struct uglMesaContext * UGL_MESA_CONTEXT;
|
||||
|
||||
UGL_MESA_CONTEXT uglMesaCreateNewContext (GLenum mode,
|
||||
UGL_MESA_CONTEXT share_list);
|
||||
|
||||
UGL_MESA_CONTEXT uglMesaCreateNewContextExt (GLenum mode,
|
||||
GLint depth_bits,
|
||||
GLint stencil_bits,
|
||||
GLint accum_red_bits,
|
||||
GLint accum_green_bits,
|
||||
GLint accum_blue_bits,
|
||||
GLint accum_alpha_bits,
|
||||
UGL_MESA_CONTEXT share_list);
|
||||
|
||||
GLboolean uglMesaMakeCurrentContext (UGL_MESA_CONTEXT umc,
|
||||
GLsizei left, GLsizei top,
|
||||
GLsizei width, GLsizei height);
|
||||
|
||||
GLboolean uglMesaMoveWindow (GLsizei dx, GLsizei dy);
|
||||
|
||||
GLboolean uglMesaMoveToWindow (GLsizei left, GLsizei top);
|
||||
|
||||
GLboolean uglMesaResizeWindow (GLsizei dw, GLsizei dh);
|
||||
|
||||
GLboolean uglMesaResizeToWindow (GLsizei width, GLsizei height);
|
||||
|
||||
void uglMesaDestroyContext (void);
|
||||
|
||||
UGL_MESA_CONTEXT uglMesaGetCurrentContext (void);
|
||||
|
||||
void uglMesaSwapBuffers (void);
|
||||
|
||||
void uglMesaPixelStore (GLint pname, GLint value);
|
||||
|
||||
void uglMesaGetIntegerv (GLint pname, GLint *value);
|
||||
|
||||
GLboolean uglMesaGetDepthBuffer (GLint *width, GLint *height,
|
||||
GLint *bytesPerValue, void **buffer);
|
||||
|
||||
GLboolean uglMesaGetColorBuffer (GLint *width, GLint *height,
|
||||
GLint *format, void **buffer);
|
||||
|
||||
GLboolean uglMesaSetColor (GLubyte index, GLfloat red,
|
||||
GLfloat green, GLfloat blue);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
#endif
|
@@ -2,34 +2,38 @@
|
||||
#define _EGL_H
|
||||
|
||||
/*
|
||||
* SGI FREE SOFTWARE LICENSE B (Version 2.0, Sept. 18, 2008)
|
||||
* Copyright (C) 1991-2000 Silicon Graphics, Inc. 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 including the dates of first publication and
|
||||
* either this permission notice or a reference to
|
||||
* http://oss.sgi.com/projects/FreeB/
|
||||
* 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
|
||||
* SILICON GRAPHICS, INC. 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.
|
||||
*
|
||||
* Except as contained in this notice, the name of Silicon Graphics, Inc.
|
||||
* shall not be used in advertising or otherwise to promote the sale, use or
|
||||
* other dealings in this Software without prior written authorization from
|
||||
* Silicon Graphics, Inc.
|
||||
*/
|
||||
** License Applicability. Except to the extent portions of this file are
|
||||
** made subject to an alternative license as permitted in the SGI Free
|
||||
** Software License B, Version 1.0 (the "License"), the contents of this
|
||||
** file are subject only to the provisions of the License. You may not use
|
||||
** this file except in compliance with the License. You may obtain a copy
|
||||
** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
|
||||
** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
|
||||
**
|
||||
** http://oss.sgi.com/projects/FreeB
|
||||
**
|
||||
** Note that, as provided in the License, the Software is distributed on an
|
||||
** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
|
||||
** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
|
||||
** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
|
||||
** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
|
||||
**
|
||||
** Original Code. The Original Code is: OpenGL Sample Implementation,
|
||||
** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
|
||||
** Inc. The Original Code is Copyright (c) 1991-2004 Silicon Graphics, Inc.
|
||||
** Copyright in any portions created by third parties is as indicated
|
||||
** elsewhere herein. All Rights Reserved.
|
||||
**
|
||||
** Additional Notice Provisions: The application programming interfaces
|
||||
** established by SGI in conjunction with the Original Code are The
|
||||
** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
|
||||
** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
|
||||
** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
|
||||
** Window System(R) (Version 1.3), released October 19, 1998. This software
|
||||
** was created using the OpenGL(R) version 1.2.1 Sample Implementation
|
||||
** published by SGI, but has not been independently verified as being
|
||||
** compliant with the OpenGL(R) version 1.2.1 Specification.
|
||||
*/
|
||||
|
||||
#if 0/*XXX TEMPORARY HACK*/
|
||||
#include <GLES/gl.h>
|
||||
|
@@ -13,20 +13,20 @@
|
||||
/*
|
||||
** These opaque EGL types are implemented as unsigned 32-bit integers:
|
||||
*/
|
||||
typedef uint32_t EGLDisplay;
|
||||
typedef uint32_t EGLConfig;
|
||||
typedef uint32_t EGLSurface;
|
||||
typedef uint32_t EGLContext;
|
||||
typedef u_int32_t EGLDisplay;
|
||||
typedef u_int32_t EGLConfig;
|
||||
typedef u_int32_t EGLSurface;
|
||||
typedef u_int32_t EGLContext;
|
||||
|
||||
/* EGL_MESA_screen_surface */
|
||||
typedef uint32_t EGLModeMESA;
|
||||
typedef uint32_t EGLScreenMESA;
|
||||
typedef u_int32_t EGLModeMESA;
|
||||
typedef u_int32_t EGLScreenMESA;
|
||||
|
||||
|
||||
/*
|
||||
** Other basic EGL types:
|
||||
*/
|
||||
typedef uint8_t EGLBoolean;
|
||||
typedef u_int8_t EGLBoolean;
|
||||
typedef int32_t EGLint;
|
||||
|
||||
typedef void * NativeDisplayType;
|
||||
|
192
include/GLView.h
Normal file
192
include/GLView.h
Normal file
@@ -0,0 +1,192 @@
|
||||
/*******************************************************************************
|
||||
/
|
||||
/ File: GLView.h
|
||||
/
|
||||
/ Copyright 1993-98, Be Incorporated, All Rights Reserved.
|
||||
/
|
||||
*******************************************************************************/
|
||||
|
||||
#ifndef BGLVIEW_H
|
||||
#define BGLVIEW_H
|
||||
|
||||
#include <GL/gl.h>
|
||||
|
||||
#define BGL_RGB 0
|
||||
#define BGL_INDEX 1
|
||||
#define BGL_SINGLE 0
|
||||
#define BGL_DOUBLE 2
|
||||
#define BGL_DIRECT 0
|
||||
#define BGL_INDIRECT 4
|
||||
#define BGL_ACCUM 8
|
||||
#define BGL_ALPHA 16
|
||||
#define BGL_DEPTH 32
|
||||
#define BGL_OVERLAY 64
|
||||
#define BGL_UNDERLAY 128
|
||||
#define BGL_STENCIL 512
|
||||
|
||||
#ifdef __cplusplus
|
||||
|
||||
|
||||
#include <AppKit.h>
|
||||
#include <interface/Window.h>
|
||||
#include <interface/View.h>
|
||||
#include <interface/Bitmap.h>
|
||||
#include <game/WindowScreen.h>
|
||||
#include <game/DirectWindow.h>
|
||||
|
||||
class BGLView : public BView {
|
||||
public:
|
||||
|
||||
BGLView(BRect rect, char *name,
|
||||
ulong resizingMode, ulong mode,
|
||||
ulong options);
|
||||
virtual ~BGLView();
|
||||
|
||||
void LockGL();
|
||||
void UnlockGL();
|
||||
void SwapBuffers();
|
||||
void SwapBuffers( bool vSync );
|
||||
BView * EmbeddedView();
|
||||
status_t CopyPixelsOut(BPoint source, BBitmap *dest);
|
||||
status_t CopyPixelsIn(BBitmap *source, BPoint dest);
|
||||
virtual void ErrorCallback(unsigned long errorCode); // Mesa's GLenum is uint where Be's ones was ulong!
|
||||
|
||||
virtual void Draw(BRect updateRect);
|
||||
|
||||
virtual void AttachedToWindow();
|
||||
virtual void AllAttached();
|
||||
virtual void DetachedFromWindow();
|
||||
virtual void AllDetached();
|
||||
|
||||
virtual void FrameResized(float width, float height);
|
||||
virtual status_t Perform(perform_code d, void *arg);
|
||||
|
||||
/* The public methods below, for the moment,
|
||||
are just pass-throughs to BView */
|
||||
|
||||
virtual status_t Archive(BMessage *data, bool deep = true) const;
|
||||
|
||||
virtual void MessageReceived(BMessage *msg);
|
||||
virtual void SetResizingMode(uint32 mode);
|
||||
|
||||
virtual void Show();
|
||||
virtual void Hide();
|
||||
|
||||
virtual BHandler *ResolveSpecifier(BMessage *msg, int32 index,
|
||||
BMessage *specifier, int32 form,
|
||||
const char *property);
|
||||
virtual status_t GetSupportedSuites(BMessage *data);
|
||||
|
||||
/* New public functions */
|
||||
void DirectConnected( direct_buffer_info *info );
|
||||
void EnableDirectMode( bool enabled );
|
||||
|
||||
void * getGC() { return m_gc; }
|
||||
|
||||
private:
|
||||
|
||||
virtual void _ReservedGLView1();
|
||||
virtual void _ReservedGLView2();
|
||||
virtual void _ReservedGLView3();
|
||||
virtual void _ReservedGLView4();
|
||||
virtual void _ReservedGLView5();
|
||||
virtual void _ReservedGLView6();
|
||||
virtual void _ReservedGLView7();
|
||||
virtual void _ReservedGLView8();
|
||||
|
||||
BGLView(const BGLView &);
|
||||
BGLView &operator=(const BGLView &);
|
||||
|
||||
void dither_front();
|
||||
bool confirm_dither();
|
||||
void draw(BRect r);
|
||||
|
||||
void * m_gc;
|
||||
uint32 m_options;
|
||||
uint32 m_ditherCount;
|
||||
BLocker m_drawLock;
|
||||
BLocker m_displayLock;
|
||||
void * m_clip_info;
|
||||
void * _Unused1;
|
||||
|
||||
BBitmap * m_ditherMap;
|
||||
BRect m_bounds;
|
||||
int16 * m_errorBuffer[2];
|
||||
uint64 _reserved[8];
|
||||
|
||||
/* Direct Window stuff */
|
||||
private:
|
||||
void drawScanline( int x1, int x2, int y, void *data );
|
||||
static void scanlineHandler(struct rasStateRec *state, GLint x1, GLint x2);
|
||||
|
||||
void lock_draw();
|
||||
void unlock_draw();
|
||||
bool validateView();
|
||||
};
|
||||
|
||||
|
||||
|
||||
class BGLScreen : public BWindowScreen {
|
||||
public:
|
||||
BGLScreen(char *name,
|
||||
ulong screenMode, ulong options,
|
||||
status_t *error, bool debug=false);
|
||||
~BGLScreen();
|
||||
|
||||
void LockGL();
|
||||
void UnlockGL();
|
||||
void SwapBuffers();
|
||||
virtual void ErrorCallback(GLenum errorCode);
|
||||
|
||||
virtual void ScreenConnected(bool connected);
|
||||
virtual void FrameResized(float width, float height);
|
||||
virtual status_t Perform(perform_code d, void *arg);
|
||||
|
||||
/* The public methods below, for the moment,
|
||||
are just pass-throughs to BWindowScreen */
|
||||
|
||||
virtual status_t Archive(BMessage *data, bool deep = true) const;
|
||||
virtual void MessageReceived(BMessage *msg);
|
||||
|
||||
virtual void Show();
|
||||
virtual void Hide();
|
||||
|
||||
virtual BHandler *ResolveSpecifier(BMessage *msg,
|
||||
int32 index,
|
||||
BMessage *specifier,
|
||||
int32 form,
|
||||
const char *property);
|
||||
virtual status_t GetSupportedSuites(BMessage *data);
|
||||
|
||||
private:
|
||||
|
||||
virtual void _ReservedGLScreen1();
|
||||
virtual void _ReservedGLScreen2();
|
||||
virtual void _ReservedGLScreen3();
|
||||
virtual void _ReservedGLScreen4();
|
||||
virtual void _ReservedGLScreen5();
|
||||
virtual void _ReservedGLScreen6();
|
||||
virtual void _ReservedGLScreen7();
|
||||
virtual void _ReservedGLScreen8();
|
||||
|
||||
BGLScreen(const BGLScreen &);
|
||||
BGLScreen &operator=(const BGLScreen &);
|
||||
|
||||
void * m_gc;
|
||||
long m_options;
|
||||
BLocker m_drawLock;
|
||||
|
||||
int32 m_colorSpace;
|
||||
uint32 m_screen_mode;
|
||||
|
||||
uint64 _reserved[7];
|
||||
};
|
||||
|
||||
#endif // __cplusplus
|
||||
|
||||
#endif // BGLVIEW_H
|
||||
|
||||
|
||||
|
||||
|
||||
|
@@ -1,3 +1,4 @@
|
||||
// $Id: demo.cpp,v 1.2 2004/08/14 09:59:16 phoudoin Exp $
|
||||
|
||||
// Simple BeOS GLView demo
|
||||
// Written by Brian Paul
|
||||
|
@@ -37,7 +37,7 @@
|
||||
static GLboolean Anim = GL_TRUE;
|
||||
static GLfloat Xpos = 0;
|
||||
static GLuint OccQuery;
|
||||
static GLint Win = 0;
|
||||
|
||||
|
||||
|
||||
static void
|
||||
@@ -204,7 +204,6 @@ static void Key( unsigned char key, int x, int y )
|
||||
(void) y;
|
||||
switch (key) {
|
||||
case 27:
|
||||
glutDestroyWindow(Win);
|
||||
exit(0);
|
||||
break;
|
||||
case ' ':
|
||||
@@ -272,7 +271,7 @@ int main( int argc, char *argv[] )
|
||||
glutInitWindowPosition( 0, 0 );
|
||||
glutInitWindowSize( 400, 400 );
|
||||
glutInitDisplayMode( GLUT_RGB | GLUT_DOUBLE | GLUT_DEPTH );
|
||||
Win = glutCreateWindow(argv[0]);
|
||||
glutCreateWindow(argv[0]);
|
||||
glutReshapeFunc( Reshape );
|
||||
glutKeyboardFunc( Key );
|
||||
glutSpecialFunc( SpecialKey );
|
||||
|
@@ -154,7 +154,6 @@ static GLuint TexObj;
|
||||
static GLuint MyFB;
|
||||
static GLuint DepthRB;
|
||||
static GLboolean WireFrame = GL_FALSE;
|
||||
static GLboolean Anim = GL_TRUE;
|
||||
static GLint texType = 0;
|
||||
|
||||
static GLint T0 = 0;
|
||||
@@ -164,11 +163,6 @@ static GLint Win = 0;
|
||||
static GLfloat ViewRotX = 20.0, ViewRotY = 30.0, ViewRotZ = 0.0;
|
||||
static GLfloat CubeRot = 0.0;
|
||||
|
||||
|
||||
static void
|
||||
idle(void);
|
||||
|
||||
|
||||
static void
|
||||
CheckError(int line)
|
||||
{
|
||||
@@ -567,7 +561,7 @@ drawfire(void)
|
||||
printstring(GLUT_BITMAP_HELVETICA_18, texNames[texType]);
|
||||
glColor3f(1.0, 0.0, 0.0);
|
||||
glRasterPos2i(10, 470);
|
||||
printstring(GLUT_BITMAP_HELVETICA_10,
|
||||
printstring(GLUT_BITMAP_HELVETICA_10,
|
||||
"Fire V1.5 Written by David Bucciarelli (tech.hmw@plus.it)");
|
||||
|
||||
if (help)
|
||||
@@ -611,10 +605,7 @@ key(unsigned char key, int x, int y)
|
||||
cleanup();
|
||||
exit(0);
|
||||
break;
|
||||
case ' ':
|
||||
Anim = !Anim;
|
||||
glutIdleFunc(Anim ? idle : NULL);
|
||||
break;
|
||||
|
||||
case 'a':
|
||||
v += 0.0005;
|
||||
break;
|
||||
@@ -1022,7 +1013,7 @@ static void
|
||||
visible(int vis)
|
||||
{
|
||||
if (vis == GLUT_VISIBLE)
|
||||
glutIdleFunc(Anim ? idle : NULL);
|
||||
glutIdleFunc(idle);
|
||||
else
|
||||
glutIdleFunc(NULL);
|
||||
}
|
||||
|
@@ -114,7 +114,7 @@ static void calcposobs(void)
|
||||
rainParticle::setRainingArea(obs[0]-7.0f,-0.2f,obs[2]-7.0f,obs[0]+7.0f,8.0f,obs[2]+7.0f);
|
||||
}
|
||||
|
||||
static void printstring(void *font, const char *string)
|
||||
static void printstring(void *font, char *string)
|
||||
{
|
||||
int len,i;
|
||||
|
||||
|
@@ -1,3 +1,4 @@
|
||||
/* $Id: gears.c,v 1.3 1999/08/22 08:56:50 jtaylor Exp $ */
|
||||
|
||||
/*
|
||||
* 3-D gear wheels. This program is in the public domain.
|
||||
|
1
progs/glsl/.gitignore
vendored
1
progs/glsl/.gitignore
vendored
@@ -4,7 +4,6 @@ bump
|
||||
deriv
|
||||
extfuncs.h
|
||||
mandelbrot
|
||||
multinoise
|
||||
multitex
|
||||
noise
|
||||
points
|
||||
|
@@ -15,21 +15,15 @@ PROGS = \
|
||||
bump \
|
||||
convolutions \
|
||||
deriv \
|
||||
fragcoord \
|
||||
mandelbrot \
|
||||
multinoise \
|
||||
multitex \
|
||||
noise \
|
||||
points \
|
||||
pointcoord \
|
||||
samplers \
|
||||
skinning \
|
||||
texdemo1 \
|
||||
toyball \
|
||||
twoside \
|
||||
trirast \
|
||||
vert-or-frag-only \
|
||||
vert-tex
|
||||
trirast
|
||||
|
||||
|
||||
##### RULES #####
|
||||
@@ -111,13 +105,6 @@ deriv: deriv.o shaderutil.o
|
||||
$(CC) -I$(INCDIR) $(CFLAGS) $(LDFLAGS) deriv.o shaderutil.o $(LIBS) -o $@
|
||||
|
||||
|
||||
fragcoord.o: fragcoord.c extfuncs.h shaderutil.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) fragcoord.c
|
||||
|
||||
fragcoord: fragcoord.o shaderutil.o
|
||||
$(CC) -I$(INCDIR) $(CFLAGS) $(LDFLAGS) fragcoord.o shaderutil.o $(LIBS) -o $@
|
||||
|
||||
|
||||
mandelbrot.o: mandelbrot.c extfuncs.h shaderutil.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) mandelbrot.c
|
||||
|
||||
@@ -153,20 +140,6 @@ pointcoord: pointcoord.o readtex.o shaderutil.o
|
||||
$(CC) -I$(INCDIR) $(CFLAGS) $(LDFLAGS) pointcoord.o readtex.o shaderutil.o $(LIBS) -o $@
|
||||
|
||||
|
||||
samplers.o: samplers.c readtex.h extfuncs.h shaderutil.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) samplers.c
|
||||
|
||||
samplers: samplers.o readtex.o shaderutil.o
|
||||
$(CC) -I$(INCDIR) $(CFLAGS) $(LDFLAGS) samplers.o readtex.o shaderutil.o $(LIBS) -o $@
|
||||
|
||||
|
||||
skinning.o: skinning.c readtex.h extfuncs.h shaderutil.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) skinning.c
|
||||
|
||||
skinning: skinning.o readtex.o shaderutil.o
|
||||
$(CC) -I$(INCDIR) $(CFLAGS) $(LDFLAGS) skinning.o readtex.o shaderutil.o $(LIBS) -o $@
|
||||
|
||||
|
||||
texdemo1.o: texdemo1.c readtex.h extfuncs.h shaderutil.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) texdemo1.c
|
||||
|
||||
@@ -195,20 +168,6 @@ trirast: trirast.o shaderutil.o
|
||||
$(CC) -I$(INCDIR) $(CFLAGS) $(LDFLAGS) trirast.o shaderutil.o $(LIBS) -o $@
|
||||
|
||||
|
||||
vert-or-frag-only.o: vert-or-frag-only.c extfuncs.h shaderutil.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) vert-or-frag-only.c
|
||||
|
||||
vert-or-frag-only: vert-or-frag-only.o shaderutil.o
|
||||
$(CC) -I$(INCDIR) $(CFLAGS) $(LDFLAGS) vert-or-frag-only.o shaderutil.o $(LIBS) -o $@
|
||||
|
||||
|
||||
|
||||
vert-tex.o: vert-tex.c extfuncs.h shaderutil.h
|
||||
$(CC) -c -I$(INCDIR) $(CFLAGS) vert-tex.c
|
||||
|
||||
vert-tex: vert-tex.o shaderutil.o
|
||||
$(CC) -I$(INCDIR) $(CFLAGS) $(LDFLAGS) vert-tex.o shaderutil.o $(LIBS) -o $@
|
||||
|
||||
|
||||
|
||||
|
||||
|
@@ -141,6 +141,9 @@ Redisplay(void)
|
||||
|
||||
glPopMatrix();
|
||||
|
||||
glFinish();
|
||||
glFlush();
|
||||
|
||||
CheckError(__LINE__);
|
||||
|
||||
glutSwapBuffers();
|
||||
|
@@ -438,6 +438,8 @@ static void draw()
|
||||
|
||||
glPopMatrix();
|
||||
|
||||
glFlush();
|
||||
|
||||
glutSwapBuffers();
|
||||
}
|
||||
|
||||
|
@@ -1,185 +0,0 @@
|
||||
/**
|
||||
* Test GLSL gl_FragCoord fragment program attribute.
|
||||
* Color the quad's fragments according to their window position.
|
||||
*
|
||||
* Brian Paul
|
||||
* 20 Nov 2008
|
||||
*/
|
||||
|
||||
|
||||
#include <assert.h>
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <math.h>
|
||||
#include <GL/gl.h>
|
||||
#include <GL/glut.h>
|
||||
#include <GL/glext.h>
|
||||
#include "extfuncs.h"
|
||||
#include "shaderutil.h"
|
||||
|
||||
|
||||
static GLint WinWidth = 200, WinHeight = 200;
|
||||
static char *FragProgFile = NULL;
|
||||
static char *VertProgFile = NULL;
|
||||
static GLuint fragShader;
|
||||
static GLuint vertShader;
|
||||
static GLuint program;
|
||||
static GLint win = 0;
|
||||
static GLboolean Anim = GL_TRUE;
|
||||
static GLfloat PosX = 0.0, PosY = 0.0;
|
||||
|
||||
|
||||
static void
|
||||
Idle(void)
|
||||
{
|
||||
float r = (WinWidth < WinHeight) ? WinWidth : WinHeight;
|
||||
float a = glutGet(GLUT_ELAPSED_TIME) * 0.001;
|
||||
r *= 0.25;
|
||||
PosX = WinWidth / 2 + r * cos(a);
|
||||
PosY = WinHeight / 2 + r * sin(a);
|
||||
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Redisplay(void)
|
||||
{
|
||||
glClear(GL_COLOR_BUFFER_BIT);
|
||||
|
||||
glPushMatrix();
|
||||
glTranslatef(PosX, PosY, 0.0);
|
||||
#if 0
|
||||
glBegin(GL_POLYGON);
|
||||
glVertex2f(-50, -50);
|
||||
glVertex2f( 50, -50);
|
||||
glVertex2f( 50, 50);
|
||||
glVertex2f(-50, 50);
|
||||
glEnd();
|
||||
#else
|
||||
glutSolidSphere(50, 20, 10);
|
||||
#endif
|
||||
glPopMatrix();
|
||||
|
||||
glutSwapBuffers();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Reshape(int width, int height)
|
||||
{
|
||||
glViewport(0, 0, width, height);
|
||||
glMatrixMode(GL_PROJECTION);
|
||||
glLoadIdentity();
|
||||
glOrtho(0, width, 0, height, -55, 55);
|
||||
|
||||
glMatrixMode(GL_MODELVIEW);
|
||||
glLoadIdentity();
|
||||
|
||||
WinWidth = width;
|
||||
WinHeight = height;
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
CleanUp(void)
|
||||
{
|
||||
glDeleteShader_func(fragShader);
|
||||
glDeleteShader_func(vertShader);
|
||||
glDeleteProgram_func(program);
|
||||
glutDestroyWindow(win);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Key(unsigned char key, int x, int y)
|
||||
{
|
||||
(void) x;
|
||||
(void) y;
|
||||
|
||||
switch(key) {
|
||||
case ' ':
|
||||
case 'a':
|
||||
Anim = !Anim;
|
||||
glutIdleFunc(Anim ? Idle : NULL);
|
||||
break;
|
||||
case 27:
|
||||
CleanUp();
|
||||
exit(0);
|
||||
break;
|
||||
}
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Init(void)
|
||||
{
|
||||
static const char *fragShaderText =
|
||||
"void main() { \n"
|
||||
" vec4 scale = vec4(.005, 0.005, 0.5, 1.0);\n"
|
||||
" gl_FragColor = gl_FragCoord * scale; \n"
|
||||
"}\n";
|
||||
static const char *vertShaderText =
|
||||
"void main() {\n"
|
||||
" gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;\n"
|
||||
"}\n";
|
||||
|
||||
if (!ShadersSupported())
|
||||
exit(1);
|
||||
|
||||
GetExtensionFuncs();
|
||||
|
||||
vertShader = CompileShaderText(GL_VERTEX_SHADER, vertShaderText);
|
||||
fragShader = CompileShaderText(GL_FRAGMENT_SHADER, fragShaderText);
|
||||
program = LinkShaders(vertShader, fragShader);
|
||||
|
||||
glUseProgram_func(program);
|
||||
|
||||
/*assert(glGetError() == 0);*/
|
||||
|
||||
glClearColor(0.3f, 0.3f, 0.3f, 0.0f);
|
||||
|
||||
printf("GL_RENDERER = %s\n",(const char *) glGetString(GL_RENDERER));
|
||||
|
||||
assert(glIsProgram_func(program));
|
||||
assert(glIsShader_func(fragShader));
|
||||
assert(glIsShader_func(vertShader));
|
||||
|
||||
glColor3f(1, 0, 0);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
ParseOptions(int argc, char *argv[])
|
||||
{
|
||||
int i;
|
||||
for (i = 1; i < argc; i++) {
|
||||
if (strcmp(argv[i], "-fs") == 0) {
|
||||
FragProgFile = argv[i+1];
|
||||
}
|
||||
else if (strcmp(argv[i], "-vs") == 0) {
|
||||
VertProgFile = argv[i+1];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
main(int argc, char *argv[])
|
||||
{
|
||||
glutInit(&argc, argv);
|
||||
glutInitWindowPosition( 0, 0);
|
||||
glutInitWindowSize(WinWidth, WinHeight);
|
||||
glutInitDisplayMode(GLUT_RGB | GLUT_DOUBLE);
|
||||
win = glutCreateWindow(argv[0]);
|
||||
glutReshapeFunc(Reshape);
|
||||
glutKeyboardFunc(Key);
|
||||
glutDisplayFunc(Redisplay);
|
||||
ParseOptions(argc, argv);
|
||||
Init();
|
||||
glutIdleFunc(Anim ? Idle : NULL);
|
||||
glutMainLoop();
|
||||
return 0;
|
||||
}
|
@@ -74,6 +74,8 @@ Redisplay(void)
|
||||
|
||||
glPopMatrix();
|
||||
|
||||
glFinish();
|
||||
glFlush();
|
||||
glutSwapBuffers();
|
||||
}
|
||||
|
||||
|
@@ -1,281 +0,0 @@
|
||||
/**
|
||||
* Another test for noise() functions (noise1 to noise4 tested independently).
|
||||
* 13 Dec 2008
|
||||
*/
|
||||
|
||||
#include <assert.h>
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <math.h>
|
||||
#include <GL/gl.h>
|
||||
#include <GL/glut.h>
|
||||
#include <GL/glext.h>
|
||||
#include "extfuncs.h"
|
||||
|
||||
static const char *VertShaderText =
|
||||
"void main() {\n"
|
||||
" gl_TexCoord[0].xyz = gl_Vertex.xyz;\n"
|
||||
" gl_TexCoord[0].w = gl_MultiTexCoord1.x;\n"
|
||||
" gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;\n"
|
||||
"}\n";
|
||||
|
||||
static const char *FragShaderText[ 4 ] = {
|
||||
"void main()\n"
|
||||
"{\n"
|
||||
" gl_FragColor.rgb = noise3( gl_TexCoord[ 0 ].w ) * 0.5 + 0.5;\n"
|
||||
" gl_FragColor.a = 1;\n"
|
||||
"}\n",
|
||||
"void main()\n"
|
||||
"{\n"
|
||||
" gl_FragColor.rgb = noise3( gl_TexCoord[ 0 ].xw ) * 0.5 + 0.5;\n"
|
||||
" gl_FragColor.a = 1;\n"
|
||||
"}\n",
|
||||
"void main()\n"
|
||||
"{\n"
|
||||
" gl_FragColor.rgb = noise3( gl_TexCoord[ 0 ].xyw ) * 0.5 + 0.5;\n"
|
||||
" gl_FragColor.a = 1;\n"
|
||||
"}\n",
|
||||
"void main()\n"
|
||||
"{\n"
|
||||
" gl_FragColor.rgb = noise3( gl_TexCoord[ 0 ].xyzw ) * 0.5 + 0.5;\n"
|
||||
" gl_FragColor.a = 1;\n"
|
||||
"}\n"
|
||||
};
|
||||
|
||||
struct uniform_info {
|
||||
const char *name;
|
||||
GLuint size;
|
||||
GLint location;
|
||||
GLfloat value[4];
|
||||
};
|
||||
|
||||
/* program/shader objects */
|
||||
static GLuint fragShader[ 4 ];
|
||||
static GLuint vertShader;
|
||||
static GLuint program[ 4 ];
|
||||
|
||||
static GLint win = 0;
|
||||
static GLfloat xRot = 0.0f, yRot = 0.0f, zRot = 0.0f;
|
||||
static GLfloat Slice = 0.0;
|
||||
static GLboolean Anim = GL_FALSE;
|
||||
|
||||
|
||||
static void
|
||||
Idle(void)
|
||||
{
|
||||
Slice += 0.01;
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Redisplay(void)
|
||||
{
|
||||
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
|
||||
|
||||
glMultiTexCoord1f( GL_TEXTURE1, Slice );
|
||||
|
||||
glPushMatrix();
|
||||
glRotatef(xRot, 1.0f, 0.0f, 0.0f);
|
||||
glRotatef(yRot, 0.0f, 1.0f, 0.0f);
|
||||
glRotatef(zRot, 0.0f, 0.0f, 1.0f);
|
||||
|
||||
glutSolidTeapot( 1.0 );
|
||||
|
||||
glPopMatrix();
|
||||
|
||||
glutSwapBuffers();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Reshape(int width, int height)
|
||||
{
|
||||
glViewport(0, 0, width, height);
|
||||
glMatrixMode(GL_PROJECTION);
|
||||
glLoadIdentity();
|
||||
glFrustum(-1.0, 1.0, -1.0, 1.0, 5.0, 25.0);
|
||||
glMatrixMode(GL_MODELVIEW);
|
||||
glLoadIdentity();
|
||||
glTranslatef(0.0f, 0.0f, -15.0f);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
CleanUp(void)
|
||||
{
|
||||
GLint i;
|
||||
|
||||
glDeleteShader_func(vertShader);
|
||||
for( i = 0; i < 4; i++ ) {
|
||||
glDeleteShader_func(fragShader[ i ]);
|
||||
glDeleteProgram_func(program[ i ]);
|
||||
}
|
||||
glutDestroyWindow(win);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Key(unsigned char key, int x, int y)
|
||||
{
|
||||
const GLfloat step = 0.01;
|
||||
(void) x;
|
||||
(void) y;
|
||||
|
||||
switch(key) {
|
||||
case 'a':
|
||||
Anim = !Anim;
|
||||
glutIdleFunc(Anim ? Idle : NULL);
|
||||
case 's':
|
||||
Slice -= step;
|
||||
break;
|
||||
case 'S':
|
||||
Slice += step;
|
||||
break;
|
||||
case 'z':
|
||||
zRot -= 1.0;
|
||||
break;
|
||||
case 'Z':
|
||||
zRot += 1.0;
|
||||
break;
|
||||
case '1':
|
||||
case '2':
|
||||
case '3':
|
||||
case '4':
|
||||
glUseProgram_func(program[ key - '1' ]);
|
||||
break;
|
||||
case 27:
|
||||
CleanUp();
|
||||
exit(0);
|
||||
break;
|
||||
}
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
SpecialKey(int key, int x, int y)
|
||||
{
|
||||
const GLfloat step = 3.0f;
|
||||
|
||||
(void) x;
|
||||
(void) y;
|
||||
|
||||
switch(key) {
|
||||
case GLUT_KEY_UP:
|
||||
xRot -= step;
|
||||
break;
|
||||
case GLUT_KEY_DOWN:
|
||||
xRot += step;
|
||||
break;
|
||||
case GLUT_KEY_LEFT:
|
||||
yRot -= step;
|
||||
break;
|
||||
case GLUT_KEY_RIGHT:
|
||||
yRot += step;
|
||||
break;
|
||||
}
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
|
||||
static void
|
||||
LoadAndCompileShader(GLuint shader, const char *text)
|
||||
{
|
||||
GLint stat;
|
||||
|
||||
glShaderSource_func(shader, 1, (const GLchar **) &text, NULL);
|
||||
|
||||
glCompileShader_func(shader);
|
||||
|
||||
glGetShaderiv_func(shader, GL_COMPILE_STATUS, &stat);
|
||||
if (!stat) {
|
||||
GLchar log[1000];
|
||||
GLsizei len;
|
||||
glGetShaderInfoLog_func(shader, 1000, &len, log);
|
||||
fprintf(stderr, "noise: problem compiling shader: %s\n", log);
|
||||
exit(1);
|
||||
}
|
||||
else {
|
||||
printf("Shader compiled OK\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
CheckLink(GLuint prog)
|
||||
{
|
||||
GLint stat;
|
||||
glGetProgramiv_func(prog, GL_LINK_STATUS, &stat);
|
||||
if (!stat) {
|
||||
GLchar log[1000];
|
||||
GLsizei len;
|
||||
glGetProgramInfoLog_func(prog, 1000, &len, log);
|
||||
fprintf(stderr, "Linker error:\n%s\n", log);
|
||||
}
|
||||
else {
|
||||
fprintf(stderr, "Link success!\n");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Init(void)
|
||||
{
|
||||
const char *version;
|
||||
GLint i;
|
||||
|
||||
version = (const char *) glGetString(GL_VERSION);
|
||||
if (version[0] != '2' || version[1] != '.') {
|
||||
printf("Warning: this program expects OpenGL 2.0\n");
|
||||
/*exit(1);*/
|
||||
}
|
||||
|
||||
GetExtensionFuncs();
|
||||
|
||||
vertShader = glCreateShader_func(GL_VERTEX_SHADER);
|
||||
LoadAndCompileShader(vertShader, VertShaderText);
|
||||
|
||||
for( i = 0; i < 4; i++ ) {
|
||||
fragShader[ i ] = glCreateShader_func(GL_FRAGMENT_SHADER);
|
||||
LoadAndCompileShader(fragShader[ i ], FragShaderText[ i ]);
|
||||
program[ i ] = glCreateProgram_func();
|
||||
glAttachShader_func(program[ i ], fragShader[ i ]);
|
||||
glAttachShader_func(program[ i ], vertShader);
|
||||
glLinkProgram_func(program[ i ]);
|
||||
CheckLink(program[ i ]);
|
||||
}
|
||||
|
||||
glUseProgram_func(program[ 0 ]);
|
||||
|
||||
assert(glGetError() == 0);
|
||||
|
||||
glClearColor(0.4f, 0.4f, 0.8f, 0.0f);
|
||||
|
||||
glColor3f(1, 0, 0);
|
||||
|
||||
glFrontFace( GL_CW );
|
||||
glEnable( GL_CULL_FACE );
|
||||
glEnable( GL_DEPTH_TEST );
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
main(int argc, char *argv[])
|
||||
{
|
||||
glutInit(&argc, argv);
|
||||
glutInitWindowPosition( 0, 0);
|
||||
glutInitWindowSize(400, 400);
|
||||
glutInitDisplayMode(GLUT_RGB | GLUT_DOUBLE | GLUT_DEPTH);
|
||||
win = glutCreateWindow(argv[0]);
|
||||
glutReshapeFunc(Reshape);
|
||||
glutKeyboardFunc(Key);
|
||||
glutSpecialFunc(SpecialKey);
|
||||
glutDisplayFunc(Redisplay);
|
||||
Init();
|
||||
glutMainLoop();
|
||||
return 0;
|
||||
}
|
||||
|
@@ -47,12 +47,9 @@ static const char *TexFiles[2] =
|
||||
|
||||
static GLuint Program;
|
||||
|
||||
static GLfloat Xrot = 0.0, Yrot = .0, Zrot = 0.0;
|
||||
static GLfloat Xrot = -90.0, Yrot = .0, Zrot = 0.0;
|
||||
static GLfloat EyeDist = 10;
|
||||
static GLboolean Anim = GL_TRUE;
|
||||
static GLboolean UseArrays = GL_TRUE;
|
||||
|
||||
static GLint VertCoord_attr = -1, TexCoord0_attr = -1, TexCoord1_attr = -1;
|
||||
|
||||
|
||||
/* value[0] = tex unit */
|
||||
@@ -63,62 +60,32 @@ static struct uniform_info Uniforms[] = {
|
||||
};
|
||||
|
||||
|
||||
static const GLfloat Tex0Coords[4][2] = {
|
||||
{ 0.0, 0.0 }, { 2.0, 0.0 }, { 2.0, 2.0 }, { 0.0, 2.0 }
|
||||
};
|
||||
|
||||
static const GLfloat Tex1Coords[4][2] = {
|
||||
{ 0.0, 0.0 }, { 1.0, 0.0 }, { 1.0, 1.0 }, { 0.0, 1.0 }
|
||||
};
|
||||
|
||||
static const GLfloat VertCoords[4][2] = {
|
||||
{ -3.0, -3.0 }, { 3.0, -3.0 }, { 3.0, 3.0 }, { -3.0, 3.0 }
|
||||
};
|
||||
|
||||
|
||||
static void
|
||||
DrawPolygonArray(void)
|
||||
DrawPolygon(GLfloat size)
|
||||
{
|
||||
if (VertCoord_attr >= 0) {
|
||||
glVertexAttribPointer_func(VertCoord_attr, 2, GL_FLOAT, GL_FALSE,
|
||||
0, VertCoords);
|
||||
glEnableVertexAttribArray_func(VertCoord_attr);
|
||||
}
|
||||
else {
|
||||
glVertexPointer(2, GL_FLOAT, 0, VertCoords);
|
||||
glEnable(GL_VERTEX_ARRAY);
|
||||
}
|
||||
glPushMatrix();
|
||||
glRotatef(90, 1, 0, 0);
|
||||
glNormal3f(0, 0, 1);
|
||||
glBegin(GL_POLYGON);
|
||||
|
||||
glVertexAttribPointer_func(TexCoord0_attr, 2, GL_FLOAT, GL_FALSE,
|
||||
0, Tex0Coords);
|
||||
glEnableVertexAttribArray_func(TexCoord0_attr);
|
||||
glMultiTexCoord2f(GL_TEXTURE0, 0, 0);
|
||||
glMultiTexCoord2f(GL_TEXTURE1, 0, 0);
|
||||
glVertex2f(-size, -size);
|
||||
|
||||
glVertexAttribPointer_func(TexCoord1_attr, 2, GL_FLOAT, GL_FALSE,
|
||||
0, Tex1Coords);
|
||||
glEnableVertexAttribArray_func(TexCoord1_attr);
|
||||
glMultiTexCoord2f(GL_TEXTURE0, 2, 0);
|
||||
glMultiTexCoord2f(GL_TEXTURE1, 1, 0);
|
||||
glVertex2f( size, -size);
|
||||
|
||||
glDrawArrays(GL_TRIANGLE_FAN, 0, 4);
|
||||
}
|
||||
glMultiTexCoord2f(GL_TEXTURE0, 2, 2);
|
||||
glMultiTexCoord2f(GL_TEXTURE1, 1, 1);
|
||||
glVertex2f( size, size);
|
||||
|
||||
|
||||
static void
|
||||
DrawPolygonVert(void)
|
||||
{
|
||||
GLuint i;
|
||||
|
||||
glBegin(GL_TRIANGLE_FAN);
|
||||
|
||||
for (i = 0; i < 4; i++) {
|
||||
glVertexAttrib2fv_func(TexCoord0_attr, Tex0Coords[i]);
|
||||
glVertexAttrib2fv_func(TexCoord1_attr, Tex1Coords[i]);
|
||||
|
||||
if (VertCoord_attr >= 0)
|
||||
glVertexAttrib2fv_func(VertCoord_attr, VertCoords[i]);
|
||||
else
|
||||
glVertex2fv(VertCoords[i]);
|
||||
}
|
||||
glMultiTexCoord2f(GL_TEXTURE0, 0, 2);
|
||||
glMultiTexCoord2f(GL_TEXTURE1, 0, 1);
|
||||
glVertex2f(-size, size);
|
||||
|
||||
glEnd();
|
||||
glPopMatrix();
|
||||
}
|
||||
|
||||
|
||||
@@ -133,10 +100,7 @@ draw(void)
|
||||
glRotatef(Yrot, 0, 1, 0);
|
||||
glRotatef(Xrot, 1, 0, 0);
|
||||
|
||||
if (UseArrays)
|
||||
DrawPolygonArray();
|
||||
else
|
||||
DrawPolygonVert();
|
||||
DrawPolygon(3.0);
|
||||
|
||||
glPopMatrix();
|
||||
|
||||
@@ -159,11 +123,8 @@ key(unsigned char k, int x, int y)
|
||||
(void) x;
|
||||
(void) y;
|
||||
switch (k) {
|
||||
case 'a':
|
||||
UseArrays = !UseArrays;
|
||||
printf("Arrays: %d\n", UseArrays);
|
||||
break;
|
||||
case ' ':
|
||||
case 'a':
|
||||
Anim = !Anim;
|
||||
if (Anim)
|
||||
glutIdleFunc(idle);
|
||||
@@ -271,13 +232,6 @@ CreateProgram(const char *vertProgFile, const char *fragProgFile,
|
||||
|
||||
InitUniforms(program, uniforms);
|
||||
|
||||
TexCoord0_attr = glGetAttribLocation_func(program, "TexCoord0");
|
||||
TexCoord1_attr = glGetAttribLocation_func(program, "TexCoord1");
|
||||
VertCoord_attr = glGetAttribLocation_func(program, "VertCoord");
|
||||
printf("TexCoord0_attr = %d\n", TexCoord0_attr);
|
||||
printf("TexCoord1_attr = %d\n", TexCoord1_attr);
|
||||
printf("VertCoord_attr = %d\n", VertCoord_attr);
|
||||
|
||||
return program;
|
||||
}
|
||||
|
||||
|
@@ -2,13 +2,9 @@
|
||||
// Brian Paul
|
||||
|
||||
|
||||
attribute vec4 TexCoord0, TexCoord1;
|
||||
attribute vec4 VertCoord;
|
||||
|
||||
void main()
|
||||
{
|
||||
gl_TexCoord[0] = TexCoord0;
|
||||
gl_TexCoord[1] = TexCoord1;
|
||||
// note: may use gl_Vertex or VertCoord here for testing:
|
||||
gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex;
|
||||
gl_TexCoord[0] = gl_MultiTexCoord0;
|
||||
gl_TexCoord[1] = gl_MultiTexCoord1;
|
||||
gl_Position = ftransform();
|
||||
}
|
||||
|
@@ -30,7 +30,6 @@ static const char *FragShaderText =
|
||||
" vec4 p;\n"
|
||||
" p.xy = gl_TexCoord[0].xy;\n"
|
||||
" p.z = Slice;\n"
|
||||
" p.w = 0;\n"
|
||||
" vec4 n = noise4(p * scale);\n"
|
||||
" gl_FragColor = n * Scale + Bias;\n"
|
||||
"}\n";
|
||||
|
@@ -1,357 +0,0 @@
|
||||
/**
|
||||
* Exercise all available GLSL texture samplers.
|
||||
*
|
||||
* Copyright (C) 2009 VMware, Inc. 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.
|
||||
*/
|
||||
|
||||
/**
|
||||
* We generate a fragment shader which uses the maximum number of supported
|
||||
* texture samplers.
|
||||
* For each sampler we create a separate texture. Each texture has a
|
||||
* single strip of color at a different intensity. The fragment shader
|
||||
* samples all the textures at the same coordinate and sums the values.
|
||||
* The result should be a quad with rows of colors of increasing intensity
|
||||
* from bottom to top.
|
||||
*
|
||||
* Brian Paul
|
||||
* 1 Jan 2009
|
||||
*/
|
||||
|
||||
#include <assert.h>
|
||||
#include <math.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include "GL/glut.h"
|
||||
#include "readtex.h"
|
||||
#include "extfuncs.h"
|
||||
#include "shaderutil.h"
|
||||
|
||||
|
||||
#define MAX_SAMPLERS 128
|
||||
|
||||
|
||||
static const char *Demo = "samplers";
|
||||
|
||||
static GLuint Program;
|
||||
static GLint NumSamplers;
|
||||
static GLuint Textures[MAX_SAMPLERS];
|
||||
static GLfloat Xrot = 0.0, Yrot = .0, Zrot = 0.0;
|
||||
static GLfloat EyeDist = 10;
|
||||
static GLboolean Anim = GL_FALSE;
|
||||
|
||||
|
||||
static void
|
||||
DrawPolygon(GLfloat size)
|
||||
{
|
||||
glPushMatrix();
|
||||
glNormal3f(0, 0, 1);
|
||||
glBegin(GL_POLYGON);
|
||||
|
||||
glMultiTexCoord2f(GL_TEXTURE0, 0, 0);
|
||||
glVertex2f(-size, -size);
|
||||
|
||||
glMultiTexCoord2f(GL_TEXTURE0, 1, 0);
|
||||
glVertex2f( size, -size);
|
||||
|
||||
glMultiTexCoord2f(GL_TEXTURE0, 1, 1);
|
||||
glVertex2f( size, size);
|
||||
|
||||
glMultiTexCoord2f(GL_TEXTURE0, 0, 1);
|
||||
glVertex2f(-size, size);
|
||||
|
||||
glEnd();
|
||||
glPopMatrix();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
draw(void)
|
||||
{
|
||||
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
|
||||
|
||||
glPushMatrix();
|
||||
glTranslatef(0.0, 0.0, -EyeDist);
|
||||
glRotatef(Zrot, 0, 0, 1);
|
||||
glRotatef(Yrot, 0, 1, 0);
|
||||
glRotatef(Xrot, 1, 0, 0);
|
||||
|
||||
DrawPolygon(3.0);
|
||||
|
||||
glPopMatrix();
|
||||
|
||||
glutSwapBuffers();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
idle(void)
|
||||
{
|
||||
GLfloat t = 0.05 * glutGet(GLUT_ELAPSED_TIME);
|
||||
Yrot = t;
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
key(unsigned char k, int x, int y)
|
||||
{
|
||||
(void) x;
|
||||
(void) y;
|
||||
switch (k) {
|
||||
case ' ':
|
||||
case 'a':
|
||||
Anim = !Anim;
|
||||
if (Anim)
|
||||
glutIdleFunc(idle);
|
||||
else
|
||||
glutIdleFunc(NULL);
|
||||
break;
|
||||
case 'z':
|
||||
EyeDist -= 0.5;
|
||||
if (EyeDist < 3.0)
|
||||
EyeDist = 3.0;
|
||||
break;
|
||||
case 'Z':
|
||||
EyeDist += 0.5;
|
||||
if (EyeDist > 90.0)
|
||||
EyeDist = 90;
|
||||
break;
|
||||
case 27:
|
||||
exit(0);
|
||||
}
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
specialkey(int key, int x, int y)
|
||||
{
|
||||
GLfloat step = 2.0;
|
||||
(void) x;
|
||||
(void) y;
|
||||
switch (key) {
|
||||
case GLUT_KEY_UP:
|
||||
Xrot += step;
|
||||
break;
|
||||
case GLUT_KEY_DOWN:
|
||||
Xrot -= step;
|
||||
break;
|
||||
case GLUT_KEY_LEFT:
|
||||
Yrot -= step;
|
||||
break;
|
||||
case GLUT_KEY_RIGHT:
|
||||
Yrot += step;
|
||||
break;
|
||||
}
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
/* new window size or exposure */
|
||||
static void
|
||||
Reshape(int width, int height)
|
||||
{
|
||||
GLfloat ar = (float) width / (float) height;
|
||||
glViewport(0, 0, (GLint)width, (GLint)height);
|
||||
glMatrixMode(GL_PROJECTION);
|
||||
glLoadIdentity();
|
||||
glFrustum(-2.0*ar, 2.0*ar, -2.0, 2.0, 4.0, 100.0);
|
||||
glMatrixMode(GL_MODELVIEW);
|
||||
glLoadIdentity();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
InitTextures(void)
|
||||
{
|
||||
const GLint size = MAX_SAMPLERS;
|
||||
GLubyte *texImage;
|
||||
GLenum filter = GL_NEAREST;
|
||||
GLint stripeSize;
|
||||
GLint s;
|
||||
|
||||
texImage = (GLubyte *) malloc(size * size * 4);
|
||||
|
||||
glGenTextures(NumSamplers, Textures);
|
||||
|
||||
/* size of texels stripe */
|
||||
stripeSize = size / NumSamplers;
|
||||
|
||||
/* create a texture for each sampler */
|
||||
for (s = 0; s < NumSamplers; s++) {
|
||||
GLint x, y, ypos;
|
||||
GLubyte intensity = 31 + s * (256-32) / (NumSamplers - 1);
|
||||
|
||||
printf("Texture %d: color = %d, %d, %d\n", s,
|
||||
(int) intensity, 0, (int) intensity );
|
||||
|
||||
/* initialize the texture to black */
|
||||
memset(texImage, 0, size * size * 4);
|
||||
|
||||
/* set a stripe of texels to the intensity value */
|
||||
ypos = s * stripeSize;
|
||||
for (y = 0; y < stripeSize; y++) {
|
||||
for (x = 0; x < size; x++) {
|
||||
GLint k = 4 * ((ypos + y) * size + x);
|
||||
texImage[k + 0] = intensity;
|
||||
texImage[k + 1] = intensity;
|
||||
texImage[k + 2] = 0;
|
||||
texImage[k + 3] = 255;
|
||||
}
|
||||
}
|
||||
|
||||
glActiveTexture(GL_TEXTURE0 + s);
|
||||
glBindTexture(GL_TEXTURE_2D, Textures[s]);
|
||||
gluBuild2DMipmaps(GL_TEXTURE_2D, 4, size, size,
|
||||
GL_RGBA, GL_UNSIGNED_BYTE, texImage);
|
||||
|
||||
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT);
|
||||
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT);
|
||||
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, filter);
|
||||
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, filter);
|
||||
}
|
||||
|
||||
free(texImage);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Generate a fragment shader that uses the given number of samplers.
|
||||
*/
|
||||
static char *
|
||||
GenFragmentShader(GLint numSamplers)
|
||||
{
|
||||
const int maxLen = 10 * 1000;
|
||||
char *prog = (char *) malloc(maxLen);
|
||||
char *p = prog;
|
||||
int s;
|
||||
|
||||
p += sprintf(p, "// Generated fragment shader:\n");
|
||||
for (s = 0; s < numSamplers; s++) {
|
||||
p += sprintf(p, "uniform sampler2D tex%d;\n", s);
|
||||
}
|
||||
p += sprintf(p, "void main()\n");
|
||||
p += sprintf(p, "{\n");
|
||||
p += sprintf(p, " vec4 color = vec4(0.0);\n");
|
||||
for (s = 0; s < numSamplers; s++) {
|
||||
p += sprintf(p, " color += texture2D(tex%d, gl_TexCoord[0].xy);\n", s);
|
||||
}
|
||||
p += sprintf(p, " gl_FragColor = color;\n");
|
||||
p += sprintf(p, "}\n");
|
||||
|
||||
assert(p - prog < maxLen);
|
||||
return prog;
|
||||
}
|
||||
|
||||
|
||||
/** Create & bind shader program */
|
||||
static GLuint
|
||||
CreateProgram(void)
|
||||
{
|
||||
GLuint fragShader, vertShader, program;
|
||||
const char *vertShaderText =
|
||||
"void main() \n"
|
||||
"{ \n"
|
||||
" gl_TexCoord[0] = gl_MultiTexCoord0; \n"
|
||||
" gl_Position = ftransform(); \n"
|
||||
"} \n";
|
||||
char *fragShaderText = GenFragmentShader(NumSamplers);
|
||||
|
||||
printf("%s", fragShaderText);
|
||||
|
||||
vertShader = CompileShaderText(GL_VERTEX_SHADER, vertShaderText);
|
||||
fragShader = CompileShaderText(GL_FRAGMENT_SHADER, fragShaderText);
|
||||
assert(vertShader);
|
||||
program = LinkShaders(vertShader, fragShader);
|
||||
|
||||
glUseProgram_func(program);
|
||||
|
||||
free(fragShaderText);
|
||||
|
||||
return program;
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
InitProgram(void)
|
||||
{
|
||||
GLint s;
|
||||
|
||||
Program = CreateProgram();
|
||||
|
||||
/* init sampler uniforms */
|
||||
for (s = 0; s < NumSamplers; s++) {
|
||||
char uname[10];
|
||||
GLint loc;
|
||||
|
||||
sprintf(uname, "tex%d", s);
|
||||
loc = glGetUniformLocation_func(Program, uname);
|
||||
assert(loc >= 0);
|
||||
|
||||
glUniform1i_func(loc, s);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
InitGL(void)
|
||||
{
|
||||
if (!ShadersSupported()) {
|
||||
printf("GLSL not supported!\n");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
printf("GL_RENDERER = %s\n", (const char *) glGetString(GL_RENDERER));
|
||||
|
||||
GetExtensionFuncs();
|
||||
|
||||
glGetIntegerv(GL_MAX_TEXTURE_IMAGE_UNITS, &NumSamplers);
|
||||
if (NumSamplers > MAX_SAMPLERS)
|
||||
NumSamplers = MAX_SAMPLERS;
|
||||
printf("Testing %d samplers\n", NumSamplers);
|
||||
|
||||
InitTextures();
|
||||
InitProgram();
|
||||
|
||||
glClearColor(.6, .6, .9, 0);
|
||||
glColor3f(1.0, 1.0, 1.0);
|
||||
|
||||
printf("Each color corresponds to a separate sampler/texture.\n");
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
main(int argc, char *argv[])
|
||||
{
|
||||
glutInit(&argc, argv);
|
||||
glutInitWindowSize(500, 400);
|
||||
glutInitDisplayMode(GLUT_RGB | GLUT_DEPTH | GLUT_DOUBLE);
|
||||
glutCreateWindow(Demo);
|
||||
glutReshapeFunc(Reshape);
|
||||
glutKeyboardFunc(key);
|
||||
glutSpecialFunc(specialkey);
|
||||
glutDisplayFunc(draw);
|
||||
if (Anim)
|
||||
glutIdleFunc(idle);
|
||||
InitGL();
|
||||
glutMainLoop();
|
||||
return 0;
|
||||
}
|
@@ -1,280 +0,0 @@
|
||||
/**
|
||||
* Vertex "skinning" example.
|
||||
* The idea is there are multiple modeling matrices applied to every
|
||||
* vertex. Weighting values in [0,1] control the influence of each
|
||||
* matrix on each vertex.
|
||||
*
|
||||
* 4 Nov 2008
|
||||
*/
|
||||
|
||||
#include <assert.h>
|
||||
#include <string.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <math.h>
|
||||
#include <GL/gl.h>
|
||||
#include <GL/glut.h>
|
||||
#include <GL/glext.h>
|
||||
#include "extfuncs.h"
|
||||
#include "shaderutil.h"
|
||||
|
||||
|
||||
static char *FragProgFile = "skinning.frag";
|
||||
static char *VertProgFile = "skinning.vert";
|
||||
|
||||
/* program/shader objects */
|
||||
static GLuint fragShader;
|
||||
static GLuint vertShader;
|
||||
static GLuint program;
|
||||
|
||||
|
||||
static GLint win = 0;
|
||||
static GLboolean Anim = GL_TRUE;
|
||||
static GLboolean WireFrame = GL_TRUE;
|
||||
static GLfloat xRot = 0.0f, yRot = 90.0f, zRot = 0.0f;
|
||||
|
||||
#define NUM_MATS 2
|
||||
|
||||
static GLfloat Matrices[NUM_MATS][16];
|
||||
static GLint uMat0, uMat1;
|
||||
static GLint WeightAttr;
|
||||
|
||||
|
||||
static void
|
||||
Idle(void)
|
||||
{
|
||||
yRot = 90 + glutGet(GLUT_ELAPSED_TIME) * 0.005;
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Cylinder(GLfloat length, GLfloat radius, GLint slices, GLint stacks)
|
||||
{
|
||||
float dw = 1.0 / (stacks - 1);
|
||||
float dz = length / stacks;
|
||||
int i, j;
|
||||
|
||||
for (j = 0; j < stacks; j++) {
|
||||
float w0 = j * dw;
|
||||
float z0 = j * dz;
|
||||
|
||||
glBegin(GL_TRIANGLE_STRIP);
|
||||
for (i = 0; i < slices; i++) {
|
||||
float a = (float) i / (slices - 1) * M_PI * 2.0;
|
||||
float x = radius * cos(a);
|
||||
float y = radius * sin(a);
|
||||
glVertexAttrib1f_func(WeightAttr, w0);
|
||||
glNormal3f(x, y, 0.0);
|
||||
glVertex3f(x, y, z0);
|
||||
|
||||
glVertexAttrib1f_func(WeightAttr, w0 + dw);
|
||||
glNormal3f(x, y, 0.0);
|
||||
glVertex3f(x, y, z0 + dz);
|
||||
}
|
||||
glEnd();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Update/animate the two matrices. One rotates, the other scales.
|
||||
*/
|
||||
static void
|
||||
UpdateMatrices(void)
|
||||
{
|
||||
GLfloat t = glutGet(GLUT_ELAPSED_TIME) * 0.0025;
|
||||
GLfloat scale = 0.5 * (1.1 + sin(0.5 * t));
|
||||
GLfloat rot = cos(t) * 90.0;
|
||||
|
||||
glPushMatrix();
|
||||
glLoadIdentity();
|
||||
glScalef(1.0, scale, 1.0);
|
||||
glGetFloatv(GL_MODELVIEW_MATRIX, Matrices[0]);
|
||||
glPopMatrix();
|
||||
|
||||
glPushMatrix();
|
||||
glLoadIdentity();
|
||||
glRotatef(rot, 0, 0, 1);
|
||||
glGetFloatv(GL_MODELVIEW_MATRIX, Matrices[1]);
|
||||
glPopMatrix();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Redisplay(void)
|
||||
{
|
||||
UpdateMatrices();
|
||||
|
||||
glUniformMatrix4fv_func(uMat0, 1, GL_FALSE, Matrices[0]);
|
||||
glUniformMatrix4fv_func(uMat1, 1, GL_FALSE, Matrices[1]);
|
||||
|
||||
if (WireFrame)
|
||||
glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
|
||||
else
|
||||
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
|
||||
|
||||
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
|
||||
|
||||
glPushMatrix();
|
||||
glRotatef(xRot, 1.0f, 0.0f, 0.0f);
|
||||
glRotatef(yRot, 0.0f, 1.0f, 0.0f);
|
||||
glRotatef(zRot, 0.0f, 0.0f, 1.0f);
|
||||
|
||||
glPushMatrix();
|
||||
glTranslatef(0, 0, -2.5);
|
||||
Cylinder(5.0, 1.0, 10, 20);
|
||||
glPopMatrix();
|
||||
|
||||
glPopMatrix();
|
||||
|
||||
glutSwapBuffers();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Reshape(int width, int height)
|
||||
{
|
||||
glViewport(0, 0, width, height);
|
||||
glMatrixMode(GL_PROJECTION);
|
||||
glLoadIdentity();
|
||||
glFrustum(-1.0, 1.0, -1.0, 1.0, 5.0, 25.0);
|
||||
glMatrixMode(GL_MODELVIEW);
|
||||
glLoadIdentity();
|
||||
glTranslatef(0.0f, 0.0f, -15.0f);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
CleanUp(void)
|
||||
{
|
||||
glDeleteShader_func(fragShader);
|
||||
glDeleteShader_func(vertShader);
|
||||
glDeleteProgram_func(program);
|
||||
glutDestroyWindow(win);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Key(unsigned char key, int x, int y)
|
||||
{
|
||||
const GLfloat step = 2.0;
|
||||
(void) x;
|
||||
(void) y;
|
||||
|
||||
switch(key) {
|
||||
case 'a':
|
||||
Anim = !Anim;
|
||||
if (Anim)
|
||||
glutIdleFunc(Idle);
|
||||
else
|
||||
glutIdleFunc(NULL);
|
||||
break;
|
||||
case 'w':
|
||||
WireFrame = !WireFrame;
|
||||
break;
|
||||
case 'z':
|
||||
zRot += step;
|
||||
break;
|
||||
case 'Z':
|
||||
zRot -= step;
|
||||
break;
|
||||
case 27:
|
||||
CleanUp();
|
||||
exit(0);
|
||||
break;
|
||||
}
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
SpecialKey(int key, int x, int y)
|
||||
{
|
||||
const GLfloat step = 2.0;
|
||||
|
||||
(void) x;
|
||||
(void) y;
|
||||
|
||||
switch(key) {
|
||||
case GLUT_KEY_UP:
|
||||
xRot += step;
|
||||
break;
|
||||
case GLUT_KEY_DOWN:
|
||||
xRot -= step;
|
||||
break;
|
||||
case GLUT_KEY_LEFT:
|
||||
yRot -= step;
|
||||
break;
|
||||
case GLUT_KEY_RIGHT:
|
||||
yRot += step;
|
||||
break;
|
||||
}
|
||||
glutPostRedisplay();
|
||||
}
|
||||
|
||||
|
||||
|
||||
static void
|
||||
Init(void)
|
||||
{
|
||||
if (!ShadersSupported())
|
||||
exit(1);
|
||||
|
||||
GetExtensionFuncs();
|
||||
|
||||
vertShader = CompileShaderFile(GL_VERTEX_SHADER, VertProgFile);
|
||||
fragShader = CompileShaderFile(GL_FRAGMENT_SHADER, FragProgFile);
|
||||
program = LinkShaders(vertShader, fragShader);
|
||||
|
||||
glUseProgram_func(program);
|
||||
|
||||
uMat0 = glGetUniformLocation_func(program, "mat0");
|
||||
uMat1 = glGetUniformLocation_func(program, "mat1");
|
||||
|
||||
WeightAttr = glGetAttribLocation_func(program, "weight");
|
||||
|
||||
assert(glGetError() == 0);
|
||||
|
||||
glClearColor(0.4f, 0.4f, 0.8f, 0.0f);
|
||||
|
||||
glEnable(GL_DEPTH_TEST);
|
||||
|
||||
glColor3f(1, 0, 0);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
ParseOptions(int argc, char *argv[])
|
||||
{
|
||||
int i;
|
||||
for (i = 1; i < argc; i++) {
|
||||
if (strcmp(argv[i], "-fs") == 0) {
|
||||
FragProgFile = argv[i+1];
|
||||
}
|
||||
else if (strcmp(argv[i], "-vs") == 0) {
|
||||
VertProgFile = argv[i+1];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
main(int argc, char *argv[])
|
||||
{
|
||||
glutInit(&argc, argv);
|
||||
glutInitWindowSize(500, 500);
|
||||
glutInitDisplayMode(GLUT_RGB | GLUT_DOUBLE | GLUT_DEPTH);
|
||||
win = glutCreateWindow(argv[0]);
|
||||
glutReshapeFunc(Reshape);
|
||||
glutKeyboardFunc(Key);
|
||||
glutSpecialFunc(SpecialKey);
|
||||
glutDisplayFunc(Redisplay);
|
||||
ParseOptions(argc, argv);
|
||||
Init();
|
||||
if (Anim)
|
||||
glutIdleFunc(Idle);
|
||||
glutMainLoop();
|
||||
return 0;
|
||||
}
|
||||
|
@@ -1,6 +0,0 @@
|
||||
// color pass-through
|
||||
|
||||
void main()
|
||||
{
|
||||
gl_FragColor = gl_Color;
|
||||
}
|
@@ -1,24 +0,0 @@
|
||||
// Vertex weighting/blendin shader
|
||||
// Brian Paul
|
||||
// 4 Nov 2008
|
||||
|
||||
uniform mat4 mat0, mat1;
|
||||
attribute float weight;
|
||||
|
||||
void main()
|
||||
{
|
||||
// simple diffuse shading
|
||||
// Note that we should really transform the normal vector along with
|
||||
// the postion below... someday.
|
||||
vec3 lightVec = vec3(0, 0, 1);
|
||||
vec3 norm = gl_NormalMatrix * gl_Normal;
|
||||
float dot = 0.2 + max(0.0, dot(norm, lightVec));
|
||||
gl_FrontColor = vec4(dot);
|
||||
|
||||
// compute sum of weighted transformations
|
||||
vec4 pos0 = mat0 * gl_Vertex;
|
||||
vec4 pos1 = mat1 * gl_Vertex;
|
||||
vec4 pos = mix(pos0, pos1, weight);
|
||||
|
||||
gl_Position = gl_ModelViewProjectionMatrix * pos;
|
||||
}
|
@@ -79,6 +79,8 @@ Redisplay(void)
|
||||
|
||||
glPopMatrix();
|
||||
|
||||
glFinish();
|
||||
glFlush();
|
||||
glutSwapBuffers();
|
||||
}
|
||||
|
||||
|
@@ -26,39 +26,27 @@ static GLuint fragShader;
|
||||
static GLuint vertShader;
|
||||
static GLuint program;
|
||||
static GLint win = 0;
|
||||
static GLboolean anim;
|
||||
static GLboolean DetermineFacingInFragProg;
|
||||
static GLfloat Xrot;
|
||||
static GLboolean anim = 0*GL_TRUE;
|
||||
static GLboolean DetermineInFragProg = GL_TRUE;
|
||||
static GLfloat Xrot = 30.0f;
|
||||
static GLint u_fragface;
|
||||
static GLenum FrontWinding;
|
||||
static GLenum FrontWinding = GL_CCW;
|
||||
static int prevTime = 0;
|
||||
|
||||
|
||||
static const GLfloat Red[4] = {1, 0, 0, 1};
|
||||
static const GLfloat Red[4] = {1, 0, 0, 0};
|
||||
static const GLfloat Green[4] = {0, 1, 0, 0};
|
||||
|
||||
|
||||
static void
|
||||
SetDefaults(void)
|
||||
{
|
||||
DetermineFacingInFragProg = GL_TRUE;
|
||||
FrontWinding = GL_CCW;
|
||||
Xrot = 30;
|
||||
anim = 0;
|
||||
glutIdleFunc(NULL);
|
||||
}
|
||||
|
||||
|
||||
static void
|
||||
Redisplay(void)
|
||||
{
|
||||
const int sections = 20;
|
||||
int i;
|
||||
float radius = 2;
|
||||
|
||||
glFrontFace(FrontWinding);
|
||||
|
||||
if (DetermineFacingInFragProg) {
|
||||
if (DetermineInFragProg) {
|
||||
glUniform1i_func(u_fragface, 1);
|
||||
glDisable(GL_VERTEX_PROGRAM_TWO_SIDE);
|
||||
}
|
||||
@@ -76,8 +64,8 @@ Redisplay(void)
|
||||
glBegin(GL_TRIANGLE_STRIP);
|
||||
glColor4fv(Red);
|
||||
glSecondaryColor3fv_func(Green);
|
||||
for (i = 0; i <= sections; i++) {
|
||||
float a = (float) i / (sections) * M_PI * 2.0;
|
||||
for (i = 0; i < 20; i++) {
|
||||
float a = i / 19.0 * M_PI * 2.0;
|
||||
float x = radius * cos(a);
|
||||
float y = radius * sin(a);
|
||||
glVertex3f(x, -1, y);
|
||||
@@ -151,15 +139,17 @@ Key(unsigned char key, int x, int y)
|
||||
break;
|
||||
case 'f':
|
||||
printf("Using frag shader gl_FrontFacing\n");
|
||||
DetermineFacingInFragProg = GL_TRUE;
|
||||
DetermineInFragProg = GL_TRUE;
|
||||
break;
|
||||
case 'v':
|
||||
printf("Using vert shader Two-sided lighting\n");
|
||||
DetermineFacingInFragProg = GL_FALSE;
|
||||
DetermineInFragProg = GL_FALSE;
|
||||
break;
|
||||
case 'r':
|
||||
/* reset */
|
||||
SetDefaults();
|
||||
Xrot = 30;
|
||||
anim = 0;
|
||||
glutIdleFunc(NULL);
|
||||
break;
|
||||
case 's':
|
||||
Xrot += 5;
|
||||
@@ -192,16 +182,14 @@ Init(void)
|
||||
static const char *fragShaderText =
|
||||
"uniform bool fragface; \n"
|
||||
"void main() { \n"
|
||||
#if 1
|
||||
#if 0
|
||||
" if (!fragface || gl_FrontFacing) { \n"
|
||||
" gl_FragColor = gl_Color; \n"
|
||||
" } \n"
|
||||
" else { \n"
|
||||
" // note: dim green to help debug \n"
|
||||
" gl_FragColor = 0.8 * gl_SecondaryColor; \n"
|
||||
" } \n"
|
||||
#else
|
||||
/* DEBUG CODE */
|
||||
" bool f = gl_FrontFacing; \n"
|
||||
" if (f) { \n"
|
||||
" gl_FragColor = vec4(1.0, 0.0, 0.0, 0.0); \n"
|
||||
@@ -209,6 +197,8 @@ Init(void)
|
||||
" else { \n"
|
||||
" gl_FragColor = vec4(0.0, 1.0, 0.0, 0.0); \n"
|
||||
" } \n"
|
||||
" //float g = float(gl_FrontFacing) * 0.5 + 0.5; \n"
|
||||
" //gl_FragColor = vec4(g); \n"
|
||||
#endif
|
||||
"} \n";
|
||||
static const char *vertShaderText =
|
||||
@@ -251,8 +241,6 @@ Init(void)
|
||||
assert(glIsShader_func(vertShader));
|
||||
|
||||
glEnable(GL_DEPTH_TEST);
|
||||
|
||||
SetDefaults();
|
||||
}
|
||||
|
||||
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user