Home
last modified time | relevance | path

Searched refs:M_PI (Results 1 – 25 of 76) sorted by relevance

1234

/aosp12/frameworks/av/media/libaaudio/examples/utils/
H A DSineGenerator.h30 mPhaseIncrement = frequency * M_PI * 2 / frameRate; in setup()
36 mPhaseIncrementLow = frequencyLow * M_PI * 2 / mFrameRate; in setSweep()
37 mPhaseIncrementHigh = frequencyHigh * M_PI * 2 / mFrameRate; in setSweep()
106 if (mPhase > M_PI * 2) { in advancePhase()
107 mPhase -= M_PI * 2; in advancePhase()
126 double mPhaseIncrement = 440 * M_PI * 2 / 48000;
/aosp12/frameworks/av/media/libheadtracking/
H A DPoseRateLimiter-test.cpp52 Pose3f pose2({1, 2, 8}, rotateZ(M_PI * 5 / 8)); in TEST()
64 EXPECT_EQ(limiter.calculatePose(1002), Pose3f({1, 2, 4}, rotateZ(M_PI * 1 / 8))); in TEST()
66 EXPECT_EQ(limiter.calculatePose(1003), Pose3f({1, 2, 5}, rotateZ(M_PI * 2 / 8))); in TEST()
69 EXPECT_EQ(limiter.calculatePose(1005), Pose3f({1, 2, 7}, rotateZ(M_PI * 4 / 8))); in TEST()
80 Pose3f pose2({1, 2, 8}, rotateZ(M_PI * 5 / 8)); in TEST()
88 EXPECT_EQ(limiter.calculatePose(1001), Pose3f({1, 2, 4}, rotateZ(M_PI * 1 / 8))); in TEST()
H A DPoseDriftCompensator-test.cpp119 Pose3f pose1({1, 2, 3}, rotateZ(-M_PI * 3 / 4)); in TEST()
133 Pose3f(Vector3f{1, 2, 3} * std::expf(-2), rotateZ(-M_PI * 3 / 4 * std::expf(-1)))); in TEST()
138 Pose3f(Vector3f{1, 2, 3} * std::expf(-4), rotateZ(-M_PI * 3 / 4 * std::expf(-2)))); in TEST()
H A DHeadTrackingProcessor-test.cpp108 const Pose3f targetHeadToWorld = Pose3f({4, 0, 0}, rotateZ(M_PI / 2)); in TEST()
129 EXPECT_EQ(processor->getHeadToStagePose(), Pose3f({2, 0, 0}, rotateZ(M_PI / 4))); in TEST()
/aosp12/frameworks/native/libs/vr/libdvrcommon/include/private/dvr/
H A Dlog_helpers.h55 return out << "fov(" << (fov.GetLeft() * 180.0f / M_PI) << ','
56 << (fov.GetRight() * 180.0f / M_PI) << ','
57 << (fov.GetBottom() * 180.0f / M_PI) << ','
58 << (fov.GetTop() * 180.0f / M_PI) << ')';
H A Dnumeric.h17 return f * static_cast<FT>(180.0 / M_PI); in ToDeg()
22 return f * static_cast<FT>(M_PI / 180.0); in ToRad()
62 T NormalizeRadians(T x, T centre = static_cast<T>(M_PI)) {
63 return NormalizePeriodicRange(x, centre - static_cast<T>(M_PI),
64 centre + static_cast<T>(M_PI));
/aosp12/frameworks/native/libs/vr/libdvrcommon/tests/
H A Dpose_test.cpp32 FT(M_PI / 3.0), vec3_t(FT(3.0), FT(4.0), FT(5.0)).normalized())); in TYPED_TEST()
51 Eigen::AngleAxis<FT>(FT(M_PI / 2.0), vec3_t(FT(0.0), FT(0.0), FT(1.0)))); in TYPED_TEST()
75 FT(M_PI / 6.0), vec3_t(FT(3.0), FT(4.0), FT(5.0)).normalized())); in TYPED_TEST()
99 Eigen::AngleAxis<FT>(FT(M_PI / 2.0), vec3_t(FT(0.0), FT(0.0), FT(1.0)))); in TYPED_TEST()
102 FT(M_PI / 3.0), vec3_t(FT(1.0), FT(-1.0), FT(0.0)).normalized())); in TYPED_TEST()
130 FT(M_PI / 2.0), vec3_t(FT(4.0), FT(-2.0), FT(-1.0)).normalized())); in TYPED_TEST()
/aosp12/hardware/libhardware/modules/sensors/dynamic_sensor/
H A DDummyDynamicAccelDaemon.cpp168 event.data[0] = 2 * ::sin(3 * M_PI * t); in threadLoop()
169 event.data[1] = 3 * ::cos(3 * M_PI * t); in threadLoop()
170 event.data[2] = 1.5 * ::sin(6 * M_PI * t); in threadLoop()
/aosp12/hardware/invensense/65xx/libsensors_iio/software/core/mllite/
H A Dml_math_func.c242 return acos(quat0)*2*180/M_PI; in quaternion_to_rotation_angle()
514 if (ang > M_PI) in inv_wrap_angle()
515 return ang - 2 * (float)M_PI; in inv_wrap_angle()
516 else if (ang <= -(float)M_PI) in inv_wrap_angle()
517 return ang + 2 * (float)M_PI; in inv_wrap_angle()
534 if (d > M_PI) in inv_angle_diff()
535 d -= 2 * (float)M_PI; in inv_angle_diff()
536 else if (d < -(float)M_PI) in inv_angle_diff()
537 d += 2 * (float)M_PI; in inv_angle_diff()
/aosp12/hardware/invensense/6515/libsensors_iio/software/core/mllite/
H A Dml_math_func.c242 return acos(quat0)*2*180/M_PI; in quaternion_to_rotation_angle()
514 if (ang > M_PI) in inv_wrap_angle()
515 return ang - 2 * (float)M_PI; in inv_wrap_angle()
516 else if (ang <= -(float)M_PI) in inv_wrap_angle()
517 return ang + 2 * (float)M_PI; in inv_wrap_angle()
534 if (d > M_PI) in inv_angle_diff()
535 d -= 2 * (float)M_PI; in inv_angle_diff()
536 else if (d < -(float)M_PI) in inv_angle_diff()
537 d += 2 * (float)M_PI; in inv_angle_diff()
/aosp12/hardware/invensense/65xx/libsensors_iio/software/core/driver/include/
H A Dmlmath.h78 #ifndef M_PI
79 #define M_PI 3.14159265358979 macro
/aosp12/hardware/invensense/6515/libsensors_iio/software/core/driver/include/
H A Dmlmath.h78 #ifndef M_PI
79 #define M_PI 3.14159265358979 macro
/aosp12/bionic/libm/upstream-freebsd/lib/msun/bsdsrc/
H A Db_tgamma.c290 z = sin(M_PI*z);
292 z = cos(M_PI*(0.5-z));
299 lsine = __log__D(M_PI/z); /* = TRUNC(log(u)) + small */
314 return (M_PI / (y*z));
/aosp12/frameworks/base/libs/hwui/
H A DInterpolator.cpp33 return (float)(cosf((input + 1) * M_PI) / 2.0f) + 0.5f; in interpolate()
80 return sinf(2 * mCycles * M_PI * input); in interpolate()
/aosp12/frameworks/rs/driver/runtime/
H A Drs_quaternion.c58 rot *= (float)(M_PI / 180.0f) * 0.5f; in rsQuaternionLoadRotateUnit()
162 scale = sin(M_PI * (0.5f - t)); in rsQuaternionSlerp()
163 invScale = sin(M_PI * t); in rsQuaternionSlerp()
/aosp12/frameworks/native/libs/math/tests/
H A Dmat_test.cpp563 std::uniform_real_distribution<float> distribution(-6.0 * 2.0*M_PI, 6.0 * 2.0*M_PI); in TYPED_TEST()
582 std::uniform_real_distribution<float> distribution(-6.0 * 2.0*M_PI, 6.0 * 2.0*M_PI); in TYPED_TEST()
603 std::uniform_real_distribution<float> distribution(-6.0 * 2.0*M_PI, 6.0 * 2.0*M_PI); in TYPED_TEST()
H A Dquat_test.cpp242 quatd qr = quatd::fromAxisAngle(double3(0, 0, 1), M_PI / 2); in TEST_F()
259 quatd qb = quatd::fromAxisAngle(double3(0, 0, 1), M_PI / 2); in TEST_F()
261 qr = quatd::fromAxisAngle(double3(0, 0, 1), M_PI / 4); in TEST_F()
/aosp12/frameworks/av/media/libaudioprocessing/
H A DAudioResamplerFirGen.h526 double wstart = fstart*(2.*M_PI);
527 double wend = fend*(2.*M_PI);
719 const double xstep = (2. * M_PI) * fcr / L;
721 const double yscale = atten * L / (I0(beta) * M_PI);
/aosp12/frameworks/rs/
H A DrsScriptC_Lib.cpp38 const float A = 1.0f / (2.0f * M_PI);
55 x += float(M_PI / 2);
57 const float A = 1.0f / (2.0f * M_PI);
/aosp12/frameworks/base/media/mca/filterfw/native/core/
H A Dstatistics.cpp43 pdf_denom_ = sqrtf(M_PI * exp_denom_); in Add()
/aosp12/hardware/invensense/6515/libsensors_iio/software/simple_apps/playback/linux/
H A Ddatalogger_outputs.c185 *mag_north = atan2f((float) t1, (float) t2) * 180.f / (float) M_PI; in inv_get_sensor_type_compass_float()
191 *true_north = atan2f((float) t1, (float) t2) * 180.f / (float) M_PI; in inv_get_sensor_type_compass_float()
/aosp12/packages/inputmethods/LatinIME/native/jni/src/suggest/core/layout/
H A Dgeometry_utils.h41 static const float M_2PI_F = M_PI * 2.0f; in getAngleDiff()
/aosp12/frameworks/av/media/libaudioprocessing/tests/
H A Dtest_utils.h201 double y = sin(2. * M_PI * freq * t);
227 double y = sin(2. * M_PI * (k * t + minfreq) * t);
/aosp12/hardware/qcom/sm8150p/gps/utils/
H A Dloc_nmea.cpp246 Mu = M_PI / 2.0; in convert_Ecef_to_Lla()
248 Mu = -M_PI / 2.0; in convert_Ecef_to_Lla()
1339 lla_w84.lat = location.gpsLocation.latitude / 180.0 * M_PI; in loc_nmea_generate_pos()
1340 lla_w84.lon = location.gpsLocation.longitude / 180.0 * M_PI; in loc_nmea_generate_pos()
1352 local_lla.lat = lla_p90.lat / M_PI * 180.0; in loc_nmea_generate_pos()
1353 local_lla.lon = lla_p90.lon / M_PI * 180.0; in loc_nmea_generate_pos()
1357 ref_lla.lat = lla_p90.lat / M_PI * 180.0; in loc_nmea_generate_pos()
1358 ref_lla.lon = lla_p90.lon / M_PI * 180.0; in loc_nmea_generate_pos()
/aosp12/frameworks/native/services/sensorservice/
H A DOrientationSensor.cpp53 const float rad2deg = 180 / M_PI; in process()

1234