mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 10:22:45 -04:00
cmath: Use combined sincos on GNU where it is available
This commit is contained in:
parent
78fb565f2b
commit
480226a97a
@ -64,10 +64,12 @@ csincos(float v, float *sin_result, float *cos_result) {
|
||||
fstp DWORD ptr [edx]
|
||||
fstp DWORD ptr [eax]
|
||||
}
|
||||
#else //!_X86_
|
||||
#elif defined(_GNU_SOURCE)
|
||||
sincosf(v, sin_result, cos_result);
|
||||
#else
|
||||
*sin_result = sinf(v);
|
||||
*cos_result = cosf(v);
|
||||
#endif //!_X86_
|
||||
#endif
|
||||
}
|
||||
|
||||
/**
|
||||
@ -231,6 +233,8 @@ csincos(double v, double *sin_result, double *cos_result) {
|
||||
fstp QWORD ptr [edx]
|
||||
fstp QWORD ptr [eax]
|
||||
}
|
||||
#elif defined(_GNU_SOURCE)
|
||||
sincos(v, sin_result, cos_result);
|
||||
#else //!_X86_
|
||||
*sin_result = sin(v);
|
||||
*cos_result = cos(v);
|
||||
|
Loading…
x
Reference in New Issue
Block a user