Corrects an error in the _m3xm3 shader function in pixel and vertex

shaders.
This commit is contained in:
Oliver Stieber 2005-11-22 15:01:55 +00:00 committed by Alexandre Julliard
parent fd2004e52f
commit 30ad95b6cd
2 changed files with 4 additions and 4 deletions

View File

@ -373,8 +373,8 @@ void pshader_m3x4(WINED3DSHADERVECTOR* d, WINED3DSHADERVECTOR* s0, D3DMATRIX34 m
}
void pshader_m3x3(WINED3DSHADERVECTOR* d, WINED3DSHADERVECTOR* s0, D3DMATRIX33 mat) {
d->x = mat[0][0] * s0->x + mat[0][1] * s0->y + mat[2][2] * s0->z;
d->y = mat[1][0] * s0->x + mat[1][1] * s0->y + mat[2][2] * s0->z;
d->x = mat[0][0] * s0->x + mat[0][1] * s0->y + mat[0][2] * s0->z;
d->y = mat[1][0] * s0->x + mat[1][1] * s0->y + mat[1][2] * s0->z;
d->z = mat[2][0] * s0->x + mat[2][1] * s0->y + mat[2][2] * s0->z;
d->w = 1.0f;
PSTRACE(("executing m3x3(1): mat=(%f, %f, %f) s0=(%f) d=(%f) \n", mat[0][0], mat[0][1], mat[0][2], s0->x, d->x));

View File

@ -325,8 +325,8 @@ void vshader_m3x4(WINED3DSHADERVECTOR* d, WINED3DSHADERVECTOR* s0, D3DMATRIX34 m
}
void vshader_m3x3(WINED3DSHADERVECTOR* d, WINED3DSHADERVECTOR* s0, D3DMATRIX33 mat) {
d->x = mat[0][0] * s0->x + mat[0][1] * s0->y + mat[2][2] * s0->z;
d->y = mat[1][0] * s0->x + mat[1][1] * s0->y + mat[2][2] * s0->z;
d->x = mat[0][0] * s0->x + mat[0][1] * s0->y + mat[0][2] * s0->z;
d->y = mat[1][0] * s0->x + mat[1][1] * s0->y + mat[1][2] * s0->z;
d->z = mat[2][0] * s0->x + mat[2][1] * s0->y + mat[2][2] * s0->z;
d->w = 1.0f;
VSTRACE(("executing m3x3(1): mat=(%f, %f, %f) s0=(%f) d=(%f) \n", mat[0][0], mat[0][1], mat[0][2], s0->x, d->x));