From 48e089375ebe4aeb30d60e9d8ef6f467280cf07d Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Fri, 7 Aug 2020 22:56:13 +1000 Subject: Cleanup: pass arrays const where possible --- source/blender/draw/intern/draw_cache_extract_mesh.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'source/blender/draw/intern') diff --git a/source/blender/draw/intern/draw_cache_extract_mesh.c b/source/blender/draw/intern/draw_cache_extract_mesh.c index a1d2a7eeb4a..a22d4cc95a2 100644 --- a/source/blender/draw/intern/draw_cache_extract_mesh.c +++ b/source/blender/draw/intern/draw_cache_extract_mesh.c @@ -3611,12 +3611,14 @@ static void compute_normalize_edge_vectors(float auv[2][2], normalize_v3(av[1]); } -static short v2_to_short_angle(float v[2]) +static short v2_to_short_angle(const float v[2]) { return atan2f(v[1], v[0]) * (float)M_1_PI * SHRT_MAX; } -static void edituv_get_stretch_angle(float auv[2][2], float av[2][3], UVStretchAngle *r_stretch) +static void edituv_get_stretch_angle(float auv[2][2], + const float av[2][3], + UVStretchAngle *r_stretch) { /* Send UV's to the shader and let it compute the aspect corrected angle. */ r_stretch->uv_angles[0] = v2_to_short_angle(auv[0]); -- cgit v1.2.3