Commit Graph

46057 Commits

Author SHA1 Message Date
José Fonseca a68ba5e0f0 libgl-gdi: Fix mingw-w64 build.
Mingw-w64 actually seems to be closer to MSVC in terms of .DEF parsing.
2011-08-30 09:42:01 +01:00
José Fonseca ec759b3755 st/wgl: Fix build on mingw-w64
Which already declares wglSwapMultipleBuffers and WGLSWAP.
2011-08-30 09:42:01 +01:00
José Fonseca d290febdc8 gdi: Remove mesa_wgl.h
All commonly used windows toolchains define wgl entrypoints in the windows
headers, and mesa_wgl.h not only is unnecessary but actually often stands
in the waydue to slight inconsistencies.

So remove it.
2011-08-30 09:42:01 +01:00
José Fonseca 191428ccb8 scons: Prefer x86_64-w64-mingw32- prefix.
This allows to use mingw-w64 binaries on debian systems which already
include a (typically incomplete) 64 cross compiler.
2011-08-30 09:42:01 +01:00
Maarten Lankhorst f5cf4ec90d xorg/xvmc: Only set decode buffer when available
The nouveau xvmc decoder doesn't need it.

Signed-off-by: Maarten Lankhorst <m.b.lankhorst@gmail.com>
2011-08-29 19:39:22 -04:00
Marek Olšák b2064ff311 glsl_to_tgsi: fix a reference leak on an error path 2011-08-29 22:31:10 +02:00
Kenneth Graunke dc7f449d1a i965: Avoid generating MOVs for most ir_assignment handling.
This is a port of vec4_visitor::try_rewrite_rhs_to_dst to fs_visitor.

Not only is this technique less invasive and more robust, it also
generates better code.  Over and above the previous technique, this
reduced instruction count in shader-db by 0.28% on average and 1.4% in
the best case.

In no case did this technique result in more code than the prior method.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Signed-off-by: Eric Anholt <eric@anholt.net>
2011-08-29 11:39:41 -07:00
Kenneth Graunke d28a3bd4bf i965/fs: Revert "Avoid generating MOVs for assignments for expressions."
This reverts commit 53c89c67f3, along with
the subsequent this->result = reg_undef additions it required.

Both Eric and I agree that the way he did this is really fragile; if you
forget to add this->result = reg_undef before calling accept(), it may
end up using the same register for two separate things, breaking things
in strange and mysterious ways.

The next commit will port over the new VS backend's method for solving
this problem, which is simpler, less intrusive, and still manages to
avoid MOVs in the common case.
2011-08-29 11:39:41 -07:00
Ian Romanick 55d232a815 mesa: Remove all mention of MESA_FORMAT_CI8
Nothing in Mesa supports color-index textures, and most of the other
infrastructure that could allow such support has already been removed.
This puts the final nail in the coffin.

Also clean out some GL_COLOR_INDEX comments in formats.c.

Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2011-08-29 11:07:49 -07:00
Ian Romanick 0c1b716654 dri: Remove MESA_FORMAT_CI8 bits from drivers that don't do paletted textures
This came from the "kill it with fire" discussion at XDS 2010.

Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2011-08-29 11:07:49 -07:00
Brian Paul 6f1846e392 scons: add swrast/s_texture.c to the build 2011-08-29 11:37:13 -06:00
Eric Anholt 336f87d5d5 intel: Rely on Mesa core for the non-blit glTexSubImage* implementation.
It uses MapTextureImage() now, so we don't need our own mapping.

Reviewed-by: Brian Paul <brianp@vmware.com>
2011-08-29 10:14:19 -07:00
Brian Paul b8950c2225 mesa: Convert texture debug dump function to using MapTextureImage().
Reviewed-by: Brian Paul <brianp@vmware.com>
2011-08-29 10:14:19 -07:00
Eric Anholt bad53f3ba5 intel: Remove our custom _mesa_store_compressed_texsubimage2d().
Now that Mesa core knows how to map teximages, we no longer needed the
compressed paths here.

