svn merge -r39792:39829 https://svn.blender.org/svnroot/bf-blender/trunk/blender
[blender.git] / source / blender / editors / space_view3d / drawobject.c
index fbb3aac43fe2d0b3bf9a7f0401b53101ce0543a4..2b994a2d0d273dd77905d0397faedd81d4e316d8 100644 (file)
@@ -1496,7 +1496,7 @@ static void drawcamera(Scene *scene, View3D *v3d, RegionView3D *rv3d, Object *ob
 }
 
 /* flag similar to draw_object() */
-static void drawspeaker(Scene *scene, View3D *v3d, RegionView3D *rv3d, Object *ob, int flag)
+static void drawspeaker(Scene *UNUSED(scene), View3D *UNUSED(v3d), RegionView3D *UNUSED(rv3d), Object *UNUSED(ob), int UNUSED(flag))
 {
        //Speaker *spk = ob->data;
 
@@ -1505,34 +1505,29 @@ static void drawspeaker(Scene *scene, View3D *v3d, RegionView3D *rv3d, Object *o
 
        glEnable(GL_BLEND);
 
-       for(j = 0; j < 3; j++)
-       {
-               vec[2] = .25f * j -.125f;
+       for(j = 0; j < 3; j++) {
+               vec[2] = 0.25f * j -0.125f;
 
                glBegin(GL_LINE_LOOP);
-               for(i = 0; i < 16; i++)
-               {
-                       vec[0] = cos(M_PI * i / 8.0f) * (j == 0 ? .5f : .25f);
-                       vec[1] = sin(M_PI * i / 8.0f) * (j == 0 ? .5f : .25f);
+               for(i = 0; i < 16; i++) {
+                       vec[0] = cosf(M_PI * i / 8.0f) * (j == 0 ? 0.5f : 0.25f);
+                       vec[1] = sinf(M_PI * i / 8.0f) * (j == 0 ? 0.5f : 0.25f);
                        glVertex3fv(vec);
                }
                glEnd();
        }
 
-       for(j = 0; j < 4; j++)
-       {
-               vec[0] = (((j + 1) % 2) * (j - 1)) * .5f;
-               vec[1] = ((j % 2) * (j - 2)) * .5f;
+       for(j = 0; j < 4; j++) {
+               vec[0] = (((j + 1) % 2) * (j - 1)) * 0.5f;
+               vec[1] = ((j % 2) * (j - 2)) * 0.5f;
                glBegin(GL_LINE_STRIP);
-               for(i = 0; i < 3; i++)
-               {
-                       if(i == 1)
-                       {
-                               vec[0] *= .5f;
-                               vec[1] *= .5f;
+               for(i = 0; i < 3; i++) {
+                       if(i == 1) {
+                               vec[0] *= 0.5f;
+                               vec[1] *= 0.5f;
                        }
 
-                       vec[2] = .25f * i -.125f;
+                       vec[2] = 0.25f * i -0.125f;
                        glVertex3fv(vec);
                }
                glEnd();