2d: add translate2d and its friends

This commit is contained in:
Recep Aslantas
2020-07-31 11:40:52 +03:00
parent 6dc37f6cc9
commit bb751d32ca
6 changed files with 186 additions and 3 deletions

39
src/affine2d.c Normal file
View File

@@ -0,0 +1,39 @@
/*
* Copyright (c), Recep Aslantas.
*
* MIT License (MIT), http://opensource.org/licenses/MIT
* Full license can be found in the LICENSE file
*/
#include "../include/cglm/cglm.h"
#include "../include/cglm/call.h"
CGLM_EXPORT
void
glmc_translate2d_make(mat3 m, vec2 v) {
glm_translate2d_make(m, v);
}
CGLM_EXPORT
void
glmc_translate2d_to(mat3 m, vec2 v, mat3 dest) {
glm_translate2d_to(m, v, dest);
}
CGLM_EXPORT
void
glmc_translate2d(mat3 m, vec2 v) {
glm_translate2d(m, v);
}
CGLM_EXPORT
void
glmc_translate2d_x(mat3 m, float to) {
glm_translate2d_x(m, to);
}
CGLM_EXPORT
void
glmc_translate2d_y(mat3 m, float to) {
glm_translate2d_y(m, to);
}