[PATCH 1/5] wined3d: Optimize scanning changed texture states in wined3d_device_apply_stateblock().