Lines Matching defs:ctx

49    struct etna_context *ctx = etna_context(pctx);
50 struct etna_screen *screen = ctx->screen;
56 ctx->num_fragment_samplers = num_samplers;
68 ctx->sampler[offset + idx] = samplers[idx];
70 ctx->active_samplers |= mask;
72 ctx->active_samplers &= ~mask;
75 ctx->dirty |= ETNA_DIRTY_SAMPLERS;
150 struct etna_context *ctx = etna_context(view->context);
163 ctx->dirty |= ETNA_DIRTY_TEXTURE_CACHES;
165 if (ctx->ts_for_sampler_view && etna_can_use_sampler_ts(view, num)) {
173 ctx->dirty |= ETNA_DIRTY_TEXTURE_CACHES;
177 ctx->dirty |= ETNA_DIRTY_TEXTURE_CACHES;
179 if (ctx->ts_for_sampler_view &&
180 etna_configure_sampler_ts(ctx->ts_for_sampler_view(view), view, enable_sampler_ts)) {
181 ctx->dirty |= ETNA_DIRTY_SAMPLER_VIEWS | ETNA_DIRTY_TEXTURE_CACHES;
182 ctx->dirty_sampler_views |= (1 << num);
242 set_sampler_views(struct etna_context *ctx, unsigned start, unsigned end,
247 uint32_t prev_active_sampler_views = ctx->active_sampler_views;
253 pipe_sampler_view_reference(&ctx->sampler_view[i], NULL);
254 ctx->sampler_view[i] = view;
256 pipe_sampler_view_reference(&ctx->sampler_view[i], view);
259 ctx->active_sampler_views |= mask;
260 ctx->dirty_sampler_views |= mask;
262 ctx->active_sampler_views &= ~mask;
266 pipe_sampler_view_reference(&ctx->sampler_view[i], NULL);
267 ctx->active_sampler_views &= ~mask;
271 ctx->dirty_sampler_views |= ctx->active_sampler_views ^ prev_active_sampler_views;
275 etna_fragtex_set_sampler_views(struct etna_context *ctx, unsigned nr,
279 struct etna_screen *screen = ctx->screen;
283 set_sampler_views(ctx, start, end, nr, take_ownership, views);
284 ctx->num_fragment_sampler_views = nr;
289 etna_vertex_set_sampler_views(struct etna_context *ctx, unsigned nr,
293 struct etna_screen *screen = ctx->screen;
297 set_sampler_views(ctx, start, end, nr, take_ownership, views);
307 struct etna_context *ctx = etna_context(pctx);
310 ctx->dirty |= ETNA_DIRTY_SAMPLER_VIEWS | ETNA_DIRTY_TEXTURE_CACHES;
314 etna_fragtex_set_sampler_views(ctx, num_views, take_ownership, views);
317 etna_vertex_set_sampler_views(ctx, num_views, take_ownership, views);
326 struct etna_context *ctx = etna_context(pctx);
329 etna_set_state(ctx->stream, VIVS_GL_FLUSH_CACHE, VIVS_GL_FLUSH_CACHE_COLOR | VIVS_GL_FLUSH_CACHE_TEXTURE);
333 active_samplers_bits(struct etna_context *ctx)
335 return ctx->active_sampler_views & ctx->active_samplers;
341 struct etna_context *ctx = etna_context(pctx);
342 struct etna_screen *screen = ctx->screen;
349 u_suballocator_init(&ctx->tex_desc_allocator, pctx, 4096, 0,
360 struct etna_context *ctx = etna_context(pctx);
361 struct etna_screen *screen = ctx->screen;
364 u_suballocator_destroy(&ctx->tex_desc_allocator);