Commit Graph

54 Commits

Author SHA1 Message Date
ef1295e723 === Custom Transform Orientation ===
Adding the possibility to use 2 or 3 vertice to define an edge or face-like orientation.
Adding the possibility to use 2 connected edges to define a face-like orientation.
2008-01-27 19:26:17 +00:00
450b3664e1 === Mirror Tool ===
Making the mirror tool axis selection interactive instead of using a popmenu.

Mirror is now just a constant -1 scaling transform, which enables you to choose the mirror axis through hotkeys (x,y,z) and with MMB. It also means it's easier to select the correct axis if you're not sure which is which and gives access to all the orientation supported in transform (including custom user orientations).

Mesh and Object header menus still have the individual axis as options but have an added "Interactive Mirror" which just enters transform and lets user pick the axis there. Ctrl-M enters "Interactive Mirror" too.

In a nutshell, this changes adds more possible mirroring axis and unifies the mirror axis selection process with transform constraint axis selection.
2008-01-24 20:11:54 +00:00
3d7271f059 === Transform Snap ===
Snapping Mode: Active

With this mode, the active element (at this time, object or vertice) is used as snapping target. If there is no active element in the selection, it reverts back to median mode.


Edit Mode snapping, other meshes no longer have to be selected to act as snapping point.


Fix a potential bug with snapping point from other meshes.
2008-01-20 22:43:48 +00:00
e4e66c9aa4 === Transform Snap ===
Snapping for object mode

Changes:
- Transform snap now working in object mode and not just mesh edit mode
- Shift-Tab can be used to toggle snap on/off inside transform too (no more Esc,toggle,restart)
- Object mode snap: Closest uses the bounding box corners of all selected objects, Median uses object center and Center uses transform center (same as edit mode).
- Object mode snap: all visible meshes can be used to get the snapping point (unlike edit mode snap which is limited to selected mesh: this might be adjusted to make edit mode snap use all visible too).

To Do:
- Add "Active" snap target method: use active object (or mesh element) as snap target
- Add snapping capabilities to Scale
- (Maybe) Add "Near pointer" snap target method: use selected element that is closest to mouse pointer as snap target. Active could probably accomplish that already in a less confusing manner, so I might skip this.
2008-01-13 22:20:18 +00:00
d660e29365 === Custom Transform Orientation ===
Custom Orientations can be added with Ctrl-Shift-C (hotkey suggestions are welcomed), this adds and select the new alignment. Custom Orientations can also be added, deleted, selected from the Transform Orientations panel (View -> Transform Orientations). Standard orientations (global, local, normal, view) can also be selected from this panel.

If you plan on using only a single custom orientation and don't really need a list, I suggest you use the hotkey as it adds and selects at the same time.

Custom Orientations are save in the scene and are selected per 3D view (like normal orientation).

Adding from an object, the orientation is a normalized version of the object's orientation.
Adding from mesh data, a single element (vertex, edge, face) must be selected in its respective selection mode. Vertex orientation Z-axis is based on the normal, edge Z-axis on the edge itself (X-axis is on the XoY plane when possible, Y-axis is perpendicular to the rest). Face orientation Z-axis is the face normal, X-axis is perpendicular to the first edge, Y-axis is perpendicular to the rest.
(More logical orientations can be suggested).

I plan to add: 2 vertice (connected or not) => edge orientation , 3 vertice = face orientation

Differences from the patch:
- orientations no longer link back to the object they came from, everything is copy on creation.
- orientations are overwritten based on name (if you add an orientation with the same name as one that already exists, it overwrites the old one)
2008-01-13 18:24:09 +00:00
38a33eb7da == Auto-Keyframing Refactor (Peach Request) ==
Refactored Auto-Keyframing to make it easier to add more options. There are now three "states" for auto-keying: off, add/replace keys, replace keys.

Description of modes:
1) No auto-keying is done
2) Add new keyframes or replace existing ones if possible (old behaviour)
3) Only modify existing keys, but not insert new ones. 

