diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-04-15 14:28:32 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-04-15 14:28:32 +0400 |
commit | 9a85013692322f8a821b8228ad552f84d2a215e9 (patch) | |
tree | 666bb54fa093429d65b6b0322e8058c03f5fe223 /source/blender/makesrna/intern | |
parent | 2b018673509fe7a38a6332fae00bd605335bd286 (diff) |
Merge various small changes from render branch:
* Division by zero fix for TNT SVD code.
* Sound fix, in case ffmpeg decode fails, don't use the samples.
* Fix for incorrect bounds of transformed objects in new raytracing code.
* Gave memory arena's a name used for allocations for easier memory
usage debugging.
* Dupligroup no_draw option was using layers but not restrict view/render
setting. (not a bugfix exactly but would do display list context switching
while drawing for no reason).
* Fix objects instanced on hair particles not giving consistent results
when the object is transformed.
* New math functions: madd_v4_v4fl, len_squared_v3v3, interp_v4_v4v4v4,
mul_v4_m4v4, SH and form factor functions, box_minmax_bounds_m4.
* mul_m4_m4m4 and mul_m3_m3m3 now accept the same pointers for multiple
arguments.
* endjob callback for WM jobs system.
* Geometry node uv/color layer now has search list/autocomplete.
* Various small buildsystem tweaks, not strictly needed yet in trunk.
Diffstat (limited to 'source/blender/makesrna/intern')
-rw-r--r-- | source/blender/makesrna/intern/makesrna.c | 10 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_object.c | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_object_force.c | 2 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_scene.c | 3 |
4 files changed, 10 insertions, 7 deletions
diff --git a/source/blender/makesrna/intern/makesrna.c b/source/blender/makesrna/intern/makesrna.c index c9db05c30b1..c568fea38d7 100644 --- a/source/blender/makesrna/intern/makesrna.c +++ b/source/blender/makesrna/intern/makesrna.c @@ -30,7 +30,9 @@ #include "MEM_guardedalloc.h" +#include "RNA_access.h" #include "RNA_define.h" +#include "RNA_types.h" #include "rna_internal.h" @@ -483,13 +485,13 @@ static char *rna_def_property_get_func(FILE *f, StructRNA *srna, PropertyRNA *pr if(dp->dnaarraylength == 1) { if(prop->type == PROP_BOOLEAN && dp->booleanbit) - fprintf(f, " values[i]= (%s(data->%s & (%d<<i)) != 0);\n", (dp->booleannegative)? "!": "", dp->dnaname, dp->booleanbit); + fprintf(f, " values[i]= %s((data->%s & (%d<<i)) != 0);\n", (dp->booleannegative)? "!": "", dp->dnaname, dp->booleanbit); else fprintf(f, " values[i]= (%s)%s((&data->%s)[i]);\n", rna_type_type(prop), (dp->booleannegative)? "!": "", dp->dnaname); } else { if(prop->type == PROP_BOOLEAN && dp->booleanbit) { - fprintf(f, " values[i]= (%s(data->%s[i] & ", (dp->booleannegative)? "!": "", dp->dnaname); + fprintf(f, " values[i]= %s((data->%s[i] & ", (dp->booleannegative)? "!": "", dp->dnaname); rna_int_print(f, dp->booleanbit); fprintf(f, ") != 0);\n"); } @@ -514,7 +516,7 @@ static char *rna_def_property_get_func(FILE *f, StructRNA *srna, PropertyRNA *pr else { rna_print_data_get(f, dp); if(prop->type == PROP_BOOLEAN && dp->booleanbit) { - fprintf(f, " return (%s((data->%s) & ", (dp->booleannegative)? "!": "", dp->dnaname); + fprintf(f, " return %s(((data->%s) & ", (dp->booleannegative)? "!": "", dp->dnaname); rna_int_print(f, dp->booleanbit); fprintf(f, ") != 0);\n"); } @@ -1684,7 +1686,7 @@ static const char *rna_property_subtype_unit(PropertyType type) case PROP_UNIT_TIME: return "PROP_UNIT_TIME"; case PROP_UNIT_VELOCITY: return "PROP_UNIT_VELOCITY"; case PROP_UNIT_ACCELERATION:return "PROP_UNIT_ACCELERATION"; - default: return "PROP_UNKNOWN"; + default: return "PROP_UNIT_UNKNOWN"; } } diff --git a/source/blender/makesrna/intern/rna_object.c b/source/blender/makesrna/intern/rna_object.c index 6d1ae6db562..42c9b3d38e7 100644 --- a/source/blender/makesrna/intern/rna_object.c +++ b/source/blender/makesrna/intern/rna_object.c @@ -1322,7 +1322,7 @@ static void rna_def_object_modifiers(BlenderRNA *brna, PropertyRNA *cprop) /* add target */ func= RNA_def_function(srna, "new", "rna_Object_modifier_new"); RNA_def_function_flag(func, FUNC_USE_CONTEXT|FUNC_USE_REPORTS); - RNA_def_function_ui_description(func, "Add a new bone."); + RNA_def_function_ui_description(func, "Add a new modifier."); parm= RNA_def_string(func, "name", "Name", 0, "", "New name for the bone."); RNA_def_property_flag(parm, PROP_REQUIRED); /* modifier to add */ diff --git a/source/blender/makesrna/intern/rna_object_force.c b/source/blender/makesrna/intern/rna_object_force.c index 238098e85e2..4cd092972d1 100644 --- a/source/blender/makesrna/intern/rna_object_force.c +++ b/source/blender/makesrna/intern/rna_object_force.c @@ -869,8 +869,6 @@ static void rna_def_effector_weight(BlenderRNA *brna) /* General */ prop= RNA_def_property(srna, "group", PROP_POINTER, PROP_NONE); - RNA_def_property_pointer_sdna(prop, NULL, "group"); - RNA_def_property_struct_type(prop, "Group"); RNA_def_property_flag(prop, PROP_EDITABLE); RNA_def_property_ui_text(prop, "Effector Group", "Limit effectors to this Group"); RNA_def_property_update(prop, 0, "rna_EffectorWeight_dependency_update"); diff --git a/source/blender/makesrna/intern/rna_scene.c b/source/blender/makesrna/intern/rna_scene.c index e5c6d970687..7e186f0a587 100644 --- a/source/blender/makesrna/intern/rna_scene.c +++ b/source/blender/makesrna/intern/rna_scene.c @@ -2366,6 +2366,7 @@ static void rna_def_scene_render_data(BlenderRNA *brna) RNA_def_property_ui_text(prop, "Edge Color", ""); RNA_def_property_update(prop, NC_SCENE|ND_RENDER_OPTIONS, NULL); + /* threads */ prop= RNA_def_property(srna, "threads", PROP_INT, PROP_NONE); RNA_def_property_int_sdna(prop, NULL, "threads"); RNA_def_property_range(prop, 1, BLENDER_MAX_THREADS); @@ -2379,6 +2380,7 @@ static void rna_def_scene_render_data(BlenderRNA *brna) RNA_def_property_ui_text(prop, "Threads Mode", "Determine the amount of render threads used"); RNA_def_property_update(prop, NC_SCENE|ND_RENDER_OPTIONS, NULL); + /* motion blur */ prop= RNA_def_property(srna, "motion_blur", PROP_BOOLEAN, PROP_NONE); RNA_def_property_boolean_sdna(prop, NULL, "mode", R_MBLUR); RNA_def_property_ui_text(prop, "Motion Blur", "Use multi-sampled 3D scene motion blur"); @@ -2390,6 +2392,7 @@ static void rna_def_scene_render_data(BlenderRNA *brna) RNA_def_property_ui_text(prop, "Motion Samples", "Number of scene samples to take with motion blur"); RNA_def_property_update(prop, NC_SCENE|ND_RENDER_OPTIONS, NULL); + /* border */ prop= RNA_def_property(srna, "use_border", PROP_BOOLEAN, PROP_NONE); RNA_def_property_boolean_sdna(prop, NULL, "mode", R_BORDER); RNA_def_property_ui_text(prop, "Border", "Render a user-defined border region, within the frame size. Note, this disables save_buffers and full_sample"); |