diff options
| author | Courtney Goeltzenleuchter <courtney@LunarG.com> | 2015-02-11 14:13:34 -0700 |
|---|---|---|
| committer | Courtney Goeltzenleuchter <courtney@LunarG.com> | 2015-02-17 10:20:49 -0700 |
| commit | 1710d8d2cd8b73668c19bec9cad34e40b2aa68f8 (patch) | |
| tree | 53c242eaa72124a61971db835b7a56e60568e78d /demos | |
| parent | 3ee56f121cce1c0d96fdc60566afa71db45413b0 (diff) | |
| download | usermoji-1710d8d2cd8b73668c19bec9cad34e40b2aa68f8.tar.xz | |
intel: Remove scissor enable and scissor count
bug #12925
header version: r29511
Remove separate scissor enable and scissor count. Scissor always
enabled and must always provide scissor rect for every viewport.
Diffstat (limited to 'demos')
| -rw-r--r-- | demos/cube.c | 9 | ||||
| -rw-r--r-- | demos/tri.c | 11 |
2 files changed, 15 insertions, 5 deletions
diff --git a/demos/cube.c b/demos/cube.c index 42a95709..1e961a78 100644 --- a/demos/cube.c +++ b/demos/cube.c @@ -1142,7 +1142,6 @@ static void demo_prepare_pipeline(struct demo *demo) memset(&vp, 0, sizeof(vp)); vp.sType = XGL_STRUCTURE_TYPE_PIPELINE_VP_STATE_CREATE_INFO; - vp.scissorEnable = XGL_FALSE; memset(&ds, 0, sizeof(ds)); ds.sType = XGL_STRUCTURE_TYPE_PIPELINE_DS_STATE_CREATE_INFO; @@ -1201,13 +1200,19 @@ static void demo_prepare_dynamic_states(struct demo *demo) memset(&viewport_create, 0, sizeof(viewport_create)); viewport_create.sType = XGL_STRUCTURE_TYPE_DYNAMIC_VP_STATE_CREATE_INFO; - viewport_create.viewportCount = 1; + viewport_create.viewportAndScissorCount = 1; XGL_VIEWPORT viewport; + XGL_RECT scissor; viewport.height = (float) demo->height; viewport.width = (float) demo->width; viewport.minDepth = (float) 0.0f; viewport.maxDepth = (float) 1.0f; + scissor.extent.width = demo->width; + scissor.extent.height = demo->height; + scissor.offset.x = 0; + scissor.offset.y = 0; viewport_create.pViewports = &viewport; + viewport_create.pScissors = &scissor; memset(&raster, 0, sizeof(raster)); raster.sType = XGL_STRUCTURE_TYPE_DYNAMIC_RS_STATE_CREATE_INFO; diff --git a/demos/tri.c b/demos/tri.c index 74ba8951..3cfb86d9 100644 --- a/demos/tri.c +++ b/demos/tri.c @@ -757,7 +757,6 @@ static void demo_prepare_pipeline(struct demo *demo) memset(&vp, 0, sizeof(vp)); vp.sType = XGL_STRUCTURE_TYPE_PIPELINE_VP_STATE_CREATE_INFO; - vp.scissorEnable = XGL_FALSE; memset(&ds, 0, sizeof(ds)); @@ -817,14 +816,20 @@ static void demo_prepare_dynamic_states(struct demo *demo) memset(&viewport_create, 0, sizeof(viewport_create)); viewport_create.sType = XGL_STRUCTURE_TYPE_DYNAMIC_VP_STATE_CREATE_INFO; - viewport_create.viewportCount = 1; + viewport_create.viewportAndScissorCount = 1; XGL_VIEWPORT viewport; + XGL_RECT scissor; memset(&viewport, 0, sizeof(viewport)); - viewport.width = (float) demo->width; viewport.height = (float) demo->height; + viewport.width = (float) demo->width; viewport.minDepth = (float) 0.0f; viewport.maxDepth = (float) 1.0f; + scissor.extent.width = demo->width; + scissor.extent.height = demo->height; + scissor.offset.x = 0; + scissor.offset.y = 0; viewport_create.pViewports = &viewport; + viewport_create.pScissors = &scissor; memset(&raster, 0, sizeof(raster)); raster.sType = XGL_STRUCTURE_TYPE_DYNAMIC_RS_STATE_CREATE_INFO; |