Internally, I've moved the auto-keying settings out of G.flag and U.uiflag and moved them into their own variables in Userdef, and provided some macros to access those easily. As a result, old auto-keying settings are currently lost.

Also, removed the manual calls to insertkey done in pose-relax. The reason auto-keying didn't work before was because the bones didn't have the BONE_TRANSFORM flag applied. Now, these are set temporarily.


Todo(s):
* Make icons for the TimeLine header menu (currently just a text menu)
* Add version-patches for old files
* Double-check code for all places that use auto-keying (i.e. PoseLib)
2008-01-10 01:36:22 +00:00
b0b3a69c19 == Transform: Warp ==
Adding special hotkey (MMB) to reverse the direction of the warp.

Normal input is 0..360 mapped to the horizontal position of the mouse on the 3D view (the 3D view becomes a sort of giant horizontal slider), pressing MMB reverses the value to 0..-360 and back if you press it again.

I've used MMB mostly because it's unused in Warp, easily accessible and already used to switches mode for Shear (shear x/y).

Indirectly suggested by a user question on ba.
2007-12-26 03:06:59 +00:00
faf638238d == Auto-IK ==
-- Peach request (from wiki feature request list) --

When translating a bone using Auto-IK, you can now use the ScrollWheel on the Mouse or the Page Up/Down keys to adjust the chain length. 

Notes:
* Up decreases the length, while Down increases it.
* The previously used chain-length is stored per scene
* Currently, it might be too sensitive. Also, it would help to have some kind of indication of the current chain-length somewhere...
* The chain length specified this way determines the MAXIMUM chain length possible for all chains (if 0, then the default chain-length is used). Chains are clamped to have a chain length which does not exceed the default chain length. This restriction may be removed following further feedback...
2007-12-15 07:35:16 +00:00
5c13e82140 Two transform tweaks:
* [Peach Request] AutoIK now respects axis locking (rotation locks).
- Temporary DOF-Locks are turned on for those bones that are part of an AutoIK chain while transforming. These locks get cleared after transforming.
- This works for all bones except the root bone of the chain, which doesn't seem to be able to be locked.

* Limit Location constraint can now optionally affect Translations too (i.e. NKEY panel values won't change). 
- LimitRot,LimitScale support (for their respective transforms) will be done at a later date
- This only works if the constraint is using World/Local space (the other spaces are not supported yet).
- I've added a temporary button in the LimitLoc panel to enable this option (it is disabled by default). This button will be properly assigned a place in that panel sometime.
2007-12-05 11:19:36 +00:00
7da56f4a9b Particles
=========

Merge of the famous particle patch by Janne Karhu, a full rewrite
of the Blender particle system. This includes:

- Emitter, Hair and Reactor particle types.
- Newtonian, Keyed and Boids physics.
- Various particle visualisation and rendering types.
- Vertex group and texture control for various properties.
- Interpolated child particles from parents.
- Hair editing with combing, growing, cutting, .. .
- Explode modifier.
- Harmonic, Magnetic fields, and multiple falloff types.

.. and lots of other things, some more info is here:

http://wiki.blender.org/index.php/BlenderDev/Particles_Rewrite
http://wiki.blender.org/index.php/BlenderDev/Particles_Rewrite_Doc

The new particle system cannot be backwards compatible. Old particle
systems are being converted to the new system, but will require
tweaking to get them looking the same as before.

Point Cache
===========

The new system to replace manual baking, based on automatic caching
on disk. This is currently used by softbodies and the particle system.

See the Cache API section on:
http://wiki.blender.org/index.php/BlenderDev/PhysicsSprint

Documentation
=============

These new features still need good docs for the release logs, help
for this is appreciated.
2007-11-26 22:09:57 +00:00
0ca5c98f23 Hinge Bone Transform
====================

This changes the way hinge bones are transformed when their parent bones
are also selected. Before it just disabled transform for these, now they
are rotated and scaled as well, but without influencing the transform
center, which gives behaviour as if they were regular bones.
2007-11-01 12:55:47 +00:00
6833fa4148 == IPO Editor Transform Refactor ==
As with the Action and NLA editors, I've refactored the transform code for the IPO editor to get rid of the special (and clunky) transform loop that had been created. The approach this time is closer to the one taken for the UV/Image editor.

What's New/Will-be-possible-in-the-future:
* Numeric input now works for the IPO editor
* Proportional Edit support for the IPO editor will eventually be added. 
* Rotation (hopefully), once some hotkeys have been remapped

Known Problems:
* If a keyframe moves past neighbouring keyframes and the transform gets cancelled, it doesn't get restored correctly. This problem is quite icky to resolve (I've got a large hack for this, but that currently segfaults randomly).
* When scaling, the dashed-line (helpline) is drawn from the wrong starting co-ordinates. This does not affect the actual scaling though
* Trying to scale BezTriples with autohandles still doesn't work if either of the handles haven't been transformed yet. This behaviour was already present prior to this commit.
2007-09-30 11:43:16 +00:00
c4860afba3 == Action and NLA Editor Transform ==
I've refactored the Action and NLA Editor Transform tools to use the Transform System instead of setting up their own transform loops. This should have happened ages ago, but no-one got around to doing so. 

