Commit Graph

589 Commits

Author SHA1 Message Date
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
2807d82e90 getVertsFromGroup was vaguely documented 2007-08-07 13:20:46 +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
c6785e3292 fixes from 2.4x 2007-08-03 16:33:08 +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
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
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
ff6c3dd0ae == Constraints Work - PyAPI ==
A few tweaks to documentation and implementation of PyAPI access for constraints following Constraints recode. Just doing a little bit of cleanup.
2007-07-17 12:03:17 +00:00
8f6c18dc17 was missing colorband from the flags in the epy docs 2007-07-15 19:31:45 +00:00
Ken Hughes
db2cc09913 Correct comments in example for Python Ipo module doc.
Remove redundant description of yafrayGIMethod in Python Render module doc.
2007-07-07 17:33:46 +00:00
cff039bc58 Ipo doc correction thanks to kempoller 2007-07-05 11:28:11 +00:00
25ec0533a9 == PyConstraints - BPy API Access ==
The BPy Access to PyConstraints. I have not implemented the setter for the PyC-ID-Properties access as I'm not too sure how this should be done.

Also fixed a few typos in the py-docs for the Limit Scale constraint.
2007-06-18 10:39:50 +00:00
3db1a55b2d added an optional window ID arg to Window.ViewLayers so you can set the layer for each viewport. 2007-06-08 15:41:31 +00:00
25baab252c yafray settings access from Py API 2007-06-06 19:12:07 +00:00
0ea4607308 scene.camera was missing from docs
bad bad mistake- key wasnt returning IPO's
2007-05-31 13:48:16 +00:00
189d8b8d28 == PY-API Docs ==
Fixed bad description for a function.

As reported here:
http://www.blender.org/forum/viewtopic.php?t=11752
2007-05-29 06:30:33 +00:00
91ea74c339 adding object.matrixParentInverse 2007-05-28 03:09:46 +00:00
f231bd0d57 Many long standing memory leaks fixed in the BPY api.
Data from Armature.c and logic.c still leaks.

Mostly todo with PyList_Append adding a refcount and the bpython api not decrefing.

Also added some features needed to fix a bug in mesh_clean.py (ob.pinShape and ob.activeShape)
2007-05-25 16:43:25 +00:00
Ken Hughes
617200a01a Python API
==========
Bugfix #6682: some Mesh.Primitive default values didn't match UI values.
2007-05-24 15:00:10 +00:00
d6cbdabfe1 Bugfix for python Image.save()
[ #6702 ] Image doesn't get saved after painting & packing
IMB_saveiff - (general saving function), does not write a file when the image is packed.
so write a file with writePackedFile for packed files.
2007-05-22 19:40:11 +00:00
Ken Hughes
5d1c012c0d 2007-05-22 17:41:32 +00:00
42121b6a3d Fixed a few typos in the documentation for Draw module of Python API. 2007-05-18 11:50:04 +00:00
66ffd1d207 more epy doc updates
added a constant dict "Blender.Object.IpoKeyTypes" to pass to ob.insertIpoKey(keytype), previously these constants were not documented well and added to Blender.Object directly
2007-05-05 06:09:03 +00:00
610fca2906 updated epydocs 2007-05-05 03:35:12 +00:00
Ken Hughes
c494a76e35 Python API
----------
Correct some typos.
2007-05-04 13:53:06 +00:00
7bd69efaec added access to SSS settings in Python
buttons_shading.c - 2 tooltips elaborated
2007-05-04 03:23:40 +00:00
d7235265fe PyAPI, Mesh.c - added renderColorLayer and renderUVLayer to the mesh
buttons_editing.c - use icons for mesh viewport layer/render layer
2007-05-02 00:49:41 +00:00
c40997656e Really minor updates related to code I wrote for the Cast modifier:
- modifier.c: moved a check out of a loop, removed an unneeded var, made a couple cosmetic changes.

- DNA_modifier_types.h: added parentheses to cast and smooth modifier defines that used bit-shifting (like 1<<1, etc.).

Note: realized they were needed when I tried to use "flag &= ~MOD_CAST_Z" in modifier.c. Since MOD_CAST_Z is #defined as 1<<3, ~MOD_CAST_Z ended up as ~1<<3 while I wanted ~(1<<3). There are other places in that header file and others in Blender where it'd be safer to add the parentheses...

- Updated the epydoc documentation for the features added by Ben Batt to the cast modifier; fixed small typo in API_intro.py.

BTW, thanks Ben Batt (artificer) for checking, improving with a couple features and committing these modifiers :).
2007-04-30 19:20:43 +00:00
125c77bca3 Patch #6113 - Cast & Smooth modifiers
This patch adds two modifiers: Cast and Smooth.

The Cast modifier deforms vertices into a sphere, cylinder or cuboid shape.
The location and orientation of the projection shape can be controlled by a
specified control object.

The Smooth modifier smooths the mesh in a similar way to the Edit mode "Smooth"
button.

Thanks to Willian Padovani Germano (ianwill) for the patch!
2007-04-29 18:13:55 +00:00
99135b0674 dont use tface hide or select anymore, since maintaining 2 sets of hide/select data for each face is annoying.
using mface->flag for both.