Reviewed-by: Brian Paul <brianp@vmware.com>
2011-08-29 10:14:19 -07:00
Brian Paul 81430ab54f mesa: Convert texstore.c to accessing textures using MapTextureImage.
This continues to allocate texImage->Data as before, so
drivers calling these functions need to use that when present.

Reviewed-by: Brian Paul <brianp@vmware.com>
2011-08-29 10:14:19 -07:00
Eric Anholt 5b257442a8 nouveau: Add MapTextureImage() implementation.
This is untested, but should be close to working since it's basically
a copy of nouveau_teximage_map().

Reviewed-by: Brian Paul <brianp@vmware.com>
2011-08-29 10:10:03 -07:00
Eric Anholt 587fdf07da radeon: Add MapTextureImage() implementation.
Reviewed-by: Brian Paul <brianp@vmware.com>
2011-08-29 10:10:03 -07:00
Eric Anholt ff68e3d304 radeon: Refactor the common texture hook setup to common code.
Reviewed-by: Brian Paul <brianp@vmware.com>
2011-08-29 10:10:03 -07:00
Brian Paul e10337da21 swrast: Add implementation of MapTextureImage/UnmapTextureImage.
Reviewed-by: Brian Paul <brianp@vmware.com>
2011-08-29 10:10:03 -07:00
Eric Anholt bfc09e92ff intel: Add implementation of MapTextureImage/UnmapTextureImage.
Reviewed-by: Brian Paul <brianp@vmware.com>
2011-08-29 10:10:03 -07:00
Brian Paul 0abb2659dd st/mesa: Add implementation of MapTextureImage.
Reviewed-by: Brian Paul <brianp@vmware.com>
2011-08-29 10:10:03 -07:00
Brian Paul 570016cef2 mesa: Add driver hooks for texture image mapping/unmapping.
ctx->Driver.MapTextureImage() / UnmapTextureImage() will be called by
the glTex[Sub]Image(), glGetTexImage() functions, etc. when we're
accessing texture data, and also for software rendering when accessing
texture data.

Reviewed-by: Brian Paul <brianp@vmware.com>
2011-08-29 10:10:03 -07:00
Eric Anholt 68f8cf7263 mesa: Don't check for image->Data when freeing an image's contents.
All driver implementations of FreeTextureImageBuffer already check
that Data != NULL and free it.  However, this means that we will also
free driver storage if the driver storage wasn't in the form of a Data
pointer.

This was produced by the following semantic patch:

@@
expression C;
expression T;
@@
- if (T->Data) {
- C->Driver.FreeTextureImageBuffer(C, T);
+ C->Driver.FreeTextureImageBuffer(C, T);
- }

Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2011-08-29 10:10:03 -07:00
Eric Anholt 5401590815 Rename some driver FreeTextureImageData functions to FreeTextureImageBuffer.
Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2011-08-29 10:10:03 -07:00
Eric Anholt 0bb29949ba mesa: Rename FreeTexImageData to FreeTextureImageBuffer.
This was produced by sed, except for one hunk in driverfuncs.c where
trailing whitespace was dropped.

Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2011-08-29 10:09:41 -07:00
Brian Paul beca3316fb i915g: remove unused var in i915_flush_heuristically() 2011-08-29 08:11:50 -06:00
Kai Wasserbäch d4e8f38477 winsys/g3dvl: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:03:06 -06:00
Kai Wasserbäch 066875f340 tests/unit: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:03:04 -06:00
Kai Wasserbäch a546acdaf4 targets/xorg-vmwgfx: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:03:03 -06:00
Kai Wasserbäch 7ea550621e st/xorg: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:03:01 -06:00
Kai Wasserbäch 28f8ff6b62 vdpau: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:02:55 -06:00
Kai Wasserbäch 8bc7ccede1 va: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:02:55 -06:00
Kai Wasserbäch 92bc1111f3 d3d1x: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:02:55 -06:00
Kai Wasserbäch 51ecb33c6b include/pipe: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:02:55 -06:00
Kai Wasserbäch 8fb7f1a8a4 r600g: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:02:55 -06:00
Kai Wasserbäch 625593fde2 noop: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:02:54 -06:00
Kai Wasserbäch 19bcd21ed1 vl: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:02:54 -06:00
Kai Wasserbäch 137ba91aad util: Fix include style
As explained in the thread starting at [0], the internal include style
should be »#include "path/to/header.h"« for non-system includes.

