zink: pass zink_render_pass to pipeline-creation
Acked-by: Jordan Justen <jordan.l.justen@intel.com>
This commit is contained in:
@@ -798,7 +798,7 @@ zink_draw_vbo(struct pipe_context *pctx,
|
|||||||
VkPipeline pipeline = zink_create_gfx_pipeline(screen->dev,
|
VkPipeline pipeline = zink_create_gfx_pipeline(screen->dev,
|
||||||
gfx_program,
|
gfx_program,
|
||||||
&ctx->gfx_pipeline_state,
|
&ctx->gfx_pipeline_state,
|
||||||
ctx->render_pass->render_pass);
|
ctx->render_pass);
|
||||||
|
|
||||||
bool depth_bias = false;
|
bool depth_bias = false;
|
||||||
switch (u_reduced_prim(dinfo->mode)) {
|
switch (u_reduced_prim(dinfo->mode)) {
|
||||||
|
@@ -26,6 +26,7 @@
|
|||||||
#include "zink_compiler.h"
|
#include "zink_compiler.h"
|
||||||
#include "zink_context.h"
|
#include "zink_context.h"
|
||||||
#include "zink_program.h"
|
#include "zink_program.h"
|
||||||
|
#include "zink_render_pass.h"
|
||||||
#include "zink_screen.h"
|
#include "zink_screen.h"
|
||||||
#include "zink_state.h"
|
#include "zink_state.h"
|
||||||
|
|
||||||
@@ -35,7 +36,7 @@
|
|||||||
VkPipeline
|
VkPipeline
|
||||||
zink_create_gfx_pipeline(VkDevice dev, struct zink_gfx_program *prog,
|
zink_create_gfx_pipeline(VkDevice dev, struct zink_gfx_program *prog,
|
||||||
struct zink_gfx_pipeline_state *state,
|
struct zink_gfx_pipeline_state *state,
|
||||||
VkRenderPass render_pass)
|
struct zink_render_pass *rp)
|
||||||
{
|
{
|
||||||
VkPipelineVertexInputStateCreateInfo vertex_input_state = {};
|
VkPipelineVertexInputStateCreateInfo vertex_input_state = {};
|
||||||
vertex_input_state.sType = VK_STRUCTURE_TYPE_PIPELINE_VERTEX_INPUT_STATE_CREATE_INFO;
|
vertex_input_state.sType = VK_STRUCTURE_TYPE_PIPELINE_VERTEX_INPUT_STATE_CREATE_INFO;
|
||||||
@@ -113,7 +114,7 @@ zink_create_gfx_pipeline(VkDevice dev, struct zink_gfx_program *prog,
|
|||||||
pci.sType = VK_STRUCTURE_TYPE_GRAPHICS_PIPELINE_CREATE_INFO;
|
pci.sType = VK_STRUCTURE_TYPE_GRAPHICS_PIPELINE_CREATE_INFO;
|
||||||
pci.flags = VK_PIPELINE_CREATE_DISABLE_OPTIMIZATION_BIT;
|
pci.flags = VK_PIPELINE_CREATE_DISABLE_OPTIMIZATION_BIT;
|
||||||
pci.layout = prog->layout;
|
pci.layout = prog->layout;
|
||||||
pci.renderPass = render_pass;
|
pci.renderPass = rp->render_pass;
|
||||||
pci.pVertexInputState = &vertex_input_state;
|
pci.pVertexInputState = &vertex_input_state;
|
||||||
pci.pInputAssemblyState = &primitive_state;
|
pci.pInputAssemblyState = &primitive_state;
|
||||||
pci.pRasterizationState = &rast_state;
|
pci.pRasterizationState = &rast_state;
|
||||||
|
@@ -32,7 +32,7 @@ struct zink_blend_state;
|
|||||||
struct zink_depth_stencil_alpha_state;
|
struct zink_depth_stencil_alpha_state;
|
||||||
struct zink_gfx_program;
|
struct zink_gfx_program;
|
||||||
struct zink_rasterizer_state;
|
struct zink_rasterizer_state;
|
||||||
struct zink_shader;
|
struct zink_render_pass;
|
||||||
struct zink_vertex_elements_state;
|
struct zink_vertex_elements_state;
|
||||||
|
|
||||||
struct zink_gfx_pipeline_state {
|
struct zink_gfx_pipeline_state {
|
||||||
@@ -54,6 +54,6 @@ struct zink_gfx_pipeline_state {
|
|||||||
VkPipeline
|
VkPipeline
|
||||||
zink_create_gfx_pipeline(VkDevice dev, struct zink_gfx_program *prog,
|
zink_create_gfx_pipeline(VkDevice dev, struct zink_gfx_program *prog,
|
||||||
struct zink_gfx_pipeline_state *state,
|
struct zink_gfx_pipeline_state *state,
|
||||||
VkRenderPass render_pass);
|
struct zink_render_pass *rp);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
Reference in New Issue
Block a user