Lines Matching refs:prsc
46 struct pipe_resource *prsc = &rsc->base; in vc4_resource_bo_alloc() local
47 struct pipe_screen *pscreen = prsc->screen; in vc4_resource_bo_alloc()
57 rsc->cube_map_stride * (prsc->array_size - 1)); in vc4_resource_bo_alloc()
63 rsc->cube_map_stride * (prsc->array_size - 1), in vc4_resource_bo_alloc()
132 struct pipe_resource *prsc, in vc4_get_temp_resource() argument
138 temp_setup.target = prsc->target; in vc4_get_temp_resource()
139 temp_setup.format = prsc->format; in vc4_get_temp_resource()
150 struct pipe_resource *prsc, in vc4_resource_transfer_map() argument
156 struct vc4_resource *rsc = vc4_resource(prsc); in vc4_resource_transfer_map()
159 enum pipe_format format = prsc->format; in vc4_resource_transfer_map()
167 !(prsc->flags & PIPE_RESOURCE_FLAG_MAP_COHERENT) && in vc4_resource_transfer_map()
168 prsc->last_level == 0 && in vc4_resource_transfer_map()
169 prsc->width0 == box->width && in vc4_resource_transfer_map()
170 prsc->height0 == box->height && in vc4_resource_transfer_map()
171 prsc->depth0 == box->depth && in vc4_resource_transfer_map()
172 prsc->array_size == 1 && in vc4_resource_transfer_map()
182 if (prsc->bind & PIPE_BIND_VERTEX_BUFFER) in vc4_resource_transfer_map()
188 vc4_flush_jobs_reading_resource(vc4, prsc); in vc4_resource_transfer_map()
196 vc4_flush_jobs_reading_resource(vc4, prsc); in vc4_resource_transfer_map()
198 vc4_flush_jobs_writing_resource(vc4, prsc); in vc4_resource_transfer_map()
216 pipe_resource_reference(&ptrans->resource, prsc); in vc4_resource_transfer_map()
224 if (prsc->nr_samples > 1) { in vc4_resource_transfer_map()
225 trans->ss_resource = vc4_get_temp_resource(pctx, prsc, box); in vc4_resource_transfer_map()
250 blit.mask = util_format_get_mask(prsc->format); in vc4_resource_transfer_map()
258 prsc = trans->ss_resource; in vc4_resource_transfer_map()
259 rsc = vc4_resource(prsc); in vc4_resource_transfer_map()
326 uint32_t slice_width = u_minify(prsc->width0, level); in vc4_resource_transfer_map()
332 uint32_t slice_height = u_minify(prsc->height0, level); in vc4_resource_transfer_map()
372 struct pipe_resource *prsc) in vc4_resource_destroy() argument
375 struct vc4_resource *rsc = vc4_resource(prsc); in vc4_resource_destroy()
387 struct pipe_resource *prsc, in vc4_resource_get_handle() argument
392 struct vc4_resource *rsc = vc4_resource(prsc); in vc4_resource_get_handle()
437 struct pipe_resource *prsc = &rsc->base; in vc4_setup_slices() local
438 uint32_t width = prsc->width0; in vc4_setup_slices()
439 uint32_t height = prsc->height0; in vc4_setup_slices()
440 if (prsc->format == PIPE_FORMAT_ETC1_RGB8) { in vc4_setup_slices()
451 for (int i = prsc->last_level; i >= 0; i--) { in vc4_setup_slices()
465 if (prsc->nr_samples > 1) { in vc4_setup_slices()
489 MAX2(prsc->nr_samples, 1)); in vc4_setup_slices()
504 util_format_short_name(prsc->format), in vc4_setup_slices()
506 prsc->width0, prsc->height0, in vc4_setup_slices()
520 for (int i = 0; i <= prsc->last_level; i++) in vc4_setup_slices()
527 if (prsc->target == PIPE_TEXTURE_CUBE) { in vc4_setup_slices()
540 struct pipe_resource *prsc = &rsc->base; in vc4_resource_setup() local
542 *prsc = *tmpl; in vc4_resource_setup()
544 pipe_reference_init(&prsc->reference, 1); in vc4_resource_setup()
545 prsc->screen = pscreen; in vc4_resource_setup()
547 if (prsc->nr_samples <= 1) in vc4_resource_setup()
558 get_resource_texture_format(struct pipe_resource *prsc) in get_resource_texture_format() argument
560 struct vc4_resource *rsc = vc4_resource(prsc); in get_resource_texture_format()
561 uint8_t format = vc4_get_tex_format(prsc->format); in get_resource_texture_format()
564 if (prsc->nr_samples > 1) { in get_resource_texture_format()
596 struct pipe_resource *prsc = &rsc->base; in vc4_resource_create_with_modifiers() local
623 vc4_size_is_lt(prsc->width0, prsc->height0, rsc->cpp)) in vc4_resource_create_with_modifiers()
649 rsc->vc4_format = get_resource_texture_format(prsc); in vc4_resource_create_with_modifiers()
673 renderonly_scanout_for_resource(prsc, screen->ro, NULL); in vc4_resource_create_with_modifiers()
681 rsc->cpp * 8, prsc->last_level); in vc4_resource_create_with_modifiers()
683 return prsc; in vc4_resource_create_with_modifiers()
685 vc4_resource_destroy(pscreen, prsc); in vc4_resource_create_with_modifiers()
705 struct pipe_resource *prsc = &rsc->base; in vc4_resource_from_handle() local
766 rsc->vc4_format = get_resource_texture_format(prsc); in vc4_resource_from_handle()
775 renderonly_create_gpu_import_for_resource(prsc, in vc4_resource_from_handle()
789 prsc->width0, prsc->height0, in vc4_resource_from_handle()
790 util_format_short_name(prsc->format), in vc4_resource_from_handle()
797 return prsc; in vc4_resource_from_handle()
800 vc4_resource_destroy(pscreen, prsc); in vc4_resource_from_handle()
847 struct pipe_resource *prsc = psurf->texture; in vc4_dump_surface_non_msaa() local
848 struct vc4_resource *rsc = vc4_resource(prsc); in vc4_dump_surface_non_msaa()
944 struct pipe_resource *prsc = psurf->texture; in vc4_surface_msaa_get_sample() local
945 struct vc4_resource *rsc = vc4_resource(prsc); in vc4_surface_msaa_get_sample()