Compare commits
95 Commits
mesa-9.2-r
...
mesa-9.2.3
Author | SHA1 | Date | |
---|---|---|---|
|
f4657c4e10 | ||
|
a6252a56a5 | ||
|
cf33e6d85d | ||
|
69d5778b36 | ||
|
9b8c5847e6 | ||
|
6e491b875f | ||
|
57cd553eda | ||
|
95a708abe6 | ||
|
8c2e3c8275 | ||
|
81245daed3 | ||
|
e5ed198f35 | ||
|
52a6ebe200 | ||
|
5dc0d13e3d | ||
|
dbeb24c39b | ||
|
621a461cd9 | ||
|
259448d02f | ||
|
c8e0d10c0a | ||
|
26c599e00a | ||
|
6f966b58a1 | ||
|
6e557f03f3 | ||
|
7ab2b8c4c4 | ||
|
0048df9cd0 | ||
|
8f0742051e | ||
|
8eb1046996 | ||
|
cc6ad9ce2c | ||
|
82d5b5e20f | ||
|
bf9be81b47 | ||
|
995dc3782b | ||
|
cd5ea2788d | ||
|
f1257f5fe0 | ||
|
cde1ff2d7c | ||
|
eb69e251a8 | ||
|
fb3e55f898 | ||
|
6d6d8fb073 | ||
|
9eae0c95f8 | ||
|
fac3094fef | ||
|
8c4c3d01ee | ||
|
2c3aa1b4ee | ||
|
5377bc3e40 | ||
|
486aecac7e | ||
|
8fc8f38d94 | ||
|
dfcc8caf25 | ||
|
c8ae770068 | ||
|
88513d6485 | ||
|
2eb55601bb | ||
|
26ffbf6f39 | ||
|
421141192f | ||
|
be029eb993 | ||
|
f7fba18e2e | ||
|
42b6d94537 | ||
|
563c488453 | ||
|
4babf9ba6b | ||
|
8a9099d4ef | ||
|
beebb2d9d5 | ||
|
e021b50227 | ||
|
3801e9a87e | ||
|
faec15dc7a | ||
|
5461cc1f00 | ||
|
4fbbf49cc5 | ||
|
130fda3d3b | ||
|
3a2926fdbf | ||
|
616da8f818 | ||
|
72295c5f67 | ||
|
a6a2039a44 | ||
|
f53b9849a1 | ||
|
50ffa8bac5 | ||
|
0547f28134 | ||
|
47da22626d | ||
|
c3de1eea7f | ||
|
ab9322534c | ||
|
2cda3f0e90 | ||
|
3b852f9d52 | ||
|
fd31f5ee1d | ||
|
c0253baaa0 | ||
|
9dd4e1ef85 | ||
|
fbbe25ef26 | ||
|
e5f788e1e0 | ||
|
26ae6ec1e8 | ||
|
9586f4de71 | ||
|
fa892ecc04 | ||
|
2377205bcb | ||
|
8218eebc80 | ||
|
46273ba256 | ||
|
d3f99fb532 | ||
|
6fb2032c35 | ||
|
c0abf6499f | ||
|
1a9bda1f34 | ||
|
59781051eb | ||
|
f31a1d9f8d | ||
|
3370dfdf3e | ||
|
2153557906 | ||
|
dda7358377 | ||
|
3fd1ca7949 | ||
|
4aa9f013d5 | ||
|
7aefdab219 |
@@ -35,7 +35,7 @@ LOCAL_C_INCLUDES += \
|
||||
|
||||
# define ANDROID_VERSION (e.g., 4.0.x => 0x0400)
|
||||
LOCAL_CFLAGS += \
|
||||
-DPACKAGE_VERSION=\"9.2.0-rc2\" \
|
||||
-DPACKAGE_VERSION=\"9.2.3\" \
|
||||
-DPACKAGE_BUGREPORT=\"https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa\" \
|
||||
-DANDROID_VERSION=0x0$(MESA_ANDROID_MAJOR_VERSION)0$(MESA_ANDROID_MINOR_VERSION)
|
||||
|
||||
|
@@ -50,6 +50,7 @@ EXTRA_FILES = \
|
||||
bin/install-sh \
|
||||
bin/ltmain.sh \
|
||||
bin/missing \
|
||||
bin/test-driver \
|
||||
bin/ylwrap \
|
||||
src/glsl/glsl_parser.cpp \
|
||||
src/glsl/glsl_parser.h \
|
||||
|
@@ -70,7 +70,7 @@ if env['gles']:
|
||||
# Environment setup
|
||||
|
||||
env.Append(CPPDEFINES = [
|
||||
('PACKAGE_VERSION', '\\"9.2.0-rc2\\"'),
|
||||
('PACKAGE_VERSION', '\\"9.2.3\\"'),
|
||||
('PACKAGE_BUGREPORT', '\\"https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa\\"'),
|
||||
])
|
||||
|
||||
|
17
bin/.cherry-ignore
Normal file
17
bin/.cherry-ignore
Normal file
@@ -0,0 +1,17 @@
|
||||
# Already cherry picked without -x
|
||||
d8ac987f6ab228df1a478b36c3d889992754374f glsl: Disallow uniform block layout qualifiers on non-uniform block vars.
|
||||
|
||||
# The bug fixed by this patch does not exist in 9.2. Discussed with Marek and
|
||||
# Brian Paul on the mesa-stable mailing list.
|
||||
89a665eb5fa176f68223bf54a472d6a0567c3546 draw: fix segfaults with aaline and aapoint stages disabled
|
||||
|
||||
# Previously cherry picked (patch originally appeared twice on master with a
|
||||
# revert in between)
|
||||
4e5eb8ba25054ede4798fa424e6f32b23aba0f98 i965/vec4: Only zero out unused message components when there are any.
|
||||
|
||||
# Backported as 7ab2b8c4c4607817c91946dcba943b29f1bd1895 but without "cherry
|
||||
# picked from" in commit message
|
||||
360a141f24a9d00891665b7fedb77ffb116944ca wayland: Don't rely on static variable for identifying wl_drm buffers
|
||||
|
||||
# Code being fixed is not present in 9.2
|
||||
f278d49c4bcfedbda10cb224cb251e3755e88288 i965: Do not set bilinear_filter flag in case of multisample blits
|
@@ -14,7 +14,7 @@ git log --reverse --grep="cherry picked from commit" origin/master..HEAD |\
|
||||
sed -e 's/^[[:space:]]*(cherry picked from commit[[:space:]]*//' -e 's/)//' > already_picked
|
||||
|
||||
# Grep for commits that were marked as a candidate for the stable tree.
|
||||
git log --reverse --pretty=%H -i --grep='^\([[:space:]]*NOTE: .*[Cc]andidate\|CC:.*mesa-stable\)' HEAD..origin/master |\
|
||||
git log --reverse --pretty=%H -i --grep='^\([[:space:]]*NOTE: .*[Cc]andidate.*9\.2\|CC:.*9\.2.*mesa-stable\)' HEAD..origin/master |\
|
||||
while read sha
|
||||
do
|
||||
# Check to see whether the patch is on the ignore list.
|
||||
|
@@ -6,7 +6,7 @@ dnl Tell the user about autoconf.html in the --help output
|
||||
m4_divert_once([HELP_END], [
|
||||
See docs/autoconf.html for more details on the options for Mesa.])
|
||||
|
||||
AC_INIT([Mesa], [9.2.0-rc2],
|
||||
AC_INIT([Mesa], [9.2.3],
|
||||
[https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa])
|
||||
AC_CONFIG_AUX_DIR([bin])
|
||||
AC_CONFIG_MACRO_DIR([m4])
|
||||
@@ -1925,8 +1925,8 @@ AM_CONDITIONAL(NEED_GALLIUM_SOFTPIPE_DRIVER, test "x$HAVE_GALLIUM_SVGA" = xyes -
|
||||
"x$HAVE_GALLIUM_I915" = xyes -o \
|
||||
"x$HAVE_GALLIUM_SOFTPIPE" = xyes)
|
||||
AM_CONDITIONAL(NEED_GALLIUM_LLVMPIPE_DRIVER, test "x$HAVE_GALLIUM_I915" = xyes -o \
|
||||
"x$HAVE_GALLIUM_SOFTPIPE" = xyes -a \
|
||||
"x$MESA_LLVM" = x1)
|
||||
"x$HAVE_GALLIUM_SOFTPIPE" = xyes \
|
||||
&& test "x$MESA_LLVM" = x1)
|
||||
|
||||
if test "x$enable_gallium_loader" = xyes; then
|
||||
GALLIUM_WINSYS_DIRS="$GALLIUM_WINSYS_DIRS sw/null"
|
||||
@@ -2066,6 +2066,7 @@ AC_CONFIG_FILES([Makefile
|
||||
src/gallium/targets/gbm/Makefile
|
||||
src/gallium/targets/opencl/Makefile
|
||||
src/gallium/targets/osmesa/Makefile
|
||||
src/gallium/targets/osmesa/osmesa.pc
|
||||
src/gallium/targets/pipe-loader/Makefile
|
||||
src/gallium/targets/libgl-xlib/Makefile
|
||||
src/gallium/targets/vdpau-nouveau/Makefile
|
||||
|
206
docs/relnotes/9.2.1.html
Normal file
206
docs/relnotes/9.2.1.html
Normal file
@@ -0,0 +1,206 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
||||
<title>Mesa Release Notes</title>
|
||||
<link rel="stylesheet" type="text/css" href="../mesa.css">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="header">
|
||||
<h1>The Mesa 3D Graphics Library</h1>
|
||||
</div>
|
||||
|
||||
<iframe src="../contents.html"></iframe>
|
||||
<div class="content">
|
||||
|
||||
<h1>Mesa 9.2.1 Release Notes / (October 4, 2013)</h1>
|
||||
|
||||
<p>
|
||||
Mesa 9.2.1 is a bug fix release which fixes bugs found since the 9.2 release.
|
||||
</p>
|
||||
<p>
|
||||
Mesa 9.2 implements the OpenGL 3.1 API, but the version reported by
|
||||
glGetString(GL_VERSION) or glGetIntegerv(GL_MAJOR_VERSION) /
|
||||
glGetIntegerv(GL_MINOR_VERSION) depends on the particular driver being used.
|
||||
Some drivers don't support all the features required in OpenGL 3.1. OpenGL
|
||||
3.1 is <strong>only</strong> available if requested at context creation
|
||||
because GL_ARB_compatibility is not supported.
|
||||
</p>
|
||||
|
||||
|
||||
<h2>MD5 checksums</h2>
|
||||
<pre>
|
||||
e6cdfa84dfddd86e3d36ec7ff4b6478a MesaLib-9.2.1.tar.gz
|
||||
dd4c82667d9c19c28a553b12eba3f8a0 MesaLib-9.2.1.tar.bz2
|
||||
d9af0f5607f7d275793d293057ca9ac6 MesaLib-9.2.1.zip
|
||||
</pre>
|
||||
|
||||
|
||||
<h2>New features</h2>
|
||||
<p>None</p>
|
||||
|
||||
<h2>Bug fixes</h2>
|
||||
|
||||
<p>This list is likely incomplete.</p>
|
||||
|
||||
<ul>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=66779">Bug 66779</a> - Use of uninitialized stack variable with brw_search_cache()</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=68233">Bug 68233</a> - Valgrind errors in mesa</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=68250">Bug 68250</a> - Automatic mipmap generation with texture compression produces borders that fade to black</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=68637">Bug 68637</a> - [Bisected IVB/HSW]Unigine demo crash</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=68753">Bug 68753</a> - [regression bisected] GLSL ES: structs members can't have precision qualifiers anymore in 9.2</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=69525">Bug 69525</a> - [GM45, bisected] Piglit tex-shadow2drect fails</li>
|
||||
|
||||
</ul>
|
||||
|
||||
<h2>Changes</h2>
|
||||
|
||||
<p>The full set of changes can be viewed by using the following GIT command:</p>
|
||||
|
||||
<pre>
|
||||
git log mesa-9.2..mesa-9.2.1
|
||||
</pre>
|
||||
|
||||
|
||||
<p>Alex Deucher (1):</p>
|
||||
<ul>
|
||||
<li>radeon/winsys: pad IBs to a multiple of 8 DWs</li>
|
||||
</ul>
|
||||
|
||||
<p>Andreas Boll (1):</p>
|
||||
<ul>
|
||||
<li>os: First check for __GLIBC__ and then for PIPE_OS_BSD</li>
|
||||
</ul>
|
||||
|
||||
<p>Anuj Phogat (1):</p>
|
||||
<ul>
|
||||
<li>glsl: Allow precision qualifiers for sampler types</li>
|
||||
</ul>
|
||||
|
||||
<p>Brian Paul (2):</p>
|
||||
<ul>
|
||||
<li>docs: minor fixes for 9.2 release notes</li>
|
||||
<li>mesa: check for bufSize > 0 in _mesa_GetSynciv()</li>
|
||||
</ul>
|
||||
|
||||
<p>Carl Worth (3):</p>
|
||||
<ul>
|
||||
<li>cherry-ignore: Ignore a commit which appeared twice on master</li>
|
||||
<li>Use -Bsymbolic when linking libEGL.so</li>
|
||||
<li>mesa: Bump version to 9.2.1</li>
|
||||
</ul>
|
||||
|
||||
<p>Chris Forbes (3):</p>
|
||||
<ul>
|
||||
<li>i965/fs: Gen4: Zero out extra coordinates when using shadow compare</li>
|
||||
<li>i965: Fix cube array coordinate normalization</li>
|
||||
<li>i965: fix bogus swizzle in brw_cubemap_normalize</li>
|
||||
</ul>
|
||||
|
||||
<p>Christoph Bumiller (2):</p>
|
||||
<ul>
|
||||
<li>nvc0/ir: add f32 long immediate cannot saturate</li>
|
||||
<li>nvc0: delete compute object on screen destruction</li>
|
||||
</ul>
|
||||
|
||||
<p>Dave Airlie (1):</p>
|
||||
<ul>
|
||||
<li>st/mesa: don't dereference stObj->pt if NULL</li>
|
||||
</ul>
|
||||
|
||||
<p>Dominik Behr (1):</p>
|
||||
<ul>
|
||||
<li>glsl: propagate max_array_access through function calls</li>
|
||||
</ul>
|
||||
|
||||
<p>Emil Velikov (1):</p>
|
||||
<ul>
|
||||
<li>nouveau: initialise the nouveau_transfer maps</li>
|
||||
</ul>
|
||||
|
||||
<p>Eric Anholt (4):</p>
|
||||
<ul>
|
||||
<li>mesa: Rip out more extension checking from texformat.c.</li>
|
||||
<li>mesa: Don't choose S3TC for generic compression if we can't compress.</li>
|
||||
<li>i965/gen4: Fix fragment program rectangle texture shadow compares.</li>
|
||||
<li>i965: Reenable glBitmap() after the sRGB winsys enabling.</li>
|
||||
</ul>
|
||||
|
||||
<p>Ian Romanick (7):</p>
|
||||
<ul>
|
||||
<li>docs: Add 9.2 release md5sums</li>
|
||||
<li>Add .cherry-ignore file</li>
|
||||
<li>mesa: Note that 89a665e should not be picked</li>
|
||||
<li>glsl: Reallow precision qualifiers on structure members</li>
|
||||
<li>mesa: Support GL_MAX_VERTEX_OUTPUT_COMPONENTS query with ES3</li>
|
||||
<li>mesa: Remove all traces of GL_OES_matrix_get</li>
|
||||
<li>mesa: Don't return any data for GL_SHADER_BINARY_FORMATS</li>
|
||||
</ul>
|
||||
|
||||
<p>Ilia Mirkin (2):</p>
|
||||
<ul>
|
||||
<li>nv30: find first unused texcoord rather than bailing if first is used</li>
|
||||
<li>nv30: fix inconsistent setting of push->user_priv</li>
|
||||
</ul>
|
||||
|
||||
<p>Joakim Sindholt (1):</p>
|
||||
<ul>
|
||||
<li>nvc0: fix blitctx memory leak</li>
|
||||
</ul>
|
||||
|
||||
<p>Johannes Obermayr (1):</p>
|
||||
<ul>
|
||||
<li>st/gbm: Add $(WAYLAND_CFLAGS) for HAVE_EGL_PLATFORM_WAYLAND.</li>
|
||||
</ul>
|
||||
|
||||
<p>Kenneth Graunke (5):</p>
|
||||
<ul>
|
||||
<li>i965/vs: Detect GRF sources in split_virtual_grfs send-from-GRF code.</li>
|
||||
<li>i965/fs: Detect GRF sources in split_virtual_grfs send-from-GRF code.</li>
|
||||
<li>i965/vec4: Only zero out unused message components when there are any.</li>
|
||||
<li>i965: Fix brw_vs_prog_data_compare to actually check field members.</li>
|
||||
<li>meta: Set correct viewport and projection in decompress_texture_image.</li>
|
||||
</ul>
|
||||
|
||||
<p>Maarten Lankhorst (2):</p>
|
||||
<ul>
|
||||
<li>st/dri: do not create a new context for msaa copy</li>
|
||||
<li>nvc0: restore viewport after blit</li>
|
||||
</ul>
|
||||
|
||||
<p>Marek Olšák (2):</p>
|
||||
<ul>
|
||||
<li>r600g: fix constant buffer cache flushing</li>
|
||||
<li>r600g: fix texture buffer object cache flushing</li>
|
||||
</ul>
|
||||
|
||||
<p>Paul Berry (1):</p>
|
||||
<ul>
|
||||
<li>i965: Initialize inout_offset parameter to brw_search_cache().</li>
|
||||
</ul>
|
||||
|
||||
<p>Rico Schüller (1):</p>
|
||||
<ul>
|
||||
<li>glx: Initialize OpenGL version to 1.0</li>
|
||||
</ul>
|
||||
|
||||
<p>Tiziano Bacocco (1):</p>
|
||||
<ul>
|
||||
<li>nvc0/ir: fix use after free in texture barrier insertion pass</li>
|
||||
</ul>
|
||||
|
||||
<p>Torsten Duwe (1):</p>
|
||||
<ul>
|
||||
<li>wayland-egl.pc requires wayland-client.pc.</li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
100
docs/relnotes/9.2.2.html
Normal file
100
docs/relnotes/9.2.2.html
Normal file
@@ -0,0 +1,100 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
||||
<title>Mesa Release Notes</title>
|
||||
<link rel="stylesheet" type="text/css" href="../mesa.css">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="header">
|
||||
<h1>The Mesa 3D Graphics Library</h1>
|
||||
</div>
|
||||
|
||||
<iframe src="../contents.html"></iframe>
|
||||
<div class="content">
|
||||
|
||||
<h1>Mesa 9.2.2 Release Notes / (October 18, 2013)</h1>
|
||||
|
||||
<p>
|
||||
Mesa 9.2.2 is a bug fix release which fixes bugs found since the 9.2.1 release.
|
||||
</p>
|
||||
<p>
|
||||
Mesa 9.2 implements the OpenGL 3.1 API, but the version reported by
|
||||
glGetString(GL_VERSION) or glGetIntegerv(GL_MAJOR_VERSION) /
|
||||
glGetIntegerv(GL_MINOR_VERSION) depends on the particular driver being used.
|
||||
Some drivers don't support all the features required in OpenGL 3.1. OpenGL
|
||||
3.1 is <strong>only</strong> available if requested at context creation
|
||||
because GL_ARB_compatibility is not supported.
|
||||
</p>
|
||||
|
||||
|
||||
<h2>MD5 checksums</h2>
|
||||
<pre>
|
||||
df801a975045150790e10e2ccf32193f MesaLib-9.2.2.tar.gz
|
||||
20887f8020db7d1736a01ae9cd5d8c38 MesaLib-9.2.2.tar.bz2
|
||||
1676f4f1b157c838d077dadd31ba6c84 MesaLib-9.2.2.zip
|
||||
</pre>
|
||||
|
||||
|
||||
<h2>New features</h2>
|
||||
<p>None</p>
|
||||
|
||||
<h2>Bug fixes</h2>
|
||||
|
||||
<p>This list is likely incomplete.</p>
|
||||
|
||||
<ul>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=69449">Bug 69449</a> - Valgrind error in program_resource_visitor::recursion</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=70411">Bug 70411</a> - glInvalidateFramebuffer fails with GL_INVALID_ENUM</li>
|
||||
|
||||
</ul>
|
||||
|
||||
<h2>Changes</h2>
|
||||
|
||||
<p>The full set of changes can be viewed by using the following GIT command:</p>
|
||||
|
||||
<pre>
|
||||
git log mesa-9.2.1..mesa-9.2.2
|
||||
</pre>
|
||||
|
||||
<p>Brian Paul (3):</p>
|
||||
<ul>
|
||||
<li>docs: add missing <pre> tag</li>
|
||||
<li>svga: fix incorrect memcpy src in svga_buffer_upload_piecewise()</li>
|
||||
<li>mesa: consolidate cube width=height error checking</li>
|
||||
</ul>
|
||||
|
||||
<p>Carl Worth (3):</p>
|
||||
<ul>
|
||||
<li>docs: Add md5sums for 9.2.1 release</li>
|
||||
<li>Bump version to 9.2.2</li>
|
||||
</ul>
|
||||
|
||||
<p>Constantin Baranov (1):</p>
|
||||
<ul>
|
||||
<li>mesa: Add missing switch break in invalidate_framebuffer_storage()</li>
|
||||
</ul>
|
||||
|
||||
<p>Eric Anholt (3):</p>
|
||||
<ul>
|
||||
<li>i965: Don't forget the cube map padding on gen5+.</li>
|
||||
<li>mesa: Fix compiler warnings when ALIGN's alignment is "1 << value".</li>
|
||||
<li>i965: Fix 3D texture layout by more literally copying from the spec.</li>
|
||||
</ul>
|
||||
|
||||
<p>Francisco Jerez (1):</p>
|
||||
<ul>
|
||||
<li>glsl: Fix usage of the wrong union member in program_resource_visitor::recursion.</li>
|
||||
</ul>
|
||||
|
||||
<p>Tom Stellard (1):</p>
|
||||
<ul>
|
||||
<li>radeonsi: Use 'SI' as the LLVM processor for CIK on LLVM <= 3.3</li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
113
docs/relnotes/9.2.3.html
Normal file
113
docs/relnotes/9.2.3.html
Normal file
@@ -0,0 +1,113 @@
|
||||
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
||||
<title>Mesa Release Notes</title>
|
||||
<link rel="stylesheet" type="text/css" href="../mesa.css">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="header">
|
||||
<h1>The Mesa 3D Graphics Library</h1>
|
||||
</div>
|
||||
|
||||
<iframe src="../contents.html"></iframe>
|
||||
<div class="content">
|
||||
|
||||
<h1>Mesa 9.2.3 Release Notes / (November 13, 2013)</h1>
|
||||
|
||||
<p>
|
||||
Mesa 9.2.3 is a bug fix release which fixes bugs found since the 9.2.2 release.
|
||||
</p>
|
||||
<p>
|
||||
Mesa 9.2 implements the OpenGL 3.1 API, but the version reported by
|
||||
glGetString(GL_VERSION) or glGetIntegerv(GL_MAJOR_VERSION) /
|
||||
glGetIntegerv(GL_MINOR_VERSION) depends on the particular driver being used.
|
||||
Some drivers don't support all the features required in OpenGL 3.1. OpenGL
|
||||
3.1 is <strong>only</strong> available if requested at context creation
|
||||
because GL_ARB_compatibility is not supported.
|
||||
</p>
|
||||
|
||||
|
||||
<h2>MD5 checksums</h2>
|
||||
<pre>
|
||||
TBA
|
||||
</pre>
|
||||
|
||||
|
||||
<h2>New features</h2>
|
||||
<p>None</p>
|
||||
|
||||
<h2>Bug fixes</h2>
|
||||
|
||||
<p>This list is likely incomplete.</p>
|
||||
|
||||
<ul>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=69437">Bug 69437</a> - Composite Bypass no longer works</li>
|
||||
|
||||
</ul>
|
||||
|
||||
<h2>Changes</h2>
|
||||
|
||||
<p>The full set of changes can be viewed by using the following GIT command:</p>
|
||||
|
||||
<pre>
|
||||
git log mesa-9.2.2..mesa-9.2.3
|
||||
</pre>
|
||||
|
||||
<p>Brian Paul (2):</p>
|
||||
<ul>
|
||||
<li>st/mesa: move out of memory check in st_draw_vbo()</li>
|
||||
<li>osmesa: fix broken triangle/line drawing when using float color buffer</li>
|
||||
</ul>
|
||||
|
||||
<p>Carl Worth (7):</p>
|
||||
<ul>
|
||||
<li>Remove error when calling glGenQueries/glDeleteQueries while a query is active</li>
|
||||
<li>Bump version to 9.2.3</li>
|
||||
</ul>
|
||||
|
||||
<p>Daniel Vetter (1):</p>
|
||||
<ul>
|
||||
<li>i965: CS writes/reads should use I915_GEM_INSTRUCTION</li>
|
||||
</ul>
|
||||
|
||||
<p>Eric Anholt (1):</p>
|
||||
<ul>
|
||||
<li>i965: Fix texture buffer rendering after a whole buffer replacement.</li>
|
||||
</ul>
|
||||
|
||||
<p>Kenneth Graunke (6):</p>
|
||||
<ul>
|
||||
<li>i965: Emit post-sync non-zero flush before 3DSTATE_GS_SVB_INDEX.</li>
|
||||
<li>i965: Emit post-sync non-zero flush before 3DSTATE_DRAWING_RECTANGLE.</li>
|
||||
<li>i965: Also guard 3DSTATE_DRAWING_RECTANGLE with a flush in blorp.</li>
|
||||
<li>i965: Move post-sync non-zero flush for 3DSTATE_MULTISAMPLE.</li>
|
||||
<li>i965: Also emit HIER_DEPTH and STENCIL packets when disabling depth.</li>
|
||||
<li>i965: Also emit HiZ and Stencil packets when disabling depth on Gen6.</li>
|
||||
</ul>
|
||||
|
||||
<p>Kristian Høgsberg (1):</p>
|
||||
<ul>
|
||||
<li>wayland: Don't rely on static variable for identifying wl_drm buffers</li>
|
||||
</ul>
|
||||
|
||||
<p>Marek Olšák (1):</p>
|
||||
<ul>
|
||||
<li>radeonsi: fix blitting the last 2 mipmap levels of compressed textures</li>
|
||||
</ul>
|
||||
|
||||
<p>Petr Sebor (1):</p>
|
||||
<ul>
|
||||
<li>meta: enable vertex attributes in the context of the newly created array object</li>
|
||||
</ul>
|
||||
|
||||
<p>Scott Graham (1):</p>
|
||||
<ul>
|
||||
<li>mesa: fixes for MSVC 2013</li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
@@ -14,7 +14,7 @@
|
||||
<iframe src="../contents.html"></iframe>
|
||||
<div class="content">
|
||||
|
||||
<h1>Mesa 9.2 Release Notes / (date TBD)</h1>
|
||||
<h1>Mesa 9.2 Release Notes / (August 27, 2013)</h1>
|
||||
|
||||
<p>
|
||||
Mesa 9.2 is a new development release.
|
||||
@@ -33,7 +33,9 @@ because GL_ARB_compatibility is not supported.
|
||||
|
||||
<h2>MD5 checksums</h2>
|
||||
<pre>
|
||||
tbd
|
||||
4f93c6475ec656fc1f7b93aeffc9b6c4 MesaLib-9.2.0.tar.gz
|
||||
4185b6aae890bc62a964f4b24cc1aca8 MesaLib-9.2.0.tar.bz2
|
||||
3bc5339bc98b9c37777ffd14e3a8eca4 MesaLib-9.2.0.zip
|
||||
</pre>
|
||||
|
||||
|
||||
@@ -44,11 +46,14 @@ Note: some of the new features are only available with certain drivers.
|
||||
</p>
|
||||
|
||||
<ul>
|
||||
<li>GL_ARB_shading_language_420pack in all drivers that support GLSL 1.30.</li>
|
||||
<li>GL_ARB_texture_buffer_range</li>
|
||||
<li>GL_ARB_texture_multisample</li>
|
||||
<li>GL_ARB_texture_storage_multisample</li>
|
||||
<li>GL_ARB_texture_query_lod</li>
|
||||
<li>Enable GL_ARB_texture_storage on radeon, r200, and nouveau</li>
|
||||
<li>GL_ARB_texture_storage on radeon, r200, and nouveau</li>
|
||||
<li>GL_EXT_discard_framebuffer in all OpenGL ES (all versions) drivers</li>
|
||||
<li>GL_EXT_framebuffer_multisample_blit_scaled on i965</li>
|
||||
<li>Added new freedreno gallium driver</li>
|
||||
<li>OSMesa interface for gallium llvmpipe/softpipe drivers</li>
|
||||
<li>Gallium Heads-Up Display (HUD) feature for performance monitoring</li>
|
||||
@@ -58,8 +63,149 @@ Note: some of the new features are only available with certain drivers.
|
||||
|
||||
<h2>Bug fixes</h2>
|
||||
|
||||
<p>TBD -- This list is likely incomplete.</p>
|
||||
<p>Attempts have been made to <b>not</b> include bugs fixed in previous 9.1
|
||||
releases or bugs that were regressions during 9.2 development. This list is
|
||||
likely incomplete.</p>
|
||||
|
||||
<ul>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=41787">Bug 41787</a> - [llvmpipe] stencil broken</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=44618">Bug 44618</a> - Cross-compilation broken by glsl builtin_compiler</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=46632">Bug 46632</a> - Make the alignment checks for the readpixel blit fastpath a bit more lenient</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=47116">Bug 47116</a> - Enemy territory freezes with rs880 and commit fbebd431ec4e2e461a0cbcd5f3a04a000b8f6bbf</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=47248">Bug 47248</a> - autogen missing dependency on flex and bison, causes infinite loop in glsl build</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=48694">Bug 48694</a> - radeonsi_pipe.c:322:7: error: ‘PIPE_CAP_DUAL_SOURCE_BLEND’ undeclared</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=50655">Bug 50655</a> - [r600g][RV670 HD3870] Ioquake games causes GPU lockup (waiting for 0x00003039 last fence id 0x00003030)</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=51471">Bug 51471</a> - [965gm] Corrupted graphics in corners of screen with pixel shaders enabled</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=51782">Bug 51782</a> - mesa-8.0.3: fails to compile against uclibc</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=54240">Bug 54240</a> - [swrast] piglit fbo-generatemipmap-filtering regression</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=55503">Bug 55503</a> - Constant vertex attributes broken</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=55783">Bug 55783</a> - glEnable(GL_FRAMEBUFFER_SRGB) has no effect on the backbuffer</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=55825">Bug 55825</a> - [Bisected i965]Oglc max_values(advanced.fragmentProgram.GL_MAX_PROGRAM_ALU_INSTRUCTIONS_ARB) causes OOM-killer</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=56920">Bug 56920</a> - [sandybridge][uxa] graphics very glitchy and always flickering</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=57753">Bug 57753</a> - leak in loop_analysis</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=57875">Bug 57875</a> - Second Life viewer bad rendering with git-ec83535</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=58666">Bug 58666</a> - rv670 + llvm = errors.</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=58680">Bug 58680</a> - [IVB] Graphical glitches in 0 A.D</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=58872">Bug 58872</a> - Mac OS X configure: error: Couldn't find clock_gettime</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59322">Bug 59322</a> - r300g MSAA breaks Half-Life 2 in Wine</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59364">Bug 59364</a> - [bisected] Mesa build fails: clientattrib.c:33:22: fatal error: indirect.h: No such file or directory</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59439">Bug 59439</a> - glCopyPixels generates no fragments (occlusion_query_meta_fragments test fails)</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59440">Bug 59440</a> - glBitmap generates no fragments (occlusion_query_meta_fragments test fails)</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59494">Bug 59494</a> - [Bisected]Piglit glean_depthStencil fails</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59592">Bug 59592</a> - Radeon HD 5670: reproducable GPU lockups with htile enabled</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59648">Bug 59648</a> - [SNB/IVB/HSW Bisected]Piglit spec/ARB_uniform_buffer/object_layout-std140-base-size-and-alignment fails</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59701">Bug 59701</a> - lp_test_arit fails on non-sse41 capable machines, breaking make check</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59737">Bug 59737</a> - [bisected] 0d108116bd80b757fb01a84a9f1946ef870b57b8 breaks osmesa when cross compiling</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59740">Bug 59740</a> - [i965 Bisected]Oglc api-error(negative.glEvalMesh) fails</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59851">Bug 59851</a> - AC_ARG_WITH misusage leading to mesa configure failure</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59873">Bug 59873</a> - [swrast] piglit ext_framebuffer_multisample-interpolation 0 centroid-edges regression</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=59876">Bug 59876</a> - glGetTexLevelParameteriv broken for indirect rendering</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60038">Bug 60038</a> - [osmesa] [git] building 32-bit mesa on 64 bit fails</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60047">Bug 60047</a> - [softpipe] piglit masked-clear regression</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60052">Bug 60052</a> - [Bisected]Piglit glx_extension_string_sanity fail</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60082">Bug 60082</a> - [ FAILED ] DispatchSanity_test.GL31_CORE</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60086">Bug 60086</a> - Wayland platform backend crashes if there's no back buffer during dri2_swap_buffers</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60098">Bug 60098</a> - [softpipe] Unexpected PIPE_CAP 78 query</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60172">Bug 60172</a> - Planeshift: triangles where grass would be</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60200">Bug 60200</a> - radeon_bo with virtual address referencing mismatch</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60212">Bug 60212</a> - [Bisected] Weston black output</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60524">Bug 60524</a> - [softpipe] piglit depthstencil-render-miplevels 146 s=z24_s8 regression</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60527">Bug 60527</a> - [softpipe] fbo-stencil GL_DEPTH24_STENCIL8 clear regression</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60633">Bug 60633</a> - EXT_texture_sRGB does not work in game The Cave on IvyBridge</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60737">Bug 60737</a> - In GLSL ES, a missing FS precision qualifier does not generate an error</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=60866">Bug 60866</a> - GLSL performance issues for uniform buffer objects</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=61036">Bug 61036</a> - Shader fails to build in LLVMpipe, aborts program</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=61200">Bug 61200</a> - insufficient linking of libxatracker.so</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=61635">Bug 61635</a> - glVertexAttribPointer(id, GL_UNSIGNED_BYTE, GL_FALSE,...) does not work</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=62466">Bug 62466</a> - r600g hyperz lockups with KSP 0.19</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=62669">Bug 62669</a> - HyperZ freeze when playing PrBoom-Plus demo with lots of monsters</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=62721">Bug 62721</a> - GPU lockup in Minecraft 1.5.1 with HyperZ</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=62830">Bug 62830</a> - [i965 bisected] Wrong Lightning on Freespace 2 SCP (patch attached)</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=63124">Bug 63124</a> - [r600g] HyperZ lockup on REDWOOD in Half Life 2 Deathmatch</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=63702">Bug 63702</a> - tiling2d in radeon trash vdpau UVD textures</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=64935">Bug 64935</a> - [swrast] s_texfetch.c:1335: set_fetch_functions: Assertion `texImage->FetchTexel' failed.</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=64959">Bug 64959</a> - Cannot build against EGL without X11</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=65112">Bug 65112</a> - glcpp hangs parsing line continuations</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=65958">Bug 65958</a> - GPU Lockup on Trinity 7500G</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=66450">Bug 66450</a> - JUNIPER UVD accelerated playback of MPEG 1/2 streams does not work</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=66606">Bug 66606</a> - [i965 bisected]GLBenchmark 2.5.1/2.7.0 sometimes render error with gnome-session enabling SNA</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=66713">Bug 66713</a> - Team Fortress 2 crashes with r600-sb on HD4850</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=67354">Bug 67354</a> - glsl_parser.cpp is broken with bison 3.0</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=67548">Bug 67548</a> - glGetAttribLocation seems to be broken</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=67927">Bug 67927</a> - R600_DEBUG=sb: Celestia show 2 earths, one wrongly rendered</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=67934">Bug 67934</a> - [SNB/IVB/HSW 9.2 Bisected]Ogles2conform/GL2Tests/glUniform/glUniform.test fails with gnome-session enable compositing</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=68162">Bug 68162</a> - [radeonsi] texture rendering is broken in Source-Engine games</li>
|
||||
|
||||
<li><a href="https://bugs.freedesktop.org/show_bug.cgi?id=68195">Bug 68195</a> - piglit tests vs-struct-pad and fs-struct-pad both fail</li>
|
||||
|
||||
</ul>
|
||||
|
||||
<h2>Changes</h2>
|
||||
|
||||
|
@@ -35,7 +35,8 @@
|
||||
#define bool _Bool
|
||||
|
||||
/* For compilers that don't have the builtin _Bool type. */
|
||||
#if defined(_MSC_VER) || (__STDC_VERSION__ < 199901L && __GNUC__ < 3)
|
||||
#if (defined(_MSC_VER) && _MSC_VER < 1800) || \
|
||||
(defined __GNUC__&& __STDC_VERSION__ < 199901L && __GNUC__ < 3)
|
||||
typedef unsigned char _Bool;
|
||||
#endif
|
||||
|
||||
|
@@ -1203,7 +1203,7 @@ dri2_create_image_wayland_wl_buffer(_EGLDisplay *disp, _EGLContext *ctx,
|
||||
EGLint err;
|
||||
int32_t plane;
|
||||
|
||||
if (!wayland_buffer_is_drm(&buffer->buffer))
|
||||
if (!wayland_buffer_is_drm(dri2_dpy->wl_server_drm, &buffer->buffer))
|
||||
return NULL;
|
||||
|
||||
err = _eglParseImageAttribList(&attrs, disp, attr_list);
|
||||
@@ -1585,6 +1585,11 @@ dri2_bind_wayland_display_wl(_EGLDriver *drv, _EGLDisplay *disp,
|
||||
if (!dri2_dpy->wl_server_drm)
|
||||
return EGL_FALSE;
|
||||
|
||||
#ifdef HAVE_DRM_PLATFORM
|
||||
if (dri2_dpy->gbm_dri)
|
||||
dri2_dpy->gbm_dri->wl_drm = dri2_dpy->wl_server_drm;
|
||||
#endif
|
||||
|
||||
return EGL_TRUE;
|
||||
}
|
||||
|
||||
@@ -1611,9 +1616,10 @@ dri2_query_wayland_buffer_wl(_EGLDriver *drv, _EGLDisplay *disp,
|
||||
EGLint attribute, EGLint *value)
|
||||
{
|
||||
struct wl_drm_buffer *buffer = (struct wl_drm_buffer *) _buffer;
|
||||
struct dri2_egl_display *dri2_dpy = dri2_egl_display(disp);
|
||||
const struct wl_drm_components_descriptor *format;
|
||||
|
||||
if (!wayland_buffer_is_drm(&buffer->buffer))
|
||||
if (!wayland_buffer_is_drm(dri2_dpy->wl_server_drm, &buffer->buffer))
|
||||
return EGL_FALSE;
|
||||
|
||||
format = buffer->driver_format;
|
||||
|
@@ -75,7 +75,7 @@ libEGL_la_SOURCES = \
|
||||
|
||||
libEGL_la_LIBADD = \
|
||||
$(EGL_LIB_DEPS)
|
||||
libEGL_la_LDFLAGS = -version-number 1:0 -no-undefined
|
||||
libEGL_la_LDFLAGS = -Wl,-Bsymbolic -version-number 1:0 -no-undefined
|
||||
|
||||
if HAVE_EGL_PLATFORM_X11
|
||||
AM_CFLAGS += -DHAVE_X11_PLATFORM
|
||||
|
@@ -45,6 +45,7 @@ struct wl_drm {
|
||||
uint32_t flags;
|
||||
|
||||
struct wayland_drm_callbacks *callbacks;
|
||||
struct wl_buffer_interface buffer_interface;
|
||||
};
|
||||
|
||||
static void
|
||||
@@ -63,10 +64,6 @@ buffer_destroy(struct wl_client *client, struct wl_resource *resource)
|
||||
wl_resource_destroy(resource);
|
||||
}
|
||||
|
||||
const static struct wl_buffer_interface drm_buffer_interface = {
|
||||
buffer_destroy
|
||||
};
|
||||
|
||||
static void
|
||||
create_buffer(struct wl_client *client, struct wl_resource *resource,
|
||||
uint32_t id, uint32_t name, int fd,
|
||||
@@ -107,7 +104,7 @@ create_buffer(struct wl_client *client, struct wl_resource *resource,
|
||||
buffer->buffer.resource.object.id = id;
|
||||
buffer->buffer.resource.object.interface = &wl_buffer_interface;
|
||||
buffer->buffer.resource.object.implementation =
|
||||
(void (**)(void)) &drm_buffer_interface;
|
||||
(void (**)(void)) &drm->buffer_interface;
|
||||
buffer->buffer.resource.data = buffer;
|
||||
|
||||
buffer->buffer.resource.destroy = destroy_buffer;
|
||||
@@ -246,6 +243,7 @@ wayland_drm_init(struct wl_display *display, char *device_name,
|
||||
drm->callbacks = callbacks;
|
||||
drm->user_data = user_data;
|
||||
drm->flags = flags;
|
||||
drm->buffer_interface.destroy = buffer_destroy;
|
||||
|
||||
wl_display_add_global(display, &wl_drm_interface, drm, bind_drm);
|
||||
|
||||
@@ -263,10 +261,10 @@ wayland_drm_uninit(struct wl_drm *drm)
|
||||
}
|
||||
|
||||
int
|
||||
wayland_buffer_is_drm(struct wl_buffer *buffer)
|
||||
wayland_buffer_is_drm(struct wl_drm *drm, struct wl_buffer *buffer)
|
||||
{
|
||||
return buffer->resource.object.implementation ==
|
||||
(void (**)(void)) &drm_buffer_interface;
|
||||
(void (**)(void)) &drm->buffer_interface;
|
||||
}
|
||||
|
||||
uint32_t
|
||||
|
@@ -99,7 +99,7 @@ void
|
||||
wayland_drm_uninit(struct wl_drm *drm);
|
||||
|
||||
int
|
||||
wayland_buffer_is_drm(struct wl_buffer *buffer);
|
||||
wayland_buffer_is_drm(struct wl_drm *drm, struct wl_buffer *buffer);
|
||||
|
||||
uint32_t
|
||||
wayland_drm_buffer_get_format(struct wl_buffer *buffer_base);
|
||||
|
@@ -6,5 +6,6 @@ includedir=@includedir@
|
||||
Name: wayland-egl
|
||||
Description: Mesa wayland-egl library
|
||||
Version: @VERSION@
|
||||
Requires: wayland-client
|
||||
Libs: -L${libdir} -lwayland-egl
|
||||
Cflags: -I${includedir}
|
||||
|
@@ -32,10 +32,10 @@
|
||||
|
||||
#if defined(PIPE_SUBSYSTEM_WINDOWS_USER)
|
||||
# include <windows.h>
|
||||
#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE)
|
||||
# include <stdlib.h>
|
||||
#elif defined(__GLIBC__)
|
||||
# include <errno.h>
|
||||
#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE)
|
||||
# include <stdlib.h>
|
||||
#else
|
||||
#warning unexpected platform in os_process.c
|
||||
#endif
|
||||
@@ -68,11 +68,11 @@ os_get_process_name(char *procname, size_t size)
|
||||
|
||||
name = lpProcessName;
|
||||
|
||||
#elif defined(__GLIBC__)
|
||||
name = program_invocation_short_name;
|
||||
#elif defined(PIPE_OS_BSD) || defined(PIPE_OS_APPLE)
|
||||
/* *BSD and OS X */
|
||||
name = getprogname();
|
||||
#elif defined(__GLIBC__)
|
||||
name = program_invocation_short_name;
|
||||
#else
|
||||
#warning unexpected platform in os_process.c
|
||||
return FALSE;
|
||||
|
@@ -289,6 +289,7 @@ nouveau_buffer_cache(struct nouveau_context *nv, struct nv04_resource *buf)
|
||||
tx.base.box.x = 0;
|
||||
tx.base.box.width = buf->base.width0;
|
||||
tx.bo = NULL;
|
||||
tx.map = NULL;
|
||||
|
||||
if (!buf->data)
|
||||
if (!nouveau_buffer_malloc(buf))
|
||||
@@ -690,6 +691,7 @@ nouveau_buffer_migrate(struct nouveau_context *nv,
|
||||
tx.base.box.x = 0;
|
||||
tx.base.box.width = buf->base.width0;
|
||||
tx.bo = NULL;
|
||||
tx.map = NULL;
|
||||
if (!nouveau_transfer_staging(nv, &tx, FALSE))
|
||||
return FALSE;
|
||||
nouveau_transfer_write(nv, &tx, 0, tx.base.box.width);
|
||||
|
@@ -208,7 +208,7 @@ nv30_context_create(struct pipe_screen *pscreen, void *priv)
|
||||
/*XXX: *cough* per-context pushbufs */
|
||||
push = screen->base.pushbuf;
|
||||
nv30->base.pushbuf = push;
|
||||
nv30->base.pushbuf->user_priv = push->user_priv; /* hack at validate time */
|
||||
nv30->base.pushbuf->user_priv = &nv30->bufctx; /* hack at validate time */
|
||||
nv30->base.pushbuf->rsvd_kick = 16; /* hack in screen before first space */
|
||||
nv30->base.pushbuf->kick_notify = nv30_context_kick_notify;
|
||||
|
||||
|
@@ -113,6 +113,7 @@ nv30_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
|
||||
case PIPE_CAP_TEXTURE_BARRIER:
|
||||
case PIPE_CAP_SEAMLESS_CUBE_MAP:
|
||||
case PIPE_CAP_SEAMLESS_CUBE_MAP_PER_TEXTURE:
|
||||
case PIPE_CAP_CUBE_MAP_ARRAY:
|
||||
case PIPE_CAP_VERTEX_COLOR_UNCLAMPED:
|
||||
case PIPE_CAP_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION:
|
||||
case PIPE_CAP_MIXED_COLORBUFFER_FORMATS:
|
||||
|
@@ -976,9 +976,8 @@ nvfx_fragprog_assign_generic(struct nv30_context *nvfx, struct nvfx_fpc *fpc,
|
||||
fpc->r_input[idx] = nvfx_reg(NVFXSR_INPUT, hw);
|
||||
return TRUE;
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
return TRUE;
|
||||
return FALSE;
|
||||
default:
|
||||
return TRUE;
|
||||
}
|
||||
|
@@ -441,6 +441,7 @@ NVC0LegalizePostRA::insertTextureBarriers(Function *fn)
|
||||
if (i->op == OP_TEXBAR) {
|
||||
if (i->subOp >= max) {
|
||||
delete_Instruction(prog, i);
|
||||
i = NULL;
|
||||
} else {
|
||||
max = i->subOp;
|
||||
if (prev && prev->op == OP_TEXBAR && prev->subOp >= max) {
|
||||
@@ -452,7 +453,7 @@ NVC0LegalizePostRA::insertTextureBarriers(Function *fn)
|
||||
if (isTextureOp(i->op)) {
|
||||
max++;
|
||||
}
|
||||
if (!i->isNop())
|
||||
if (i && !i->isNop())
|
||||
prev = i;
|
||||
}
|
||||
}
|
||||
|
@@ -337,6 +337,11 @@ TargetNVC0::insnCanLoad(const Instruction *i, int s,
|
||||
// (except if we implement more constraints)
|
||||
if (ld->getSrc(0)->asImm()->reg.data.u32 & 0xfff)
|
||||
return false;
|
||||
} else
|
||||
if (i->op == OP_ADD && i->sType == TYPE_F32) {
|
||||
// add f32 LIMM cannot saturate
|
||||
if (i->saturate && (reg.data.u32 & 0xfff))
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -431,6 +436,13 @@ TargetNVC0::isSatSupported(const Instruction *insn) const
|
||||
if (insn->dType == TYPE_U32)
|
||||
return (insn->op == OP_ADD) || (insn->op == OP_MAD);
|
||||
|
||||
// add f32 LIMM cannot saturate
|
||||
if (insn->op == OP_ADD && insn->sType == TYPE_F32) {
|
||||
if (insn->getSrc(1)->asImm() &&
|
||||
insn->getSrc(1)->reg.data.u32 & 0xfff)
|
||||
return false;
|
||||
}
|
||||
|
||||
return insn->dType == TYPE_F32;
|
||||
}
|
||||
|
||||
|
@@ -111,6 +111,7 @@ nvc0_destroy(struct pipe_context *pipe)
|
||||
nouveau_pushbuf_kick(nvc0->base.pushbuf, nvc0->base.pushbuf->channel);
|
||||
|
||||
nvc0_context_unreference_resources(nvc0);
|
||||
nvc0_blitctx_destroy(nvc0);
|
||||
|
||||
#ifdef NVC0_WITH_DRAW_MODULE
|
||||
draw_destroy(nvc0->draw);
|
||||
|
@@ -96,6 +96,7 @@
|
||||
struct nvc0_blitctx;
|
||||
|
||||
boolean nvc0_blitctx_create(struct nvc0_context *);
|
||||
void nvc0_blitctx_destroy(struct nvc0_context *);
|
||||
|
||||
struct nvc0_context {
|
||||
struct nouveau_context base;
|
||||
@@ -197,6 +198,7 @@ struct nvc0_context {
|
||||
struct pipe_surface *surfaces[2][NVC0_MAX_SURFACE_SLOTS];
|
||||
uint16_t surfaces_dirty[2];
|
||||
uint16_t surfaces_valid[2];
|
||||
uint32_t vport_int[2];
|
||||
|
||||
struct util_dynarray global_residents;
|
||||
|
||||
|
@@ -371,6 +371,7 @@ nvc0_screen_destroy(struct pipe_screen *pscreen)
|
||||
nouveau_object_del(&screen->eng3d);
|
||||
nouveau_object_del(&screen->eng2d);
|
||||
nouveau_object_del(&screen->m2mf);
|
||||
nouveau_object_del(&screen->compute);
|
||||
|
||||
nouveau_screen_fini(&screen->base);
|
||||
|
||||
|
@@ -245,9 +245,11 @@ nvc0_validate_viewport(struct nvc0_context *nvc0)
|
||||
zmin = vp->translate[2] - fabsf(vp->scale[2]);
|
||||
zmax = vp->translate[2] + fabsf(vp->scale[2]);
|
||||
|
||||
nvc0->vport_int[0] = (w << 16) | x;
|
||||
nvc0->vport_int[1] = (h << 16) | y;
|
||||
BEGIN_NVC0(push, NVC0_3D(VIEWPORT_HORIZ(0)), 2);
|
||||
PUSH_DATA (push, (w << 16) | x);
|
||||
PUSH_DATA (push, (h << 16) | y);
|
||||
PUSH_DATA (push, nvc0->vport_int[0]);
|
||||
PUSH_DATA (push, nvc0->vport_int[1]);
|
||||
BEGIN_NVC0(push, NVC0_3D(DEPTH_RANGE_NEAR(0)), 2);
|
||||
PUSH_DATAf(push, zmin);
|
||||
PUSH_DATAf(push, zmax);
|
||||
|
@@ -948,8 +948,8 @@ nvc0_blit_3d(struct nvc0_context *nvc0, const struct pipe_blit_info *info)
|
||||
/* restore viewport */
|
||||
|
||||
BEGIN_NVC0(push, NVC0_3D(VIEWPORT_HORIZ(0)), 2);
|
||||
PUSH_DATA (push, nvc0->framebuffer.width << 16);
|
||||
PUSH_DATA (push, nvc0->framebuffer.height << 16);
|
||||
PUSH_DATA (push, nvc0->vport_int[0]);
|
||||
PUSH_DATA (push, nvc0->vport_int[1]);
|
||||
IMMED_NVC0(push, NVC0_3D(VIEWPORT_TRANSFORM_EN), 1);
|
||||
}
|
||||
|
||||
@@ -1246,6 +1246,13 @@ nvc0_blitctx_create(struct nvc0_context *nvc0)
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
void
|
||||
nvc0_blitctx_destroy(struct nvc0_context *nvc0)
|
||||
{
|
||||
if (nvc0->blit)
|
||||
FREE(nvc0->blit);
|
||||
}
|
||||
|
||||
void
|
||||
nvc0_init_surface_functions(struct nvc0_context *nvc0)
|
||||
{
|
||||
|
@@ -236,14 +236,21 @@ void r600_flush_emit(struct r600_context *rctx)
|
||||
}
|
||||
|
||||
if (rctx->flags & R600_CONTEXT_INV_CONST_CACHE) {
|
||||
cp_coher_cntl |= S_0085F0_SH_ACTION_ENA(1);
|
||||
/* Direct constant addressing uses the shader cache.
|
||||
* Indirect contant addressing uses the vertex cache. */
|
||||
cp_coher_cntl |= S_0085F0_SH_ACTION_ENA(1) |
|
||||
(rctx->has_vertex_cache ? S_0085F0_VC_ACTION_ENA(1)
|
||||
: S_0085F0_TC_ACTION_ENA(1));
|
||||
}
|
||||
if (rctx->flags & R600_CONTEXT_INV_VERTEX_CACHE) {
|
||||
cp_coher_cntl |= rctx->has_vertex_cache ? S_0085F0_VC_ACTION_ENA(1)
|
||||
: S_0085F0_TC_ACTION_ENA(1);
|
||||
}
|
||||
if (rctx->flags & R600_CONTEXT_INV_TEX_CACHE) {
|
||||
cp_coher_cntl |= S_0085F0_TC_ACTION_ENA(1);
|
||||
/* Textures use the texture cache.
|
||||
* Texture buffer objects use the vertex cache. */
|
||||
cp_coher_cntl |= S_0085F0_TC_ACTION_ENA(1) |
|
||||
(rctx->has_vertex_cache ? S_0085F0_VC_ACTION_ENA(1) : 0);
|
||||
}
|
||||
|
||||
/* Don't use the DB CP COHER logic on r6xx.
|
||||
|
@@ -322,6 +322,21 @@ static void r600_compressed_to_blittable(struct pipe_resource *tex,
|
||||
rtex->surface.level[0].npix_y = util_format_get_nblocksy(orig->format, orig->npix0_y);
|
||||
rtex->surface.level[level].npix_x = util_format_get_nblocksx(orig->format, orig->npix_x);
|
||||
rtex->surface.level[level].npix_y = util_format_get_nblocksy(orig->format, orig->npix_y);
|
||||
|
||||
/* By dividing the dimensions by 4, we effectively decrement
|
||||
* last_level by 2, therefore the last 2 mipmap levels disappear and
|
||||
* aren't blittable. Note that the last 3 mipmap levels (4x4, 2x2,
|
||||
* 1x1) have equal slice sizes, which is an important assumption
|
||||
* for this to work.
|
||||
*
|
||||
* In order to make the last 2 mipmap levels blittable, we have to
|
||||
* add the slice size of the last mipmap level to the texture
|
||||
* address, so that even though the hw thinks it reads last_level-2,
|
||||
* it will actually read last_level-1, and if we add the slice size*2,
|
||||
* it will read last_level. That's how this workaround works.
|
||||
*/
|
||||
if (level > rtex->resource.b.b.last_level-2)
|
||||
rtex->mipmap_shift = level - (rtex->resource.b.b.last_level-2);
|
||||
}
|
||||
|
||||
static void r600_change_format(struct pipe_resource *tex,
|
||||
@@ -355,6 +370,7 @@ static void r600_reset_blittable_to_orig(struct pipe_resource *tex,
|
||||
rtex->surface.level[0].npix_y = orig->npix0_y;
|
||||
rtex->surface.level[level].npix_x = orig->npix_x;
|
||||
rtex->surface.level[level].npix_y = orig->npix_y;
|
||||
rtex->mipmap_shift = 0;
|
||||
}
|
||||
|
||||
static void r600_resource_copy_region(struct pipe_context *ctx,
|
||||
|
@@ -53,6 +53,8 @@ struct r600_resource_texture {
|
||||
struct r600_resource_texture *flushed_depth_texture;
|
||||
boolean is_flushing_texture;
|
||||
struct radeon_surface surface;
|
||||
|
||||
unsigned mipmap_shift;
|
||||
};
|
||||
|
||||
struct r600_surface {
|
||||
|
@@ -298,11 +298,15 @@ const char *r600_get_llvm_processor_name(enum radeon_family family)
|
||||
case CHIP_PITCAIRN: return "pitcairn";
|
||||
case CHIP_VERDE: return "verde";
|
||||
case CHIP_OLAND: return "oland";
|
||||
#if HAVE_LLVM <= 0x0303
|
||||
default: return "SI";
|
||||
#else
|
||||
case CHIP_HAINAN: return "hainan";
|
||||
case CHIP_BONAIRE: return "bonaire";
|
||||
case CHIP_KABINI: return "kabini";
|
||||
case CHIP_KAVERI: return "kaveri";
|
||||
default: return "";
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -804,7 +804,10 @@ handle_semantic:
|
||||
args[7] =
|
||||
args[8] =
|
||||
args[6] = LLVMBuildLoad(base->gallivm->builder, out_ptr, "");
|
||||
mask |= 0x2;
|
||||
/* Only setting the stencil component bit (0x2) here
|
||||
* breaks some stencil piglit tests
|
||||
*/
|
||||
mask |= 0x3;
|
||||
|
||||
if (depth_index < 0)
|
||||
args[5] = args[6];
|
||||
|
@@ -2394,6 +2394,7 @@ static struct pipe_sampler_view *si_create_sampler_view(struct pipe_context *ctx
|
||||
|
||||
va = r600_resource_va(ctx->screen, texture);
|
||||
va += surflevel[0].offset;
|
||||
va += tmp->mipmap_shift * surflevel[texture->last_level].slice_size;
|
||||
view->state[0] = va >> 8;
|
||||
view->state[1] = (S_008F14_BASE_ADDRESS_HI(va >> 40) |
|
||||
S_008F14_DATA_FORMAT(format) |
|
||||
@@ -2404,8 +2405,8 @@ static struct pipe_sampler_view *si_create_sampler_view(struct pipe_context *ctx
|
||||
S_008F1C_DST_SEL_Y(si_map_swizzle(swizzle[1])) |
|
||||
S_008F1C_DST_SEL_Z(si_map_swizzle(swizzle[2])) |
|
||||
S_008F1C_DST_SEL_W(si_map_swizzle(swizzle[3])) |
|
||||
S_008F1C_BASE_LEVEL(state->u.tex.first_level) |
|
||||
S_008F1C_LAST_LEVEL(state->u.tex.last_level) |
|
||||
S_008F1C_BASE_LEVEL(state->u.tex.first_level - tmp->mipmap_shift) |
|
||||
S_008F1C_LAST_LEVEL(state->u.tex.last_level - tmp->mipmap_shift) |
|
||||
S_008F1C_TILING_INDEX(si_tile_mode_index(tmp, 0, false)) |
|
||||
S_008F1C_POW2_PAD(texture->last_level > 0) |
|
||||
S_008F1C_TYPE(si_tex_dim(texture->target)));
|
||||
|
@@ -502,7 +502,7 @@ svga_buffer_upload_piecewise(struct svga_screen *ss,
|
||||
PIPE_TRANSFER_DISCARD_RANGE);
|
||||
assert(map);
|
||||
if (map) {
|
||||
memcpy(map, sbuf->swbuf, size);
|
||||
memcpy(map, (const char *) sbuf->swbuf + offset, size);
|
||||
sws->buffer_unmap(sws, hwbuf);
|
||||
}
|
||||
|
||||
|
@@ -342,7 +342,8 @@ struct st_framebuffer_iface
|
||||
* the last call might be destroyed. This behavior might change in the
|
||||
* future.
|
||||
*/
|
||||
boolean (*validate)(struct st_framebuffer_iface *stfbi,
|
||||
boolean (*validate)(struct st_context_iface *stctx,
|
||||
struct st_framebuffer_iface *stfbi,
|
||||
const enum st_attachment_type *statts,
|
||||
unsigned count,
|
||||
struct pipe_resource **out);
|
||||
|
@@ -174,7 +174,7 @@ mapping::mapping(command_queue &q, resource &r,
|
||||
pctx(q.pipe) {
|
||||
unsigned usage = ((flags & CL_MAP_WRITE ? PIPE_TRANSFER_WRITE : 0 ) |
|
||||
(flags & CL_MAP_READ ? PIPE_TRANSFER_READ : 0 ) |
|
||||
(blocking ? PIPE_TRANSFER_UNSYNCHRONIZED : 0));
|
||||
(!blocking ? PIPE_TRANSFER_UNSYNCHRONIZED : 0));
|
||||
|
||||
p = pctx->transfer_map(pctx, r.pipe, 0, usage,
|
||||
box(origin + r.offset, region), &pxfer);
|
||||
|
@@ -42,11 +42,13 @@ static void
|
||||
swap_fences_unref(struct dri_drawable *draw);
|
||||
|
||||
static boolean
|
||||
dri_st_framebuffer_validate(struct st_framebuffer_iface *stfbi,
|
||||
dri_st_framebuffer_validate(struct st_context_iface *stctx,
|
||||
struct st_framebuffer_iface *stfbi,
|
||||
const enum st_attachment_type *statts,
|
||||
unsigned count,
|
||||
struct pipe_resource **out)
|
||||
{
|
||||
struct dri_context *ctx = (struct dri_context *)stctx->st_manager_private;
|
||||
struct dri_drawable *drawable =
|
||||
(struct dri_drawable *) stfbi->st_manager_private;
|
||||
struct dri_screen *screen = dri_screen(drawable->sPriv);
|
||||
@@ -78,7 +80,7 @@ dri_st_framebuffer_validate(struct st_framebuffer_iface *stfbi,
|
||||
if (new_stamp && drawable->update_drawable_info)
|
||||
drawable->update_drawable_info(drawable);
|
||||
|
||||
drawable->allocate_textures(drawable, statts, count);
|
||||
drawable->allocate_textures(ctx, drawable, statts, count);
|
||||
|
||||
/* add existing textures */
|
||||
for (i = 0; i < ST_ATTACHMENT_COUNT; i++) {
|
||||
@@ -183,7 +185,8 @@ dri_destroy_buffer(__DRIdrawable * dPriv)
|
||||
* exist. Used by the TFP extension.
|
||||
*/
|
||||
static void
|
||||
dri_drawable_validate_att(struct dri_drawable *drawable,
|
||||
dri_drawable_validate_att(struct dri_context *ctx,
|
||||
struct dri_drawable *drawable,
|
||||
enum st_attachment_type statt)
|
||||
{
|
||||
enum st_attachment_type statts[ST_ATTACHMENT_COUNT];
|
||||
@@ -203,7 +206,7 @@ dri_drawable_validate_att(struct dri_drawable *drawable,
|
||||
|
||||
drawable->texture_stamp = drawable->dPriv->lastStamp - 1;
|
||||
|
||||
drawable->base.validate(&drawable->base, statts, count, NULL);
|
||||
drawable->base.validate(ctx->st, &drawable->base, statts, count, NULL);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -217,7 +220,7 @@ dri_set_tex_buffer2(__DRIcontext *pDRICtx, GLint target,
|
||||
struct dri_drawable *drawable = dri_drawable(dPriv);
|
||||
struct pipe_resource *pt;
|
||||
|
||||
dri_drawable_validate_att(drawable, ST_ATTACHMENT_FRONT_LEFT);
|
||||
dri_drawable_validate_att(ctx, drawable, ST_ATTACHMENT_FRONT_LEFT);
|
||||
|
||||
/* Use the pipe resource associated with the X drawable */
|
||||
pt = drawable->textures[ST_ATTACHMENT_FRONT_LEFT];
|
||||
|
@@ -71,7 +71,8 @@ struct dri_drawable
|
||||
struct pipe_surface *drisw_surface;
|
||||
|
||||
/* hooks filled in by dri2 & drisw */
|
||||
void (*allocate_textures)(struct dri_drawable *drawable,
|
||||
void (*allocate_textures)(struct dri_context *ctx,
|
||||
struct dri_drawable *drawable,
|
||||
const enum st_attachment_type *statts,
|
||||
unsigned count);
|
||||
|
||||
|
@@ -169,7 +169,8 @@ dri2_drawable_get_buffers(struct dri_drawable *drawable,
|
||||
* Process __DRIbuffer and convert them into pipe_resources.
|
||||
*/
|
||||
static void
|
||||
dri2_drawable_process_buffers(struct dri_drawable *drawable,
|
||||
dri2_drawable_process_buffers(struct dri_context *ctx,
|
||||
struct dri_drawable *drawable,
|
||||
__DRIbuffer *buffers, unsigned buffer_count,
|
||||
const enum st_attachment_type *atts,
|
||||
unsigned att_count)
|
||||
@@ -180,8 +181,6 @@ dri2_drawable_process_buffers(struct dri_drawable *drawable,
|
||||
struct winsys_handle whandle;
|
||||
boolean alloc_depthstencil = FALSE;
|
||||
unsigned i, j, bind;
|
||||
struct pipe_screen *pscreen = screen->base.screen;
|
||||
struct pipe_context *pipe = NULL;
|
||||
|
||||
if (drawable->old_num == buffer_count &&
|
||||
drawable->old_w == dri_drawable->w &&
|
||||
@@ -308,14 +307,8 @@ dri2_drawable_process_buffers(struct dri_drawable *drawable,
|
||||
* The single-sample resources are not exposed
|
||||
* to the state tracker.
|
||||
*
|
||||
* We don't have a context here, so create one temporarily.
|
||||
* We may need to create a persistent context if creation and
|
||||
* destruction of the context becomes a bottleneck.
|
||||
*/
|
||||
if (!pipe)
|
||||
pipe = pscreen->context_create(pscreen, NULL);
|
||||
|
||||
dri_pipe_blit(pipe,
|
||||
dri_pipe_blit(ctx->st->pipe,
|
||||
drawable->msaa_textures[att],
|
||||
drawable->textures[att]);
|
||||
}
|
||||
@@ -371,11 +364,6 @@ dri2_drawable_process_buffers(struct dri_drawable *drawable,
|
||||
drawable->old_w = dri_drawable->w;
|
||||
drawable->old_h = dri_drawable->h;
|
||||
memcpy(drawable->old, buffers, sizeof(__DRIbuffer) * buffer_count);
|
||||
|
||||
if (pipe) {
|
||||
pipe->flush(pipe, NULL, 0);
|
||||
pipe->destroy(pipe);
|
||||
}
|
||||
}
|
||||
|
||||
static __DRIbuffer *
|
||||
@@ -470,7 +458,8 @@ dri2_release_buffer(__DRIscreen *sPriv, __DRIbuffer *bPriv)
|
||||
*/
|
||||
|
||||
static void
|
||||
dri2_allocate_textures(struct dri_drawable *drawable,
|
||||
dri2_allocate_textures(struct dri_context *ctx,
|
||||
struct dri_drawable *drawable,
|
||||
const enum st_attachment_type *statts,
|
||||
unsigned statts_count)
|
||||
{
|
||||
@@ -479,7 +468,7 @@ dri2_allocate_textures(struct dri_drawable *drawable,
|
||||
|
||||
buffers = dri2_drawable_get_buffers(drawable, statts, &num_buffers);
|
||||
if (buffers)
|
||||
dri2_drawable_process_buffers(drawable, buffers, num_buffers,
|
||||
dri2_drawable_process_buffers(ctx, drawable, buffers, num_buffers,
|
||||
statts, statts_count);
|
||||
}
|
||||
|
||||
|
@@ -182,7 +182,8 @@ drisw_flush_frontbuffer(struct dri_context *ctx,
|
||||
* framebuffer is resized or destroyed.
|
||||
*/
|
||||
static void
|
||||
drisw_allocate_textures(struct dri_drawable *drawable,
|
||||
drisw_allocate_textures(struct dri_context *stctx,
|
||||
struct dri_drawable *drawable,
|
||||
const enum st_attachment_type *statts,
|
||||
unsigned count)
|
||||
{
|
||||
|
@@ -443,7 +443,7 @@ egl_g3d_create_pbuffer_from_client_buffer(_EGLDriver *drv, _EGLDisplay *dpy,
|
||||
gsurf->client_buffer = buffer;
|
||||
|
||||
/* validate now so that it fails if the client buffer is invalid */
|
||||
if (!gsurf->stfbi->validate(gsurf->stfbi,
|
||||
if (!gsurf->stfbi->validate(NULL, gsurf->stfbi,
|
||||
&gsurf->stvis.render_buffer, 1, &ptex)) {
|
||||
egl_g3d_destroy_st_framebuffer(gsurf->stfbi);
|
||||
FREE(gsurf);
|
||||
|
@@ -149,7 +149,8 @@ pbuffer_allocate_pbuffer_texture(struct egl_g3d_surface *gsurf)
|
||||
}
|
||||
|
||||
static boolean
|
||||
egl_g3d_st_framebuffer_validate_pbuffer(struct st_framebuffer_iface *stfbi,
|
||||
egl_g3d_st_framebuffer_validate_pbuffer(struct st_context_iface *stctx,
|
||||
struct st_framebuffer_iface *stfbi,
|
||||
const enum st_attachment_type *statts,
|
||||
unsigned count,
|
||||
struct pipe_resource **out)
|
||||
@@ -202,7 +203,8 @@ egl_g3d_st_framebuffer_flush_front(struct st_context_iface *stctx,
|
||||
}
|
||||
|
||||
static boolean
|
||||
egl_g3d_st_framebuffer_validate(struct st_framebuffer_iface *stfbi,
|
||||
egl_g3d_st_framebuffer_validate(struct st_context_iface *stctx,
|
||||
struct st_framebuffer_iface *stfbi,
|
||||
const enum st_attachment_type *statts,
|
||||
unsigned count,
|
||||
struct pipe_resource **out)
|
||||
|
@@ -246,6 +246,10 @@ struct native_display {
|
||||
const struct native_display_buffer *buffer;
|
||||
const struct native_display_modeset *modeset;
|
||||
const struct native_display_wayland_bufmgr *wayland_bufmgr;
|
||||
|
||||
#ifdef HAVE_WAYLAND_BACKEND
|
||||
struct wl_drm *wl_server_drm; /* for EGL_WL_bind_wayland_display */
|
||||
#endif
|
||||
};
|
||||
|
||||
/**
|
||||
|
@@ -77,7 +77,7 @@ egl_g3d_wl_drm_common_query_buffer(struct native_display *ndpy,
|
||||
struct wl_drm_buffer *buffer = (struct wl_drm_buffer *) _buffer;
|
||||
struct pipe_resource *resource = buffer->driver_buffer;
|
||||
|
||||
if (!wayland_buffer_is_drm(&buffer->buffer))
|
||||
if (!wayland_buffer_is_drm(ndpy->wl_server_drm, &buffer->buffer))
|
||||
return EGL_FALSE;
|
||||
|
||||
switch (attribute) {
|
||||
|
@@ -39,6 +39,10 @@
|
||||
#include <libudev.h>
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_WAYLAND_BACKEND
|
||||
#include "common/native_wayland_drm_bufmgr_helper.h"
|
||||
#endif
|
||||
|
||||
static boolean
|
||||
drm_display_is_format_supported(struct native_display *ndpy,
|
||||
enum pipe_format fmt, boolean is_color)
|
||||
@@ -207,14 +211,14 @@ drm_display_bind_wayland_display(struct native_display *ndpy,
|
||||
{
|
||||
struct drm_display *drmdpy = drm_display(ndpy);
|
||||
|
||||
if (drmdpy->wl_server_drm)
|
||||
if (ndpy->wl_server_drm)
|
||||
return FALSE;
|
||||
|
||||
drmdpy->wl_server_drm = wayland_drm_init(wl_dpy,
|
||||
ndpy->wl_server_drm = wayland_drm_init(wl_dpy,
|
||||
drmdpy->device_name,
|
||||
&wl_drm_callbacks, ndpy, 0);
|
||||
|
||||
if (!drmdpy->wl_server_drm)
|
||||
if (!ndpy->wl_server_drm)
|
||||
return FALSE;
|
||||
|
||||
return TRUE;
|
||||
@@ -224,13 +228,11 @@ static boolean
|
||||
drm_display_unbind_wayland_display(struct native_display *ndpy,
|
||||
struct wl_display *wl_dpy)
|
||||
{
|
||||
struct drm_display *drmdpy = drm_display(ndpy);
|
||||
|
||||
if (!drmdpy->wl_server_drm)
|
||||
if (!ndpy->wl_server_drm)
|
||||
return FALSE;
|
||||
|
||||
wayland_drm_uninit(drmdpy->wl_server_drm);
|
||||
drmdpy->wl_server_drm = NULL;
|
||||
wayland_drm_uninit(ndpy->wl_server_drm);
|
||||
ndpy->wl_server_drm = NULL;
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
@@ -36,10 +36,6 @@
|
||||
#include "common/native.h"
|
||||
#include "common/native_helper.h"
|
||||
|
||||
#ifdef HAVE_WAYLAND_BACKEND
|
||||
#include "common/native_wayland_drm_bufmgr_helper.h"
|
||||
#endif
|
||||
|
||||
#include "gbm_gallium_drmint.h"
|
||||
|
||||
struct drm_config;
|
||||
@@ -67,10 +63,6 @@ struct drm_display {
|
||||
struct drm_surface **shown_surfaces;
|
||||
/* save the original settings of the CRTCs */
|
||||
struct drm_crtc *saved_crtcs;
|
||||
|
||||
#ifdef HAVE_WAYLAND_BACKEND
|
||||
struct wl_drm *wl_server_drm; /* for EGL_WL_bind_wayland_display */
|
||||
#endif
|
||||
};
|
||||
|
||||
struct drm_config {
|
||||
|
@@ -268,7 +268,7 @@ wayland_drm_display_bind_wayland_display(struct native_display *ndpy,
|
||||
if (drmdpy->wl_server_drm)
|
||||
return FALSE;
|
||||
|
||||
drmdpy->wl_server_drm =
|
||||
ndpy->wl_server_drm =
|
||||
wayland_drm_init(wl_dpy, drmdpy->device_name,
|
||||
&wl_drm_callbacks, ndpy, 0);
|
||||
|
||||
|
@@ -858,7 +858,7 @@ dri2_display_bind_wayland_display(struct native_display *ndpy,
|
||||
if (dri2dpy->wl_server_drm)
|
||||
return FALSE;
|
||||
|
||||
dri2dpy->wl_server_drm = wayland_drm_init(wl_dpy,
|
||||
ndpy->wl_server_drm = wayland_drm_init(wl_dpy,
|
||||
x11_screen_get_device_name(dri2dpy->xscr),
|
||||
&wl_drm_callbacks, ndpy, 0);
|
||||
|
||||
|
@@ -27,6 +27,7 @@ AM_CPPFLAGS = \
|
||||
-I$(top_srcdir)/src/gbm/main \
|
||||
-I$(top_srcdir)/include
|
||||
if HAVE_EGL_PLATFORM_WAYLAND
|
||||
AM_CFLAGS += $(WAYLAND_CFLAGS)
|
||||
AM_CPPFLAGS += -DHAVE_WAYLAND_PLATFORM
|
||||
endif
|
||||
|
||||
|
@@ -194,7 +194,8 @@ xmesa_st_framebuffer_validate_textures(struct st_framebuffer_iface *stfbi,
|
||||
* \param out returns resources for each of the attachments
|
||||
*/
|
||||
static boolean
|
||||
xmesa_st_framebuffer_validate(struct st_framebuffer_iface *stfbi,
|
||||
xmesa_st_framebuffer_validate(struct st_context_iface *stctx,
|
||||
struct st_framebuffer_iface *stfbi,
|
||||
const enum st_attachment_type *statts,
|
||||
unsigned count,
|
||||
struct pipe_resource **out)
|
||||
|
@@ -342,7 +342,8 @@ osmesa_st_framebuffer_flush_front(struct st_context_iface *stctx,
|
||||
* its resources).
|
||||
*/
|
||||
static boolean
|
||||
osmesa_st_framebuffer_validate(struct st_framebuffer_iface *stfbi,
|
||||
osmesa_st_framebuffer_validate(struct st_context_iface *stctx,
|
||||
struct st_framebuffer_iface *stfbi,
|
||||
const enum st_attachment_type *statts,
|
||||
unsigned count,
|
||||
struct pipe_resource **out)
|
||||
|
@@ -113,7 +113,8 @@ vg_manager_validate_framebuffer(struct vg_context *ctx)
|
||||
if (stfb->iface_stamp != new_stamp) {
|
||||
do {
|
||||
/* validate the fb */
|
||||
if (!stfb->iface->validate(stfb->iface, &stfb->strb_att,
|
||||
if (!stfb->iface->validate((struct st_context_iface *)ctx,
|
||||
stfb->iface, &stfb->strb_att,
|
||||
1, &pt) || !pt)
|
||||
return;
|
||||
|
||||
|
@@ -121,7 +121,8 @@ stw_st_framebuffer_validate_locked(struct st_framebuffer_iface *stfb,
|
||||
}
|
||||
|
||||
static boolean
|
||||
stw_st_framebuffer_validate(struct st_framebuffer_iface *stfb,
|
||||
stw_st_framebuffer_validate(struct st_context_iface *stctx,
|
||||
struct st_framebuffer_iface *stfb,
|
||||
const enum st_attachment_type *statts,
|
||||
unsigned count,
|
||||
struct pipe_resource **out)
|
||||
|
@@ -57,19 +57,12 @@ lib@OSMESA_LIB@_la_LIBADD = \
|
||||
$(CLOCK_LIB)
|
||||
|
||||
|
||||
nodist_EXTRA_lib@OSMESA_LIB@_la_SOURCES = dummy.cpp
|
||||
|
||||
if HAVE_MESA_LLVM
|
||||
lib@OSMESA_LIB@_la_LINK = $(CXXLINK) $(lib@OSMESA_LIB@_la_LDFLAGS)
|
||||
# Mention a dummy pure C++ file to trigger generation of the $(LINK) variable
|
||||
nodist_EXTRA_lib@OSMESA_LIB@_la_SOURCES = dummy-cpp.cpp
|
||||
|
||||
lib@OSMESA_LIB@_la_LIBADD += $(top_builddir)/src/gallium/drivers/llvmpipe/libllvmpipe.la $(LLVM_LIBS)
|
||||
AM_CPPFLAGS += -DGALLIUM_LLVMPIPE
|
||||
lib@OSMESA_LIB@_la_LDFLAGS += $(LLVM_LDFLAGS)
|
||||
else
|
||||
lib@OSMESA_LIB@_la_LINK = $(CXXLINK) $(lib@OSMESA_LIB@_la_LDFLAGS)
|
||||
# Mention a dummy pure C file to trigger generation of the $(LINK) variable
|
||||
nodist_EXTRA_lib@OSMESA_LIB@_la_SOURCES = dummy-c.c
|
||||
lib@OSMESA_LIB@_la_LIBADD += $(top_builddir)/src/gallium/drivers/llvmpipe/libllvmpipe.la $(LLVM_LIBS)
|
||||
endif
|
||||
|
||||
|
||||
@@ -82,9 +75,8 @@ all-local: lib@OSMESA_LIB@.la
|
||||
$(MKDIR_P) $(top_builddir)/$(LIB_DIR)/gallium;
|
||||
ln -f .libs/lib@OSMESA_LIB@.so $(top_builddir)/$(LIB_DIR)/gallium/lib@OSMESA_LIB@.so;
|
||||
ln -f .libs/lib@OSMESA_LIB@.so.@OSMESA_VERSION@ $(top_builddir)/$(LIB_DIR)/gallium/lib@OSMESA_LIB@.so.@OSMESA_VERSION@;
|
||||
cp .libs/lib@OSMESA_LIB@.so.@OSMESA_VERSION@.0.0 $(top_builddir)/$(LIB_DIR)/gallium/
|
||||
ln -f .libs/lib@OSMESA_LIB@.so.@OSMESA_VERSION@.0.0 $(top_builddir)/$(LIB_DIR)/gallium/
|
||||
endif
|
||||
|
||||
# XXX fix-up?
|
||||
#pkgconfigdir = $(libdir)/pkgconfig
|
||||
#pkgconfig_DATA = osmesa.pc
|
||||
pkgconfigdir = $(libdir)/pkgconfig
|
||||
pkgconfig_DATA = osmesa.pc
|
||||
|
12
src/gallium/targets/osmesa/osmesa.pc.in
Normal file
12
src/gallium/targets/osmesa/osmesa.pc.in
Normal file
@@ -0,0 +1,12 @@
|
||||
prefix=@prefix@
|
||||
exec_prefix=${prefix}
|
||||
libdir=@libdir@
|
||||
includedir=@includedir@
|
||||
|
||||
Name: osmesa
|
||||
Description: Mesa Off-screen Rendering library
|
||||
Requires: @OSMESA_PC_REQ@
|
||||
Version: @OSMESA_VERSION@
|
||||
Libs: -L${libdir} -l@OSMESA_LIB@
|
||||
Libs.private: @OSMESA_PC_LIB_PRIV@
|
||||
Cflags: -I${includedir}
|
@@ -466,6 +466,36 @@ static void radeon_drm_cs_flush(struct radeon_winsys_cs *rcs, unsigned flags, ui
|
||||
struct radeon_drm_cs *cs = radeon_drm_cs(rcs);
|
||||
struct radeon_cs_context *tmp;
|
||||
|
||||
switch (cs->base.ring_type) {
|
||||
case RING_DMA:
|
||||
/* pad DMA ring to 8 DWs */
|
||||
if (cs->ws->info.chip_class <= SI) {
|
||||
while (rcs->cdw & 7)
|
||||
OUT_CS(&cs->base, 0xf0000000); /* NOP packet */
|
||||
} else {
|
||||
while (rcs->cdw & 7)
|
||||
OUT_CS(&cs->base, 0x00000000); /* NOP packet */
|
||||
}
|
||||
break;
|
||||
case RING_GFX:
|
||||
/* pad DMA ring to 8 DWs to meet CP fetch alignment requirements
|
||||
* r6xx, requires at least 4 dw alignment to avoid a hw bug.
|
||||
*/
|
||||
if (flags & RADEON_FLUSH_COMPUTE) {
|
||||
if (cs->ws->info.chip_class <= SI) {
|
||||
while (rcs->cdw & 7)
|
||||
OUT_CS(&cs->base, 0x80000000); /* type2 nop packet */
|
||||
} else {
|
||||
while (rcs->cdw & 7)
|
||||
OUT_CS(&cs->base, 0xffff1000); /* type3 nop packet */
|
||||
}
|
||||
} else {
|
||||
while (rcs->cdw & 7)
|
||||
OUT_CS(&cs->base, 0x80000000); /* type2 nop packet */
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
if (rcs->cdw > RADEON_MAX_CMDBUF_DWORDS) {
|
||||
fprintf(stderr, "radeon: command stream overflowed\n");
|
||||
}
|
||||
|
@@ -376,7 +376,10 @@ gbm_dri_bo_import(struct gbm_device *gbm,
|
||||
{
|
||||
struct wl_drm_buffer *wb = (struct wl_drm_buffer *) buffer;
|
||||
|
||||
if (!wayland_buffer_is_drm(buffer))
|
||||
if (dri->wl_drm == NULL)
|
||||
return NULL;
|
||||
|
||||
if (!wayland_buffer_is_drm(dri->wl_drm, buffer))
|
||||
return NULL;
|
||||
|
||||
image = wb->driver_buffer;
|
||||
|
@@ -66,6 +66,8 @@ struct gbm_dri_device {
|
||||
int *width, int *height,
|
||||
unsigned int *attachments, int count,
|
||||
int *out_count, void *data);
|
||||
|
||||
struct wl_drm *wl_drm;
|
||||
};
|
||||
|
||||
struct gbm_dri_bo {
|
||||
|
@@ -1847,9 +1847,18 @@ is_varying_var(ir_variable *var, _mesa_glsl_parser_targets target)
|
||||
static void
|
||||
validate_matrix_layout_for_type(struct _mesa_glsl_parse_state *state,
|
||||
YYLTYPE *loc,
|
||||
const glsl_type *type)
|
||||
const glsl_type *type,
|
||||
ir_variable *var)
|
||||
{
|
||||
if (!type->is_matrix()) {
|
||||
if (var && !var->is_in_uniform_block()) {
|
||||
/* Layout qualifiers may only apply to interface blocks and fields in
|
||||
* them.
|
||||
*/
|
||||
_mesa_glsl_error(loc, state,
|
||||
"uniform block layout qualifiers row_major and "
|
||||
"column_major may not be applied to variables "
|
||||
"outside of uniform blocks");
|
||||
} else if (!type->is_matrix()) {
|
||||
/* The OpenGL ES 3.0 conformance tests did not originally allow
|
||||
* matrix layout qualifiers on non-matrices. However, the OpenGL
|
||||
* 4.4 and OpenGL ES 3.0 (revision TBD) specifications were
|
||||
@@ -2287,7 +2296,7 @@ apply_type_qualifier_to_variable(const struct ast_type_qualifier *qual,
|
||||
}
|
||||
|
||||
if (qual->flags.q.row_major || qual->flags.q.column_major) {
|
||||
validate_matrix_layout_for_type(state, loc, var->type);
|
||||
validate_matrix_layout_for_type(state, loc, var->type, var);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2997,32 +3006,45 @@ ast_declarator_list::hir(exec_list *instructions,
|
||||
}
|
||||
|
||||
|
||||
/* Precision qualifiers only apply to floating point and integer types.
|
||||
/* Precision qualifiers apply to floating point, integer and sampler
|
||||
* types.
|
||||
*
|
||||
* From section 4.5.2 of the GLSL 1.30 spec:
|
||||
* Section 4.5.2 (Precision Qualifiers) of the GLSL 1.30 spec says:
|
||||
* "Any floating point or any integer declaration can have the type
|
||||
* preceded by one of these precision qualifiers [...] Literal
|
||||
* constants do not have precision qualifiers. Neither do Boolean
|
||||
* variables.
|
||||
*
|
||||
* In GLSL ES, sampler types are also allowed.
|
||||
* Section 4.5 (Precision and Precision Qualifiers) of the GLSL 1.30
|
||||
* spec also says:
|
||||
*
|
||||
* From page 87 of the GLSL ES spec:
|
||||
* "RESOLUTION: Allow sampler types to take a precision qualifier."
|
||||
* "Precision qualifiers are added for code portability with OpenGL
|
||||
* ES, not for functionality. They have the same syntax as in OpenGL
|
||||
* ES."
|
||||
*
|
||||
* Section 8 (Built-In Functions) of the GLSL ES 1.00 spec says:
|
||||
*
|
||||
* "uniform lowp sampler2D sampler;
|
||||
* highp vec2 coord;
|
||||
* ...
|
||||
* lowp vec4 col = texture2D (sampler, coord);
|
||||
* // texture2D returns lowp"
|
||||
*
|
||||
* From this, we infer that GLSL 1.30 (and later) should allow precision
|
||||
* qualifiers on sampler types just like float and integer types.
|
||||
*/
|
||||
if (this->type->qualifier.precision != ast_precision_none
|
||||
&& !var->type->is_float()
|
||||
&& !var->type->is_integer()
|
||||
&& !var->type->is_record()
|
||||
&& !(var->type->is_sampler() && state->es_shader)
|
||||
&& !var->type->is_sampler()
|
||||
&& !(var->type->is_array()
|
||||
&& (var->type->fields.array->is_float()
|
||||
|| var->type->fields.array->is_integer()))) {
|
||||
|
||||
_mesa_glsl_error(&loc, state,
|
||||
"precision qualifiers apply only to floating point"
|
||||
"%s types", state->es_shader ? ", integer, and sampler"
|
||||
: "and integer");
|
||||
", integer and sampler types");
|
||||
}
|
||||
|
||||
/* From page 17 (page 23 of the PDF) of the GLSL 1.20 spec:
|
||||
@@ -4350,7 +4372,7 @@ ast_process_structure_or_interface_block(exec_list *instructions,
|
||||
"row_major and column_major can only be "
|
||||
"applied to uniform interface blocks");
|
||||
} else
|
||||
validate_matrix_layout_for_type(state, &loc, field_type);
|
||||
validate_matrix_layout_for_type(state, &loc, field_type, NULL);
|
||||
}
|
||||
|
||||
if (qual->flags.q.uniform && qual->has_interpolation()) {
|
||||
|
@@ -1667,13 +1667,17 @@ struct_declaration_list:
|
||||
;
|
||||
|
||||
struct_declaration:
|
||||
type_specifier struct_declarator_list ';'
|
||||
fully_specified_type struct_declarator_list ';'
|
||||
{
|
||||
void *ctx = state;
|
||||
ast_fully_specified_type *type = new(ctx) ast_fully_specified_type();
|
||||
ast_fully_specified_type *const type = $1;
|
||||
type->set_location(yylloc);
|
||||
|
||||
type->specifier = $1;
|
||||
if (type->qualifier.flags.i != 0)
|
||||
_mesa_glsl_error(&@1, state,
|
||||
"only precision qualifiers may be applied to "
|
||||
"structure members");
|
||||
|
||||
$$ = new(ctx) ast_declarator_list(type);
|
||||
$$->set_location(yylloc);
|
||||
|
||||
|
@@ -173,6 +173,38 @@ public:
|
||||
return visit_continue;
|
||||
}
|
||||
|
||||
virtual ir_visitor_status visit_leave(ir_call *ir)
|
||||
{
|
||||
/* Traverse list of function parameters, and for array parameters
|
||||
* propagate max_array_access. Otherwise arrays that are only referenced
|
||||
* from inside functions via function parameters will be incorrectly
|
||||
* optimized. This will lead to incorrect code being generated (or worse).
|
||||
* Do it when leaving the node so the children would propagate their
|
||||
* array accesses first.
|
||||
*/
|
||||
|
||||
const exec_node *formal_param_node = ir->callee->parameters.get_head();
|
||||
if (formal_param_node) {
|
||||
const exec_node *actual_param_node = ir->actual_parameters.get_head();
|
||||
while (!actual_param_node->is_tail_sentinel()) {
|
||||
ir_variable *formal_param = (ir_variable *) formal_param_node;
|
||||
ir_rvalue *actual_param = (ir_rvalue *) actual_param_node;
|
||||
|
||||
formal_param_node = formal_param_node->get_next();
|
||||
actual_param_node = actual_param_node->get_next();
|
||||
|
||||
if (formal_param->type->is_array()) {
|
||||
ir_dereference_variable *deref = actual_param->as_dereference_variable();
|
||||
if (deref && deref->var && deref->var->type->is_array()) {
|
||||
deref->var->max_array_access =
|
||||
MAX2(formal_param->max_array_access, deref->var->max_array_access);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return visit_continue;
|
||||
}
|
||||
|
||||
virtual ir_visitor_status visit(ir_dereference_variable *ir)
|
||||
{
|
||||
if (hash_table_find(locals, ir->var) == NULL) {
|
||||
|
@@ -140,8 +140,8 @@ program_resource_visitor::recursion(const glsl_type *t, char **name,
|
||||
/* Append the subscript to the current variable name */
|
||||
ralloc_asprintf_rewrite_tail(name, &new_length, "[%u]", i);
|
||||
|
||||
recursion(t->fields.array, name, new_length,
|
||||
t->fields.structure[i].row_major, record_type);
|
||||
recursion(t->fields.array, name, new_length, row_major,
|
||||
record_type);
|
||||
|
||||
/* Only the first leaf-field of the record gets called with the
|
||||
* record type pointer.
|
||||
|
@@ -260,12 +260,12 @@ dri2_create_context_attribs(struct glx_screen *base,
|
||||
__GLXDRIconfigPrivate *config = (__GLXDRIconfigPrivate *) config_base;
|
||||
__DRIcontext *shared = NULL;
|
||||
|
||||
uint32_t minor_ver = 1;
|
||||
uint32_t major_ver = 2;
|
||||
uint32_t renderType = GLX_RGBA_TYPE;
|
||||
uint32_t flags = 0;
|
||||
uint32_t minor_ver;
|
||||
uint32_t major_ver;
|
||||
uint32_t renderType;
|
||||
uint32_t flags;
|
||||
unsigned api;
|
||||
int reset = __DRI_CTX_RESET_NO_NOTIFICATION;
|
||||
int reset;
|
||||
uint32_t ctx_attribs[2 * 5];
|
||||
unsigned num_ctx_attribs = 0;
|
||||
|
||||
|
@@ -470,8 +470,14 @@ dri2_convert_glx_attribs(unsigned num_attribs, const uint32_t *attribs,
|
||||
bool got_profile = false;
|
||||
uint32_t profile;
|
||||
|
||||
*major_ver = 1;
|
||||
*minor_ver = 0;
|
||||
*render_type = GLX_RGBA_TYPE;
|
||||
*reset = __DRI_CTX_RESET_NO_NOTIFICATION;
|
||||
*flags = 0;
|
||||
*api = __DRI_API_OPENGL;
|
||||
|
||||
if (num_attribs == 0) {
|
||||
*api = __DRI_API_OPENGL;
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -482,11 +488,6 @@ dri2_convert_glx_attribs(unsigned num_attribs, const uint32_t *attribs,
|
||||
return false;
|
||||
}
|
||||
|
||||
*major_ver = 1;
|
||||
*minor_ver = 0;
|
||||
*render_type = GLX_RGBA_TYPE;
|
||||
*reset = __DRI_CTX_RESET_NO_NOTIFICATION;
|
||||
|
||||
for (i = 0; i < num_attribs; i++) {
|
||||
switch (attribs[i * 2]) {
|
||||
case GLX_CONTEXT_MAJOR_VERSION_ARB:
|
||||
@@ -526,7 +527,6 @@ dri2_convert_glx_attribs(unsigned num_attribs, const uint32_t *attribs,
|
||||
}
|
||||
}
|
||||
|
||||
*api = __DRI_API_OPENGL;
|
||||
if (!got_profile) {
|
||||
if (*major_ver > 3 || (*major_ver == 3 && *minor_ver >= 2))
|
||||
*api = __DRI_API_OPENGL_CORE;
|
||||
|
@@ -433,12 +433,12 @@ drisw_create_context_attribs(struct glx_screen *base,
|
||||
struct drisw_screen *psc = (struct drisw_screen *) base;
|
||||
__DRIcontext *shared = NULL;
|
||||
|
||||
uint32_t minor_ver = 1;
|
||||
uint32_t major_ver = 0;
|
||||
uint32_t renderType = GLX_RGBA_TYPE;
|
||||
uint32_t flags = 0;
|
||||
uint32_t minor_ver;
|
||||
uint32_t major_ver;
|
||||
uint32_t renderType;
|
||||
uint32_t flags;
|
||||
unsigned api;
|
||||
int reset = __DRI_CTX_RESET_NO_NOTIFICATION;
|
||||
int reset;
|
||||
uint32_t ctx_attribs[2 * 4];
|
||||
unsigned num_ctx_attribs = 0;
|
||||
|
||||
|
@@ -1515,6 +1515,9 @@ setup_glsl_blit_framebuffer(struct gl_context *ctx,
|
||||
sizeof(struct vertex), OFFSET(x));
|
||||
_mesa_VertexAttribPointer(1, 2, GL_FLOAT, GL_FALSE,
|
||||
sizeof(struct vertex), OFFSET(s));
|
||||
|
||||
_mesa_EnableVertexAttribArray(0);
|
||||
_mesa_EnableVertexAttribArray(1);
|
||||
}
|
||||
|
||||
/* Generate a relevant fragment shader program for the texture target */
|
||||
@@ -1591,8 +1594,6 @@ setup_glsl_blit_framebuffer(struct gl_context *ctx,
|
||||
_mesa_DeleteObjectARB(vs);
|
||||
_mesa_BindAttribLocation(ShaderProg, 0, "position");
|
||||
_mesa_BindAttribLocation(ShaderProg, 1, "texcoords");
|
||||
_mesa_EnableVertexAttribArray(0);
|
||||
_mesa_EnableVertexAttribArray(1);
|
||||
link_program_with_debug(ctx, ShaderProg);
|
||||
ralloc_free(mem_ctx);
|
||||
if (texture_2d)
|
||||
@@ -4022,6 +4023,11 @@ decompress_texture_image(struct gl_context *ctx,
|
||||
verts[3].x = 0.0F;
|
||||
verts[3].y = height;
|
||||
|
||||
_mesa_MatrixMode(GL_PROJECTION);
|
||||
_mesa_LoadIdentity();
|
||||
_mesa_Ortho(0.0, width, 0.0, height, -1.0, 1.0);
|
||||
_mesa_set_viewport(ctx, 0, 0, width, height);
|
||||
|
||||
/* upload new vertex data */
|
||||
_mesa_BufferSubData(GL_ARRAY_BUFFER_ARB, 0, sizeof(verts), verts);
|
||||
|
||||
|
@@ -2280,7 +2280,7 @@ uint32_t
|
||||
brw_blorp_blit_params::get_wm_prog(struct brw_context *brw,
|
||||
brw_blorp_prog_data **prog_data) const
|
||||
{
|
||||
uint32_t prog_offset;
|
||||
uint32_t prog_offset = 0;
|
||||
if (!brw_search_cache(&brw->cache, BRW_BLORP_BLIT_PROG,
|
||||
&this->wm_prog_key, sizeof(this->wm_prog_key),
|
||||
&prog_offset, prog_data)) {
|
||||
|
@@ -342,7 +342,7 @@ brw_blorp_const_color_params::get_wm_prog(struct brw_context *brw,
|
||||
brw_blorp_prog_data **prog_data)
|
||||
const
|
||||
{
|
||||
uint32_t prog_offset;
|
||||
uint32_t prog_offset = 0;
|
||||
if (!brw_search_cache(&brw->cache, BRW_BLORP_CONST_COLOR_PROG,
|
||||
&this->wm_prog_key, sizeof(this->wm_prog_key),
|
||||
&prog_offset, prog_data)) {
|
||||
|
@@ -32,6 +32,7 @@
|
||||
|
||||
#include "glsl/glsl_types.h"
|
||||
#include "glsl/ir.h"
|
||||
#include "program/prog_instruction.h" /* For WRITEMASK_* */
|
||||
|
||||
class brw_cubemap_normalize_visitor : public ir_hierarchical_visitor {
|
||||
public:
|
||||
@@ -88,11 +89,18 @@ brw_cubemap_normalize_visitor::visit_leave(ir_texture *ir)
|
||||
glsl_type::float_type,
|
||||
expr, NULL);
|
||||
|
||||
deref = new(mem_ctx) ir_dereference_variable(var);
|
||||
ir->coordinate = new(mem_ctx) ir_expression(ir_binop_mul,
|
||||
ir->coordinate->type,
|
||||
deref,
|
||||
expr);
|
||||
/* coordinate.xyz *= expr */
|
||||
assign = new(mem_ctx) ir_assignment(
|
||||
new(mem_ctx) ir_dereference_variable(var),
|
||||
new(mem_ctx) ir_swizzle(
|
||||
new(mem_ctx) ir_expression(ir_binop_mul,
|
||||
ir->coordinate->type,
|
||||
new(mem_ctx) ir_dereference_variable(var),
|
||||
expr),
|
||||
0, 1, 2, 0, 3));
|
||||
assign->write_mask = WRITEMASK_XYZ;
|
||||
base_ir->insert_before(assign);
|
||||
ir->coordinate = new(mem_ctx) ir_dereference_variable(var);
|
||||
|
||||
progress = true;
|
||||
return visit_continue;
|
||||
|
@@ -1358,7 +1358,11 @@ fs_visitor::split_virtual_grfs()
|
||||
* the send is reading the whole thing.
|
||||
*/
|
||||
if (inst->is_send_from_grf()) {
|
||||
split_grf[inst->src[0].reg] = false;
|
||||
for (int i = 0; i < 3; i++) {
|
||||
if (inst->src[i].file == GRF) {
|
||||
split_grf[inst->src[i].reg] = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -490,15 +490,15 @@ fs_visitor::emit_fragment_program_code()
|
||||
ir_constant_data junk_data;
|
||||
ir->coordinate = new(mem_ctx) ir_constant(coordinate_type, &junk_data);
|
||||
|
||||
coordinate = rescale_texcoord(ir, coordinate,
|
||||
fpi->TexSrcTarget == TEXTURE_RECT_INDEX,
|
||||
fpi->TexSrcUnit, fpi->TexSrcUnit);
|
||||
|
||||
if (fpi->TexShadow) {
|
||||
shadow_c = regoffset(coordinate, 2);
|
||||
ir->shadow_comparitor = new(mem_ctx) ir_constant(0.0f);
|
||||
}
|
||||
|
||||
coordinate = rescale_texcoord(ir, coordinate,
|
||||
fpi->TexSrcTarget == TEXTURE_RECT_INDEX,
|
||||
fpi->TexSrcUnit, fpi->TexSrcUnit);
|
||||
|
||||
fs_inst *inst;
|
||||
if (brw->gen >= 7) {
|
||||
inst = emit_texture_gen7(ir, dst, coordinate, shadow_c, lod, dpdy, sample_index);
|
||||
|
@@ -868,7 +868,13 @@ fs_visitor::emit_texture_gen4(ir_texture *ir, fs_reg dst, fs_reg coordinate,
|
||||
emit(MOV(fs_reg(MRF, base_mrf + mlen + i), coordinate));
|
||||
coordinate.reg_offset++;
|
||||
}
|
||||
/* gen4's SIMD8 sampler always has the slots for u,v,r present. */
|
||||
|
||||
/* gen4's SIMD8 sampler always has the slots for u,v,r present.
|
||||
* the unused slots must be zeroed.
|
||||
*/
|
||||
for (int i = ir->coordinate->type->vector_elements; i < 3; i++) {
|
||||
emit(MOV(fs_reg(MRF, base_mrf + mlen + i), fs_reg(0.0f)));
|
||||
}
|
||||
mlen += 3;
|
||||
|
||||
if (ir->op == ir_tex) {
|
||||
|
@@ -48,6 +48,10 @@ static void upload_drawing_rect(struct brw_context *brw)
|
||||
{
|
||||
struct gl_context *ctx = &brw->ctx;
|
||||
|
||||
/* 3DSTATE_DRAWING_RECTANGLE is non-pipelined. */
|
||||
if (brw->gen == 6)
|
||||
intel_emit_post_sync_nonzero_flush(brw);
|
||||
|
||||
BEGIN_BATCH(4);
|
||||
OUT_BATCH(_3DSTATE_DRAWING_RECTANGLE << 16 | (4 - 2));
|
||||
OUT_BATCH(0); /* xmin, ymin */
|
||||
|
@@ -204,6 +204,18 @@ brw_miptree_layout_2d(struct intel_mipmap_tree *mt)
|
||||
}
|
||||
}
|
||||
|
||||
static void
|
||||
align_cube(struct intel_mipmap_tree *mt)
|
||||
{
|
||||
/* The 965's sampler lays cachelines out according to how accesses
|
||||
* in the texture surfaces run, so they may be "vertical" through
|
||||
* memory. As a result, the docs say in Surface Padding Requirements:
|
||||
* Sampling Engine Surfaces that two extra rows of padding are required.
|
||||
*/
|
||||
if (mt->target == GL_TEXTURE_CUBE_MAP)
|
||||
mt->total_height += 2;
|
||||
}
|
||||
|
||||
static void
|
||||
brw_miptree_layout_texture_array(struct brw_context *brw,
|
||||
struct intel_mipmap_tree *mt)
|
||||
@@ -228,84 +240,45 @@ brw_miptree_layout_texture_array(struct brw_context *brw,
|
||||
}
|
||||
}
|
||||
mt->total_height = qpitch * mt->physical_depth0;
|
||||
|
||||
align_cube(mt);
|
||||
}
|
||||
|
||||
static void
|
||||
brw_miptree_layout_texture_3d(struct brw_context *brw,
|
||||
struct intel_mipmap_tree *mt)
|
||||
{
|
||||
unsigned width = mt->physical_width0;
|
||||
unsigned height = mt->physical_height0;
|
||||
unsigned depth = mt->physical_depth0;
|
||||
unsigned pack_x_pitch, pack_x_nr;
|
||||
unsigned pack_y_pitch;
|
||||
unsigned yscale = mt->compressed ? 4 : 1;
|
||||
|
||||
mt->total_width = 0;
|
||||
mt->total_height = 0;
|
||||
|
||||
if (mt->compressed) {
|
||||
mt->total_width = ALIGN(width, mt->align_w);
|
||||
pack_y_pitch = (height + 3) / 4;
|
||||
} else {
|
||||
mt->total_width = mt->physical_width0;
|
||||
pack_y_pitch = ALIGN(mt->physical_height0, mt->align_h);
|
||||
}
|
||||
|
||||
pack_x_pitch = width;
|
||||
pack_x_nr = 1;
|
||||
|
||||
unsigned ysum = 0;
|
||||
for (unsigned level = mt->first_level; level <= mt->last_level; level++) {
|
||||
int x = 0;
|
||||
int y = 0;
|
||||
unsigned WL = MAX2(mt->physical_width0 >> level, 1);
|
||||
unsigned HL = MAX2(mt->physical_height0 >> level, 1);
|
||||
unsigned DL = MAX2(mt->physical_depth0 >> level, 1);
|
||||
unsigned wL = ALIGN(WL, mt->align_w);
|
||||
unsigned hL = ALIGN(HL, mt->align_h);
|
||||
|
||||
intel_miptree_set_level_info(mt, level,
|
||||
0, mt->total_height,
|
||||
width, height, depth);
|
||||
if (mt->target == GL_TEXTURE_CUBE_MAP)
|
||||
DL = 6;
|
||||
|
||||
for (int q = 0; q < depth; /* empty */) {
|
||||
for (int j = 0; j < pack_x_nr && q < depth; j++, q++) {
|
||||
intel_miptree_set_image_offset(mt, level, q, x, y);
|
||||
x += pack_x_pitch;
|
||||
}
|
||||
if (x > mt->total_width)
|
||||
mt->total_width = x;
|
||||
intel_miptree_set_level_info(mt, level, 0, 0, WL, HL, DL);
|
||||
|
||||
x = 0;
|
||||
y += pack_y_pitch;
|
||||
for (unsigned q = 0; q < DL; q++) {
|
||||
unsigned x = (q % (1 << level)) * wL;
|
||||
unsigned y = ysum + (q >> level) * hL;
|
||||
|
||||
intel_miptree_set_image_offset(mt, level, q, x, y / yscale);
|
||||
mt->total_width = MAX2(mt->total_width, x + wL);
|
||||
mt->total_height = MAX2(mt->total_height, (y + hL) / yscale);
|
||||
}
|
||||
|
||||
mt->total_height += y;
|
||||
width = minify(width, 1);
|
||||
height = minify(height, 1);
|
||||
if (mt->target == GL_TEXTURE_3D)
|
||||
depth = minify(depth, 1);
|
||||
|
||||
if (mt->compressed) {
|
||||
pack_y_pitch = (height + 3) / 4;
|
||||
|
||||
if (pack_x_pitch > ALIGN(width, mt->align_w)) {
|
||||
pack_x_pitch = ALIGN(width, mt->align_w);
|
||||
pack_x_nr <<= 1;
|
||||
}
|
||||
} else {
|
||||
pack_x_nr <<= 1;
|
||||
if (pack_x_pitch > 4) {
|
||||
pack_x_pitch >>= 1;
|
||||
}
|
||||
|
||||
if (pack_y_pitch > 2) {
|
||||
pack_y_pitch >>= 1;
|
||||
pack_y_pitch = ALIGN(pack_y_pitch, mt->align_h);
|
||||
}
|
||||
}
|
||||
ysum += ALIGN(DL, 1 << level) / (1 << level) * hL;
|
||||
}
|
||||
|
||||
/* The 965's sampler lays cachelines out according to how accesses
|
||||
* in the texture surfaces run, so they may be "vertical" through
|
||||
* memory. As a result, the docs say in Surface Padding Requirements:
|
||||
* Sampling Engine Surfaces that two extra rows of padding are required.
|
||||
*/
|
||||
if (mt->target == GL_TEXTURE_CUBE_MAP)
|
||||
mt->total_height += 2;
|
||||
align_cube(mt);
|
||||
}
|
||||
|
||||
void
|
||||
|
@@ -1030,10 +1030,14 @@ vec4_visitor::split_virtual_grfs()
|
||||
vec4_instruction *inst = (vec4_instruction *)node;
|
||||
|
||||
/* If there's a SEND message loading from a GRF on gen7+, it needs to be
|
||||
* contiguous. Assume that the GRF for the SEND is always in src[0].
|
||||
* contiguous.
|
||||
*/
|
||||
if (inst->is_send_from_grf()) {
|
||||
split_grf[inst->src[0].reg] = false;
|
||||
for (int i = 0; i < 3; i++) {
|
||||
if (inst->src[i].file == GRF) {
|
||||
split_grf[inst->src[i].reg] = false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -2403,8 +2403,10 @@ vec4_visitor::visit(ir_texture *ir)
|
||||
emit(MOV(dst_reg(MRF, param_base, ir->coordinate->type, coord_mask),
|
||||
coordinate));
|
||||
}
|
||||
emit(MOV(dst_reg(MRF, param_base, ir->coordinate->type, zero_mask),
|
||||
src_reg(0)));
|
||||
if (zero_mask != 0) {
|
||||
emit(MOV(dst_reg(MRF, param_base, ir->coordinate->type, zero_mask),
|
||||
src_reg(0)));
|
||||
}
|
||||
/* Load the shadow comparitor */
|
||||
if (ir->shadow_comparitor && ir->op != ir_txd) {
|
||||
emit(MOV(dst_reg(MRF, param_base + 1, ir->shadow_comparitor->type,
|
||||
|
@@ -204,7 +204,7 @@ brw_vs_prog_data_compare(const void *in_a, const void *in_b,
|
||||
|
||||
/* Compare the rest of the struct. */
|
||||
const unsigned offset = sizeof(struct brw_vec4_prog_data);
|
||||
if (memcmp(((char *) &a) + offset, ((char *) &b) + offset,
|
||||
if (memcmp(((char *) a) + offset, ((char *) b) + offset,
|
||||
sizeof(struct brw_vs_prog_data) - offset)) {
|
||||
return false;
|
||||
}
|
||||
|
@@ -259,6 +259,7 @@ brw_update_texture_surface(struct gl_context *ctx,
|
||||
uint32_t *surf;
|
||||
uint32_t tile_x, tile_y;
|
||||
|
||||
/* BRW_NEW_UNIFORM_BUFFER */
|
||||
if (tObj->Target == GL_TEXTURE_BUFFER) {
|
||||
brw_update_buffer_texture_surface(ctx, unit, binding_table, surf_index);
|
||||
return;
|
||||
@@ -797,6 +798,7 @@ const struct brw_tracked_state brw_texture_surfaces = {
|
||||
.dirty = {
|
||||
.mesa = _NEW_TEXTURE,
|
||||
.brw = BRW_NEW_BATCH |
|
||||
BRW_NEW_UNIFORM_BUFFER |
|
||||
BRW_NEW_VERTEX_PROGRAM |
|
||||
BRW_NEW_FRAGMENT_PROGRAM,
|
||||
.cache = 0
|
||||
|
@@ -924,6 +924,18 @@ gen6_blorp_emit_depth_disable(struct brw_context *brw,
|
||||
OUT_BATCH(0);
|
||||
OUT_BATCH(0);
|
||||
ADVANCE_BATCH();
|
||||
|
||||
BEGIN_BATCH(3);
|
||||
OUT_BATCH(_3DSTATE_HIER_DEPTH_BUFFER << 16 | (3 - 2));
|
||||
OUT_BATCH(0);
|
||||
OUT_BATCH(0);
|
||||
ADVANCE_BATCH();
|
||||
|
||||
BEGIN_BATCH(3);
|
||||
OUT_BATCH(_3DSTATE_STENCIL_BUFFER << 16 | (3 - 2));
|
||||
OUT_BATCH(0);
|
||||
OUT_BATCH(0);
|
||||
ADVANCE_BATCH();
|
||||
}
|
||||
|
||||
|
||||
@@ -951,6 +963,9 @@ void
|
||||
gen6_blorp_emit_drawing_rectangle(struct brw_context *brw,
|
||||
const brw_blorp_params *params)
|
||||
{
|
||||
if (brw->gen == 6)
|
||||
intel_emit_post_sync_nonzero_flush(brw);
|
||||
|
||||
BEGIN_BATCH(4);
|
||||
OUT_BATCH(_3DSTATE_DRAWING_RECTANGLE << 16 | (4 - 2));
|
||||
OUT_BATCH(0);
|
||||
|
@@ -128,6 +128,9 @@ gen6_emit_3dstate_multisample(struct brw_context *brw,
|
||||
break;
|
||||
}
|
||||
|
||||
/* 3DSTATE_MULTISAMPLE is nonpipelined. */
|
||||
intel_emit_post_sync_nonzero_flush(brw);
|
||||
|
||||
int len = brw->gen >= 7 ? 4 : 3;
|
||||
BEGIN_BATCH(len);
|
||||
OUT_BATCH(_3DSTATE_MULTISAMPLE << 16 | (len - 2));
|
||||
@@ -183,9 +186,6 @@ static void upload_multisample_state(struct brw_context *brw)
|
||||
}
|
||||
}
|
||||
|
||||
/* 3DSTATE_MULTISAMPLE is nonpipelined. */
|
||||
intel_emit_post_sync_nonzero_flush(brw);
|
||||
|
||||
gen6_emit_3dstate_multisample(brw, num_samples);
|
||||
gen6_emit_3dstate_sample_mask(brw, num_samples, coverage,
|
||||
coverage_invert, sample_mask);
|
||||
|
@@ -115,14 +115,14 @@ write_reg(struct brw_context *brw,
|
||||
BEGIN_BATCH(3);
|
||||
OUT_BATCH(MI_STORE_REGISTER_MEM | (3 - 2));
|
||||
OUT_BATCH(reg);
|
||||
OUT_RELOC(query_bo, I915_GEM_DOMAIN_RENDER, I915_GEM_DOMAIN_RENDER,
|
||||
OUT_RELOC(query_bo, I915_GEM_DOMAIN_INSTRUCTION, I915_GEM_DOMAIN_INSTRUCTION,
|
||||
idx * sizeof(uint64_t));
|
||||
ADVANCE_BATCH();
|
||||
|
||||
BEGIN_BATCH(3);
|
||||
OUT_BATCH(MI_STORE_REGISTER_MEM | (3 - 2));
|
||||
OUT_BATCH(reg + sizeof(uint32_t));
|
||||
OUT_RELOC(query_bo, I915_GEM_DOMAIN_RENDER, I915_GEM_DOMAIN_RENDER,
|
||||
OUT_RELOC(query_bo, I915_GEM_DOMAIN_INSTRUCTION, I915_GEM_DOMAIN_INSTRUCTION,
|
||||
sizeof(uint32_t) + idx * sizeof(uint64_t));
|
||||
ADVANCE_BATCH();
|
||||
}
|
||||
|
@@ -153,6 +153,9 @@ brw_begin_transform_feedback(struct gl_context *ctx, GLenum mode,
|
||||
= _mesa_compute_max_transform_feedback_vertices(xfb_obj,
|
||||
linked_xfb_info);
|
||||
|
||||
/* 3DSTATE_GS_SVB_INDEX is non-pipelined. */
|
||||
intel_emit_post_sync_nonzero_flush(brw);
|
||||
|
||||
/* Initialize the SVBI 0 register to zero and set the maximum index. */
|
||||
BEGIN_BATCH(4);
|
||||
OUT_BATCH(_3DSTATE_GS_SVB_INDEX << 16 | (4 - 2));
|
||||
|
@@ -763,6 +763,18 @@ gen7_blorp_emit_depth_disable(struct brw_context *brw,
|
||||
OUT_BATCH(0);
|
||||
OUT_BATCH(0);
|
||||
ADVANCE_BATCH();
|
||||
|
||||
BEGIN_BATCH(3);
|
||||
OUT_BATCH(GEN7_3DSTATE_HIER_DEPTH_BUFFER << 16 | (3 - 2));
|
||||
OUT_BATCH(0);
|
||||
OUT_BATCH(0);
|
||||
ADVANCE_BATCH();
|
||||
|
||||
BEGIN_BATCH(3);
|
||||
OUT_BATCH(GEN7_3DSTATE_STENCIL_BUFFER << 16 | (3 - 2));
|
||||
OUT_BATCH(0);
|
||||
OUT_BATCH(0);
|
||||
ADVANCE_BATCH();
|
||||
}
|
||||
|
||||
|
||||
|
@@ -25,6 +25,7 @@
|
||||
*
|
||||
**************************************************************************/
|
||||
|
||||
#include "main/blend.h"
|
||||
#include "main/glheader.h"
|
||||
#include "main/enums.h"
|
||||
#include "main/image.h"
|
||||
@@ -227,7 +228,7 @@ do_blit_bitmap( struct gl_context *ctx,
|
||||
UNCLAMPED_FLOAT_TO_UBYTE(ubcolor[2], tmpColor[2]);
|
||||
UNCLAMPED_FLOAT_TO_UBYTE(ubcolor[3], tmpColor[3]);
|
||||
|
||||
switch (irb->mt->format) {
|
||||
switch (_mesa_get_render_format(ctx, intel_rb_format(irb))) {
|
||||
case MESA_FORMAT_ARGB8888:
|
||||
case MESA_FORMAT_XRGB8888:
|
||||
color = PACK_COLOR_8888(ubcolor[3], ubcolor[0], ubcolor[1], ubcolor[2]);
|
||||
|
@@ -197,6 +197,14 @@ osmesa_choose_line_function( struct gl_context *ctx )
|
||||
const OSMesaContext osmesa = OSMESA_CONTEXT(ctx);
|
||||
const SWcontext *swrast = SWRAST_CONTEXT(ctx);
|
||||
|
||||
if (ctx->DrawBuffer &&
|
||||
ctx->DrawBuffer->Visual.redBits == 32) {
|
||||
/* the special-case line functions in this file don't work
|
||||
* for float color channels.
|
||||
*/
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if (ctx->RenderMode != GL_RENDER) return NULL;
|
||||
if (ctx->Line.SmoothFlag) return NULL;
|
||||
if (ctx->Texture._EnabledUnits) return NULL;
|
||||
@@ -298,6 +306,14 @@ osmesa_choose_triangle_function( struct gl_context *ctx )
|
||||
const OSMesaContext osmesa = OSMESA_CONTEXT(ctx);
|
||||
const SWcontext *swrast = SWRAST_CONTEXT(ctx);
|
||||
|
||||
if (ctx->DrawBuffer &&
|
||||
ctx->DrawBuffer->Visual.redBits == 32) {
|
||||
/* the special-case triangle functions in this file don't work
|
||||
* for float color channels.
|
||||
*/
|
||||
return (swrast_tri_func) NULL;
|
||||
}
|
||||
|
||||
if (ctx->RenderMode != GL_RENDER) return (swrast_tri_func) NULL;
|
||||
if (ctx->Polygon.SmoothFlag) return (swrast_tri_func) NULL;
|
||||
if (ctx->Polygon.StippleFlag) return (swrast_tri_func) NULL;
|
||||
|
@@ -622,7 +622,7 @@ _mesa_init_constants(struct gl_context *ctx)
|
||||
ctx->Const.MaxSamples = 0;
|
||||
|
||||
/* GL_ARB_sync */
|
||||
ctx->Const.MaxServerWaitTimeout = (GLuint64) ~0;
|
||||
ctx->Const.MaxServerWaitTimeout = 0x1fff7fffffffULL;
|
||||
|
||||
/* GL_ATI_envmap_bumpmap */
|
||||
ctx->Const.SupportedBumpUnits = SUPPORTED_ATI_BUMP_UNITS;
|
||||
|
@@ -609,11 +609,6 @@ control_app_messages(struct gl_context *ctx, GLenum esource, GLenum etype,
|
||||
enum mesa_debug_type type = gl_enum_to_debug_type(etype);
|
||||
enum mesa_debug_severity severity = gl_enum_to_debug_severity(eseverity);
|
||||
|
||||
if (count)
|
||||
assert(severity == MESA_DEBUG_SEVERITY_COUNT
|
||||
&& type != MESA_DEBUG_TYPE_COUNT
|
||||
&& source != MESA_DEBUG_SOURCE_COUNT);
|
||||
|
||||
for (i = 0; i < count; i++)
|
||||
set_message_state(ctx, source, type, ids[i], enabled);
|
||||
|
||||
@@ -629,9 +624,6 @@ _mesa_DebugMessageControlARB(GLenum gl_source, GLenum gl_type,
|
||||
GLsizei count, const GLuint *ids,
|
||||
GLboolean enabled)
|
||||
{
|
||||
enum mesa_debug_source source;
|
||||
enum mesa_debug_type type;
|
||||
enum mesa_debug_severity severity;
|
||||
GET_CURRENT_CONTEXT(ctx);
|
||||
|
||||
if (count < 0) {
|
||||
@@ -651,11 +643,8 @@ _mesa_DebugMessageControlARB(GLenum gl_source, GLenum gl_type,
|
||||
return;
|
||||
}
|
||||
|
||||
source = gl_enum_to_debug_source(gl_source);
|
||||
type = gl_enum_to_debug_type(gl_type);
|
||||
severity = gl_enum_to_debug_severity(gl_severity);
|
||||
|
||||
control_app_messages(ctx, source, type, severity, count, ids, enabled);
|
||||
control_app_messages(ctx, gl_source, gl_type, gl_severity,
|
||||
count, ids, enabled);
|
||||
}
|
||||
|
||||
void GLAPIENTRY
|
||||
|
@@ -262,7 +262,6 @@ static const struct extension extension_table[] = {
|
||||
{ "GL_OES_framebuffer_object", o(dummy_true), ES1, 2005 },
|
||||
{ "GL_OES_get_program_binary", o(dummy_true), ES2, 2008 },
|
||||
{ "GL_OES_mapbuffer", o(dummy_true), ES1 | ES2, 2005 },
|
||||
{ "GL_OES_matrix_get", o(dummy_true), ES1, 2004 },
|
||||
{ "GL_OES_packed_depth_stencil", o(EXT_packed_depth_stencil), ES1 | ES2, 2007 },
|
||||
{ "GL_OES_point_size_array", o(dummy_true), ES1, 2004 },
|
||||
{ "GL_OES_point_sprite", o(ARB_point_sprite), ES1, 2004 },
|
||||
|
@@ -3581,6 +3581,7 @@ invalidate_framebuffer_storage(GLenum target, GLsizei numAttachments,
|
||||
"%s(attachment >= max. color attachments)", name);
|
||||
return;
|
||||
}
|
||||
break;
|
||||
}
|
||||
default:
|
||||
goto invalid_enum;
|
||||
|
@@ -714,6 +714,7 @@ find_custom_value(struct gl_context *ctx, const struct value_desc *d, union valu
|
||||
|
||||
case GL_MAX_VARYING_FLOATS_ARB:
|
||||
case GL_MAX_FRAGMENT_INPUT_COMPONENTS:
|
||||
case GL_MAX_VERTEX_OUTPUT_COMPONENTS:
|
||||
v->value_int = ctx->Const.MaxVarying * 4;
|
||||
break;
|
||||
|
||||
|
@@ -229,11 +229,6 @@ descriptor=[
|
||||
|
||||
|
||||
{ "apis": ["GLES"], "params": [
|
||||
# XXX: OES_matrix_get
|
||||
[ "MODELVIEW_MATRIX_FLOAT_AS_INT_BITS_OES", "" ],
|
||||
[ "PROJECTION_MATRIX_FLOAT_AS_INT_BITS_OES", "" ],
|
||||
[ "TEXTURE_MATRIX_FLOAT_AS_INT_BITS_OES", "" ],
|
||||
|
||||
# OES_point_size_array
|
||||
[ "POINT_SIZE_ARRAY_OES", "ARRAY_FIELD(VertexAttrib[VERT_ATTRIB_POINT_SIZE].Enabled, TYPE_BOOLEAN)" ],
|
||||
[ "POINT_SIZE_ARRAY_TYPE_OES", "ARRAY_FIELD(VertexAttrib[VERT_ATTRIB_POINT_SIZE].Type, TYPE_ENUM)" ],
|
||||
@@ -308,7 +303,7 @@ descriptor=[
|
||||
[ "MAX_VERTEX_UNIFORM_VECTORS", "LOC_CUSTOM, TYPE_INT, 0, extra_ARB_ES2_compatibility_api_es2" ],
|
||||
[ "MAX_FRAGMENT_UNIFORM_VECTORS", "LOC_CUSTOM, TYPE_INT, 0, extra_ARB_ES2_compatibility_api_es2" ],
|
||||
[ "NUM_SHADER_BINARY_FORMATS", "CONST(0), extra_ARB_ES2_compatibility_api_es2" ],
|
||||
[ "SHADER_BINARY_FORMATS", "CONST(0), extra_ARB_ES2_compatibility_api_es2" ],
|
||||
[ "SHADER_BINARY_FORMATS", "LOC_CUSTOM, TYPE_INVALID, 0, extra_ARB_ES2_compatibility_api_es2" ],
|
||||
|
||||
# GL_ARB_get_program_binary / GL_OES_get_program_binary
|
||||
[ "NUM_PROGRAM_BINARY_FORMATS", "CONST(0), NO_EXTRA" ],
|
||||
@@ -330,6 +325,7 @@ descriptor=[
|
||||
[ "MINOR_VERSION", "LOC_CUSTOM, TYPE_INT, 0, extra_gl30_es3" ],
|
||||
|
||||
# GL 3.0 / GLES3
|
||||
[ "MAX_VERTEX_OUTPUT_COMPONENTS", "LOC_CUSTOM, TYPE_INT, 0, extra_gl32_es3" ],
|
||||
[ "MAX_FRAGMENT_INPUT_COMPONENTS", "LOC_CUSTOM, TYPE_INT, 0, extra_gl32_es3" ],
|
||||
|
||||
# GL_ARB_ES3_compatibility
|
||||
|
@@ -115,12 +115,6 @@ typedef void *GLeglImageOES;
|
||||
#define GL_PALETTE8_RGB5_A1_OES 0x8B99
|
||||
#endif
|
||||
|
||||
#ifndef GL_OES_matrix_get
|
||||
#define GL_MODELVIEW_MATRIX_FLOAT_AS_INT_BITS_OES 0x898D
|
||||
#define GL_PROJECTION_MATRIX_FLOAT_AS_INT_BITS_OES 0x898E
|
||||
#define GL_TEXTURE_MATRIX_FLOAT_AS_INT_BITS_OES 0x898F
|
||||
#endif
|
||||
|
||||
#ifndef GL_ES_VERSION_2_0
|
||||
#define GL_SHADER_BINARY_FORMATS 0x8DF8
|
||||
#define GL_NUM_SHADER_BINARY_FORMATS 0x8DF9
|
||||
|
@@ -672,7 +672,7 @@ minify(unsigned value, unsigned levels)
|
||||
*
|
||||
* \sa ROUND_DOWN_TO()
|
||||
*/
|
||||
#define ALIGN(value, alignment) (((value) + alignment - 1) & ~(alignment - 1))
|
||||
#define ALIGN(value, alignment) (((value) + (alignment) - 1) & ~((alignment) - 1))
|
||||
|
||||
|
||||
|
||||
|
@@ -38,6 +38,7 @@
|
||||
#define FLOAT_TO_FIXED(x) ((GLfixed) ((x) * 65536.0))
|
||||
|
||||
#if defined(_MSC_VER)
|
||||
#if _MSC_VER < 1800 /* Not required on VS2013 and above. */
|
||||
/* Oddly, the fpclassify() function doesn't exist in such a form
|
||||
* on MSVC. This is an implementation using slightly different
|
||||
* lower-level Windows functions.
|
||||
@@ -70,6 +71,7 @@ fpclassify(double x)
|
||||
return FP_NAN;
|
||||
}
|
||||
}
|
||||
#endif /* _MSC_VER < 1800 */
|
||||
|
||||
#elif defined(__APPLE__) || defined(__CYGWIN__) || defined(__FreeBSD__) || \
|
||||
defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__) || \
|
||||
|
@@ -201,13 +201,6 @@ _mesa_GenQueries(GLsizei n, GLuint *ids)
|
||||
return;
|
||||
}
|
||||
|
||||
/* No query objects can be active at this time! */
|
||||
if (ctx->Query.CurrentOcclusionObject ||
|
||||
ctx->Query.CurrentTimerObject) {
|
||||
_mesa_error(ctx, GL_INVALID_OPERATION, "glGenQueriesARB");
|
||||
return;
|
||||
}
|
||||
|
||||
first = _mesa_HashFindFreeKeyBlock(ctx->Query.QueryObjects, n);
|
||||
if (first) {
|
||||
GLsizei i;
|
||||
@@ -240,18 +233,20 @@ _mesa_DeleteQueries(GLsizei n, const GLuint *ids)
|
||||
return;
|
||||
}
|
||||
|
||||
/* No query objects can be active at this time! */
|
||||
if (ctx->Query.CurrentOcclusionObject ||
|
||||
ctx->Query.CurrentTimerObject) {
|
||||
_mesa_error(ctx, GL_INVALID_OPERATION, "glDeleteQueriesARB");
|
||||
return;
|
||||
}
|
||||
|
||||
for (i = 0; i < n; i++) {
|
||||
if (ids[i] > 0) {
|
||||
struct gl_query_object *q = _mesa_lookup_query_object(ctx, ids[i]);
|
||||
if (q) {
|
||||
ASSERT(!q->Active); /* should be caught earlier */
|
||||
if (q->Active) {
|
||||
struct gl_query_object **bindpt;
|
||||
bindpt = get_query_binding_point(ctx, q->Target);
|
||||
assert(bindpt); /* Should be non-null for active q. */
|
||||
if (bindpt) {
|
||||
*bindpt = NULL;
|
||||
}
|
||||
q->Active = GL_FALSE;
|
||||
ctx->Driver.EndQuery(ctx, q);
|
||||
}
|
||||
_mesa_HashRemove(ctx->Query.QueryObjects, ids[i]);
|
||||
ctx->Driver.DeleteQuery(ctx, q);
|
||||
}
|
||||
@@ -485,6 +480,7 @@ _mesa_QueryCounter(GLuint id, GLenum target)
|
||||
q->Target = target;
|
||||
q->Result = 0;
|
||||
q->Ready = GL_FALSE;
|
||||
q->EverBound = GL_TRUE;
|
||||
|
||||
if (ctx->Driver.QueryCounter) {
|
||||
ctx->Driver.QueryCounter(ctx, q);
|
||||
|
@@ -409,7 +409,7 @@ _mesa_GetSynciv(GLsync sync, GLenum pname, GLsizei bufSize, GLsizei *length,
|
||||
return;
|
||||
}
|
||||
|
||||
if (size > 0) {
|
||||
if (size > 0 && bufSize > 0) {
|
||||
const GLsizei copy_count = MIN2(size, bufSize);
|
||||
|
||||
memcpy(values, v, sizeof(GLint) * copy_count);
|
||||
|
@@ -239,11 +239,9 @@ _mesa_choose_tex_format(struct gl_context *ctx, GLenum target,
|
||||
* 1D ARRAY textures in S3TC format.
|
||||
*/
|
||||
if (target != GL_TEXTURE_1D && target != GL_TEXTURE_1D_ARRAY) {
|
||||
if (ctx->Extensions.EXT_texture_compression_s3tc ||
|
||||
ctx->Extensions.ANGLE_texture_compression_dxt)
|
||||
if (ctx->Mesa_DXTn)
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_DXT1);
|
||||
if (ctx->Extensions.TDFX_texture_compression_FXT1)
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_FXT1);
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_RGB_FXT1);
|
||||
}
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_RGB888);
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_XRGB8888);
|
||||
@@ -252,11 +250,9 @@ _mesa_choose_tex_format(struct gl_context *ctx, GLenum target,
|
||||
case GL_COMPRESSED_RGBA_ARB:
|
||||
/* We don't use texture compression for 1D and 1D array textures. */
|
||||
if (target != GL_TEXTURE_1D && target != GL_TEXTURE_1D_ARRAY) {
|
||||
if (ctx->Extensions.EXT_texture_compression_s3tc ||
|
||||
ctx->Extensions.ANGLE_texture_compression_dxt)
|
||||
if (ctx->Mesa_DXTn)
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_DXT3); /* Not rgba_dxt1, see spec */
|
||||
if (ctx->Extensions.TDFX_texture_compression_FXT1)
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_FXT1);
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA_FXT1);
|
||||
}
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_RGBA8888);
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_ARGB8888);
|
||||
@@ -553,12 +549,14 @@ _mesa_choose_tex_format(struct gl_context *ctx, GLenum target,
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8);
|
||||
break;
|
||||
case GL_COMPRESSED_SRGB_EXT:
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_SRGB_DXT1);
|
||||
if (ctx->Mesa_DXTn)
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_SRGB_DXT1);
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_SRGB8);
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8);
|
||||
break;
|
||||
case GL_COMPRESSED_SRGB_ALPHA_EXT:
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_SRGBA_DXT3); /* Not srgba_dxt1, see spec */
|
||||
if (ctx->Mesa_DXTn)
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_SRGBA_DXT3); /* Not srgba_dxt1, see spec */
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_SRGBA8);
|
||||
RETURN_IF_SUPPORTED(MESA_FORMAT_SARGB8);
|
||||
break;
|
||||
|
@@ -1105,7 +1105,6 @@ _mesa_get_tex_max_num_levels(GLenum target, GLsizei width, GLsizei height,
|
||||
case GL_TEXTURE_CUBE_MAP_ARRAY:
|
||||
case GL_PROXY_TEXTURE_CUBE_MAP:
|
||||
case GL_PROXY_TEXTURE_CUBE_MAP_ARRAY:
|
||||
ASSERT(width == height);
|
||||
size = width;
|
||||
break;
|
||||
case GL_TEXTURE_2D:
|
||||
@@ -1440,6 +1439,8 @@ _mesa_legal_texture_dimensions(struct gl_context *ctx, GLenum target,
|
||||
case GL_PROXY_TEXTURE_CUBE_MAP_ARB:
|
||||
maxSize = 1 << (ctx->Const.MaxCubeTextureLevels - 1);
|
||||
maxSize >>= level;
|
||||
if (width != height)
|
||||
return GL_FALSE;
|
||||
if (width < 2 * border || width > 2 * border + maxSize)
|
||||
return GL_FALSE;
|
||||
if (height < 2 * border || height > 2 * border + maxSize)
|
||||
@@ -1493,7 +1494,9 @@ _mesa_legal_texture_dimensions(struct gl_context *ctx, GLenum target,
|
||||
return GL_FALSE;
|
||||
if (height < 2 * border || height > 2 * border + maxSize)
|
||||
return GL_FALSE;
|
||||
if (depth < 1 || depth > ctx->Const.MaxArrayTextureLayers)
|
||||
if (depth < 1 || depth > ctx->Const.MaxArrayTextureLayers || depth % 6)
|
||||
return GL_FALSE;
|
||||
if (width != height)
|
||||
return GL_FALSE;
|
||||
if (level >= ctx->Const.MaxCubeTextureLevels)
|
||||
return GL_FALSE;
|
||||
@@ -1984,27 +1987,6 @@ texture_error_check( struct gl_context *ctx,
|
||||
}
|
||||
}
|
||||
|
||||
if ((target == GL_PROXY_TEXTURE_CUBE_MAP_ARB ||
|
||||
_mesa_is_cube_face(target)) && width != height) {
|
||||
_mesa_error(ctx, GL_INVALID_VALUE,
|
||||
"glTexImage2D(cube width != height)");
|
||||
return GL_TRUE;
|
||||
}
|
||||
|
||||
if ((target == GL_PROXY_TEXTURE_CUBE_MAP_ARRAY ||
|
||||
target == GL_TEXTURE_CUBE_MAP_ARRAY) && width != height) {
|
||||
_mesa_error(ctx, GL_INVALID_VALUE,
|
||||
"glTexImage3D(cube array width != height)");
|
||||
return GL_TRUE;
|
||||
}
|
||||
|
||||
if ((target == GL_PROXY_TEXTURE_CUBE_MAP_ARRAY ||
|
||||
target == GL_TEXTURE_CUBE_MAP_ARRAY) && (depth % 6)) {
|
||||
_mesa_error(ctx, GL_INVALID_VALUE,
|
||||
"glTexImage3D(cube array depth not multiple of 6)");
|
||||
return GL_TRUE;
|
||||
}
|
||||
|
||||
/* Check internalFormat */
|
||||
if (_mesa_base_tex_format(ctx, internalFormat) < 0) {
|
||||
_mesa_error(ctx, GL_INVALID_VALUE,
|
||||
@@ -2236,14 +2218,6 @@ compressed_texture_error_check(struct gl_context *ctx, GLint dimensions,
|
||||
goto error;
|
||||
}
|
||||
|
||||
/* For cube map, width must equal height */
|
||||
if ((target == GL_PROXY_TEXTURE_CUBE_MAP_ARB ||
|
||||
_mesa_is_cube_face(target)) && width != height) {
|
||||
reason = "width != height";
|
||||
error = GL_INVALID_VALUE;
|
||||
goto error;
|
||||
}
|
||||
|
||||
/* check image size in bytes */
|
||||
if (expectedSize != imageSize) {
|
||||
/* Per GL_ARB_texture_compression: GL_INVALID_VALUE is generated [...]
|
||||
@@ -2589,13 +2563,6 @@ copytexture_error_check( struct gl_context *ctx, GLuint dimensions,
|
||||
}
|
||||
}
|
||||
|
||||
if ((target == GL_PROXY_TEXTURE_CUBE_MAP_ARB ||
|
||||
_mesa_is_cube_face(target)) && width != height) {
|
||||
_mesa_error(ctx, GL_INVALID_VALUE,
|
||||
"glTexImage2D(cube width != height)");
|
||||
return GL_TRUE;
|
||||
}
|
||||
|
||||
if (_mesa_is_compressed_format(ctx, internalFormat)) {
|
||||
if (!target_can_be_compressed(ctx, target, internalFormat)) {
|
||||
_mesa_error(ctx, GL_INVALID_ENUM,
|
||||
|
@@ -502,7 +502,7 @@ st_validate_attachment(struct gl_context *ctx,
|
||||
if (att->Type != GL_TEXTURE)
|
||||
return GL_TRUE;
|
||||
|
||||
if (!stObj)
|
||||
if (!stObj || !stObj->pt)
|
||||
return GL_FALSE;
|
||||
|
||||
format = stObj->pt->format;
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user