Skip to content

Commit

Permalink
Don't truncate spline/bezier through mode
Browse files Browse the repository at this point in the history
Don't truncate the through mode bit in the vertex type during
normalization. Normalization is used to convert different vertex types
to a singular normalized one but the through-mode bit should be preserved.

This only affects (fixes) spline and bezier draw commands. The only thing
that was broken was games that drew splines/beziers with through-mode and
have matricies that differ significantly from the identity (didn't load
identity before drawing).

This should not break anything and fix hrydgard#5087 .
  • Loading branch information
Bigpet committed Jan 19, 2014
1 parent 9980462 commit 2f7243b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion GPU/GLES/Spline.cpp
Expand Up @@ -124,7 +124,7 @@ u32 TransformDrawEngine::NormalizeVertices(u8 *outPtr, u8 *bufPtr, const u8 *inP
}

// Okay, there we are! Return the new type (but keep the index bits)
return GE_VTYPE_TC_FLOAT | GE_VTYPE_COL_8888 | GE_VTYPE_NRM_FLOAT | GE_VTYPE_POS_FLOAT | (vertType & GE_VTYPE_IDX_MASK);
return GE_VTYPE_TC_FLOAT | GE_VTYPE_COL_8888 | GE_VTYPE_NRM_FLOAT | GE_VTYPE_POS_FLOAT | (vertType & (GE_VTYPE_IDX_MASK | GE_VTYPE_THROUGH));
}

u32 TransformDrawEngine::NormalizeVertices(u8 *outPtr, u8 *bufPtr, const u8 *inPtr, int lowerBound, int upperBound, u32 vertType) {
Expand Down

0 comments on commit 2f7243b

Please sign in to comment.