Commit: c5433fdcb2a118df59cb9a5a48651a8fb61a0fd2
Author: ishbosamiya
Date:   Sun Sep 5 10:56:14 2021 +0530
Branches: soc-2021-adaptive-cloth
https://developer.blender.org/rBc5433fdcb2a118df59cb9a5a48651a8fb61a0fd2

float3x2: constructor through columns of the matrix

===================================================================

M       source/blender/blenlib/BLI_float3x2.hh

===================================================================

diff --git a/source/blender/blenlib/BLI_float3x2.hh 
b/source/blender/blenlib/BLI_float3x2.hh
index 4f672e1e96a..1b4731f701c 100644
--- a/source/blender/blenlib/BLI_float3x2.hh
+++ b/source/blender/blenlib/BLI_float3x2.hh
@@ -47,6 +47,17 @@ struct float3x2 {
   {
   }
 
+  float3x2(const float3 &col1, const float3 &col2)
+  {
+    this->ptr()[0][0] = col1[0];
+    this->ptr()[0][1] = col1[1];
+    this->ptr()[0][2] = col1[2];
+
+    this->ptr()[1][0] = col2[0];
+    this->ptr()[1][1] = col2[1];
+    this->ptr()[1][2] = col2[2];
+  }
+
   operator float *()
   {
     return &values[0][0];

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
List details, subscription details or unsubscribe:
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to