* There are still a few bugs left to iron out of a few features, but on the whole it should work as well as it used to. These are: the values which get displayed when working with NLA-scaled actions may not all be correct yet; and the Time-Slide tool in the Action Editor is currently kindof broken.

* One of the main benefits of this work, is that it is now possible to use Numeric Input during Transforms.

* Also, a bug that meant that it was not possible to negatively scale keyframes in the Action Editor has been resolved.
2007-09-24 11:29:25 +00:00
1bde4e3274 2D Cursor in UV window
this can be placed by the moused and used for transforming around.

still need numeric location input but no room left in the image panel.
2007-09-14 16:12:17 +00:00
4e2143f639 This commit fixes up a bunch of svn properties to hopefully make things a little nicer for everyone.
Patch provied by gsrb3d

bug tracker #7061

Kent
2007-08-28 10:07:08 +00:00
9e32291a75 Small Transform code cleanup and addins for future features.
- Removing evil InitTransModeFlags (I would always forget to update that when adding new stuff). It's properly done in the per transform init now.
- Add toggleable mode for Shear (with MMB) for horizontal or vertical shear. Toggle shear mode also changes the input mode from vertical to horizontal and vice versa (it's intuitiver that way). (This was suggested in a really old patch but never implemented because I disliked adding transform specific handling in the main event switch).
- Add custom event handlers per transform (currently only used for Shear)
- Add custom data pointer and freeing flag (only (a)bused by Shear).

NOTE to Levi Schooley: Some stuff in there might be useful for you.
2007-08-09 01:07:27 +00:00
1c41d19964 == Auto-Keyframing ==
I've moved the Auto-Keyframing functionality out of the special_aftertrans_update function into two separate functions, which can be called independent of the Transform system. One is for Bones, while the other is for Objects.

This now means that the Shift-S Snapping Tools will now work with auto-keyframing.
2007-06-23 06:56:16 +00:00
afdd54fa37 moved source and text to american spelling
* colour -> color
* centre -> center
* normalise -> normalize
* modelling -> modeling
2007-04-04 13:18:41 +00:00
3c13561ab5 === Transform Snap ===
Fixed the bug where it would snap to a selected (moving) vertex.

Fixed a bug with Snap Closest with only one vertex selected.

=== Internals: EditMesh Mods ===

Modify and documented findnearestvert.

Added a new parameter to restrict the search to selected or unselected vert instead of just adding a bias to them (as previously). Currently, the "strict" method bypasses the openGL optimisation, people with more knowledge about that should feel invited to fix it.

=== Internals: EditMesh Tools ===

Adding missing newline at the end.
2006-12-28 22:42:58 +00:00
d665beb5df This just silences a compiler warning I got as a result of Nick's commit
last night.

warning: "struct View3D" declared inside parameter list
2006-12-28 22:08:33 +00:00
1ad1522d10 === Transform Snap ===
==== Rotation Snap ====

Snap is no longer limited to Translation, it works in Rotation too.

There's some bugs left with rotation snap when using constraints, I'll be ironing that next.

==== Bug Fixes ====

* Fix manipulators to always use Grid.
* Fix initialization bug (took two transform call to do a correct snap init when changing between Grid and Snap)
2006-12-23 00:52:34 +00:00
39c0f6dd83 === Transform Snap ===
The circle drawn around the snap point is now truely constant regardless of zoom and size of the window. That size if linearly proportional to the vertex size (bigger vertex -> bigger circle).
2006-12-21 20:45:57 +00:00
88ef092876 === Transform Snap ===
(Implementing Matt's idea)

Grid and Snap are now exclusively controlled by the Control key (pun intented).

You can switch to Snap by selecting the snap option in the Transform menu (this option is only available in edit mode on a mesh. this option is per 3D view) (NOTE: There is currently no hotkey for that, anyone should feel free to add one).

When Snap is selected, holding down Ctrl during translations (grab) snaps to vertex.

All other situations which have no snapping code yet defaults to Grid.
2006-12-20 19:47:12 +00:00
f4a03182fb === Transform Snap ===
Draw a circle around the snapping point for visual aid.

Different snapping target method, switchable in the 3d view header menu in the Transform menu.

* Closest: Snaps the closest vertex to the point
* Median: Snaps the median of the selection to the point
* Center: Snaps the transform center to the point (this is different from median because you can use Cursor/Boundbox as center)

Fix a bug with constraints/snap handling.
2006-12-19 22:25:07 +00:00
59b30d178a === Transform Snap ===
Work in Progress: this adds vertex snapping capabilities to translations.

As before, use the menu or the hotkey (` during transform) to turn on snapping.

Currently, snapping is restricted to translation and only snap to verts. Also, it will snap the nearest moving vert to the snapping vert.

This also has a timeout period and refreshes the snapping point only every 0.25 seconds (assuming the timer is precise enough to do that) to mitigate the slowdown due to repeated calls to findnearestvert. Eventually, a faster method will have to be used.

Also, this uncovered a bug in findnearestvert which can manifest itself as jumps and lags in snapping. People are looking into it.

Still, with all those disclaimers, get the suggestions/critics pouring in.
2006-12-18 23:48:32 +00:00
d310f203da Big Commit.
Now time-markers work in all time-related spaces (i.e. Ipo,
Action Editor, NLA editor, TimeLine, Sound). The hotkeys and
functionality set should be the same for each of these modes
(with a few exceptions still). I've had to change a few hotkeys
here and there, so hopefully they aren't too bad.

Marker Operations:
MKEY - Add Marker
SHIFT MKEY - Rename marker (was CTRL MKEY)
XKEY - Delete Marker
PAGE UP - Jump to next marker
PAGE DOWN - Jump to previous marker
CTRL A - Select all markers
SHIFT G - Transform markers (NLA, IPO, Action)
G - Transform markers (Sound, Timeline)
CTRL SHIFT D - Duplicate markers (NLA, IPO, Action)
SHIFT D - Duplicate markers (Sound, Timeline)
BKEY - select markers and other keyframes (if any)

I've also made a few little tool additions to NLA and Action editors:
* NLA editor - Snap To Frame.
Now with the option to offset strip so that it starts at the current frame.
Added menus for this.
* Action editor - Snap To Frame
A few new menus for this too
2006-11-30 01:57:14 +00:00
f0dcd2db75 == Transform ==
Embryon functionnality for snapping.

- Only snaps to grid on translations (grab)
- Transform constraints are supported but header display is wrong.
- Can be turned on/off in the Object/Mesh header menu under Transform Properties (tentative spot, will have to integrate better and in other object type menus too)
- Can be turned on/off during transform with ` (Back Quote, also tentative)

This is, of course, very much Work in Progress.

This implements part of the structural ideas for the transform cleanup I've been juggling around with.
2006-10-25 23:57:00 +00:00
2ee42ac01e Huge commit: VERSE
- All code is in #ifdef ... #endif
 - Only make build system is supported and you have to add:
    export WITH_VERSE=true
   to user-def.mk file
 - Blender can share only mesh objects and bitmaps now
 - More informations can be found at wiki:
    http://mediawiki.blender.org/index.php/BlenderDev/VerseIntegrationToBlender
    http://mediawiki.blender.org/index.php/BlenderDev/VerseIntegrationToBlenderUserDoc

  I hope, that I didn't forget at anything
2006-08-20 15:22:56 +00:00
d3028ec70d * Shrink/Fatten for bevelled curves
This is a much faster and easier way to give a bevelled curve a taper, without
using taper curves. Each point on a curve now has a 'radius' value that you can
shrink and fatten using Alt S, which will influence the taper when the curve is
bevelled (either with a bevob, or with front/back turned off and a bevel dept
set). Alt S shrinks and fattens the selected points in an interactive transform,
and you can set an absolute radius for selected points with 'Set Radius' in the
curve specials menu.

See demo: http://mke3.net/blender/etc/curve_shrinkfatten-h264.mov

This can be a quick way to create revolved surfaces (eg.
http://mke3.net/blender/etc/wineglass-h264.mov ) and it would be very
interesting to use this radius value in other tools, such as a 'freehand curve'
tool that would let you draw a curve freehand, with the radius affected by pen
pressure, or even using the radius at each point to control curve guides for
particles more precisely, rather than the continous maxdist.
2006-08-13 07:37:51 +00:00
00b55aba24 1)
The F3 key 'save rendered image' made inconsistant choices to save either
in jpg or tga, when the output panel was indicating to render to movies.
Even worse, it was sometimes saying 'save jpg' and saved a targa!

Made it consistantly save .jpg now, since tga isn't a good common format.

2)
Forgot to commit transform.h for previous bugfix in transform numeric input
2006-07-08 13:18:57 +00:00
1123be1bcc Orange request; Bones in Armature now have own layer settings.
Works like for Object layers, but local within Armature itself. Each Bone
can be in (16 now) any layer, and the Armature layer defines what is
visible or not. Also note that hiding will still work too.

Since the Blender code is *stuffed* with Bone options now, this commit
requires a good test if all tools we got now comply to layers...
(I counted 130 cases for checking for selected Bones in code!)

In PoseMode; hotkey M will show 'movetolayer' menu. Not in editmode...
then its the mirror menu.

Todo: make action/nla drawing comply to Armature layer settings.
2005-12-07 12:36:26 +00:00
c4a1d655ae True X-mirror mesh editing!
Set the option in EditMode, in 2nd mesh tools panel. It only works on
transform options now (grab/rot/scale), and of course assumes a near-
perfect symmetrical mesh. Mesh Object itself can be on any location
though (and rotated etc).
2005-12-01 19:04:57 +00:00
4ad59e30a0 New: Write Protection for transform values.
You now can set, in NKEY Transform Properties Panel, per XYZ rot/loc/size,
a protection for Transform tools to not change these values anymore.
This now works for Objects or for Bones in PoseMode.

Usage is especially for character animation, to give Bones in a Pose
defaults for rotation axes, so you don't have to worry about the correct
limitations (or setup complex IK limits).
Of course, this feature doesn't influence the animation system.

As an extra also the Transform Widgets then draw less handles. Note this
is based on the actual locked value, and depends still on Manipulator
orientation whether it can be used really.

Implementation warning: I had to remove the 'return' in the middle of the
editobject.c compatible_eul() call. It now makes nice compatible eulers
when they're simple (single axis rotations). Unfortunately there was no
note in the code why it was ever removed...

ALso: fix for crash in using Crease Transform and Mirror modifier.
2005-10-29 20:08:25 +00:00
6e94b02616 Various Transform bugfixes.
- Trackball rotate was missing the NoConstraints flag
- Zooming didn't recalculate the 2D center correctly
- Zooming in transform was sending event to the 3D window even when working on UVs. (disabled when working on UVs for now, will need to send events to a 2D window handler eventually)
- In camera mode, when the selection was exactly on the camera, initgrabz was barfing, fallback to 1.0 now, which gives ok results.
2005-09-24 18:00:32 +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
9e05d6efb5 Armature "Envelope" editing.
For defining the deformation distances of Bones, three values are being
used now. The bone tip and root radius define the bone-shape itself and the
"dist" defines the soft area around it. A full (user) doc is in CMS here;

http://www.blender3d.org/cms/Armature_Envelopes.647.0.html

Note: todo still is allowing both Vertex Deform Groups and these Envelopes
together (and or per Bone).

Also part of this commit is:

- New: Hiding bones in EditMode. This is a separate 'hide flag', so you can
  keep the PoseMode hidden Bones separate from EditMode.
  (In the future we should do some kind of bone-grouping or so)
- While transform(), the hotkeys G,R,S only switch mode when the previous
  mode was compatible. Caused conflicts with Crease/BoneDist/etc.
- Deleting the last VertexGroup now also deletes the entire Mesh 'dvert'
  data. Sounds logical, but remember that VertexGroups are partial on a
  Mesh, partial on Object. Weird design decision though...
  Anyhoo, at this moment the only way to have Bone Envelopes deform, is
  by deleting all VertexGroups!
- In PoseMode, the hotkey ALT+S now does both B-Bone size or Envelope,
  depending draw type.
- In EditMode, Extrude now also works when only Root points were selected.
- Weight editing is also symmetrical btw, with the "X-axis Mirror" option
  set.
2005-08-19 12:35:15 +00:00
b45ecb43ef New! When weight-painting a Mesh, and select a Bone, you can use transform
options on the Bone (G, R, S). The manipulator doesn't show btw.
Is usful to get immediate feedback on how painted weights behave with Bones.

Martin; I had to change the T_POSE behaviour in code a bit... it now
stores in TransInfo the actual posed armature being transformed. Maybe,
some day, we'll get mixed posechannel/object transform? Not much required
at the moment though. :)
2005-08-16 10:17:02 +00:00
1d27a7676b GCC 4 didn't like static function after non static prototype. Moved prototype to c file and added static to it. 2005-07-24 09:21:31 +00:00
0e2302bfa5 Big Transform Manipulator Merge
*NOTE*: Some UI decision done in this commit will most likely be revised, all flame shall go in /dev/null. Constructive discussions of course welcomed.

This commit merges manipulator orientation selection back in "traditional" transform.
That's how it works:
	- The dropdown in the 3D view header is always visible
	- The orientation chosen will be used when choosing an axis with MMB and for the *second* key press of X,Y,Z
		However, Local orientation doesn't use the one calculated by the manipulator. This is to ensure that multiple object local and armatures in pose still works as before.
	- Alt-Space (to change the orientation) works during transform


New Transform orientation: View, using the view axis.

Fixes for the following bugs:
	- Constraint projection code "jammed" if input vector was <0,0,0>, reported a couple of times on IRC. Thanks to Basse for the example file.
	- Transform on texspace crashed on objects without texspace data (camera, lamp, ...). This was reported in tracker.
	- Numinput with lock constraints didn't work correctly. Reported on elysiun

	Probably some others that I'm forgetting

I also moved a couple of functions around in an attempt to make things clearer.
2005-07-24 06:25:00 +00:00
19abd72baa Couple of fixes combined;
- With Actions on a Pose, ESC in transform restored wrong.
  This is solved similar to ipos now, storing a 'last time evaluated'.
  Could be extended to ghosting... soon.
- Moving the little yellow 'key blocks' in Action window didn't update
  3d window. ALso the 'lock' option didn't work, and flashed header.
- Pose Transform: noticed there were still errors in cases, especially
  with actions. Painfully tried to build the desired matrix now.
- Removed obsolete Bone pointer from TransData
2005-07-19 16:12:56 +00:00
e700b79587 Removed last remainder of old transform. The function is still called
special_aftertrans_update() though...
2005-07-19 11:21:01 +00:00
e67ba0ae33 More armature goodies;
The B-Bones!
(where the B can be read as 'block' or 'bezier' or 'b-spline')

- set option on/off in edit buttons, armature panel
- scaling of B-bones only works in editmode, use ALT+S to make bones fatter
  or thinner. Also works for constrainted transform
- In pose mode, you now have a buttons panel with per-bone settings too
  Here you can find the "segments" button, which allows bones to
  interpolate between previous/next bones, including roll.
- Buttons to control interpolation ("In" and "Out" are disabled, doesn't
  work satisfying yet

NOTE: this doesn't give deform yet! Main purpose for now is to test if this
drawing method serves to animate/pose armatures well.
Still need to review proper interpolation methods... maybe bezier is too
limited.
2005-07-16 19:07:02 +00:00
28a1e8277b Result of 2 weeks of quiet coding work in Greece :)
Aim was to get a total refresh of the animation system. This
is needed because;
- we need to upgrade it with 21st century features
- current code is spaghetti/hack combo, and hides good design
- it should become lag-free with using dependency graphs

A full log, with complete code API/structure/design explanation
will follow, that's a load of work... so here below the list with
hot changes;

- The entire object update system (matrices, geometry) is now
  centralized. Calls to where_is_object and makeDispList are
  forbidden, instead we tag objects 'changed' and let the
  depgraph code sort it out
- Removed all old "Ika" code
- Depgraph is aware of all relationships, including meta balls,
  constraints, bevelcurve, and so on.
- Made depgraph aware of relation types and layers, to do smart
  flushing of 'changed' events. Nothing gets calculated too often!
- Transform uses depgraph to detect changes
- On frame-advance, depgraph flushes animated changes

Armatures;

Almost all armature related code has been fully built from scratch.
It now reveils the original design much better, with a very clean
implementation, lag free without even calculating each Bone more than
once. Result is quite a speedup yes!

Important to note is;

1) Armature is data containing the 'rest position'
2) Pose is the changes of rest position, and always on object level.
   That way more Objects can use same Pose. Also constraints are in Pose
