Commit Graph

4054 Commits

Author SHA1 Message Date
a77e3482f2 Saturday morning first cup of coffee hack (yeah, its a late
morning)

 - fun for the whole family, boolean mesh modifier... doesn't work
   with layered modifiers yet (just uses base mesh), although may
   god have mercy on your soul if you want to run boolean on a
   subsurf anyway
 - added displistmesh_add_edges

This exposes a bug in boolean, apparently the output is somehow
random (hash on alloc'd pointer value perhaps) which is sortof
lame.

It also makes more apparent the desire for some level of control
over dep graph evaluation during editmode (at the moment dep
graph is reevaluated for a mesh object in editmode, but since
mesh changes are on editmesh other objects don't really see
any change, so it is a wasted recalc).
2005-09-03 17:22:29 +00:00
e0c7d270d9 - assorted minor warning fixes 2005-09-03 16:20:33 +00:00
fdc1fd1e9c Fix for bug #2974:
Circle select in uv editor crashed when an image was assigned but not loaded.
2005-09-03 13:28:14 +00:00
517e526e9e Bug fix #2788
in 3d window, nkey panel, click in middle of number button & press ESC
moved the 3d cursor to that location. The button was passing on its
event to the window event queue, which shouldn't be.
2005-09-03 12:35:13 +00:00
cd9a35f1c6 Bug fix #2985
Envelope correction for moving bone-points in edit mode didn't reset on ESC
2005-09-03 12:14:59 +00:00
c238d21c18 Bugfix #2977
Tweaked selection code for Manipulators in 'combo' mode, it gives
preference now to the scale/translate widgets over the rotate arcs. This
enables use of these widgets in ortho top/side views.
2005-09-03 11:20:16 +00:00
fd7d224d4c Bug fix #2972
Copy/Paste bone name buttons crashed, didn't use the callback for buttons
proper yet.

Also added MAXFRAME defines for buttons, instead of hardcoded values 9000
or 18000
2005-09-03 10:50:21 +00:00
b787bc2829 Auto-Fgon Feature for subdivide
If Fgon is selected in mesh tools panel, In the following cases

Quad - 2 edge Adjacent - Path
Quad - 2 edge Adjacent - Innervert
Quad - 3 edge

'extra' faces are combined to fgons. to make cleaner subdivides. Please give feedback
2005-09-02 16:31:03 +00:00
1472a7aacd Adding back in the "Big Purple Dot" to indicate which edge the non-proportional Edgeslide is using for distance 2005-09-01 18:40:16 +00:00
0535d26e6d - Changed xz limit drawing to use same formulas as the limiting in the IK
module -- the previous method could be off pretty far.
- Added drawing of transparent surface for it, instead of just the border.
- Added "stretch IK", allowing bones not only to rotate, but also scale.
  The "Stretch" value below the DoF buttons is used to enabled this.

- Some code tweaking: slightly simplified computation of transform for IK,
  renamed chain to tree, removed unused pchan->ik_mat, ..

Internal IK module work:
- Do damping per DoF also based on stiffness, hopefully makes it converge
  faster with very stiff joints.
- Instead of having two joints types (translational and rotational), now
  all 6 DoF's can be enabled for one joint.
- Added limits for translational joints.
2005-08-31 22:09:44 +00:00
Alexander Ewering
c005095ea8 Re-enabled freetype font rendering :-) 2005-08-31 19:07:06 +00:00
5d1972cb4e - mesh_strip_loose_faces was completely wrong, dunno what I was on... 2005-08-31 04:04:28 +00:00
c9eb15714c Nonproportional mode for loopcut
while sliding the edge, press P this will swap modes. while in Non prop mode, press F to change the control "side". You can still change the control edge too.
2005-08-30 20:33:35 +00:00
3b96d6584f Force redraw on Edgeslide Cancel (RMB and ESC)
Fixes bug reported by Fab31 on IRC
2005-08-30 18:09:07 +00:00
3c4491de2f Bug #2962
Moving in Posemode + Rest Position a Bone crashed. Uninitialized Trans...
2005-08-29 18:03:03 +00:00
fa63c6a7e1 First version of visualizing the DoF (french degrees!) for Pose-bones. It
now only draws the limits for X and Z rotations (Y is bone axis itself).

Quick snaphsots (links will disappear):
http://www.blender.org/bf/rt6.jpg
http://www.blender.org/bf/rt7.jpg

