Commit Graph

3269 Commits

Author SHA1 Message Date
cb694458a6 A warning cleanup from the last commit. Added some explicit casts. Should just be double to float warnings left here now. Will do more later
Also made edgeslide move a little faster for the time being.
2005-07-13 16:33:30 +00:00
798d39dd4c Well here it is. Subdivision/Loop Tools Recode Commit #1
Ton has been pushing me to get this in and finish it up with help, so here is a run down of the commit

Revised Features
	Subdivide now is Edge based, allows for multicut
	Loopcut was recoded, now has multi option
	Knife tool now has multi option

New Features
	Edgeslide
	Edgering select

Removed Features
	Alt-B Edgeloop selection (use alt-RMB in edgemode)
	Shift-R Faceloop selection (use alt-RMB in facemode)
	Old Subdivide (Except for smooth which is left in until new one works)

Todo
	Subdivide Smooth Math is broken - could use some help here (look for alter_co in editmesh_tools.c)
	Tweak mouse control of Edgeslide is hackish ATM
	Add Non-proportional movement  to edgeslide
	Add smooth option to new loopcut

I probably left something out.

See here for more info
http://wiki.blender.org/bin/view.pl/Blenderdev/EdgeSubdivision
2005-07-13 15:20:40 +00:00
6a648da13f Another old bug bites the dust! Actually the error was simple... but
thanks to depgraph it executes nicely now. :)

#bug 2397: frame-duplicator using Constraint not evaluated.
2005-07-13 13:56:15 +00:00
542358265b Couple of small fixes;
- cleaned up 'version correction' a bit. There was code slowing down
  current files even (armatures were evaluated all, even when not in
  current layer, was added to make sure they get converted OK).
  Send me old files that crash now! :)
- on reading older files with path-constraints, a fix had to be added.
- error "badd call to addqueue' found when using header-less window for
  filewindow
2005-07-13 13:30:51 +00:00
3135b3ab83 Removed initializer str = "";
Seems to give issues in MSVC, and wasn't needed after all.

Further fixed dependencies in constraints between armatures and armatures.
It didn't update the other armature when the armature-object itself moved.
2005-07-13 08:56:07 +00:00
6787e21a63 Two little bugskis;
- Solid armature drawing didn't do well for negative scaled armatures
- Layer Ipos were not evaluated for invisible objects (there goes another
  exception bypassing dependency...!)
2005-07-12 17:46:39 +00:00
f4e1ea0b62 - add missing include 2005-07-12 17:26:19 +00:00
Alexander Ewering
6f5b3b10c8 Fix "Replace Meshes" in radiosity to actually only replace Meshes, and not
also delete lamps, cameras and anything else that was selected in the
"Collect Meshes" phase.
2005-07-12 16:24:27 +00:00
f6bd2ad3d0 ACK! Forgot to add the new drawarmature.c file. :) 2005-07-12 16:02:50 +00:00
ab45b910cd Constraint "influence" slider didn't work once there was an ipo assigned
once. Variable got initialized too often. :)

Oh! Here's a nice webpage about the previous commit:

http://www.blender3d.org/cms/Armature_draw_modes.629.0.html
2005-07-12 16:00:47 +00:00
1adf750fc3 Cleanup of Armature 3d drawing.
- In Solid drawmode, bones get drawn solid too now. Including Outline-
  selection color, if that's set.
  Disable it by setting Object-buttons "drawtype" for the Armature.
  Color used for solid bones is in Theme editor.
- EditMode armature now follows (Mesh edit) theme colors (Vertex, Edge)
- PoseMode armature has ThemeColor for selection, and draws three extra
  colors now;
   - blue shade for bones with action Ipos
   - yellow for bones with IK
   - green for bones with a constraint
- "X ray" now only works for PoseMode... needs review, can be done better
- "Draw Names" option uses theme color too, also indicates selection.

Fixes;

- In Armature EditMode, the deformed Mesh goes to rest-position
- Border select didn't clear 'active' flag in Bones in PoseMode
- Mouse-click select didn't work when a dashed line was close to Bone
2005-07-12 15:47:53 +00:00
d7ab2a584e - added missing include 2005-07-12 13:50:42 +00:00
f16ddaba04 The hide .data code didn't work correctly when databrowse is used to return something (when selecting a datablock, not just browsing).
It only counted visible blocks, but to get a valid index, it has to count invisible ones too.

Fixed
2005-07-12 03:37:16 +00:00
1b466f7765 Hide .file blocks in databrowse/pop menu.
This is mainly useful for scripts that generate/load datablocks for their own use and don't want to burry the user under an avalanche of datablocks he/she doesn't care about.

This adds a user pref "Hide .data" which now acts as a default value when opening a new fileselector.
It is also used when creating data select pop menus.