3) Actions only contain the Ipos to change values in Poses.

- Bones draw unrotated now
- Drawing bones speedup enormously (10-20 times)
- Bone selecting in EditMode, selection state is saved for PoseMode,
  and vice-versa
- Undo in editmode
- Bone renaming does vertexgroups, constraints, posechannels, actions,
  for all users of Armature in entire file
- Added Bone renaming in NKey panel
- Nkey PoseMode shows eulers now
- EditMode and PoseMode now have 'active' bone too (last clicked)
- Parenting in EditMode' CTRL+P, ALT+P, with nice options!
- Pose is added in Outliner now, with showing that constraints are in
  the Pose, not Armature
- Disconnected IK solving from constraints. It's a separate phase now,
  on top of the full Pose calculations
- Pose itself has a dependency graph too, so evaluation order is lag free.

TODO NOW;

- Rotating in Posemode has incorrect inverse transform (Martin will fix)
- Python Bone/Armature/Pose API disabled... needs full recode too
  (wait for my doc!)
- Game engine will need upgrade too
- Depgraph code needs revision, cleanup, can be much faster!
  (But, compliments for Jean-Luc, it works like a charm!)
- IK changed, it now doesnt use previous position to advance to next
  position anymore. That system looks nice (no flips) but is not well
  suited for NLA and background render.

