Commit Graph

21636 Commits

Author SHA1 Message Date
a6a2512f47 Pointcache code cleanup and disk cache compression options:
* Massive reorganization of pointcache code, things are now cleaner than ever.
* For all but smoke the cache is first written to memory when using disk cache and after that written to disk in one operation. This allows less disk operations and the possibility to compress the data before writing it to disk.
* Previously only smoke cache could be compressed, now the same options exist for other physics types too (when using disk cache). For now the default compression option is still "no compression", but if there aren't any problems this can be set to "light compression" as it's actually faster than no compression in most cases since there's less data to write to the disk. Based on quick tests heavy compression can reduce the file size down to 1/3rd of the original size, but is really slow compared to other options, so it should be used only if file size is critical!
* The pointcache code wasn't really 64bit compatible (for disk cache) until now, so this update should fix some crashes on 64bit builds too. Now all integer data that's saved to disk uses 32 bit unsigned integers, so simulations done on 64bit should load fine on 32bit machines and vice versa. (Important disk cache simulations made on 64bit builds should be converted to memory cache in a revision before this commit).
* There are also the beginnings of extradata handling code in pointcache in anticipation of adding the dynamic springs for particle fluids (the springs need to be stored as extradata into point cache).
* Particles were being read from the cache with a slightly wrong framerate. In most cases this probably wasn't noticeable, but none the less the code is now correct in every way.
* Small other fixes here and there & some cosmetic changes to cache panel, but over all there should be no functional changes other than the new disk cache compression options.
* This whole re-organization also seems to fix bug #25436 and hopefully shouldn't introduce any new ones!
2011-01-02 06:52:47 +00:00
d5820f0dd0 bugreport & fix [#25441] Copy Transforms Constraint head/tail fixin'
from Dan Eicher (dna)
2011-01-02 04:16:19 +00:00
9f88e0faeb Fix for [#25427] cloth or soft body crash un Undo
* Argh my bad, sorry about this!
* Now only the actual data array is saved to avoid constant re-allocations, but no relations to active data are kept.
* Also reverted Ton's quick fix for the crash as it's not needed anymore.
2011-01-02 03:55:26 +00:00
03d046ad4f report & fix [#25447] SceneObjects null pointer dereference crash
from Dan Eicher (dna)

noticed sequence swap also wasn't checking for None.
2011-01-02 02:48:45 +00:00
129b6190ed geometry module
- rename functions from camel case.
- added docs for undocumented methods.
- minor functional changes with exceptions and accepting 3d/4d vectors where it makes no difference.

Renamed:
 - geometry.Intersect -> intersect_ray_tri
 - geometry.ClosestPointOnLine -> intersect_point_line
 - geometry.PointInTriangle2D -> intersect_point_tri_2d
 - geometry.PointInQuad2D -> intersect_point_quad_2d
 - geometry.LineIntersect -> intersect_line_line
 - geometry.LineIntersect2D -> intersect_line_line_2d
 - geometry.BezierInterp -> interpolate_bezier
 - geometry.TriangleArea -> area_tri
 - geometry.QuadNormal, TriangleNormal -> normal
 - geometry.PolyFill -> tesselate_polygon
 - geometry.BoxPack2D -> box_pack_2d
 - geometry.BarycentricTransform -> barycentric_transform
2011-01-02 02:11:38 +00:00
373524815a Bugfix #25445
CTRL+R loopcut now shows header print with instructions.
User report was that Blender was freezing :)
2011-01-01 17:52:06 +00:00
21eb65c450 For non-gnu compilers, the __func__ doesn't exist.
Fix for commit of 2 hours ago.
2011-01-01 15:49:25 +00:00
fd7152b839 Bugfix, IRC report
Floor constraint didn't work: the defines for the enums were using
the wrong ones, the right ones are not logical... but code and dna
and old files assume these. Now it works :)
2011-01-01 15:28:21 +00:00
d7c51aa3eb Bugfix #25437
Crash in Bezier animation (inserting keys on control points in
curve object). The animation rna paths were not fixed after an
editmode session, which got fixed 2 weeks ago, but for all older
binaries the issue can still pop up.

The crash happened because the RNA array-itterator was not doing
a boundary check, even whilst the array size was passed on to the
itterator callbacks. With rna then writing far outside of valid
memory, very bad and unpredictable corruptions happen.

I've added a range check now, and a decent print to denote the
issue. An assert quit is useless, since a tab-tab on curve objects
will fix the channels nicely.

Example of warning print:
Array itterator out of range: Spline_bezier_points_lookup_int (index 30 range 2)
2011-01-01 13:49:22 +00:00
c169ccc711 Silence more compiler warnings. 2010-12-31 20:01:38 +00:00
803e9a2908 Bugfix #25427
Serious *bad* crash in undo introduced by commit Janne dec 21st.

Time window now stores some kind of cache for fluids/cloth, but
it's pointing (in SpaceTime) to data inside Objects. (Not ID).

That's really not allowed... this commit fixes crashes but the
cache code really needs to be redesigned. I'm also afraid this
crash is going to frustrate everyone using physics...
2010-12-31 12:37:30 +00:00
683694b520 Fix crash on load with a particular startup.blend, don't know how to redo
creating it, but this should be set to NULL on read.
2010-12-31 11:55:11 +00:00
c68e3913ed fix [#25429] Armature modifier and inverted vertex group
- the invert flag was only being used for multi-modifier, but there is no reason not to use this in normal cases as well.
- Armature modifier RNA name 'vertex_group' was incorrectly named 'vertex_group_multi_modifier' (own fault), confusion was caused by 'invert_vertex_group_multi_modifier' which was correct.
2010-12-31 11:51:00 +00:00
23e5b79ced armature recalc roll now works properly with mirror enabled. 2010-12-31 10:42:31 +00:00
ce863a9fdc alternative fix [#25178] Switch Direction operator for bones doesn't update mirrored bones when X-Axis Mirror is enabled
- only temporarily adjust the selection, then de-select.
- fix applies to bone merge too.
2010-12-31 10:24:40 +00:00
e9ade5adae revert a small change from Ton's commit from r33637.
Having edit operations select the mirrored bones means you cant so easily continue editing on one side of the armature.
This is also inconsistent with other mirror editing operations in armature and mesh modes which don't adjust selection like this.
2010-12-31 06:24:52 +00:00
cdefce51f5 update python api with changes from Joshua's commit r33917. translate reports into python errors. 2010-12-31 05:40:30 +00:00
ae51e1c683 reverting part of Ton's commit r33911.
The bug was 'write_still' was incorrectly being initialized to 'view_context'.

'write_still' should always write an image, so failing silently here is bad behavior.
Also, opengl render and internal render engine operator should use this option the same way.
2010-12-31 04:48:56 +00:00
6fdfa97edb CMake: use blender_include_dirs("${OPENGL_INCLUDE_DIR}") rather then blender_include_dirs(${OPENGL_INCLUDE_DIR})
Apparently this is needed for MSVC in some cases, reported by Tamito Kajiyama r33895.
2010-12-31 04:29:11 +00:00
5593436652 Continue from my commit r33952, which disallowed floats to be wrapped as ints.
this missed some cases, now also disallow ints to be wrapped as floats.

This commit also exposed a number of cases where ints/floats were incorrectly wrapped.
Bugs like [#25416] wont slip through the cracks anymore.
2010-12-31 04:12:20 +00:00
a840643993 Bugfix [#25414] Entering a newline before a : still indents it
Fixed by patch attached by submitter. Cheers Jacob F (racoon)!
<quote>
If you write something like...

def do_something:

...and press return it makes the new line with a tab which is good,
but if you want to move the def line down to make room above it by
pressing return while your caret is at the start of the line it
indents the new line which has the def statement on it.

Attached patch just checks if it's checking for a colon after the
caret and returns if it is.
</quote>
2010-12-31 04:09:15 +00:00
dfffad69a9 Bugfix [#25420] Sequencer View Zoom operator hidden
"Numpad 1" shortcut to set preview view zoom to 1:1 (i.e. 100%) did
not exist in View menu. While investigating this, I found that the
operator was missing a description/tooltip, so added one too.
2010-12-31 03:54:28 +00:00
d4ea9eb9e7 Bugfix [#25415] Circle Selection does not work on bones in Pose mode
Clobbered together some new code to do this based on the code for Edit
Bone circle select as this case doesn't seem to have been implemented
yet.

NOTE: the code in view3d_select.c needs some urgent love and tidying
up (like a room full of flaking paint).
2010-12-31 03:35:34 +00:00
7703633762 Bugfix for [#25416] Precision in glare node doesn't match display. 2010-12-30 21:46:09 +00:00
f3e623f497 Bugfix #25407
Lamp shadows for offscreen render (opengl anim) had to be remade
to cope with animated objects. Fix proved by Alexander Kuznetsov
in the tracker log. Thanks!
2010-12-30 14:47:40 +00:00
f09d7912f8 Porting URL fixes for Release Logs from Tag to Trunk. 2010-12-30 13:02:48 +00:00
46feccfaea Fix for bug #25367 didn't ensure the problem wasn't happening elsewhere.
add a check in makesrna, found FollowPathConstraint.offset was a float wrapped as an int.
2010-12-30 12:50:44 +00:00
9733e5f76f revert part of Tons commit r33884.
- rather then use unlink="None", just don't pass unlink as a keyword. This is more pythonic.
- added an RNA flag for properties which cant be unlinked by setting to None.
2010-12-30 12:22:28 +00:00
9fa2f9ffb6 Doh! 2010-12-30 05:47:34 +00:00
b67692a130 Various pedantic fixes to satisfy compilers. 2010-12-30 05:41:17 +00:00
4819c9bdfa Part one of 2.56-beta release commit
(Splash picked by Durian team to honour team Argentina!)
2010-12-29 19:05:00 +00:00
7f3c7eee67 Bugfix #25404
Frame Mapping (map old, map new) didn't set the the framelen
variable. Note that this feature is half-working, and on the
to. Might be removed/replaced with something better.
2010-12-29 18:21:57 +00:00
d36f15df03 DopeSheet Drawing Tweak:
Keyframes for locked channels are now shown faintly so that it is
possible to easily distinguish between keyframes for locked channels
and unlocked channels. Hopefully this solves the problem where you
have some keyframes selected, and try to move them but forget that
those channels are locked (without any feedback other than a single
icon).

Thanks for pointing out this problem Ronan Zeegers!
2010-12-29 12:52:06 +00:00
f22a3c16b1 Silencing some compiler warnings (gcc) 2010-12-29 12:27:03 +00:00
32b23b2b82 Bugfix [#24163] (PART 2) Unable to animate INSIDE a group node in the
compositor

Now ungrouping grouped-nodes copies the animation back to the main
nodetree. This means that it is now possible to successfully roundtrip
group/un-group nodes and their animation data.

---

This should also be done for the Separate Armature operator... hmm...
2010-12-29 12:18:59 +00:00
92172b779e Bugfix [#24163] Unable to animate INSIDE a group node in the
compositor

This commit fixes the original bug reported here by adding some
methods to move the relevant F-Curves (and drivers) over to the new
Node-Tree's (i.e. group-node) AnimData. Animated nodes which
subsequently get grouped will still be able to animate as a result of
this commit.

TODO's:
- Ungrouping now will not yet merge the animation back (or at least
copy it)
- Buttons for nodes freshly grouped do not correctly show animated
status indicators for some reason, yet normal animation does
2010-12-29 11:51:53 +00:00
c802e21dbb Bugfix #25397
Loading a vector font (.ttf) didn't have option for Relative Path
in the file window. Now it does, and it sets it to the default.

Todo note: the actual path is not visible in the UI yet, nor does
outliner RNA view allow to edit path.
2010-12-29 11:34:02 +00:00
7115a8d200 Consistency cleanups for AnimData stuff:
Some AnimData looping functions were not updated to take into account
the addition of AnimData for some additional datatypes (i.e. meshes
and lattices) as well as the changes to make nested nodetrees (i.e.
for Material and Texture nodes).
2010-12-29 05:20:19 +00:00
8c4a93110e Bugfix #21825
Auto-IK: applying back the IK transform on bones fails for constrainted 
bones themselves. This would require the post-transform of IK to be
converted to a pre-transform for the constraint. That's too much of
a headache for bugfixing days.

To keep the autoIK feature work it now stops IK chains at constrainted
bones. Added todo item for a matrix wizzard to fix this one day.

(What would be really cool is a matrix-api for armature to easily 
get all the required pre- and post transforms and apply. There's a lot
of duplicate exception handling for hinge bones for example.)
2010-12-28 17:03:09 +00:00
98ec317d2b Bugfix #25395
Mesh "Add grid" was quite broken:
- it added an edge to a previous (not selected) vertex
- it ignored cursor location
- and it didn't use 'align to view'

Now it does behave :)
2010-12-28 16:02:47 +00:00
875a7288ca Bugfix, irc report.
UI name buttons with Search callback show red when item couldn't be
found. The check was too simple though, since the searches also find
partial matches. This caused KeyingSet browse to show red for "RotScale".

Now 10 matches are stored, and each match is being checked. Still a
bit weak for cases with more than 10 matches, but in that case it
won't show red-alert.
2010-12-28 11:56:18 +00:00
7484d5b743 - Typo fixes
- Visual Location Keying Set was still using the old-style flag
defines
2010-12-28 11:50:10 +00:00
d0074169fb Bugfix: creating new 3d views in Blender now uses same defaults
as startup blend: showing solid + outline selection.

(It was wire, without outline select... confused people)
2010-12-28 11:01:26 +00:00
3c96b00500 Bugreport, IRC
Compositor: "Read & Compo Full Sample Buffers" option stopped after
1 pass; the break callback was returning '1' falsely.

Also made it show "wait cursor" again, since it doesn't run in 
thread nor updates UI while compositing buffers. Check console for
progress for now.
2010-12-28 10:39:27 +00:00
d44436ebf2 Assorted commenting, formatting, and compiler warning fixes for
keyframe pasting code
2010-12-28 06:24:01 +00:00
26104c7611 - Silencing some gcc warnings (yay! I can finally use this setup
again)
- Graph Editor "Active Keyframe" panel now displays more descriptive
error messages. In particular, hopefully this helps to alert users of
the default generator modifier for Driver F-Curves
- The first F-Modifier added to a list is now set to be active one for
that list.
2010-12-28 06:18:56 +00:00
71da1e96d1 Drivers Code Cleanups and UI Tweaks:
- Adding drivers from the UI (not from py-scripts though) will now
automatically add a "Transform Channel" driver variable to the newly
created drivers. This makes setting up drivers a bit more convenient
for the most commonly used case.

- Drivers now report their errors using the Reports system instead of
writing these directly to the console.

- Clarified some comments to be more insightful about the "why's" of
some design decisions, and related formatting/cleanup tweaks
- Reduced scope of "path" vars to just the scope they're required in

- Removed some unused defines from a failed experiment in the original
Keying Sets code ("templates" and "template flags") which was
superseeded by the more flexible + nicer "Builtin KeyingSets"
2010-12-28 05:45:15 +00:00
b2be78c0cc Bugfix #25392
Compositor: Texture node didn't use texture-nodes itself.
Now composites initialize texture nodes correctly.

Also reviewed the fix for crashing texture nodes for displace.
It appears texture nodes also are used for sculpt/paint 
brushes, in these cases it can be allowed again. But, don't
do this during rendering for now!
2010-12-27 19:26:38 +00:00
1a8cc0a8f0 Small fixes:
- OpenGL still render failed when output format was set to Movie.
  Now it just doesn't save a file and renders anyway.
- Bone heat weight was missing 'wait cursor'.
- Waitcursor for Mac Cocoa is back! Made all OS's use the same
  nice hourglass cursor.

(Note: this violates Mac UI guidelines, we should rely on the 
spinning wheel of death instead. Highly disputable that.)
2010-12-27 18:54:43 +00:00
b1b22e928d Usability fix:
OpenGL render now first opens render window.
It used to render first, save file, and then open window to show result.
2010-12-27 18:00:35 +00:00