• Home
  • Raw
  • Download

Lines Matching refs:rctx

55 	struct r600_context *rctx = (struct r600_context *)ctx;  in r600_blitter_begin()  local
57 if (rctx->cmd_buf_is_compute) { in r600_blitter_begin()
58 rctx->b.gfx.flush(rctx, PIPE_FLUSH_ASYNC, NULL); in r600_blitter_begin()
59 rctx->cmd_buf_is_compute = false; in r600_blitter_begin()
62 util_blitter_save_vertex_buffer_slot(rctx->blitter, rctx->vertex_buffer_state.vb); in r600_blitter_begin()
63 util_blitter_save_vertex_elements(rctx->blitter, rctx->vertex_fetch_shader.cso); in r600_blitter_begin()
64 util_blitter_save_vertex_shader(rctx->blitter, rctx->vs_shader); in r600_blitter_begin()
65 util_blitter_save_geometry_shader(rctx->blitter, rctx->gs_shader); in r600_blitter_begin()
66 util_blitter_save_tessctrl_shader(rctx->blitter, rctx->tcs_shader); in r600_blitter_begin()
67 util_blitter_save_tesseval_shader(rctx->blitter, rctx->tes_shader); in r600_blitter_begin()
68 util_blitter_save_so_targets(rctx->blitter, rctx->b.streamout.num_targets, in r600_blitter_begin()
69 (struct pipe_stream_output_target**)rctx->b.streamout.targets); in r600_blitter_begin()
70 util_blitter_save_rasterizer(rctx->blitter, rctx->rasterizer_state.cso); in r600_blitter_begin()
73 util_blitter_save_viewport(rctx->blitter, &rctx->b.viewports.states[0]); in r600_blitter_begin()
74 util_blitter_save_scissor(rctx->blitter, &rctx->b.scissors.states[0]); in r600_blitter_begin()
75 util_blitter_save_fragment_shader(rctx->blitter, rctx->ps_shader); in r600_blitter_begin()
76 util_blitter_save_blend(rctx->blitter, rctx->blend_state.cso); in r600_blitter_begin()
77 util_blitter_save_depth_stencil_alpha(rctx->blitter, rctx->dsa_state.cso); in r600_blitter_begin()
78 util_blitter_save_stencil_ref(rctx->blitter, &rctx->stencil_ref.pipe_state); in r600_blitter_begin()
79 util_blitter_save_sample_mask(rctx->blitter, rctx->sample_mask.sample_mask); in r600_blitter_begin()
83 util_blitter_save_framebuffer(rctx->blitter, &rctx->framebuffer.state); in r600_blitter_begin()
87 rctx->blitter, util_last_bit(rctx->samplers[PIPE_SHADER_FRAGMENT].states.enabled_mask), in r600_blitter_begin()
88 (void**)rctx->samplers[PIPE_SHADER_FRAGMENT].states.states); in r600_blitter_begin()
91 rctx->blitter, util_last_bit(rctx->samplers[PIPE_SHADER_FRAGMENT].views.enabled_mask), in r600_blitter_begin()
92 (struct pipe_sampler_view**)rctx->samplers[PIPE_SHADER_FRAGMENT].views.views); in r600_blitter_begin()
96 rctx->b.render_cond_force_off = true; in r600_blitter_begin()
101 struct r600_context *rctx = (struct r600_context *)ctx; in r600_blitter_end() local
103 rctx->b.render_cond_force_off = false; in r600_blitter_end()
118 struct r600_context *rctx = (struct r600_context *)ctx; in r600_blit_decompress_depth() local
134 if (rctx->b.chip_class == R600 && max_sample > 0) { in r600_blit_decompress_depth()
139 if (rctx->b.family == CHIP_RV610 || rctx->b.family == CHIP_RV630 || in r600_blit_decompress_depth()
140 rctx->b.family == CHIP_RV620 || rctx->b.family == CHIP_RV635) in r600_blit_decompress_depth()
146 rctx->db_misc_state.flush_depthstencil_through_cb = true; in r600_blit_decompress_depth()
147 rctx->db_misc_state.copy_depth = util_format_has_depth(desc); in r600_blit_decompress_depth()
148 rctx->db_misc_state.copy_stencil = util_format_has_stencil(desc); in r600_blit_decompress_depth()
149 rctx->db_misc_state.copy_sample = first_sample; in r600_blit_decompress_depth()
150 r600_mark_atom_dirty(rctx, &rctx->db_misc_state.atom); in r600_blit_decompress_depth()
165 if (sample != rctx->db_misc_state.copy_sample) { in r600_blit_decompress_depth()
166 rctx->db_misc_state.copy_sample = sample; in r600_blit_decompress_depth()
167 r600_mark_atom_dirty(rctx, &rctx->db_misc_state.atom); in r600_blit_decompress_depth()
182 util_blitter_custom_depth_stencil(rctx->blitter, zsurf, cbsurf, 1 << sample, in r600_blit_decompress_depth()
183 rctx->custom_dsa_flush, depth); in r600_blit_decompress_depth()
201 rctx->db_misc_state.flush_depthstencil_through_cb = false; in r600_blit_decompress_depth()
202 r600_mark_atom_dirty(rctx, &rctx->db_misc_state.atom); in r600_blit_decompress_depth()
205 static void r600_blit_decompress_depth_in_place(struct r600_context *rctx, in r600_blit_decompress_depth_in_place() argument
217 rctx->db_misc_state.flush_stencil_inplace = true; in r600_blit_decompress_depth_in_place()
220 rctx->db_misc_state.flush_depth_inplace = true; in r600_blit_decompress_depth_in_place()
223 r600_mark_atom_dirty(rctx, &rctx->db_misc_state.atom); in r600_blit_decompress_depth_in_place()
242 zsurf = rctx->b.b.create_surface(&rctx->b.b, &texture->resource.b.b, &surf_tmpl); in r600_blit_decompress_depth_in_place()
244 r600_blitter_begin(&rctx->b.b, R600_DECOMPRESS); in r600_blit_decompress_depth_in_place()
245 util_blitter_custom_depth_stencil(rctx->blitter, zsurf, NULL, ~0, in r600_blit_decompress_depth_in_place()
246 rctx->custom_dsa_flush, 1.0f); in r600_blit_decompress_depth_in_place()
247 r600_blitter_end(&rctx->b.b); in r600_blit_decompress_depth_in_place()
260 rctx->db_misc_state.flush_depth_inplace = false; in r600_blit_decompress_depth_in_place()
261 rctx->db_misc_state.flush_stencil_inplace = false; in r600_blit_decompress_depth_in_place()
262 r600_mark_atom_dirty(rctx, &rctx->db_misc_state.atom); in r600_blit_decompress_depth_in_place()
265 void r600_decompress_depth_textures(struct r600_context *rctx, in r600_decompress_depth_textures() argument
286 r600_blit_decompress_depth_in_place(rctx, tex, in r600_decompress_depth_textures()
291 r600_blit_decompress_depth(&rctx->b.b, tex, NULL, in r600_decompress_depth_textures()
299 void r600_decompress_depth_images(struct r600_context *rctx, in r600_decompress_depth_images() argument
318 r600_blit_decompress_depth_in_place(rctx, tex, in r600_decompress_depth_images()
324 r600_blit_decompress_depth(&rctx->b.b, tex, NULL, in r600_decompress_depth_images()
338 struct r600_context *rctx = (struct r600_context *)ctx; in r600_blit_decompress_color() local
363 util_blitter_custom_color(rctx->blitter, cbsurf, in r600_blit_decompress_color()
364 rtex->fmask.size ? rctx->custom_blend_decompress : rctx->custom_blend_fastclear); in r600_blit_decompress_color()
378 void r600_decompress_color_textures(struct r600_context *rctx, in r600_decompress_color_textures() argument
396 r600_blit_decompress_color(&rctx->b.b, tex, in r600_decompress_color_textures()
402 void r600_decompress_color_images(struct r600_context *rctx, in r600_decompress_color_images() argument
420 r600_blit_decompress_color(&rctx->b.b, tex, in r600_decompress_color_images()
436 struct r600_context *rctx = (struct r600_context *)ctx; in r600_decompress_subresource() local
441 r600_blit_decompress_depth_in_place(rctx, rtex, false, in r600_decompress_subresource()
445 r600_blit_decompress_depth_in_place(rctx, rtex, true, in r600_decompress_subresource()
470 struct r600_context *rctx = (struct r600_context *)ctx; in r600_clear() local
471 struct pipe_framebuffer_state *fb = &rctx->framebuffer.state; in r600_clear()
473 if (buffers & PIPE_CLEAR_COLOR && rctx->b.chip_class >= EVERGREEN) { in r600_clear()
474 evergreen_do_fast_color_clear(&rctx->b, fb, &rctx->framebuffer.atom, in r600_clear()
516 r600_mark_atom_dirty(rctx, &rctx->db_state.atom); in r600_clear()
518 rctx->db_misc_state.htile_clear = true; in r600_clear()
519 r600_mark_atom_dirty(rctx, &rctx->db_misc_state.atom); in r600_clear()
524 util_blitter_clear(rctx->blitter, fb->width, fb->height, in r600_clear()
531 if (rctx->db_misc_state.htile_clear) { in r600_clear()
532 rctx->db_misc_state.htile_clear = false; in r600_clear()
533 r600_mark_atom_dirty(rctx, &rctx->db_misc_state.atom); in r600_clear()
544 struct r600_context *rctx = (struct r600_context *)ctx; in r600_clear_render_target() local
548 util_blitter_clear_render_target(rctx->blitter, dst, color, in r600_clear_render_target()
562 struct r600_context *rctx = (struct r600_context *)ctx; in r600_clear_depth_stencil() local
566 util_blitter_clear_depth_stencil(rctx->blitter, dst, clear_flags, depth, stencil, in r600_clear_depth_stencil()
574 struct r600_context *rctx = (struct r600_context*)ctx; in r600_copy_buffer() local
576 if (rctx->screen->b.has_cp_dma) { in r600_copy_buffer()
577 r600_cp_dma_copy_buffer(rctx, dst, dstx, src, src_box->x, src_box->width); in r600_copy_buffer()
579 else if (rctx->screen->b.has_streamout && in r600_copy_buffer()
584 util_blitter_copy_buffer(rctx->blitter, dst, dstx, src, src_box->x, src_box->width); in r600_copy_buffer()
602 struct r600_context *rctx = (struct r600_context*)ctx; in r600_copy_global_buffer() local
603 struct compute_memory_pool *pool = rctx->screen->global_pool; in r600_copy_global_buffer()
648 struct r600_context *rctx = (struct r600_context*)ctx; in r600_clear_buffer() local
650 if (rctx->screen->b.has_cp_dma && in r600_clear_buffer()
651 rctx->b.chip_class >= EVERGREEN && in r600_clear_buffer()
653 evergreen_cp_dma_clear_buffer(rctx, dst, offset, size, value, coher); in r600_clear_buffer()
654 } else if (rctx->screen->b.has_streamout && offset % 4 == 0 && size % 4 == 0) { in r600_clear_buffer()
659 util_blitter_clear_buffer(rctx->blitter, dst, offset, size, in r600_clear_buffer()
663 uint32_t *map = r600_buffer_map_sync_with_rings(&rctx->b, r600_resource(dst), in r600_clear_buffer()
680 struct r600_context *rctx = (struct r600_context *)ctx; in r600_resource_copy_region() local
715 util_blitter_default_src_texture(rctx->blitter, &src_templ, src, src_level); in r600_resource_copy_region()
746 } else if (!util_blitter_is_copy_supported(rctx->blitter, dst, src)) { in r600_resource_copy_region()
799 if (rctx->b.chip_class >= EVERGREEN) { in r600_resource_copy_region()
813 util_blitter_blit_generic(rctx->blitter, dst_view, &dstbox, in r600_resource_copy_region()
826 struct r600_context *rctx = (struct r600_context*)ctx; in do_hardware_msaa_resolve() local
832 rctx->b.chip_class == CAYMAN ? ~0 : in do_hardware_msaa_resolve()
867 util_blitter_custom_resolve_color(rctx->blitter, in do_hardware_msaa_resolve()
871 sample_mask, rctx->custom_blend_resolve, in do_hardware_msaa_resolve()
897 util_blitter_custom_resolve_color(rctx->blitter, tmp, 0, 0, in do_hardware_msaa_resolve()
899 sample_mask, rctx->custom_blend_resolve, in do_hardware_msaa_resolve()
910 util_blitter_blit(rctx->blitter, &blit); in do_hardware_msaa_resolve()
920 struct r600_context *rctx = (struct r600_context*)ctx; in r600_blit() local
935 rctx->b.dma_copy && in r600_blit()
937 rctx->b.dma_copy(ctx, info->dst.resource, info->dst.level, in r600_blit()
945 assert(util_blitter_is_blit_supported(rctx->blitter, info)); in r600_blit()
955 if (rctx->screen->b.debug_flags & DBG_FORCE_DMA && in r600_blit()
961 util_blitter_blit(rctx->blitter, info); in r600_blit()
978 void r600_init_blit_functions(struct r600_context *rctx) in r600_init_blit_functions() argument
980 rctx->b.b.clear = r600_clear; in r600_init_blit_functions()
981 rctx->b.b.clear_render_target = r600_clear_render_target; in r600_init_blit_functions()
982 rctx->b.b.clear_depth_stencil = r600_clear_depth_stencil; in r600_init_blit_functions()
983 rctx->b.b.resource_copy_region = r600_resource_copy_region; in r600_init_blit_functions()
984 rctx->b.b.blit = r600_blit; in r600_init_blit_functions()
985 rctx->b.b.flush_resource = r600_flush_resource; in r600_init_blit_functions()
986 rctx->b.clear_buffer = r600_clear_buffer; in r600_init_blit_functions()
987 rctx->b.blit_decompress_depth = r600_blit_decompress_depth; in r600_init_blit_functions()