TODO LATER;

We now can do loadsa new nifty features as well; like:

- Kill PoseMode (can be option for armatures itself)
- Make B-Bones (Bezier, Bspline, like for spines)
- Move all silly button level edit to 3d window (like CTRL+I = add
  IK)
- Much better & informative drawing
- Fix action/nla editors
- Put all ipos in Actions (object, mesh key, lamp color)
- Add hooks
- Null bones
- Much more advanced constraints...


Bugfixes;

- OGL render (view3d header) had wrong first frame on anim render
- Ipo 'recording' mode had wrong playback speed
- Vertex-key mode now sticks to show 'active key', until frame change

-Ton-
2005-07-03 17:35:38 +00:00
c00adc5ff8 Transform 2D center was using short. Not good enough when it's it's way off screen. Switched to ints, that fixed the bug in the tracker.
Switching to floats would probably be safer in the long term, but too many things to test to do that now.
2005-06-05 13:50:21 +00:00
14a3166685 Push/Pull didn't do Lock Constraint correctly. Fixed.
Also added an isLockConstraint function that tells if the current constraint is a locking constraint or not.
2005-05-29 09:21:34 +00:00
70c0f60df5 Fixing bug #2556: http://projects.blender.org/tracker/?func=detail&atid=125&aid=2556&group_id=9
MEMSET was clearing the TransInfo struct after the constraint setup call has been made.

