style cleanup
authorCampbell Barton <ideasman42@gmail.com>
Sun, 12 Aug 2012 21:46:35 +0000 (21:46 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Sun, 12 Aug 2012 21:46:35 +0000 (21:46 +0000)
source/blender/blenkernel/intern/image.c
source/blender/imbuf/intern/rectop.c
source/blender/windowmanager/WM_api.h
source/blender/windowmanager/WM_types.h

index fbcd943e13f1ed139efb40c229cb5f32e808747c..1adf2c891e3383170aaae0c5a2eee40a7e02ed1f 100644 (file)
@@ -1508,7 +1508,8 @@ void BKE_stamp_buf(Scene *scene, Object *camera, unsigned char *rect, float *rec
                y -= h;
 
                /* also a little of space to the background. */
-               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp, x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
+               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp,
+                                                 x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
 
                /* and draw the text. */
                BLF_position(mono, x, y + y_ofs, 0.0);
@@ -1524,7 +1525,8 @@ void BKE_stamp_buf(Scene *scene, Object *camera, unsigned char *rect, float *rec
                y -= h;
 
                /* and space for background. */
-               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp, 0, y - BUFF_MARGIN_Y, w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
+               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp,
+                                                 0, y - BUFF_MARGIN_Y, w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
 
                BLF_position(mono, x, y + y_ofs, 0.0);
                BLF_draw_buffer(mono, stamp_data.note);
@@ -1539,7 +1541,8 @@ void BKE_stamp_buf(Scene *scene, Object *camera, unsigned char *rect, float *rec
                y -= h;
 
                /* and space for background. */
-               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp, 0, y - BUFF_MARGIN_Y, w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
+               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp,
+                                                 0, y - BUFF_MARGIN_Y, w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
 
                BLF_position(mono, x, y + y_ofs, 0.0);
                BLF_draw_buffer(mono, stamp_data.date);
@@ -1554,7 +1557,8 @@ void BKE_stamp_buf(Scene *scene, Object *camera, unsigned char *rect, float *rec
                y -= h;
 
                /* and space for background. */
-               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp, 0, y - BUFF_MARGIN_Y, w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
+               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp,
+                                                 0, y - BUFF_MARGIN_Y, w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
 
                BLF_position(mono, x, y + y_ofs, 0.0);
                BLF_draw_buffer(mono, stamp_data.rendertime);
@@ -1568,7 +1572,8 @@ void BKE_stamp_buf(Scene *scene, Object *camera, unsigned char *rect, float *rec
                BLF_width_and_height(mono, stamp_data.marker, &w, &h); h = h_fixed;
 
                /* extra space for background. */
-               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp, x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
+               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp,
+                                                 x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
 
                /* and pad the text. */
                BLF_position(mono, x, y + y_ofs, 0.0);
@@ -1583,7 +1588,8 @@ void BKE_stamp_buf(Scene *scene, Object *camera, unsigned char *rect, float *rec
                BLF_width_and_height(mono, stamp_data.time, &w, &h); h = h_fixed;
 
                /* extra space for background */
-               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp, x - BUFF_MARGIN_X, y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
+               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp,
+                                                 x - BUFF_MARGIN_X, y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
 
                /* and pad the text. */
                BLF_position(mono, x, y + y_ofs, 0.0);
@@ -1597,7 +1603,8 @@ void BKE_stamp_buf(Scene *scene, Object *camera, unsigned char *rect, float *rec
                BLF_width_and_height(mono, stamp_data.frame, &w, &h); h = h_fixed;
 
                /* extra space for background. */
-               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp, x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
+               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp,
+                                                 x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
 
                /* and pad the text. */
                BLF_position(mono, x, y + y_ofs, 0.0);
@@ -1611,7 +1618,8 @@ void BKE_stamp_buf(Scene *scene, Object *camera, unsigned char *rect, float *rec
                BLF_width_and_height(mono, stamp_data.camera, &w, &h); h = h_fixed;
 
                /* extra space for background. */
-               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp, x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
+               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp,
+                                                 x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
                BLF_position(mono, x, y + y_ofs, 0.0);
                BLF_draw_buffer(mono, stamp_data.camera);
 
@@ -1623,7 +1631,8 @@ void BKE_stamp_buf(Scene *scene, Object *camera, unsigned char *rect, float *rec
                BLF_width_and_height(mono, stamp_data.cameralens, &w, &h); h = h_fixed;
 
                /* extra space for background. */
-               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp, x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
+               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp,
+                                                 x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
                BLF_position(mono, x, y + y_ofs, 0.0);
                BLF_draw_buffer(mono, stamp_data.cameralens);
        }
@@ -1635,7 +1644,8 @@ void BKE_stamp_buf(Scene *scene, Object *camera, unsigned char *rect, float *rec
                x = width - w - 2;
 
                /* extra space for background. */
-               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp, x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
+               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp,
+                                                 x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
 
                /* and pad the text. */
                BLF_position(mono, x, y + y_ofs, 0.0);
@@ -1650,7 +1660,8 @@ void BKE_stamp_buf(Scene *scene, Object *camera, unsigned char *rect, float *rec
                y = height - h;
 
                /* extra space for background. */
-               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp, x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
+               buf_rectfill_area(rect, rectf, width, height, scene->r.bg_stamp,
+                                                 x - BUFF_MARGIN_X, y - BUFF_MARGIN_Y, x + w + BUFF_MARGIN_X, y + h + BUFF_MARGIN_Y);
 
                BLF_position(mono, x, y + y_ofs, 0.0);
                BLF_draw_buffer(mono, stamp_data.strip);
index da7618ef8062d6be87295801126d78d745353ca7..d9cbbd03923f0a38a901cedc1fa22ec3ff836b68 100644 (file)
@@ -481,7 +481,8 @@ void IMB_rectfill(struct ImBuf *drect, const float col[4])
 }
 
 
-void buf_rectfill_area(unsigned char *rect, float *rectf, int width, int height, const float col[4], int x1, int y1, int x2, int y2)
+void buf_rectfill_area(unsigned char *rect, float *rectf, int width, int height, const float col[4],
+                                          int x1, int y1, int x2, int y2)
 {
        int i, j;
        float a; /* alpha */
index 55783c3b9809e8ce399f332bbabee615b46a2f77..584790b4cdae80b1178dcb78e65b9ec806372e95 100644 (file)
@@ -37,7 +37,6 @@
  *  \todo document
  */
 
-
 /* dna-savable wmStructs here */
 #include "DNA_windowmanager_types.h"
 #include "WM_keymap.h"
@@ -83,7 +82,7 @@ void          WM_check                        (struct bContext *C);
 
 struct wmWindow        *WM_window_open (struct bContext *C, struct rcti *rect);
 
-                       /* defines for 'type' WM_window_open_temp */
+               /* defines for 'type' WM_window_open_temp */
 #define WM_WINDOW_RENDER               0
 #define WM_WINDOW_USERPREFS            1
 #define WM_WINDOW_FILESEL              2
@@ -183,7 +182,7 @@ void                WM_operator_free                (struct wmOperator *op);
 void           WM_operator_stack_clear(struct wmWindowManager *wm);
 
 struct wmOperatorType *WM_operatortype_find(const char *idnamem, int quiet);
-struct GHashIterator *WM_operatortype_iter(void);
+struct GHashIterator  *WM_operatortype_iter(void);
 void           WM_operatortype_append  (void (*opfunc)(struct wmOperatorType*));
 void           WM_operatortype_append_ptr      (void (*opfunc)(struct wmOperatorType*, void *), void *userdata);
 void           WM_operatortype_append_macro_ptr        (void (*opfunc)(struct wmOperatorType*, void *), void *userdata);
@@ -311,10 +310,10 @@ struct wmJob *WM_jobs_get(struct wmWindowManager *wm, struct wmWindow *win, void
 
 int                    WM_jobs_test(struct wmWindowManager *wm, void *owner);
 float          WM_jobs_progress(struct wmWindowManager *wm, void *owner);
-char           *WM_jobs_name(struct wmWindowManager *wm, void *owner);
+char       *WM_jobs_name(struct wmWindowManager *wm, void *owner);
 
 int         WM_jobs_is_running(struct wmJob *);
-void *      WM_jobs_customdata_get(struct wmJob *);
+void       *WM_jobs_customdata_get(struct wmJob *);
 void        WM_jobs_customdata_set(struct wmJob *, void *customdata, void (*free)(void *));
 void        WM_jobs_timer(struct wmJob *, double timestep, unsigned int note, unsigned int endnote);
 void        WM_jobs_callbacks(struct wmJob *,
@@ -331,8 +330,8 @@ void                WM_jobs_stop_all(struct wmWindowManager *wm);
 int                    WM_jobs_has_running(struct wmWindowManager *wm);
 
                        /* clipboard */
-char           *WM_clipboard_text_get(int selection);
-void           WM_clipboard_text_set(char *buf, int selection);
+char       *WM_clipboard_text_get(int selection);
+void        WM_clipboard_text_set(char *buf, int selection);
 
                        /* progress */
 void           WM_progress_set(struct wmWindow *win, float progress);
index 8d7dc21d95bd4800590ffa92984d0a752d4c4076..91f93828235a91bdd74a2569283b558c2f71e0ff 100644 (file)
@@ -454,28 +454,28 @@ typedef struct wmTabletData {
 
 typedef enum {  /* motion progress, for modal handlers */
        P_NOT_STARTED,
-       P_STARTING,    // <--
-       P_IN_PROGRESS, // <-- only these are sent for NDOF motion
-       P_FINISHING,   // <--
+       P_STARTING,    /* <-- */
+       P_IN_PROGRESS, /* <-- only these are sent for NDOF motion*/
+       P_FINISHING,   /* <-- */
        P_FINISHED
-       } wmProgress;
+} wmProgress;
 
 typedef struct wmNDOFMotionData {
        /* awfully similar to GHOST_TEventNDOFMotionData... */
-       // Each component normally ranges from -1 to +1, but can exceed that.
-       // These use blender standard view coordinates, with positive rotations being CCW about the axis.
+       /* Each component normally ranges from -1 to +1, but can exceed that.
+        * These use blender standard view coordinates, with positive rotations being CCW about the axis. */
        union {
-               float tvec[3]; // translation
+               float tvec[3]; /* translation */
                struct { float tx, ty, tz; };
-               };
+       };
        union {
-               float rvec[3]; // rotation:
+               float rvec[3]; /* rotation: */
                struct { float rx, ry, rz; };
-               };
-               // axis = (rx,ry,rz).normalized
-               // amount = (rx,ry,rz).magnitude [in revolutions, 1.0 = 360 deg]
-       float dt; // time since previous NDOF Motion event
-       wmProgress progress; // is this the first event, the last, or one of many in between?
+       };
+       /* axis = (rx,ry,rz).normalized */
+       /* amount = (rx,ry,rz).magnitude [in revolutions, 1.0 = 360 deg] */
+       float dt; /* time since previous NDOF Motion event */
+       wmProgress progress; /* is this the first event, the last, or one of many in between? */
 } wmNDOFMotionData;
 
 typedef struct wmTimer {