Commit Graph

779 Commits

Author SHA1 Message Date
Willian Padovani Germano
1f4af00c94 Scripts:
- Making the ac3d importer discard bad faces in the imported model (faces that reference a vertex index more than once). Thanks Melchior Franz for reporting this one, too.
2007-02-01 01:34:51 +00:00
Campbell Barton
ed24fe31d1 fixed a python error in the exporter, small changes for the importer. 2007-01-31 11:34:41 +00:00
Campbell Barton
9cf602b949 3ds_export - enabled textures as an option since it works with some appliactions (only way to get textured models from blender to google sketchup)
3ds_import - added option to disable recursive image searching (could be slow somtimes)
export_obj - when making group/object names only use both object and mesh name when they differ.
weightpaint_clean, weightpaint_grow_shrink - minor updates.
Render.py - own error in epydocs.
2007-01-31 01:18:51 +00:00
Willian Padovani Germano
2d14f8c224 Scripts:
- Fixing another bug in the ac3d import script, thanks again Melchior Franz for testing and reporting.
2007-01-30 20:12:30 +00:00
Campbell Barton
dcc834f3fa updated render settings to support recent changes.
options like saveBuffers are available from Python and threads can be set from 1 to 8
usefull for python based renderfarms.
2007-01-30 03:02:58 +00:00
Campbell Barton
45d486f0f3 Update to JMS's latest version of google earth 3 importer.
also made some changes
* redraw in the 3d view only
* create all objects in visible layers
* other small tweaks and speedups, removed debug print's
2007-01-30 00:16:05 +00:00
Campbell Barton
5db31cb571 removing redundant scripts because of new features in blender after discussion with LetterRip.
disp_paint.py - Displacement modifier and sculpt mode replace.
uv_paint.py - making can be used to write colors to an image.
animation_empties2armature.py - Was made when BVH importer could not import direct to armature, Resulting animation has visible errors, errors have been known about for a long time and not fixed.
knife.py - Old slow code, No Multi-UV's, We now have a knife tool that has snap!

If anyone wants to maintain these scripts and have them added back in, mail the bf-python ML.

Scripts that are removed can be found here.
http://projects.blender.org/viewcvs/viewcvs.cgi/blender/release/scripts/Attic/?cvsroot=bf-blender
2007-01-29 10:20:21 +00:00
Campbell Barton
803d66a3a5 removed copy_facedata_multilayer from BPyMesh since it changes the selection and flips the faces (needed for solidify) but not for general purpose use. 2007-01-29 06:56:30 +00:00
Campbell Barton
996294e18a fixed own bug indroduced when switching to use f.edge_keys
MultiUV/Color support - all layers are copied to new faces. as well as hole filling faces.
2007-01-29 06:38:30 +00:00
Robert Holcomb
2133d87d21 Fixed accelerated openGL command list tri-strip generation for geometry. UV coordinates are still off a bit. Fixed bad frame list loading. I'm sleepy and need a snack. 2007-01-29 00:11:18 +00:00
Willian Padovani Germano
cd2e2d231f Scripts:
- Fixed a few bugs in the ac3d importer, found by Melchior Franz (thanks!). Also automatically turning on ztransp for materials with alpha < 1.0 and then also transp shadows for all imported materials.
2007-01-28 20:03:42 +00:00
Campbell Barton
5943ad8f65 update to the md2 importer.
* moved from NMesh to Mesh
* made newstyle classes (use less memory)
* optimized mesh creation
* Animation now imports and plays (Bugfix for 5834)
+ other small tweaks

Added mesh.key - was missing from docs
2007-01-28 12:33:04 +00:00
Campbell Barton
321cafa714 updated this script (one of the most out of date)
basic workings are the same but its generaly more efficient.

The main problem was it could get the data from every object across all scenes!
This means that on framechange, every mesh would be copied into an NMesh just to see the type was a camera.
2007-01-28 03:36:33 +00:00
Campbell Barton
7f5908f95a bug 5857, python 2.3 compat fix + minor changes. 2007-01-28 01:36:21 +00:00
Campbell Barton
8f075f9518 minor tweaks from testing scripts. correction in my last commit. 2007-01-27 04:58:09 +00:00
Campbell Barton
853785782e Updated docs not to use Object.New() in examples, use scn.objects.*
Bugfix from ZanQdo, MOT files wouldent load in lightwave. also made some minor improvements.
2007-01-27 02:15:14 +00:00
Campbell Barton
bc6fc72209 * nmesh to mesh
* fixed errors with Null materials
* faster material exporting
* export with modifiers applied
* faces with invalid material indicies work now (maybe should be delt with in the Py API)
* removed per vert col code since all colors are pre face now.
2007-01-26 10:37:18 +00:00
Campbell Barton
624030165b fixed some errors, small usability enhancements. 2007-01-26 07:32:29 +00:00
Campbell Barton
7239784b17 added option "morph target" since many people complain that verts are re-ordered with some options enabled. 2007-01-26 07:01:30 +00:00
Campbell Barton
0decfd140b fixed an obscure bug in obj import (possibly in Mesh.c) that made adding edges as faces mess up.
export obj now dosnt remove double UV's, its too slow.

updated version numbers to 243 and other minor changes.
2007-01-26 06:02:21 +00:00
Campbell Barton
2a829b87e2 use better Python 2.4 syntax sorting (in a try so py 2.3 still works)
use new scene/object creation for making temp objects.
2007-01-25 04:18:09 +00:00
Kent Mein
d553eeef5d More fixes thanks to paprmh.
Kent
2007-01-24 17:55:53 +00:00
Matt Ebb
5dd1a39288 == Interface ==
Added new icons by 'jendrzych' for sculpt mode and transform snapping. I'll be
doing a lot more on this in the next release cycle, but I'm bringing these icons
over now since they're new features and we don't really have any icons for them
at the present.
2007-01-22 22:26:03 +00:00
Kent Mein
6cbd505089 I put stuff into the code that shouldn't have been there. Reverts this small statement so
its correct again.

Thanks paprmh....

Kent
2007-01-22 19:47:12 +00:00
Kent Mein
c778c7f286 Paprmh's fix for the blur plugin.
Kent
2007-01-22 17:43:36 +00:00
Campbell Barton
29813971b1 applied patch 5779 with some modifications to fix own error, (uv indicies could be out of order)
removed image support, Blender could import but not 3dsmax :/ - even managed to get 3dsdump to report a blender and max file to have the same data but max still dosnt like.
2007-01-22 17:31:34 +00:00
Campbell Barton
32676b66a4 fixed error on hole filling (http://blender.org/forum/viewtopic.php?p=59062#59062) 2007-01-22 09:48:03 +00:00
Campbell Barton
e64afa6c17 Update by JMS for the hotkey script.
Also made some changes
- fly mode keys have changed and added snap key
- using "i=list.index(val)" is slow, use "for i,val in enumerate(list)" instead.
- dont use "i in range(start, end)" - silly to make a list when you can do "min < val < max"

JMS, please update from this version.
2007-01-21 23:14:57 +00:00
Kent Mein
783a2900a6 This is taking me longer than I wanted.
All of these I think still need work but they at least do not coredump.
Basically they need some troubleshooting.

I'm heading home now so will work on it again tomorrow hopefully.
If anyone is bored feel free to take a look at them and see if you can
find the problems.  (dnr.c also needs to be converted to float aware)

Kent
2007-01-19 21:06:35 +00:00
Kent Mein
c46873819d removed since it no longer works and with render layers not really needed.
Kent
2007-01-18 16:44:50 +00:00
Tom Musgrove
898fccf463 = line ending fix =
these files all had non unix line endings...
2007-01-18 08:39:31 +00:00
Campbell Barton
848e93ce41 error in generating projections fixed.
also modified the margin value so you dont need to have values like 0.001
and added an option not to use face areas to weight projections.
2007-01-18 01:10:48 +00:00
Kent Mein
fc633e46c5 in seqeffects.c I removed and extra ; and then did a lot of formatting
fixes.

gamma.c made it return B_PLUGIN_VERSION instead of a hard coded 4.
I haven't had time to look at the other plugins but I'm guessing
the deal was B_PLUGIN_VERSION was still 3 and gamma.c was float aware
so it was bummped to 4.  Now that B_PLUGIN_VERSION is 5 I'm guessing
the other plugins need to be updated so they are at level 5 as well.
(float aware)  I'm going to work on it later today.  At home with a
sick kid.  This is all in reference to bug #5692

Kent
2007-01-17 14:10:02 +00:00
Kent Mein
ea7e3f05ea fixed stupid little warning about targets differ in signedness.
(unsigned char verses char)

Kent
2007-01-16 21:34:39 +00:00
Campbell Barton
6d0089237e dont use python keywords as variable names. 2007-01-16 15:19:04 +00:00
Campbell Barton
05ecd017ca cleaned up uv island projection generation and added an option 'Init from view' - to use the view vector as one of the first projections 2007-01-16 14:33:32 +00:00
Campbell Barton
dc00d9c5de set the render aspect correctly when rendering non square images. 2007-01-16 06:39:15 +00:00
Campbell Barton
dced690915 wasnt working for mixed modes 2007-01-16 02:49:58 +00:00
Willian Padovani Germano
feb63d7d3b Scripts:
More small updates to the ac3d importer, to calculate normals for the created meshes and to avoid problems with older .ac files.
2007-01-16 00:50:31 +00:00
Campbell Barton
72de9a64c9 was missing a check for the end edge that made skinning it raise an error. 2007-01-15 23:37:34 +00:00
Campbell Barton
a77178467b when a vert is shared by more then 1 vertloop give a nice error and exit 2007-01-15 07:59:29 +00:00
Joseph Eagar
7a19fe19f6 =ID Property Script update and api bugfix=
Turned out somehow I managed to miss adding the proper
type refs in Blender.Types for IDGroupType and IDArrayType,
which made the script not work.  So, I've got it all fixed now.
Or at least hopefully :)
2007-01-15 07:54:08 +00:00
Willian Padovani Germano
82bfd281f2 Scripts:
Misc updates to the ac3d importer and exporter:
- use Mesh instead of NMesh;
- properly export modified data and materials from either ob or obdata (thanks for mesh.getFromObject :) );
- option to export local rot and loc info;
- better import / export of hierarchies;
- + tiny updates here and there to support old or weird .ac files.
2007-01-14 18:13:47 +00:00
Brecht Van Lommel
878d9f9c68 Fix for bug #5680:
Vertex color node worked only if VCol Paint/Light was enabled. Fixed
that, and removed the vertex color node making it part of the geometry
node instead.

