Commit Graph

28592 Commits

Author SHA1 Message Date
M.G. Kishalmi b7d349e09c The modifications in mkktspace broke compilation on gcc 4.2.x
This is a patch proposed by sparky_ on irc.
2011-02-16 08:49:27 +00:00
Joshua Leung 437bdbc96c PoseLib Bugfixes, Cleanups, and Missing Operators
* All the various index-related issues should finally be sorted now.
It seems you cannot just partially implement some of these active
index getter/setters...
* Standardised the call used by PoseLib operators to get the Object
from which they get the active PoseLib data from
* PoseLib operators which require some existing data to work now use a
poll() which checks for this
* Added back the operator used to make standard actions into ones
usable by PoseLib
* Added a dummy operator for the apply active pose button which really
just calls the same backend functions as "Browse Interactive", but
which has a nicer frontend (naming + description) for the purpose of
being used in this way
* Also, removed some useless code from here
2011-02-16 06:18:20 +00:00
Campbell Barton 7748860aeb doc generation support for excluding some modules, without this a full rebuild takes too long to test changes.
also include own function definitions for blf_dir.c.
2011-02-16 05:18:10 +00:00
Campbell Barton 85edbd5f8d fix from mikes for building on apple with gcc 4.2.1 2011-02-16 05:03:33 +00:00
Campbell Barton 4c35d8d5a8 rename IDPropertyGroup to PropertyGroup
also renamed IDProperty to PropertyGroupItem (these are not referenced for common usage and we already have 'Property' defined).
2011-02-16 02:51:56 +00:00
Campbell Barton fee5363912 bugfix [#26094] Going to Bone Roll menu brings up python error
also correct for pep8 warnings.
2011-02-16 02:25:03 +00:00
Joshua Leung 78c135d93e Fix for compiler warning: forgot to hook up a poll callback I defined
for unlinking PoseLib data
2011-02-16 02:10:26 +00:00
Joshua Leung 7756da34c9 PoseLib UI and Bugfixes:
- Added operator button to show the current pose. This runs on top of
the interactive pose browse functionality, so the tooltip may be a bit
obtuse...
- Specifying a pose for the Pose browse functionality to set now works
correctly. Previously, some old depsgraph hacks were actually
interferring with correct updating (only the armature updated
correctly, but deforms didn't occur)
- Fixed a case of accessing freed memory, which I'm surprised no
static checkers have reportedly picked up on yet, or that nobody has
really had issues with (probably due to low memory "turnaround" so
far)
2011-02-16 02:05:41 +00:00
Campbell Barton 669cffdb1e fix [#26098] python API: quaternion.rotate never seems to work. 2011-02-16 02:05:36 +00:00
Joshua Leung f5217afd18 Ugly hack to get PoseLib UI working ok (problem mentioned in log for
r34883).

Full description:
When defining an operator button in the UI layout code, trying to set
the value for such an operator's enum properties, where said enum uses
a dynamically generated list of items (which depends on using context
info), will "fail". No context info will be passed to the callbacks
used to generate this list of items, as PROP_ENUM_NO_CONTEXT is still
set on the operator properties (it seems these will only get cleared
when the operator actually runs, which is far too late already for
this usage) so RNA_property_enum_items() will pass NULL instead of a
context pointer *even* when one exists!

I'm not sure of why we even need this flag. It seems to have caused a
few other rounds of problems already, from quick searches I did on
this matter...
2011-02-16 01:46:32 +00:00
Joshua Leung c39aba0f82 Bugfix: Browing Pose Libs should work now... RNA wrapping was missing
an "editable" flag there
2011-02-16 00:19:54 +00:00
Joshua Leung 147309e3c5 Pose Lib: Start of PoseLib UI in Armature buttons
This presents a UI from which PoseLibs can be assigned/removed from
Objects. From here, it is also possible to see the list of poses and
add/remove poses from this list.

Known Issues:
- [Py/RNA/Operators BUG ALERT!] If after immediately starting Blender
you try to remove a pose from the PoseLib using the UI buttons, you'll
get a an error the first time you do so (but not for subsequent
attempts). This seems to be caused by the "pose" enum (dynamically
generated) of the POSELIB_OT_pose_remove operator, which does not seem
to be getting initialised when the operator's exec gets called without
the invoke having been called previously
- Changing the active Pose Library still seems to be broken (to be
fixed soon)

Todos:
- Operator button to make the selected pose get shown in the 3d view
- Restore the "validate action" operator and add that to this panel
- Rename pose access
2011-02-16 00:17:22 +00:00
Michael Fox c195e68e8e small correction to BGE as recent commits broken normal mapping in the GE 2011-02-16 00:04:37 +00:00
Nathan Letwory b94be2aa14 Fix from sparky for compile problem with older GCC 2011-02-15 19:57:33 +00:00
Lukas Steiblys 610917d52e removed some more magic constants
another fix: the patch for #25806 was submitted by Riakiotakis Antonis and not by Andrew Wall
2011-02-15 19:22:08 +00:00
Sergey Sharybin e9ff1b98cb - Do not use old anchor toggling operator. It used to set brush flags to
unawaliable state.
- Also changed dynamic space bar menu, so it now also wouldn't allow to
  set brush stroke flags to unavaliable state.

Also tried to remove use_anchor, use_space, use_restore_mesh and
use_airbrush, so user would be unable to set flags to unavaliable state,
but it was quite difficult for non-sculpt paint modes. They don't support
all of stroke methods, so brush.stroke_method can't be used for them.

Keep this area unchanged for now.
2011-02-15 19:19:36 +00:00
Campbell Barton c461a7ea4d patch from IRIE Shinsuke, use systems openjpeg on *nix. 2011-02-15 19:04:51 +00:00
Lukas Steiblys 7fba9eab47 added more code comments and removed some magic constants 2011-02-15 19:04:00 +00:00
Lukas Steiblys 15570631fd a fix for bug #25806
http://projects.blender.org/tracker/index.php?func=detail&aid=25806
Thanks Andrew Wall for the report and the patch
2011-02-15 18:36:42 +00:00
Campbell Barton 52c08fa4d3 CPack packaging support from Dan Eicher, tested to build redhat RPM's, a Mac bundle also defined. 2011-02-15 18:33:05 +00:00
Campbell Barton 8845163574 menu to select an enum from an RNA path:
eg,
   bpy.ops.wm.context_menu_enum(data_path="scene.tool_settings.vertex_paint.brush.stroke_method")

This saves us defining operators only for menus.
2011-02-15 18:12:41 +00:00
Sergey Sharybin 35c03e85ef - Use the same logic as for BEZIERs when making segment of between
first and last NURBS' control points (toggle cyclic flag)
- Show U/V selection menu only for surface objects. There's no
  much logic in asking U/V direction for simple curves.
- Set active spline when two segments were joined.
2011-02-15 16:37:44 +00:00
Sergey Sharybin c4ad7b4ebe Fix #26087: in a curve, can't make segment if Fkey was pressed 2 times before on a single vertex
- Disallow setting cyclic flag for single-point segment when this lonely
  segment is selected
- Clear cyclic flag for single-pointed segments when finding segments which
  can be merged
2011-02-15 16:09:53 +00:00
Campbell Barton cb12d708c7 Doc generator now makes 'bpy.context' api reference.
http://www.blender.org/documentation/250PythonDoc/bpy.context.html

strings are extracted from blender to ensure all values are included, currently there is no type info so this is stored in the doc generator.
2011-02-15 15:37:40 +00:00
Janne Karhu 78bb53a1bf Fix for [#26083] Animated Particle Textures have no effect
* Duplicating particle settings didn't duplicate texture slots.
2011-02-15 15:03:49 +00:00
Campbell Barton 86cf6b4016 moving dir strings into global namespace for doc access (coming up) 2011-02-15 14:38:43 +00:00
Campbell Barton efb21625bf ...and for blenderplayer 2011-02-15 12:43:34 +00:00
Campbell Barton f94256ea5c fix for building with make on linux from recent new lib. 2011-02-15 12:37:15 +00:00
Joshua Leung e63b51a9ab PoseLib: Adding support for custom properties
Custom properties are now supported by Pose Library. They will get
saved and restored correctly during previewing and pose adding.

To do this, I've changed PoseLib over from using the "LocRotScale"
Builtin Keying Set to the "Whole Character" one instead. One
consequence of this, is that now entire poses are stored in the Pose
Lib, irrespective of whether you only selected part of a pose to store
(i.e. facial controls only, or hand poses only). If this is enough of
a problem, I'll make a second Keying Set that does take selections
into account, and use that here instead.
2011-02-15 11:47:09 +00:00
Campbell Barton d5316768c3 corrention for bpy.props docstrings. 2011-02-15 11:43:35 +00:00
Nathan Letwory 3ce233e28d Move mikktspace code to own library, so it is clear that it is also
intended as a standalone library for use in other applications that
want the same tangent space as Blender.

This also keeps blenkernel clean(er) from extra math functions.
2011-02-15 09:24:35 +00:00
Campbell Barton be8c8942f4 fix for own error with image info display, also dont draw if the mouse is outside the image. 2011-02-15 04:06:13 +00:00
Campbell Barton 07e9cfef81 fix warnings. 2011-02-15 03:20:12 +00:00
Joshua Leung b47bfd85e8 UI Tweaks: Text field in Rename Markers popup now gets focus when the
popup appears, saving an extra click

I've separated out the "XXX"-'d event-adding-hack section from the
search-menu code into a separate API function (as recommended there).
This call is used to make sure that textboxes in popups can get
activated by default, to allow typing immediately.
2011-02-15 01:24:12 +00:00
Joshua Leung dab76a3ccf Ctrl-0 can now be used to just reset a single component of an array to
its default value instead of resetting the entire array
2011-02-15 00:53:20 +00:00
Nathan Letwory d4ebace149 Tweak priority so link error on Linux is solved. Reported by Hypercrush on IRC. 2011-02-14 21:00:49 +00:00
Campbell Barton ba0d167d2a more vars made static 2011-02-14 18:20:10 +00:00
M.G. Kishalmi 20553d4064 This commit will switch blender to use tangent space generated within
the two files mikktspace.h and mikktspace.c. These are standalone files
which can be redistributed into any other application and regenerate the
same tangent spaces. The implementation is independent of the ordering
of faces and the vertex ordering of faces.
2011-02-14 18:18:46 +00:00
Campbell Barton 8b7482892b made most variables which are only used in a single file and not defined in header static for blenlib, blenkernel and editors. 2011-02-14 17:55:27 +00:00
Sergey Sharybin d7e2607f96 Fix #26082: Fkey in a curve witch was empty before
Stupid error in own previous commit to addvert_Nurb -- empty spline
had been added to spline list.
2011-02-14 17:17:05 +00:00
Ton Roosendaal c66ce21a86 Bug fix #26021
Very nasty UI code issue: since every button is re-defined on a
redraw, having UI redraws while using a button was not possible.

This was solved long ago by copying over data from previous button.

However, this fails when buttons have callbacks with its own (or
a parent button) pointer. 

This bug reporter found crashes in draw-overlap UI mode, this 
draws entire UI over for every menu redraws, making previous button
pointers invalid. (for triple buffer, the UI is not redrawn, only
the menus).

In general: all systems falling back to old swapbuffers would have
suffered some instability because of this.

Fix is that now the old button gets lifted out from the previous
list and inserted in the new list. Works fine, but needs some tests!

Also in this commit: TIFF endian switching not needed for 16 bits tiff.
2011-02-14 17:09:02 +00:00
Sergey Sharybin 8ee0c96f4b Previous commit to small optimization of sculpting broke smooth and layer
brushes. They aren't using proxies, so deformation wouldn't be propagated
in sculpt_combine_proxies().

So, maye idea of getting rid of "extra" memory allocaiton/disposing was not
such cool due to it lead to such exception ways?
2011-02-14 16:54:52 +00:00
Sergey Sharybin 2b9c9e3ad9 First modifiers with deformMatrices callback used to be applied twice when
building crazytspace. Not sure why this worked.
2011-02-14 16:06:15 +00:00
Campbell Barton d845d6308a comments for how py-rna calls api new classes. small speedup for StructRNA.__new__(...) used for creating new classes and corrected exception type. 2011-02-14 11:30:35 +00:00
Campbell Barton a3c2ad34b1 improve py/rna exception messages. 2011-02-14 08:14:52 +00:00
Campbell Barton a6765280f9 py rna api: turn class.is_register into a class property rather then a class method.
eg:

if MySybclass.is_registered:
    ...
2011-02-14 07:26:07 +00:00
Campbell Barton 44be05f7f9 convenience targets for makefile
clean, test, package_debian, package_pacman
2011-02-14 06:15:23 +00:00
Sergey Sharybin 665a0ff789 Revert incorrect fix for 26062 made in svn rev34828. 2011-02-14 06:04:40 +00:00
Guillermo S. Romero 7b201c7693 SVN maintenance. 2011-02-14 04:47:55 +00:00
Campbell Barton 72bc3f22b7 python api renaming and added headers for some files which didnt have one, no functionality change. 2011-02-14 04:15:25 +00:00