From 45eb592c27677f05ede0633020a7561f6ad573c8 Mon Sep 17 00:00:00 2001 From: Owen Thompson Date: Mon, 30 Mar 2020 14:12:27 -0400 Subject: [PATCH] Matrix22 template constructor and make identity no longer use memset. Signed-off-by: Owen Thompson --- IlmBase/Imath/ImathMatrix.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/IlmBase/Imath/ImathMatrix.h b/IlmBase/Imath/ImathMatrix.h index 0c744041..b86b7970 100644 --- a/IlmBase/Imath/ImathMatrix.h +++ b/IlmBase/Imath/ImathMatrix.h @@ -1181,8 +1181,9 @@ template inline Matrix22::Matrix22 () { - memset (x, 0, sizeof (x)); x[0][0] = 1; + x[0][1] = 0; + x[1][0] = 0; x[1][1] = 1; } @@ -1326,8 +1327,9 @@ template inline void Matrix22::makeIdentity() { - memset (x, 0, sizeof (x)); x[0][0] = 1; + x[0][1] = 0; + x[1][0] = 0; x[1][1] = 1; }