It only draws for selected Bones that are part of IK, and have limits set.
Most work was getting code OK to setup drawing this 'DoF space', so now
experiments can be done with more drawing types.

ALso; Buttons for DoFs now only draw if the pose-bones are part of an IK
chain.
2005-08-29 17:02:24 +00:00
Alexander Ewering
a07394ef2c More text object fancyness, and fixes:
- "Flush" is now split into two seperate Alignment modes "Flush" and
   "Justify":

   - Justify does exactly the same as a normal word processor's justify
     function does, and in addition, it uses *whitespace* instead of
     *character spacing* (kerning) to fill lines. Much more readable.

   - Flush is pretty much the old Blender "Flush" mode - and as such it
     uses character spacing to fill lines. Just as Justify, this only
     works with at least one textframe.

 - Underlining for text objects. Not a lot to explain. New button "U" in
   the editbuttons, and CTRL-U as hotkey toggle underlining for newly
   entered characters or for the selection, just like CTRL-B/CTRL-I do for
   bold/italic.

   Underline height (thickness) and Underline position (vertical) can be
   set in the editbuttons.

   Implemented as CU_POLY polygon curves.

 - The B, U and i buttons (and the corresponding CTRL-B/U/I keystrokes)
   have been fixed to only affect *one* attribute at a time. Formerly,
   hitting CTRL-B when no other style was active, on a text portion with
   italics text, for example, would kill the italics and just apply bold.

   Now, these attributes always add or substract only, but do not
   replace the style.

 - In the past, there were bugs with material indices uninitialized, and
   thus crashes in the renderer with illegal material indices.

   Even though I assume they have been fixed, I've put in a check that
   checks (hah) if the material index of a character is illegal (bigger
   than ob->totcol), and then sets it to zero, and spits out a warning
   on stderr.

   If you see such warnings, please report and link to the .blend.

 - Bugfix: All alignment modes only worked if there were at least *two*
   lines of text in the text object. Fixed


There's now a regression test file for text objects, please add to the
corresponding repository:

http://blender.instinctive.de/downloads/release/demo/text-regression.blend.gz
2005-08-29 12:46:07 +00:00
Chris Want
5dd3bfdb18 MEM_freeN() and MEM_mallocN() should not have been redeclared in this
file.
2005-08-29 02:47:55 +00:00
796e4d33e0 Errors in buttons defining DoF for bones; needed a redraw and fixed typo
in min/max detection for buttons.
2005-08-28 17:52:34 +00:00
ae28d7bcfc Pose depgraph error... skipped a bone for proper IK sorting. Caused lag or
bad updates in grabbing.
2005-08-28 15:26:00 +00:00
275c214195 IK rotation limits fixes:
- Z-axis rotation limits were not working, was using wrong flag.
- Don't allow min limit to go over max, or vice versa.
- Fix for jacobian getting overwritten with IK clamping.
2005-08-28 13:06:41 +00:00
85efe767f0 Integration of new IK lib features in Armature Poses.
Best is to forget yesterday's commit and old docs. New docs are underway...

Here's how IK works now;

- IK chains can go all the way to the furthest parent Bone. Disregarding
  the old option "IK to Parent" and disgregarding whether a Bone has an
  offset to its parent (offsets now work for IK, so you can also make
  T-bones).
- The old "IK to Parent" option now only does what it should do: it denotes
  whether a Bone is directly connected to a Parent Bone, or not.
  In the UI and in code this option is now called "Connected".
- You can also define yourself which Bone will become the "Root" for an IK
  chain. This can be any Parent of the IK tip (where the IK constraint is).
  By default it goes all the way, unless you set a value for the new IK
  Constraint Panel option "Chain Lenght".
- "Tree IK" now is detected automatic, when multiple IK Roots are on the
  same Bone, and when there's a branched structure.
  Multiple IK's on a single chain (no branches) is still executed as usual,
  doing the IK's sequentially.
- Note: Branched structures, with _partial_ overlapping IK chains, that don't
  share the same Root will possibly disconnect branches.
- When you select a Bone with IK, it now draws a yellow dashed line to its
  Root.
- The IK options "Location Weight" and "Rotation Weight" are relative,
  in case there's a Tree IK structure. These weights cannot be set to
  zero. To animate or disable IK Targets, use the "Influence" slider.
- This new IK is backwards and upwards compatible for Blender files.
  Of course, the new features won't show in older Blender binaries! :)

Other changes & notes;

- In PoseMode, the Constraint Panel now also draws in Editing Buttons, next
  to the Bones Panel.
