OpenGL: add gpuMatrixUpdate_legacy function
Marks matrix state as dirty so shader will use the latest values from glScale, glTranslate, etc. We'll remove this after transitioning 100% to the new matrix API, which handles this sort of thing automatically. Part of T49450
This commit is contained in:
parent
d23c57b84c
commit
97fa285ae1
|
@ -133,6 +133,9 @@ const float *gpuGetNormalMatrixInverse(float m[3][3]);
|
|||
#if SUPPORT_LEGACY_MATRIX
|
||||
/* copy top matrix from each legacy stack into new fresh stack */
|
||||
void gpuMatrixBegin3D_legacy(void);
|
||||
|
||||
/* call after using glScale, glTranslate, etc. between draw calls */
|
||||
void gpuMatrixUpdate_legacy(void);
|
||||
#endif
|
||||
|
||||
|
||||
|
|
|
@ -699,3 +699,11 @@ bool gpuMatricesDirty()
|
|||
{
|
||||
return state.dirty;
|
||||
}
|
||||
|
||||
#if SUPPORT_LEGACY_MATRIX
|
||||
void gpuMatrixUpdate_legacy()
|
||||
{
|
||||
BLI_assert(state.mode == MATRIX_MODE_INACTIVE);
|
||||
state.dirty = true;
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue