浏览代码

Add Quaternion._conjugate()

customisations
alemart 10 个月前
父节点
当前提交
ead82a413a
共有 1 个文件被更改,包括 14 次插入0 次删除
  1. 14
    0
      src/geometry/quaternion.ts

+ 14
- 0
src/geometry/quaternion.ts 查看文件

@@ -133,6 +133,20 @@ export class Quaternion
133 133
     }
134 134
 
135 135
     /**
136
+     * Conjugate this quaternion
137
+     * @returns this quaternion, conjugated
138
+     * @internal
139
+     */
140
+    _conjugate(): Quaternion
141
+    {
142
+        this.x = -this.x;
143
+        this.y = -this.y;
144
+        this.z = -this.z;
145
+
146
+        return this;
147
+    }
148
+
149
+    /**
136 150
      * Copy q to this
137 151
      * @param q a quaternion
138 152
      * @returns this quaternion

正在加载...
取消
保存