wined3d: wined3d_device_multiply_transform() never fails.
This commit is contained in:
parent
bf23df7980
commit
90bd04c6b6
|
@ -1291,16 +1291,15 @@ static HRESULT WINAPI d3d8_device_MultiplyTransform(IDirect3DDevice8 *iface,
|
|||
D3DTRANSFORMSTATETYPE state, const D3DMATRIX *matrix)
|
||||
{
|
||||
struct d3d8_device *device = impl_from_IDirect3DDevice8(iface);
|
||||
HRESULT hr;
|
||||
|
||||
TRACE("iface %p, state %#x, matrix %p.\n", iface, state, matrix);
|
||||
|
||||
/* Note: D3DMATRIX is compatible with struct wined3d_matrix. */
|
||||
wined3d_mutex_lock();
|
||||
hr = wined3d_device_multiply_transform(device->wined3d_device, state, (const struct wined3d_matrix *)matrix);
|
||||
wined3d_device_multiply_transform(device->wined3d_device, state, (const struct wined3d_matrix *)matrix);
|
||||
wined3d_mutex_unlock();
|
||||
|
||||
return hr;
|
||||
return D3D_OK;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI d3d8_device_SetViewport(IDirect3DDevice8 *iface, const D3DVIEWPORT8 *viewport)
|
||||
|
|
|
@ -1357,16 +1357,15 @@ static HRESULT WINAPI d3d9_device_MultiplyTransform(IDirect3DDevice9Ex *iface,
|
|||
D3DTRANSFORMSTATETYPE state, const D3DMATRIX *matrix)
|
||||
{
|
||||
struct d3d9_device *device = impl_from_IDirect3DDevice9Ex(iface);
|
||||
HRESULT hr;
|
||||
|
||||
TRACE("iface %p, state %#x, matrix %p.\n", iface, state, matrix);
|
||||
|
||||
/* Note: D3DMATRIX is compatible with struct wined3d_matrix. */
|
||||
wined3d_mutex_lock();
|
||||
hr = wined3d_device_multiply_transform(device->wined3d_device, state, (const struct wined3d_matrix *)matrix);
|
||||
wined3d_device_multiply_transform(device->wined3d_device, state, (const struct wined3d_matrix *)matrix);
|
||||
wined3d_mutex_unlock();
|
||||
|
||||
return hr;
|
||||
return D3D_OK;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI d3d9_device_SetViewport(IDirect3DDevice9Ex *iface, const D3DVIEWPORT9 *viewport)
|
||||
|
|
|
@ -3299,7 +3299,6 @@ static HRESULT d3d_device7_MultiplyTransform(IDirect3DDevice7 *iface,
|
|||
{
|
||||
struct d3d_device *device = impl_from_IDirect3DDevice7(iface);
|
||||
enum wined3d_transform_state wined3d_state;
|
||||
HRESULT hr;
|
||||
|
||||
TRACE("iface %p, state %#x, matrix %p.\n", iface, state, matrix);
|
||||
|
||||
|
@ -3323,11 +3322,11 @@ static HRESULT d3d_device7_MultiplyTransform(IDirect3DDevice7 *iface,
|
|||
|
||||
/* Note: D3DMATRIX is compatible with struct wined3d_matrix. */
|
||||
wined3d_mutex_lock();
|
||||
hr = wined3d_device_multiply_transform(device->wined3d_device,
|
||||
wined3d_device_multiply_transform(device->wined3d_device,
|
||||
wined3d_state, (struct wined3d_matrix *)matrix);
|
||||
wined3d_mutex_unlock();
|
||||
|
||||
return hr;
|
||||
return D3D_OK;
|
||||
}
|
||||
|
||||
static HRESULT WINAPI d3d_device7_MultiplyTransform_FPUSetup(IDirect3DDevice7 *iface,
|
||||
|
|
|
@ -1763,10 +1763,10 @@ void CDECL wined3d_device_get_transform(const struct wined3d_device *device,
|
|||
*matrix = device->stateBlock->state.transforms[state];
|
||||
}
|
||||
|
||||
HRESULT CDECL wined3d_device_multiply_transform(struct wined3d_device *device,
|
||||
void CDECL wined3d_device_multiply_transform(struct wined3d_device *device,
|
||||
enum wined3d_transform_state state, const struct wined3d_matrix *matrix)
|
||||
{
|
||||
const struct wined3d_matrix *mat = NULL;
|
||||
const struct wined3d_matrix *mat;
|
||||
struct wined3d_matrix temp;
|
||||
|
||||
TRACE("device %p, state %s, matrix %p.\n", device, debug_d3dtstype(state), matrix);
|
||||
|
@ -1778,7 +1778,7 @@ HRESULT CDECL wined3d_device_multiply_transform(struct wined3d_device *device,
|
|||
if (state > HIGHEST_TRANSFORMSTATE)
|
||||
{
|
||||
WARN("Unhandled transform state %#x.\n", state);
|
||||
return WINED3D_OK;
|
||||
return;
|
||||
}
|
||||
|
||||
mat = &device->updateStateBlock->state.transforms[state];
|
||||
|
@ -1786,8 +1786,6 @@ HRESULT CDECL wined3d_device_multiply_transform(struct wined3d_device *device,
|
|||
|
||||
/* Apply change via set transform - will reapply to eg. lights this way. */
|
||||
wined3d_device_set_transform(device, state, &temp);
|
||||
|
||||
return WINED3D_OK;
|
||||
}
|
||||
|
||||
/* Note lights are real special cases. Although the device caps state only
|
||||
|
|
|
@ -2177,7 +2177,7 @@ HRESULT __cdecl wined3d_device_get_vs_consts_i(const struct wined3d_device *devi
|
|||
ULONG __cdecl wined3d_device_incref(struct wined3d_device *device);
|
||||
HRESULT __cdecl wined3d_device_init_3d(struct wined3d_device *device, struct wined3d_swapchain_desc *swapchain_desc);
|
||||
HRESULT __cdecl wined3d_device_init_gdi(struct wined3d_device *device, struct wined3d_swapchain_desc *swapchain_desc);
|
||||
HRESULT __cdecl wined3d_device_multiply_transform(struct wined3d_device *device,
|
||||
void __cdecl wined3d_device_multiply_transform(struct wined3d_device *device,
|
||||
enum wined3d_transform_state state, const struct wined3d_matrix *matrix);
|
||||
HRESULT __cdecl wined3d_device_present(const struct wined3d_device *device, const RECT *src_rect,
|
||||
const RECT *dst_rect, HWND dst_window_override, const RGNDATA *dirty_region, DWORD flags);
|
||||
|
|
Loading…
Reference in New Issue