(other)
| 1433 | return new Matrix4(matrix4add(this.ptr, other.ptr)); |
| 1434 | } |
| 1435 | sub(other) { |
| 1436 | if (typeof other === "number") { |
| 1437 | return new Matrix4(this.x.sub(other), this.y.sub(other), this.z.sub(other), this.w.sub(other)); |
| 1438 | } |
| 1439 | return new Matrix4(matrix4sub(this.ptr, other.ptr)); |
| 1440 | } |
| 1441 | mul(other) { |
| 1442 | if (typeof other === "number") { |
| 1443 | return new Matrix4(this.x.mul(other), this.y.mul(other), this.z.mul(other), this.w.mul(other)); |