Blender V4.5
domain.cc
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2023 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
5#include "BLI_math_matrix.hh"
8
9#include "COM_domain.hh"
10
11namespace blender::compositor {
12
14
19
20void Domain::transform(const float3x3 &input_transformation)
21{
22 transformation = input_transformation * transformation;
23}
24
29
30bool Domain::is_equal(const Domain &a, const Domain &b, const float epsilon)
31{
32 return a.size == b.size && math::is_equal(a.transformation, b.transformation, epsilon);
33}
34
35bool operator==(const Domain &a, const Domain &b)
36{
37 return a.size == b.size && a.transformation == b.transformation;
38}
39
40bool operator!=(const Domain &a, const Domain &b)
41{
42 return !(a == b);
43}
44
45} // namespace blender::compositor
Domain(const int2 &size)
Definition domain.cc:13
static bool is_equal(const Domain &a, const Domain &b, const float epsilon=0.0f)
Definition domain.cc:30
void transform(const float3x3 &input_transformation)
Definition domain.cc:20
static Domain identity()
Definition domain.cc:25
bool operator==(const BokehKernelKey &a, const BokehKernelKey &b)
bool operator!=(const Domain &a, const Domain &b)
Definition domain.cc:40
bool is_equal(const MatBase< T, NumCol, NumRow > &a, const MatBase< T, NumCol, NumRow > &b, const T epsilon=T(0))
VecBase< int32_t, 2 > int2
MatBase< float, 3, 3 > float3x3