The "ghost" button in a fileselect window is independant from the userpref. It can be turned on/off individually without affecting

Note: When turning the option on/off, it sometimes take a couple of times before the pop menu registers it. Probably some caching thing. Will have to look at it.

Default value is Off.
2005-07-11 23:49:06 +00:00
0c0205ad78 My Radiosity commit had some code from my base list ordering experiement. (It wasn't removed because it didn't use the macros)
Caused radio to often say "no vertices" when that was obviously untrue.
2005-07-11 23:23:06 +00:00
01daf04ea6 - Object buttons, Hooks panel, clear offset didn't redraw correct
- Particle panel was drawing in wrong size
2005-07-11 19:31:15 +00:00
03c255ac1d New: Armature editmode/posemode now react correctly to HOME or Numpad-DOT
for viewing all or only selection nicely centered.

Fix: Poses without NLA or Action were reset to restposition on file read
or exit editmode.
2005-07-11 17:12:33 +00:00
7d80ffa538 - added bglVertex3f call (to match bglVertex3fv) 2005-07-11 17:06:03 +00:00
4c4de10cf8 Fix: Prevented depgraph to execute do_all_actions when you paste a poste. 2005-07-11 15:38:51 +00:00
70271db367 Corrected the Armature option "Delay deform", which doesn't update its
children during transform... to make it work, had to trick the nice
depgraph code... <sob> :)
2005-07-11 13:59:02 +00:00
a17e21dfab SLightly altered rule for the new IpoCurve option "Keep horizontal on
extrema". It now also keeps auto-handles horizontal when the Y coordinate
is exactly identical.

And; made this option default on inserting new curve/keys.
2005-07-11 12:31:15 +00:00
85aca9bba1 Fix for bug #2747
Knife cut in edge selection mode can cause crashes, since it uses subdivide
which isn't edge-select aware yet.
Quickly patched it by making knife checking on vertex selection.

Johnny: undo this change when you add the new subdiv code, good test for if
it works as well! :)
2005-07-11 11:58:29 +00:00
10c4c6463c Boundbox select object mode optimisation.
Changed selectprojektie (and renamed to view3d_opengl_select as suggested by Ton) to accept a buffer size, so boundbox can adapt it's buffer size to the number of object in scene.
Also, the loop is done more smartly, since glSelect fills the buffer in the same order as the drawing order, so we save lops of looping on unselected object (which used to go through all the buffer before finding that they weren't selected).

This scheme could probably be applied to all the other loops using glSelect. (good project for newbie coders)
2005-07-11 11:09:26 +00:00
8301d7ad00 Bug fix #2762
Quite harmless, but was lazy code...
When you choosed "Vertex Color Paint" material, the init_render_material()
also set the "Vertex color Light" option, because that flag was checked on
during render to detect vertex colors.
Now it has proper checks in render code.
2005-07-11 11:01:06 +00:00
54cd0cf56d This commit fixes radiosity to correctly preserve and subdivide UV
coordinates.

  Known problem: Pin status bleeds a bit, so new subdivided UVs around
points that were original pinned can end up pinned in the end. Could be
fixed, or could just drop pinned status entirely.

Also, when gathering meshes, it doesn't add materials twice, so it's harder to bust the 16 materials limit.
2005-07-11 10:48:14 +00:00
9cb84a662e Bug fix #2763
Depgraph missed proper relation from one armature bone to another armature
bone. Interesting rig setup for facial animation by Malefico! :)
http://projects.blender.org/tracker/index.php?func=detail&aid=2763&group_id=9&atid=125
2005-07-11 09:46:05 +00:00
0c197b211b Bugfix for #2768
Starting a Bake for SoftBody didn't initialize the animation system for the
first frame correctly, causing an initial unwanted softbody effect.
2005-07-11 09:27:35 +00:00
0fa1e2dcc7 Bug fix #2772
EditMesh undo didn't restore vertex colors! That slipped our attention for
almost a year... :)
2005-07-11 09:17:43 +00:00
27943d8798 More cleanup: removed do_all_actions() from the src/ tree, replaced with
proper recalc events. Now action-curve editing updates as it should be.
2005-07-11 08:33:52 +00:00
11a8714e54 Cleaned up the old call to do_all_actions(). It only is supposed to do
a single object, but was still called outside of that scope. Caused crashes
for example when editing Ipo curves of action keys.

editaction.c and editnla.c still need to be tackled...
2005-07-11 08:04:34 +00:00
b72c540f1c MetaBall editmode didn't send the DAG recalc event while transformed. :)
Meaning, it didn't do polygonizing while moving elements in edit mode.
2005-07-11 07:31:51 +00:00
399f670ac7 Scripts updated:
- Jean-Michel Soler: paths import -- ai and svg modules;
- Jean-Baptiste PERIN: bvh to armatures (note: should not work until we re-wrap armatures in bpython);
- Campbell Barton: obj importer.

