Merging r58330 through r58361 from trunk into soc-2013-depsgraph_mt
authorSergey Sharybin <sergey.vfx@gmail.com>
Thu, 18 Jul 2013 09:29:12 +0000 (09:29 +0000)
committerSergey Sharybin <sergey.vfx@gmail.com>
Thu, 18 Jul 2013 09:29:12 +0000 (09:29 +0000)
18 files changed:
intern/cycles/kernel/kernel_light.h
intern/opencl/OCL_opencl.h
intern/opencl/intern/OCL_opencl.c
intern/opencl/intern/clew.c
release/scripts/startup/bl_operators/node.py
source/blender/blenkernel/BKE_fcurve.h
source/blender/blenkernel/intern/curve.c
source/blender/blenkernel/intern/fcurve.c
source/blender/collada/ArmatureImporter.cpp
source/blender/collada/ControllerExporter.cpp
source/blender/compositor/intern/COM_WorkScheduler.cpp
source/blender/editors/interface/interface.c
source/blender/editors/render/render_opengl.c
source/blender/editors/render/render_shading.c
source/blender/editors/space_action/action_edit.c
source/blender/imbuf/intern/cineon/logImageCore.c
source/blender/makesdna/DNA_curve_types.h
source/blender/makesrna/intern/rna_wm_api.c

index 4983122fb346b2f2a11dcd5042b6f98be99528c7..5091eac41db6f4a34ee93de0fa11129161a2f767 100644 (file)
@@ -271,7 +271,7 @@ __device void lamp_light_sample(KernelGlobals *kg, int lamp,
                        ls->pdf = invarea;
 
                        if(type == LIGHT_SPOT) {
-                               /* spot light attentuation */
+                               /* spot light attenuation */
                                float4 data2 = kernel_tex_fetch(__light_data, lamp*LIGHT_SIZE + 2);
                                ls->eval_fac *= spot_light_attenuation(data1, data2, ls);
                        }
index 4ee167b2fb43af597666fe86cc627f40009564c7..733e3527197416d16895d54761db44ad609556cf 100644 (file)
@@ -28,7 +28,7 @@ extern "C" {
 #endif
 
 #include "intern/clew.h"
-void OCL_init(void);
+int OCL_init(void);
 
 #ifdef __cplusplus
 }
index e3130e16bde7aae3ff833acf4c95a86f460f8083..33a936896fd7eaadd0d828238cf79c5630d75661 100644 (file)
@@ -22,7 +22,7 @@
 
 #include "OCL_opencl.h"
 
-void OCL_init(void)
+int OCL_init(void)
 {
 #ifdef _WIN32
        const char *path = "OpenCL.dll";
@@ -32,6 +32,6 @@ void OCL_init(void)
        const char *path = "libOpenCL.so";
 #endif
 
-       clewInit(path);
+       return (clewInit(path) == CLEW_SUCCESS);
 }
 
index d68eb17288f532e8d490b273f5a562ce42658f6a..1e31ebced0a042a083daf0b7433b904eed06949e 100644 (file)
@@ -227,6 +227,11 @@ int clewInit(const char* path)
     __oclEnqueueWaitForEvents          = (PFNCLENQUEUEWAITFOREVENTS        )CLCC_DYNLIB_IMPORT(module, "clEnqueueWaitForEvents");
     __oclEnqueueBarrier                = (PFNCLENQUEUEBARRIER              )CLCC_DYNLIB_IMPORT(module, "clEnqueueBarrier");
     __oclGetExtensionFunctionAddress   = (PFNCLGETEXTENSIONFUNCTIONADDRESS )CLCC_DYNLIB_IMPORT(module, "clGetExtensionFunctionAddress");
+       
+       if(__oclGetPlatformIDs == NULL) return CLEW_ERROR_OPEN_FAILED;
+       if(__oclGetPlatformInfo == NULL) return CLEW_ERROR_OPEN_FAILED;
+       if(__oclGetDeviceIDs == NULL) return CLEW_ERROR_OPEN_FAILED;
+       if(__oclGetDeviceInfo == NULL) return CLEW_ERROR_OPEN_FAILED;
 
     return CLEW_SUCCESS;
 }
index cc1fa93ec2c660ca3856e7e866ea20d8e40e4d27..c70b5832bfb9e853fe240a453778a5678a070305 100644 (file)
@@ -66,8 +66,12 @@ class NodeAddOperator():
 
         # convert mouse position to the View2D for later node placement
         if context.region.type == 'WINDOW':
+            # XXX, temp fix for [#35920], still fails for (U.pixelsize != 1)
+            dpi_fac = context.user_preferences.system.dpi / 72.0
             space.cursor_location = v2d.region_to_view(event.mouse_region_x,
                                                        event.mouse_region_y)
+            space.cursor_location /= dpi_fac
+
         else:
             space.cursor_location = tree.view_center
 
index d7ef04195d553574cad71dd726924f4d750aca44..64a6811bf519a1527351ce4017502de0d64a0c4e 100644 (file)
@@ -216,7 +216,7 @@ struct FCurve *rna_get_fcurve(struct PointerRNA *ptr, struct PropertyRNA *prop,
 int binarysearch_bezt_index(struct BezTriple array[], float frame, int arraylen, bool *r_replace);
 
 /* get the time extents for F-Curve */
-void calc_fcurve_range(struct FCurve *fcu, float *min, float *max,
+bool calc_fcurve_range(struct FCurve *fcu, float *min, float *max,
                        const short do_sel_only, const short do_min_length);
 
 /* get the bounding-box extents for F-Curve */
index b7926e5302f87c422e7fd08bb59163e59d2e07c9..fb4d8395777afde309d5eaef2ea0439d94ab07dc 100644 (file)
@@ -2362,6 +2362,7 @@ void BKE_curve_bevelList_make(Object *ob, ListBase *nurbs, bool for_render)
                        bl = MEM_callocN(sizeof(BevList) + 1 * sizeof(BevPoint), "makeBevelList1");
                        BLI_addtail(bev, bl);
                        bl->nr = 0;
+                       bl->charidx = nu->charidx;
                }
                else {
                        if (for_render && cu->resolu_ren != 0)
@@ -2374,10 +2375,10 @@ void BKE_curve_bevelList_make(Object *ob, ListBase *nurbs, bool for_render)
                                bl = MEM_callocN(sizeof(BevList) + len * sizeof(BevPoint), "makeBevelList2");
                                BLI_addtail(bev, bl);
 
-                               if (nu->flagu & CU_NURB_CYCLIC) bl->poly = 0;
-                               else bl->poly = -1;
+                               bl->poly = (nu->flagu & CU_NURB_CYCLIC) ? 0 : -1;
                                bl->nr = len;
                                bl->dupe_nr = 0;
+                               bl->charidx = nu->charidx;
                                bevp = (BevPoint *)(bl + 1);
                                bp = nu->bp;
 
@@ -2397,8 +2398,8 @@ void BKE_curve_bevelList_make(Object *ob, ListBase *nurbs, bool for_render)
                                bl = MEM_callocN(sizeof(BevList) + len * sizeof(BevPoint), "makeBevelBPoints");
                                BLI_addtail(bev, bl);
 
-                               if (nu->flagu & CU_NURB_CYCLIC) bl->poly = 0;
-                               else bl->poly = -1;
+                               bl->poly = (nu->flagu & CU_NURB_CYCLIC) ? 0 : -1;
+                               bl->charidx = nu->charidx;
                                bevp = (BevPoint *)(bl + 1);
 
                                a = nu->pntsu - 1;
@@ -2484,8 +2485,8 @@ void BKE_curve_bevelList_make(Object *ob, ListBase *nurbs, bool for_render)
                                        BLI_addtail(bev, bl);
                                        bl->nr = len;
                                        bl->dupe_nr = 0;
-                                       if (nu->flagu & CU_NURB_CYCLIC) bl->poly = 0;
-                                       else bl->poly = -1;
+                                       bl->poly = (nu->flagu & CU_NURB_CYCLIC) ? 0 : -1;
+                                       bl->charidx = nu->charidx;
                                        bevp = (BevPoint *)(bl + 1);
 
                                        BKE_nurb_makeCurve(nu, &bevp->vec[0],
@@ -2611,9 +2612,11 @@ void BKE_curve_bevelList_make(Object *ob, ListBase *nurbs, bool for_render)
                        bl = sd->bl;     /* is bl a hole? */
                        sd1 = sortdata + (a - 1);
                        for (b = a - 1; b >= 0; b--, sd1--) { /* all polys to the left */
-                               if (bevelinside(sd1->bl, bl)) {
-                                       bl->hole = 1 - sd1->bl->hole;
-                                       break;
+                               if (sd1->bl->charidx == bl->charidx) { /* for text, only check matching char */
+                                       if (bevelinside(sd1->bl, bl)) {
+                                               bl->hole = 1 - sd1->bl->hole;
+                                               break;
+                                       }
                                }
                        }
                }
index 8958680d611198c6f58bef5bd71853958763f071..bd282095c333943a10d8634c2f88dbd82361b0cb 100644 (file)
@@ -577,7 +577,7 @@ short calc_fcurve_bounds(FCurve *fcu, float *xmin, float *xmax, float *ymin, flo
 }
 
 /* Calculate the extents of F-Curve's keyframes */
-void calc_fcurve_range(FCurve *fcu, float *start, float *end,
+bool calc_fcurve_range(FCurve *fcu, float *start, float *end,
                        const short do_sel_only, const short do_min_length)
 {
        float min = 999999999.0f, max = -999999999.0f;
@@ -621,6 +621,8 @@ void calc_fcurve_range(FCurve *fcu, float *start, float *end,
 
        *start = min;
        *end = max;
+
+       return foundvert;
 }
 
 /* ----------------- Status Checks -------------------------- */
index 0cd48707566c3d699a6a8ede2b7a2e3799b679dc..eb92b089f481dca9f93a9769f75f3babaded659c 100644 (file)
@@ -133,24 +133,28 @@ void ArmatureImporter::create_bone(SkinInfo *skin, COLLADAFW::Node *node, EditBo
        add_v3_v3v3(bone->tail, bone->head, vec);
 
        // set parent tail
-       if (parent && totchild == 1) {
-               copy_v3_v3(parent->tail, bone->head);
-
-               // not setting BONE_CONNECTED because this would lock child bone location with respect to parent
-               bone->flag |= BONE_CONNECTED;
+       if (parent) {
 
                // XXX increase this to prevent "very" small bones?
                const float epsilon = 0.000001f;
 
                // derive leaf bone length
-               float length = len_v3v3(parent->head, parent->tail);
+               float length = len_v3v3(parent->head, bone->head);
                if ((length < leaf_bone_length || totbone == 0) && length > epsilon) {
                        leaf_bone_length = length;
                }
 
-               // treat zero-sized bone like a leaf bone
-               if (length <= epsilon) {
-                       add_leaf_bone(parent_mat, parent, node);
+               if (totchild == 1) {
+                       copy_v3_v3(parent->tail, bone->head);
+
+                       // not setting BONE_CONNECTED because this would lock child bone location with respect to parent
+                       bone->flag |= BONE_CONNECTED;
+
+
+                       // treat zero-sized bone like a leaf bone
+                       if (length <= epsilon) {
+                               add_leaf_bone(parent_mat, parent, node);
+                       }
                }
 
        }
index 4c6f71ff1a6e099d8730a8e94a25a58b1878b9f4..d04ed8d6fa1f54cce007bac048b564295d1844a1 100644 (file)
@@ -123,7 +123,7 @@ void ControllerExporter::operator()(Object *ob)
        if (ob_arm) {
                export_skin_controller(ob, ob_arm);
        }
-       if (key) {
+       if (key && this->export_settings->include_shapekeys) {
                export_morph_controller(ob, key);
        }
 }
index 402fa28e210c856a1eced34cd09a1cae322dae74..e0ac767b6287e1201579f351f8db597a3bb198e0 100644 (file)
@@ -304,7 +304,8 @@ void WorkScheduler::initialize(bool use_opencl)
                g_context = NULL;
                g_program = NULL;
 
-               OCL_init(); /* this will check and skip if already initialized */
+               if (!OCL_init()) /* this will check for errors and skip if already initialized */
+                       return;
 
                if (clCreateContextFromType) {
                        cl_uint numberOfPlatforms = 0;
index 097f042d6c9a2dff2cb33f11711e64943c25bac1..b59e06cbc0e3bcce4405824dff6ba6001d10a039 100644 (file)
@@ -962,10 +962,10 @@ static bool ui_but_event_property_operator_string(const bContext *C, uiBut *but,
                                                data_path = BLI_sprintfN("scene.%s", path);
                                                MEM_freeN(path);
                                        }
-                                       else {
+                                       /*else {
                                                printf("ERROR in %s(): Couldn't get path for scene property - %s\n", 
                                                       __func__, RNA_property_identifier(but->rnaprop));
-                                       }
+                                       }*/
                                }
                        }
                        else {
index 13379425258dd06126957ec5c27cd90a4e4ed27f..93ae913cee0481f11fa53c279a96c86695ec60af 100644 (file)
@@ -107,6 +107,10 @@ typedef struct OGLRender {
        bMovieHandle *mh;
        int cfrao, nfra;
 
+       /* wm vars for timer and progress cursor */
+       wmWindowManager *wm;
+       wmWindow *win;
+
        wmTimer *timer; /* use to check if running modal or not (invoke'd or exec'd)*/
 } OGLRender;
 
@@ -327,6 +331,9 @@ static void screen_opengl_render_apply(OGLRender *oglrender)
 static int screen_opengl_render_init(bContext *C, wmOperator *op)
 {
        /* new render clears all callbacks */
+       wmWindowManager *wm = CTX_wm_manager(C);
+       wmWindow *win = CTX_wm_window(C);
+
        Scene *scene = CTX_data_scene(C);
        ScrArea *prevsa = CTX_wm_area(C);
        ARegion *prevar = CTX_wm_region(C);
@@ -353,7 +360,7 @@ static int screen_opengl_render_init(bContext *C, wmOperator *op)
        }
 
        /* only one render job at a time */
-       if (WM_jobs_test(CTX_wm_manager(C), scene, WM_JOB_TYPE_RENDER))
+       if (WM_jobs_test(wm, scene, WM_JOB_TYPE_RENDER))
                return 0;
        
        if (!is_view_context && scene->camera == NULL) {
@@ -367,7 +374,7 @@ static int screen_opengl_render_init(bContext *C, wmOperator *op)
        }
 
        /* stop all running jobs, except screen one. currently previews frustrate Render */
-       WM_jobs_kill_all_except(CTX_wm_manager(C), CTX_wm_screen(C));
+       WM_jobs_kill_all_except(wm, CTX_wm_screen(C));
 
        /* create offscreen buffer */
        sizex = (scene->r.size * scene->r.xsch) / 100;
@@ -381,9 +388,6 @@ static int screen_opengl_render_init(bContext *C, wmOperator *op)
                return 0;
        }
 
-       /* handle UI stuff */
-       WM_cursor_wait(1);
-
        /* allocate opengl render */
        oglrender = MEM_callocN(sizeof(OGLRender), "OGLRender");
        op->customdata = oglrender;
@@ -441,6 +445,10 @@ static int screen_opengl_render_init(bContext *C, wmOperator *op)
                rr->rectf = MEM_callocN(sizeof(float) * 4 * sizex * sizey, "screen_opengl_render_init rect");
        RE_ReleaseResult(oglrender->re);
 
+       /* wm vars */
+       oglrender->wm = wm;
+       oglrender->win = win;
+
        return 1;
 }
 
@@ -458,10 +466,13 @@ static void screen_opengl_render_end(bContext *C, OGLRender *oglrender)
                scene->r.cfra = oglrender->cfrao;
                BKE_scene_update_for_newframe(bmain, scene, screen_opengl_layers(oglrender));
 
-               WM_event_remove_timer(CTX_wm_manager(C), CTX_wm_window(C), oglrender->timer);
+               WM_event_remove_timer(oglrender->wm, oglrender->win, oglrender->timer);
+       }
+
+       if (oglrender->win) {
+               WM_cursor_restore(oglrender->win);
        }
 
-       WM_cursor_wait(0);
        WM_event_add_notifier(C, NC_SCENE | ND_RENDER_RESULT, oglrender->scene);
 
        U.obcenter_dia = oglrender->obcenter_dia_back;
@@ -549,6 +560,10 @@ static int screen_opengl_render_anim_step(bContext *C, wmOperator *op)
                }
        }
 
+       if (oglrender->win) {
+               WM_cursor_time(oglrender->win, scene->r.cfra);
+       }
+
        BKE_scene_update_for_newframe(bmain, scene, screen_opengl_layers(oglrender));
 
        if (view_context) {
@@ -714,7 +729,7 @@ static int screen_opengl_render_invoke(bContext *C, wmOperator *op, const wmEven
        render_view_open(C, event->x, event->y);
        
        WM_event_add_modal_handler(C, op);
-       oglrender->timer = WM_event_add_timer(CTX_wm_manager(C), CTX_wm_window(C), TIMER, 0.01f);
+       oglrender->timer = WM_event_add_timer(oglrender->wm, oglrender->win, TIMER, 0.01f);
        
        return OPERATOR_RUNNING_MODAL;
 }
index 7a274396e86bf470138e2baee362a35f20a997ca..3cdc2c771fc7c64a22dc98eda5331c85e537b7c4 100644 (file)
@@ -110,6 +110,7 @@ static int material_slot_add_exec(bContext *C, wmOperator *UNUSED(op))
        object_add_material_slot(ob);
        WM_event_add_notifier(C, NC_OBJECT | ND_DRAW, ob);
        WM_event_add_notifier(C, NC_OBJECT | ND_OB_SHADING, ob);
+       WM_event_add_notifier(C, NC_MATERIAL | ND_SHADING_PREVIEW, ob);
        
        return OPERATOR_FINISHED;
 }
@@ -146,6 +147,7 @@ static int material_slot_remove_exec(bContext *C, wmOperator *op)
        DAG_id_tag_update(&ob->id, OB_RECALC_DATA);
        WM_event_add_notifier(C, NC_OBJECT | ND_DRAW, ob);
        WM_event_add_notifier(C, NC_OBJECT | ND_OB_SHADING, ob);
+       WM_event_add_notifier(C, NC_MATERIAL | ND_SHADING_PREVIEW, ob);
        
        return OPERATOR_FINISHED;
 }
index 803e7b71c775f1770574973bb5568f14cddff62d..7c9d867aad65fb1485a8ae18b0aacb0f55a7022b 100644 (file)
@@ -231,11 +231,12 @@ void ACTION_OT_markers_make_local(wmOperatorType *ot)
 /* *************************** Calculate Range ************************** */
 
 /* Get the min/max keyframes*/
-static void get_keyframe_extents(bAnimContext *ac, float *min, float *max, const short onlySel)
+static bool get_keyframe_extents(bAnimContext *ac, float *min, float *max, const short onlySel)
 {
        ListBase anim_data = {NULL, NULL};
        bAnimListElem *ale;
        int filter;
+       bool found = false;
        
        /* get data to filter, from Action or Dopesheet */
        /* XXX: what is sel doing here?!
@@ -261,6 +262,7 @@ static void get_keyframe_extents(bAnimContext *ac, float *min, float *max, const
                                        const float framenum = (float)gpf->framenum;
                                        *min = min_ff(*min, framenum);
                                        *max = max_ff(*max, framenum);
+                                       found = true;
                                }
                        }
                        else if (ale->datatype == ALE_MASKLAY) {
@@ -275,6 +277,7 @@ static void get_keyframe_extents(bAnimContext *ac, float *min, float *max, const
                                        const float framenum = (float)masklay_shape->frame;
                                        *min = min_ff(*min, framenum);
                                        *max = max_ff(*max, framenum);
+                                       found = true;
                                }
                        }
                        else {
@@ -282,16 +285,18 @@ static void get_keyframe_extents(bAnimContext *ac, float *min, float *max, const
                                float tmin, tmax;
 
                                /* get range and apply necessary scaling before processing */
-                               calc_fcurve_range(fcu, &tmin, &tmax, onlySel, TRUE);
+                               if (calc_fcurve_range(fcu, &tmin, &tmax, onlySel, TRUE)) {
 
-                               if (adt) {
-                                       tmin = BKE_nla_tweakedit_remap(adt, tmin, NLATIME_CONVERT_MAP);
-                                       tmax = BKE_nla_tweakedit_remap(adt, tmax, NLATIME_CONVERT_MAP);
-                               }
+                                       if (adt) {
+                                               tmin = BKE_nla_tweakedit_remap(adt, tmin, NLATIME_CONVERT_MAP);
+                                               tmax = BKE_nla_tweakedit_remap(adt, tmax, NLATIME_CONVERT_MAP);
+                                       }
 
-                               /* try to set cur using these values, if they're more extreme than previously set values */
-                               *min = min_ff(*min, tmin);
-                               *max = max_ff(*max, tmax);
+                                       /* try to set cur using these values, if they're more extreme than previously set values */
+                                       *min = min_ff(*min, tmin);
+                                       *max = max_ff(*max, tmax);
+                                       found = true;
+                               }
                        }
                }
                
@@ -309,6 +314,8 @@ static void get_keyframe_extents(bAnimContext *ac, float *min, float *max, const
                        *max = 100;
                }
        }
+
+       return found;
 }
 
 /* ****************** Automatic Preview-Range Operator ****************** */