Also, preview.blend had black vertex colors for the sphere, so set them
to white like the other primitives.
2007-01-14 15:19:27 +00:00
Campbell Barton
c6a57fb4b0 import_obj - name imported objects/mesh data
weightpaint_clean - report how many verts removed from groups
save_theme - no need to do type(''), just use type(vat) == str
2007-01-13 03:07:04 +00:00
Campbell Barton
0b89910800 disp_paint - was raising an error when the mesh had no image and texuv was selected, or when the image had no data.
discombobulator - updated to use newer API functions
object_random_loc_sz_rot - improved layout and use new Scene objects.context
2007-01-13 02:03:38 +00:00
Tom Musgrove
74291cc503 = removed nendo import/export and tex2uvbaker =
tex2uvbaker is now redundant with buitin functionality so thank you for maintaining this script in the past.  nendo is a marginal format and the scripts are not maintained so removing
2007-01-12 09:08:00 +00:00
Campbell Barton
54863a2fef error, camera scale couldnt be set. bpyrender now sets ortho properly 2007-01-12 00:31:18 +00:00
Campbell Barton
3c578fbe12 tested export scripts with a large scene and resolved errors that came up as well as some speedups- mostly problems with lightwave_export 2007-01-11 09:39:16 +00:00
Campbell Barton
34c11de62a improved this script
* use mesh.transform instead of a python matrix multiplication function.
* use the image filename rather then ID name for the URL
* use the scenes world rather then the first world for getting world data.
* mesh.verts.index(face.vert[i]) is extreamly slow!, use face.vert[i].index instead. also got rid of a face loop in a face loop that didnt do anything.