Also found that the cdDM_drawMappedFaces and cdDM_drawFacesTex_common could get normals mixed up when rendering hidden faces. because hidden/invisible faces used continue without advancing to the next normal.
2007-04-29 13:39:46 +00:00
1d181b9108 removed doc_browser.py - since it covers ~half the BPY api, not documenting any of blenders data types.
replaced with a help_bpy_api.py, that opens a web browser at the Blender Python API page.
Camera.c - added a veriable .angle to camera, same as .lens but adjusts the camera angle in degrees (like the D button)
export_fbx.py - use the the camera angle property.
object_cookie_cutter.py - use PointInTriangle2D rather then own function.
buttons_shading.c - added OB: and tooltip to object world mapping.
interface_draw.c - (Simple theme) text buttons looked exactly like normal buttons (more confusing when they had no text), made the text and ID buttons render inset so you can tell them apart.
2007-04-28 17:21:00 +00:00
a2000b53cd Adding Blender.Geometry function PointInTriangle2D 2007-04-27 20:48:23 +00:00
0a9dc31c8b added blender-camera export to fbx
py api was massing shiftX/Y
2007-04-27 00:33:07 +00:00
0c7e145dce Object.c - made object action writable
gen_library - fixed bug, wasnt adjusting user counts properly.
bpy_data.c - added default new names for new data
2007-04-25 00:37:19 +00:00
77f08ddc12 editface.c & buttons_logic.c & Draw.c & verse_session.c - added missing header
Bone.c - return an empty list rather then None for bone.children bone.getAllChildren()
Draw.c - per button callbacks are now have (event, value) passed
2007-04-24 17:28:40 +00:00
1ad4f024c8 had debug oprions enabled for cal3d, small updates to epydoc 2007-04-24 02:09:25 +00:00
df33b2855c New UI popup block Blender.Draw.UIBlock(func) - similar to PupBlock but less restrictive since it uses user defined buttons.
Also added per button callbacks, so each button can have its own python functions.
2007-04-22 13:48:40 +00:00
d76778f0e4 2 new python functions for the NLA.
action.getChannelNames() and action.renameChannel(from, to)

editaction.c - maximum new name length was too short
2007-04-20 23:33:56 +00:00
3fe793f2b5 [ #6442 ] image.repack (Python)
- Modified pack so it can repack too, rather the n raising an error.

editobject - Dont need to recalc data when hiding and unhiding. rather do what layers do and re-sort the scene.
2007-04-19 23:45:33 +00:00
bd142ac2f4 Anti - NMesh commit.
unweld - warn that this tool destroys MultiUV/Col's (because of NMesh)
API_intro and NMesh - note that NMesh is maintained but deprecated.
2007-04-09 07:03:26 +00:00
b1c8a1eefb == Clamp To Constraint ==
* PyApi access to this constraint
* Also, a minor tweak to one of the comments about one of this constraint's variables.
2007-04-07 04:21:12 +00:00
f42bc12285 === BPY ===
Adding Python counterparts to the Invert params for Copy Rot and Copy Loc.

I had to align the constants being used, so if you had files using those options (introduced after 2.43), you'll have to modify the INVERT settings for ROTLIKE constraints (didn't feel like making a minor version bump for this, if people thing otherwise, please say so).

Based on a patch by Juho Vepsäläinen (bebraw)
2007-04-06 19:42:46 +00:00
985fb03478 * Changed mesh so all new data is selected (fits in with blender's UI and other areas of Python API), this could break existing scripts that count on new data being unselected (unlikely)
* Added a keyword argument to mesh.transform() - "selected_only" so you can transform the selected verts. this wont break existing scripts.
* Documented these changes in epydocs.
* used these functions in BPyAddMesh
2007-04-05 07:45:11 +00:00
3aec899828 Mesh.py - Updated doc and example about faceUV/vertexColor
image_billboard.py - was broken because textures dont accept the antialias flag anymore
2007-03-31 04:20:00 +00:00
1a47d71f72 added Window.Get/SetActiveLayer() and changed how scn.objects.new() works, if scn is the active scene it uses the 3d views active layer to create the object in. 2007-03-30 08:20:37 +00:00
cfdef7a88a ICVS: ----------------------------------------------------------------------
import OBJ dosnt raise a Py Error when no image is given for a material
export FBX works much better, tested 179 models and dosnt crash on any now. tested import export with large scene, 375,000 tri's.
Mesh.py doc note about UV coords,,
editmesh_add minor typo
2007-03-29 14:35:01 +00:00
Stephen Swaney
a675bc1904 add some details for new sequence type 2007-03-29 05:08:09 +00:00
30fb777971 py api
bpy.*libBlickSeq*.new() - name is now an optiona arg.
moved some more scripts to bpy.* api.
2007-03-27 14:49:37 +00:00
66238eab7c PyAPI
curve - added curve_type() to return the curve type
BPyModule & gen_library - works with text3d now, can also make new text3d through bpy.curves.new
Added Draw.Label() so scripts can draw can using freetype.
widgetwizard - use Draw.Label
2007-03-27 11:37:54 +00:00