Temporary fix until the manipulator transform init is split off, like normal transform.
2005-05-15 05:44:11 +00:00
d07dccc386 Found some time do sanitize the big Transform call:
- Splited off the event treatment into a fonction of its own
- Splited off the initialisation phase into a function of its own (will have to do it for the manipulator function too)
	Calling transform now works like this:
		initTransform(mode, context)
		- possible post init calls, constraints mostly
		Transform()
		- eventually, the postTransform function, so that Transform is just a simple big loop which could in the end just be tied in the blender event system instead.
- Added a state variable in TransInfo to replace the ret_val local variable. Possible values are: TRANS_RUNNING, TRANS_CANCEL, TRANS_CONFIRM
- Tied MMB and the hotkey select for constraint together, so selecting an axis with MMB and pressing the axis key after that goes to local mode on that axis. Much less confusing.
2005-05-10 04:21:11 +00:00
eec4e32714 Another Transform todo: correct Undo names for using Transform.
Martin; I've added calls like:
	BIF_TransformSetUndo("Add Duplicate");
In advance of calling transform itself, to indicate that this is the
string name to be used for Undo, and also has to be done on ESC.
To make that possible I had to add a memset() to zero the global struct
TransInfo. Nicely done with if(Trans.mode==TRANS_INIT)

