virgl: Add a tweak to set the value for emulated queries of GL_SAMPLES_PASSED

Graphics / Mesa 3D Graphics Library / Mesa - Gert Wollny [collabora.com] - 20 June 2019 06:50 EDT

On GLES hosts GL_SAMPLES_PASSED is emulated by GL_ANY_SAMPLES_PASSED which returns a boolen. With this tweak the value that is returned if any sample passed can be set. This may be of iterest when an application decides whether some geometry is rendered based on an amount of visibility and not just a binary desicion. virgelrenderer sets a default of 1024 on th host.

v2: Remove reference from virgl and correct description (Emil)
v3: Send the tweak binary encoded instead of using strings (Gurchetan)

5dbecf7863d virgl: Add a tweak to set the value for emulated queries of GL_SAMPLES_PASSED
src/gallium/drivers/virgl/virgl_context.c | 4 ++++
src/gallium/drivers/virgl/virgl_driinfo.h.in | 2 +-
src/gallium/drivers/virgl/virgl_protocol.h | 1 +
src/gallium/drivers/virgl/virgl_screen.c | 5 +++++
src/gallium/drivers/virgl/virgl_screen.h | 1 +
src/util/xmlpool/t_options.h | 5 +++++
6 files changed, 17 insertions(+), 1 deletion(-)

Upstream: cgit.freedesktop.org


  • Share