Commit Graph

29 Commits

Author SHA1 Message Date
charles lefebvre
19316f65ff UE Units: Add acceleration (cm/s2 and m/s2)
#rb Yoan.StAmant
#rnx
#tests Tested in editor, preflight

[CL 31057164 by charles lefebvre in ue5-main branch]
2024-01-31 13:59:44 -05:00
sapayne
a5389f30c0 #ue5 - Optimize TQuat<T>::Slerp_NotNormalized(). Removes 1 branch, based on negative angle identity for Sine function. Added startup tests to validate old versus new function and also test both versions for both positive and negative 'RawCosom' values (not previously tested).
#jira UE-187917
#10448
#rb ben.hoffman
#tests startup tests and PIE with player animation stressing Slerp()

[CL 30987249 by sapayne in ue5-main branch]
2024-01-29 23:37:46 -05:00
matt peters
12f885365f Core Tests: Relabel non-System.Core core tests as System.Core to match the other core tests.
#rnx
#rb Devin.Doucette

[CL 30429883 by matt peters in ue5-main branch]
2023-12-21 12:01:26 -05:00
steve robb
fd871cfac0 Replaced loop with modulo in FMath::Wrap to make it run in constant time.
Added some tests that would have failed with the previous implementation due to lack of floating point precision.
Added some constexpr tests, though only the integer tests can be supported before C++23.

#rb fabian.giesen, jodon.karlik
#jira UE-202852

[CL 30374367 by steve robb in ue5-main branch]
2023-12-18 07:49:44 -05:00
steve robb
41b295c875 Added floating point unit tests for FMath::Wrap.
Added a new FMath::Modulo which generically encapsulates integral/float differences.

#rb fabian.giesen, jodon.karlik

[CL 30015486 by steve robb in ue5-main branch]
2023-11-30 10:44:32 -05:00
steve robb
51f3ea53ae Removed ChooseClass.h includes.
#rb trivial

[CL 27823723 by steve robb in ue5-main branch]
2023-09-13 05:43:01 -04:00
steve robb
da9f5a828a Replaced TChooseClass with std::conditional_t.
#rb none
#jira UE-195271

[CL 27816205 by steve robb in ue5-main branch]
2023-09-12 19:55:55 -04:00
justin hare
a0c6f25ff3 Added angular speed units (deg/s, rad/s) for display in editor and conversion
#rb ben.hoffman

[CL 27492784 by justin hare in ue5-main branch]
2023-08-30 14:38:26 -04:00
andrew scheidecker
786b137e22 Rename TGuardedSignedInt to TGuardedInt and add support for unsigned integers.
Factor some of the arithmetic operators out of TGuardedInt into AddAndCheckForOverflow et al functions in FPlatformMath so they can use the __builtin_*_overflow functions on clang that compile to much more efficient code than the portable C code does in most cases.
#rb Fabian.Giesen, Johan.Torp

[CL 26880341 by andrew scheidecker in ue5-main branch]
2023-08-07 08:13:41 -04:00
steve robb
77b279f4f1 Fix for root node's children not being properly unset during TOctree2::ApplyOffset.
#rb richard.talbotwatkin

[CL 26120279 by steve robb in ue5-main branch]
2023-06-20 09:00:20 -04:00
zak middleton
d51c438871 #ue5 - Change TQuat::FindBetween_Helper() when dealing with anti-parallel (opposite direction) vectors. This restores the old behavior to prefer rotation around the Z-axis when dealing with vectors with X or Y dominant components, which causes rotations in gameplay to avoid adding roll when the quat is used for interpolation. Added more validation tests to compare old and new methods.
#rb David.Paquette

[CL 25881692 by zak middleton in ue5-main branch]
2023-06-08 16:28:33 -04:00
tom waterson
b2a34a684b Add torque units and extend force units
#rb justin.hare
#preflight 647862b85d23eca37d782f2c

[CL 25723425 by tom waterson in ue5-main branch]
2023-06-01 07:44:12 -04:00
dan thompson
5f360661f3 Move GuardedInt.h to Core as it's about to be needed elsewhere.
#rb devin.doucette
#preflight 6467a9a52c0a5da0dcd0afa9

[CL 25553319 by dan thompson in ue5-main branch]
2023-05-19 17:51:45 -04:00
Zak Middleton
8fb2dd249e #ue5 - Fix TQuat<T>::FindBetweenNormals() and TQuat<T>::FindBetweenVectors() choosing poor basis vectors when input vectors are anti-parallel (opposite directions). Added more test coverage in engine startup tests.
Modified from PR #10029
#jira UE-174630
#preflight 642f242a4c3ccbbdf18eace1
#rb Jodon.Karlik

