Version: Unity 6.5 Alpha (6000.5)
LanguageEnglish
  • C#

math.sincos

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Declaration

public static void sincos(float x, out float s, out float c);

Parameters

Parameter Description
x Input angle in radians.
s Output sine of the input.
c Output cosine of the input.

Description

Returns the sine and cosine of the input float value x through the out parameters s and c.

When Burst compiled, his method is faster than calling sin() and cos() separately.


Declaration

public static void sincos(float2 x, out float2 s, out float2 c);

Parameters

Parameter Description
x Input vector containing angles in radians.
s Output vector containing the componentwise sine of the input.
c Output vector containing the componentwise cosine of the input.

Description

Returns the componentwise sine and cosine of the input float2 vector x through the out parameters s and c.

When Burst compiled, his method is faster than calling sin() and cos() separately.


Declaration

public static void sincos(float3 x, out float3 s, out float3 c);

Parameters

Parameter Description
x Input vector containing angles in radians.
s Output vector containing the componentwise sine of the input.
c Output vector containing the componentwise cosine of the input.

Description

Returns the componentwise sine and cosine of the input float3 vector x through the out parameters s and c.

When Burst compiled, his method is faster than calling sin() and cos() separately.


Declaration

public static void sincos(float4 x, out float4 s, out float4 c);

Parameters

Parameter Description
x Input vector containing angles in radians.
s Output vector containing the componentwise sine of the input.
c Output vector containing the componentwise cosine of the input.

Description

Returns the componentwise sine and cosine of the input float4 vector x through the out parameters s and c.

When Burst compiled, his method is faster than calling sin() and cos() separately.


Declaration

public static void sincos(double x, out double s, out double c);

Parameters

Parameter Description
x Input angle in radians.
s Output sine of the input.
c Output cosine of the input.

Description

Returns the sine and cosine of the input double value x through the out parameters s and c.

When Burst compiled, his method is faster than calling sin() and cos() separately.


Declaration

public static void sincos(double2 x, out double2 s, out double2 c);

Parameters

Parameter Description
x Input vector containing angles in radians.
s Output vector containing the componentwise sine of the input.
c Output vector containing the componentwise cosine of the input.

Description

Returns the componentwise sine and cosine of the input double2 vector x through the out parameters s and c.

When Burst compiled, his method is faster than calling sin() and cos() separately.


Declaration

public static void sincos(double3 x, out double3 s, out double3 c);

Parameters

Parameter Description
x Input vector containing angles in radians.
s Output vector containing the componentwise sine of the input.
c Output vector containing the componentwise cosine of the input.

Description

Returns the componentwise sine and cosine of the input double3 vector x through the out parameters s and c.

When Burst compiled, his method is faster than calling sin() and cos() separately.


Declaration

public static void sincos(double4 x, out double4 s, out double4 c);

Parameters

Parameter Description
x Input vector containing angles in radians.
s Output vector containing the componentwise sine of the input.
c Output vector containing the componentwise cosine of the input.

Description

Returns the componentwise sine and cosine of the input double4 vector x through the out parameters s and c.

When Burst compiled, his method is faster than calling sin() and cos() separately.