Searched refs:svga (Results 1 - 25 of 57) sorted by relevance

123

/external/mesa3d/src/gallium/drivers/svga/
H A Dsvga_context.c56 struct svga_context *svga = svga_context( pipe ); local
59 svga_cleanup_framebuffer( svga );
60 svga_cleanup_tss_binding( svga );
62 svga_hwtnl_destroy( svga->hwtnl );
64 svga_cleanup_vertex_state(svga);
66 svga->swc->destroy(svga->swc);
68 svga_destroy_swtnl( svga );
70 u_upload_destroy( svga->upload_vb );
71 u_upload_destroy( svga
88 struct svga_context *svga = NULL; local
201 svga_context_flush( struct svga_context *svga, struct pipe_fence_handle **pfence ) argument
266 svga_hwtnl_flush_buffer( struct svga_context *svga, struct pipe_resource *buffer ) argument
277 svga_surfaces_flush(struct svga_context *svga) argument
[all...]
H A Dsvga_swtnl_draw.c39 svga_swtnl_draw_vbo(struct svga_context *svga, argument
45 struct draw_context *draw = svga->swtnl.draw;
50 assert(!svga->dirty);
51 assert(svga->state.sw.need_swtnl);
55 svga->state.sw.in_swtnl_draw = TRUE;
57 ret = svga_update_state(svga, SVGA_STATE_SWTNL_DRAW);
59 svga_context_flush(svga, NULL);
60 ret = svga_update_state(svga, SVGA_STATE_SWTNL_DRAW);
61 svga->swtnl.new_vbuf = TRUE;
68 for (i = 0; i < svga
[all...]
H A Dsvga_swtnl.h36 boolean svga_init_swtnl( struct svga_context *svga );
37 void svga_destroy_swtnl( struct svga_context *svga );
41 svga_swtnl_draw_vbo(struct svga_context *svga,
H A Dsvga_pipe_vertex.c42 struct svga_context *svga = svga_context(pipe); local
47 if (count == svga->curr.num_vertex_buffers &&
48 memcmp(svga->curr.vb, buffers, count * sizeof buffers[0]) == 0)
53 pipe_resource_reference(&svga->curr.vb[i].buffer, buffers[i].buffer);
58 for ( ; i < svga->curr.num_vertex_buffers; i++)
59 pipe_resource_reference(&svga->curr.vb[i].buffer, NULL);
62 memcpy(svga->curr.vb, buffers, count * sizeof buffers[0]);
63 svga->curr.num_vertex_buffers = count;
64 svga->curr.any_user_vertex_buffers = any_user_buffer;
66 svga
73 struct svga_context *svga = svga_context(pipe); local
106 struct svga_context *svga = svga_context(pipe); local
[all...]
H A Dsvga_state_rss.c44 #define EMIT_RS(svga, value, token, fail) \
46 assert(SVGA3D_RS_##token < Elements(svga->state.hw_draw.rs)); \
47 if (svga->state.hw_draw.rs[SVGA3D_RS_##token] != value) { \
49 svga->state.hw_draw.rs[SVGA3D_RS_##token] = value; \
53 #define EMIT_RS_FLOAT(svga, fvalue, token, fail) \
56 assert(SVGA3D_RS_##token < Elements(svga->state.hw_draw.rs)); \
57 if (svga->state.hw_draw.rs[SVGA3D_RS_##token] != value) { \
59 svga->state.hw_draw.rs[SVGA3D_RS_##token] = value; \
80 emit_rss(struct svga_context *svga, unsigned dirty) argument
82 struct svga_screen *screen = svga_screen(svga
[all...]
H A Dsvga_state_need_swtnl.c75 update_need_swvfetch( struct svga_context *svga, argument
81 if (!svga->curr.velems) {
86 for (i = 0; i < svga->curr.velems->count; i++) {
87 svga->state.sw.ve_format[i] = svga_translate_vertex_format(svga->curr.velems->velem[i].src_format);
88 if (svga->state.sw.ve_format[i] == SVGA3D_DECLTYPE_MAX) {
95 if (need_swvfetch != svga->state.sw.need_swvfetch) {
96 svga->state.sw.need_swvfetch = need_swvfetch;
97 svga->dirty |= SVGA_NEW_NEED_SWVFETCH;
115 update_need_pipeline( struct svga_context *svga, argument
194 update_need_swtnl( struct svga_context *svga, unsigned dirty ) argument
[all...]
H A Dsvga_pipe_draw.c56 svga_user_buffer_range(struct svga_context *svga, argument
61 const struct pipe_vertex_element *ve = svga->curr.velems->velem;
69 for (i=0; i < svga->curr.velems->count; i++) {
71 &svga->curr.vb[ve[i].vertex_buffer_index];
82 for (i=0; i < svga->curr.velems->count; i++) {
84 &svga->curr.vb[ve[i].vertex_buffer_index];
92 svga->dirty |= SVGA_NEW_VBUFFER;
117 svga_upload_user_buffers(struct svga_context *svga, argument
122 const struct pipe_vertex_element *ve = svga->curr.velems->velem;
126 svga_user_buffer_range(svga, star
184 svga_release_user_upl_buffers(struct svga_context *svga) argument
219 retry_draw_range_elements( struct svga_context *svga, struct pipe_resource *index_buffer, unsigned index_size, int index_bias, unsigned min_index, unsigned max_index, unsigned prim, unsigned start, unsigned count, unsigned instance_count, boolean do_retry ) argument
275 retry_draw_arrays( struct svga_context *svga, unsigned prim, unsigned start, unsigned count, unsigned instance_count, boolean do_retry ) argument
327 struct svga_context *svga = svga_context( pipe ); local
[all...]
H A Dsvga_pipe_flush.c37 struct svga_context *svga = svga_context(pipe); local
41 svga_surfaces_flush( svga );
45 svga_context_flush(svga, fence);
52 struct pipe_framebuffer_state *fb = &svga->curr.framebuffer;
59 debug_dump_surface_bmp(&svga->pipe, filename, fb->cbufs[i]);
64 debug_dump_surface_bmp(&svga->pipe, filename, fb->zsbuf);
72 void svga_init_flush_functions( struct svga_context *svga )
74 svga->pipe.flush = svga_flush;
H A Dsvga_state.h36 void svga_init_state( struct svga_context *svga );
37 void svga_destroy_state( struct svga_context *svga );
43 enum pipe_error (*update)( struct svga_context *svga, unsigned dirty );
85 enum pipe_error svga_update_state( struct svga_context *svga,
88 void svga_update_state_retry( struct svga_context *svga,
92 enum pipe_error svga_emit_initial_state( struct svga_context *svga );
94 enum pipe_error svga_reemit_framebuffer_bindings( struct svga_context *svga );
96 enum pipe_error svga_reemit_tss_bindings( struct svga_context *svga );
H A Dsvga_resource.h39 void svga_init_resource_functions(struct svga_context *svga );
H A Dsvga_pipe_misc.c37 struct svga_context *svga = svga_context(pipe); local
39 memcpy( &svga->curr.scissor, scissor, sizeof(*scissor) );
40 svga->dirty |= SVGA_NEW_SCISSOR;
51 void svga_cleanup_framebuffer(struct svga_context *svga) argument
53 struct pipe_framebuffer_state *curr = &svga->curr.framebuffer;
54 struct pipe_framebuffer_state *hw = &svga->state.hw_clear.framebuffer;
75 struct svga_context *svga = svga_context(pipe); local
76 struct pipe_framebuffer_state *dst = &svga->curr.framebuffer;
93 svga_hwtnl_flush_retry( svga );
97 svga_propagate_surface(svga, ds
152 struct svga_context *svga = svga_context(pipe); local
167 struct svga_context *svga = svga_context(pipe); local
[all...]
H A Dsvga_pipe_vs.c102 struct svga_context *svga = svga_context(pipe); local
109 vs->base.tokens = tgsi_dup_tokens(substitute_vs(svga->debug.shader_id,
123 vs->draw_shader = draw_create_vertex_shader(svga->swtnl.draw, &tmp2);
126 vs->base.id = svga->debug.shader_id++;
140 struct svga_context *svga = svga_context(pipe); local
142 svga->curr.vs = vs;
143 svga->dirty |= SVGA_NEW_VS;
149 struct svga_context *svga = svga_context(pipe); local
154 svga_hwtnl_flush_retry( svga );
156 draw_delete_vertex_shader(svga
[all...]
H A Dsvga_resource.c59 svga_init_resource_functions(struct svga_context *svga) argument
61 svga->pipe.get_transfer = u_get_transfer_vtbl;
62 svga->pipe.transfer_map = u_transfer_map_vtbl;
63 svga->pipe.transfer_flush_region = u_transfer_flush_region_vtbl;
64 svga->pipe.transfer_unmap = u_transfer_unmap_vtbl;
65 svga->pipe.transfer_destroy = u_transfer_destroy_vtbl;
66 svga->pipe.transfer_inline_write = u_transfer_inline_write_vtbl;
H A Dsvga_swtnl_backend.c50 struct svga_context *svga = svga_render->svga; local
52 svga_swtnl_update_vdecl(svga);
64 struct svga_context *svga = svga_render->svga; local
65 struct pipe_screen *screen = svga->pipe.screen;
71 svga->swtnl.new_vdecl = TRUE;
74 if (svga->swtnl.new_vbuf)
76 svga->swtnl.new_vbuf = FALSE;
93 svga_context_flush(svga, NUL
122 struct svga_context *svga = svga_render->svga; local
149 struct svga_context *svga = svga_render->svga; local
175 struct svga_context *svga = svga_render->svga; local
232 struct svga_context *svga = svga_render->svga; local
261 struct svga_context *svga = svga_render->svga; local
[all...]
H A Dsvga_pipe_fs.c48 struct svga_context *svga = svga_context(pipe); local
61 fs->base.id = svga->debug.shader_id++;
67 fs->draw_shader = draw_create_fragment_shader(svga->swtnl.draw, templ);
82 struct svga_context *svga = svga_context(pipe); local
84 svga->curr.fs = fs;
85 svga->dirty |= SVGA_NEW_FS;
91 struct svga_context *svga = svga_context(pipe); local
96 svga_hwtnl_flush_retry( svga );
98 draw_delete_fragment_shader(svga->swtnl.draw, fs->draw_shader);
103 ret = SVGA3D_DestroyShader(svga
[all...]
H A Dsvga_pipe_clear.c38 try_clear(struct svga_context *svga, argument
48 struct pipe_framebuffer_state *fb = &svga->curr.framebuffer;
51 ret = svga_update_state(svga, SVGA_STATE_HW_CLEAR);
55 if (svga->rebind.rendertargets) {
56 ret = svga_reemit_framebuffer_bindings(svga);
74 if ((svga->curr.framebuffer.zsbuf->format == PIPE_FORMAT_S8_UINT_Z24_UNORM) &&
82 if (memcmp(&rect, &svga->state.hw_clear.viewport, sizeof(rect)) != 0) {
84 ret = SVGA3D_SetViewport(svga->swc, &rect);
89 ret = SVGA3D_ClearRect(svga->swc, flags, uc.ui, depth, stencil,
95 memcpy(&rect, &svga
111 struct svga_context *svga = svga_context( pipe ); local
[all...]
H A Dsvga_state.c122 update_state(struct svga_context *svga, argument
130 ret = svga_hwtnl_flush( svga->hwtnl );
153 ret = atoms[i]->update( svga, *state );
176 ret = atoms[i]->update( svga, *state );
189 svga_update_state(struct svga_context *svga, unsigned max_level) argument
191 struct svga_screen *screen = svga_screen(svga->pipe.screen);
199 if (svga->state.texture_timestamp != screen->texture_timestamp) {
200 svga->state.texture_timestamp = screen->texture_timestamp;
201 svga->dirty |= SVGA_NEW_TEXTURE;
205 svga
228 svga_update_state_retry( struct svga_context *svga, unsigned max_level ) argument
[all...]
H A Dsvga_pipe_constants.c51 struct svga_context *svga = svga_context(pipe); local
64 pipe_resource_reference( &svga->curr.cb[shader],
68 svga->dirty |= SVGA_NEW_FS_CONST_BUFFER;
70 svga->dirty |= SVGA_NEW_VS_CONST_BUFFER;
79 void svga_init_constbuffer_functions( struct svga_context *svga )
81 svga->pipe.set_constant_buffer = svga_set_constant_buffer;
H A Dsvga_state_vdecl.c46 emit_hw_vs_vdecl(struct svga_context *svga, unsigned dirty) argument
48 const struct pipe_vertex_element *ve = svga->curr.velems->velem;
53 assert(svga->curr.velems->count >=
54 svga->curr.vs->base.info.file_count[TGSI_FILE_INPUT]);
56 svga_hwtnl_reset_vdecl( svga->hwtnl,
57 svga->curr.velems->count );
74 for (i = 0; i < svga->curr.velems->count; i++) {
76 &svga->curr.vb[ve[i].vertex_buffer_index];
93 for (i = 0; i < svga->curr.velems->count; i++) {
95 &svga
136 emit_hw_vdecl(struct svga_context *svga, unsigned dirty) argument
[all...]
H A Dsvga_state_tss.c38 void svga_cleanup_tss_binding(struct svga_context *svga) argument
41 unsigned count = MAX2( svga->curr.num_sampler_views,
42 svga->state.hw_draw.num_views );
45 struct svga_hw_view_state *view = &svga->state.hw_draw.views[i];
48 pipe_sampler_view_reference( &svga->curr.sampler_views[i], NULL );
67 update_tss_binding(struct svga_context *svga, argument
70 boolean reemit = svga->rebind.texture_samplers;
72 unsigned count = MAX2( svga->curr.num_sampler_views,
73 svga->state.hw_draw.num_views );
82 const struct svga_sampler_state *s = svga
183 svga_reemit_tss_bindings(struct svga_context *svga) argument
290 update_tss(struct svga_context *svga, unsigned dirty ) argument
[all...]
H A Dsvga_state_fs.c103 static enum pipe_error compile_fs( struct svga_context *svga, argument
129 result->id = util_bitmask_add(svga->fs_bm);
135 ret = SVGA3D_DefineShader(svga->swc,
151 util_bitmask_clear( svga->fs_bm, result->id );
164 make_fs_key(const struct svga_context *svga, argument
178 if (!svga->state.sw.need_swtnl) {
181 key->light_twoside = svga->curr.rast->templ.light_twoside;
182 key->front_ccw = svga->curr.rast->templ.front_ccw;
199 if (svga->curr.blend->need_white_fragments) {
208 for (i = 0; i < svga
250 emit_hw_fs(struct svga_context *svga, unsigned dirty) argument
[all...]
H A Dsvga_pipe_sampler.c98 struct svga_context *svga = svga_context(pipe); local
135 if (svga->debug.use_min_mipmap) {
158 struct svga_context *svga = svga_context(pipe); local
169 if (start + num <= svga->curr.num_samplers &&
170 !memcmp(svga->curr.sampler + start, samplers, num * sizeof(void *))) {
176 svga->curr.sampler[start + i] = samplers[i];
180 unsigned j = MAX2(svga->curr.num_samplers, start + num);
181 while (j > 0 && svga->curr.sampler[j - 1] == NULL)
183 svga->curr.num_samplers = j;
186 svga
239 struct svga_context *svga = svga_context(pipe); local
[all...]
H A Dsvga_swtnl_state.c48 static void set_draw_viewport( struct svga_context *svga )
50 struct pipe_viewport_state vp = svga->curr.viewport;
54 switch (svga->curr.reduced_prim) {
64 if (svga->curr.rast->need_pipeline & SVGA_PIPELINE_FLAG_LINES)
83 draw_set_viewport_state(svga->swtnl.draw, &vp);
87 update_swtnl_draw( struct svga_context *svga, argument
90 draw_flush( svga->swtnl.draw );
93 draw_bind_vertex_shader(svga->swtnl.draw,
94 svga->curr.vs->draw_shader);
97 draw_bind_fragment_shader(svga
234 update_swtnl_vdecl( struct svga_context *svga, unsigned dirty ) argument
[all...]
H A Dsvga_state_constants.c66 emit_const(struct svga_context *svga, unsigned shader, unsigned i, argument
74 if (memcmp(svga->state.hw_draw.cb[shader][i], value,
86 ret = SVGA3D_SetShaderConst( svga->swc,
94 memcpy(svga->state.hw_draw.cb[shader][i], value, 4 * sizeof(float));
107 emit_const_range(struct svga_context *svga, argument
118 debug_printf("svga: too many constants (offset + count = %u)\n",
142 if (memcmp(svga->state.hw_draw.cb[shader][offset + i],
162 memcmp(svga->state.hw_draw.cb[shader][offset + j],
183 ret = SVGA3D_SetShaderConsts(svga->swc,
195 memcpy(svga
213 emit_consts(struct svga_context *svga, unsigned shader) argument
262 emit_fs_consts(struct svga_context *svga, unsigned dirty) argument
320 emit_vs_consts(struct svga_context *svga, unsigned dirty) argument
[all...]
H A Dsvga_pipe_query.c71 struct svga_context *svga = svga_context( pipe ); local
84 sq->hwbuf = svga_winsys_buffer_create(svga,
136 struct svga_context *svga = svga_context( pipe ); local
142 assert(!svga->sq);
147 svga_hwtnl_flush_retry(svga);
167 ret = SVGA3D_BeginQuery(svga->swc, sq->type);
169 svga_context_flush(svga, NULL);
170 ret = SVGA3D_BeginQuery(svga->swc, sq->type);
174 svga->sq = sq;
180 struct svga_context *svga local
212 struct svga_context *svga = svga_context( pipe ); local
[all...]

Completed in 501 milliseconds

123