Primitives are discarded before rasterization if the rasterizerDiscardEnable member of afxPipelineRasterizationConfig is enabled. When enabled, primitives are discarded after they are processed by the last active shader stage in the pipeline before rasterization.
To dynamically enable whether primitives are discarded before the rasterization stage, call:
void AfxCmdEnableRasterizerDiscard ( afxDrawScript dscr, /// is the command buffer into which the command will be recorded. afxBool enabled /// controls whether primitives are discarded immediately before the rasterization stage. );
This command sets the discard enable for subsequent drawing commands when the graphics pipeline is created with VK_DYNAMIC_STATE_RASTERIZER_DISCARD_ENABLE set in VkPipelineDynamicStateCreateInfo::pDynamicStates. Otherwise, this state is specified by the VkPipelineRasterizationStateCreateInfo::rasterizerDiscardEnable value used to create the currently active pipeline.