Commit Graph

1615 Commits

Author SHA1 Message Date
19c09fe0da -> Fix for Mesh Properties Python API
When switching Mesh properties over to METH_O from METH_VARARGS certain method definitions
didn't get switched over correctly, causing calls to mesh property functions to fail.
2007-09-11 20:58:00 +00:00
0bd32f3ac6 Changes to "Face Select" mode
* Does not indicate that UV's exist, nor does it add UV's when used.
* Only accessible for texturepaint, vertexpaint and weightpaint from a button in the header (Paint Selection Mask)
* Not accessible from the mode menu, this is only an option that applies to paint modes.

This dosnt effect DNA, face select (G_FACESELECT) can be enabled at any time but is only used when paint modes are enabled.

Other changes
* UKey is uv unwrap in editmode, Ukey for undo was editmode only anyway.
* UVCalc in editmode adds a UV Layer if there is not one alredy.
* texture draw in editmode does not draw the face dots (they are get in the way of texturing)
* some missing updates were added.
* removed manipulator from when paint modes are enabled since the manipulator is not drawn in the 3d view.
2007-09-10 19:32:44 +00:00
d00894c45c =Epydoc Fix=
epydoc changes for last commit weren't entirely clear.  Reworked a paragraph
to be a bit clearer.
2007-09-08 00:57:34 +00:00
3d58fc3660 Fix compile warning.
The function newVectorObject is declare in the vector.h.
2007-09-08 00:54:42 +00:00
8aa152df93 =Python Bugfix=
The python wrapper code for shape keys was really bad; whoever wrote it
(mis)read the wrong section of blender's codebase and got the totally wrong
idea.  The code was definitely broken to the point where either it had to be
fixed for 2.45, or else the entire keyblock wrapper would have to be removed
from the stable branch.  The fact that it didn't crash is just sheer luck;
the code assume mesh keys were MVerts, when in fact mesh keys are just
arrays of three-float vectors.

So shapekey data can now be editing directly, and is exposed as Mathutils.Vectors.
Also I updated the epydocs to explain how it all works now.
2007-09-08 00:04:32 +00:00
8a11629602 matrix to scale fixes from stable 2007-09-07 07:55:36 +00:00
5116048649 printing a pose's bone dict was limited to 4096 characters otherwise it would crash.
malloc the string instead.
2007-09-05 04:17:55 +00:00
Stephen Swaney
e20e3e94ff more warning cleanup:
unused variables
undefined variables
discarded qualifiers
2007-09-04 15:53:22 +00:00
Stephen Swaney
1b35c1c1ec fix warning: no newline at end of file 2007-09-03 17:28:50 +00:00
Ken Hughes
072c926aab Update Python API to change to curve 'extrude' limit from 5 to 100. 2007-09-03 16:56:09 +00:00
Stephen Swaney
ca087fabbe fix No newline at end of file 2007-09-03 14:23:05 +00:00
ca59cd68d3 shell script that works with epydoc 3.0 2007-09-03 00:03:29 +00:00
356ab94373 == imagebrowser ==
Initial commit of imagebrowser in trunk.
BIG COMMIT!

Main changes:
* completely reworked imasel space
* creation and storage of the preview images for materials, textures, world and lamp
* thumbnails of images and movie files when browsing in the file system
* loading previews from external .blend when linking or appending
* thumbnail caching according to the Thumbnail Managing Standard: http://jens.triq.net/thumbnail-spec/
* for now just kept imasel access mostly as old imgbrowser (CTRL+F4, CTRL+F1) a bit hidden still.
* filtering of file types (images, movies, .blend, py,...)
* preliminary managing of bookmarks ('B' button to add, XKEY while bookmark active to delete)

More detailed info which will be updated here: http://wiki.blender.org/index.php/User:Elubie/PreviewImageBrowser

Places that need special review (and probably fixes):
* BLO_blendhandle_get_previews in readblenentry
* readfile.c: do_version and refactorings of do_library_append
* UI integration

TODO and known issues still:
* Accented characters do not display correctly with international fonts
* Crash was reported when browsing in directory with movie files
* Bookmark management still needs some UI work (second scrollbar?), feedback here is welcome!

