From a2c182e9233333fc3b8ff40d352113ec95e7e30c Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 3 Mar 2012 16:31:46 +0000 Subject: style cleanup - use aligned * prefixed blocks for descriptive comments (was already used a lot and part of proposed style guide). --- source/blender/editors/space_image/image_buttons.c | 14 +++++++------- source/blender/editors/space_image/image_draw.c | 18 ++++++++++-------- source/blender/editors/space_image/space_image.c | 6 ++++-- 3 files changed, 21 insertions(+), 17 deletions(-) (limited to 'source/blender/editors/space_image') diff --git a/source/blender/editors/space_image/image_buttons.c b/source/blender/editors/space_image/image_buttons.c index 150872813b2..d54468f64ea 100644 --- a/source/blender/editors/space_image/image_buttons.c +++ b/source/blender/editors/space_image/image_buttons.c @@ -212,10 +212,10 @@ static void image_panel_curves(const bContext *C, Panel *pa) #if 0 /* 0: disable preview - otherwise refresh preview - - XXX if you put this back, also check XXX in image_main_area_draw() */ -*/ + * otherwise refresh preview + * + * XXX if you put this back, also check XXX in image_main_area_draw() */ + */ void image_preview_event(int event) { int exec= 0; @@ -602,12 +602,12 @@ static void rna_update_cb(bContext *C, void *arg_cb, void *UNUSED(arg)) RNAUpdateCb *cb= (RNAUpdateCb*)arg_cb; /* ideally this would be done by RNA itself, but there we have - no image user available, so we just update this flag here */ + * no image user available, so we just update this flag here */ cb->iuser->ok= 1; /* we call update here on the pointer property, this way the - owner of the image pointer can still define it's own update - and notifier */ + * owner of the image pointer can still define it's own update + * and notifier */ RNA_property_update(C, &cb->ptr, cb->prop); } diff --git a/source/blender/editors/space_image/image_draw.c b/source/blender/editors/space_image/image_draw.c index 9ec9c5ef0e0..e91a44e0358 100644 --- a/source/blender/editors/space_image/image_draw.c +++ b/source/blender/editors/space_image/image_draw.c @@ -79,11 +79,11 @@ static void image_verify_buffer_float(Image *ima, ImBuf *ibuf, int color_manage) { /* detect if we need to redo the curve map. - ibuf->rect is zero for compositor and render results after change - convert to 32 bits always... drawing float rects isnt supported well (atis) - - NOTE: if float buffer changes, we have to manually remove the rect - */ + * ibuf->rect is zero for compositor and render results after change + * convert to 32 bits always... drawing float rects isnt supported well (atis) + * + * NOTE: if float buffer changes, we have to manually remove the rect + */ if(ibuf->rect_float && (ibuf->rect==NULL || (ibuf->userflags & IB_RECT_INVALID)) ) { if(color_manage) { @@ -531,8 +531,10 @@ static void draw_image_buffer(SpaceImage *sima, ARegion *ar, Scene *scene, Image if(ibuf->rect) glaDrawPixelsSafe(x, y, ibuf->x, ibuf->y, ibuf->x, GL_RGBA, GL_UNSIGNED_BYTE, ibuf->rect); - /*else - glaDrawPixelsSafe(x, y, ibuf->x, ibuf->y, ibuf->x, GL_RGBA, GL_FLOAT, ibuf->rect_float);*/ +#if 0 + else + glaDrawPixelsSafe(x, y, ibuf->x, ibuf->y, ibuf->x, GL_RGBA, GL_FLOAT, ibuf->rect_float); +#endif if(sima->flag & SI_USE_ALPHA) glDisable(GL_BLEND); @@ -734,7 +736,7 @@ static void draw_image_paint_helpers(ARegion *ar, Scene *scene, float zoomx, flo if(brush && (brush->imagepaint_tool == PAINT_TOOL_CLONE)) { /* this is not very efficient, but glDrawPixels doesn't allow - drawing with alpha */ + * drawing with alpha */ clonerect= get_alpha_clone_image(scene, &w, &h); if(clonerect) { diff --git a/source/blender/editors/space_image/space_image.c b/source/blender/editors/space_image/space_image.c index 7abc0c6ea71..1af37a66022 100644 --- a/source/blender/editors/space_image/space_image.c +++ b/source/blender/editors/space_image/space_image.c @@ -824,9 +824,11 @@ static void image_main_area_draw(const bContext *C, ARegion *ar) draw_image_grease_pencil((bContext *)C, 0); /* scrollers? */ - /*scrollers= UI_view2d_scrollers_calc(C, v2d, V2D_UNIT_VALUES, V2D_GRID_CLAMP, V2D_ARG_DUMMY, V2D_ARG_DUMMY); +#if 0 + scrollers= UI_view2d_scrollers_calc(C, v2d, V2D_UNIT_VALUES, V2D_GRID_CLAMP, V2D_ARG_DUMMY, V2D_ARG_DUMMY); UI_view2d_scrollers_draw(C, v2d, scrollers); - UI_view2d_scrollers_free(scrollers);*/ + UI_view2d_scrollers_free(scrollers); +#endif } static void image_main_area_listener(ARegion *ar, wmNotifier *wmn) -- cgit v1.2.3