[Bf-blender-cvs] [099ce95ef36] master: UI: Add auto keyframing popover
Commit: 099ce95ef36d8d1bb4fd49d5be94ad60d4831978 Author: Hans Goudey Date: Tue Oct 6 15:17:36 2020 -0500 Branches: master https://developer.blender.org/rB099ce95ef36d8d1bb4fd49d5be94ad60d4831978 UI: Add auto keyframing popover For other areas in Blender that have a toggle and related settings, we put a popover with the settings right next to the toggle. This combination is nice because it organizes the settings without making interaction slower. It also makes the settings more discoverable since they're right next to the toggle. Differential Revision: https://developer.blender.org/D8537 === M release/scripts/startup/bl_ui/space_time.py === diff --git a/release/scripts/startup/bl_ui/space_time.py b/release/scripts/startup/bl_ui/space_time.py index 62b765c7d32..290bbdb1ab6 100644 --- a/release/scripts/startup/bl_ui/space_time.py +++ b/release/scripts/startup/bl_ui/space_time.py @@ -32,7 +32,14 @@ class TIME_HT_editor_buttons: layout.separator_spacer() -layout.prop(tool_settings, "use_keyframe_insert_auto", text="", toggle=True) +row = layout.row(align=True) +row.prop(tool_settings, "use_keyframe_insert_auto", text="", toggle=True) +sub = row.row(align=True) +sub.active = tool_settings.use_keyframe_insert_auto +sub.popover( +panel="TIME_PT_auto_keyframing", +text="", +) row = layout.row(align=True) row.operator("screen.frame_jump", text="", icon='REW').end = False @@ -278,28 +285,45 @@ class TIME_PT_keyframing_settings(TimelinePanelButtons, Panel): scene = context.scene tool_settings = context.tool_settings -prefs = context.preferences col = layout.column(align=True) -col.label(text="Active Keying Set:") +col.label(text="Active Keying Set") row = col.row(align=True) row.prop_search(scene.keying_sets_all, "active", scene, "keying_sets_all", text="") row.operator("anim.keyframe_insert", text="", icon='KEY_HLT') row.operator("anim.keyframe_delete", text="", icon='KEY_DEHLT') col = layout.column(align=True) -col.label(text="New Keyframe Type:") +col.label(text="New Keyframe Type") col.prop(tool_settings, "keyframe_type", text="") +class TIME_PT_auto_keyframing(TimelinePanelButtons, Panel): +bl_label = "Auto Keyframing" +bl_options = {'HIDE_HEADER'} +bl_region_type = 'HEADER' +bl_ui_units_x = 9 + +@classmethod +def poll(cls, context): +# Only for timeline editor. +return cls.has_timeline(context) + +def draw(self, context): +layout = self.layout + +tool_settings = context.tool_settings +prefs = context.preferences + +layout.active = tool_settings.use_keyframe_insert_auto + +layout.prop(tool_settings, "auto_keying_mode", expand=True) + col = layout.column(align=True) -col.label(text="Auto Keyframing:") -row = col.row() -row.prop(tool_settings, "auto_keying_mode", text="") -row.prop(tool_settings, "use_keyframe_insert_keyingset", text="") +col.prop(tool_settings, "use_keyframe_insert_keyingset", text="Only Active Keying Set", toggle=False) if not prefs.edit.use_keyframe_insert_available: col.prop(tool_settings, "use_record_with_nla", text="Layered Recording") -layout.prop(tool_settings, "use_keyframe_cycle_aware") +col.prop(tool_settings, "use_keyframe_cycle_aware") ### @@ -311,6 +335,7 @@ classes = ( TIME_MT_cache, TIME_PT_playback, TIME_PT_keyframing_settings, +TIME_PT_auto_keyframing, ) if __name__ == "__main__": # only for live edit. ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [eb68cd713b1] master: Fix T81465: Snapping to edge center doesn't work as expected when using axis locking
Commit: eb68cd713b151d97394cd9c9d12d9ee8148970ec Author: Germano Cavalcante Date: Tue Oct 6 16:19:22 2020 -0300 Branches: master https://developer.blender.org/rBeb68cd713b151d97394cd9c9d12d9ee8148970ec Fix T81465: Snapping to edge center doesn't work as expected when using axis locking The result was being affected by the view alignment correction. Regression introduced in rB4eda60c2d82d === M source/blender/editors/transform/transform_constraints.c === diff --git a/source/blender/editors/transform/transform_constraints.c b/source/blender/editors/transform/transform_constraints.c index 9cb8d97393a..ac27f2cd7aa 100644 --- a/source/blender/editors/transform/transform_constraints.c +++ b/source/blender/editors/transform/transform_constraints.c @@ -384,9 +384,9 @@ static void applyAxisConstraintVec( if (activeSnap(t)) { if (validSnap(t)) { -is_snap_to_point = (t->tsnap.snapElem & SCE_SNAP_MODE_VERTEX) != 0; is_snap_to_edge = (t->tsnap.snapElem & SCE_SNAP_MODE_EDGE) != 0; is_snap_to_face = (t->tsnap.snapElem & SCE_SNAP_MODE_FACE) != 0; +is_snap_to_point = !is_snap_to_edge && !is_snap_to_face; } else if (t->tsnap.snapElem & SCE_SNAP_MODE_GRID) { is_snap_to_point = true; ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [183c4af6923] soc-2020-io-performance: Cleanup: edit comments, spellings.
Commit: 183c4af692355ac0b4596ddd0594f96625839752 Author: Ankit Meel Date: Tue Oct 6 23:07:58 2020 +0530 Branches: soc-2020-io-performance https://developer.blender.org/rB183c4af692355ac0b4596ddd0594f96625839752 Cleanup: edit comments, spellings. === M source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc M source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh M source/blender/io/wavefront_obj/intern/obj_export_mtl.cc === diff --git a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc index 050ddf1e0a1..ee5fbf0b78c 100644 --- a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc +++ b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc @@ -320,7 +320,7 @@ void OBJWriter::write_vertex_group(const OBJMesh &obj_mesh_data, } /** - * Select which syntax to write polygon elements with. + * Select which OBJ syntax to write polygon elements with. */ OBJWriter::func_vert_uv_normal_indices OBJWriter::get_poly_element_writer( const OBJMesh &obj_mesh_data) @@ -420,21 +420,22 @@ void OBJWriter::write_nurbs_curve(const OBJCurve &obj_nurbs_data) const nurbs_name, nurbs_degree); /** - * The numbers here are indices into the point vertex coordinates written above. + * The numbers here are indices into the vertex coordinates written + * above, relative to the line that is going to be written. + * [0.0 - 1.0] is the curve parameter range. * 0.0 1.0 -1 -2 -3 -4 for a non-cyclic curve with 4 points. * 0.0 1.0 -1 -2 -3 -4 -1 -2 -3 for a cyclic curve with 4 points. */ const int total_control_points = obj_nurbs_data.get_nurbs_num(i); -/* [0.0 - 1.0] is the curve parameter range. */ fputs("curv 0.0 1.0", outfile_); for (int i = 0; i < total_control_points; i++) { - /* + 1 to keep indices one-based, even if they're negative. */ + /* "+1" to keep indices one-based, even if they're negative. */ fprintf(outfile_, " %d", -((i % tot_points) + 1)); } fputs("\n", outfile_); /** - * In "parm u 0 0.1 .." line:, total control points + 2 equidistant numbers in the paramter + * In "parm u 0 0.1 .." line:, total control points + 2 equidistant numbers in the parameter * range are inserted. */ fputs("parm u 0.00 ", outfile_); diff --git a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh index f72da42e3a8..332c30f3780 100644 --- a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh +++ b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh @@ -86,12 +86,12 @@ class OBJWriter { void update_index_offsets(const OBJMesh &obj_mesh_data); private: - /* Based on export parameters, a writer function with correct OBJ syntax is needed. */ + /* Based on export parameters, a writer function with appropriate OBJ syntax is needed. */ typedef void (OBJWriter::*func_vert_uv_normal_indices)(Span vert_indices, Span uv_indices, Span normal_indices) const; - func_vert_uv_normal_indices get_poly_element_writer(const OBJMesh &obj_mesh_data); + void write_vert_uv_normal_indices(Span vert_indices, Span uv_indices, Span normal_indices) const; diff --git a/source/blender/io/wavefront_obj/intern/obj_export_mtl.cc b/source/blender/io/wavefront_obj/intern/obj_export_mtl.cc index d432e3c5e5c..bfb8e0e7cd1 100644 --- a/source/blender/io/wavefront_obj/intern/obj_export_mtl.cc +++ b/source/blender/io/wavefront_obj/intern/obj_export_mtl.cc @@ -131,7 +131,7 @@ static const bNode *get_node_of_type(Span socket /** * From a texture image shader node, get the image's filepath. - * Returned filepath is stripped of inital "//". If packed image is found, + * Returned filepath is stripped of initial "//". If packed image is found, * only the file "name" is returned. */ static const char *get_image_filepath(const bNode *tex_node) @@ -159,7 +159,7 @@ static const char *get_image_filepath(const bNode *tex_node) } /** - * Find the Principled-BSDF from the object's node tree & initialise class member. + * Find the Principled-BSDF from the object's node tree & initialize class member. */ void MaterialWrap::init_bsdf_node(StringRefNull object_name) { ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [670c103f107] soc-2020-io-performance: Move files to exporter and importer folder.
Commit: 670c103f107d6926f019c512894fee3ceb39098f Author: Ankit Meel Date: Wed Oct 7 00:08:20 2020 +0530 Branches: soc-2020-io-performance https://developer.blender.org/rB670c103f107d6926f019c512894fee3ceb39098f Move files to exporter and importer folder. === M source/blender/io/wavefront_obj/CMakeLists.txt R100source/blender/io/wavefront_obj/intern/wavefront_obj.cc source/blender/io/wavefront_obj/IO_wavefront_obj.cc R100source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc source/blender/io/wavefront_obj/exporter/obj_export_file_writer.cc R100source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh source/blender/io/wavefront_obj/exporter/obj_export_file_writer.hh R100source/blender/io/wavefront_obj/intern/obj_export_mesh.cc source/blender/io/wavefront_obj/exporter/obj_export_mesh.cc R100source/blender/io/wavefront_obj/intern/obj_export_mesh.hh source/blender/io/wavefront_obj/exporter/obj_export_mesh.hh R100source/blender/io/wavefront_obj/intern/obj_export_mtl.cc source/blender/io/wavefront_obj/exporter/obj_export_mtl.cc R100source/blender/io/wavefront_obj/intern/obj_export_mtl.hh source/blender/io/wavefront_obj/exporter/obj_export_mtl.hh R100source/blender/io/wavefront_obj/intern/obj_export_nurbs.cc source/blender/io/wavefront_obj/exporter/obj_export_nurbs.cc R100source/blender/io/wavefront_obj/intern/obj_export_nurbs.hh source/blender/io/wavefront_obj/exporter/obj_export_nurbs.hh R100source/blender/io/wavefront_obj/intern/obj_exporter.cc source/blender/io/wavefront_obj/exporter/obj_exporter.cc R100source/blender/io/wavefront_obj/intern/obj_exporter.hh source/blender/io/wavefront_obj/exporter/obj_exporter.hh R100source/blender/io/wavefront_obj/intern/importer_mesh_utils.cc source/blender/io/wavefront_obj/importer/importer_mesh_utils.cc R100source/blender/io/wavefront_obj/intern/importer_mesh_utils.hh source/blender/io/wavefront_obj/importer/importer_mesh_utils.hh R100source/blender/io/wavefront_obj/intern/obj_import_file_reader.cc source/blender/io/wavefront_obj/importer/obj_import_file_reader.cc R100source/blender/io/wavefront_obj/intern/obj_import_file_reader.hh source/blender/io/wavefront_obj/importer/obj_import_file_reader.hh R100source/blender/io/wavefront_obj/intern/obj_import_mesh.cc source/blender/io/wavefront_obj/importer/obj_import_mesh.cc R100source/blender/io/wavefront_obj/intern/obj_import_mesh.hh source/blender/io/wavefront_obj/importer/obj_import_mesh.hh R100source/blender/io/wavefront_obj/intern/obj_import_mtl.cc source/blender/io/wavefront_obj/importer/obj_import_mtl.cc R100source/blender/io/wavefront_obj/intern/obj_import_mtl.hh source/blender/io/wavefront_obj/importer/obj_import_mtl.hh R100source/blender/io/wavefront_obj/intern/obj_import_nurbs.cc source/blender/io/wavefront_obj/importer/obj_import_nurbs.cc R100source/blender/io/wavefront_obj/intern/obj_import_nurbs.hh source/blender/io/wavefront_obj/importer/obj_import_nurbs.hh R100source/blender/io/wavefront_obj/intern/obj_import_objects.cc source/blender/io/wavefront_obj/importer/obj_import_objects.cc R100source/blender/io/wavefront_obj/intern/obj_import_objects.hh source/blender/io/wavefront_obj/importer/obj_import_objects.hh R100source/blender/io/wavefront_obj/intern/obj_importer.cc source/blender/io/wavefront_obj/importer/obj_importer.cc R100source/blender/io/wavefront_obj/intern/obj_importer.hh source/blender/io/wavefront_obj/importer/obj_importer.hh R100source/blender/io/wavefront_obj/intern/parser_string_utils.cc source/blender/io/wavefront_obj/importer/parser_string_utils.cc R100source/blender/io/wavefront_obj/intern/parser_string_utils.hh source/blender/io/wavefront_obj/importer/parser_string_utils.hh === diff --git a/source/blender/io/wavefront_obj/CMakeLists.txt b/source/blender/io/wavefront_obj/CMakeLists.txt index 184098a226c..b48ec67cf68 100644 --- a/source/blender/io/wavefront_obj/CMakeLists.txt +++ b/source/blender/io/wavefront_obj/CMakeLists.txt @@ -20,6 +20,8 @@ set(INC . + ./exporter + ./importer ../../blenkernel ../../blenlib ../../bmesh @@ -38,35 +40,35 @@ set(INC_SYS ) set(SRC - intern/importer_mesh_utils.cc - intern/obj_exporter.cc - intern/obj_export_mesh.cc - intern/obj_export_mtl.cc - intern/obj_export_nurbs.cc - intern/obj_export_file_writer.cc - intern/obj_import_file_reader.cc - intern/obj_importer.cc - intern/obj_import_mesh.cc - intern/obj_import_mtl.cc - intern/obj_import_nurbs.cc - intern/obj_import_objects.cc - intern/parser_string_utils.cc - intern/wavefront_obj.cc + IO_wavefront_obj.cc + exporter/obj_exporter.cc + exporter/obj_export_mesh.cc + exporter/ob
[Bf-blender-cvs] [85f809ca390] soc-2020-io-performance: Remove writer's destructor to .cc file
Commit: 85f809ca3902c3eee136e4c18fabd83e1397f422 Author: Ankit Meel Date: Tue Oct 6 22:32:55 2020 +0530 Branches: soc-2020-io-performance https://developer.blender.org/rB85f809ca3902c3eee136e4c18fabd83e1397f422 Remove writer's destructor to .cc file === M source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc M source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh === diff --git a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc index 3d7c9301a5f..050ddf1e0a1 100644 --- a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc +++ b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc @@ -120,6 +120,14 @@ void OBJWriter::write_vert_indices(Span vert_indices, Span, Span) fputs("\n", outfile_); } +OBJWriter::~OBJWriter() +{ + if (outfile_ && fclose(outfile_)) { +std::cerr << "Error: could not close the OBJ file properly, file may be corrupted." + << std::endl; + } +} + /** * Try to open the OBJ file and write file header. * \return Whether the destination file is writable. diff --git a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh index fd8801bbcce..f72da42e3a8 100644 --- a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh +++ b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh @@ -60,13 +60,7 @@ class OBJWriter { OBJWriter(const OBJExportParams &export_params) : export_params_(export_params) { } - ~OBJWriter() - { -if (outfile_ && fclose(outfile_)) { - std::cerr << "Error: could not close the OBJ file properly, file may be corrupted." -<< std::endl; -} - } + ~OBJWriter(); bool init_writer(const char *filepath); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [f1a60130bd9] soc-2020-io-performance: Move normal indices update near normal writer code.
Commit: f1a60130bd94a4756a43c8cf74c5ba46d473e36c Author: Ankit Meel Date: Tue Oct 6 22:32:13 2020 +0530 Branches: soc-2020-io-performance https://developer.blender.org/rBf1a60130bd94a4756a43c8cf74c5ba46d473e36c Move normal indices update near normal writer code. Remove `per_object_tot_normals_` from member variable. === M source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc M source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh === diff --git a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc index ce302f13014..3d7c9301a5f 100644 --- a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc +++ b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.cc @@ -348,16 +348,16 @@ void OBJWriter::write_poly_elements(const OBJMesh &obj_mesh_data) Vector face_vertex_indices; Vector face_normal_indices; - /* Reset for every Object. */ - per_object_tot_normals_ = 0; + /** Number of normals may not be equal to number of polygons due to smooth shading. */ + int per_object_tot_normals = 0; const int tot_polygons = obj_mesh_data.tot_polygons(); for (int i = 0; i < tot_polygons; i++) { obj_mesh_data.calc_poly_vertex_indices(i, face_vertex_indices); /* For an Object, a normal index depends on how many have been written before it. * This is unknown because of smooth shading. So pass "per object total normals" * and update it after each call. */ -per_object_tot_normals_ += obj_mesh_data.calc_poly_normal_indices( -i, per_object_tot_normals_, face_normal_indices); +per_object_tot_normals += obj_mesh_data.calc_poly_normal_indices( +i, per_object_tot_normals, face_normal_indices); write_smooth_group(obj_mesh_data, i, last_face_smooth_group); write_vertex_group(obj_mesh_data, i, last_face_vertex_group); @@ -365,6 +365,7 @@ void OBJWriter::write_poly_elements(const OBJMesh &obj_mesh_data) (this->*poly_element_writer)( face_vertex_indices, obj_mesh_data.uv_indices(i), face_normal_indices); } + index_offsets_.normal_offset += per_object_tot_normals; } /** @@ -447,8 +448,7 @@ void OBJWriter::update_index_offsets(const OBJMesh &obj_mesh_data) { index_offsets_.vertex_offset += obj_mesh_data.tot_vertices(); index_offsets_.uv_vertex_offset += obj_mesh_data.tot_uv_vertices(); - index_offsets_.normal_offset += per_object_tot_normals_; - per_object_tot_normals_ = 0; + /* Normal index is updated right after writing the normals. */ } /* */ diff --git a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh index dfb42f53b04..fd8801bbcce 100644 --- a/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh +++ b/source/blender/io/wavefront_obj/intern/obj_export_file_writer.hh @@ -55,13 +55,6 @@ class OBJWriter { const OBJExportParams &export_params_; IndexOffsets index_offsets_{0, 0, 0}; - /** - * Total normals of an Object. It is not that same as `Mesh.tot_poly` due - * to unknown smooth groups which add loop normals for smooth faces. - * - * Used for updating normal offset. - */ - int per_object_tot_normals_ = 0; public: OBJWriter(const OBJExportParams &export_params) : export_params_(export_params) ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [43ceea30f11] master: Fix T81488: Deleting an Object Constraint crashes Blender
Commit: 43ceea30f11ef71be5f996624f8ba9ba549fa0fc Author: Hans Goudey Date: Tue Oct 6 13:07:36 2020 -0500 Branches: master https://developer.blender.org/rB43ceea30f11ef71be5f996624f8ba9ba549fa0fc Fix T81488: Deleting an Object Constraint crashes Blender The edit_constraint_property_get function was using bone constraints in pose mode even for object constraints. This change mirrors the code in `uiTemplateConstraints` as well. Differential Revision: https://developer.blender.org/D9128 === M source/blender/editors/object/object_constraint.c === diff --git a/source/blender/editors/object/object_constraint.c b/source/blender/editors/object/object_constraint.c index af04c4a3263..9b8a50cfe89 100644 --- a/source/blender/editors/object/object_constraint.c +++ b/source/blender/editors/object/object_constraint.c @@ -818,7 +818,7 @@ static bConstraint *edit_constraint_property_get(bContext *C, wmOperator *op, Ob list = ED_object_pose_constraint_list(C); } else { -list = ED_object_constraint_active_list(ob); +list = &ob->constraints; } con = BKE_constraints_find_name(list, constraint_name); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [a0ebfab4f3a] master: Fluid: Updated Mantaflow source files
Commit: a0ebfab4f3a31f08da651cf129982cbb419e0603 Author: Sebastián Barschkis Date: Tue Oct 6 18:17:20 2020 +0200 Branches: master https://developer.blender.org/rBa0ebfab4f3a31f08da651cf129982cbb419e0603 Fluid: Updated Mantaflow source files Among code cleanups, this update includes a new flood-fill helper function for levelsets. === M extern/mantaflow/helper/util/randomstream.h M extern/mantaflow/preprocessed/fileio/iovdb.cpp M extern/mantaflow/preprocessed/gitinfo.h M extern/mantaflow/preprocessed/grid.h M extern/mantaflow/preprocessed/levelset.cpp M extern/mantaflow/preprocessed/levelset.h M extern/mantaflow/preprocessed/levelset.h.reg.cpp M extern/mantaflow/preprocessed/plugin/initplugins.cpp === diff --git a/extern/mantaflow/helper/util/randomstream.h b/extern/mantaflow/helper/util/randomstream.h index 6c20ddc6a14..5b477326f6f 100644 --- a/extern/mantaflow/helper/util/randomstream.h +++ b/extern/mantaflow/helper/util/randomstream.h @@ -377,19 +377,6 @@ class RandomStream { } /*! get a random number from the stream */ - inline double getDouble(void) - { -return mtr.rand(); - }; - inline float getFloat(void) - { -return (float)mtr.rand(); - }; - - inline float getFloat(float min, float max) - { -return mtr.rand(max - min) + min; - }; inline float getRandNorm(float mean, float var) { return mtr.randNorm(mean, var); @@ -400,12 +387,20 @@ class RandomStream { { return getFloat(); } + inline Real getReal(float min, float max) + { +return getFloat(min, max); + } #else inline Real getReal() { return getDouble(); } + inline Real getReal(double min, double max) + { +return getDouble(min, max); + } #endif inline Vec3 getVec3() @@ -422,6 +417,24 @@ class RandomStream { private: MTRand mtr; + + inline double getDouble(void) + { +return mtr.rand(); + }; + inline float getFloat(void) + { +return (float)mtr.rand(); + }; + + inline double getDouble(double min, double max) + { +return mtr.rand(max - min) + min; + }; + inline float getFloat(float min, float max) + { +return (float)(mtr.rand(max - min) + min); + }; }; } // namespace Manta diff --git a/extern/mantaflow/preprocessed/fileio/iovdb.cpp b/extern/mantaflow/preprocessed/fileio/iovdb.cpp index b31f7e0e760..b990274e1c4 100644 --- a/extern/mantaflow/preprocessed/fileio/iovdb.cpp +++ b/extern/mantaflow/preprocessed/fileio/iovdb.cpp @@ -405,6 +405,7 @@ int writeObjectsVDB(const string &filename, vdb_flags = openvdb::io::COMPRESS_NONE; break; } + default: case COMPRESSION_ZIP: { vdb_flags |= openvdb::io::COMPRESS_ZIP; break; @@ -445,6 +446,7 @@ int readObjectsVDB(const string &filename, std::vector *objects, floa (void)metadata; // Unused for now } catch (const openvdb::IoError &e) { +(void)e; // Unused for now debMsg("readObjectsVDB: Could not open vdb file " << filename, 1); file.close(); return 0; diff --git a/extern/mantaflow/preprocessed/gitinfo.h b/extern/mantaflow/preprocessed/gitinfo.h index e87c8739cf4..64367e0e096 100644 --- a/extern/mantaflow/preprocessed/gitinfo.h +++ b/extern/mantaflow/preprocessed/gitinfo.h @@ -1,3 +1,3 @@ -#define MANTA_GIT_VERSION "commit e2f6e59e3679f88e5100ae2145410cca4971b9df" +#define MANTA_GIT_VERSION "commit b8e557707805720ff00a8eb946db2ee5b9361b5a" diff --git a/extern/mantaflow/preprocessed/grid.h b/extern/mantaflow/preprocessed/grid.h index 9bd4e5d72d9..ec70cc953ff 100644 --- a/extern/mantaflow/preprocessed/grid.h +++ b/extern/mantaflow/preprocessed/grid.h @@ -355,7 +355,6 @@ class GridBase : public PbClass { return isInBounds(Vec3i(i, j, k), bnd); } -#ifdef BLENDER //! expose name field to Python for Blender void setName(const std::string &name) { @@ -386,7 +385,6 @@ class GridBase : public PbClass { } } -#endif protected: GridType mType; Vec3i mSize; diff --git a/extern/mantaflow/preprocessed/levelset.cpp b/extern/mantaflow/preprocessed/levelset.cpp index a6f9fb40f3f..122f71917eb 100644 --- a/extern/mantaflow/preprocessed/levelset.cpp +++ b/extern/mantaflow/preprocessed/levelset.cpp @@ -639,8 +639,207 @@ void LevelsetGrid::initFromFlags(const FlagGrid &flags, bool ignoreWalls) } } +/* Helper variables that are used in flood-fill functions. */ +static const int ID_UNKNOWN = 0; +static const int ID_VISITED = 1; + +/* Fills all cells in the target grid that have not been marked during a flood-fill. */ + +struct KnFillApply : public KernelBase { + KnFillApply(Grid &target, + Grid &visited, + const Real value, + const int boundaryWidth, + const bool outside) + : KernelBase(&target, boundaryWidth), +target(target), +
[Bf-blender-cvs] [55fd7f55bd1] master: Fluid: Enable new flood-fill helper function
Commit: 55fd7f55bd184851b321152d61cf9bc8b70cef44 Author: Sebastián Barschkis Date: Tue Oct 6 18:34:38 2020 +0200 Branches: master https://developer.blender.org/rB55fd7f55bd184851b321152d61cf9bc8b70cef44 Fluid: Enable new flood-fill helper function The flood-fill helper serves as a sanity check for scenes with complex obstacles. Similarly to the holes filler function it ensures that there are no holes in obstacles. In addition, it ensures that there will be no holes resulting from multiple intersecting obstacles. In general, this commit should improve stability. === M intern/mantaflow/intern/strings/liquid_script.h M intern/mantaflow/intern/strings/smoke_script.h === diff --git a/intern/mantaflow/intern/strings/liquid_script.h b/intern/mantaflow/intern/strings/liquid_script.h index c4e4efe46a4..f26930b5d03 100644 --- a/intern/mantaflow/intern/strings/liquid_script.h +++ b/intern/mantaflow/intern/strings/liquid_script.h @@ -186,14 +186,13 @@ def liquid_adaptive_step_$ID$(framenr):\n\ \n\ mantaMsg('Initializing obstacle levelset')\n\ phiObsIn_s$ID$.join(phiObsSIn_s$ID$) # Join static obstacle map\n\ -phiObsIn_s$ID$.fillHoles(maxDepth=int(res_s$ID$), boundaryWidth=1)\n\ +phiObsIn_s$ID$.floodFill(boundaryWidth=1)\n\ extrapolateLsSimple(phi=phiObsIn_s$ID$, distance=6, inside=True)\n\ extrapolateLsSimple(phi=phiObsIn_s$ID$, distance=3, inside=False)\n\ phiObs_s$ID$.join(phiObsIn_s$ID$)\n\ \n\ -# Using boundaryWidth=2 to not search beginning from walls (just a performance optimization)\n\ # Additional sanity check: fill holes in phiObs which can result after joining with phiObsIn\n\ -phiObs_s$ID$.fillHoles(maxDepth=int(res_s$ID$), boundaryWidth=2 if using_fractions_s$ID$ else 1)\n\ +phiObs_s$ID$.floodFill(boundaryWidth=2 if using_fractions_s$ID$ else 1)\n\ extrapolateLsSimple(phi=phiObs_s$ID$, distance=6, inside=True)\n\ extrapolateLsSimple(phi=phiObs_s$ID$, distance=3)\n\ \n\ diff --git a/intern/mantaflow/intern/strings/smoke_script.h b/intern/mantaflow/intern/strings/smoke_script.h index 370ffa0cc85..77ee5fa4077 100644 --- a/intern/mantaflow/intern/strings/smoke_script.h +++ b/intern/mantaflow/intern/strings/smoke_script.h @@ -289,14 +289,13 @@ def smoke_adaptive_step_$ID$(framenr):\n\ \n\ mantaMsg('Initializing obstacle levelset')\n\ phiObsIn_s$ID$.join(phiObsSIn_s$ID$) # Join static obstacle map\n\ -phiObsIn_s$ID$.fillHoles(maxDepth=int(res_s$ID$), boundaryWidth=1)\n\ +phiObsIn_s$ID$.floodFill(boundaryWidth=1)\n\ extrapolateLsSimple(phi=phiObsIn_s$ID$, distance=6, inside=True)\n\ extrapolateLsSimple(phi=phiObsIn_s$ID$, distance=3, inside=False)\n\ phiObs_s$ID$.join(phiObsIn_s$ID$)\n\ \n\ -# Using boundaryWidth=2 to not search beginning from walls (just a performance optimization)\n\ # Additional sanity check: fill holes in phiObs which can result after joining with phiObsIn\n\ -phiObs_s$ID$.fillHoles(maxDepth=int(res_s$ID$), boundaryWidth=1)\n\ +phiObs_s$ID$.floodFill(boundaryWidth=1)\n\ extrapolateLsSimple(phi=phiObs_s$ID$, distance=6, inside=True)\n\ extrapolateLsSimple(phi=phiObs_s$ID$, distance=3, inside=False)\n\ \n\ ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [2b72860ff44] master: Sculpt: Union and Join mode for trim tools
Commit: 2b72860ff4473255ac73519e5a66c085c0c1fbe8 Author: Pablo Dobarro Date: Tue Oct 6 18:07:39 2020 +0200 Branches: master https://developer.blender.org/rB2b72860ff4473255ac73519e5a66c085c0c1fbe8 Sculpt: Union and Join mode for trim tools This enables a union boolean mode for the trimming gestures tools which adds geometry to the mesh instead of cutting it. It also adds a Join mode, which adds the geometry directly without using a boolean operation. Depending if you plan to use dyntopo or not, it is useful to have both options available. This is using the full depth of the object from the camera view for the depth of the geometry, but options for controlling the trimming depth in all modes are going to be added in later patches Reviewed By: mont29 Differential Revision: https://developer.blender.org/D9066 === M release/scripts/startup/bl_ui/space_toolsystem_toolbar.py M source/blender/editors/sculpt_paint/paint_mask.c === diff --git a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py index e021433bee3..af263bf5d53 100644 --- a/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py +++ b/release/scripts/startup/bl_ui/space_toolsystem_toolbar.py @@ -1304,22 +1304,30 @@ class _defs_sculpt: @ToolDef.from_fn def trim_box(): +def draw_settings(_context, layout, tool): +props = tool.operator_properties("sculpt.trim_box_gesture") +layout.prop(props, "trim_mode", expand=False) return dict( idname="builtin.box_trim", label="Box Trim", icon="ops.sculpt.box_trim", widget=None, keymap=(), +draw_settings=draw_settings, ) @ToolDef.from_fn def trim_lasso(): +def draw_settings(_context, layout, tool): +props = tool.operator_properties("sculpt.trim_lasso_gesture") +layout.prop(props, "trim_mode", expand=False) return dict( idname="builtin.lasso_trim", label="Lasso Trim", icon="ops.sculpt.lasso_trim", widget=None, keymap=(), +draw_settings=draw_settings, ) @ToolDef.from_fn diff --git a/source/blender/editors/sculpt_paint/paint_mask.c b/source/blender/editors/sculpt_paint/paint_mask.c index f7e8abde021..622ea82bf25 100644 --- a/source/blender/editors/sculpt_paint/paint_mask.c +++ b/source/blender/editors/sculpt_paint/paint_mask.c @@ -821,11 +821,24 @@ static void paint_mask_gesture_operator_properties(wmOperatorType *ot) typedef enum eSculptTrimOperationType { SCULPT_GESTURE_TRIM_INTERSECT, SCULPT_GESTURE_TRIM_DIFFERENCE, + SCULPT_GESTURE_TRIM_UNION, + SCULPT_GESTURE_TRIM_JOIN, } eSculptTrimOperationType; +/* Intersect is not exposed in the UI because it does not work correctly with symmetry (it deletes + * the symmetrical part of the mesh in the first symmetry pass). */ static EnumPropertyItem prop_trim_operation_types[] = { -{SCULPT_GESTURE_TRIM_INTERSECT, "INTERSECT", 0, "Intersect", ""}, -{SCULPT_GESTURE_TRIM_DIFFERENCE, "DIFFERENCE", 0, "Difference", ""}, +{SCULPT_GESTURE_TRIM_DIFFERENCE, + "DIFFERENCE", + 0, + "Difference", + "Use a difference boolean operation"}, +{SCULPT_GESTURE_TRIM_UNION, "UNION", 0, "Union", "Use a union boolean operation"}, +{SCULPT_GESTURE_TRIM_JOIN, + "JOIN", + 0, + "Join", + "Join the new mesh as separate geometry, without preforming any boolean operation"}, {0, NULL, 0, NULL, NULL}, }; @@ -1088,18 +1101,26 @@ static void sculpt_gesture_apply_trim(SculptGestureContext *sgcontext) } } - int boolean_mode; - switch (trim_operation->mode) { -case SCULPT_GESTURE_TRIM_INTERSECT: - boolean_mode = eBooleanModifierOp_Intersect; - break; -case SCULPT_GESTURE_TRIM_DIFFERENCE: - boolean_mode = eBooleanModifierOp_Difference; - break; + /* Join does not do a boolean operation, it just adds the geometry. */ + if (trim_operation->mode != SCULPT_GESTURE_TRIM_JOIN) { +int boolean_mode = 0; +switch (trim_operation->mode) { + case SCULPT_GESTURE_TRIM_INTERSECT: +boolean_mode = eBooleanModifierOp_Intersect; +break; + case SCULPT_GESTURE_TRIM_DIFFERENCE: +boolean_mode = eBooleanModifierOp_Difference; +break; + case SCULPT_GESTURE_TRIM_UNION: +boolean_mode = eBooleanModifierOp_Union; +break; + case SCULPT_GESTURE_TRIM_JOIN: +BLI_assert(false); +break; +} +BM_mesh_boolean(bm, looptris, tottri, bm_face_isect_pair, NULL, 2, false, boolean_mode); } - BM_mesh_boolean(bm, looptris, tottri, bm_face_isect_pair, NULL, 2, false, boolean_mode); - Mesh *result = BKE_mesh_from_bmesh_for_eval_nomain(bm,
[Bf-blender-cvs] [d43e3f34d26] master: Fix T81218: Crash in pose mode using a driver on bendy bone Segment
Commit: d43e3f34d26daca4f2b0f4c524a35a98cc85d1ce Author: Sybren A. Stüvel Date: Tue Oct 6 17:49:57 2020 +0200 Branches: master https://developer.blender.org/rBd43e3f34d26daca4f2b0f4c524a35a98cc85d1ce Fix T81218: Crash in pose mode using a driver on bendy bone Segment The example file in T81218 has a driver that maps a bone's X-location to the number of BBone segments. This caused a dependency cycle, which resulted in bad thread serialisation, which caused the crash. This patch breaks the dependency cycle `BONE_LOCAL` → `DRIVER(bones["Bone"].bbone_segments)` → `BONE_LOCAL`. The 'Driver Data' relation now points to `BONE_SEGMENTS` when the driven property starts with `bbone_`. Differential Revision: https://developer.blender.org/D9122 === M source/blender/depsgraph/intern/builder/deg_builder_relations.cc === diff --git a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc index 26839c67324..c0630cd47c6 100644 --- a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc +++ b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc @@ -1489,6 +1489,9 @@ void DepsgraphRelationBuilder::build_driver_data(ID *id, FCurve *fcu) return; } +const char *prop_identifier = RNA_property_identifier(property_entry_key.prop); +const bool driver_targets_bbone = STRPREFIX(prop_identifier, "bbone_"); + /* Find objects which use this, and make their eval callbacks depend on this. */ for (IDNode *to_node : graph_->id_nodes) { if (GS(to_node->id_orig->name) != ID_OB) { @@ -1506,7 +1509,9 @@ void DepsgraphRelationBuilder::build_driver_data(ID *id, FCurve *fcu) continue; } - OperationKey bone_key(&object->id, NodeType::BONE, pchan->name, OperationCode::BONE_LOCAL); + OperationCode target_op = driver_targets_bbone ? OperationCode::BONE_SEGMENTS : + OperationCode::BONE_LOCAL; + OperationKey bone_key(&object->id, NodeType::BONE, pchan->name, target_op); add_relation(driver_key, bone_key, "Arm Bone -> Driver -> Bone"); } /* Make the driver depend on COW, similar to the generic case below. */ ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [a2b18423589] master: Batch previews: improve speed of preview generation.
Commit: a2b184235892650102f1766015961a959518a9a1 Author: Bastien Montagne Date: Tue Oct 6 16:52:09 2020 +0200 Branches: master https://developer.blender.org/rBa2b184235892650102f1766015961a959518a9a1 Batch previews: improve speed of preview generation. Force multi-threading of preview renders by setting appropriate tile sizes (by default it would typically render on one or two threads only). === M release/scripts/modules/bl_previews_utils/bl_previews_render.py === diff --git a/release/scripts/modules/bl_previews_utils/bl_previews_render.py b/release/scripts/modules/bl_previews_utils/bl_previews_render.py index c9603e46ecf..6e3d04e7fa2 100644 --- a/release/scripts/modules/bl_previews_utils/bl_previews_render.py +++ b/release/scripts/modules/bl_previews_utils/bl_previews_render.py @@ -135,6 +135,9 @@ def do_previews(do_objects, do_collections, do_scenes, do_data_intern): scene.render.filepath = os.path.join(bpy.app.tempdir, 'TEMP_preview_render.png') scene.render.use_overwrite = True scene.render.use_stamp = False +scene.render.threads_mode = 'AUTO' +scene.render.tile_x = RENDER_PREVIEW_SIZE // 4 +scene.render.tile_y = RENDER_PREVIEW_SIZE // 4 image = bpy.data.images.new("TEMP_render_image", RENDER_PREVIEW_SIZE, RENDER_PREVIEW_SIZE, alpha=True) image.source = 'FILE' ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [f7c78b1c7c1] temp-T81218-bbone-segments-driver-crash: Fix T81218: Crash in pose mode using a driver on bendy bone Segment
Commit: f7c78b1c7c1f6aceeb5e63e73e1ef9d841e9e2df Author: Sybren A. Stüvel Date: Tue Oct 6 13:51:30 2020 +0200 Branches: temp-T81218-bbone-segments-driver-crash https://developer.blender.org/rBf7c78b1c7c1f6aceeb5e63e73e1ef9d841e9e2df Fix T81218: Crash in pose mode using a driver on bendy bone Segment The example file in T81218 has a driver that maps a bone's X-location to the number of BBone segments. This caused a dependency cycle, which resulted in bad thread serialisation, which caused the crash. This patch breaks the dependency cycle `BONE_LOCAL` → `DRIVER(bones["Bone"].bbone_segments)` → `BONE_LOCAL`. The 'Driver Data' relation now points to `BONE_SEGMENTS` when the driven property starts with `bbone_`. Differential Revision: https://developer.blender.org/D9122 === M source/blender/depsgraph/intern/builder/deg_builder_relations.cc === diff --git a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc index 26839c67324..c0630cd47c6 100644 --- a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc +++ b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc @@ -1489,6 +1489,9 @@ void DepsgraphRelationBuilder::build_driver_data(ID *id, FCurve *fcu) return; } +const char *prop_identifier = RNA_property_identifier(property_entry_key.prop); +const bool driver_targets_bbone = STRPREFIX(prop_identifier, "bbone_"); + /* Find objects which use this, and make their eval callbacks depend on this. */ for (IDNode *to_node : graph_->id_nodes) { if (GS(to_node->id_orig->name) != ID_OB) { @@ -1506,7 +1509,9 @@ void DepsgraphRelationBuilder::build_driver_data(ID *id, FCurve *fcu) continue; } - OperationKey bone_key(&object->id, NodeType::BONE, pchan->name, OperationCode::BONE_LOCAL); + OperationCode target_op = driver_targets_bbone ? OperationCode::BONE_SEGMENTS : + OperationCode::BONE_LOCAL; + OperationKey bone_key(&object->id, NodeType::BONE, pchan->name, target_op); add_relation(driver_key, bone_key, "Arm Bone -> Driver -> Bone"); } /* Make the driver depend on COW, similar to the generic case below. */ ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [4bb15c8eecb] master: VSE: Fix audio strips
Commit: 4bb15c8eecbf8186a8948ced9349d54c1a8c5e33 Author: Dalai Felinto Date: Tue Oct 6 14:09:04 2020 +0200 Branches: master https://developer.blender.org/rB4bb15c8eecbf8186a8948ced9349d54c1a8c5e33 VSE: Fix audio strips When sequencer was moved from kernel, the DEFINES based on audaspace were not moved along. That means users had no way of creating new audio strips since BKE_sequencer_add_sound_strip was ifdef'out === M source/blender/sequencer/CMakeLists.txt === diff --git a/source/blender/sequencer/CMakeLists.txt b/source/blender/sequencer/CMakeLists.txt index 75b5f2fef64..866eba9ca41 100644 --- a/source/blender/sequencer/CMakeLists.txt +++ b/source/blender/sequencer/CMakeLists.txt @@ -53,4 +53,16 @@ set(LIB bf_blenlib ) +if(WITH_AUDASPACE) + add_definitions(-DWITH_AUDASPACE) + + list(APPEND INC_SYS +${AUDASPACE_C_INCLUDE_DIRS} + ) + list(APPEND LIB +${AUDASPACE_C_LIBRARIES} +${AUDASPACE_PY_LIBRARIES} + ) +endif() + blender_add_lib(bf_sequencer "${SRC}" "${INC}" "${INC_SYS}" "${LIB}") ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [f3fce877b34] master: Cleanup: Depsgraph, reduce nesting of driver relations code
Commit: f3fce877b34154224ff0d1e7789b28382fa8f0ea Author: Sybren A. Stüvel Date: Tue Oct 6 13:13:42 2020 +0200 Branches: master https://developer.blender.org/rBf3fce877b34154224ff0d1e7789b28382fa8f0ea Cleanup: Depsgraph, reduce nesting of driver relations code Reduce nesting of `DepsgraphRelationBuilder::build_driver_data()` by flipping conditions and `return`/`continue` early. No functional changes. === M source/blender/depsgraph/intern/builder/deg_builder_relations.cc === diff --git a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc index 525f9e304cb..26839c67324 100644 --- a/source/blender/depsgraph/intern/builder/deg_builder_relations.cc +++ b/source/blender/depsgraph/intern/builder/deg_builder_relations.cc @@ -1484,31 +1484,35 @@ void DepsgraphRelationBuilder::build_driver_data(ID *id, FCurve *fcu) /* Drivers on armature-level bone settings (i.e. bbone stuff), * which will affect the evaluation of corresponding pose bones. */ Bone *bone = (Bone *)property_entry_key.ptr.data; -if (bone != nullptr) { - /* Find objects which use this, and make their eval callbacks - * depend on this. */ - for (IDNode *to_node : graph_->id_nodes) { -if (GS(to_node->id_orig->name) == ID_OB) { - Object *object = (Object *)to_node->id_orig; - /* We only care about objects with pose data which use this. */ - if (object->data == id_ptr && object->pose != nullptr) { -bPoseChannel *pchan = BKE_pose_channel_find_name(object->pose, bone->name); -if (pchan != nullptr) { - OperationKey bone_key( - &object->id, NodeType::BONE, pchan->name, OperationCode::BONE_LOCAL); - add_relation(driver_key, bone_key, "Arm Bone -> Driver -> Bone"); -} - } -} +if (bone == nullptr) { + fprintf(stderr, "Couldn't find armature bone name for driver path - '%s'\n", rna_path); + return; +} + +/* Find objects which use this, and make their eval callbacks depend on this. */ +for (IDNode *to_node : graph_->id_nodes) { + if (GS(to_node->id_orig->name) != ID_OB) { +continue; } - /* Make the driver depend on COW, similar to the generic case below. */ - if (id_ptr != id) { -ComponentKey cow_key(id_ptr, NodeType::COPY_ON_WRITE); -add_relation(cow_key, driver_key, "Driven CoW -> Driver", RELATION_CHECK_BEFORE_ADD); + + /* We only care about objects with pose data which use this. */ + Object *object = (Object *)to_node->id_orig; + if (object->data != id_ptr || object->pose == nullptr) { +continue; + } + + bPoseChannel *pchan = BKE_pose_channel_find_name(object->pose, bone->name); + if (pchan == nullptr) { +continue; } + + OperationKey bone_key(&object->id, NodeType::BONE, pchan->name, OperationCode::BONE_LOCAL); + add_relation(driver_key, bone_key, "Arm Bone -> Driver -> Bone"); } -else { - fprintf(stderr, "Couldn't find armature bone name for driver path - '%s'\n", rna_path); +/* Make the driver depend on COW, similar to the generic case below. */ +if (id_ptr != id) { + ComponentKey cow_key(id_ptr, NodeType::COPY_ON_WRITE); + add_relation(cow_key, driver_key, "Driven CoW -> Driver", RELATION_CHECK_BEFORE_ADD); } } else { ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [1b9de4fa337] master: BLI: escape double quotes in dot export
Commit: 1b9de4fa3379cd74cb138c2f78960ce9831daf66 Author: Jacques Lucke Date: Tue Oct 6 13:35:12 2020 +0200 Branches: master https://developer.blender.org/rB1b9de4fa3379cd74cb138c2f78960ce9831daf66 BLI: escape double quotes in dot export === M source/blender/blenlib/intern/dot_export.cc === diff --git a/source/blender/blenlib/intern/dot_export.cc b/source/blender/blenlib/intern/dot_export.cc index 9ffb1895d04..eb15a51366e 100644 --- a/source/blender/blenlib/intern/dot_export.cc +++ b/source/blender/blenlib/intern/dot_export.cc @@ -225,7 +225,15 @@ void Attributes::export__as_bracket_list(std::stringstream &ss) const ss << key << "=" << value << ", "; } else { - ss << key << "=\"" << value << "\", "; + ss << key << "=\""; + for (char c : value) { +if (c == '\"') { + /* Escape double quotes. */ + ss << '\\'; +} +ss << c; + } + ss << "\", "; } }); ss << "]"; ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [4f041c98fc3] soc-2020-io-performance: Merge branch 'master' into soc-2020-io-performance
Commit: 4f041c98fc320d4c475baf08c21d6dcb03ac5b57 Author: Ankit Meel Date: Mon Oct 5 17:54:15 2020 +0530 Branches: soc-2020-io-performance https://developer.blender.org/rB4f041c98fc320d4c475baf08c21d6dcb03ac5b57 Merge branch 'master' into soc-2020-io-performance === === ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [b3f08db4502] soc-2020-io-performance: Merge branch 'master' into soc-2020-io-performance
Commit: b3f08db4502410d81d98a2d396064fa101bac2e2 Author: Ankit Meel Date: Tue Oct 6 14:39:48 2020 +0530 Branches: soc-2020-io-performance https://developer.blender.org/rBb3f08db4502410d81d98a2d396064fa101bac2e2 Merge branch 'master' into soc-2020-io-performance === === ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [0af469d131c] soc-2020-io-performance: Merge branch 'master' into soc-2020-io-performance
Commit: 0af469d131c5ee7d1356576fad1e30785ee18110 Author: Ankit Meel Date: Fri Oct 2 16:33:14 2020 +0530 Branches: soc-2020-io-performance https://developer.blender.org/rB0af469d131c5ee7d1356576fad1e30785ee18110 Merge branch 'master' into soc-2020-io-performance === === ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] [6e7617211b6] master: UI messages fixes...
Commit: 6e7617211b67cc305f960369d59e63f7503c5358 Author: Bastien Montagne Date: Tue Oct 6 10:38:21 2020 +0200 Branches: master https://developer.blender.org/rB6e7617211b67cc305f960369d59e63f7503c5358 UI messages fixes... === M release/scripts/modules/bl_i18n_utils/utils_spell_check.py === diff --git a/release/scripts/modules/bl_i18n_utils/utils_spell_check.py b/release/scripts/modules/bl_i18n_utils/utils_spell_check.py index 986f785a1ff..05985cac868 100644 --- a/release/scripts/modules/bl_i18n_utils/utils_spell_check.py +++ b/release/scripts/modules/bl_i18n_utils/utils_spell_check.py @@ -608,6 +608,7 @@ class SpellChecker: "catmull", "catrom", "chebychev", +"conrady", # Brown-Conrady "courant", "cryptomatte", "crypto", "embree", ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs