diff options
author | Axel Davy <[email protected]> | 2018-09-23 16:45:30 +0200 |
---|---|---|
committer | Axel Davy <[email protected]> | 2018-10-26 22:16:16 +0200 |
commit | bbeddb801e0ad953a06862412ecd5b8bed51ab5c (patch) | |
tree | 6b3d13a5fbe6015d71f602f5fe40d60b1a28bd08 /src/gallium/state_trackers/nine | |
parent | a4e9bbb8f81f85f49d59dd472257ae3e034b91d9 (diff) |
st/nine: Mark transform matrices dirty for D3DSBT_ALL
D3DSBT_ALL stateblocks capture the transform matrices.
Fixes some d3d test programs not displaying properly.
Signed-off-by: Axel Davy <[email protected]>
Diffstat (limited to 'src/gallium/state_trackers/nine')
-rw-r--r-- | src/gallium/state_trackers/nine/device9.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/gallium/state_trackers/nine/device9.c b/src/gallium/state_trackers/nine/device9.c index 3b174587a44..25a8172b3fd 100644 --- a/src/gallium/state_trackers/nine/device9.c +++ b/src/gallium/state_trackers/nine/device9.c @@ -2376,13 +2376,24 @@ NineDevice9_CreateStateBlock( struct NineDevice9 *This, NINE_STATE_IDXBUF | NINE_STATE_FF_MATERIAL | NINE_STATE_BLEND_COLOR | - NINE_STATE_SAMPLE_MASK; + NINE_STATE_SAMPLE_MASK | + NINE_STATE_FF_VSTRANSF; memset(dst->changed.rs, ~0, (D3DRS_COUNT / 32) * sizeof(uint32_t)); dst->changed.rs[D3DRS_LAST / 32] |= (1 << (D3DRS_COUNT % 32)) - 1; dst->changed.vtxbuf = (1ULL << This->caps.MaxStreams) - 1; dst->changed.stream_freq = dst->changed.vtxbuf; dst->changed.ucp = (1 << PIPE_MAX_CLIP_PLANES) - 1; dst->changed.texture = (1 << NINE_MAX_SAMPLERS) - 1; + /* The doc says the projection, world, view and texture matrices + * are saved, which would translate to: + * dst->ff.changed.transform[0] = 0x00FF000C; + * dst->ff.changed.transform[D3DTS_WORLD / 32] |= 1 << (D3DTS_WORLD % 32); + * However we assume they meant save everything (which is basically just the + * above plus the other world matrices). + */ + dst->ff.changed.transform[0] = 0x00FF000C; + for (s = 0; s < 8; s++) + dst->ff.changed.transform[8+s] = ~0; } NineStateBlock9_Capture(NineStateBlock9(*ppSB)); |