Merge branch 'mesa_7_7_branch' of http://anongit.freedesktop.org/git/mesa/mesa into mesa_7_7_branch
This commit is contained in:
commit
635823d267
|
@ -51,13 +51,7 @@ LIBRARY_INCLUDES = \
|
|||
-I$(TOP)/src/gallium/drivers/svga/include
|
||||
|
||||
LIBRARY_DEFINES = \
|
||||
-std=gnu99 -fvisibility=hidden \
|
||||
-DHAVE_STDINT_H -DHAVE_SYS_TYPES_H
|
||||
|
||||
CC = gcc -fvisibility=hidden -msse -msse2
|
||||
|
||||
# Set the gnu99 standard to enable anonymous structs in vmware headers.
|
||||
#
|
||||
CFLAGS = -Wall -Wmissing-prototypes -std=gnu99 -ffast-math \
|
||||
$(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) $(ASM_FLAGS)
|
||||
|
||||
include ../../Makefile.template
|
||||
|
|
|
@ -151,9 +151,11 @@ render_filter_to_gallium(int xrender_filter, int *out_filter)
|
|||
case PictFilterBest:
|
||||
*out_filter = PIPE_TEX_FILTER_LINEAR;
|
||||
break;
|
||||
case PictFilterConvolution:
|
||||
*out_filter = PIPE_TEX_FILTER_NEAREST;
|
||||
return FALSE;
|
||||
default:
|
||||
debug_printf("Unknown xrender filter\n");
|
||||
case PictFilterConvolution:
|
||||
*out_filter = PIPE_TEX_FILTER_NEAREST;
|
||||
return FALSE;
|
||||
}
|
||||
|
|
|
@ -446,7 +446,7 @@ display_video(ScrnInfoPtr pScrn, struct xorg_xv_port_priv *pPriv, int id,
|
|||
int x, y, w, h;
|
||||
struct exa_pixmap_priv *dst = exaGetPixmapDriverPrivate(pPixmap);
|
||||
|
||||
if (!dst->tex) {
|
||||
if (dst && !dst->tex) {
|
||||
xorg_exa_set_shared_usage(pPixmap);
|
||||
pScrn->pScreen->ModifyPixmapHeader(pPixmap, 0, 0, 0, 0, 0, NULL);
|
||||
}
|
||||
|
|
|
@ -28,20 +28,8 @@ LIBRARY_INCLUDES = \
|
|||
$(shell pkg-config libdrm --cflags-only-I)
|
||||
|
||||
LIBRARY_DEFINES = \
|
||||
-std=gnu99 -fvisibility=hidden \
|
||||
-DHAVE_STDINT_H -D_FILE_OFFSET_BITS=64 \
|
||||
$(shell pkg-config libdrm --cflags-only-other)
|
||||
|
||||
CC = gcc -fvisibility=hidden -msse -msse2
|
||||
|
||||
# Set the gnu99 standard to enable anonymous structs in vmware headers.
|
||||
#
|
||||
CFLAGS = -Wall -Wmissing-prototypes -std=gnu99 -ffast-math \
|
||||
$(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) $(ASM_FLAGS)
|
||||
|
||||
include ../../../../Makefile.template
|
||||
|
||||
|
||||
symlinks:
|
||||
|
||||
|
||||
include depend
|
||||
|
|
|
@ -331,6 +331,7 @@ vmw_ioctl_region_create(struct vmw_winsys_screen *vws, uint32_t size)
|
|||
return region;
|
||||
|
||||
out_err1:
|
||||
FREE(region);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
|
|
@ -39,7 +39,7 @@ vmw_svga_winsys_surface_reference(struct vmw_svga_winsys_surface **pdst,
|
|||
struct pipe_reference *dst_ref;
|
||||
struct vmw_svga_winsys_surface *dst = *pdst;
|
||||
|
||||
if(*pdst == src || pdst == NULL)
|
||||
if(pdst == NULL || *pdst == src)
|
||||
return;
|
||||
|
||||
src_ref = src ? &src->refcnt : NULL;
|
||||
|
|
|
@ -284,7 +284,12 @@ GLUhalfEdge *__gl_meshMakeEdge( GLUmesh *mesh )
|
|||
}
|
||||
|
||||
e = MakeEdge( &mesh->eHead );
|
||||
if (e == NULL) return NULL;
|
||||
if (e == NULL) {
|
||||
memFree(newVertex1);
|
||||
memFree(newVertex2);
|
||||
memFree(newFace);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
MakeVertex( newVertex1, e, &mesh->vHead );
|
||||
MakeVertex( newVertex2, e->Sym, &mesh->vHead );
|
||||
|
|
|
@ -3526,6 +3526,8 @@ gluScaleImage(GLenum format, GLsizei widthin, GLsizei heightin,
|
|||
afterImage =
|
||||
malloc(image_size(widthout, heightout, format, GL_UNSIGNED_SHORT));
|
||||
if (beforeImage == NULL || afterImage == NULL) {
|
||||
free(beforeImage);
|
||||
free(afterImage);
|
||||
return GLU_OUT_OF_MEMORY;
|
||||
}
|
||||
|
||||
|
@ -3760,6 +3762,7 @@ static int bitmapBuild2DMipmaps(GLenum target, GLint internalFormat,
|
|||
glPixelStorei(GL_UNPACK_SKIP_PIXELS,psm.unpack_skip_pixels);
|
||||
glPixelStorei(GL_UNPACK_ROW_LENGTH, psm.unpack_row_length);
|
||||
glPixelStorei(GL_UNPACK_SWAP_BYTES, psm.unpack_swap_bytes);
|
||||
free(newImage);
|
||||
return GLU_OUT_OF_MEMORY;
|
||||
}
|
||||
}
|
||||
|
@ -7382,6 +7385,8 @@ int gluScaleImage3D(GLenum format,
|
|||
afterImage = malloc(imageSize3D(widthOut, heightOut, depthOut, format,
|
||||
GL_UNSIGNED_SHORT));
|
||||
if (beforeImage == NULL || afterImage == NULL) {
|
||||
free(beforeImage);
|
||||
free(afterImage);
|
||||
return GLU_OUT_OF_MEMORY;
|
||||
}
|
||||
retrieveStoreModes3D(&psm);
|
||||
|
|
|
@ -250,12 +250,14 @@ driCreateContext(__GLXscreenConfigs * psc,
|
|||
{
|
||||
__GLXDRIcontextPrivate *pcp, *pcp_shared;
|
||||
__GLXDRIconfigPrivate *config = (__GLXDRIconfigPrivate *) mode;
|
||||
const __DRIcoreExtension *core = psc->core;
|
||||
const __DRIcoreExtension *core;
|
||||
__DRIcontext *shared = NULL;
|
||||
|
||||
if (!psc || !psc->driScreen)
|
||||
return NULL;
|
||||
|
||||
core = psc->core;
|
||||
|
||||
if (shareList) {
|
||||
pcp_shared = (__GLXDRIcontextPrivate *) shareList->driContext;
|
||||
shared = pcp_shared->driContext;
|
||||
|
|
|
@ -191,7 +191,7 @@ struct rc_src_register lmul_swizzle(unsigned int swizzle, struct rc_src_register
|
|||
|
||||
static inline void reset_srcreg(struct rc_src_register* reg)
|
||||
{
|
||||
memset(reg, 0, sizeof(reg));
|
||||
memset(reg, 0, sizeof(struct rc_src_register));
|
||||
reg->Swizzle = RC_SWIZZLE_XYZW;
|
||||
}
|
||||
|
||||
|
|
|
@ -560,23 +560,23 @@ static void sincos_constants(struct radeon_compiler* c, unsigned int *constants)
|
|||
* MAD dest, tmp.y, weight, tmp.x
|
||||
*/
|
||||
static void sin_approx(
|
||||
struct radeon_compiler* c, struct rc_instruction * before,
|
||||
struct radeon_compiler* c, struct rc_instruction * inst,
|
||||
struct rc_dst_register dst, struct rc_src_register src, const unsigned int* constants)
|
||||
{
|
||||
unsigned int tempreg = rc_find_free_temporary(c);
|
||||
|
||||
emit2(c, before, RC_OPCODE_MUL, 0, dstregtmpmask(tempreg, RC_MASK_XY),
|
||||
emit2(c, inst->Prev, RC_OPCODE_MUL, 0, dstregtmpmask(tempreg, RC_MASK_XY),
|
||||
swizzle(src, RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X),
|
||||
srcreg(RC_FILE_CONSTANT, constants[0]));
|
||||
emit3(c, before, RC_OPCODE_MAD, 0, dstregtmpmask(tempreg, RC_MASK_X),
|
||||
emit3(c, inst->Prev, RC_OPCODE_MAD, 0, dstregtmpmask(tempreg, RC_MASK_X),
|
||||
swizzle(srcreg(RC_FILE_TEMPORARY, tempreg), RC_SWIZZLE_Y, RC_SWIZZLE_Y, RC_SWIZZLE_Y, RC_SWIZZLE_Y),
|
||||
absolute(swizzle(src, RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X)),
|
||||
swizzle(srcreg(RC_FILE_TEMPORARY, tempreg), RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X));
|
||||
emit3(c, before, RC_OPCODE_MAD, 0, dstregtmpmask(tempreg, RC_MASK_Y),
|
||||
emit3(c, inst->Prev, RC_OPCODE_MAD, 0, dstregtmpmask(tempreg, RC_MASK_Y),
|
||||
swizzle(srcreg(RC_FILE_TEMPORARY, tempreg), RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X),
|
||||
absolute(swizzle(srcreg(RC_FILE_TEMPORARY, tempreg), RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X)),
|
||||
negate(swizzle(srcreg(RC_FILE_TEMPORARY, tempreg), RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X)));
|
||||
emit3(c, before, RC_OPCODE_MAD, 0, dst,
|
||||
emit3(c, inst->Prev, RC_OPCODE_MAD, 0, dst,
|
||||
swizzle(srcreg(RC_FILE_TEMPORARY, tempreg), RC_SWIZZLE_Y, RC_SWIZZLE_Y, RC_SWIZZLE_Y, RC_SWIZZLE_Y),
|
||||
swizzle(srcreg(RC_FILE_CONSTANT, constants[0]), RC_SWIZZLE_W, RC_SWIZZLE_W, RC_SWIZZLE_W, RC_SWIZZLE_W),
|
||||
swizzle(srcreg(RC_FILE_TEMPORARY, tempreg), RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X, RC_SWIZZLE_X));
|
||||
|
|
|
@ -570,7 +570,7 @@ texfetch_funcs[MESA_FORMAT_COUNT] =
|
|||
static FetchTexelFuncF
|
||||
_mesa_get_texel_fetch_func(gl_format format, GLuint dims)
|
||||
{
|
||||
FetchTexelFuncF f;
|
||||
FetchTexelFuncF f = NULL;
|
||||
GLuint i;
|
||||
/* XXX replace loop with direct table lookup */
|
||||
for (i = 0; i < MESA_FORMAT_COUNT; i++) {
|
||||
|
|
Loading…
Reference in New Issue