summaryrefslogtreecommitdiff
path: root/src/intel/blorp
diff options
context:
space:
mode:
authorMatt Turner <mattst88@gmail.com>2017-08-25 20:08:23 -0700
committerMatt Turner <mattst88@gmail.com>2017-08-29 15:20:57 -0700
commit37f664a066f28207bbf6d68904222919ad962c1e (patch)
tree1a30c892a690c95622e11d9b9509767659fa17c6 /src/intel/blorp
parentb962922fb7f1f4fe6364b113322bd521ac9c555c (diff)
blorp: Explicitly cast between different enums
Fixes warnings like warning: implicit conversion from enumeration type 'enum isl_format' to different enumeration type 'enum GEN10_SURFACE_FORMAT' [-Wenum-conversion] .SourceElementFormat = ISL_FORMAT_R32_UINT, ^~~~~~~~~~~~~~~~~~~ Reviewed-by: Emil Velikov <emil.velikov@collabora.com> Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
Diffstat (limited to 'src/intel/blorp')
-rw-r--r--src/intel/blorp/blorp_genX_exec.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/intel/blorp/blorp_genX_exec.h b/src/intel/blorp/blorp_genX_exec.h
index 524736fbc0e..5f9a8ab4a51 100644
--- a/src/intel/blorp/blorp_genX_exec.h
+++ b/src/intel/blorp/blorp_genX_exec.h
@@ -380,7 +380,7 @@ blorp_emit_vertex_elements(struct blorp_batch *batch,
ve[slot] = (struct GENX(VERTEX_ELEMENT_STATE)) {
.VertexBufferIndex = 1,
.Valid = true,
- .SourceElementFormat = ISL_FORMAT_R32G32B32A32_FLOAT,
+ .SourceElementFormat = (enum GENX(SURFACE_FORMAT)) ISL_FORMAT_R32G32B32A32_FLOAT,
.SourceElementOffset = 0,
.Component0Control = VFCOMP_STORE_SRC,
@@ -412,7 +412,7 @@ blorp_emit_vertex_elements(struct blorp_batch *batch,
ve[slot] = (struct GENX(VERTEX_ELEMENT_STATE)) {
.VertexBufferIndex = 0,
.Valid = true,
- .SourceElementFormat = ISL_FORMAT_R32G32B32_FLOAT,
+ .SourceElementFormat = (enum GENX(SURFACE_FORMAT)) ISL_FORMAT_R32G32B32_FLOAT,
.SourceElementOffset = 0,
.Component0Control = VFCOMP_STORE_SRC,
.Component1Control = VFCOMP_STORE_SRC,
@@ -426,7 +426,7 @@ blorp_emit_vertex_elements(struct blorp_batch *batch,
ve[slot] = (struct GENX(VERTEX_ELEMENT_STATE)) {
.VertexBufferIndex = 0,
.Valid = true,
- .SourceElementFormat = ISL_FORMAT_R32G32B32_FLOAT,
+ .SourceElementFormat = (enum GENX(SURFACE_FORMAT)) ISL_FORMAT_R32G32B32_FLOAT,
.SourceElementOffset = 0,
.Component0Control = VFCOMP_STORE_SRC,
.Component1Control = VFCOMP_STORE_SRC,
@@ -442,7 +442,7 @@ blorp_emit_vertex_elements(struct blorp_batch *batch,
ve[slot] = (struct GENX(VERTEX_ELEMENT_STATE)) {
.VertexBufferIndex = 1,
.Valid = true,
- .SourceElementFormat = ISL_FORMAT_R32G32B32A32_FLOAT,
+ .SourceElementFormat = (enum GENX(SURFACE_FORMAT)) ISL_FORMAT_R32G32B32A32_FLOAT,
.SourceElementOffset = 16 + i * 4 * sizeof(float),
.Component0Control = VFCOMP_STORE_SRC,
.Component1Control = VFCOMP_STORE_SRC,
@@ -1268,7 +1268,7 @@ blorp_emit_null_surface_state(struct blorp_batch *batch,
{
struct GENX(RENDER_SURFACE_STATE) ss = {
.SurfaceType = SURFTYPE_NULL,
- .SurfaceFormat = ISL_FORMAT_R8G8B8A8_UNORM,
+ .SurfaceFormat = (enum GENX(SURFACE_FORMAT)) ISL_FORMAT_R8G8B8A8_UNORM,
.Width = surface->surf.logical_level0_px.width - 1,
.Height = surface->surf.logical_level0_px.height - 1,
.MIPCountLOD = surface->view.base_level,