Lines Matching refs:ctx

43 static struct pipe_context *ctx = NULL;
119 ctx->set_constant_buffer(ctx,
127 ctx->set_constant_buffer(ctx,
156 ctx->set_viewport_states( ctx, 0, 1, &vp );
174 handle = ctx->create_vertex_elements_state(ctx, 3, ve);
175 ctx->bind_vertex_elements_state(ctx, handle);
181 vbuf.buffer.resource = pipe_buffer_create_with_data(ctx,
187 ctx->set_vertex_buffers(ctx, 0, 1, 0, false, &vbuf);
206 handle = graw_parse_vertex_shader(ctx, text);
207 ctx->bind_vs_state(ctx, handle);
230 handle = graw_parse_fragment_shader(ctx, buf);
231 ctx->bind_fs_state(ctx, handle);
240 ctx->clear(ctx, PIPE_CLEAR_COLOR, NULL, &clear_color, 0, 0);
241 util_draw_arrays(ctx, PIPE_PRIM_TRIANGLES, 0, 3);
242 ctx->flush(ctx, NULL, 0);
244 graw_save_surface_to_file(ctx, surf, NULL);
246 screen->flush_frontbuffer(screen, ctx, rttex, 0, 0, window, NULL);
319 ctx->texture_subdata(ctx,
334 ptr = pipe_texture_map(ctx, samptex,
344 ctx->texture_unmap(ctx, t);
354 sv = ctx->create_sampler_view(ctx, samptex, &sv_template);
358 ctx->set_sampler_views(ctx, PIPE_SHADER_FRAGMENT, 0, 1, 0, false, &sv);
373 sampler = ctx->create_sampler_state(ctx, &sampler_desc);
377 ctx->bind_sampler_states(ctx, PIPE_SHADER_FRAGMENT, 0, 1, &sampler);
406 ctx = screen->context_create(screen, NULL, 0);
407 if (ctx == NULL)
430 surf = ctx->create_surface(ctx, rttex, &surf_tmpl);
440 ctx->set_framebuffer_state(ctx, &fb);
447 handle = ctx->create_blend_state(ctx, &blend);
448 ctx->bind_blend_state(ctx, handle);
455 handle = ctx->create_depth_stencil_alpha_state(ctx, &depthstencil);
456 ctx->bind_depth_stencil_alpha_state(ctx, handle);
468 handle = ctx->create_rasterizer_state(ctx, &rasterizer);
469 ctx->bind_rasterizer_state(ctx, handle);