- IK Constraint Panel was redesigned... it's still a bit squished
- Buttons "No X DoF" is now called "Lock X". This to follow convention to
  name options positive.
- Added Undo push for Make/Clear Parent in Editmode Armature
- Use CTRL+P "Make Parent" on a single selected Bone to make it become
  connected (ALT+P had already "Disconnect").

On todo next; Visualizing & review of Bone DoF limits and stiffness
2005-08-28 12:23:06 +00:00
Stephen Swaney
adc1d7137a patch #2911 - tp_getset for Lamp module.
A nice juicy chunk of new style attribute handling from Ken Hughes.

Thanks, Ken.
2005-08-27 18:44:56 +00:00
eb1f65768a IK work-in-progress commit;
- Removed old convention that only allowed one "IK" connection for Bones
  in a joint. Was highly frustrating for editing trees or branches.
  In a next commit, there will be a different method to define IK target
  and IK root, so this option actually will become "Connect Bone" or so.

- the IK group name is gone, now is just an option "Tree IK". When IK
  chains share a root they'll form a tree.
  Todo is preventing conflicts here (will be for editor to define IK Root)

- Adding new IK constraint with CTRL+I activates Constraint
2005-08-27 17:04:29 +00:00
8f5bff6051 Make IK DOF stiffness work in range 0.0-1.0, for consistency. 2005-08-27 14:27:05 +00:00
ac619bace6 Third and last commit for Brecht's IK work.
Full logs for changes will be added later. Worth to note now;
- support for 'tree IK' added
- DOF and stiffness per IK bone (in pose only)
- Orientation IK support (target rotates -> chain follows)

This is still WIP. Buttons might change, button ranges will change, and the
way 'IK groups' are working will change. You can play with this, but don't
expect saved files to work still by end of this day! :)
2005-08-27 12:48:45 +00:00
669c4dbecb Fixes, as reported by Basse
- Softbody Mesh didnt update when it was child of armature-posing
- Bone Stick drawing didn't draw selected in Solid + Object mode.
- WeightPaint + Subsurf (nice that it works!) didn't update on Bone
  selection
2005-08-26 17:48:46 +00:00
1046dfb136 - tsk tsk, ll suffix for constants is not C standard, doesn't
work on msvc
2005-08-26 16:07:44 +00:00
8fb7bbacad accidentally left in testing printf. 2005-08-25 20:32:49 +00:00
6c9d743ef4 Based on a suggestion from Zr, using line line intersection for single axis projection.
This makes perspective handling a bit better.
2005-08-25 18:03:19 +00:00
8d940dfafe Random() issues with rendering...
- AO and soft shadow AreaLight tables were generated without fixed seed,
  causing animations to give unwanted amounts of noise.
- Made sure these tables now are calculated before render, with fixed seed
- Then found out the BLI_rand() has very bad seeding... it showed up as
  patterns. After some experimenting, found a nice method using noise.c
  hash tables. For compatibility with old code, named it BLI_srandom() to
  use this next to the BLI_srand(). This follows libc rand() and random()
  naming convention.
- Then of course threading should work... so made a BLI_thread_rand version
  of the calls. Now supports up to 16 threads, comments added in .h and .c

Result is stable animation render with AO and soft shadow. But, please
test and feedback!
2005-08-25 13:11:04 +00:00
c9f01eefcd iBug fix #2965
Switching scene in Edit Mode crashed. Accessed the DAG without it being
initialized yet.
2005-08-24 21:12:58 +00:00
a51896b591 Move the settings in the Mesh Tools panel to the new toolsettings struct in Scene. These settings are now saved per scene. 2005-08-24 20:37:25 +00:00
a978c122ee Making compiler happy;
- removed unused variables
- #if 0 around unused calls
- init of uninitialized vars
2005-08-24 20:26:28 +00:00
dfb654ba60 Huge commit, but not much features... had to shuffle a lot of code around.
Main target was cleanup of editconstraint.c and removal of the ugly
ob->activecon (active constraint channel), which was set by the "Show"
button in the Constraint Panel.
Better is to introduce an 'Active Constraint' itself, which stores in
the Constraint itself. By using this setting, and by checking the active
Bone, the UI can update reliably now. This only shows now in IpoWindow
btw (for constraint ipos). The active Constraint is drawn in the Buttons
with a slightly brighter backdrop. Any action in that Panel selects a
constraint now (even click in backdrop).

