[virglrenderer-devel] [PATCH v2 1/2] vrend: If available use glCopyImageSubData to execute memcopy like blits
Gurchetan Singh
gurchetansingh at chromium.org
Thu Jul 12 03:43:42 UTC 2018
On Wed, Jul 11, 2018 at 2:58 AM Gert Wollny <gert.wollny at collabora.com> wrote:
>
> Am Mittwoch, den 11.07.2018, 09:37 +0200 schrieb Gert Wollny:
> > [...]
> > > Thanks for the clarifications. gert.wollny@, would it be possible
> > > to
> > > get rid of vrend_canonical_formats_of_same_size /
> > > vrend_is_canonical_format, and do the following instead in
> > > vrend_renderer_blit?
> > >
> > > const struct util_format_description *src_desc =
> > > util_format_description(info->src.format);
> > > const struct util_format_description *dst_desc =
> > > util_format_description(info->dest.format);
> > > if (util_is_format_compatible(src_desc, dst_desc) && ...)
> > > vrend_copy_sub_image(..)
> >
> > Good point, I actually used that already in *resource_copy_region,
> > makes sense to use it in blit too.
> util_is_format_compatible is actually to restrictive, e.g. the
> canonical formats for e.g. RG16 and RGBA8 are different,
Which particular tests show that the canonical formats for RG16 /
RGBA8 are different? I ran:
dEQP-GLES31.functional.copy_image.non_compressed.viewclass_32_bits.rg16f_r32i.texture2d_to_texture2d
and see that swizzled_copy makes blit_dst_format and blit_src_format
PIPE_FORMAT_R8G8B8A8_UNORM.
> but glCopyImageSubData can (and should) copy this, so I'll implement a
> short version that can also take the compressed formats etc.
>
> >
> > Best,
> > Gert
> >
More information about the virglrenderer-devel
mailing list