mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-03 13:40:11 +01:00
st/nine: Catch redundant SetStreamSourceFreq calls
Some apps do redundant SetStreamSourceFreq calls. Catch them to improve performance. Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
This commit is contained in:
parent
ea3f504f7c
commit
15ce2778fb
1 changed files with 3 additions and 0 deletions
|
|
@ -3555,6 +3555,9 @@ NineDevice9_SetStreamSourceFreq( struct NineDevice9 *This,
|
|||
(Setting & D3DSTREAMSOURCE_INDEXEDDATA)), D3DERR_INVALIDCALL);
|
||||
user_assert(Setting, D3DERR_INVALIDCALL);
|
||||
|
||||
if (likely(!This->is_recording) && state->stream_freq[StreamNumber] == Setting)
|
||||
return D3D_OK;
|
||||
|
||||
state->stream_freq[StreamNumber] = Setting;
|
||||
|
||||
if (Setting & D3DSTREAMSOURCE_INSTANCEDATA)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue