diff options
author | Jonathan Gray <jsg@cvs.openbsd.org> | 2021-07-22 10:17:30 +0000 |
---|---|---|
committer | Jonathan Gray <jsg@cvs.openbsd.org> | 2021-07-22 10:17:30 +0000 |
commit | ca11beabae33eb59fb981b8adf50b1d47a2a98f0 (patch) | |
tree | 3e4691a396e6e54cd54224a190663d5cf976625b /lib/mesa/src/gallium/drivers/llvmpipe/lp_jit.h | |
parent | 27c8a50e8bbde7d28b1fc46d715a4c469e24f2c4 (diff) |
Import Mesa 21.1.5
Diffstat (limited to 'lib/mesa/src/gallium/drivers/llvmpipe/lp_jit.h')
-rw-r--r-- | lib/mesa/src/gallium/drivers/llvmpipe/lp_jit.h | 29 |
1 files changed, 26 insertions, 3 deletions
diff --git a/lib/mesa/src/gallium/drivers/llvmpipe/lp_jit.h b/lib/mesa/src/gallium/drivers/llvmpipe/lp_jit.h index 71931e15e..ce08b90dc 100644 --- a/lib/mesa/src/gallium/drivers/llvmpipe/lp_jit.h +++ b/lib/mesa/src/gallium/drivers/llvmpipe/lp_jit.h @@ -60,6 +60,8 @@ struct lp_jit_texture uint32_t first_level; uint32_t last_level; uint32_t mip_offsets[LP_MAX_TEXTURE_LEVELS]; + uint32_t num_samples; + uint32_t sample_stride; }; @@ -87,6 +89,8 @@ struct lp_jit_image const void *base; uint32_t row_stride; uint32_t img_stride; + uint32_t num_samples; + uint32_t sample_stride; }; enum { @@ -99,6 +103,8 @@ enum { LP_JIT_TEXTURE_FIRST_LEVEL, LP_JIT_TEXTURE_LAST_LEVEL, LP_JIT_TEXTURE_MIP_OFFSETS, + LP_JIT_TEXTURE_NUM_SAMPLES, + LP_JIT_TEXTURE_SAMPLE_STRIDE, LP_JIT_TEXTURE_NUM_FIELDS /* number of fields above */ }; @@ -125,6 +131,8 @@ enum { LP_JIT_IMAGE_BASE, LP_JIT_IMAGE_ROW_STRIDE, LP_JIT_IMAGE_IMG_STRIDE, + LP_JIT_IMAGE_NUM_SAMPLES, + LP_JIT_IMAGE_SAMPLE_STRIDE, LP_JIT_IMAGE_NUM_FIELDS /* number of fields above */ }; /** @@ -158,6 +166,8 @@ struct lp_jit_context const uint32_t *ssbos[LP_MAX_TGSI_SHADER_BUFFERS]; int num_ssbos[LP_MAX_TGSI_SHADER_BUFFERS]; + + uint32_t sample_mask; }; @@ -179,6 +189,7 @@ enum { LP_JIT_CTX_VIEWPORTS, LP_JIT_CTX_SSBOS, LP_JIT_CTX_NUM_SSBOS, + LP_JIT_CTX_SAMPLE_MASK, LP_JIT_CTX_COUNT }; @@ -222,6 +233,9 @@ enum { #define lp_jit_context_num_ssbos(_gallivm, _ptr) \ lp_build_struct_get_ptr(_gallivm, _ptr, LP_JIT_CTX_NUM_SSBOS, "num_ssbos") +#define lp_jit_context_sample_mask(_gallivm, _ptr) \ + lp_build_struct_get_ptr(_gallivm, _ptr, LP_JIT_CTX_SAMPLE_MASK, "sample_mask") + struct lp_jit_thread_data { struct lp_build_format_cache *cache; @@ -233,6 +247,7 @@ struct lp_jit_thread_data */ struct { uint32_t viewport_index; + uint32_t view_index; } raster_state; }; @@ -242,6 +257,7 @@ enum { LP_JIT_THREAD_DATA_COUNTER, LP_JIT_THREAD_DATA_INVOCATIONS, LP_JIT_THREAD_DATA_RASTER_STATE_VIEWPORT_INDEX, + LP_JIT_THREAD_DATA_RASTER_STATE_VIEW_INDEX, LP_JIT_THREAD_DATA_COUNT }; @@ -259,6 +275,11 @@ enum { lp_build_struct_get(_gallivm, _ptr, \ LP_JIT_THREAD_DATA_RASTER_STATE_VIEWPORT_INDEX, \ "raster_state.viewport_index") + +#define lp_jit_thread_data_raster_state_view_index(_gallivm, _ptr) \ + lp_build_struct_get(_gallivm, _ptr, \ + LP_JIT_THREAD_DATA_RASTER_STATE_VIEW_INDEX, \ + "raster_state.view_index") /** * typedef for fragment shader function @@ -272,7 +293,7 @@ enum { * @param dady shader input dady * @param color color buffer * @param depth depth buffer - * @param mask mask of visible pixels in block + * @param mask mask of visible pixels in block (16-bits per sample) * @param thread_data task thread data * @param stride color buffer row stride in bytes * @param depth_stride depth buffer row stride in bytes @@ -287,10 +308,12 @@ typedef void const void *dady, uint8_t **color, uint8_t *depth, - uint32_t mask, + uint64_t mask, struct lp_jit_thread_data *thread_data, unsigned *stride, - unsigned depth_stride); + unsigned depth_stride, + unsigned *color_sample_stride, + unsigned depth_sample_stride); struct lp_jit_cs_thread_data |