Thanks guys, excuse me the delay.

- tiny doc update.
2005-07-11 02:41:08 +00:00
3d267e88e3 Fix for Bug #2793.
A really dumb coding error that I made when I coded this. left out brackets around an if block.
2005-07-10 13:45:12 +00:00
31f50d9247 For long on the wanna-have list;
Ipocurves with "Auto" handles now have option to remain horizontal on the
extrema (tops & valleys). Use ALT+H to set this per selected curve.
Note this is a per-curve feature, not per-handle.

If it works satisfying I can check on making this the default new added
curve.
2005-07-10 12:50:14 +00:00
227a67e105 Bug fix #2774
Using linked library files with relative paths, didn't set the correct
relative root... so it only worked with files in the same directory.
ALso fixed the button-lock in material buttons, it didn't allow to see
which materials were linked to the mesh/object.
2005-07-10 11:00:27 +00:00
65c9ea4588 Duplicating armatures didn't give proper re-build pose signal. 2005-07-10 10:36:01 +00:00
d7c7b54875 Switching scenes in the editor now correctly exits all modes, it didn't do
vertex/weight/texture paint yet.
2005-07-10 09:55:55 +00:00
36c2f0b682 Bug fix #2790
Pressing Wkey with no object active crashed.
2005-07-10 09:42:13 +00:00
3d6d14011c Bugfix #2791
Apply deform without object active crashed (only when using pulldowns)
2005-07-10 09:38:36 +00:00
7a31d07fda Bugfix #2797
Editmesh SHIFT+F "Fill" used an unsigned char to count amount of selected
edges linking to vertices, but also subtracted... causing the char to
become 255. Gave crashes (or infinite loops) when using "Fill" on random
input of solid meshes.
2005-07-10 09:32:30 +00:00
9fa952f9a5 Bugfix #2803
Transparent shadow could accidentally intersect first with a face being
farther away, due to the fact larger faces can fill up multiple octree
nodes. Had to use the same exception handling as for raytracing mirror or
glass.
2005-07-10 08:55:14 +00:00
0c89ddbf1c Changed type for new textimeout and texcollectrate into "int".
Please note that the "long" should be avoided in dna structs... it is a
reserved type for use in our code for pointer storage. It is 32 or 64 bits,
depending CPU architecture (pointer size).

The "long" type currently is in the makesdna.c code, and interpreted as 32
bits only, which is actually wrong yes... I should remove it or code it
correct.

BTW; this gave a warning in space.c, another case where MSVC forgives you?
:)
2005-07-10 08:31:56 +00:00
a7cd780ebf Armature;
- IK constraint now uses Ipo from action again
- Bug in last commit; the object action was ignored... did NLA always

Editmesh:

- when there are edges in mesh, it now only copies selection in edges
  when you have selectmode edge
2005-07-09 20:40:44 +00:00
d7bf5c0583 New! Pose-constraint Ipos now are integrated in NLA. ALso cleaned up the
weird disabled code that was hanging out there for ages.

Also cleaned up NLA blending itself, it was copying far too much data
around. Should be three times faster or so... need good test!

And restored Action Baking.
2005-07-09 19:37:38 +00:00
ef4bc76dc7 - add missing includes for lazy programmers who don't read error msgs 2005-07-09 18:04:53 +00:00
23980dd6b0 - fix what appeared to be obvious bug, "if (fclose) fclose(file)" ->
"if (file) fclose(file)", Text3d.c owner should check.
2005-07-09 17:54:03 +00:00
a4f907d2e0 Armatures; the bones menu used for "Make Parent" (CTRL+P) used wrong
indices still.
Cleaned the code, moved to editobject.c
2005-07-09 16:16:45 +00:00
30f89a6db7 Armature drawing fixes;
- Dashed line to parent bone was drawn to wrong bone in Rest Position
- Dashed line had selection color of parent, not of own bone.
2005-07-09 14:08:09 +00:00
c8f195d00c - Fix for action constraints; for Bone targets (target is input bone
actually) only the relative rotation is used.

- Added scale=1.0 initializer in saving files, this fixes a little  bit
  better upward compatibility

- Still there are cases where bones flip 180 degrees when you read it with
  older Blenders... not sure what it is caused by
2005-07-09 13:41:01 +00:00
5b24b2d31e Two little bugs showing up in workshop;
- update_for_new_frame() (on frame advance, alt+a) crashed when no 3d view
  was opened ever (NULL pointer)
- using proportional mode on Curve editing wrote beyond end of a malloced
  block. Just a minus one needed here...
2005-07-08 06:55:10 +00:00