@@ -357,11 +364,12 @@ void ACTION_OT_previewrange_set(wmOperatorType *ot)
 
 /* ****************** View-All Operator ****************** */
 
-static int actkeys_viewall(bContext *C, const short onlySel)
+static int actkeys_viewall(bContext *C, const bool only_sel, const bool only_xaxis)
 {
        bAnimContext ac;
        View2D *v2d;
        float extra;
+       bool found;
        
        /* get editor data */
        if (ANIM_animdata_get_context(C, &ac) == 0)
@@ -369,15 +377,20 @@ static int actkeys_viewall(bContext *C, const short onlySel)
        v2d = &ac.ar->v2d;
        
        /* set the horizontal range, with an extra offset so that the extreme keys will be in view */
-       get_keyframe_extents(&ac, &v2d->cur.xmin, &v2d->cur.xmax, onlySel);
+       found = get_keyframe_extents(&ac, &v2d->cur.xmin, &v2d->cur.xmax, only_sel);
+
+       if (only_sel && (found == false))
+               return OPERATOR_CANCELLED;
        
        extra = 0.1f * BLI_rctf_size_x(&v2d->cur);
        v2d->cur.xmin -= extra;
        v2d->cur.xmax += extra;
        
        /* set vertical range */
-       v2d->cur.ymax = 0.0f;
-       v2d->cur.ymin = (float)-BLI_rcti_size_y(&v2d->mask);
+       if (only_xaxis == false) {
+               v2d->cur.ymax = 0.0f;
+               v2d->cur.ymin = (float)-BLI_rcti_size_y(&v2d->mask);
+       }
        
        /* do View2D syncing */
        UI_view2d_sync(CTX_wm_screen(C), CTX_wm_area(C), v2d, V2D_LOCK_COPY);
@@ -393,13 +406,13 @@ static int actkeys_viewall(bContext *C, const short onlySel)
 static int actkeys_viewall_exec(bContext *C, wmOperator *UNUSED(op))
 {      
        /* whole range */
-       return actkeys_viewall(C, FALSE);
+       return actkeys_viewall(C, false, false);
 }
 
 static int actkeys_viewsel_exec(bContext *C, wmOperator *UNUSED(op))
 {
        /* only selected */
-       return actkeys_viewall(C, TRUE);
+       return actkeys_viewall(C, true, true);
 }
  
 void ACTION_OT_view_all(wmOperatorType *ot)
index d8d01d0cc5a55f731cad8c0ca9d516acf3541560..822f495d5bc70b66a7903c05b918aa870b9d4699 100644 (file)
@@ -925,7 +925,7 @@ static float *getLinToLogLut(LogImageFile *logImage, LogImageElement logElement)
        unsigned int lutsize = (unsigned int)(logElement.maxValue + 1);
        unsigned int i;
        
-       lut = MEM_mallocN(sizeof(float)*lutsize, "getLinToLogLut");
+       lut = MEM_mallocN(sizeof(float) * lutsize, "getLinToLogLut");
 
        negativeFilmGamma = 0.6;
        step = logElement.refHighQuantity / logElement.maxValue;
@@ -946,7 +946,7 @@ static float *getLogToLinLut(LogImageFile *logImage, LogImageElement logElement)
        unsigned int lutsize = (unsigned int)(logElement.maxValue + 1);
        unsigned int i;
        
-       lut = MEM_mallocN(sizeof(float)*lutsize, "getLogToLinLut");
+       lut = MEM_mallocN(sizeof(float) * lutsize, "getLogToLinLut");
 
        /* Building the Log -> Lin LUT */
        step = logElement.refHighQuantity / logElement.maxValue;
@@ -980,7 +980,7 @@ static float *getLinToSrgbLut(LogImageElement logElement)
        unsigned int lutsize = (unsigned int)(logElement.maxValue + 1);
        unsigned int i;
 
-       lut = MEM_mallocN(sizeof(float)*lutsize, "getLogToLinLut");
+       lut = MEM_mallocN(sizeof(float) * lutsize, "getLogToLinLut");
 
        for (i = 0; i < lutsize; i++) {
                col = (float)i / logElement.maxValue;
@@ -999,7 +999,7 @@ static float *getSrgbToLinLut(LogImageElement logElement)
        unsigned int lutsize = (unsigned int)(logElement.maxValue + 1);
        unsigned int i;
 
-       lut = MEM_mallocN(sizeof(float)*lutsize, "getLogToLinLut");
+       lut = MEM_mallocN(sizeof(float) * lutsize, "getLogToLinLut");
 
        for (i = 0; i < lutsize; i++) {
                col = (float)i / logElement.maxValue;
index 38cbd95b61fba138cf0bf6baf9530757b10241cb..1c99f9ac827bb5c9de742dc988ce5aa476a22a6c 100644 (file)
@@ -75,6 +75,7 @@ typedef struct BevList {
        struct BevList *next, *prev;
        int nr, dupe_nr;
        int poly, hole;
+       int charidx;
 } BevList;
 
 /* These two Lines with # tell makesdna this struct can be excluded. */
index 5805bcefdb4e8ad1d165c3b90679314d36dd9a37..c822378e76ef1330c47ebbf2bc0fd089b02b28f1 100644 (file)
@@ -333,17 +333,23 @@ void RNA_api_wm(StructRNA *srna)
 
        /* Progress bar interface */
        func = RNA_def_function(srna, "progress_begin", "rna_progress_begin");
+       RNA_def_function_ui_description(func, "Start Progress bar");
+
        parm = RNA_def_property(func, "min", PROP_FLOAT, PROP_NONE);
+       RNA_def_property_ui_text(parm, "min", "any value in range [0,9999]");
        RNA_def_property_flag(parm, PROP_REQUIRED);
+
        parm = RNA_def_property(func, "max", PROP_FLOAT, PROP_NONE);
        RNA_def_property_flag(parm, PROP_REQUIRED);
+       RNA_def_property_ui_text(parm, "max", "any value in range [min+1,9998]");
 
        func = RNA_def_function(srna, "progress_update", "rna_progress_update");
        parm = RNA_def_property(func, "value", PROP_FLOAT, PROP_NONE);
        RNA_def_property_flag(parm, PROP_REQUIRED);
-       RNA_def_property_ui_text(parm, "value", "any value between min and max as set in progress_init()");
+       RNA_def_property_ui_text(parm, "value", "any value between min and max as set in progress_begin()");
 
        func = RNA_def_function(srna, "progress_end", "rna_progress_end");
+       RNA_def_function_ui_description(func, "Terminate Progress bar");
 
        /* invoke functions, for use with python */
        func = RNA_def_function(srna, "invoke_props_popup", "rna_Operator_props_popup");