struct gl_texture_object *texobj = image->TexObject;
struct intel_texture_object *intel_texobj = intel_texture_object(texobj);
- _mesa_init_teximage_fields(&intel->ctx, target, image,
+ _mesa_init_teximage_fields(&intel->ctx, image,
region->width, region->height, 1,
0, internalFormat, format);
s->format = get_texbuffer_format(rb, format);
/* Update the image fields. */
- _mesa_init_teximage_fields(ctx, target, ti, s->width, s->height,
+ _mesa_init_teximage_fields(ctx, ti, s->width, s->height,
1, 0, s->cpp, s->format);
nti->base.RowStride = s->pitch / s->cpp;
break;
}
- _mesa_init_teximage_fields(radeon->glCtx, target, texImage,
+ _mesa_init_teximage_fields(radeon->glCtx, texImage,
rb->base.Width, rb->base.Height, 1, 0,
rb->cpp, texFormat);
rImage->base.RowStride = rb->pitch / rb->cpp;
break;
}
- _mesa_init_teximage_fields(radeon->glCtx, target, texImage,
+ _mesa_init_teximage_fields(radeon->glCtx, texImage,
rb->base.Width, rb->base.Height, 1, 0,
rb->cpp, texFormat);
rImage->base.RowStride = rb->pitch / rb->cpp;
else
texFormat = MESA_FORMAT_ARGB8888;
- _mesa_init_teximage_fields(&dri_ctx->Base, target, texImage,
+ _mesa_init_teximage_fields(&dri_ctx->Base, texImage,
w, h, 1, 0, internalFormat, texFormat);
sPriv->swrast_loader->getImage(dPriv, x, y, w, h, (char *)swImage->Data,
/* need to (re)allocate image */
ctx->Driver.FreeTextureImageBuffer(ctx, dstImage);
- _mesa_init_teximage_fields(ctx, target, dstImage,
+ _mesa_init_teximage_fields(ctx, dstImage,
width, height, depth,
border, intFormat, format);
* Initialize basic fields of the gl_texture_image struct.
*
* \param ctx GL context.
- * \param target texture target (GL_TEXTURE_1D, GL_TEXTURE_RECTANGLE, etc).
* \param img texture image structure to be initialized.
* \param width image width.
* \param height image height.
* Note: width, height and depth include the border.
*/
void
-_mesa_init_teximage_fields(struct gl_context *ctx, GLenum target,
+_mesa_init_teximage_fields(struct gl_context *ctx,
struct gl_texture_image *img,
GLsizei width, GLsizei height, GLsizei depth,
GLint border, GLenum internalFormat,
format, type);
if (legal_texture_size(ctx, texFormat, width, height, depth)) {
- _mesa_init_teximage_fields(ctx, target, texImage, width, height,
+ _mesa_init_teximage_fields(ctx, texImage, width, height,
depth, border, internalFormat,
texFormat);
}
type);
if (legal_texture_size(ctx, texFormat, width, height, depth)) {
- _mesa_init_teximage_fields(ctx, target, texImage,
+ _mesa_init_teximage_fields(ctx, texImage,
width, height, depth,
border, internalFormat, texFormat);
/* Free old texture image */
ctx->Driver.FreeTextureImageBuffer(ctx, texImage);
- _mesa_init_teximage_fields(ctx, target, texImage, width, height, 1,
+ _mesa_init_teximage_fields(ctx, texImage, width, height, 1,
border, internalFormat, texFormat);
/* Allocate texture memory (no pixel data yet) */
}
else {
/* no error: store the teximage parameters */
- _mesa_init_teximage_fields(ctx, target, texImage, width, height,
+ _mesa_init_teximage_fields(ctx, texImage, width, height,
depth, border, internalFormat,
MESA_FORMAT_NONE);
}
GL_NONE);
if (legal_texture_size(ctx, texFormat, width, height, depth)) {
- _mesa_init_teximage_fields(ctx, target, texImage,
+ _mesa_init_teximage_fields(ctx, texImage,
width, height, depth,
border, internalFormat, texFormat);
extern void
-_mesa_init_teximage_fields(struct gl_context *ctx, GLenum target,
+_mesa_init_teximage_fields(struct gl_context *ctx,
struct gl_texture_image *img,
GLsizei width, GLsizei height, GLsizei depth,
GLint border, GLenum internalFormat,
GL_UNSIGNED_BYTE);
/* init the image fields */
- _mesa_init_teximage_fields(ctx, GL_TEXTURE_2D, texImage,
+ _mesa_init_teximage_fields(ctx, texImage,
8, 8, 1, 0, GL_RGBA, texFormat);
ASSERT(texImage->TexFormat != MESA_FORMAT_NONE);
return;
}
- _mesa_init_teximage_fields(ctx, target, texImage,
+ _mesa_init_teximage_fields(ctx, texImage,
levelWidth, levelHeight, levelDepth,
0, internalFormat, texFormat);
}
for (face = 0; face < numFaces; face++) {
struct gl_texture_image *texImage = texObj->Image[face][level];
if (texImage) {
- _mesa_init_teximage_fields(ctx, target, texImage,
+ _mesa_init_teximage_fields(ctx, texImage,
0, 0, 0, 0,
GL_NONE, MESA_FORMAT_NONE);
}
return;
}
- _mesa_init_teximage_fields(ctx, target, texImage,
+ _mesa_init_teximage_fields(ctx, texImage,
0, 0, 0, 0, GL_NONE, MESA_FORMAT_NONE);
}
}
texFormat = st_pipe_format_to_mesa_format(ps->format);
- _mesa_init_teximage_fields(ctx, target, texImage,
+ _mesa_init_teximage_fields(ctx, texImage,
ps->width, ps->height, 1, 0, internalFormat,
texFormat);
texFormat = _mesa_choose_texture_format(ctx, texObj, target, level,
internalFormat, format, type);
- _mesa_init_teximage_fields(ctx, target, texImage,
+ _mesa_init_teximage_fields(ctx, texImage,
width, height, depth, border,
internalFormat, texFormat);
texImg = _mesa_get_tex_image(st->ctx, texObj, target, 0);
- _mesa_init_teximage_fields(st->ctx, target, texImg,
+ _mesa_init_teximage_fields(st->ctx, texImg,
16, 16, 1, 0, /* w, h, d, border */
GL_RGBA, MESA_FORMAT_RGBA8888);
ctx->Driver.FreeTextureImageBuffer(ctx, dstImage);
/* initialize new image */
- _mesa_init_teximage_fields(ctx, target, dstImage, dstWidth, dstHeight,
+ _mesa_init_teximage_fields(ctx, dstImage, dstWidth, dstHeight,
dstDepth, border, srcImage->InternalFormat,
srcImage->TexFormat);
texFormat = st_ChooseTextureFormat(ctx, internalFormat,
GL_BGRA, GL_UNSIGNED_BYTE);
- _mesa_init_teximage_fields(ctx, target, texImage,
+ _mesa_init_teximage_fields(ctx, texImage,
tex->width0, tex->height0, 1, 0,
internalFormat, texFormat);