So now we have pose channels & constraint channels nicely behaving. Now the
darn Action channels... :)

Further in this commit:

- interface.c: Button ROUNDBOX now does button callback too.
               Button NUMSLI didn't do the callback on a click only

- Cleaned up include files in yafray, got annoyed it compiled over all the
  time.

- removed unused variables from Constraint struct
2005-08-24 20:18:03 +00:00
Chris Want
bc3f228bc9 Variable was defined in a header file (constant_Type), resulting in
'multiply defined symbol' warning on IRIX for every file that
included that file. Moved to a C source file.
2005-08-23 22:12:06 +00:00
9759296483 - more fixes for wpaint mode, need to patch mesh modifier as well
- change wpaint to flush changes during painting... can see this
   is going to be a problem because will also redeform. what to
   do, what to do...
2005-08-23 21:04:17 +00:00
81f995b741 - disabled incremental subsurf support (during object mode) for the
time being, misses features for texture/color drawing and I don't
   have time to finish at the moment. can return once UV/colors are
   incorporated into subdivision.
2005-08-23 20:39:58 +00:00
ad9099ea5d Fix for reading older files... it didn't always convert OK for the new
deformation options of Armatures, causing bones not to deform.

It was caused by using the old "boneclass" variable and SKINNABLE.
Apparently the boneclass can have any value in older files. Will be killed.

Please note; in files created after last sunday, with setting "No deform" on a
Bone, that setting has to be done again.
2005-08-23 20:19:01 +00:00
7396075ef1 - add option to drawMappedFaces to draw with colors (from tface or mcol)
- convert weightpaint/vertexpaint to draw using drawMappedFaces, slightly
   hacky because during weightpaint mcol's get overridden in order to
   have them propogate through modifiers. should work fine.
 - add NULL check in shaded draw, prevents crash w/ dupliframe
2005-08-23 20:04:10 +00:00
e12e2469c8 Bretch's patch for 2D transform. Thanks
Using new transform code to handle UV window.

With the ground work done, Transform could more easily be extended to handle IPO window now.

Tracker item: http://projects.blender.org/tracker/?func=detail&atid=127&aid=2946&group_id=9
2005-08-23 18:13:30 +00:00
207cbbd535 don't need Object.h 2005-08-23 16:50:53 +00:00
2540ca88e8 Quad Adjacent edge subdivide type moved to Mesh Tools panel rather than pupmenu on all subdiv calls. This is a session value like beauty and will revert to path each time you load blender. 2005-08-23 14:13:00 +00:00
056a33ac69 new game-menu option 'Record Game Physics to Ipo'
including implementation. hope it works, and doesn't break to much.
it bakes physics objects transform into ipo, every frame of the running gameengine.
When you disable and run the game again, it clears the ipo's again. just for physics objects at the moment.

(perhaps some better UI in the future?)
2005-08-23 13:16:02 +00:00
0192536102 - added iterator to edgehash
- updated decimator to make edges
2005-08-23 02:29:22 +00:00
Chris Want
3c1887036a Added (non-default) Makefile option to build blender with tweak mode.
To build with this option, set:

export NAN_TWEAK_MODE=true
2005-08-23 02:28:01 +00:00
4ad5cdf91e - subsurf getVertCos returned verts in wrong order since
shuffling of code... led to fun and crazy results (maybe
   less fun for les artiste)
2005-08-23 02:05:45 +00:00
Chris Want
d6b4392710 On windows/gcc (aka. FREE_WINDOWS), build the blenderplayer whenever
blender is configured to build with the gameengine.
2005-08-23 01:31:11 +00:00
50315dc100 Another painful editing issue solved!
Adding Ipos on a Constraint just was working totally insane. Here's how
it works now in the constraint Panel:

- Button "Show" will make the IpoWindow show the Constraint Ipo
 (it didn't before, when IpoWindow was not set to correct mode)

- Button "Key" will insert a key point on current frame (and show it in
  IpoWindow)

Note that both options will create an Action too, if not existed yet.
So, without opening an IpoWindow you can already animate Constraints.
(Todo: use the auto key option to always insert on changing slider)

And; selecting a Bone will update the Constraint IpoWindow too. Note
however, that when theres multiple Constraint Ipos on a Bone, it only
shows the first... will solve that later.
2005-08-22 21:58:55 +00:00
931d0fc235 - switch modifiers_isDeformedByArmature to also include
virtual modifiers
2005-08-22 20:25:54 +00:00