[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37063] branches/soc-2011-pepper/source/ blender/collada/AnimationExporter.cpp: Setting svn props on collada code
Revision: 37063 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37063 Author: aligorith Date: 2011-06-01 06:05:08 + (Wed, 01 Jun 2011) Log Message: --- Setting svn props on collada code Modified Paths: -- branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp Property Changed: branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp Modified: branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp === --- branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp 2011-06-01 05:48:37 UTC (rev 37062) +++ branches/soc-2011-pepper/source/blender/collada/AnimationExporter.cpp 2011-06-01 06:05:08 UTC (rev 37063) @@ -1,108 +1,108 @@ -/* - * $Id: DocumentExporter.cpp 36898 2011-05-25 17:14:31Z phabtar $ - * - * * BEGIN GPL LICENSE BLOCK * - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software Foundation, - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - * - * Contributor(s): Chingiz Dyussenov, Arystanbek Dyussenov, Jan Diederich, Tod Liverseed. - * - * * END GPL LICENSE BLOCK * - */ - -#include GeometryExporter.h -#include AnimationExporter.h - -templateclass Functor -void forEachObjectInScene(Scene *sce, Functor f) -{ - Base *base= (Base*) sce-base.first; - while(base) { - Object *ob = base-object; - - f(ob); - - base= base-next; - } -} - -void AnimationExporter::exportAnimations(Scene *sce) - { - if(hasAnimations(sce)) { - this-scene = sce; - - openLibrary(); - - forEachObjectInScene(sce, *this); - - closeLibrary(); - } - } - - // called for each exported object - void AnimationExporter::operator() (Object *ob) - { - if (!ob-adt || !ob-adt-action) return; //this is already checked in hasAnimations() - - FCurve *fcu = (FCurve*)ob-adt-action-curves.first; - - if (ob-type == OB_ARMATURE) { - if (!ob-data) return; - - bArmature *arm = (bArmature*)ob-data; - for (Bone *bone = (Bone*)arm-bonebase.first; bone; bone = bone-next) - write_bone_animation(ob, bone); - } - else { - while (fcu) { - // TODO rotation_quaternion is also possible for objects (although euler is default) - if ((!strcmp(fcu-rna_path, location) || !strcmp(fcu-rna_path, scale)) || - (!strcmp(fcu-rna_path, rotation_euler) ob-rotmode == ROT_MODE_EUL)) - dae_animation(fcu, id_name(ob)); - - fcu = fcu-next; - } - } - } - - void AnimationExporter::dae_animation(FCurve *fcu, std::string ob_name) - { - const char *axis_names[] = {X, Y, Z}; - const char *axis_name = NULL; - char anim_id[200]; - bool has_tangents = false; - - if (fcu-array_index 3) - axis_name = axis_names[fcu-array_index]; - - BLI_snprintf(anim_id, sizeof(anim_id), %s_%s_%s, (char*)translate_id(ob_name).c_str(), -fcu-rna_path, axis_names[fcu-array_index]); - - // check rna_path is one of: rotation, scale, location - - openAnimation(anim_id, COLLADABU::Utils::EMPTY_STRING); - - // create input source - std::string input_id = create_source_from_fcurve(COLLADASW::InputSemantic::INPUT, fcu, anim_id, axis_name); - - // create output source - std::string output_id = create_source_from_fcurve(COLLADASW::InputSemantic::OUTPUT, fcu, anim_id, axis_name); - - // create interpolations source - std::string interpolation_id = create_interpolation_source(fcu, anim_id, axis_name, has_tangents); - +/* + * $Id:
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37064] branches/soc-2011-pepper/source/ blender/editors/animation/keyingsets.c: Bugfix [#27535] Insert delta key via IKey menu doesn't work well
Revision: 37064 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37064 Author: aligorith Date: 2011-06-01 06:09:34 + (Wed, 01 Jun 2011) Log Message: --- Bugfix [#27535] Insert delta key via IKey menu doesn't work well Index needed to be incrememented regardless of whether Keying Set is able to be shown, otherwise lookup fails with wrong Keying Set found Modified Paths: -- branches/soc-2011-pepper/source/blender/editors/animation/keyingsets.c Modified: branches/soc-2011-pepper/source/blender/editors/animation/keyingsets.c === --- branches/soc-2011-pepper/source/blender/editors/animation/keyingsets.c 2011-06-01 06:05:08 UTC (rev 37063) +++ branches/soc-2011-pepper/source/blender/editors/animation/keyingsets.c 2011-06-01 06:09:34 UTC (rev 37064) @@ -782,19 +782,19 @@ * - these are listed in the order in which they were defined for the active scene */ if (scene-keyingsets.first) { - for (ks= scene-keyingsets.first; ks; ks= ks-next) { + for (ks= scene-keyingsets.first; ks; ks=ks-next, i++) { if (ANIM_keyingset_context_ok_poll(C, ks)) - uiItemIntO(layout, ks-name, ICON_NONE, op_name, type, i++); + uiItemIntO(layout, ks-name, ICON_NONE, op_name, type, i); } uiItemS(layout); } /* builtin Keying Sets */ i= -1; - for (ks= builtin_keyingsets.first; ks; ks= ks-next) { + for (ks= builtin_keyingsets.first; ks; ks=ks-next, i--) { /* only show KeyingSet if context is suitable */ if (ANIM_keyingset_context_ok_poll(C, ks)) - uiItemEnumO_value(layout, ks-name, ICON_NONE, op_name, type, i--); + uiItemEnumO_value(layout, ks-name, ICON_NONE, op_name, type, i); } uiPupMenuEnd(C, pup); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37065] branches/soc-2011-pepper/source/ blender/editors: Usability Tweak [#27469]
Revision: 37065 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37065 Author: aligorith Date: 2011-06-01 06:26:54 + (Wed, 01 Jun 2011) Log Message: --- Usability Tweak [#27469] Adding/Rename markers (M/Ctrl-M) were restricted to only being available when the mouse was hovering just over the time scroller at the bottom of animation editors, as otherwise we'd get nasty keymap conflicts where markers keymap would block all the primary function keymaps. However, in the case of Adding/Renaming markers, there are no other keys which currently conflict with these in such cases. Hence, it is fine to let these ones be able to be run from anywhere within the animation editors, which should make it easier to add markers for lipsyncing purposes again for example. Modified Paths: -- branches/soc-2011-pepper/source/blender/editors/animation/anim_markers.c branches/soc-2011-pepper/source/blender/editors/include/ED_markers.h branches/soc-2011-pepper/source/blender/editors/space_action/action_ops.c branches/soc-2011-pepper/source/blender/editors/space_graph/graph_ops.c branches/soc-2011-pepper/source/blender/editors/space_nla/nla_ops.c Modified: branches/soc-2011-pepper/source/blender/editors/animation/anim_markers.c === --- branches/soc-2011-pepper/source/blender/editors/animation/anim_markers.c 2011-06-01 06:09:34 UTC (rev 37064) +++ branches/soc-2011-pepper/source/blender/editors/animation/anim_markers.c 2011-06-01 06:26:54 UTC (rev 37065) @@ -1495,3 +1495,14 @@ WM_keymap_add_item(keymap, MARKER_OT_camera_bind, BKEY, KM_PRESS, KM_CTRL, 0); #endif } + +/* to be called from animation editor keymaps, see note below */ +void ED_marker_keymap_animedit_conflictfree(wmKeyMap *keymap) +{ + /* duplicate of some marker-hotkeys but without the bounds checking +* since these are handy to be able to do unrestricted and won't conflict +* with primary function hotkeys (Usability tweak [#27469]) +*/ + WM_keymap_add_item(keymap, MARKER_OT_add, MKEY, KM_PRESS, 0, 0); + WM_keymap_add_item(keymap, MARKER_OT_rename, MKEY, KM_PRESS, KM_CTRL, 0); +} Modified: branches/soc-2011-pepper/source/blender/editors/include/ED_markers.h === --- branches/soc-2011-pepper/source/blender/editors/include/ED_markers.h 2011-06-01 06:09:34 UTC (rev 37064) +++ branches/soc-2011-pepper/source/blender/editors/include/ED_markers.h 2011-06-01 06:26:54 UTC (rev 37065) @@ -72,6 +72,9 @@ /* called in screen_ops.c:ED_keymap_screen() */ void ED_marker_keymap(struct wmKeyConfig *keyconf); +/* called in animation editors - keymap defines */ +void ED_marker_keymap_animedit_conflictfree(struct wmKeyMap *keymap); + /* debugging only */ void debug_markers_print_list(struct ListBase *markers); Modified: branches/soc-2011-pepper/source/blender/editors/space_action/action_ops.c === --- branches/soc-2011-pepper/source/blender/editors/space_action/action_ops.c 2011-06-01 06:09:34 UTC (rev 37064) +++ branches/soc-2011-pepper/source/blender/editors/space_action/action_ops.c 2011-06-01 06:26:54 UTC (rev 37065) @@ -40,6 +40,7 @@ #include BLI_blenlib.h #include ED_anim_api.h +#include ED_markers.h #include ED_transform.h #include action_intern.h @@ -193,6 +194,9 @@ /* transform system */ transform_keymap_for_space(keyconf, keymap, SPACE_ACTION); + + /* special markers hotkeys for anim editors: see note in definition of this function */ + ED_marker_keymap_animedit_conflictfree(keymap); } /* --- */ Modified: branches/soc-2011-pepper/source/blender/editors/space_graph/graph_ops.c === --- branches/soc-2011-pepper/source/blender/editors/space_graph/graph_ops.c 2011-06-01 06:09:34 UTC (rev 37064) +++ branches/soc-2011-pepper/source/blender/editors/space_graph/graph_ops.c 2011-06-01 06:26:54 UTC (rev 37065) @@ -46,6 +46,7 @@ #include UI_view2d.h #include ED_anim_api.h +#include ED_markers.h #include ED_screen.h #include ED_transform.h @@ -399,6 +400,9 @@ /* transform system */ transform_keymap_for_space(keyconf, keymap, SPACE_IPO); + + /* special markers hotkeys for anim editors: see note in definition of this function */ + ED_marker_keymap_animedit_conflictfree(keymap); } /* --- */ Modified: branches/soc-2011-pepper/source/blender/editors/space_nla/nla_ops.c === --- branches/soc-2011-pepper/source/blender/editors/space_nla/nla_ops.c 2011-06-01 06:09:34 UTC (rev 37064) +++ branches/soc-2011-pepper/source/blender/editors/space_nla/nla_ops.c
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37066] branches/soc-2011-pepper/source: BGE Animations: Removing guards that prevent the action actuator from being used on non-armatures .
Revision: 37066 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37066 Author: moguri Date: 2011-06-01 06:43:10 + (Wed, 01 Jun 2011) Log Message: --- BGE Animations: Removing guards that prevent the action actuator from being used on non-armatures. Object animation works through this actuator now too. :) Modified Paths: -- branches/soc-2011-pepper/source/blender/editors/space_logic/logic_window.c branches/soc-2011-pepper/source/blender/makesrna/intern/rna_actuator.c branches/soc-2011-pepper/source/gameengine/Converter/KX_ConvertActuators.cpp Modified: branches/soc-2011-pepper/source/blender/editors/space_logic/logic_window.c === --- branches/soc-2011-pepper/source/blender/editors/space_logic/logic_window.c 2011-06-01 06:26:54 UTC (rev 37065) +++ branches/soc-2011-pepper/source/blender/editors/space_logic/logic_window.c 2011-06-01 06:43:10 UTC (rev 37066) @@ -3679,10 +3679,6 @@ PointerRNA settings_ptr; uiLayout *row; - if(ob-type != OB_ARMATURE){ - uiItemL(layout, Actuator only available for armatures, ICON_NONE); - return; - } RNA_pointer_create((ID *)ob, RNA_GameObjectSettings, ob, settings_ptr); row= uiLayoutRow(layout, 0); Modified: branches/soc-2011-pepper/source/blender/makesrna/intern/rna_actuator.c === --- branches/soc-2011-pepper/source/blender/makesrna/intern/rna_actuator.c 2011-06-01 06:26:54 UTC (rev 37065) +++ branches/soc-2011-pepper/source/blender/makesrna/intern/rna_actuator.c 2011-06-01 06:43:10 UTC (rev 37066) @@ -426,11 +426,11 @@ if (ob != NULL) { if (ob-type==OB_ARMATURE) { - RNA_enum_items_add_value(item, totitem, actuator_type_items, ACT_ACTION); RNA_enum_items_add_value(item, totitem, actuator_type_items, ACT_ARMATURE); } } - + + RNA_enum_items_add_value(item, totitem, actuator_type_items, ACT_ACTION); RNA_enum_items_add_value(item, totitem, actuator_type_items, ACT_CAMERA); RNA_enum_items_add_value(item, totitem, actuator_type_items, ACT_CONSTRAINT); RNA_enum_items_add_value(item, totitem, actuator_type_items, ACT_EDIT_OBJECT); Modified: branches/soc-2011-pepper/source/gameengine/Converter/KX_ConvertActuators.cpp === --- branches/soc-2011-pepper/source/gameengine/Converter/KX_ConvertActuators.cpp 2011-06-01 06:26:54 UTC (rev 37065) +++ branches/soc-2011-pepper/source/gameengine/Converter/KX_ConvertActuators.cpp 2011-06-01 06:43:10 UTC (rev 37066) @@ -191,30 +191,26 @@ } case ACT_ACTION: { - if (blenderobject-type==OB_ARMATURE){ - bActionActuator* actact = (bActionActuator*) bact-data; - STR_String propname = (actact-name ? actact-name : ); - STR_String propframe = (actact-frameProp ? actact-frameProp : ); + bActionActuator* actact = (bActionActuator*) bact-data; + STR_String propname = (actact-name ? actact-name : ); + STR_String propframe = (actact-frameProp ? actact-frameProp : ); - BL_ActionActuator* tmpbaseact = new BL_ActionActuator( - gameobj, - propname, - propframe, - actact-sta, - actact-end, - actact-act, - actact-type, // + 1, because Blender starts to count at zero, - actact-blendin, - actact-priority, - actact-end_reset, - actact-stridelength - // Ketsji at 1, because zero is reserved for NoDef - ); - baseact= tmpbaseact; - break; - } - else - printf (Discarded action actuator from non-armature object [%s]\n, blenderobject-id.name+2); + BL_ActionActuator* tmpbaseact = new
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37067] branches/soc-2011-pepper/source/ gameengine: BGE Animations: Reimplemented the continuous function of the action actuator.
Revision: 37067 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37067 Author: moguri Date: 2011-06-01 07:42:40 + (Wed, 01 Jun 2011) Log Message: --- BGE Animations: Reimplemented the continuous function of the action actuator. * To do this, I've added Get/SetFrame() functions. * I've also cleaned up a little bit of the wrap around logic in BL_Action.cpp. Modified Paths: -- branches/soc-2011-pepper/source/gameengine/Converter/BL_ActionActuator.cpp branches/soc-2011-pepper/source/gameengine/Ketsji/BL_Action.cpp branches/soc-2011-pepper/source/gameengine/Ketsji/BL_Action.h branches/soc-2011-pepper/source/gameengine/Ketsji/BL_ActionManager.cpp branches/soc-2011-pepper/source/gameengine/Ketsji/BL_ActionManager.h branches/soc-2011-pepper/source/gameengine/Ketsji/KX_GameObject.cpp branches/soc-2011-pepper/source/gameengine/Ketsji/KX_GameObject.h Modified: branches/soc-2011-pepper/source/gameengine/Converter/BL_ActionActuator.cpp === --- branches/soc-2011-pepper/source/gameengine/Converter/BL_ActionActuator.cpp 2011-06-01 06:43:10 UTC (rev 37066) +++ branches/soc-2011-pepper/source/gameengine/Converter/BL_ActionActuator.cpp 2011-06-01 07:42:40 UTC (rev 37067) @@ -173,12 +173,21 @@ { m_is_going = true; obj-PlayAction(m_action-id.name+2, m_startframe, m_endframe, 0, m_blendin, play_mode); + if (m_end_reset) + obj-SetActionFrame(0, m_localtime); } else if (m_is_going bNegativeEvent) { m_is_going = false; - obj-StopAction(0); - return false; + + if (!m_end_reset) + { + obj-StopAction(0); + return false; + } + + m_localtime = obj-GetActionFrame(0); + obj-StopAction(0); // Stop the action after getting the frame } // Handle a finished animation Modified: branches/soc-2011-pepper/source/gameengine/Ketsji/BL_Action.cpp === --- branches/soc-2011-pepper/source/gameengine/Ketsji/BL_Action.cpp 2011-06-01 06:43:10 UTC (rev 37066) +++ branches/soc-2011-pepper/source/gameengine/Ketsji/BL_Action.cpp 2011-06-01 07:42:40 UTC (rev 37067) @@ -27,6 +27,8 @@ * * END GPL LICENSE BLOCK * */ +#include cstdlib + #include BL_Action.h #include BL_ArmatureObject.h #include KX_IpoConvert.h @@ -106,6 +108,33 @@ m_sg_contr-SetOption(SG_Controller::SG_CONTR_IPO_LOCAL, false); } +float BL_Action::GetFrame() +{ + return m_localtime; +} + +void BL_Action::SetFrame(float frame) +{ + float dt; + + // Clamp the frame to the start and end frame + if (frame min(m_startframe, m_endframe)) + frame = min(m_startframe, m_endframe); + else if (frame max(m_startframe, m_endframe)) + frame = max(m_startframe, m_endframe); + + // We don't set m_localtime directly since it's recalculated + // in the next update. So, we modify the value (m_starttime) + // used to calculate m_localtime the next time SetLocalTime() is called. + + dt = frame-m_startframe; + + if (m_endframe m_startframe) + dt = -dt; + + m_starttime -= dt / (KX_KetsjiEngine::GetAnimFrameRate()*m_speed); +} + void BL_Action::SetLocalTime(float curtime) { float dt = (curtime-m_starttime)*KX_KetsjiEngine::GetAnimFrameRate()*m_speed; @@ -127,9 +156,7 @@ SetLocalTime(curtime); // Handle wrap around - bool bforward = m_startframe m_endframe; - if (bforward (m_localtime m_startframe || m_localtime m_endframe) || - !bforward (m_localtime m_startframe || m_localtime m_endframe)) + if (m_localtime min(m_startframe, m_endframe) || m_localtime max(m_startframe, m_endframe)) { switch(m_playmode) { Modified: branches/soc-2011-pepper/source/gameengine/Ketsji/BL_Action.h === --- branches/soc-2011-pepper/source/gameengine/Ketsji/BL_Action.h 2011-06-01 06:43:10 UTC (rev 37066) +++ branches/soc-2011-pepper/source/gameengine/Ketsji/BL_Action.h 2011-06-01 07:42:40 UTC (rev 37067) @@ -77,6 +77,12 @@ bool IsDone() {return m_done;} void Update(float curtime); + // Accessors + float GetFrame(); + + // Mutators + void SetFrame(float frame); + enum { ACT_MODE_PLAY = 0, Modified: branches/soc-2011-pepper/source/gameengine/Ketsji/BL_ActionManager.cpp === ---
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37068] branches/soc-2010-jwilkins: svn property fixes.
Revision: 37068 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37068 Author: jwilkins Date: 2011-06-01 07:52:53 + (Wed, 01 Jun 2011) Log Message: --- svn property fixes. These are all empty svn:mergeinfo tags that should probably be cleaned up in trunk, but I'm adding them back in our branch so that diffs come out clean. Property Changed: branches/soc-2010-jwilkins/release/scripts/modules/bpy/ops.py branches/soc-2010-jwilkins/release/scripts/modules/bpy/utils.py branches/soc-2010-jwilkins/release/scripts/presets/sss/chicken.py branches/soc-2010-jwilkins/release/scripts/presets/sss/cream.py branches/soc-2010-jwilkins/release/scripts/presets/sss/ketchup.py branches/soc-2010-jwilkins/release/scripts/presets/sss/marble.py branches/soc-2010-jwilkins/release/scripts/presets/sss/potato.py branches/soc-2010-jwilkins/release/scripts/presets/sss/skim_milk.py branches/soc-2010-jwilkins/release/scripts/presets/sss/skin1.py branches/soc-2010-jwilkins/release/scripts/presets/sss/skin2.py branches/soc-2010-jwilkins/release/scripts/startup/bl_operators/add_mesh_torus.py branches/soc-2010-jwilkins/release/scripts/startup/bl_operators/uvcalc_smart_project.py branches/soc-2010-jwilkins/release/scripts/startup/bl_operators/vertexpaint_dirt.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_data_armature.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_data_bone.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_data_camera.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_data_empty.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_data_lamp.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_data_lattice.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_data_mesh.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_data_metaball.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_data_modifier.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_game.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_material.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_particle.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_physics_field.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_physics_fluid.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_physics_smoke.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_texture.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/properties_world.py branches/soc-2010-jwilkins/release/scripts/startup/bl_ui/space_node.py branches/soc-2010-jwilkins/source/blender/blenkernel/BKE_customdata_file.h branches/soc-2010-jwilkins/source/blender/blenkernel/intern/customdata_file.c branches/soc-2010-jwilkins/source/blender/editors/datafiles/startup.blend.c branches/soc-2010-jwilkins/source/blender/editors/include/ED_particle.h branches/soc-2010-jwilkins/source/blender/editors/include/ED_physics.h branches/soc-2010-jwilkins/source/blender/editors/include/ED_render.h branches/soc-2010-jwilkins/source/blender/editors/include/ED_transform.h branches/soc-2010-jwilkins/source/blender/editors/interface/interface_intern.h branches/soc-2010-jwilkins/source/blender/editors/mesh/mesh_data.c branches/soc-2010-jwilkins/source/blender/editors/metaball/mball_edit.c branches/soc-2010-jwilkins/source/blender/editors/object/object_add.c branches/soc-2010-jwilkins/source/blender/editors/object/object_constraint.c branches/soc-2010-jwilkins/source/blender/editors/object/object_group.c branches/soc-2010-jwilkins/source/blender/editors/object/object_hook.c branches/soc-2010-jwilkins/source/blender/editors/object/object_lattice.c branches/soc-2010-jwilkins/source/blender/editors/object/object_relations.c branches/soc-2010-jwilkins/source/blender/editors/object/object_select.c branches/soc-2010-jwilkins/source/blender/editors/object/object_shapekey.c branches/soc-2010-jwilkins/source/blender/editors/object/object_transform.c branches/soc-2010-jwilkins/source/blender/editors/object/object_vgroup.c branches/soc-2010-jwilkins/source/blender/editors/physics/particle_boids.c branches/soc-2010-jwilkins/source/blender/editors/physics/particle_edit.c branches/soc-2010-jwilkins/source/blender/editors/physics/physics_fluid.c branches/soc-2010-jwilkins/source/blender/editors/physics/physics_pointcache.c branches/soc-2010-jwilkins/source/blender/editors/render/ branches/soc-2010-jwilkins/source/blender/editors/render/render_intern.h
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37069] branches/soc-2011-garlic/po: Enable the popot update system, simply with two python scripts.
Revision: 37069 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37069 Author: xiaoxiangquan Date: 2011-06-01 07:57:09 + (Wed, 01 Jun 2011) Log Message: --- Enable the popot update system, simply with two python scripts. Modified Paths: -- branches/soc-2011-garlic/po/ca.po branches/soc-2011-garlic/po/es.po branches/soc-2011-garlic/po/fi.po branches/soc-2011-garlic/po/fr.po branches/soc-2011-garlic/po/hr.po branches/soc-2011-garlic/po/it.po branches/soc-2011-garlic/po/ja.po branches/soc-2011-garlic/po/ko.po branches/soc-2011-garlic/po/pl.po branches/soc-2011-garlic/po/ru.po branches/soc-2011-garlic/po/sr.po branches/soc-2011-garlic/po/s...@latn.po branches/soc-2011-garlic/po/sv.po Added Paths: --- branches/soc-2011-garlic/po/POTFILES.in branches/soc-2011-garlic/po/blender.pot branches/soc-2011-garlic/po/update-po.py branches/soc-2011-garlic/po/update-pot.py Added: branches/soc-2011-garlic/po/POTFILES.in === --- branches/soc-2011-garlic/po/POTFILES.in (rev 0) +++ branches/soc-2011-garlic/po/POTFILES.in 2011-06-01 07:57:09 UTC (rev 37069) @@ -0,0 +1 @@ +release/scripts/startup/bl_ui/space_info.py Property changes on: branches/soc-2011-garlic/po/POTFILES.in ___ Added: svn:executable + * Added: branches/soc-2011-garlic/po/blender.pot === --- branches/soc-2011-garlic/po/blender.pot (rev 0) +++ branches/soc-2011-garlic/po/blender.pot 2011-06-01 07:57:09 UTC (rev 37069) @@ -0,0 +1,62 @@ +# SOME DESCRIPTIVE TITLE. +# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER +# This file is distributed under the same license as the PACKAGE package. +# FIRST AUTHOR EMAIL@ADDRESS, YEAR. +# +#, fuzzy +msgid +msgstr +Project-Id-Version: PACKAGE VERSION\n +Report-Msgid-Bugs-To: \n +POT-Creation-Date: 2011-06-01 15:03+0800\n +PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n +Last-Translator: FULL NAME EMAIL@ADDRESS\n +Language-Team: LANGUAGE l...@li.org\n +Language: \n +MIME-Version: 1.0\n +Content-Type: text/plain; charset=CHARSET\n +Content-Transfer-Encoding: 8bit\n + +#: release/scripts/startup/bl_ui/space_info.py:101 +msgid File +msgstr + +#: release/scripts/startup/bl_ui/space_info.py:107 +msgid New +msgstr + +#: release/scripts/startup/bl_ui/space_info.py:109 +msgid Open... +msgstr + +#: release/scripts/startup/bl_ui/space_info.py:112 +msgid Recover Auto Save... +msgstr + +#: release/scripts/startup/bl_ui/space_info.py:117 +msgid Save +msgstr + +#: release/scripts/startup/bl_ui/space_info.py:119 +msgid Save As... +msgstr + +#: release/scripts/startup/bl_ui/space_info.py:121 +msgid Save Copy... +msgstr + +#: release/scripts/startup/bl_ui/space_info.py:125 +msgid User Preferences... +msgstr + +#: release/scripts/startup/bl_ui/space_info.py:134 +msgid Link +msgstr + +#: release/scripts/startup/bl_ui/space_info.py:135 +msgid Append +msgstr + +#: release/scripts/startup/bl_ui/space_info.py:151 +msgid Quit +msgstr Property changes on: branches/soc-2011-garlic/po/blender.pot ___ Added: svn:executable + * Modified: branches/soc-2011-garlic/po/ca.po === --- branches/soc-2011-garlic/po/ca.po 2011-06-01 07:52:53 UTC (rev 37068) +++ branches/soc-2011-garlic/po/ca.po 2011-06-01 07:57:09 UTC (rev 37069) @@ -1,6 +1,14 @@ # Copyright (C) 2003 Free Software Foundation, Inc. # Est. 2003. # +msgid +msgstr +Report-Msgid-Bugs-To: \n +POT-Creation-Date: 2011-06-01 15:03+0800\n +Language: ca\n +MIME-Version: 1.0\n +Content-Type: text/plain; charset=UTF-8\n +Content-Transfer-Encoding: 8bit\n ### ### Modified: branches/soc-2011-garlic/po/es.po === --- branches/soc-2011-garlic/po/es.po 2011-06-01 07:52:53 UTC (rev 37068) +++ branches/soc-2011-garlic/po/es.po 2011-06-01 07:57:09 UTC (rev 37069) @@ -1,6 +1,14 @@ # Copyright (C) 2003 Free Software Foundation, Inc. # Est. 2003. # +msgid +msgstr +Report-Msgid-Bugs-To: \n +POT-Creation-Date: 2011-06-01 15:03+0800\n +Language: es\n +MIME-Version: 1.0\n +Content-Type: text/plain; charset=UTF-8\n +Content-Transfer-Encoding: 8bit\n ### ### Modified: branches/soc-2011-garlic/po/fi.po === --- branches/soc-2011-garlic/po/fi.po 2011-06-01 07:52:53 UTC (rev 37068) +++ branches/soc-2011-garlic/po/fi.po 2011-06-01 07:57:09 UTC (rev 37069) @@ -8,6 +8,14 @@ # Copyright (C) 2003 Free Software Foundation, Inc.
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37070] branches/soc-2011-onion: svn property fixes.
Revision: 37070 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37070 Author: jwilkins Date: 2011-06-01 08:28:41 + (Wed, 01 Jun 2011) Log Message: --- svn property fixes. These are all empty svn:mergeinfo tags that should probably be cleaned up in trunk, but I'm adding them back in our branch so that diffs come out clean. Property Changed: branches/soc-2011-onion/release/scripts/modules/bpy/ops.py branches/soc-2011-onion/release/scripts/modules/bpy/utils.py branches/soc-2011-onion/release/scripts/presets/sss/chicken.py branches/soc-2011-onion/release/scripts/presets/sss/cream.py branches/soc-2011-onion/release/scripts/presets/sss/ketchup.py branches/soc-2011-onion/release/scripts/presets/sss/marble.py branches/soc-2011-onion/release/scripts/presets/sss/potato.py branches/soc-2011-onion/release/scripts/presets/sss/skim_milk.py branches/soc-2011-onion/release/scripts/presets/sss/skin1.py branches/soc-2011-onion/release/scripts/presets/sss/skin2.py branches/soc-2011-onion/release/scripts/startup/bl_operators/add_mesh_torus.py branches/soc-2011-onion/release/scripts/startup/bl_operators/vertexpaint_dirt.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_armature.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_bone.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_camera.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_empty.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_lamp.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_lattice.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_mesh.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_metaball.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_data_modifier.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_game.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_particle.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_physics_field.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_physics_fluid.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_physics_smoke.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_texture.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_world.py branches/soc-2011-onion/release/scripts/startup/bl_ui/space_node.py branches/soc-2011-onion/source/blender/blenkernel/BKE_customdata_file.h branches/soc-2011-onion/source/blender/blenkernel/intern/customdata_file.c branches/soc-2011-onion/source/blender/editors/datafiles/startup.blend.c branches/soc-2011-onion/source/blender/editors/interface/interface_intern.h branches/soc-2011-onion/source/blender/editors/metaball/mball_edit.c branches/soc-2011-onion/source/blender/editors/object/object_add.c branches/soc-2011-onion/source/blender/editors/object/object_constraint.c branches/soc-2011-onion/source/blender/editors/object/object_group.c branches/soc-2011-onion/source/blender/editors/object/object_hook.c branches/soc-2011-onion/source/blender/editors/object/object_lattice.c branches/soc-2011-onion/source/blender/editors/object/object_relations.c branches/soc-2011-onion/source/blender/editors/object/object_select.c branches/soc-2011-onion/source/blender/editors/object/object_shapekey.c branches/soc-2011-onion/source/blender/editors/object/object_transform.c branches/soc-2011-onion/source/blender/editors/object/object_vgroup.c branches/soc-2011-onion/source/blender/editors/physics/particle_boids.c branches/soc-2011-onion/source/blender/editors/physics/particle_edit.c branches/soc-2011-onion/source/blender/editors/physics/physics_fluid.c branches/soc-2011-onion/source/blender/editors/physics/physics_pointcache.c branches/soc-2011-onion/source/blender/editors/render/ branches/soc-2011-onion/source/blender/editors/render/render_intern.h branches/soc-2011-onion/source/blender/editors/render/render_preview.c branches/soc-2011-onion/source/blender/editors/render/render_shading.c branches/soc-2011-onion/source/blender/editors/render/render_update.c branches/soc-2011-onion/source/blender/editors/sculpt_paint/ branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_image.c branches/soc-2011-onion/source/blender/editors/sculpt_paint/sculpt.c branches/soc-2011-onion/source/blender/editors/space_image/image_buttons.c branches/soc-2011-onion/source/blender/editors/space_info/info_ops.c branches/soc-2011-onion/source/blender/editors/space_node/node_state.c branches/soc-2011-onion/source/blender/editors/space_text/text_ops.c
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37071] branches/soc-2011-onion: move svn property fixes
Revision: 37071 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37071 Author: jwilkins Date: 2011-06-01 08:47:17 + (Wed, 01 Jun 2011) Log Message: --- move svn property fixes Property Changed: branches/soc-2011-onion/release/scripts/startup/bl_operators/uvcalc_smart_project.py branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_material.py branches/soc-2011-onion/source/blender/blenkernel/BKE_customdata_file.h branches/soc-2011-onion/source/blender/editors/include/ED_particle.h branches/soc-2011-onion/source/blender/editors/include/ED_physics.h branches/soc-2011-onion/source/blender/editors/include/ED_render.h branches/soc-2011-onion/source/blender/editors/include/ED_transform.h branches/soc-2011-onion/source/blender/editors/mesh/mesh_data.c branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_vertex.c branches/soc-2011-onion/source/blender/editors/space_node/node_edit.c Property changes on: branches/soc-2011-onion/release/scripts/startup/bl_operators/uvcalc_smart_project.py ___ Added: svn:mergeinfo + Property changes on: branches/soc-2011-onion/release/scripts/startup/bl_ui/properties_material.py ___ Added: svn:mergeinfo + Property changes on: branches/soc-2011-onion/source/blender/blenkernel/BKE_customdata_file.h ___ Deleted: svn:merginfo - Added: svn:mergeinfo + Property changes on: branches/soc-2011-onion/source/blender/editors/include/ED_particle.h ___ Added: svn:mergeinfo + Property changes on: branches/soc-2011-onion/source/blender/editors/include/ED_physics.h ___ Added: svn:mergeinfo + Property changes on: branches/soc-2011-onion/source/blender/editors/include/ED_render.h ___ Added: svn:mergeinfo + Property changes on: branches/soc-2011-onion/source/blender/editors/include/ED_transform.h ___ Added: svn:mergeinfo + Property changes on: branches/soc-2011-onion/source/blender/editors/mesh/mesh_data.c ___ Added: svn:mergeinfo + Property changes on: branches/soc-2011-onion/source/blender/editors/sculpt_paint/paint_vertex.c ___ Added: svn:mergeinfo + Property changes on: branches/soc-2011-onion/source/blender/editors/space_node/node_edit.c ___ Added: svn:mergeinfo + ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37072] branches/soc-2011-pepper/source/ blender/editors: * Fix compiler warning from previous commit
Revision: 37072 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37072 Author: aligorith Date: 2011-06-01 11:55:28 + (Wed, 01 Jun 2011) Log Message: --- * Fix compiler warning from previous commit * For new themes, size of handles in graph editor is now 4. Allows them to be seen better. (TODO: .b.blend needs updating) Modified Paths: -- branches/soc-2011-pepper/source/blender/editors/include/ED_markers.h branches/soc-2011-pepper/source/blender/editors/interface/resources.c Modified: branches/soc-2011-pepper/source/blender/editors/include/ED_markers.h === --- branches/soc-2011-pepper/source/blender/editors/include/ED_markers.h 2011-06-01 08:47:17 UTC (rev 37071) +++ branches/soc-2011-pepper/source/blender/editors/include/ED_markers.h 2011-06-01 11:55:28 UTC (rev 37072) @@ -34,6 +34,7 @@ #define ED_MARKERS_H struct wmKeyConfig; +struct wmKeyMap; struct bContext; struct bAnimContext; struct Scene; Modified: branches/soc-2011-pepper/source/blender/editors/interface/resources.c === --- branches/soc-2011-pepper/source/blender/editors/interface/resources.c 2011-06-01 08:47:17 UTC (rev 37071) +++ branches/soc-2011-pepper/source/blender/editors/interface/resources.c 2011-06-01 11:55:28 UTC (rev 37072) @@ -663,7 +663,7 @@ SETCOL(btheme-tipo.handle_vertex, 0, 0, 0, 255); SETCOL(btheme-tipo.handle_vertex_select, 255, 133, 0, 255); - btheme-tipo.handle_vertex_size= 3; + btheme-tipo.handle_vertex_size= 4; SETCOL(btheme-tipo.ds_channel, 82, 96, 110, 255); SETCOL(btheme-tipo.ds_subchannel, 124, 137, 150, 255); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37073] trunk/blender/source/blender/ blenloader/intern/readfile.c: Fix #27541: f-curve generator modifier file read missed endian switch,
Revision: 37073 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37073 Author: blendix Date: 2011-06-01 13:10:37 + (Wed, 01 Jun 2011) Log Message: --- Fix #27541: f-curve generator modifier file read missed endian switch, found by Guillaume Roguez. Modified Paths: -- trunk/blender/source/blender/blenloader/intern/readfile.c Modified: trunk/blender/source/blender/blenloader/intern/readfile.c === --- trunk/blender/source/blender/blenloader/intern/readfile.c 2011-06-01 11:55:28 UTC (rev 37072) +++ trunk/blender/source/blender/blenloader/intern/readfile.c 2011-06-01 13:10:37 UTC (rev 37073) @@ -1723,6 +1723,7 @@ static void direct_link_fmodifiers(FileData *fd, ListBase *list) { FModifier *fcm; + int a; for (fcm= list-first; fcm; fcm= fcm-next) { /* relink general data */ @@ -1736,6 +1737,11 @@ FMod_Generator *data= (FMod_Generator *)fcm-data; data-coefficients= newdataadr(fd, data-coefficients); + + if(fd-flags FD_FLAGS_SWITCH_ENDIAN) { + for(a = 0; a data-arraysize; a++) + SWITCH_INT(data-coefficients[a]); + } } break; case FMODIFIER_TYPE_ENVELOPE: ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37074] trunk/blender: Fix #27481: windows uninstaller could remove files unrelated to blender
Revision: 37074 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37074 Author: blendix Date: 2011-06-01 13:13:55 + (Wed, 01 Jun 2011) Log Message: --- Fix #27481: windows uninstaller could remove files unrelated to blender when installing to a folder that already existed. Now the uninstaller will remove only the files it has installed, and leave any other files in the installation directory intact. Modified Paths: -- trunk/blender/build_files/scons/tools/btools.py trunk/blender/release/windows/installer/00.sconsblender.nsi Modified: trunk/blender/build_files/scons/tools/btools.py === --- trunk/blender/build_files/scons/tools/btools.py 2011-06-01 13:10:37 UTC (rev 37073) +++ trunk/blender/build_files/scons/tools/btools.py 2011-06-01 13:13:55 UTC (rev 37074) @@ -605,9 +605,12 @@ doneroot = False rootdirconts = [] datafiles = '' +deldatafiles = '' +deldatadirs = '' l = len(bf_installdir) for dp,dn,df in os.walk(bf_installdir): +# install if not doneroot: for f in df: rootdirconts.append(os.path.join(dp,f)) @@ -621,6 +624,16 @@ outfile = os.path.join(dp,f) datafiles += ' File '+outfile + \n +# uninstall +deldir = dp[l+1:] + +if len(deldir)0: +deldatadirs = RMDir $INSTDIR\\ + deldir + \n + deldatadirs +deldatadirs = RMDir /r $INSTDIR\\ + deldir + \\__pycache__\n + deldatadirs + +for f in df: +deldatafiles += 'Delete \$INSTDIR\\' + os.path.join(deldir, f) + \\n + change to suit install dir inst_dir = install_base_dir + env['BF_INSTALLDIR'] @@ -657,6 +670,8 @@ ns_cnt = string.replace(ns_cnt, [DELROOTDIRCONTS], delrootstring) ns_cnt = string.replace(ns_cnt, [DODATAFILES], datafiles) +ns_cnt = string.replace(ns_cnt, [DELDATAFILES], deldatafiles) +ns_cnt = string.replace(ns_cnt, [DELDATADIRS], deldatadirs) tmpnsi = os.path.normpath(install_base_dir+os.sep+env['BF_BUILDDIR']+os.sep+00.blender_tmp.nsi) new_nsis = open(tmpnsi, 'w') Modified: trunk/blender/release/windows/installer/00.sconsblender.nsi === --- trunk/blender/release/windows/installer/00.sconsblender.nsi 2011-06-01 13:10:37 UTC (rev 37073) +++ trunk/blender/release/windows/installer/00.sconsblender.nsi 2011-06-01 13:13:55 UTC (rev 37074) @@ -205,6 +205,8 @@ ; Remove files [DELROOTDIRCONTS] + [DELDATAFILES] + [DELDATADIRS] Delete $INSTDIR\uninstall.exe @@ -212,13 +214,14 @@ RMDir /r $BLENDERCONFIG\$SHORTVERSION ${Endif} + ; Remove install directory if it's empty + RMDir $INSTDIR ; Remove shortcuts Delete $SMPROGRAMS\Blender Foundation\Blender\*.* Delete $DESKTOP\Blender.lnk ; Remove all link related directories and files - RMDir /r $SMPROGRAMS\Blender Foundation - ; Clear out installation dir - RMDir /r $INSTDIR + RMDir $SMPROGRAMS\Blender Foundation\Blender + RMDir $SMPROGRAMS\Blender Foundation System::Call 'shell32.dll::SHChangeNotify(i, i, i, i) v (0x0800, 0, 0, 0)' ; Refresh icons SectionEnd ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37075] trunk/blender/release/scripts/ startup/bl_ui/space_userpref_keymap.py: Fix #27490: export key configuration gave error when trying to export
Revision: 37075 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37075 Author: blendix Date: 2011-06-01 14:35:14 + (Wed, 01 Jun 2011) Log Message: --- Fix #27490: export key configuration gave error when trying to export properties from an unknown (e.g. removed) operator. Modified Paths: -- trunk/blender/release/scripts/startup/bl_ui/space_userpref_keymap.py Modified: trunk/blender/release/scripts/startup/bl_ui/space_userpref_keymap.py === --- trunk/blender/release/scripts/startup/bl_ui/space_userpref_keymap.py 2011-06-01 13:13:55 UTC (rev 37074) +++ trunk/blender/release/scripts/startup/bl_ui/space_userpref_keymap.py 2011-06-01 14:35:14 UTC (rev 37075) @@ -411,8 +411,8 @@ if lines is None: lines = [] -for pname in properties.keys(): -if not properties.is_property_hidden(pname): +for pname in properties.bl_rna.properties.keys(): +if pname != rna_type and not properties.is_property_hidden(pname): value = getattr(properties, pname) if isinstance(value, bpy.types.OperatorProperties): export_properties(prefix + . + pname, value, lines) ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37076] branches/soc-2011-radish/source/ blender/editors/sculpt_paint/paint_vertex.c: Remembered to free memory in gen_lck_flags() when it returned NU
Revision: 37076 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37076 Author: jason_hays22 Date: 2011-06-01 15:45:09 + (Wed, 01 Jun 2011) Log Message: --- Remembered to free memory in gen_lck_flags() when it returned NULL when there were no locks present. Changed the lock system to redistribute changes of unlocked groups to other unlocked groups instead of just maintaining ratios within locked groups. Modified Paths: -- branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c Modified: branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c === --- branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c 2011-06-01 14:35:14 UTC (rev 37075) +++ branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c 2011-06-01 15:45:09 UTC (rev 37076) @@ -1075,7 +1075,7 @@ } } /* Jason was here */ -static char get_locked_flag(Object *ob, int vgroup) +/*static char get_locked_flag(Object *ob, int vgroup) { int i; bDeformGroup *defgroup = ob-defbase.first; @@ -1086,7 +1086,7 @@ return defgroup-flag; } return 0; -} +}*/ /* Jason was here */ static int locked_group_exists(Object *ob) { @@ -1099,40 +1099,53 @@ } return FALSE; } - +/* Jason was here */ +/* +See if the current deform group has a locked group +*/ +static char has_locked_group(MDeformVert *dvert, char *flags) +{ + int i; + for(i = 0; i dvert-totweight; i++) { + if(flags[(dvert-dw+i)-def_nr]) { + return TRUE; + } + } + return FALSE; +} /*Jason was here -not sure where these prototypes belong at them moment +not sure where the prototypes belong at the moment static char* gen_lck_flags(Object* ob); -static void fix_weight_ratios(Mesh *me, MDeformWeight *pnt_dw, float oldw); gen_lck_flags gets the status of flag for each bDeformGroup in ob-defbase and returns an array containing them - -But I didn't need all of them in one place yet, so I'm using get_locked_flag() */ -/*static char* gen_lck_flags(Object* ob) +static char* gen_lck_flags(Object* ob, int defcnt) { - char is_locked = 0; - int i, k; - int defcnt = BLI_countlist(ob-defbase); + char is_locked = FALSE; + int i; + //int defcnt = BLI_countlist(ob-defbase); char *flags = MEM_mallocN(defcnt*sizeof(char), defflags); bDeformGroup *defgroup = ob-defbase.first; for(i = 0; i defcnt defgroup; i++) { flags[i] = defgroup-flag; defgroup = defgroup-next; if(flags[i]) { - is_locked = 1; + is_locked = TRUE; } } if(is_locked){ return flags; } + // don't forget to free it + MEM_freeN(flags); return NULL; -}*/ +} /*Jason was here this alters the weights in order to maintain the ratios to match with the change in weights of pnt_dw +This was not the intended solution evidently */ -static void fix_weight_ratios(Mesh *me, MDeformWeight *pnt_dw, float oldw) +/*static void fix_weight_ratios(Mesh *me, MDeformWeight *pnt_dw, float oldw) { int i, k, totvert, cnt; float scaledown = 1.0f; @@ -1175,6 +1188,73 @@ } } } +}*/ +/* Jason was here */ +/* +The idea behind this function is to get the difference in weight for pnt_dw, +and to redistribute that weight to the unlocked groups +(if it has to, then it will put some/all of the change +back onto the original group) +*/ +static void redistribute_weight_change(MDeformVert *dvert, MDeformWeight *pnt_dw, float oldw, char* flags, int defcnt) +{ + int i; + float change_left = oldw - pnt_dw-weight; + float change; + char was_a_change; + int groups_left_that_can_change = 0; + char* change_status = MEM_mallocN(defcnt*sizeof(char), defflags); + MDeformWeight *dw; + //printf(start\n); + for(i = 0; i defcnt; i++) { + if(pnt_dw-def_nr == i) { + change_status[i] = FALSE; + } else { + change_status[i] = !flags[i]; + } + if(change_status[i]) { + groups_left_that_can_change++; + } + //printf(group %d, change status: %d flag: %d active?: %d\n, i, change_status[i], flags[i], pnt_dw-def_nr == i); + } + //printf(\n); + if(groups_left_that_can_change 0) { + do { + was_a_change = FALSE; + for(i = 0; i dvert-totweight; i++) { + dw = (dvert-dw+i); + if(!change_status[dw-def_nr]) { +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37077] trunk/blender/source/blender/ editors/interface/interface_templates.c: UI: template_ID now takes into account if the property is editable.
Revision: 37077 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37077 Author: blendix Date: 2011-06-01 16:13:48 + (Wed, 01 Jun 2011) Log Message: --- UI: template_ID now takes into account if the property is editable. Modified Paths: -- trunk/blender/source/blender/editors/interface/interface_templates.c Modified: trunk/blender/source/blender/editors/interface/interface_templates.c === --- trunk/blender/source/blender/editors/interface/interface_templates.c 2011-06-01 15:45:09 UTC (rev 37076) +++ trunk/blender/source/blender/editors/interface/interface_templates.c 2011-06-01 16:13:48 UTC (rev 37077) @@ -332,6 +332,7 @@ PointerRNA idptr; // ListBase *lb; // UNUSED ID *id, *idfrom; + int editable= RNA_property_editable(template-ptr, template-prop); idptr= RNA_property_pointer_get(template-ptr, template-prop); id= idptr.data; @@ -352,14 +353,12 @@ if (id) but-icon = ui_id_icon_get(C, id, 1); uiButSetFlag(but, UI_HAS_ICON|UI_ICON_PREVIEW); } - if((idfrom idfrom-lib)) + if((idfrom idfrom-lib) || !editable) uiButSetFlag(but, UI_BUT_DISABLED); - uiLayoutRow(layout, 1); - } else - - if(flag UI_ID_BROWSE) { + } + else if(flag UI_ID_BROWSE) { but= uiDefBlockButN(block, id_search_menu, MEM_dupallocN(template), , 0, 0, UI_UNIT_X*1.6, UI_UNIT_Y, template_id_browse_tip(type)); if(type) { but-icon= RNA_struct_ui_icon(type); @@ -368,7 +367,7 @@ uiButSetFlag(but, UI_HAS_ICON|UI_ICON_LEFT); } - if((idfrom idfrom-lib)) + if((idfrom idfrom-lib) || !editable) uiButSetFlag(but, UI_BUT_DISABLED); } @@ -410,7 +409,7 @@ but= uiDefBut(block, BUT, 0, str, 0,0,UI_UNIT_X+10,UI_UNIT_Y, NULL, 0, 0, 0, 0, Displays number of users of this data. Click to make a single-user copy.); uiButSetNFunc(but, template_id_cb, MEM_dupallocN(template), SET_INT_IN_POINTER(UI_ID_ALONE)); - if(!id_copy(id, NULL, 1 /* test only */) || (idfrom idfrom-lib)) + if(!id_copy(id, NULL, 1 /* test only */) || (idfrom idfrom-lib) || !editable) uiButSetFlag(but, UI_BUT_DISABLED); } @@ -433,7 +432,7 @@ uiButSetNFunc(but, template_id_cb, MEM_dupallocN(template), SET_INT_IN_POINTER(UI_ID_ADD_NEW)); } - if((idfrom idfrom-lib)) + if((idfrom idfrom-lib) || !editable) uiButSetFlag(but, UI_BUT_DISABLED); } @@ -449,7 +448,7 @@ uiButSetNFunc(but, template_id_cb, MEM_dupallocN(template), SET_INT_IN_POINTER(UI_ID_OPEN)); } - if((idfrom idfrom-lib)) + if((idfrom idfrom-lib) || !editable) uiButSetFlag(but, UI_BUT_DISABLED); } @@ -468,7 +467,7 @@ uiButSetFlag(but, UI_BUT_DISABLED); } - if((idfrom idfrom-lib)) + if((idfrom idfrom-lib) || !editable) uiButSetFlag(but, UI_BUT_DISABLED); } ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37078] trunk/blender/source/blender: Fix #27550: texture node editor header was still showing texture datablock
Revision: 37078 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37078 Author: blendix Date: 2011-06-01 16:17:38 + (Wed, 01 Jun 2011) Log Message: --- Fix #27550: texture node editor header was still showing texture datablock selector even if there is no active texture slot or node, now it's disabled in that case. Modified Paths: -- trunk/blender/source/blender/blenkernel/BKE_texture.h trunk/blender/source/blender/blenkernel/intern/texture.c trunk/blender/source/blender/editors/space_node/space_node.c trunk/blender/source/blender/makesrna/intern/rna_internal.h trunk/blender/source/blender/makesrna/intern/rna_lamp.c trunk/blender/source/blender/makesrna/intern/rna_material.c trunk/blender/source/blender/makesrna/intern/rna_particle.c trunk/blender/source/blender/makesrna/intern/rna_world.c Modified: trunk/blender/source/blender/blenkernel/BKE_texture.h === --- trunk/blender/source/blender/blenkernel/BKE_texture.h 2011-06-01 16:13:48 UTC (rev 37077) +++ trunk/blender/source/blender/blenkernel/BKE_texture.h 2011-06-01 16:17:38 UTC (rev 37078) @@ -103,6 +103,8 @@ void set_current_lamp_texture(struct Lamp *la, struct Tex *tex); void set_current_particle_texture(struct ParticleSettings *part, struct Tex *tex); +int has_current_material_texture(struct Material *ma); + struct TexMapping *add_mapping(void); void init_mapping(struct TexMapping *texmap); Modified: trunk/blender/source/blender/blenkernel/intern/texture.c === --- trunk/blender/source/blender/blenkernel/intern/texture.c2011-06-01 16:13:48 UTC (rev 37077) +++ trunk/blender/source/blender/blenkernel/intern/texture.c2011-06-01 16:17:38 UTC (rev 37078) @@ -1191,6 +1191,28 @@ } } +int has_current_material_texture(Material *ma) +{ + bNode *node; + + if(ma ma-use_nodes ma-nodetree) { + node= nodeGetActiveID(ma-nodetree, ID_TE); + + if(node) { + return 1; + } + else { + node= nodeGetActiveID(ma-nodetree, ID_MA); + if(node) + ma= (Material*)node-id; + else + ma= NULL; + } + } + + return (ma != NULL); +} + Tex *give_current_world_texture(World *world) { MTex *mtex= NULL; Modified: trunk/blender/source/blender/editors/space_node/space_node.c === --- trunk/blender/source/blender/editors/space_node/space_node.c 2011-06-01 16:13:48 UTC (rev 37077) +++ trunk/blender/source/blender/editors/space_node/space_node.c 2011-06-01 16:17:38 UTC (rev 37078) @@ -222,6 +222,8 @@ case NC_NODE: if (wmn-action == NA_EDITED) ED_area_tag_refresh(sa); + else if (wmn-action == NA_SELECTED) + ED_area_tag_redraw(sa); break; case NC_IMAGE: Modified: trunk/blender/source/blender/makesrna/intern/rna_internal.h === --- trunk/blender/source/blender/makesrna/intern/rna_internal.h 2011-06-01 16:13:48 UTC (rev 37077) +++ trunk/blender/source/blender/makesrna/intern/rna_internal.h 2011-06-01 16:17:38 UTC (rev 37078) @@ -187,7 +187,7 @@ void rna_def_motionpath_common(struct StructRNA *srna); void rna_def_texmat_common(struct StructRNA *srna, const char *texspace_editable); -void rna_def_mtex_common(struct BlenderRNA *brna, struct StructRNA *srna, const char *begin, const char *activeget, const char *activeset, const char *structname, const char *structname_slots, const char *update); +void rna_def_mtex_common(struct BlenderRNA *brna, struct StructRNA *srna, const char *begin, const char *activeget, const char *activeset, const char *activeeditable, const char *structname, const char *structname_slots, const char *update); void rna_def_render_layer_common(struct StructRNA *srna, int scene); void rna_ID_name_get(struct PointerRNA *ptr, char *value); Modified: trunk/blender/source/blender/makesrna/intern/rna_lamp.c === --- trunk/blender/source/blender/makesrna/intern/rna_lamp.c 2011-06-01 16:13:48 UTC (rev 37077) +++ trunk/blender/source/blender/makesrna/intern/rna_lamp.c 2011-06-01 16:17:38 UTC (rev 37078) @@ -374,7 +374,7 @@ /* textures */ rna_def_mtex_common(brna, srna, rna_Lamp_mtex_begin, rna_Lamp_active_texture_get, - rna_Lamp_active_texture_set, LampTextureSlot, LampTextureSlots, rna_Lamp_update); +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37079] branches/soc-2011-radish/source/ blender/editors/sculpt_paint/paint_vertex.c: I' ve begun treating unlocked misc vertex groups differently tha
Revision: 37079 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37079 Author: jason_hays22 Date: 2011-06-01 17:04:32 + (Wed, 01 Jun 2011) Log Message: --- I've begun treating unlocked misc vertex groups differently than unlocked bone groups- unlocked misc vertex groups should no longer have any involvement in the redistribution of weights. I may need a better auto normalize solution, however, because the weights can become 0 with enough division. Modified Paths: -- branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c Modified: branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c === --- branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c 2011-06-01 16:17:38 UTC (rev 37078) +++ branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c 2011-06-01 17:04:32 UTC (rev 37079) @@ -1037,6 +1037,9 @@ it simply makes the highest weight sum add up to one the Mesh is needed to change the ratios across the group + +I need to resolve a precision error issue, however: +dividing can cause the weights to drop to 0 */ static void do_wp_auto_normalize_locked_groups(Mesh *me, MDeformVert *dvert, char* map) { @@ -1056,7 +1059,10 @@ cnt = dv.totweight; currentSum = 0.0f; for(k = 0; k cnt; k++) { - currentSum += (dv.dw+k)-weight; + if(map[dv.dw-def_nr]) { + //printf(group %d considered\n, dv.dw-def_nr); + currentSum += (dv.dw+k)-weight; + } } if(highestSum currentSum) { highestSum = currentSum; @@ -1070,7 +1076,9 @@ cnt = dv.totweight; for(k = 0; k cnt; k++) { - (dv.dw+k)-weight /= highestSum; + if(map[dv.dw-def_nr]) { + (dv.dw+k)-weight /= highestSum; + } } } } @@ -1107,7 +1115,7 @@ { int i; for(i = 0; i dvert-totweight; i++) { - if(flags[(dvert-dw+i)-def_nr]) { + if(flags[(dvert-dw+i)-def_nr] (dvert-dw+i)-weight 0.0f) { return TRUE; } } @@ -1196,7 +1204,7 @@ (if it has to, then it will put some/all of the change back onto the original group) */ -static void redistribute_weight_change(MDeformVert *dvert, MDeformWeight *pnt_dw, float oldw, char* flags, int defcnt) +static void redistribute_weight_change(MDeformVert *dvert, MDeformWeight *pnt_dw, float oldw, char* flags, int defcnt, char *map) { int i; float change_left = oldw - pnt_dw-weight; @@ -1207,7 +1215,7 @@ MDeformWeight *dw; //printf(start\n); for(i = 0; i defcnt; i++) { - if(pnt_dw-def_nr == i) { + if(pnt_dw-def_nr == i || !map[i]) { change_status[i] = FALSE; } else { change_status[i] = !flags[i]; @@ -1256,6 +1264,24 @@ MEM_freeN(change_status); //printf(done\n); } +/* Jason */ +static void check_locks_and_normalize(Mesh *me, int index, int vgroup, MDeformWeight *dw, float oldw, char *validmap, char *flags, int defcnt, char *bone_groups) +{ + if(flags has_locked_group(me-dvert+index, flags)) { + if(flags[dw-def_nr]) { + // cannot change locked groups! + dw-weight = oldw; + } else if(bone_groups[dw-def_nr]) { + redistribute_weight_change(me-dvert+index, dw, oldw, flags, defcnt, bone_groups); + do_wp_auto_normalize_locked_groups(me, me-dvert, validmap); + } + } else { + do_weight_paint_auto_normalize(me-dvert+index, vgroup, validmap); + } +} +// Jason +static char *wpaint_make_validmap(Object *ob); + static void do_weight_paint_vertex(VPaint *wp, Object *ob, int index, float alpha, float paintweight, int flip, int vgroup_mirror, char *validmap) @@ -1266,8 +1292,14 @@ /* Jason was here */ char* flags; + char* bone_groups; float oldw; int defcnt; + if(validmap) { + bone_groups = validmap; + }else { + bone_groups = wpaint_make_validmap(ob); + } if(wp-flag VP_ONLYVGROUP) { dw= defvert_find_index(me-dvert+index, vgroup); @@ -1286,17 +1318,7 @@ wpaint_blend(wp, dw, uw, alpha, paintweight, flip); /* Jason was here */ - if(flags has_locked_group(me-dvert+index, flags)) { - if(flags[dw-def_nr]) { - //
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37080] branches/soc-2011-radish/source/ blender/editors/sculpt_paint/paint_vertex.c: Fixed the redistribute_weight_change() function so that it sprea
Revision: 37080 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37080 Author: jason_hays22 Date: 2011-06-01 19:21:36 + (Wed, 01 Jun 2011) Log Message: --- Fixed the redistribute_weight_change() function so that it spreads the change evenly and cannot /0. Modified Paths: -- branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c Modified: branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c === --- branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c 2011-06-01 17:04:32 UTC (rev 37079) +++ branches/soc-2011-radish/source/blender/editors/sculpt_paint/paint_vertex.c 2011-06-01 19:21:36 UTC (rev 37080) @@ -1211,6 +1211,8 @@ float change; char was_a_change; int groups_left_that_can_change = 0; + // make sure there is no case for division by 0, and make the redistribution the same per loop. + int groups_currently_left; char* change_status = MEM_mallocN(defcnt*sizeof(char), defflags); MDeformWeight *dw; //printf(start\n); @@ -1227,6 +1229,7 @@ } //printf(\n); if(groups_left_that_can_change 0) { + groups_currently_left = groups_left_that_can_change; do { was_a_change = FALSE; for(i = 0; i dvert-totweight; i++) { @@ -1245,18 +1248,19 @@ change_left += dw-weight-1.0f; dw-weight = 1.0f; - groups_left_that_can_change--; + groups_currently_left--; change_status[dw-def_nr] = FALSE; }else if(dw-weight = 0.0f) { change_left += dw-weight; dw-weight = 0.0f; - groups_left_that_can_change--; + groups_currently_left--; change_status[dw-def_nr] = FALSE; } was_a_change = TRUE; } + groups_left_that_can_change = groups_currently_left; } while(groups_left_that_can_change 0 change_left != 0.0f was_a_change); } // add any remaining change back to the original weight ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37081] branches/bmesh/blender/source/ blender: =bmesh= committing not-quite-functional edge split modifier code before replacing it with a bmesh vers
Revision: 37081 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37081 Author: joeedh Date: 2011-06-01 19:30:19 + (Wed, 01 Jun 2011) Log Message: --- =bmesh= committing not-quite-functional edge split modifier code before replacing it with a bmesh version, taking too much time to debug right now. Modified Paths: -- branches/bmesh/blender/source/blender/blenkernel/intern/cdderivedmesh.c branches/bmesh/blender/source/blender/blenkernel/intern/mesh.c branches/bmesh/blender/source/blender/blenkernel/intern/subsurf_ccg.c branches/bmesh/blender/source/blender/bmesh/operators/mesh_conv.c branches/bmesh/blender/source/blender/editors/space_view3d/drawobject.c branches/bmesh/blender/source/blender/modifiers/intern/MOD_edgesplit.c branches/bmesh/blender/source/blender/modifiers/intern/MOD_solidify.c Modified: branches/bmesh/blender/source/blender/blenkernel/intern/cdderivedmesh.c === --- branches/bmesh/blender/source/blender/blenkernel/intern/cdderivedmesh.c 2011-06-01 19:21:36 UTC (rev 37080) +++ branches/bmesh/blender/source/blender/blenkernel/intern/cdderivedmesh.c 2011-06-01 19:30:19 UTC (rev 37081) @@ -867,7 +867,7 @@ MVert *mv = cddm-mvert; MFace *mf = cddm-mface; MCol *mc; - float *nors= dm-getTessFaceDataArray(dm, CD_NORMAL); + float *nors= DM_get_tessface_data_layer(dm, CD_NORMAL); int i, orig, *index = DM_get_tessface_data_layer(dm, CD_ORIGINDEX); mc = DM_get_tessface_data_layer(dm, CD_ID_MCOL); @@ -944,6 +944,8 @@ } glEnd(); + } else { + printf(eek!\n); } if (nors) nors += 3; @@ -2189,7 +2191,9 @@ cddm-mloop = CustomData_get_layer(dm-loopData, CD_MLOOP); cddm-mpoly = CustomData_get_layer(dm-polyData, CD_MPOLY); - + + cdDM_recalcTesselation(cddm); + return dm; } Modified: branches/bmesh/blender/source/blender/blenkernel/intern/mesh.c === --- branches/bmesh/blender/source/blender/blenkernel/intern/mesh.c 2011-06-01 19:21:36 UTC (rev 37080) +++ branches/bmesh/blender/source/blender/blenkernel/intern/mesh.c 2011-06-01 19:30:19 UTC (rev 37081) @@ -2296,9 +2296,9 @@ for (j=0; jmp-totloop; j++, ml++) { v = BLI_addfillvert(mvert[ml-v].co); if (polyorigIndex use_poly_origindex) - v-tmp.l = polyorigIndex[i]; + v-hash = polyorigIndex[i]; else - v-tmp.l = i; + v-hash = i; v-keyindex = mp-loopstart + j; @@ -2323,11 +2323,11 @@ mf[k].v3 = f-v3-keyindex; /*put poly index in mf-v4*/ - mf[k].v4 = f-v1-tmp.l; + mf[k].v4 = f-v1-hash; mf[k].mat_nr = mp-mat_nr; mf[k].flag = mp-flag; - origIndex[k] = use_face_origindex ? k : f-v1-tmp.l; + origIndex[k] = use_face_origindex ? k : f-v1-hash; k++; } Modified: branches/bmesh/blender/source/blender/blenkernel/intern/subsurf_ccg.c === --- branches/bmesh/blender/source/blender/blenkernel/intern/subsurf_ccg.c 2011-06-01 19:21:36 UTC (rev 37080) +++ branches/bmesh/blender/source/blender/blenkernel/intern/subsurf_ccg.c 2011-06-01 19:30:19 UTC (rev 37081) @@ -2624,7 +2624,7 @@ int index, totvert, totedge, totface; int i; int vertNum, edgeNum, faceNum; - int *vertOrigIndex, *faceOrigIndex, *polyOrigIndex; /* *edgeOrigIndex - as yet, unused */ + int *vertOrigIndex, *faceOrigIndex, *polyOrigIndex, *base_polyOrigIndex; /* *edgeOrigIndex - as yet, unused */ short *edgeFlags; char *faceFlags; int *loopidx = NULL, *vertidx = NULL; @@ -2777,6 +2777,8 @@ mface = dm-getTessFaceArray(dm); mpoly = CustomData_get_layer(dm-polyData, CD_MPOLY); + base_polyOrigIndex = CustomData_get_layer(dm-polyData, CD_ORIGINDEX); + /*CDDM hack*/ edgeFlags = ccgdm-edgeFlags = MEM_callocN(sizeof(short)*totedge, faceFlags); faceFlags = ccgdm-faceFlags = MEM_callocN(sizeof(char)*2*totface, faceFlags);
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37082] branches/bmesh/blender/source/ blender: =bmesh= edge split modifier uses bmesh code for now, slower but works.
Revision: 37082 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37082 Author: joeedh Date: 2011-06-01 19:47:21 + (Wed, 01 Jun 2011) Log Message: --- =bmesh= edge split modifier uses bmesh code for now, slower but works. Modified Paths: -- branches/bmesh/blender/source/blender/blenkernel/intern/editderivedbmesh.c branches/bmesh/blender/source/blender/modifiers/intern/MOD_edgesplit.c Modified: branches/bmesh/blender/source/blender/blenkernel/intern/editderivedbmesh.c === --- branches/bmesh/blender/source/blender/blenkernel/intern/editderivedbmesh.c 2011-06-01 19:30:19 UTC (rev 37081) +++ branches/bmesh/blender/source/blender/blenkernel/intern/editderivedbmesh.c 2011-06-01 19:47:21 UTC (rev 37082) @@ -200,18 +200,18 @@ tm-looptris = (BMLoop *(*)[3])looptris; } -void BMEdit_RecalcTesselation(BMEditMesh *tm) +void BMEdit_RecalcTesselation(BMEditMesh *em) { - BMEdit_RecalcTesselation_intern(tm); + BMEdit_RecalcTesselation_intern(em); - if (tm-derivedFinal tm-derivedFinal == tm-derivedCage) { - if (tm-derivedFinal-recalcTesselation) - tm-derivedFinal-recalcTesselation(tm-derivedFinal); - } else if (tm-derivedFinal) { - if (tm-derivedCage-recalcTesselation) - tm-derivedCage-recalcTesselation(tm-derivedCage); - if (tm-derivedFinal-recalcTesselation) - tm-derivedFinal-recalcTesselation(tm-derivedFinal); + if (em-derivedFinal em-derivedFinal == em-derivedCage) { + if (em-derivedFinal-recalcTesselation) + em-derivedFinal-recalcTesselation(em-derivedFinal); + } else if (em-derivedFinal) { + if (em-derivedCage-recalcTesselation) + em-derivedCage-recalcTesselation(em-derivedCage); + if (em-derivedFinal-recalcTesselation) + em-derivedFinal-recalcTesselation(em-derivedFinal); } } Modified: branches/bmesh/blender/source/blender/modifiers/intern/MOD_edgesplit.c === --- branches/bmesh/blender/source/blender/modifiers/intern/MOD_edgesplit.c 2011-06-01 19:30:19 UTC (rev 37081) +++ branches/bmesh/blender/source/blender/modifiers/intern/MOD_edgesplit.c 2011-06-01 19:47:21 UTC (rev 37082) @@ -52,521 +52,65 @@ * or edge angle (can be used to achieve autosmoothing) */ -/*new cddm-based edge split code*/ -typedef struct VertUser { - int ov, v, done; - ListBase users; -} VertUser; +#define EDGE_MARK 1 -typedef struct EdgeNode { - struct EdgeNode *next, *prev; - struct EdgeData *edge; -} EdgeNode; - -typedef struct EdgeData { - EdgeNode v1node, v2node; - VertUser *v1user, *v2user; - float fno[3]; /*used to calculate face angles*/ - int has_fno; - int tag; - int v1, v2; - int used; - int idx; - int ml1, ml2, mp1, mp2; -} EdgeData; - -typedef struct LoopPair { - int ml1, ml2, mp1, mp2; -} LoopPair; - -typedef struct MemBase { - BLI_mempool *vertuserpool; -} MemBase; - -BM_INLINE EdgeData *edge_get_next(EdgeData *e, int ov) { - if (ov == e-v1) - return e-v1node.next ? e-v1node.next-edge : NULL; - else return e-v2node.next ? e-v2node.next-edge : NULL; -} - -BM_INLINE EdgeNode *edge_get_node(EdgeData *e, int ov) +DerivedMesh *doEdgeSplit(DerivedMesh *dm, EdgeSplitModifierData *emd, Object *ob) { - if (ov == e-v1) - return e-v1node; - else return e-v2node; - return NULL; -} - -BM_INLINE VertUser *edge_get_vuser(MemBase *UNUSED(b), EdgeData *edge, int ov) -{ - if (ov == edge-v1) - return edge-v1user; - else if (ov == edge-v2) - return edge-v2user; - else { - printf(yeek!!\n); - return NULL; - } -} - -BM_INLINE void edge_set_vuser(MemBase *b, EdgeData *e, int ov, VertUser *vu) - -{ - VertUser *olduser = edge_get_vuser(b, e, ov); - - if (vu == olduser) - return; - - if (olduser) - BLI_remlink(olduser-users, ov==e-v1 ? e-v1node : e-v2node); - BLI_addtail(vu-users, ov==e-v1 ? e-v1node : e-v2node); - - if (ov == e-v1) - e-v1user = vu; - else e-v2user = vu; -} - -BM_INLINE VertUser *new_vuser(MemBase *base) -{ - VertUser *vusr = BLI_mempool_calloc(base-vertuserpool); - - return vusr; -} - -BM_INLINE MemBase *new_membase(void) -{ - MemBase *b = MEM_callocN(sizeof(MemBase), MemBase for edgesplit in modifier.c); - b-vertuserpool = BLI_mempool_create(sizeof(VertUser), 1, 2048, 1, 0); - - return b; -} - -BM_INLINE void free_membase(MemBase *b) -{ - BLI_mempool_destroy(b-vertuserpool); -
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37083] branches/bmesh/blender: svn merge -r37035:37078 https://svn.blender.org/svnroot/bf-blender/trunk/ blender
Revision: 37083 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37083 Author: campbellbarton Date: 2011-06-01 23:38:46 + (Wed, 01 Jun 2011) Log Message: --- svn merge -r37035:37078 https://svn.blender.org/svnroot/bf-blender/trunk/blender Revision Links: -- http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37035 Modified Paths: -- branches/bmesh/blender/build_files/scons/tools/btools.py branches/bmesh/blender/intern/audaspace/CMakeLists.txt branches/bmesh/blender/release/scripts/modules/bpy_extras/image_utils.py branches/bmesh/blender/release/scripts/startup/bl_ui/space_userpref_keymap.py branches/bmesh/blender/release/windows/installer/00.sconsblender.nsi branches/bmesh/blender/source/blender/blenkernel/BKE_texture.h branches/bmesh/blender/source/blender/blenkernel/intern/texture.c branches/bmesh/blender/source/blender/blenloader/intern/readfile.c branches/bmesh/blender/source/blender/editors/interface/interface.c branches/bmesh/blender/source/blender/editors/interface/interface_handlers.c branches/bmesh/blender/source/blender/editors/interface/interface_templates.c branches/bmesh/blender/source/blender/editors/space_node/space_node.c branches/bmesh/blender/source/blender/makesrna/intern/rna_internal.h branches/bmesh/blender/source/blender/makesrna/intern/rna_lamp.c branches/bmesh/blender/source/blender/makesrna/intern/rna_material.c branches/bmesh/blender/source/blender/makesrna/intern/rna_particle.c branches/bmesh/blender/source/blender/makesrna/intern/rna_world.c branches/bmesh/blender/source/blender/nodes/intern/CMP_nodes/CMP_colorMatte.c branches/bmesh/blender/source/blender/nodes/intern/SHD_nodes/SHD_material.c branches/bmesh/blender/source/blender/nodes/intern/SHD_util.h branches/bmesh/blender/source/blender/windowmanager/SConscript Property Changed: branches/bmesh/blender/ branches/bmesh/blender/release/scripts/startup/bl_operators/add_mesh_torus.py branches/bmesh/blender/release/scripts/startup/bl_operators/uvcalc_smart_project.py branches/bmesh/blender/release/scripts/startup/bl_operators/vertexpaint_dirt.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_data_armature.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_data_bone.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_data_camera.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_data_empty.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_data_lamp.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_data_lattice.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_data_mesh.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_data_metaball.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_data_modifier.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_game.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_material.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_particle.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_physics_field.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_physics_fluid.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_physics_smoke.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_texture.py branches/bmesh/blender/release/scripts/startup/bl_ui/properties_world.py branches/bmesh/blender/release/scripts/startup/bl_ui/space_node.py branches/bmesh/blender/source/blender/editors/render/render_update.c branches/bmesh/blender/source/blender/editors/uvedit/uvedit_buttons.c Property changes on: branches/bmesh/blender ___ Modified: svn:mergeinfo - /trunk/blender:31524-37035 + /trunk/blender:31524-37078 Modified: branches/bmesh/blender/build_files/scons/tools/btools.py === --- branches/bmesh/blender/build_files/scons/tools/btools.py2011-06-01 19:47:21 UTC (rev 37082) +++ branches/bmesh/blender/build_files/scons/tools/btools.py2011-06-01 23:38:46 UTC (rev 37083) @@ -605,9 +605,12 @@ doneroot = False rootdirconts = [] datafiles = '' +deldatafiles = '' +deldatadirs = '' l = len(bf_installdir) for dp,dn,df in os.walk(bf_installdir): +# install if not doneroot: for f in df: rootdirconts.append(os.path.join(dp,f)) @@ -621,6 +624,16 @@ outfile = os.path.join(dp,f) datafiles += ' File '+outfile + \n +# uninstall +deldir = dp[l+1:] + +if len(deldir)0: +
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37084] branches/bmesh/blender/source/ blender/blenkernel/intern/cdderivedmesh.c: add missing cast
Revision: 37084 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37084 Author: campbellbarton Date: 2011-06-01 23:46:48 + (Wed, 01 Jun 2011) Log Message: --- add missing cast Modified Paths: -- branches/bmesh/blender/source/blender/blenkernel/intern/cdderivedmesh.c Modified: branches/bmesh/blender/source/blender/blenkernel/intern/cdderivedmesh.c === --- branches/bmesh/blender/source/blender/blenkernel/intern/cdderivedmesh.c 2011-06-01 23:38:46 UTC (rev 37083) +++ branches/bmesh/blender/source/blender/blenkernel/intern/cdderivedmesh.c 2011-06-01 23:46:48 UTC (rev 37084) @@ -2192,7 +2192,7 @@ cddm-mloop = CustomData_get_layer(dm-loopData, CD_MLOOP); cddm-mpoly = CustomData_get_layer(dm-polyData, CD_MPOLY); - cdDM_recalcTesselation(cddm); + cdDM_recalcTesselation((DerivedMesh *)cddm); return dm; } ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37085] trunk/blender/source/blender/ editors: uninitialized variable was used when ensuring mirrored vertex groups.
Revision: 37085 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37085 Author: campbellbarton Date: 2011-06-01 23:55:49 + (Wed, 01 Jun 2011) Log Message: --- uninitialized variable was used when ensuring mirrored vertex groups. Modified Paths: -- trunk/blender/source/blender/editors/interface/interface.c trunk/blender/source/blender/editors/sculpt_paint/paint_vertex.c Modified: trunk/blender/source/blender/editors/interface/interface.c === --- trunk/blender/source/blender/editors/interface/interface.c 2011-06-01 23:46:48 UTC (rev 37084) +++ trunk/blender/source/blender/editors/interface/interface.c 2011-06-01 23:55:49 UTC (rev 37085) @@ -1668,7 +1668,7 @@ return 0; } -void ui_set_but_default(bContext *C, uiBut *but, short all) +void ui_set_but_default(bContext *C, uiBut *UNUSED(but), short all) { PointerRNA ptr; Modified: trunk/blender/source/blender/editors/sculpt_paint/paint_vertex.c === --- trunk/blender/source/blender/editors/sculpt_paint/paint_vertex.c 2011-06-01 23:46:48 UTC (rev 37084) +++ trunk/blender/source/blender/editors/sculpt_paint/paint_vertex.c 2011-06-01 23:55:49 UTC (rev 37085) @@ -301,7 +301,7 @@ flip_side_name(name, defgroup-name, FALSE); if(strcmp(name, defgroup-name) != 0) { - for (curdef= ob-defbase.first, mirrdef; curdef; curdef=curdef-next, mirrdef++) { + for (curdef= ob-defbase.first, mirrdef= 0; curdef; curdef=curdef-next, mirrdef++) { if (!strcmp(curdef-name, name)) { break; } ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37086] trunk/blender/extern/glew: update to glew 1.6 from 1.5.8
Revision: 37086 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37086 Author: campbellbarton Date: 2011-06-02 00:05:54 + (Thu, 02 Jun 2011) Log Message: --- update to glew 1.6 from 1.5.8 Modified Paths: -- trunk/blender/extern/glew/include/GL/glew.h trunk/blender/extern/glew/include/GL/glxew.h trunk/blender/extern/glew/include/GL/wglew.h trunk/blender/extern/glew/src/glew.c Modified: trunk/blender/extern/glew/include/GL/glew.h === --- trunk/blender/extern/glew/include/GL/glew.h 2011-06-01 23:55:49 UTC (rev 37085) +++ trunk/blender/extern/glew/include/GL/glew.h 2011-06-02 00:05:54 UTC (rev 37086) @@ -1158,11 +1158,13 @@ /* -- GLU -- */ +#ifndef GLEW_NO_GLU /* this is where we can safely include GLU */ -#if defined(__APPLE__) defined(__MACH__) -#include OpenGL/glu.h -#else -#include GL/glu.h +# if defined(__APPLE__) defined(__MACH__) +#include OpenGL/glu.h +# else +#include GL/glu.h +# endif #endif /* - GL_VERSION_1_2 */ @@ -2445,6 +2447,18 @@ #endif /* GL_3DFX_texture_compression_FXT1 */ +/* --- GL_AMD_blend_minmax_factor -- */ + +#ifndef GL_AMD_blend_minmax_factor +#define GL_AMD_blend_minmax_factor 1 + +#define GL_FACTOR_MIN_AMD 0x901C +#define GL_FACTOR_MAX_AMD 0x901D + +#define GLEW_AMD_blend_minmax_factor GLEW_GET_VAR(__GLEW_AMD_blend_minmax_factor) + +#endif /* GL_AMD_blend_minmax_factor */ + /* --- GL_AMD_conservative_depth --- */ #ifndef GL_AMD_conservative_depth @@ -2587,6 +2601,21 @@ #endif /* GL_AMD_performance_monitor */ +/* GL_AMD_sample_positions */ + +#ifndef GL_AMD_sample_positions +#define GL_AMD_sample_positions 1 + +#define GL_SUBSAMPLE_DISTANCE_AMD 0x883F + +typedef void (GLAPIENTRY * PFNGLSETMULTISAMPLEFVAMDPROC) (GLenum pname, GLuint index, const GLfloat* val); + +#define glSetMultisamplefvAMD GLEW_GET_FUN(__glewSetMultisamplefvAMD) + +#define GLEW_AMD_sample_positions GLEW_GET_VAR(__GLEW_AMD_sample_positions) + +#endif /* GL_AMD_sample_positions */ + /* -- GL_AMD_seamless_cubemap_per_texture -- */ #ifndef GL_AMD_seamless_cubemap_per_texture @@ -3262,12 +3291,6 @@ #ifndef GL_ARB_draw_instanced #define GL_ARB_draw_instanced 1 -typedef void (GLAPIENTRY * PFNGLDRAWARRAYSINSTANCEDARBPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount); -typedef void (GLAPIENTRY * PFNGLDRAWELEMENTSINSTANCEDARBPROC) (GLenum mode, GLsizei count, GLenum type, const void* indices, GLsizei primcount); - -#define glDrawArraysInstancedARB GLEW_GET_FUN(__glewDrawArraysInstancedARB) -#define glDrawElementsInstancedARB GLEW_GET_FUN(__glewDrawElementsInstancedARB) - #define GLEW_ARB_draw_instanced GLEW_GET_VAR(__GLEW_ARB_draw_instanced) #endif /* GL_ARB_draw_instanced */ @@ -3827,8 +3850,12 @@ #define GL_VERTEX_ATTRIB_ARRAY_DIVISOR_ARB 0x88FE +typedef void (GLAPIENTRY * PFNGLDRAWARRAYSINSTANCEDARBPROC) (GLenum mode, GLint first, GLsizei count, GLsizei primcount); +typedef void (GLAPIENTRY * PFNGLDRAWELEMENTSINSTANCEDARBPROC) (GLenum mode, GLsizei count, GLenum type, const void* indices, GLsizei primcount); typedef void (GLAPIENTRY * PFNGLVERTEXATTRIBDIVISORARBPROC) (GLuint index, GLuint divisor); +#define glDrawArraysInstancedARB GLEW_GET_FUN(__glewDrawArraysInstancedARB) +#define glDrawElementsInstancedARB GLEW_GET_FUN(__glewDrawElementsInstancedARB) #define glVertexAttribDivisorARB GLEW_GET_FUN(__glewVertexAttribDivisorARB) #define GLEW_ARB_instanced_arrays GLEW_GET_VAR(__GLEW_ARB_instanced_arrays) @@ -6211,8 +6238,8 @@ typedef void (GLAPIENTRY * PFNGLPNTRIANGLESFATIPROC) (GLenum pname, GLfloat param); typedef void (GLAPIENTRY * PFNGLPNTRIANGLESIATIPROC) (GLenum pname, GLint param); -#define glPNTrianglesfATI GLEW_GET_FUN(__glPNTrianglewesfATI) -#define glPNTrianglesiATI GLEW_GET_FUN(__glPNTrianglewesiATI) +#define glPNTrianglesfATI GLEW_GET_FUN(__glewPNTrianglesfATI) +#define glPNTrianglesiATI GLEW_GET_FUN(__glewPNTrianglesiATI) #define GLEW_ATI_pn_triangles GLEW_GET_VAR(__GLEW_ATI_pn_triangles) @@ -7599,12 +7626,10 @@ typedef void (GLAPIENTRY * PFNGLFRAMEBUFFERTEXTUREEXTPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level); typedef void (GLAPIENTRY * PFNGLFRAMEBUFFERTEXTUREFACEEXTPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLenum face); -typedef void (GLAPIENTRY * PFNGLFRAMEBUFFERTEXTURELAYEREXTPROC) (GLenum target, GLenum attachment, GLuint texture, GLint level, GLint layer); typedef void (GLAPIENTRY * PFNGLPROGRAMPARAMETERIEXTPROC) (GLuint program, GLenum pname, GLint value); #define glFramebufferTextureEXT
[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [37087] trunk/blender/source/blender/ blenkernel/intern/multires.c: Fix #27539: Sculpt data is lost after editing base mesh
Revision: 37087 http://projects.blender.org/scm/viewvc.php?view=revroot=bf-blenderrevision=37087 Author: nazgul Date: 2011-06-02 04:58:27 + (Thu, 02 Jun 2011) Log Message: --- Fix #27539: Sculpt data is lost after editing base mesh Face's totdisp was set to correct value, but memory hasn't been allocated for disps. Handle this in multires_topology_changed(), so the whole MDISPS layer wouldn't be totally re-allocated when applying displacement. Modified Paths: -- trunk/blender/source/blender/blenkernel/intern/multires.c Modified: trunk/blender/source/blender/blenkernel/intern/multires.c === --- trunk/blender/source/blender/blenkernel/intern/multires.c 2011-06-02 00:05:54 UTC (rev 37086) +++ trunk/blender/source/blender/blenkernel/intern/multires.c 2011-06-02 04:58:27 UTC (rev 37087) @@ -1756,7 +1756,7 @@ int nvert= me-mface[i].v4 ? 4 : 3; /* allocate memory for mdisp, the whole disp layer would be erased otherwise */ - if(!mdisp-totdisp) { + if(!mdisp-totdisp || !mdisp-disps) { if(grid) { mdisp-totdisp= nvert*grid; mdisp-disps= MEM_callocN(mdisp-totdisp*sizeof(float)*3, mdisp topology); ___ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org http://lists.blender.org/mailman/listinfo/bf-blender-cvs