Skip to content

Commit 6642c85

Browse files
juhdanadnerzhul
authored andcommittedJan 30, 2017
Use fabs() instead of abs() (#5141)
1 parent f0e3abc commit 6642c85

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed
 

Diff for: ‎src/mapblock_mesh.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -1090,9 +1090,9 @@ MapBlockMesh::MapBlockMesh(MeshMakeData *data, v3s16 camera_offset):
10901090
brightness of vertices 1 and 3 differ less than
10911091
the brightness of vertices 0 and 2.
10921092
*/
1093-
if (abs(f.vertices[0].Color.getLuminance()
1093+
if (fabs(f.vertices[0].Color.getLuminance()
10941094
- f.vertices[2].Color.getLuminance())
1095-
> abs(f.vertices[1].Color.getLuminance()
1095+
> fabs(f.vertices[1].Color.getLuminance()
10961096
- f.vertices[3].Color.getLuminance()))
10971097
indices_p = indices_alternate;
10981098

0 commit comments

Comments
 (0)
Please sign in to comment.