Commit Graph

3249 Commits

Author SHA1 Message Date
Ton Roosendaal
d8f23c8d3c Reflecting the discussions on Transform Manipulators...
Here you can see the notes and pictures:
http://www.blender3d.org/cms/Manipulator_Widgets.548.0.html

The alternative rotate widgets are still under rt=2 and rt=3.

Still enough work todo here, but hope it's a good step forward!
2005-04-24 13:22:24 +00:00
Brecht Van Lommel
0016d29b51 Make view translation and zooming 'smooth' in the uv editor. Power-of-two
zoom levels can be found in the View > View Navigation menu. Also Ctrl+MMB
zooming was added.

Added the E-key, LSCM unwrap popup back again.
2005-04-24 11:57:23 +00:00
Martin Poirier
6379ff9b70 Toying a bit with MMB behavior:
MMB click with no constraint selects a constraint right away (the axis selector doesn't flash on screen)
MMB click with a constraint removes the constraint
MMB click-drag in both case (with and without a constraint) uses the axis selector.

stopConstraint didn't remove the CON_SELECT flag, so cancelling transform while selecting a constraint and then reentering transform was funny. Fixed
2005-04-24 01:18:13 +00:00
Martin Poirier
7a4ae00da2 Replaced powf to (float)pow in zblur.c. Was giving problems with MSVC (the rest of the code base uses pow too).
MSVC 6.0 Projectfile changes for zblur and new files in ketsji.

Also adding BL_src projectfile to the commit, apparently it's not up to date with transform_conversions.c but I have it ok here and don't get any diffs.
2005-04-23 22:45:34 +00:00
Ton Roosendaal
7fa7826da7 The zblur plugin (aka as DoF) integrated in render. Compared to patch
submitted by Alexander, changes/improvements are:

- Moved to new Panel in Scene buttons "Post Effects". Together with other
  postprocessing options, such as Edge render. It is also not called DoF,
  this because that's a bit pretending too much then. It's a zblur still!
- Made it render Alpha as well
- Made it use and deliver float buffers
- Huge cleanup of zblur.c code, was very messy. It was alling things in render
  code without need even (win matrices, transform faces, etc)
- Fixed errors in using Z values (zbuffer is signed int)
- Removed very weird gamma corrections for front/back half
- Tweaked gaussian table, allow variable 'Sigma' to be set for gauss curve
- Didn't copy 'auto focus' yet. Use of this is very limited, and gives
  false expectations, nor works for rendering anims with deamons well.

Main issue remains: it's not a very advanced feature... I still doubt
very much if this deserves to be released. Spent 2 days on trying to get
the key issues solved, with not much results.

- gauss filter code has weird side effects on large blur size
- having unsharp (blurred) in front also blurs what's around in back.
  only blurred in back with sharp in front works a little bit
- severe aliasing errors... also due the code splitting in 2 halves
- doesnt work with unified yet
- won't work for halos, spot halos or transparant faces

Anyhoo... It was promised to be committed, so now artists can play with it.
Who knows it's useful after all, or some fixes can be implemented. :)
2005-04-23 20:49:23 +00:00
Kester Maddock
0dcba86c6b Added the docs & use Python booleans for physics reinstance. 2005-04-23 12:25:21 +00:00
Kester Maddock
10acf20645 Support reinstancing the physics mesh from Python. 2005-04-23 12:03:37 +00:00
Kester Maddock
32daf2cdc4 Fix lighting in game engine 2005-04-23 11:54:21 +00:00
Kester Maddock
2ac1ef13e2 Added bone parent relationship. 2005-04-23 11:36:44 +00:00
Brecht Van Lommel
c333ba8dfa Merging over some uv editor tweaks from tuhopuu:
- Moved Weld/Align out of transform code, now it's a menu.
- Removed confirmation popups for LSCM unwrapping in the uv editor, didn't
  make sense anymore now we have undo.
- Extended select linked, to work more like it does in edit mode:
	- L: select linked uvs/faces under the mouse
	- Shift+L: select/deselect linked uvs/faces under the mouse
	(like shift+click for selecting single uvs/faces)
	- Ctrl+L: how L worked before
- More accurate uv selection: when selecting one uv from a group of uvs that
  are in the same position, it now selects the uv belonging to the face the
  mouse is over, instead of a random uv.
- 'View Selected' (numpad .-key) for both faceselect mode and the uv editor.
2005-04-23 01:36:08 +00:00
Chris Burt
375cf60462 Commented out DOF code that did not have a home yet because it broke
compile. Normally it would probably be best just to wait till Ton committed
but its still pretty early and I didn't want people complaining all night.
Hope its no problem!
2005-04-22 21:58:37 +00:00
Ton Roosendaal
075ed5fd53 The do_versions() for new shaders always initialized the values... 2005-04-22 21:31:52 +00:00
Brecht Van Lommel
6a00fcd90c Add "View Selected" (numpad .-key) for faceselect mode and the uv editor.
Also includes some 2d vector operations (subtract, dot, normalise).
2005-04-22 20:16:02 +00:00
Johnny Matthews
43835d4d04 Matched the default value for rkerror limit in bpy 2005-04-22 18:05:56 +00:00
Jens Ole Wund
55f4ead5a2 gave softbody runge kutta error limit a nice default value 2005-04-22 17:58:39 +00:00
Stephen Swaney
621d218056 removed extra qualifier `SumoPHYCallbackBridge::' that was choking
gcc in c89 mode.  More potential breakage.
2005-04-22 16:17:27 +00:00
Stephen Swaney
63388ad246 Fix previous fix by moving some code around to try to please everyone.
or at least their compilers.  let me know what breaks.
2005-04-22 16:10:46 +00:00
Stephen Swaney
9fb241c930 fix compiler error with gcc 4.0. mismatched declarations. 2005-04-22 02:27:16 +00:00
Stephen Swaney
b89bddbf6f doc updates. NMesn.transform( matrix, recalc_normals )
had description for recalc_normals backward.
2005-04-22 02:17:20 +00:00
Martin Poirier
c1a7b8b7a1 Local axis constraints for pose mode. Added
Camera rotation fix (was off centered because it used persinv instead of viewinv. Now rotation center is always center screen in camera mode. (Still need to fix the helpline not showing)
Numinput constraint function was no good, didn't check if a constraint was even on... Fixed.
Rotation was missing constraint text in header print. Fixed.
2005-04-22 01:14:15 +00:00
Willian Padovani Germano
589ce4a005 BPython:
- based on a request by Campbell (he also provided a patch for scene.Layer) access to layers was improved a little, keeping the old method (ob.Layers is a bitmask) and adding the nicer one (ob.layers is a list of ints).  Done for objects and scenes.  House-cleaning: .Layer was renamed to .Layers (actually just using strncmp instead of strcmp, so both work, same done for Window.ViewLayers).
- finally committing patch by Ken Hughes to let .clearScriptLinks() accept a parameter (list of strings) to clear only specified texts.
- doc updates and fixes (JMS reported a problem in nmesh.transform() example code).

Thanks all who contributed.
2005-04-21 19:44:52 +00:00
Jens Ole Wund
c5214c1571 rescaled stregth of wind and forcefield effects by some magnitudes
wind 250
field 1000
yeah WARNING to all testers:
tighten belts
scale down wind and forcefield settings (IPOs)
2005-04-21 18:58:15 +00:00
Ton Roosendaal
8a75569f9a Testing, 1, 2, 3... (just added enter) 2005-04-21 11:24:44 +00:00
Jens Ole Wund
bccd65de8a give some nice defaults for new SB deflectors 2005-04-20 19:35:27 +00:00
Ton Roosendaal
be3eec3014 Softbody: added "time" button, to control speed for wriggling. Low values
make it slower, higher values faster.

Monkey: accidentally got inverted normals for they eye again. :)
2005-04-20 16:55:04 +00:00
Matt Ebb
3dbae624d3 * Brought over a 'mode' parameter to drawcircball to prevent
further loss of Hos' hair during tuhopuu merges.

This doesn't change any user functionality. 'Mode' can be
GL_LINE_LOOP for a circle outline (as it currently is), GL_POLYGON
for a filled circle, or whatever gl mode you like.
2005-04-20 08:26:22 +00:00
Jens Ole Wund
4126e4e345 providing a minimalistic UI for SB vertex to face collision detection
in the particle interaction panel
"D"= "Amount of damping during softbody collision/intrusion"
"I"= "Inner face thickness" good value for unit cube == 0.2
"O"= "Outer face thickness" good value for unit cube == 0.02
still we can easily hide that before releasing
2005-04-19 22:06:12 +00:00
Jens Ole Wund
1d47d662f9 removed my SB hack from particle collision code
(which still can't really handle moving targets)
leaving 2 bug fixes
1. multiple objects need a reset on cache variable
2. quads always need to be handled as 2 triangles
(since they don't need to share a plane)

added a collision detecting function in effect.c for SB
( no need to be there, but i did not find a better place )
but should handle 'moving targets' up to 0.2 blender units/frame

well .. important info in this case:
collision
uses 'face normal' to decide if *intrusion* happend
uses 'damping' of collision target to slow down movement
when *intrusion* happend

+some more removing unneeded code in softbody.c
2005-04-18 21:51:45 +00:00
Ton Roosendaal
99ee891596 Fixed several annoyances with halo render + unified render (bug 1989+2382)
- Maximum faces/halos per pixel was 500, which wasn't correctly applied in
  all cases, causing errors in AA
- Moved maximum up to 1000 now
- made halos become clipped away from filling in buffers when behind a
  solid face. That saves a lot of rendertime!

Unified remains weak with halos...
2005-04-18 19:36:34 +00:00
Chris Burt
5d31c72020 Uncommented a line in the FREE_WINDOWS section that appears to control the
detection of changes to dependencies. This should resolve issues with
Cygwin builds using makefiles which have bizarre behavior if 'make clean'
was not used before compile.
2005-04-18 19:28:38 +00:00
Ton Roosendaal
d556ae3874 On adding monkey primitive, the face centers were not calculated OK. 2005-04-18 16:06:37 +00:00
Ton Roosendaal
44c7cbc083 Bug fix #2458
Without 3d window, using subsurf setting buttons crashed Blender.
2005-04-18 15:55:52 +00:00
Ton Roosendaal
35f4c77d96 Little cleanup of eerie unified code for halos. Still got no clue what
was original idea of this implementation...
At least it's protected from crashing a bit more.
2005-04-18 15:30:49 +00:00
Alexander Ewering
0b0f82bbb2 Fix crash with Unified Renderer on LMB in renderwindow. Ton needs to
provide Z-Buffer for Unified still :)
2005-04-18 15:08:31 +00:00
Alexander Ewering
8a1206f56d Add a "Z:" display when pressing LMB in the renderwindow, which displays
the normalized Z-Buffer value of the corresponding pixel.

Useful for setting ZMin for DOF, see next mail to the list
2005-04-18 13:56:19 +00:00
Kester Maddock
6c4ae1eb54 Patch: [ #2439 ] Makes objects react properly to deformations after a mesh replacement call.
from brian hayward (bthayward)

Detailed description:
 Currently, when an armature deformed object's mesh is replaced by the ReplaceMesh actuator, the new mesh fails to deform to the armature's movement.

 My patch fixes this by properly replacing the deform controller along with the mesh (when appropriete).

 For instance, if one had an animated character using any of the standard deformation techniques (armature, ipo, RVK, or AVK), that character's mesh would currently be prevented from changing mid-game. It could be replaced, but the new mesh would lack the controller which tells it how to deform. If one wanted to dynamiclly add a hat on top of the character's head, it would require storing a secondary prebuilt character (mesh, armature, logic, ect...) on another layer FOR EACH HAT the character could possibly wear, then swapping out the whole character when the hat change was desired. So if you had 4 possible hat/character combos, you would have 4 character meshes, 4 armatures, 4 sets of logic, and so on. I find this lack of flexibility to be unresonable.

 With my patch, one could accomplish the same thing mearly by making one version of the character in the main layer, and adding an invisible object atop the character's head (which is parented to the head bone). Then whenever it becomes desirable, one can replace the invisible object's mesh with the desirable hat's mesh, then make it visible. With my patch, the hat object would then continue to deform to the character's head regardless of which hat was currently being worn.

 *note 1*
 for armature/mesh deformations, the new mesh must have properly assigned vertex groups which match one or more of the bones of the target armature before the replaceMesh call is made. Otherwise the vertices won't react to the armature because they won't know how. (not sure if vertices can be scripted to change groups after the game has started)

 *note 2*
 The added processing time involved with replacing the object's deform controller is negligible.
2005-04-18 11:44:21 +00:00
Ton Roosendaal
d34acbfe44 Replaced a bunch of malloc() calls with proper MEM_mallocN()
(and free() and calloc() of course)

Remainder malloc() calls need to be there for realloc().
2005-04-17 18:00:33 +00:00
Ton Roosendaal
425f295604 Patch submitted by Jorge Bernal (lordloki) and Jonathan Merritt.
This will add Minneart diffuse and WardIso specular to our shader menu.
Minneart gives nice control over darkness/brightness areas, the wardIso
over 'plastic' style sharp or fuzzy specular.

Webpage is being made with nice samples. Will be in release log.

Jorge: one change is in the do_versions, you inserted it on wrong location.
2005-04-17 17:43:07 +00:00
Ton Roosendaal
8a02dc11de Patch provided by Andrea Weikert (elubie):
With a few tests I have discovered that when quitting Blender the filelist
in SpaceFile doesn't get free'd.

storage.c:
I have replaced strdup for the relname member in BLI_builddir with BLI_strdup.
and malloc with MEM_mallocN for the string member in BLI_addstrings().

filesel.c:
Of course also had to replace free with MEM_freeN in freefilelist().

In freespacelist (space.c) I added call to freefilelist for the SPACE_FILE
space type.
2005-04-17 15:50:52 +00:00
Stephen Swaney
f919cf75f1 More Curve Module features: access to the attributes flagU and flagV
in a  CurNurb object.
Contributed by Gergely Erdelyi (dyce).
2005-04-17 14:37:40 +00:00
Stephen Swaney
127abda43d New methods for Curve module: getBevOb() and setBevOb()
Adds ability to set, clear and get bevel object for a Curve.
Contributed by Gergely Erdelyi (dyce).
Thanks!
2005-04-17 13:48:16 +00:00
Willian Padovani Germano
fa5d910f93 Updating build systems: folder release/bpydata/ moved to release/scripts/bpydata/
It seemed trivial enough, so I updated all systems (makefiles, xcode, scons, scons win installer), please complain if something went wrong.  Mostly it was just removing release/bpydata references, since the release/scripts dir is already worked on recursevely, handling dirs inside it.

For the scons nsi file writer script I had to write code for each new dir, but it can be recoded recursively, too (in fact joining all release stuff in a single dir tree with nothing else would be a good idea, making installation code simpler).  Since it's just python and I have a little more time now, I can help scons managers if they still need.

Thanks Campbell Barton for reporting.
2005-04-16 18:25:42 +00:00
Alexander Ewering
dfe3ad0d7b copy_softbody() didn't check if object actually was softbody! 2005-04-16 16:56:06 +00:00
Ton Roosendaal
5ff281eaec Li'll feat request;
When curve objects have no front/back faces, the bevels were only drawn
for the outer part. Now it also makes interior bevels, so yo can
have a curve become a 'solid' ring easily.
Note: only works when you disable filling option "Front" and "Back".
2005-04-16 15:51:44 +00:00
Johnny Matthews
56591ade33 The setup functions for SB and PI now initialize the vars to the defaults that are set in the UI when one of the panels are accessed. Current this happens whenever an SB or PI api function is called for the first time. 2005-04-16 15:33:38 +00:00
Ton Roosendaal
07ef51cdb1 More SoftBody stuff:
- after grab/duplicate the softbody didn't get a reset signal
- added 'copy properties' for softbody settings
- duplicate object didn't copy softbody yet
2005-04-16 15:06:02 +00:00
Ton Roosendaal
7943f7990e Softbody:
- Added browsing for vertex group for "Goal" in SoftBody buttons.
- Means the default name "SOFTGOAL" isn't needed anymore
- temporally, on file read, the "SOFTGOAL" vertex group is set, if exists
- removing vertex group possible too
- changed softbody.c code to use this
2005-04-16 14:01:49 +00:00
Ton Roosendaal
097726eb50 For the manipulator freaks; rotate widget with 'arcs' now displays the
transparant grey (ghosted) rotation where mouse click started.
2005-04-16 12:35:42 +00:00
Willian Padovani Germano
d65fc84a68 Note: this commit includes new functionality to save and restore scripts configure options. This is ongoing work, scripts still have to be updated to use this feature and more tests are needed, though many have been performed. The new Scripts Config Editor script is the main part of this. If anyone wants to check it, only the AC3D importer and exporter have already been updated to use it: simply open them (you can then cancel with ESC) to have the data created, then try the config editor.
Scripts:
- Thanks Jean-Michel Soler (jms) for updated versions of dispaint, fixfromarmature and unweld (also renamed to remove version part).
- Thanks Bart for the upgraded VRML exporter (great doc webpage!).  It is available as VRML 97 and the original VRML 2 is for now still there, to help users testing the new version.  For the next release the old one should be removed, of course.
- New script: Scripts Config Editor (Scripts win -> Scripts -> System).  Scripts with config options (simple data that is to be set according to user needs or preferences) can use this facility instead of providing a gui and writing config files to disk themselves.
- Added new menu: System, available in the Scripts win.
- Updated sys_info.py, help_browse.py and the AC3D importer and exporter.
- Removed use of the Scrollbar and added arrow keys and mouse wheel support instead in Daniel Dunbar's old doc_browser.py. The scrollbar events handling doesn't exist, Ton suggested removing the scrollbar from the API months ago.  For now its ref doc is gone and no bundled script uses it, until we get time to implement it properly.
- Added module BPyRegistry.py with functions to handle reading / writing config files automatically to the scripts/bpydata/config dir.
- Removing dir release/bpydata and its contents (moved earlier to release/scripts/bpydata/)
- Bug #2379: made small changes to bevel_center's ui to fix a problem reported by Alexander Ewering (intrr):
http://projects.blender.org/tracker/?func=detail&atid=125&aid=2379&group_id=9

BPython:
- Thanks Campbell Barton for new functionality: Blender.Get() now can also return all the paths from the user prefs -> file paths win and there is a new function: Blender.sys.expandpath() to transform Blender paths (those starting with '//' and ending with '#') to absolute paths.
- Added function Blender.ShowHelp(), to open the Scripts Help Browser with a given help page -- just a time saver for scripts.
- Improved function Blender.Run() to also work with gui and file select scripts.
- Found a (new?) crash related to NMesh.PutRaw when creating a new object while in edit mode.  Leaving / entering edit mode fixes the problem, so a check for obj created, edit mode and leaving / re-entering it were added to the code for now (gdb didn't help much, no backtrace)
- doc updates, including splitting intro page in two, with bpython related stuff (registering / documenting / configuring scripts and command line mode (thanks Chris Want for "use system variables to pass parameters to scripts" idea).
- Registry: functions have been updated to support writing to / reading from disk, for the config editor -- only simple config data supported, for large amounts coders should write to a file themselves.  This is done with a new parameter: Registry.GetKey(keyname, True) will also search for the key on the config dir, if not already loaded; equiv. for Registry.SetKey(keyname, dict, True).  Data is only written to / read from disk when needed and only scripts already used (assuming they support this functionality) will have config data saved.
2005-04-16 05:25:42 +00:00
Ton Roosendaal
8b664b924b In localview the Manipulator didnt center at correct 3d cursor location. 2005-04-15 21:39:36 +00:00