Commit Graph

28007 Commits

Author SHA1 Message Date
Benoit Bolsee
fc66b3f2ef BGE: support modifiers without mapping to original mesh both graphically and physically, fixes bug #24942 and #25286.
Support for physics is done by skiping the modifiers that
don't support mapping to original mesh. This mapping is
required to report the hit polygon to the application
by the rayCast() function.

Support for graphics is done by using the same render
function that blender uses for the 3D view. This guantees
equal result.

Limitation: there is still a known bug if all these conditions are met:
- Display list enabled
- Old tex face with a several textures mapped to the same material
- no armature or shape keys
- active modifiers

In this case, only a part of the mesh will be rendered
with the wrong texture. To avoid this bug, use the GLSL
materials or make sure to have 1 material=1 texture in
your old tex face objects.
2011-01-23 17:17:21 +00:00
Janne Karhu
fa38da021c Some ui reorganization of the physics tab:
* Before the different simulations all had a panel with an "add this" button making the whole tab look really messy. It also rarely makes sense to have more than one or two physics things enabled for a single object, so having all the panels in the tab just added a great deal of visual clutter.
* Now there is a single "enable physics for" panel at the top that allows for enable/disable of any simulation. All actual physics panels are hidden until a simulation is enabled.
* There was no "add" button for force fields before, but I added a toggle between "none" and "force" to unify the ui even further.
2011-01-23 14:04:31 +00:00
Janne Karhu
eafbb9221e Panels that have the "no header" flag set are now always drawn first in a tab regardless of the order they were registered.
* This is a quick and simple workaround until we can define proper ordering for the panels.
2011-01-23 13:52:24 +00:00
Campbell Barton
7aebf814d2 update testing md5's for changes in exporters. 2011-01-23 13:34:36 +00:00
Campbell Barton
d2076e38f1 correct own bad spelling 2011-01-23 12:42:07 +00:00
Campbell Barton
d75216ba1c - fix problem with cmake, windows 'RelWithDebInfo' target, was giving error: "ImportError: No module named _socket" because of copying wrong files over.
- move test -> tests, this name is used elsewhere in lib/tests.
- change interface code not to loop on a float value (clang warning), harmless, but with extreme cases an eternal loop would still be possible though unlikely.
2011-01-23 11:42:29 +00:00
Campbell Barton
552b36733b bugfix + minor mathutils.Vector edits.
- multiplying a 2D vector by a 3x3 or 4x4 matrix would use un-initialized memory, now throw an exception.
- use more variable length array BLI_math functions.
2011-01-23 08:37:34 +00:00
Dalai Felinto
a877155a7c Logic UI: ParentActuator fix + PropertyActuator tooltip improvement
ParentActuator: sub options only available when mode==setParent + deactive ghost option when compound is true (isntead of saying that in the tooltip)
PropertyActuator: I never knew that you could pass a property name to the Add and Assign options of the Property Actuator. Where it's by design or a side effect is cool. And a tooltip explaining that does help.
2011-01-23 04:54:23 +00:00
Janne Karhu
f39c794c7c Own mistake in fluid particles ui cleanup commit.
* Emission tab was shown without particle settings.
2011-01-22 21:22:29 +00:00
Janne Karhu
3dc1c14a13 Bug fix: pre 2.5 particles that were using old memory caching didn't load properly
* Now the old cache is just freed so that new calculations can be done.
* The particle dynamics regression test files should display correctly now.
2011-01-22 21:13:29 +00:00
Janne Karhu
f4598728c4 "Fix" for [#25766] Fluid Particle Bugs
* Argh, particles tab was showing the whole "non applicable settings for fluid particles"-galore as the particle type "fluid" can't be checked from rna using the settings type value. Now the ui is a lot cleaner and only settings that actually effect the fluid particles are shown.
2011-01-22 20:38:27 +00:00
Ton Roosendaal
29bee35112 Small fix from the todo:
"Modal cursors" now remain visible, until reset. These cursors
were reset already on edges. Example: 3d view toolbar, grease 
pencil. Do note, only use WM_cursor_modal() on real modal tools,
and restore it at end.
2011-01-22 18:00:11 +00:00
Ton Roosendaal
c0e4c7bbc6 Bugfix #25761
Move-to-layer in 3D window didn't work for linked library objects.
That should be possible, as was in 2.49. Layer property is local.
2011-01-22 15:34:20 +00:00
Janne Karhu
db8a253ace Fix for [#25664] Remove Pack does not work in Texture panel
* Unpack menu option "Remove Pack" didn't get a pointer to the image to be unpacked. This worked from image view by using the active image, but not from texture panel.
2011-01-22 14:44:04 +00:00
Janne Karhu
1149120145 Temporary fix for [#25735] Softbody don't work in linked groups, not generate cache
* The whole case of lib linking and pointcaches is not very well defined currently, but this fix sets the behavior of sb to the same as other physics currently.
* A proper fix will be easy to implement after a good physics baking ui is added.
2011-01-22 14:13:36 +00:00
Campbell Barton
3d635c0733 own fix r34446, was incorrect, fixed properly now. 2011-01-22 04:40:15 +00:00
Campbell Barton
98124e7f94 error in own recent commit, r34445 2011-01-22 04:13:13 +00:00
Campbell Barton
99ae4467d2 fix for makesdna error.
ERROR: still 1 structs unknown
*** Unknown structs : 
  PreviewImage
2011-01-22 04:02:54 +00:00
Campbell Barton
799e9c48c1 comment dead code and fix 2 missing NULL checks (pointer used after NULL check and checking against incorrect pointer before use). 2011-01-22 03:50:09 +00:00
Campbell Barton
f6d54bd1ee correction to own cmake error checking script. 2011-01-21 11:52:56 +00:00
Campbell Barton
a5d4922639 PLY and STL importer tests. 2011-01-21 10:49:39 +00:00
Dalai Felinto
0f794b130d Logic UI + missing listener in Outliner - changes on Armature Sensor and Visibility Actuator
* fix for armature sensor (Status Changed doesn't use any value to evaluate itself) + renamed "Test Type" to "Test"
* visibility tooltip was wrong - now we can change visibility from the physic buttons instead of the outliner
* bonus * when you change the visibility from the physics panel the icon in the outliner wasn't changing
2011-01-21 08:59:08 +00:00
Dalai Felinto
1f099087c3 Logic UI: more tooltips, adding (blank = all objects) for the Property field of the physic sensors + using PROP_ANGLE for Radar Sensor
(to work in tooltips bring good karma !)
2011-01-21 06:12:56 +00:00
Campbell Barton
d9f7a05f2e bugfix [#25712] Deletion of vertex groups under script control causes incorrect reassignment of vertices in other groups
vgroup functions were mixing up active group and one passed as an argument.

also made other changes.
- removed superfluous call to defvert_find_index() in vgroup_delete_object_mode(), was also doing unnecessary NULL check on each loop.
- remove paranoid NULL check from ED_vgroup_vert_remove, callers all check for valid 'ob'
2011-01-21 05:09:32 +00:00
Dalai Felinto
26429d0a63 BGE Logic UI: Near Sensor tooltip update 2011-01-21 04:07:32 +00:00
Campbell Barton
262a33cbe4 change mathutils.Matrix.Shear() for 3x3 or 4x4 matrices
The plane which defined the shear had the factor applied to each axis equally.
This meant that the shear for any 3x3 or 4x4 matrix would be diagonal on the positive values of each axis.
Only being able to create diagonal shear matrices seems stupid, now take a pair of floats for the shear factor corresponding to the plane axis values, so its possible to shear on only one axis of the plane.
2011-01-21 03:18:01 +00:00
Campbell Barton
d7c6ddd7e9 correct spelling 2011-01-21 02:32:58 +00:00
Campbell Barton
022511d5ad [#25732] Incorrect shear matrix in XY plane
fix included by Lawrence D'Oliveiro (ldo)
2011-01-21 02:27:04 +00:00
Guillermo S. Romero
a994f872c2 SVN maintenance. 2011-01-21 00:33:37 +00:00
Campbell Barton
8a3beb0012 import/export automated testing using CMake's CTest
Will need to write full docs on this on the wiki.
basic info.
- 21 tests, OBJ/3DS/X3D/FBX, 3 tests per format import export. STL, PLY, BVH are TODO.
- uses files in ../lib/tests (checkout separate)
- run with CMake Makefiles "make test" or "ctest"
- currently checks against basic MD5 hash on scene import and file MD5 hash on export (realize this wont work predictably on binary formats *TODO*).
- currently uses a generic script for all tests with arguments to specify command to run, expected output, testing method, files to check against etc.

Has already proved useful, found a number of bugs in import export and some in blender too.
2011-01-21 00:06:30 +00:00
Campbell Barton
df6bb34c2b correct fix for [#25737] Console error message 2011-01-20 23:05:25 +00:00
Joshua Leung
76940e6f5c - Bugfix: NLA "duplicate" operator now lets strips get moved between
tracks too, instead of only sliding around on the track they were
defined on.
- Adding description fields for many (older) operators that lacked
them
2011-01-20 22:22:16 +00:00
Joshua Leung
cfe1f77a5f Bugfix [#25737] Console error message
It seems that rna_def_effect() is missing a rna_def_input(), resulting
in:

  rna_uiItemR: property not found:
EffectSequence.animation_offset_start
  rna_uiItemR: property not found: EffectSequence.animation_offset_end

in the console. I'm not sure whether these settings are used for
"effect" strips or not, but I'll leave that to sequencer guys to
figure out if/when they get a report about this.
2011-01-20 21:46:11 +00:00
Campbell Barton
039bb7812f bugfix [#25742] blender-thumbnailer.py doesn't work with python 3.1 2011-01-20 21:02:42 +00:00
Joshua Leung
dc2431c491 Small code reshuffle... sequencer transform stuff was bisecting the
code for object transform stuff
2011-01-20 20:51:38 +00:00
Diego Borghetti
44fbbe7c55 Ghost:X11 Set the default max width and max height value.
Some window manager can set default value of this to be the
screen size, so running blender with -p or --window-geometry
don't work with value bigger than that.

This commit try to "avoid" the bug #25709, but at the end
depend on the window manager, so maybe work or maybe not.
2011-01-20 20:24:18 +00:00
Ton Roosendaal
f407f38204 Bugfix #25656
Fixed one of oldest annoyances in Blender: the text input button!
It always behaved stupid when you had clipped text in a button.

Now while using arrows the cursor will move as expected, and only
internally shift contents when cursor reaches edge of button.
2011-01-20 18:34:48 +00:00
Ton Roosendaal
2e8c93b663 Bugfix #25619
Paint modes: toolbar showed the preview image with double scaling applied,
so if UI zoomed in the image grew outside boundary.
2011-01-20 16:29:43 +00:00
Ton Roosendaal
2e436acff0 Bugfix #25611
Pose Proxy: layer settings only saved the 16 bits for proxy armatures, was
still a short, whilst the other layer settings use ints.
2011-01-20 15:17:02 +00:00
Joshua Leung
ba965ab32e NLA Tool Bugfixes:
- Swap strips operator crashed when it encountered an empty track
- Duplicating NLA strips was renaming the wrong strips - the old ones
would always get renamed, which was annoying
2011-01-20 09:26:36 +00:00
Campbell Barton
09ceb859b7 no functional change,
- remove G.flag, its not used anywhere (and confusing with G.f).
- also remove strcpy where memory locations may overlap.
2011-01-20 07:44:58 +00:00
Campbell Barton
ac058624ae fix for bug where python functions were not raising exceptions because reports were not added to the list in background mode. 2011-01-20 07:41:25 +00:00
Campbell Barton
287efe6036 don't set the path to ~/untitled.blend on initializing the WM, this isn't well defined how this behavior should work,
existing behavior was inconsistent since loading a new file would set the path to "".
2011-01-20 07:38:00 +00:00
Joshua Leung
6cadef1fb1 NLA backend code cleanups: Ensure all user-count management is done
via id_us_*() functions instead of direct access, for more security
2011-01-19 23:05:02 +00:00
Joshua Leung
677ed28b3e Bugfix [#25721] Unable to delete grease pencil data blocks
Missing check for id-block users before saving
2011-01-19 22:49:09 +00:00
Campbell Barton
f0d9ff34af Command line options to set blender system environment variables.
Added because CTest has no convenient way to set environment vars for commands it runs.

 --env-system-config -> BLENDER_SYSTEM_CONFIG
 --env-system-datafiles -> BLENDER_SYSTEM_DATAFILES
 --env-system-scripts -> BLENDER_SYSTEM_SCRIPTS
 --env-system-plugins -> BLENDER_SYSTEM_PLUGINS
 --env-system-python -> BLENDER_SYSTEM_PYTHON
2011-01-19 21:30:23 +00:00
Campbell Barton
e2f9006bd3 set variable as unused. 2011-01-19 19:58:44 +00:00
Ton Roosendaal
36852b98cb Bugfix #25613
Dropping file in Blender from pre 2.5 period caused eternal loop
loading .blend files :)
2011-01-19 18:07:13 +00:00
Ton Roosendaal
d0f4e7767e Bugfix #25720
Preview icons got lost... commit of yesterday caused it.
Conflict between preview render icons, and brush icons...
2011-01-19 17:10:05 +00:00
Ton Roosendaal
f49d7d59dc Bugfix #25652
Report was that move-to-layer menu failed. The real cause was
more complex; had to dive deep in the dungeons of the interface
code that handled undos and operators. Found several issues:

- popup menus (like redo operator, color picker) executed again
  on a mouse-exit
- far too many buttons were sending undo pushes; even worse, in
  the operator redo-panel each button action was pushed twice
- in case operator redo-buttons have own callbacks (like layer
  buttons) the redo wasn't working
- layerbutton menu was called without creating a proper undo/redo
  case

Things should all work smoother now!

On todo:
- better definition and handling of all versions for operator menus
  (four types now, not fun)
  also: make operator "do" menu, which on first action does operator
  and then switches to redo-ing
- bring back Undo menu, to list the undo stack and jump in it.
2011-01-19 14:19:20 +00:00