Still need to move this script to Mesh from NMesh
2007-01-11 06:48:25 +00:00
Campbell Barton
99857e40e3 some PLY files dont have faces, made these import without raising an error. 2007-01-11 02:09:45 +00:00
Tom Musgrove
20413f17bb = dxf update =
update by the script author - may have killed some changes cambo did to the previous version but the layout of the script is too significantly different to merge them.
2007-01-10 11:37:19 +00:00
Campbell Barton
4b9051501f forgot to remove when I changed the name. 2007-01-09 16:58:39 +00:00
Campbell Barton
e2da632f8f ply export patch 5576 applied with parts rewritten.
BPyMesh getMeshFromObject bugfix in some cases non mesh object types could be a problem.
2007-01-09 16:01:38 +00:00
Campbell Barton
9065f0b55a Made skinning between 2 open edge loops work better 2007-01-09 09:24:20 +00:00
Campbell Barton
ca97ede0cd fixes spelling of filename.
Window.c was calling undo_push_mesh, even for non mesh objects, exiting editmode would crash for any non mesh object (found with the armature symmetry script), bad juju.
2007-01-09 05:28:37 +00:00
Campbell Barton
d01374b4d0 image_auto_layout update to use new UV coords, bugfix #5624 thenaks (fredz)
added some text to mesh_boneweight_copy
2007-01-09 00:36:42 +00:00
Martin Poirier
eb3d720bd9 === Transform Snapping ===
Snap/Grid icon button in 3D view header (edit mesh). FIXME NOTICE: make nice looking icons (yes, that's for you Matt)
When snap is on, a drop down appears for the target method (closest, median, center)

Hotkey to toggle snap is Shift-Tab (this was previously used for a not totally equivalent to Tab. Ton said OK to scrap it). That hotkey is currently restricted to edit mesh (where snap is currently restricted).

Changed a couple of ugliness on how snap settings are stored.
2007-01-07 19:33:00 +00:00
Campbell Barton
713f42dc3c Metaball - docs were wrong
Sound - needed t ohave the PyType as extern
3ds_export can now export derived objects (dupli's)
2007-01-07 15:33:28 +00:00
Campbell Barton
95a202322d made python 2.3 compat again. 2007-01-07 07:33:40 +00:00
Campbell Barton
0306a86d94 bugfix, would make bow-tie faces when skinning more then 2 loops.
big speedup to loop detection
added support for skinning open loops (could be improved, dosnt work that well when open loops have different vert counts)
speedup elsewhere with LC's
2007-01-05 16:41:04 +00:00
Campbell Barton
330efd46fa standard set of minor improvements, tho this is a good script and not much to change.
faster dict/list operations.
use layer flags ratehr then lists.
2007-01-05 03:49:54 +00:00
Tom Musgrove
85c2a0a9b7 = mdd import update =
changed menu location from animation menu to import menu
2007-01-05 01:45:54 +00:00
Tom Musgrove
aaf91787c2 = mdd export update =
changed menu location from animation menu to export menu
2007-01-05 01:42:19 +00:00
Tom Musgrove
e586ec7bcd ==dxf import script ==
script for DXF import by kitsu (Ed Blake) - provide superior import to our native DXF import for many files
2007-01-05 00:51:12 +00:00
Campbell Barton
d26d0e2889 Update to JMSs scripts fixed bug 5419.
Optimized 3ds_export.py
  newstyle classes and fixed an error where objects with no material would fail to export.
2007-01-04 20:44:33 +00:00
Campbell Barton
eb424ec18d 3ds_export now exports Texface UV images to 3ds's materials - supports material images as well
3ds_import - made it support image maps without a file chunk. unlikely but possible.
2007-01-04 15:20:28 +00:00
Campbell Barton
7cacb35845 toolbox.c - for the label in VarStruct use the tooltip for the text to get around the 15 char limit that only allowed you to fill about half of the available area on the clever numbuts panel,
the tip isnt used for a label anyway. added comments explaining whats going on. only effects clever numbuts internaly.

type fixes for weightpaint_envelope_assign.py
2007-01-04 11:43:13 +00:00
Campbell Barton
50edac630b removed blender2cal3d.py, this is the second time where nobody has been able to maintain this script to fix minor bugs, aparently the cal3d/soya guys maintain their own scripts anyhow.
Adding switchDirection() for curNurbs. simple function and double checked to make sure its ok.
2007-01-04 10:18:37 +00:00
Campbell Barton
6d5b24fcb8 bugfix for #5167 images are now exported from the material, (todo - texface) thanks to digiboy
Also found that the exported UV coords were scrambled, now fixed.
2007-01-04 05:59:23 +00:00
Kent Mein
7356ede09c I commited a dumb little icon for Sculpt mode since we didn't have anything.
If anyone has anything better feel free to blow this one away.
I was going for a chunk of marble and a chisel if anyone is going wtf?

Kent
2007-01-03 21:12:56 +00:00
Campbell Barton
426cc6dca3 weightpaint_envelope_assign - was making an error checking a null vgroup
API_intro - changed URL from elysuin
others - added __copy__() docs.
2007-01-02 13:12:23 +00:00
Willian Padovani Germano
91b2bc5c23 Python API:
-Added missing access to Node win theme (thanks Mickaël Le-bihan for pointing) and also options group and group_active.
-Added Node space to Window.Types dict.
-Tiny update to the save theme script version numbers (keeping 2.42 for now to avoid popups, but should change to 2.43 right before release).

BTW: Happy New Year everyone :).
2006-12-30 18:28:49 +00:00
Campbell Barton
98f607e127 use new edge/face keys ittributes 2006-12-30 09:40:05 +00:00
Campbell Barton
5af67129f8 * theme save script now saves iconThemes and supports string types.
* added .iconTheme variable
* bugfix. drawType was not being saved because Py_BuildValue and __members__ was missing an "s"
* added Blender.Get('icondir')
2006-12-30 07:32:58 +00:00
Joseph Eagar
4763c3817b =IDProperties Python Test GUI Script update=
Another stupid little coding mistake, made switching
idblock types (like from object to scene) crash the
script.
2006-12-29 21:17:57 +00:00
Campbell Barton
60544bb7cc JMS's latest SVG importer with his compatibility fixes and optimizations.
http://blenderartists.org/forum/showthread.php?t=66207
2006-12-29 11:09:29 +00:00
Campbell Barton
9ca61ba44d Scene.c - deprecation warning for getScene
bvh_import.py - use old slow method of adding keyframes. setting IPO's was having problems.
2006-12-29 08:57:33 +00:00
Campbell Barton
37c42e2949 adding this script that takes 3 clicks to set the selected faces projections.
Will try to add visual guides to make this easier to understand before release.

http://mediawiki.blender.org/index.php/Scripts/Manual/UV_Calculate/Click_project_from_face
2006-12-29 00:25:56 +00:00
Campbell Barton
c95eda7a8b added a call to mesh calcNormals so smooth faces look right 2006-12-28 22:56:24 +00:00
Campbell Barton
2feea3dcc3 made scn.objects more flexible... you can now things like...
scn.objects.selected = [] # deselect all
scn.objects.selected = scn.objects # select all
scn.objects.context = [ob1, ob2...]

Added epydoc examples and updates importer scripts to use this de-select-all method.
2006-12-28 11:09:36 +00:00
Campbell Barton
de04849752 mesh skin was flipping the skin between 2 loops because of an error in AngleBetweenVecs python function that always returned 180d 2006-12-28 06:51:44 +00:00
Campbell Barton
ab06e52343 Mech cleanup use new edge_keys
continual script stuff, minor stuff..

fix for bad return in group.
Added back group.objects.append/remove but print deprectaed warning. also some epydoc changes.
2006-12-28 05:00:35 +00:00
Campbell Barton
7b93fff204 Added a function to BPyMesh - getFaceLoopEdges(faces, seams=[])
returns all face loops as a list of their edge keys

Used this in uvcalc_follow_active_coords to speed it from 5.53sec to 0.098 on a 1000 face mesh.
2006-12-27 15:21:34 +00:00
Campbell Barton
84f60b19c8 weightpaint_clean, option to clean all vgroups
weightpaint_envelope_assign - can update active vgroup only
weightpaint_normalize - fixups
BKE_plugin_types - made the max length 32 ratehr then 16 so you can fill the text space in pupBlock
2006-12-27 09:31:28 +00:00
Campbell Barton
470f91b506 object_cookie_cutter - use edge keys
widgetwizard - made a mistake in last commit, works and also dosnt creash with bug.
https://projects.blender.org/tracker/index.php?func=detail&aid=5289&group_id=9&atid=125
Can others test so we can close?

Object_join was messing up object usercounts
2006-12-26 01:45:58 +00:00
Campbell Barton
8f010d2a58 mesh_skin updated to use ed.key, other minor cleanups.
updated the url in other scripts
2006-12-25 23:14:48 +00:00
Campbell Barton
604defd8f2 somehow pasted some text by mistake that raised an error. 2006-12-25 10:53:00 +00:00
Campbell Barton
859b7f207e modified scripts from using older/depricated Python API commands, deprecated scn.getChildren() in the docs. 2006-12-25 09:17:23 +00:00
Campbell Barton
7816c3ca07 adding this script that makes surrounding quads follow the mapping of the active face.
Added a new mode that generaly gives better results. "Loop Average" -
It gives good results for mapping roads that are more then just 1 quad wide.
Thanks LucidMonkey for pointing this out.

See the bottom of these docs.
http://mediawiki.blender.org/index.php/Scripts/Manual/UV_Calculate/Follow_active_quads
2006-12-23 10:42:34 +00:00
Campbell Barton
ea837b25e3 Added Draw.BeginAlign(), Draw.EndAlign()
added align to a few scripts where it looks nice.
2006-12-23 00:56:40 +00:00
Campbell Barton
9197b25490 removed typo from Render
added extFromFormat to BPyRender to get the extension for a format
2006-12-22 07:07:20 +00:00
Campbell Barton
60ebff78ab rewrote this script, it was the most out of date script and had some errors that are solved in the new script.
- moved to the weightpaint menu
- Use a group for envelope objects, no special names.
- Can use non mesh data for envalopes (anything that can be converted into a mesh - metaballs, text, surface)
- Dosnt rely on applying loc/size/rot for it to work properly
- Uses a good point-inside-mesh method (optimized with mesh and face bounding checks)
- uses Mesh instead of NMesh

todo, only update active vgroup
2006-12-22 00:19:45 +00:00
Campbell Barton
b3eb2d19a9 fix for bevel center as pointed out of the forums 2006-12-21 22:13:14 +00:00
Campbell Barton
0325ee8f22 boxpack2d - python 2.3 compat fix, thanks brecht
gen_utils - needed to include BKE_library.h
off_import - use ed.key
2006-12-21 21:56:11 +00:00
Campbell Barton
04fc326371 Updated to use face.edge_keys,
fixed problem with merging islands not detecting an island in an island (wrong offset)
better island merging from user input
2006-12-21 04:20:07 +00:00
Joseph Eagar
6acadfe982 =IDProperties Python Test GUI Script update=
Stupid typo in script, you couldn't go into
a subgroup if it was the first property in 
the list.

Also, name collision code needed a little work.
This could result in overwriting properties
with the New button, which should instead
work as the rest of blender and add .XXX
to the name.
2006-12-17 01:08:47 +00:00
Joseph Eagar
36bfa35b9e =IDProperties Python update=
Added a test gui script for ID Properties.  To use,
just select ID Property Browser from the help menu.
You can browse, create and edit ID Properties
for several library block types.  Should be
fairly straightforward to use.

This is a test gui script; once an actual ID property
gui is implemented in blender it will be removed.  It
is *not* going to be in the release, obviously, so once
the real gui is implemented this script will be removed.
Also, this being a testing non-release script it seems to me
to be okay to add it without all the proper review stuff.  If
not, I can remove it.

I believe a test script is really, really needed to properly
test/review id properties, so I feel this is worth it.
2006-12-17 00:51:07 +00:00
Campbell Barton
08e3f8b1da Use ed.key and face.edge_keys to build connectivity data faster. 2006-12-17 00:08:05 +00:00
Campbell Barton
711a1f8686 made editmode select grouped work with mixed selections - can show select grouped items for vert/edges/faces all at once.
bad comment in Axiscopy and spelling fix in export_obj
2006-12-16 10:39:08 +00:00
Campbell Barton
827cce172c update to Axiscopy, more error checking. basic functionality the same.
- Dont allow it to apply the matrix twice to a linked-dupe. (Same as Apply Loc/Size/Rot)
- Make sure that the source object is active, not just the first selected object.
- Use Mesh instead of NMesh.
- use mesh.transform(mat) rather then vert by vert vec*mat

Other scripts had pupBlock changes for better layout.
2006-12-15 22:14:33 +00:00
Campbell Barton
0369f08299 made the hax height of the clever_numbers 8 rather then 5, was wrapping on too many scripts.
bvh import was having errors on joints with no animation.
typo in uvcopy from my previous commit.
2006-12-15 20:22:59 +00:00
Campbell Barton
65d5b47a10 removing uvcalc_from_adjacent for review on Sunday's meeting.
image_dump2path is a stopgap util. We need to look into making Pack/Unpack use filenames, not IDnames. or have some other datamanagement utility.
2006-12-15 09:25:57 +00:00
Campbell Barton
e4340d1b58 Shift flips the current axis your draging.
uv's and mocified vertex coords are now in a big list rather then stored be faces, should be faster
2006-12-15 04:49:06 +00:00
Campbell Barton
0254065f3b Updated, optimizations and cleanup.
* accurate mouse to mapping using ray intersect,
* right clicking cancels and returns original coords

Doc is here
http://mediawiki.blender.org/index.php/Scripts/Manual/UV_Calculate/Click_project_from_face
2006-12-15 04:14:09 +00:00
Campbell Barton
f631c2d49e new Uv-Calculation tool,
Click project, a nifty 3 click way to use a face to set a projection aurientation and then 2 more clicks for the U and V scales
with realtime updating as you move the mouse
should be faster then using view project all the time because you dont have to line the view up with the faces.
2006-12-14 19:36:37 +00:00
Campbell Barton
b995593eee faster sorting syntax in python, try/except for py 2.3 backwards compat
ls.sort(key = lambda v: v.foo)
rather then
  ls.sort(lambda a,b: cmp(a.foo, b.foo))
2006-12-14 14:53:32 +00:00
Campbell Barton
3a739d9bd2 fixed mouseViewRay in BPyWindow, was not applying the objects matrix to the mouse direction correctly.
VCol and Weight gradient work again.
2006-12-14 09:56:56 +00:00
Campbell Barton
c5fba51131 object_apply_def - use new BPy Object API funcs, no error in localview
off_export - minor changes
uv_archimap - cleanup. slightly slower but less duplicate code
uv_from_adjacent - nothing

BPY_menus - renamed py slot UvCalculation to UVCalculation to be consistant
2006-12-14 03:43:02 +00:00
Campbell Barton
824f391c75 mesh_edges2curves - edge key optimize and made use of scn.objects rather then Object.New()..
Object.py - passIndex mistake
2006-12-12 21:38:04 +00:00
Campbell Barton
09e4fa8f6a simple change, made
Changed...
  me = NMesh.GetRaw(ob.data.name)
To
  me = NMesh.GetRaw(ob.getData(name_only=1))

The line above converts the entire mesh to a python thick wrapper just to get its name, then only to that that same mesh again??
A lot of older scripts did this but theres no reason to do it.

in most (all?) cases..
  me = ob.data - should be ok, but theres a subtle difference and I dont want to break anything.

xfig_export, xsi_export and videoscape_export need error checking too.
2006-12-12 10:38:43 +00:00
Campbell Barton
848d3ae617 popup error if the active objects datatype cant have keys as well as other cases where it would quit,
use Mesh rather then NMesh to get the keyblock, enable restrictRender for driver objects.
2006-12-12 08:05:08 +00:00
Campbell Barton
6959e689be added many checks to uvcopy so it dosnt raise errors.
Minor changes to radiosity_export, updated to work with the new API (vertexColors MTFace)
obdatacopier - was getting the selection but not using it. made it ignore some read only properties.
BPyMesh - minor change: use face iterator rather then making a tuple()
2006-12-12 07:28:20 +00:00
Campbell Barton
8063417de5 bevel_center.py - avoid 2 python errors. (doing recursive before bevel, now UI prevents this)
console.py - if the scriptdir didnt exist it would do an error, now just ignore and dont try to do the console_autoexec.py stuff
doc_browser.py - If you typed in an invalid module it would give an error and exit, now have a message instead.
2006-12-12 05:29:42 +00:00
Campbell Barton
e22feb7d6e made the script work with no images, redraw when done and some optimizations. 2006-12-12 04:34:35 +00:00
Campbell Barton
97b6a65c74 Added a new Python slot "UvCalculate", moved Archimap and "UVs from adjacent" into it.
Removed 1/2 1/4 1/8 uv mapping options.
made re-evaluating the py-scripts dir use the wait cursor (could take a while at times)
2006-12-12 04:18:45 +00:00
Campbell Barton
5841ba740a dont remove dummy 0 index verts to workaround me.verts.delete([...]) being buggy (since tface > mtface conversion) 2006-12-11 23:03:14 +00:00
Campbell Barton
9c3cacd283 added the flag group_exclusive to material
added restrictDraw/Select/Render to objects in python
updated group and scene docs for last commit
made 3ds import use new scn.objects rather then Object.New() - (removed import as instance for now)
fixes off import error from this report http://blenderartists.org/forum/showthread.php?t=84182
2006-12-11 08:57:39 +00:00
Ton Roosendaal
00becf015b Preview.blend: made lightgroup "Override" for all lamps, to allow
lightgroups to be ignored in preview render.
2006-12-08 18:38:37 +00:00
Campbell Barton
d9c68666f3 Adding a function that gets a list of polylines from a curve object
curve2vecs(ob, WORLDSPACE= True):
'''
Takes a curve object and returns a list of vec lists (polylines)
one list per curve

This is usefull as a way to get a polyline per curve
so as not to have to deal with the spline types directly
'''
2006-12-07 15:22:55 +00:00
Campbell Barton
93e920aea9 UV islands are now detected by edge connection (was using verts) - added support for seams to delimit UV islands. 2006-12-02 09:44:40 +00:00
Campbell Barton
4b982acf17 Made work with new vertex colors 2006-11-30 21:32:32 +00:00
Campbell Barton
0d5a152094 request from malefico - select faces based on there weight in the active group.
Access from the face select menu
2006-11-28 21:26:00 +00:00
Campbell Barton
a314527e20 when importing am OBJ referencing an unknown image (PSD in linux for eg) - it creates a dummy image.
checking the .depth of this dummy image raised an error. now a check for has_data is done.
2006-11-27 23:59:53 +00:00
Joseph Eagar
7101e76d9c =md2_export.py small fix=
There was an integer division error in md2_export.py,
where values were getting clamped to either 0 or 1.
Fixed it by putting the appropriate vars in float().

Reported by deltab on IRC.
2006-11-27 01:05:44 +00:00
Campbell Barton
703647d08b previous commit to fix this script with VCols didnt work, should be ok now. 2006-11-26 23:47:53 +00:00
Campbell Barton
b36bafe524 removing image bake scripts to make room for Ton's built in baking stuff. 2006-11-26 19:08:19 +00:00
Campbell Barton
d2c482115e minor change so other scripts can call image_edit.edit_extern(img) to edit an image in the gimp, photoshop etc. 2006-11-26 18:40:04 +00:00
Ed Halley
8292e4ac1a Was crashing the import_obj script when using Python 2.3.
Python 2.4+ supports large list processing with generators, but
Python 2.3 will break if you use that syntax.  Until we depend on
the newer versions, I have commented out the generator syntax and
only use the list-comprehension type instead.
2006-11-25 17:34:57 +00:00
Campbell Barton
909cb06dfe modified to support new vcol operation (separate from tface)
updated name and tooltip
minor fixes
2006-11-24 07:35:53 +00:00
Ken Hughes
7b9fac49f5 Bugfix #5289: "Shape Wizard Widget" script was using non-existant key:
changed so "Key 0" is substituted for "Basis".  This may not be correct...
Also, fix to make ob.setEuler() accept a tuple again.
2006-11-23 00:28:09 +00:00
Chris Want
0b0c8c9244 =Texture Plugins=
Added a callback instance_init() so that any particular instance of a
texture plugin can initialize data. Updated the clouds2 and tile example
plugins to have a (dummy) call back.
2006-11-22 15:53:46 +00:00
Matt Ebb
a317ef6828 * The raw blenderbuttons image (note, I've updated interface_icons.c to now use the extra space on the right side of this image, since we'd run out of room) 2006-11-20 05:14:37 +00:00
Chris Want
27c42ee062 A fix for an indentation error, and better handling of faces with
images when materials are defined for the face (i.e., only use
the image as a texture in this case if 'Texface' is selected
for the material).
2006-11-17 16:11:03 +00:00
Campbell Barton
a84f60a3bd fixed error that was caused by 2 vertex loops center being 0.0 distance apart, also made the python 2.3 syntax default. 2006-11-15 21:12:53 +00:00
Matt Ebb
2e55867c23 Woops, I think I committed some wrong versions of the *nix icons the first time,
trying again now.
2006-11-15 03:43:47 +00:00
Matt Ebb
0597e17710 Tweaked the makefile build system to copy the new freedesktop icons
into an icons folder in the release package on linux, freebsd and openbsd
when doing 'make release'.
2006-11-14 04:29:04 +00:00
Matt Ebb
56b11f6e48 Added a great new set of Linux Blender icons, conforming to the
freedesktop.org standard.

Many thanks to Jakub Steiner, who created these!
( http://jimmac.musichall.cz/weblog.php/Artwork/WarOnBlobs.php )
2006-11-14 04:16:05 +00:00
Martin Poirier
51fa185ec5 == Script: UV Export ==
* SVG export support (thanks to Jarod's patch in the tracker)
* Faster tga export (from Jarod's patch too)
* Fixes from the review thread and the wiki:
** No longer adds the extension (tga or svg) if already there
** Adds the object name in between the filename and extension (and not after the extension if it was already present)
** Renamed options here and there.
2006-11-14 00:56:46 +00:00
Campbell Barton
26ef99157e made mesh.getFromObject() accept a python object as well as the object name.
accepting the name only was causing big problems when exporting library data, because duplicate names are possible the wrong data was exporting.
2006-11-13 17:37:01 +00:00
Chris Want
05c59da48f Fix for bug #4922
The VRML97 exporter was rounding a lot of stuff to three decimal points.
This is silly, since the spec says single-precision floats are used for
most things, which gives about 7 decimal points precision.
2006-11-11 19:12:43 +00:00
Campbell Barton
daec99c470 new image names were being created with 2 ..'s
added a function to BPyMesh.py to get faces in linked groups (like split by loose parts) - but returns lists of faces only.
2006-11-10 02:23:30 +00:00
Ton Roosendaal
10a4b1ad8b Patch #4743, Stephane Soppera
gamma.c plugin (sequencer) now supports float rects.
2006-11-06 18:37:26 +00:00
Campbell Barton
2dcf23c327 added Jiri as a contributer to the obj importer
Added a new script - 'Dump All Images to Path'

This script copies all the images used by 1 blend to a spesified path and references the new images from Blender
Usefull for moving projects between computers or when you reference many images. naming collisions and multiple images using the same image path are delt with properly only creating new image names when needed.

Blender images will reference the newly copied files - So be mindfull when you save your blend after running the script.

Notes, images with the path "Untitled will be ignored"

Image path collisions are managed by enumerating the path names so images will never be overwritten at the target path.
2006-11-03 20:04:56 +00:00
Campbell Barton
5ee546f053 added batch import back in - Hold shift as you click import 2006-11-02 17:42:30 +00:00
Campbell Barton
0dbac3ab69 attempt to make zero area faces result in NAN or INF loc verts happen less. 2006-11-02 00:13:38 +00:00
Campbell Barton
55d1618990 check for devide by zero error 2006-10-30 16:01:38 +00:00
Campbell Barton
8177125b0f An arg was left in that should have been removed, raised an error for reflect MTL files. 2006-10-29 19:56:52 +00:00
Campbell Barton
9b7125fafc added the option to rename objects to their DupGroups name. 2006-10-25 01:32:46 +00:00
Campbell Barton
23eb8b7a1f added the option to poly reduce all visible selected objects 2006-10-21 19:38:42 +00:00