Not sure how this relates to setting constraints in advance... I always
found it tricky to work a non-initalized global struct. :)
2005-05-08 12:00:28 +00:00
d10862a9da Fix for negative scaling & Mirror menu in Object mode (CTRL+M)
Hope Martin likes this simple hack. :)

Also; added flag in constraint to denote whether its local or not. That
way its possible to:

- prevent local scale and rotate on multiple objects to change own position
- draw constraint lines cleaner
2005-05-07 21:04:55 +00:00
f0a4ce98f9 Added the new Timeline Window, copied from Tuhopuu, coded by Matt Ebb.
Main change is that it's an own Space type now, not part of the Audio
window... the audio window should restrict to own options. This way
functionality is nicely separated.

Since it's the first time I added a new space (since long!) I've made an
extensive tutorial as well. You can find that here:
http://www.blender3d.org/cms/Adding_new_Space_Window.557.0.html

Notes for using timewindow;

- Add time markers with MKey
- CTRL+M gives option to name Marker
- Markers cannot be moved yet...
- Pageup-Pagedown keys moves current frame to next-prev Marker
- Xkey removes Markers

- If an object has Ipos or an Action, it draws key lines
- CTRL+Pageup-Pagedown moves current frame to next-prev Key

- Press S or E to set start/end frame for playback

Notes about the implementation in Tuhopuu:

- Add new Marker now selects new, deselects others
- Selecting Marker didn't work like elsewhere in Blender, on click it
  should deselect all, except the indicated Marker. Not when holding SHIFT
  of course
- Not exported functions are static now
- Removed unused defines (MARKER_NONE NEXT_AVAIL)
- Drawing order was confusing, doing too many matrix calls
- Removed not needed scrollbar, added new function to draw time values.
  (Has advantage the MMB scroll works not confusing on a scrollbar)
- Added proper support for 'frame mapping'
- The string button (name Marker) had a bug (checked str[64] while str
  was only 64 long)
- String button itself didn't allow "OK on enter"
- Made frame buttons in header larger, the arrows overlapped
- Removed support for negative frame values, that won't work so simple!
2005-05-05 17:19:21 +00:00