[CL 24966167 by Zak Middleton in ue5-main branch]
2023-04-07 12:42:54 -04:00
chris constantinescu
b0e2605d0a Nightly Low Level tests must run only slow and performance tests
Additional small quality of life fixes
#rb Jerome.Delattre, Rob.Huyett
#preflight 64120656bd6894c435c1f7c4

[CL 24660566 by chris constantinescu in ue5-main branch]
2023-03-15 15:35:19 -04:00
chris constantinescu
47e6bf6873 Undefined float to int conversion test for VectorRound removed from "System::Core::Math::RoundToIntHalfToEven Vector"
#jira UE-178724
#preflight 640f5b99d778f8897526ef02
#rb Fabian.Giesen

[CL 24618063 by chris constantinescu in ue5-main branch]
2023-03-13 14:42:29 -04:00
Mikita Hauruk
61486b8a30 Translated tests which not needed in new macro implementation
Translated Core\Tests\Math\ColorTests.cpp
Translated Core\Tests\Containers\TokenTest.cpp
Translated Core\Tests\Hash\Blake3Test.cpp
Translated Core\Tests\HAL\PlatformStringTests.cpp
Translated 3 files from String directory

#jira UE-176646
#rb adam.miezianko, chris.constantinescu, oleg.krasnov, mikalai.sukhikh
#preflight 6401a0cda20ddf1bf498910b, 6401a0e75515f4f57baf5c6d

[CL 24519078 by Mikita Hauruk in ue5-main branch]
2023-03-06 03:11:25 -05:00
Mikita Hauruk
bbdade191a Fixed unknown type name 'PRAGMA_DISABLE_UNSAFE_TYPECAST_WARNINGS'
PRAGMA_DISABLE_UNSAFE_TYPECAST_WARNINGS

#preflight 640244efd249add4a27a9d0e, 64024486a726961ed9d729c2

[CL 24504972 by Mikita Hauruk in ue5-main branch]
2023-03-03 14:49:32 -05:00
Mikita Hauruk
3aaeb2890f Translated last test Engine\Source\Runtime\Core\Private\Tests\Math\UnitCoversionTests.cpp
#jira UE-176630
#rb adam.miezianko, chris.constantinescu, oleg.krasnov, mikalai.sukhikh
#preflight 6401c2e259017a559b55dc68, 6401c492d249add4a2427be9

[CL 24496626 by Mikita Hauruk in ue5-main branch]
2023-03-03 05:37:54 -05:00
chris constantinescu
22909ccbda Skip ColorConversionHeavy
#rnx
#preflight skip

[CL 24467277 by chris constantinescu in ue5-main branch]
2023-03-01 13:59:07 -05:00
chris constantinescu
f21e84d8e7 UnrealMathTest small fixes
#preflight 63fce8a1dd78dd50f6984236

[CL 24426591 by chris constantinescu in ue5-main branch]
2023-02-27 12:42:06 -05:00
Mikita Hauruk
b9a6423823 Translated tests from Engine\Source\Runtime\Core\Private\Tests\Math
Added CHECK_FALSE_MESSAGE

#jira UE-176630
#rb adam.miezianko, chris.constantinescu, oleg.krasnov, mikalai.sukhikh
#preflight 63f5e30e500c05a6241283b8, 63f5e306ff5afbbb038a30ab

[CL 24419943 by Mikita Hauruk in ue5-main branch]
2023-02-27 00:26:21 -05:00
chris constantinescu
28111d40fc Redundancy cleanup in UBT Low Level Tests:
- test-specific targets and modules are constructed by RulesAssembly which removes a lot of spaghetti code
- no more excluding the Tests folder by default which is guaranteed to mislead users #fyi Jon.Nabozny
- test compilation in Tests is controlled through WITH_LOW_LEVEL_TESTS
- preparation code for switching tests between Catch2 / TestAutomation Fmwk

Nightly LLT PF 6260431391376845adeb4c40

#rnx
#preflight 62602d50dd47b4ad2173c30b

[CL 19834665 by chris constantinescu in ue5-main branch]
2022-04-20 14:24:59 -04:00
Devin Doucette
07adff9b17 LowLevelTests: Reverted the Core tests that were moved in 19498448 and 19571202
#preflight 62471e0e73665f7d5e634d2d
#rb Chris.Constantinescu, Mark.Lintott
#rnx

[CL 19589944 by Devin Doucette in ue5-main branch]
2022-04-01 12:14:09 -04:00
mark lintott
bc9b168688 Add new Unit Tests
#rb Chris.Constantinescu
#preflight 62458f77292f228e09013681

[CL 19571202 by mark lintott in ue5-main branch]
2022-03-31 07:45:37 -04:00