Home
last modified time | relevance | path

Searched refs:zsbuf (Results 1 – 25 of 122) sorted by relevance

12345

/external/mesa3d/src/gallium/auxiliary/util/
Du_framebuffer.c72 if (dst->zsbuf != src->zsbuf) { in util_framebuffer_state_equal()
105 pipe_surface_reference(&dst->zsbuf, src->zsbuf); in util_copy_framebuffer_state()
118 pipe_surface_reference(&dst->zsbuf, NULL); in util_copy_framebuffer_state()
132 pipe_surface_reference(&fb->zsbuf, NULL); in util_unreference_framebuffer_state()
160 if (fb->zsbuf) { in util_framebuffer_min_size()
161 w = MIN2(w, fb->zsbuf->width); in util_framebuffer_min_size()
162 h = MIN2(h, fb->zsbuf->height); in util_framebuffer_min_size()
191 if (!(fb->nr_cbufs || fb->zsbuf)) in util_framebuffer_get_num_layers()
201 if (fb->zsbuf) { in util_framebuffer_get_num_layers()
202 unsigned num = fb->zsbuf->u.tex.last_layer - in util_framebuffer_get_num_layers()
[all …]
/external/mesa3d/src/gallium/drivers/llvmpipe/
Dlp_scene.c190 if (fb->zsbuf) { in lp_scene_begin_rasterization()
191 struct pipe_surface *zsbuf = scene->fb.zsbuf; in lp_scene_begin_rasterization() local
192 scene->zsbuf.stride = llvmpipe_resource_stride(zsbuf->texture, zsbuf->u.tex.level); in lp_scene_begin_rasterization()
193 scene->zsbuf.layer_stride = llvmpipe_layer_stride(zsbuf->texture, zsbuf->u.tex.level); in lp_scene_begin_rasterization()
195 scene->zsbuf.map = llvmpipe_resource_map(zsbuf->texture, in lp_scene_begin_rasterization()
196 zsbuf->u.tex.level, in lp_scene_begin_rasterization()
197 zsbuf->u.tex.first_layer, in lp_scene_begin_rasterization()
199 scene->zsbuf.format_bytes = util_format_get_blocksize(zsbuf->format); in lp_scene_begin_rasterization()
228 if (scene->zsbuf.map) { in lp_scene_end_rasterization()
229 struct pipe_surface *zsbuf = scene->fb.zsbuf; in lp_scene_end_rasterization() local
[all …]
Dlp_state_surface.c65 enum pipe_format depth_format = fb->zsbuf ? in llvmpipe_set_framebuffer_state()
66 fb->zsbuf->format : PIPE_FORMAT_NONE; in llvmpipe_set_framebuffer_state()
70 if (lp->framebuffer.zsbuf && lp->framebuffer.zsbuf->context != pipe) { in llvmpipe_set_framebuffer_state()
85 pipe_surface_reference(&lp->framebuffer.zsbuf, NULL); in llvmpipe_set_framebuffer_state()
Dlp_rast_priv.h206 pixel_offset = px * task->scene->zsbuf.format_bytes + in lp_rast_get_depth_block_pointer()
207 py * task->scene->zsbuf.stride; in lp_rast_get_depth_block_pointer()
211 depth += layer * task->scene->zsbuf.layer_stride; in lp_rast_get_depth_block_pointer()
214 assert(lp_check_alignment(depth, llvmpipe_get_format_alignment(task->scene->fb.zsbuf->format))); in lp_rast_get_depth_block_pointer()
252 if (scene->zsbuf.map) { in lp_rast_shade_quads_all()
254 depth_stride = scene->zsbuf.stride; in lp_rast_shade_quads_all()
Dlp_rast.c119 if (task->scene->fb.zsbuf) { in lp_rast_tile_begin()
120 task->depth_tile = scene->zsbuf.map + in lp_rast_tile_begin()
121 scene->zsbuf.stride * task->y + in lp_rast_tile_begin()
122 scene->zsbuf.format_bytes * task->x; in lp_rast_tile_begin()
189 const unsigned dst_stride = scene->zsbuf.stride; in lp_rast_clear_zstencil()
201 if (scene->fb.zsbuf) { in lp_rast_clear_zstencil()
204 block_size = util_format_get_blocksize(scene->fb.zsbuf->format); in lp_rast_clear_zstencil()
282 dst_layer += scene->zsbuf.layer_stride; in lp_rast_clear_zstencil()
342 if (scene->zsbuf.map) { in lp_rast_shade_tile()
345 depth_stride = scene->zsbuf.stride; in lp_rast_shade_tile()
[all …]
/external/mesa3d/src/gallium/drivers/softpipe/
Dsp_clear.c54 struct pipe_surface *zsbuf = softpipe->framebuffer.zsbuf; in softpipe_clear() local
76 util_format_is_depth_and_stencil(zsbuf->texture->format) && in softpipe_clear()
79 util_clear_depth_stencil(pipe, zsbuf, zs_buffers, depth, stencil, in softpipe_clear()
80 0, 0, zsbuf->width, zsbuf->height); in softpipe_clear()
85 cv = util_pack64_z_stencil(zsbuf->format, depth, stencil); in softpipe_clear()
Dsp_state_surface.c75 if (sp->framebuffer.zsbuf != fb->zsbuf) { in softpipe_set_framebuffer_state()
80 pipe_surface_reference(&sp->framebuffer.zsbuf, fb->zsbuf); in softpipe_set_framebuffer_state()
83 sp_tile_cache_set_surface(sp->zsbuf_cache, fb->zsbuf); in softpipe_set_framebuffer_state()
91 (sp->framebuffer.zsbuf) ? in softpipe_set_framebuffer_state()
92 sp->framebuffer.zsbuf->format : PIPE_FORMAT_NONE); in softpipe_set_framebuffer_state()
/external/mesa3d/src/gallium/drivers/svga/
Dsvga_state_framebuffer.c95 if ((curr->zsbuf != hw->zsbuf) || (reemit && hw->zsbuf)) { in emit_fb_vgpu9()
96 ret = SVGA3D_SetRenderTarget(svga->swc, SVGA3D_RT_DEPTH, curr->zsbuf); in emit_fb_vgpu9()
101 if (hw->zsbuf && svga_surface_needs_propagation(hw->zsbuf)) in emit_fb_vgpu9()
102 svga_propagate_surface(svga, hw->zsbuf, TRUE); in emit_fb_vgpu9()
104 if (curr->zsbuf && in emit_fb_vgpu9()
105 util_format_is_depth_and_stencil(curr->zsbuf->format)) { in emit_fb_vgpu9()
107 curr->zsbuf); in emit_fb_vgpu9()
117 pipe_surface_reference(&hw->zsbuf, curr->zsbuf); in emit_fb_vgpu9()
120 struct pipe_surface *s = curr->zsbuf; in emit_fb_vgpu9()
159 if (hw->zsbuf) { in svga_reemit_framebuffer_bindings_vgpu9()
[all …]
Dsvga_pipe_misc.c97 pipe_surface_reference(&curr->zsbuf, NULL); in svga_cleanup_framebuffer()
98 pipe_surface_reference(&hw->zsbuf, NULL); in svga_cleanup_framebuffer()
130 if (fb->zsbuf) { in svga_set_framebuffer_state()
131 width = fb->zsbuf->width; in svga_set_framebuffer_state()
132 height = fb->zsbuf->height; in svga_set_framebuffer_state()
153 if (svga->curr.framebuffer.zsbuf) { in svga_set_framebuffer_state()
154 switch (svga->curr.framebuffer.zsbuf->format) { in svga_set_framebuffer_state()
Dsvga_pipe_flush.c67 if (0 && fb->zsbuf) { in svga_flush()
69 debug_dump_surface_bmp(&svga->pipe, filename, fb->zsbuf); in svga_flush()
/external/mesa3d/src/gallium/drivers/vc5/
Dvc5_job.c75 if (job->zsbuf) { in vc5_job_free()
76 remove_from_ht(vc5->write_jobs, job->zsbuf->texture); in vc5_job_free()
77 pipe_surface_reference(&job->zsbuf, NULL); in vc5_job_free()
232 struct pipe_surface **cbufs, struct pipe_surface *zsbuf) in vc5_get_job() argument
242 .zsbuf = zsbuf, in vc5_get_job()
263 if (zsbuf) { in vc5_get_job()
264 vc5_flush_jobs_reading_resource(vc5, zsbuf->texture); in vc5_get_job()
265 pipe_surface_reference(&job->zsbuf, zsbuf); in vc5_get_job()
266 if (zsbuf->texture->nr_samples > 1) in vc5_get_job()
277 if (zsbuf) in vc5_get_job()
[all …]
Dvc5_rcl.c221 (job->zsbuf && job->zsbuf->texture->nr_samples > 1))) { in vc5_rcl_emit_loads()
222 load_general(cl, job->zsbuf, in vc5_rcl_emit_loads()
305 if (job->resolve & PIPE_CLEAR_DEPTHSTENCIL && job->zsbuf && in vc5_rcl_emit_stores()
306 !(V3D_VERSION < 40 && job->zsbuf->texture->nr_samples <= 1)) { in vc5_rcl_emit_stores()
309 struct vc5_resource *rsc = vc5_resource(job->zsbuf->texture); in vc5_rcl_emit_stores()
312 store_general(job, cl, job->zsbuf, Z, in vc5_rcl_emit_stores()
318 store_general(job, cl, job->zsbuf, STENCIL, in vc5_rcl_emit_stores()
324 store_general(job, cl, job->zsbuf, in vc5_rcl_emit_stores()
467 if (job->zsbuf) { in v3dX()
468 struct vc5_surface *surf = vc5_surface(job->zsbuf); in v3dX()
[all …]
Dvc5_context.c84 if (job->key.zsbuf && job->key.zsbuf->texture == prsc) in vc5_invalidate_resource()
107 pipe_surface_reference(&vc5->framebuffer.zsbuf, NULL); in vc5_context_destroy()
/external/mesa3d/src/gallium/drivers/freedreno/a5xx/
Dfd5_draw.c185 fd5_clear_lrz(struct fd_batch *batch, struct fd_resource *zsbuf, double depth) in fd5_clear_lrz() argument
227 OUT_RING(ring, A5XX_RB_MRT_PITCH(zsbuf->lrz_pitch * 2)); in fd5_clear_lrz()
228 OUT_RING(ring, A5XX_RB_MRT_ARRAY_PITCH(fd_bo_size(zsbuf->lrz))); in fd5_clear_lrz()
229 OUT_RELOCW(ring, zsbuf->lrz, 0x1000, 0, 0); in fd5_clear_lrz()
248 OUT_RING(ring, A5XX_VSC_RESOLVE_CNTL_X(zsbuf->lrz_width) | in fd5_clear_lrz()
249 A5XX_VSC_RESOLVE_CNTL_Y(zsbuf->lrz_height)); in fd5_clear_lrz()
258 OUT_RING(ring, A5XX_RB_RESOLVE_CNTL_2_X(zsbuf->lrz_width - 1) | in fd5_clear_lrz()
259 A5XX_RB_RESOLVE_CNTL_2_Y(zsbuf->lrz_height - 1)); in fd5_clear_lrz()
273 is_z32(pfb->zsbuf->format)) in fd5_clear()
349 if (pfb->zsbuf && (buffers & (PIPE_CLEAR_DEPTH | PIPE_CLEAR_STENCIL))) { in fd5_clear()
[all …]
Dfd5_gmem.c134 emit_zs(struct fd_ringbuffer *ring, struct pipe_surface *zsbuf, in emit_zs() argument
137 if (zsbuf) { in emit_zs()
138 struct fd_resource *rsc = fd_resource(zsbuf->texture); in emit_zs()
139 enum a5xx_depth_format fmt = fd5_pipe2depth(zsbuf->format); in emit_zs()
400 emit_zs(ring, pfb->zsbuf, &ctx->gmem); in fd5_emit_tile_init()
558 struct fd_resource *rsc = fd_resource(pfb->zsbuf->texture); in fd5_emit_tile_mem2gmem()
561 emit_mem2gmem_surf(batch, gmem->zsbuf_base[0], pfb->zsbuf, BLIT_ZS); in fd5_emit_tile_mem2gmem()
563 emit_mem2gmem_surf(batch, gmem->zsbuf_base[1], pfb->zsbuf, BLIT_S); in fd5_emit_tile_mem2gmem()
580 emit_zs(ring, pfb->zsbuf, gmem); in fd5_emit_tile_renderprep()
654 struct fd_resource *rsc = fd_resource(pfb->zsbuf->texture); in fd5_emit_tile_gmem2mem()
[all …]
/external/mesa3d/src/gallium/drivers/vc4/
Dvc4_job.c169 struct pipe_surface *cbuf, struct pipe_surface *zsbuf) in vc4_get_job() argument
172 struct vc4_job_key local_key = {.cbuf = cbuf, .zsbuf = zsbuf}; in vc4_get_job()
183 if (zsbuf) in vc4_get_job()
184 vc4_flush_jobs_reading_resource(vc4, zsbuf->texture); in vc4_get_job()
197 if (zsbuf) { in vc4_get_job()
198 if (zsbuf->texture->nr_samples > 1) { in vc4_get_job()
200 pipe_surface_reference(&job->msaa_zs_write, zsbuf); in vc4_get_job()
202 pipe_surface_reference(&job->zs_write, zsbuf); in vc4_get_job()
216 if (zsbuf) in vc4_get_job()
217 _mesa_hash_table_insert(vc4->write_jobs, zsbuf->texture, job); in vc4_get_job()
[all …]
Dvc4_context.c93 if (job->key.zsbuf && job->key.zsbuf->texture == prsc) in vc4_invalidate_resource()
116 pipe_surface_reference(&vc4->framebuffer.zsbuf, NULL); in vc4_context_destroy()
/external/mesa3d/src/gallium/drivers/swr/
Dswr_clear.cpp54 if (buffers & PIPE_CLEAR_DEPTH && fb->zsbuf) { in swr_clear()
56 layers = std::max(layers, fb->zsbuf->u.tex.last_layer - in swr_clear()
57 fb->zsbuf->u.tex.first_layer + 1u); in swr_clear()
60 if (buffers & PIPE_CLEAR_STENCIL && fb->zsbuf) { in swr_clear()
62 layers = std::max(layers, fb->zsbuf->u.tex.last_layer - in swr_clear()
63 fb->zsbuf->u.tex.first_layer + 1u); in swr_clear()
86 if (fb->zsbuf && in swr_clear()
87 (fb->zsbuf->u.tex.last_layer <= fb->zsbuf->u.tex.first_layer + i)) in swr_clear()
/external/mesa3d/src/gallium/drivers/etnaviv/
Detnaviv_state.c198 if (sv->zsbuf != NULL) { in etna_set_framebuffer_state()
199 struct etna_surface *zsbuf = etna_surface(sv->zsbuf); in etna_set_framebuffer_state() local
200 struct etna_resource *res = etna_resource(zsbuf->base.texture); in etna_set_framebuffer_state()
202 etna_update_render_resource(pctx, zsbuf->base.texture); in etna_set_framebuffer_state()
204 pipe_surface_reference(&cs->zsbuf, &zsbuf->base); in etna_set_framebuffer_state()
207 uint32_t depth_format = translate_depth_format(zsbuf->base.format); in etna_set_framebuffer_state()
222 cs->PE_DEPTH_ADDR = zsbuf->reloc[0]; in etna_set_framebuffer_state()
226 cs->PE_PIPE_DEPTH_ADDR[i] = zsbuf->reloc[i]; in etna_set_framebuffer_state()
231 cs->PE_DEPTH_STRIDE = zsbuf->surf.stride; in etna_set_framebuffer_state()
235 if (zsbuf->surf.ts_size) { in etna_set_framebuffer_state()
[all …]
/external/mesa3d/src/mesa/state_tracker/
Dst_atom_framebuffer.c180 framebuffer.zsbuf = strb->surface; in st_update_framebuffer_state()
190 framebuffer.zsbuf = strb->surface; in st_update_framebuffer_state()
194 framebuffer.zsbuf = NULL; in st_update_framebuffer_state()
203 if (framebuffer.zsbuf) { in st_update_framebuffer_state()
204 assert(framebuffer.zsbuf->texture->bind & PIPE_BIND_DEPTH_STENCIL); in st_update_framebuffer_state()
/external/mesa3d/src/gallium/drivers/r300/
Dr300_blit.c145 return r300_resource(fb->zsbuf->texture)->tex.zmask_dwords[fb->zsbuf->u.tex.level] != 0; in r300_fast_zclear_allowed()
153 return r300_resource(fb->zsbuf->texture)->tex.hiz_dwords[fb->zsbuf->u.tex.level] != 0; in r300_hiz_clear_allowed()
268 if (fb->zsbuf->texture->format == PIPE_FORMAT_S8_UINT_Z24_UNORM && in r300_clear()
296 r300_depth_clear_value(fb->zsbuf->format, depth, stencil); in r300_clear()
460 if (fb->zsbuf->texture == dst->texture) { in r300_clear_depth_stencil()
501 fb.zsbuf = r300->locked_zbuffer; in r300_decompress_zmask_locked_unsafe()
659 if (fb->zsbuf->texture == src || in r300_resource_copy_region()
660 fb->zsbuf->texture == dst) { in r300_resource_copy_region()
857 if (fb->zsbuf->texture == info.src.resource || in r300_blit()
858 fb->zsbuf->texture == info.dst.resource) { in r300_blit()
/external/mesa3d/src/gallium/drivers/freedreno/a4xx/
Dfd4_gmem.c274 struct fd_resource *rsc = fd_resource(pfb->zsbuf->texture); in fd4_emit_tile_gmem2mem()
276 emit_gmem2mem_surf(batch, false, ctx->gmem.zsbuf_base[0], pfb->zsbuf); in fd4_emit_tile_gmem2mem()
278 emit_gmem2mem_surf(batch, true, ctx->gmem.zsbuf_base[1], pfb->zsbuf); in fd4_emit_tile_gmem2mem()
467 switch (pfb->zsbuf->format) { in fd4_emit_tile_mem2gmem()
470 emit.prog = (pfb->zsbuf->format == PIPE_FORMAT_Z32_FLOAT) ? in fd4_emit_tile_mem2gmem()
496 fd4_program_emit(ring, &emit, 1, &pfb->zsbuf); in fd4_emit_tile_mem2gmem()
497 emit_mem2gmem_surf(batch, gmem->zsbuf_base, &pfb->zsbuf, 1, bin_w); in fd4_emit_tile_mem2gmem()
715 if (pfb->zsbuf) { in fd4_emit_tile_prep()
716 struct fd_resource *rsc = fd_resource(pfb->zsbuf->texture); in fd4_emit_tile_prep()
721 A4XX_RB_DEPTH_INFO_DEPTH_FORMAT(fd4_pipe2depth(pfb->zsbuf->format))); in fd4_emit_tile_prep()
[all …]
/external/mesa3d/src/gallium/drivers/freedreno/
Dfreedreno_draw.c140 if (fd_resource(pfb->zsbuf->texture)->valid) in fd_draw_vbo()
143 resource_written(batch, pfb->zsbuf->texture); in fd_draw_vbo()
148 if (fd_resource(pfb->zsbuf->texture)->valid) in fd_draw_vbo()
151 resource_written(batch, pfb->zsbuf->texture); in fd_draw_vbo()
255 util_format_short_name(pipe_surface_format(pfb->zsbuf))); in fd_draw_vbo()
399 resource_written(batch, pfb->zsbuf->texture); in fd_clear()
413 util_format_short_name(pipe_surface_format(pfb->zsbuf))); in fd_clear()
/external/mesa3d/src/gallium/drivers/nouveau/nv30/
Dnv30_state_validate.c62 if (fb->zsbuf && util_format_get_blocksize(fb->zsbuf->format) > 2) in nv30_validate_fb()
68 if (fb->zsbuf) { in nv30_validate_fb()
69 rt_format |= nv30_format(pscreen, fb->zsbuf->format)->hw; in nv30_validate_fb()
70 if (nv30_miptree(fb->zsbuf->texture)->swizzled) in nv30_validate_fb()
116 if ((nv30->state.rt_enable & NV30_3D_RT_ENABLE_COLOR0) || fb->zsbuf) { in nv30_validate_fb()
118 struct nv30_surface *zsf = nv30_surface(fb->zsbuf); in nv30_validate_fb()
/external/mesa3d/src/gallium/drivers/freedreno/a3xx/
Dfd3_gmem.c447 struct fd_resource *rsc = fd_resource(pfb->zsbuf->texture); in fd3_emit_tile_gmem2mem()
450 ctx->gmem.zsbuf_base[0], pfb->zsbuf); in fd3_emit_tile_gmem2mem()
453 ctx->gmem.zsbuf_base[1], pfb->zsbuf); in fd3_emit_tile_gmem2mem()
672 if (pfb->zsbuf->format != PIPE_FORMAT_Z32_FLOAT_S8X24_UINT && in fd3_emit_tile_mem2gmem()
673 pfb->zsbuf->format != PIPE_FORMAT_Z32_FLOAT) { in fd3_emit_tile_mem2gmem()
681 if (pfb->zsbuf->format == PIPE_FORMAT_Z32_FLOAT) in fd3_emit_tile_mem2gmem()
688 fd3_program_emit(ring, &emit, 1, &pfb->zsbuf); in fd3_emit_tile_mem2gmem()
689 emit_mem2gmem_surf(batch, gmem->zsbuf_base, &pfb->zsbuf, 1, bin_w); in fd3_emit_tile_mem2gmem()
997 if (pfb->zsbuf) { in fd3_emit_tile_renderprep()
998 reg |= A3XX_RB_DEPTH_INFO_DEPTH_FORMAT(fd_pipe2depth(pfb->zsbuf->format)); in fd3_emit_tile_renderprep()
[all …]

12345