Lines Matching defs:tex
51 struct pipe_resource *tex[MAX_RESOURCES];
182 struct pipe_resource **tex = &ctx->tex[slot];
204 *tex = ctx->screen->resource_create(ctx->screen, &ttex);
205 assert(*tex);
207 map = pipe->texture_map(pipe, *tex, 0, PIPE_MAP_WRITE,
234 struct pipe_resource *tex = ctx->tex[slot];
235 int dx = util_format_get_blocksize(tex->format);
236 int dy = util_format_get_stride(tex->format, tex->width0);
237 int nx = (tex->target == PIPE_BUFFER ? (tex->width0 / dx) :
238 util_format_get_nblocksx(tex->format, tex->width0));
239 int ny = (tex->target == PIPE_BUFFER ? 1 :
240 util_format_get_nblocksy(tex->format, tex->height0));
249 map = pipe->texture_map(pipe, tex, 0, PIPE_MAP_READ,
250 &(struct pipe_box) { .width = tex->width0,
251 .height = tex->height0,
298 if (ctx->tex[i])
299 pipe_resource_reference(&ctx->tex[i], NULL);
310 u_sampler_view_default_template(&tview, ctx->tex[*slots],
311 ctx->tex[*slots]->format);
313 ctx->view[i] = pipe->create_sampler_view(pipe, ctx->tex[*slots],
343 .format = ctx->tex[*slots]->format,
347 if (ctx->tex[*slots]->target == PIPE_BUFFER)
348 tsurf.u.buf.last_element = ctx->tex[*slots]->width0 - 1;
350 ctx->surf[i] = pipe->create_surface(pipe, ctx->tex[*slots],
413 res[i] = ctx->tex[*slots];