1
0
Fork 0

include/Spectre/Math/Matrix4.inl: gcc complains about multiple definitions of Identity. just template the type instead of only allow float.

This commit is contained in:
Henrik Hautakoski 2019-06-01 20:39:06 +02:00
parent ffe75049d0
commit 9da8addeb2

View file

@ -4,12 +4,12 @@
#include <string.h>
#include "Matrix4.h"
template<>
const Matrix4f Matrix4f::Identity(
1.0f, 0.0f, 0.0f, 0.0f,
0.0f, 1.0f, 0.0f, 0.0f,
0.0f, 0.0f, 1.0f, 0.0f,
0.0f, 0.0f, 0.0f, 1.0f
template<typename T>
const Matrix4<T> Matrix4<T>::Identity(
1, 0, 0, 0,
0, 1, 0, 0,
0, 0, 1, 0,
0, 0, 0, 1
);
template<typename T>