Wire up cull mode handling to Vulkan pipeline

Bug: b/124177079
Change-Id: I8e55607c8ff7f9c2d2356268bedf170cf27eeb99
Reviewed-on: https://swiftshader-review.googlesource.com/c/25268
Tested-by: Chris Forbes <chrisforbes@google.com>
Kokoro-Presubmit: kokoro <noreply+kokoro@google.com>
Reviewed-by: Nicolas Capens <nicolascapens@google.com>
diff --git a/src/Device/Context.hpp b/src/Device/Context.hpp
index 79d9c10..704d126 100644
--- a/src/Device/Context.hpp
+++ b/src/Device/Context.hpp
@@ -177,7 +177,7 @@
 		int stencilWriteMaskCCW;
 
 		// Pixel processor states
-		CullMode cullMode;
+		VkCullModeFlags cullMode;
 		bool frontFacingCCW;
 		float alphaReference;
 
diff --git a/src/Device/SetupProcessor.cpp b/src/Device/SetupProcessor.cpp
index 7b04d5f..a0d4793 100644
--- a/src/Device/SetupProcessor.cpp
+++ b/src/Device/SetupProcessor.cpp
@@ -82,6 +82,7 @@
 		state.interpolateZ = context->depthBufferActive() || vPosZW;
 		state.interpolateW = context->perspectiveActive() || vPosZW;
 		state.perspective = context->perspectiveActive();
+		state.frontFacingCCW = context->frontFacingCCW;
 		state.cullMode = context->cullMode;
 		state.twoSidedStencil = context->stencilActive() && context->twoSidedStencil;
 		state.slopeDepthBias = context->slopeDepthBias != 0.0f;
diff --git a/src/Device/SetupProcessor.hpp b/src/Device/SetupProcessor.hpp
index 7001bce..d5b40f6 100644
--- a/src/Device/SetupProcessor.hpp
+++ b/src/Device/SetupProcessor.hpp
@@ -42,7 +42,8 @@
 			bool interpolateZ              : 1;
 			bool interpolateW              : 1;
 			bool perspective               : 1;
-			CullMode cullMode              : BITS(CULL_LAST);
+			bool frontFacingCCW            : 1;
+			VkCullModeFlags cullMode       : BITS(VK_CULL_MODE_FLAG_BITS_MAX_ENUM);
 			bool twoSidedStencil           : 1;
 			bool slopeDepthBias            : 1;
 			bool vFace                     : 1;