/* gph-cmath - C graphics math library
- * Copyright (C) 2018 John Tsiombikas <nuclear@member.fsf.org>
+ * Copyright (C) 2018-2023 John Tsiombikas <nuclear@member.fsf.org>
*
* This program is free software. Feel free to use, modify, and/or redistribute
* it under the terms of the MIT/X11 license. See LICENSE for details.
return v;
}
+static CGM_INLINE void cgm_vneg(cgm_vec3 *v)
+{
+ v->x = -v->x;
+ v->y = -v->y;
+ v->z = -v->z;
+}
+
static CGM_INLINE void cgm_vadd(cgm_vec3 *a, const cgm_vec3 *b)
{
a->x += b->x;