Merge commit 'origin/gallium-master-merge'

This is the big merge of the gallium-0.2 branch into master.
gallium-master-merge was just the staging area for it.
Both gallium-0.2 and gallium-master-merge are considered closed now.

Conflicts:

	progs/demos/Makefile
	src/mesa/main/state.c
	src/mesa/main/texenvprogram.c
This commit is contained in:
Brian Paul
2009-02-10 16:44:02 -07:00
1571 changed files with 304565 additions and 19740 deletions

View File

@@ -1161,19 +1161,30 @@ _mesa_init_teximage_fields(GLcontext *ctx, GLenum target,
img->Width = width;
img->Height = height;
img->Depth = depth;
img->Width2 = width - 2 * border; /* == 1 << img->WidthLog2; */
img->Height2 = height - 2 * border; /* == 1 << img->HeightLog2; */
img->Depth2 = depth - 2 * border; /* == 1 << img->DepthLog2; */
img->WidthLog2 = logbase2(img->Width2);
if (height == 1) /* 1-D texture */
if (height == 1) { /* 1-D texture */
img->Height2 = 1;
img->HeightLog2 = 0;
else
}
else {
img->Height2 = height - 2 * border; /* == 1 << img->HeightLog2; */
img->HeightLog2 = logbase2(img->Height2);
if (depth == 1) /* 2-D texture */
}
if (depth == 1) { /* 2-D texture */
img->Depth2 = 1;
img->DepthLog2 = 0;
else
}
else {
img->Depth2 = depth - 2 * border; /* == 1 << img->DepthLog2; */
img->DepthLog2 = logbase2(img->Depth2);
}
img->MaxLog2 = MAX2(img->WidthLog2, img->HeightLog2);
img->IsCompressed = GL_FALSE;
img->CompressedSize = 0;