[0]
<http://news.gmane.org/find-root.php?message_id=%3c4E5802BE.6020206%40vmware.com%3e>

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:02:49 -06:00
Kai Wasserbäch e106d4c731 docs: Fix minor typos.
dbec3a5d introduced minor typos, this should fix them.

Signed-off-by: Kai Wasserbäch <kai@dev.carbon-project.org>
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-08-29 08:02:46 -06:00
Christian König d4bbdbd038 g3dvl: Fix a bug not decoding the last 32-64 bits of an mpeg2 bitstream.
Another bug found by Andy Furniss.
2011-08-29 10:36:06 +02:00
Christian König ddd25cfbb0 st/vdpau: Respect source_rect in VideoMixerRender
Fixing a bug reported by Andy Furniss.
2011-08-29 10:16:56 +02:00
Benjamin Franzke efb4872a9d egl: Use gbm/wayland flags regardless of egl_dri2
Since they are needed for display autodetection.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=40443
2011-08-29 09:34:20 +02:00
Maarten Lankhorst 110f846c25 xvmc tests: Clean up test_rendering slightly
Signed-off-by: Maarten Lankhorst <m.b.lankhorst@gmail.com>
2011-08-28 12:12:59 -04:00
Chia-I Wu 099faeef33 android: add support for egl_dri2
Add rules to build egl_dri2 and make it a built-in EGL driver of
libGLES_mesa.

Reviewed-by: Chad Versace <chad@chad-versace.us>
2011-08-28 21:56:23 +08:00
Chia-I Wu 9779f6f5c1 egl_dri2: add support for Android
Add platform_android.c that supports _EGL_PLAFORM_ANDROID.  It works
with drm_gralloc, where back buffers of windows are backed by GEM
objects.

In Android a native window has a queue of back buffers allocated by the
server, through drm_gralloc.  For each frame, EGL needs to

  dequeue the next back buffer
  render to the buffer
  enqueue the buffer

After enqueuing, the buffer is no longer valid to EGL.  A window has no
depth buffer or other aux buffers.  They need to be allocated locally by
EGL.

Reviewed-by: Benjamin Franzke <benjaminfranzke@googlemail.com>
Reviewed-by: Chad Versace <chad@chad-versace.us>

[olv: with assorted minor changes, mostly suggested during the review]
2011-08-28 21:56:23 +08:00
Chia-I Wu 58911b86a1 egl_dri2: allow RGBA masks to be specified for matching
Add rgba_masks to dri2_add_config.  When it is non-NULL, the DRI config
is accepted only when the offsets and sizes of the its channels match
rgba_mask.

Reviewed-by: Chad Versace <chad@chad-versace.us>
2011-08-28 21:56:22 +08:00
Marek Olšák c8fed01c73 glsl_to_tgsi: remove unused code 2011-08-27 19:26:14 -05:00
Chia-I Wu 09b5f1fd61 android: make DRM optional
For BOARD_GPU_DRIVERS=swrast build, DRM is not needed.
2011-08-27 18:02:11 +08:00
Chia-I Wu 534df79187 android: add support for nouveau
Compile tested only.
2011-08-27 17:29:13 +08:00
Chia-I Wu c696d65793 android: add support for r300g
Compile tested only.
2011-08-27 17:29:12 +08:00