Credits:
Samir Bharadwaj (samirbharadwaj@yahoo.com) for the icon images.

Many thanks to everyone who gave feedback and helped so far!
2007-09-02 17:25:03 +00:00
32fddfbe06 my commit 11122 broke scriptlinks. was returning before re-enabling scriptlinks.
Bug [#6978] Scene script link doesn't work for Redraw event

made a script to automate building a range of revisions.
http://wiki.blender.org/index.php/User:Ideasman42#SVN_TimeWarp_Script
2007-08-31 21:54:56 +00:00
8ec207efcb fix from stable - was missing a NULL check 2007-08-31 18:21:12 +00:00
6cd6bf7d80 Updated the Makefiles removing some of the gcc specific stuff...
Basically I moved  -funsigned-char -fno-strict-aliasing
from individual Makefiles to nan_compile.mk defines for CFLAGS and CCFLAGS

Kent
2007-08-31 16:16:33 +00:00
1e3b8dc5d7 hash update from stable 2007-08-29 03:09:22 +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
7b0098bd04 getting the mesh for all curves/surfs/text raised an error every time because it was checking the wrong object was converted to a mesh. might be own fault. 2007-08-27 20:05:05 +00:00
ca843fd2f8 armature weakref evilness again, using editmode in python is not the best.
replacing PyWeakref_NewProxy with PyWeakref_NewRef fixes this problem.

list(bpy.data.armatures) # would mess up weakrefs
[arm for arm in bpy.data.armatures] # didnt.
2007-08-27 16:09:02 +00:00
e7a2a175df getting the armature twice would cause a weakref error and crash after 2-4 runs..
data = arm_ob.data
bones = arm_ob.data.bones.values()

Fixed by returning existing armatures if they exist in the weakref list. tested with FBX and BVH support.
2007-08-25 19:05:18 +00:00
567e634253 obj export had the overwrite confirmation commented out from testing, UIBlock needed to clear the events so tooltips show. 2007-08-21 19:37:03 +00:00
e8c39a5864 added face sorting to mesh so you can do mesh.faces.sort(...)
uses list sorting internally so is exactly the same as list sorting.
2007-08-20 10:08:59 +00:00
2866dde90a aparently mingw was still having problems, fixed this properly by using PyType_Ready, this needed some changes to the PyType to work. 2007-08-19 19:06:42 +00:00
Ken Hughes
b5b39e177a Undefined reference to subtarget in last PyConstraint commit:
https://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=11653

I think this commit make it do what it was intended to, but Joshua should
recheck this ASAP.
2007-08-19 00:12:34 +00:00
982d45162b == PyConstraints ==
I've added the ability for PyConstraints to define a function (doDriver) that is able to directly modify values of the owner/target, so that certain setups can be created reliably. Users should take note that this is against the basic concept of what a constraint does, and that under no circumstances may they set the values of any variables controlling the transforms. For more details, check out the information in the PyConstraint template script.

I've also updated PyConstraints to be aware of geometry targets. The script template has been updated with this information.
2007-08-18 06:17:50 +00:00
Stephen Swaney
7f3b967c30 fix warning: initialization makes integer from pointer without a cast 2007-08-17 13:53:09 +00:00
4d884c0fbf this broke on some compilers 2007-08-17 07:14:36 +00:00
5a9d5a8ce7 material leak fix from stable tree 2007-08-16 12:55:40 +00:00
61f4d6ae4d added bone comparison for the python api 2007-08-14 06:38:44 +00:00
fb985daf01 move mesh_vgroup_average to the weightpaint menu and rename. also added an option to add the active weight group or all groups.
- fix from 2.44 so makeDisplayList updates 3d text
2007-08-12 06:14:33 +00:00
9776f489e6 Mesh.c - getVertFromGroup ~25% speedup.
export_fbx.py - initial support for bones applied to weighted meshes.
2007-08-09 13:34:44 +00:00
2807d82e90 getVertsFromGroup was vaguely documented 2007-08-07 13:20:46 +00:00
Ken Hughes
6af121b407 Fix minor typo in error messages for Mathutils.DotVecs(), reported on python ML. 2007-08-06 14:27:08 +00:00
Ken Hughes
d638f54c08 Python API
----------
Fix documentation for Blender.CountPackedFiles(), incorrectly referred to
Blender.Blender_CountPackedFiles() instead.
2007-08-05 16:48:55 +00:00
c4114780d4 Little code cleanup.
bsystem_time was being called with an extra variable, which was useless. Most of the places that called it, were passing NULL for that variable anyway.

I've also cleaned up that function a bit, but the underlying problems with that part of the code still exist (EVIL GLOBALS that are exported for frame_to_float), for mblur and fields rendering features. That remains for another time.
2007-08-05 09:21:29 +00:00
c6785e3292 fixes from 2.4x 2007-08-03 16:33:08 +00:00
f707382e1e misc changes from stable 2007-08-01 18:04:44 +00:00
b38e987932 armature weakref fix from stable, Curve.c removed unneeded cruft 2007-08-01 12:57:59 +00:00
ecd42c4342 nested comment 2007-07-30 15:19:42 +00:00
655fb548aa Removing some useless code, and fixed a few compiler warnings. 2007-07-30 11:10:30 +00:00
48b07b7f15 Draw.py - typo
sceneSequence.h - bad type check, dosnt matter really since that define isnt used yet.
SurfNurb.c - was using lib hashing function and surfNurbs not a lib! (own mistake)
buttons_editing.c - Curves PathLen button was MAXFRAMEF and pathlen is a short so the button wrapped around.
2007-07-28 09:26:53 +00:00
a164d91d42 missing include and added a warning to UIBlock 2007-07-27 09:30:54 +00:00
3031f1f2bd =Draw Module Fixed=
This commit fixes the Draw module.  All buttons/widgets created via the Draw
module in a SpaceScript area are now inserted into a global list attached to
the SpaceScript data.  This list is cleared before each draw, when freeing
the space, and when the area is switched to another space.c

This is necessary to prevent Blender's internal UI code from getting invalid
pointers to python data.  In addition, it allows storing widget tooltips
inside the python Button objects, which solves that little bit of stupidity.

Note that this reverts the previous weaklist solution.  In fact, I had to go
over each previous commit by Campbell after this code originally branched
before the weaklist commit and re-add each commit.  So if anything is
missing, just tell me, or feel free to re-add it.
2007-07-27 06:14:25 +00:00
670cf8c5a9 fix from 2.44 for adding new curves. 2007-07-26 14:32:32 +00:00
534ba14d2b == PyAPI - Constraints Space Conversion Access ==
Now, for the constraints that support Constraint Space Conversion, those settings can now be set from the PyAPI too.
2007-07-26 12:15:55 +00:00
29660ac778 PyAPI Simple Bugfix:
This fixes a bug reported in IRC. getParentBoneName() was returning a string (most likely from an old bone-parent that got removed), even when the parent wasn't an Armature.
2007-07-26 06:11:58 +00:00
17533e534f removing unneeded checks 2007-07-25 04:45:20 +00:00
89792eb7ee fixed some bugs in Draw.c
* incorrect args to Draw.Create() would crash blender because it wasnt deallocating the value properly.
* deallocation of an uninitialized button could also try and free uninitialized memory if the type happened to be a STRING.
* removed the unused tooltip pointer from teh Draw.h's Button struct.
2007-07-21 23:24:08 +00:00
74ca178199 == Transformation Constraint ==
This commit adds a new constraint to Blender: the Transformation Constraint. This constraint gives you more freedom to choose how transforms are copied from one object/bone to another object/bone. 

You can assign the Loc/Rot/Scale channels of a source to the Loc/Rot/Scale channels of a destination, specifying the range of motion (per axis) from the source to consider, and the range of motion (per axis) that will be applied to the destination. Also, for each destination axis, you can choose which of the source axes to copy from. 

A similar constraint was coded by Jason Blary (snark), as Patch #4991. This constraint is basically rewritten from scratch, although there are some elements of the original patch which may be borrowed in future.

Various notes:
* PyAPI access has been coded. 
* Space conversion is also enabled for this constraint.
* Also the useless get_constraint_col function has been removed
* Doing a rotation copy with a ratio that is not 1:1 doesn't always work correctly yet (like for the Copy Rotation constraint).
2007-07-21 07:26:15 +00:00