/foundation/arkui/ace_engine/frameworks/base/utils/ |
H A D | utils.h | 138 inline bool NearEqual(const double left, const double right, const double epsilon) in NearEqual() argument 140 return (std::abs(left - right) <= epsilon); in NearEqual() 149 constexpr double epsilon = 0.001f; in NearEqual() local 150 return NearEqual(left, right, epsilon); in NearEqual() 156 constexpr double epsilon = 0.00001f; in NearEqual() local 157 return NearEqual(left, right, epsilon); in NearEqual() 166 inline bool NearZero(const double value, const double epsilon) in NearZero() argument 168 return NearEqual(value, 0.0, epsilon); in NearZero() 173 constexpr double epsilon = 0.001f; in NearEqual() local 174 return NearEqual(left, right, epsilon); in NearEqual() 179 constexpr double epsilon = 0.001f; NearZero() local 185 constexpr double epsilon = 0.001f; LessOrEqual() local 196 constexpr double epsilon = -0.001f; LessNotEqual() local 207 constexpr double epsilon = -0.001f; GreatOrEqual() local 218 constexpr double epsilon = 0.001f; GreatNotEqual() local 229 constexpr double epsilon = 0.001f; Round() local [all...] |
/foundation/multimodalinput/input/util/common/include/ |
H A D | util.h | 113 return (std::abs((x) - (y)) <= (std::numeric_limits<T>::epsilon())); in MMI_EQ() 120 inline bool MMI_EQ(T x, T y, T epsilon) in MMI_EQ() argument 122 return (std::abs((x) - (y)) <= (epsilon)); in MMI_EQ() 133 constexpr float epsilon = -0.001f; in MMI_LNE() local 134 return (left - right) < epsilon; in MMI_LNE() 139 constexpr float epsilon = 0.001f; in MMI_GNE() local 140 return (left - right) > epsilon; in MMI_GNE() 145 constexpr float epsilon = -0.001f; in MMI_GE() local 146 return (left - right) > epsilon; in MMI_GE() 151 constexpr float epsilon in MMI_LE() local [all...] |
/foundation/arkui/ace_engine/frameworks/base/geometry/ |
H A D | transform_util.h | 28 constexpr double epsilon = 0.000001; member 49 return NearEqual(scaleX, other.scaleX, epsilon) && NearEqual(scaleY, other.scaleY, epsilon) && in operator ==() 50 NearEqual(scaleZ, other.scaleZ, epsilon); in operator ==() 64 return NearEqual(skewX, other.skewX, epsilon) && NearEqual(skewY, other.skewY, epsilon); in operator ==() 77 return NearEqual(dx, other.dx, epsilon) && NearEqual(dy, other.dy, epsilon) && in operator ==() 78 NearEqual(dz, other.dz, epsilon) && NearEqual(angle, other.angle, epsilon); in operator ==() [all...] |
H A D | transform_util.cpp | 58 if (NearZero(m.Get(3, 3), epsilon)) { in Normalize() 87 if (NearZero(dx, epsilon) && NearZero(dy, epsilon) && NearZero(dz, epsilon)) { in BuildTranslationMatrix() 217 if (NearZero(ret.dx, epsilon) && NearZero(ret.dy, epsilon) && NearZero(ret.dz, epsilon)) { in Blend() 485 if (!NearZero(matrix.Get(3, 0), epsilon) || !NearZero(matrix.Get(3, 1), epsilon) || in ProcessMatrix() 486 !NearZero(matrix.Get(3, 2), epsilon)) { in ProcessMatrix() [all...] |
/foundation/graphic/graphic_2d/rosen/modules/render_service_base/include/common/ |
H A D | rs_common_def.h | 346 return (std::abs((x) - (y)) <= (std::numeric_limits<T>::epsilon())); in ROSEN_EQ() 353 inline bool ROSEN_EQ(T x, T y, T epsilon) in ROSEN_EQ() argument 355 return (std::abs((x) - (y)) <= (epsilon)); in ROSEN_EQ() 366 constexpr float epsilon = -0.001f; in ROSEN_LNE() local 367 return (left - right) < epsilon; in ROSEN_LNE() 372 constexpr float epsilon = 0.001f; in ROSEN_GNE() local 373 return (left - right) > epsilon; in ROSEN_GNE() 378 constexpr float epsilon = -0.001f; in ROSEN_GE() local 379 return (left - right) > epsilon; in ROSEN_GE() 384 constexpr float epsilon in ROSEN_LE() local [all...] |
/foundation/graphic/graphic_3d/lume/metaobject/src/curves/ |
H A D | bezier_curve.cpp | 61 constexpr bool IsFloatNull(float v, float epsilon) noexcept 63 return BASE_NS::Math::abs(v) < epsilon; 69 static constexpr float epsilon = 0.001f; variable 84 if (x = GetX(tt) - t; IsFloatNull(x, epsilon)) { 98 if (x = GetX(tt); IsFloatNull(x - t, epsilon)) {
|
/foundation/graphic/graphic_3d/lume/metaobject/test/src/ |
H A D | test_utils.cpp | 103 bool AreEqual(const BASE_NS::Math::Vec3& lhs, const BASE_NS::Math::Vec3& rhs, float epsilon) in AreEqual() argument 105 return BASE_NS::Math::abs(lhs.x - rhs.x) < epsilon && BASE_NS::Math::abs(lhs.y - rhs.y) < epsilon && in AreEqual() 106 BASE_NS::Math::abs(lhs.z - rhs.z) < epsilon; in AreEqual() 114 bool AreEqual(const BASE_NS::Math::Vec2& lhs, const BASE_NS::Math::Vec2& rhs, float epsilon) in AreEqual() argument 116 return BASE_NS::Math::abs(lhs.x - rhs.x) < epsilon && BASE_NS::Math::abs(lhs.y - rhs.y) < epsilon; in AreEqual()
|
/foundation/window/window_manager/window_scene/interfaces/include/ |
H A D | ws_common.h | 422 constexpr double epsilon = -0.00001f; in GreatOrEqual() local 423 return (left - right) > epsilon; in GreatOrEqual() 428 constexpr double epsilon = 0.00001f; in LessOrEqual() local 429 return (left - right) < epsilon; in LessOrEqual() 432 inline bool NearEqual(const double left, const double right, const double epsilon) in NearEqual() argument 434 return (std::fabs(left - right) <= epsilon); in NearEqual() 439 constexpr double epsilon = 0.001f; in NearEqual() local 440 return NearEqual(left, right, epsilon); in NearEqual() 450 constexpr double epsilon = 0.001f; in NearZero() local 451 return NearEqual(left, 0.0, epsilon); in NearZero() [all...] |
/foundation/multimedia/audio_framework/services/audio_service/common/include/ |
H A D | volume_tools.h | 33 static inline bool IsVolumeSame(const float& x, const float& y, const float& epsilon) in IsVolumeSame() argument 35 return (std::abs((x) - (y)) <= std::abs(epsilon)); in IsVolumeSame()
|
/foundation/graphic/graphic_2d/rosen/modules/render_service_base/include/render/ |
H A D | rs_light_up_effect_filter.h | 41 const std::shared_ptr<RSFilter>& other, float threshold = std::numeric_limits<float>::epsilon()) const override; 42 bool IsNearZero(float threshold = std::numeric_limits<float>::epsilon()) const override;
|
H A D | rs_blur_filter.h | 55 const std::shared_ptr<RSFilter>& other, float threshold = std::numeric_limits<float>::epsilon()) const override; 56 bool IsNearZero(float threshold = std::numeric_limits<float>::epsilon()) const override;
|
H A D | rs_filter.h | 101 const std::shared_ptr<RSFilter>& other, float threshold = std::numeric_limits<float>::epsilon()) const in IsNearEqual() 106 virtual bool IsNearZero(float threshold = std::numeric_limits<float>::epsilon()) const in IsNearZero()
|
H A D | rs_material_filter.h | 90 const std::shared_ptr<RSFilter>& other, float threshold = std::numeric_limits<float>::epsilon()) const override;
91 bool IsNearZero(float threshold = std::numeric_limits<float>::epsilon()) const override;
|
/foundation/graphic/graphic_2d/rosen/modules/render_service_base/src/render/ |
H A D | rs_colorful_shadow_filter.cpp | 38 constexpr float epsilon = 0.999f; // if blur radius less than 1, do not need to draw in IsValid() local 39 return blurRadius_ > epsilon; in IsValid()
|
H A D | rs_blur_filter.cpp | 70 constexpr float epsilon = 0.999f; in IsValid() local 71 return blurRadiusX_ > epsilon || blurRadiusY_ > epsilon; in IsValid()
|
/foundation/graphic/graphic_utils_lite/frameworks/ |
H A D | trans_affine.cpp | 90 bool TransAffine::IsValid(float epsilon) const in IsValid() 92 return (MATH_ABS(data_[0]) > epsilon) && (MATH_ABS(data_[4]) > epsilon); in IsValid()
|
/foundation/multimedia/camera_framework/frameworks/native/camera/src/session/features/ |
H A D | moon_capture_boost_feature.cpp | 66 if (fovRange.zoomMax - currentMaxRatio >= -std::numeric_limits<float>::epsilon()) { in MoonCaptureBoostFeature() 89 return inputZoomRatio - range.zoomMin >= -std::numeric_limits<float>::epsilon() && in GetSketchReferenceFovRatio() 90 inputZoomRatio - range.zoomMax < -std::numeric_limits<float>::epsilon(); in GetSketchReferenceFovRatio()
|
/foundation/graphic/graphic_2d/rosen/test/render/render/unittest/pipeline/ |
H A D | rs_graphic_config_unit_test.cpp | 161 ASSERT_TRUE(std::abs(0.1 - floatValues[0]) < std::numeric_limits<float>::epsilon()); in HWTEST_F() 162 ASSERT_TRUE(std::abs(0.2 - floatValues[1]) < std::numeric_limits<float>::epsilon()); in HWTEST_F() 163 ASSERT_TRUE(std::abs(-0.3 - floatValues[2]) < std::numeric_limits<float>::epsilon()); in HWTEST_F() 177 ASSERT_TRUE(std::abs(0.1 - floatValues[0]) < std::numeric_limits<float>::epsilon()); in HWTEST_F() 178 ASSERT_TRUE(std::abs(0.2 - floatValues[1]) < std::numeric_limits<float>::epsilon()); in HWTEST_F() 179 ASSERT_TRUE(std::abs(0.3 - floatValues[2]) < std::numeric_limits<float>::epsilon()); in HWTEST_F()
|
/foundation/graphic/graphic_2d/rosen/test/render_service/render_service/unittest/pipeline/ |
H A D | rs_graphic_config_test.cpp | 169 ASSERT_TRUE(std::abs(0.1 - floatValues[0]) < std::numeric_limits<float>::epsilon()); in HWTEST_F() 170 ASSERT_TRUE(std::abs(0.2 - floatValues[1]) < std::numeric_limits<float>::epsilon()); in HWTEST_F() 171 ASSERT_TRUE(std::abs(-0.3 - floatValues[2]) < std::numeric_limits<float>::epsilon()); in HWTEST_F() 177 ASSERT_TRUE(std::abs(0.1 - floatValues[0]) < std::numeric_limits<float>::epsilon()); in HWTEST_F() 178 ASSERT_TRUE(std::abs(0.2 - floatValues[1]) < std::numeric_limits<float>::epsilon()); in HWTEST_F() 179 ASSERT_TRUE(std::abs(0.3 - floatValues[2]) < std::numeric_limits<float>::epsilon()); in HWTEST_F()
|
/foundation/graphic/graphic_2d/rosen/test/render_service/render_service_base/fuzztest/rscommondef_fuzzer/ |
H A D | rscommondef_fuzzer.cpp | 66 float epsilon = GetData<float>();
in DoInline() local 68 ROSEN_EQ(valuex, valuey, epsilon);
in DoInline()
|
/foundation/multimedia/camera_framework/frameworks/native/camera/src/output/ |
H A D | sketch_wrapper.cpp | 296 if (fovRange.zoomMax - currentMaxRatio >= -std::numeric_limits<float>::epsilon()) { in UpdateSketchReferenceFovRatio() 353 if (fovRange.zoomMax - currentMaxRatio >= -std::numeric_limits<float>::epsilon()) { in UpdateSketchConfigFromMoonCaptureBoostConfig() 373 if (currentZoomRatio - minRange.zoomMin <= std::numeric_limits<float>::epsilon()) { in GetSketchReferenceFovRatio() 377 if (currentZoomRatio - maxRange.zoomMax >= -std::numeric_limits<float>::epsilon()) { in GetSketchReferenceFovRatio() 381 return currentZoomRatio - range.zoomMin >= -std::numeric_limits<float>::epsilon() && in GetSketchReferenceFovRatio() 382 currentZoomRatio - range.zoomMax < -std::numeric_limits<float>::epsilon(); in GetSketchReferenceFovRatio() 410 currentZoomRatio_ - sketchEnableRatio_ >= -std::numeric_limits<float>::epsilon()) { in AutoStream()
|
/foundation/arkui/ace_engine/frameworks/core/components_ng/property/ |
H A D | safe_area_insets.h | 48 constexpr float epsilon = 0.01f; in LessOrNearEqual() local 49 return (left - right) < epsilon; in LessOrNearEqual()
|
/foundation/graphic/graphic_3d/lume/Lume_3D/api/3d/shaders/common/ |
H A D | 3d_dm_inplace_fog_common.h | 32 const float epsilon = 0.005; in CalculateLineIntegral() local 41 return layer.density * exp2(-exponent) * (abs(falloff) > epsilon ? lineIntegral : lineIntegralTaylor); in CalculateLineIntegral()
|
/foundation/graphic/graphic_2d/rosen/modules/render_service_base/src/animation/ |
H A D | rs_cubic_bezier_interpolator.cpp | 90 constexpr float epsilon = 1e-6f; in BinarySearch() local 94 if (ROSEN_EQ(approximation, key, epsilon)) { in BinarySearch()
|
/foundation/graphic/graphic_utils_lite/interfaces/kits/gfx_utils/diagram/vertexprimitive/ |
H A D | geometry_path_storage.h | 311 const float epsilon = 1e-30; in ArcTo() local 318 if (rx < epsilon || ry < epsilon) { in ArcTo() 322 if (CalcDistance(x0, y0, x, y) < epsilon) { in ArcTo()
|