/** * Free the context matrix data. * * \param ctx GL context. * * Frees each of the matrix stacks and the combined modelview-projection * matrix. */ void _mesa_free_matrix_data( struct gl_context *ctx ) { GLuint i; free_matrix_stack(&ctx->ModelviewMatrixStack); free_matrix_stack(&ctx->ProjectionMatrixStack); for (i = 0; i < ARRAY_SIZE(ctx->TextureMatrixStack); i++) free_matrix_stack(&ctx->TextureMatrixStack[i]); for (i = 0; i < ARRAY_SIZE(ctx->ProgramMatrixStack); i++) free_matrix_stack(&ctx->ProgramMatrixStack[i]); /* combined Modelview*Projection matrix */ _math_matrix_dtr( &ctx->_ModelProjectMatrix ); }
/** * Free the context matrix data. * * \param ctx GL context. * * Frees each of the matrix stacks and the combined modelview-projection * matrix. */ void _mesa_free_matrix_data( GLcontext *ctx ) { GLint i; free_matrix_stack(&ctx->ModelviewMatrixStack); free_matrix_stack(&ctx->ProjectionMatrixStack); free_matrix_stack(&ctx->ColorMatrixStack); for (i = 0; i < MAX_TEXTURE_UNITS; i++) free_matrix_stack(&ctx->TextureMatrixStack[i]); for (i = 0; i < MAX_PROGRAM_MATRICES; i++) free_matrix_stack(&ctx->ProgramMatrixStack[i]); /* combined Modelview*Projection matrix */ _math_matrix_dtr( &ctx->_ModelProjectMatrix ); }