mirror of
https://github.com/recp/cglm.git
synced 2026-11-17 18:17:13 -06:00
- Adds `const` qualifiers to read-only pointer and array parameters. - Multi-dimentional array parameters use the `CGLM_CONST` macro instead, because for these `const` only works in C++ and C23 (with N2607). - For `glm_mat4_mulN`, the matrices are not const-qualified although they are read-only, but changing the pointer type would require changing application code. - Incorrect incorrect in/out in doc comments was fixed for `glm_ray_sphere`, `glm_swapf`, `glm_quat_rotate_at`.
68 lines
1.1 KiB
C
68 lines
1.1 KiB
C
/*
|
|
* Copyright (c), Recep Aslantas.
|
|
*
|
|
* MIT License (MIT), http://opensource.org/licenses/MIT
|
|
* Full license can be found in the LICENSE file
|
|
*/
|
|
|
|
#ifndef cglmc_affine2d_h
|
|
#define cglmc_affine2d_h
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
#include "../common.h"
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_translate2d_make(mat3 m, const vec2 v);
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_translate2d_to(CGLM_CONST mat3 m, const vec2 v, mat3 dest);
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_translate2d(mat3 m, const vec2 v);
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_translate2d_x(mat3 m, float to);
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_translate2d_y(mat3 m, float to);
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_scale2d_to(CGLM_CONST mat3 m, const vec2 v, mat3 dest);
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_scale2d_make(mat3 m, const vec2 v);
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_scale2d(mat3 m, const vec2 v);
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_scale2d_uni(mat3 m, float s);
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_rotate2d_make(mat3 m, float angle);
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_rotate2d(mat3 m, float angle);
|
|
|
|
CGLM_EXPORT
|
|
void
|
|
glmc_rotate2d_to(CGLM_CONST mat3 m, float angle, mat3 dest);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
#endif /* cglmc_affine2d_h */
|