Compare commits

...

5075 Commits

Author SHA1 Message Date
bac64b39e9 Merging r39948 through r39988 from trunk into vgroup_modifiers. 2011-09-07 05:40:12 +00:00
9161d3ce4b use Py_ssize_t rather than int when dealing with list sizes (original patch from Fedora but applied changes elsewhere too), also replace PyList_Size with PyList_GET_SIZE where typechecking is already done. 2011-09-06 23:46:20 +00:00
Nathan Letwory
9baff83d72 Split off scene export code. 2011-09-06 22:18:12 +00:00
813d09cb59 BGE fix: ignore sounds that cannot be opened instead of crashing. ;-) 2011-09-06 21:02:26 +00:00
53671577a4 Fixed potential crash in NodeTagIDChanged. Discovered after merge trunk
into tomato where there were no check for tree before calling this function.
Old design worked fine with this.

Mark some arguments as UNUSED.
2011-09-06 18:15:34 +00:00
decc2c2e77 Node merge: fix crash loading files with unknown nodes (e.g. cycles files). 2011-09-06 17:34:56 +00:00
Lukas Toenne
f2e236e312 Enabled the 'Layout' node category, currently only containing the 'Frame' node. Both the category and the node could be renamed as needed. The frame node is largely experimental and not totally useful yet, but much asked for, so can't hurt to let people try it out. 2011-09-06 17:28:26 +00:00
5700b1b1b2 Fix missing warning message when reading files that are not forward compatible,
it seems this never worked in 2.5.
2011-09-06 17:27:18 +00:00
2ebc534900 Fix screen/scene browsing in info header not working right, mistake in code cleanup. 2011-09-06 17:18:50 +00:00
c8a092789f Node merge: some forward compatibility code to avoid crash loading files with
node groups in older version, and to keep unconnected/default socket values.
2011-09-06 16:51:10 +00:00
Lukas Toenne
84b8ec2ec3 Fix for node group add menu, groups from old files wouldn't show up there.
Reason was that node trees are now associated to specific node types (NODE_GROUP in particular) by the ntree->nodetype id.
2011-09-06 16:48:28 +00:00
Lukas Toenne
884fc84793 Fix for multiple parallel group node executions.
This would previously break because begin/end functions for each tree type still have some checks of the ntree->execdata pointer in them, despite the intended use of execdata instances instead of trees themselves for execution data storage. This is an artifact of the old execution system that required these checks to be made in the functions to avoid multiple execution of top-level trees. Now these functions take an additional argument, so group nodes can prevent them from setting and checking the nodetree->execdata pointers.
2011-09-06 16:32:51 +00:00
e79d16270b Ambient Occlusion:
* Increase max. samples from 32 to 128.
2011-09-06 15:44:44 +00:00
d4ce95d1dc Fix #28524: Push/Pull Assert when using Operator Panel to Alter Distance value
Some transform operators (like push/pull, shrink/fatten, to sphere and so)
were creating "value" as single scalar value. This used to confuse
RNA_float_get_array used in initTransform.

Use RNA_float_get_array for array values and RNA_float_get for scalar value
in transform initi function.
2011-09-06 14:59:55 +00:00
0c15f834e4 Fix for poly line grease pencil and surface drawing. 2011-09-06 14:02:28 +00:00
47ffe63c86 remove -Wundef for code we don't maintain & generated code. 2011-09-06 13:00:46 +00:00
Lukas Toenne
71abf218f0 Fix for wrong offset of the input socket column in group node tree display. 2011-09-06 11:42:20 +00:00
Lukas Toenne
c6002873fa Backward compatibility fix for SOCK_DYNAMICS flag on group sockets.
This is currently only needed for displaying the up/down buttons of group sockets. All regular group sockets should have this flag to indicate they are added by the user. More complex "group-type" trees may use non-dynamic sockets in the future for sockets that are not supposed to be manipulated.
2011-09-06 11:38:44 +00:00
aabd702dbd fix link issues with MinGW - a substitute declaration(correctByteOrder) for itoln that was not present in MinGW was being used. Duplicated the declaration from <winsock2.h>(tried including but gave some errors) and added the appropriate link library, wsock32, according to MinGW documentation. 2011-09-06 11:17:29 +00:00
7062788017 texture evaluation function (like we had in 2.4x api), requested by Lee.
eg:
 red, green, blue, intensity = texture.evaluate(vec)
2011-09-06 10:49:55 +00:00
32287bebe8 New grease pencil mode: poly line drawing
- It's like sketch mode for lines, but you're specifying line knots
  by clicking on position you want to add next knot.
- View can be navigated between knots creation.
- Holding LMB down and sliding mouse will lead to new segment preview
  so it can be created more accurate.

Additional change: fixed GP->Bezier conversion. Last point used to
                   be ignored in this operator.
2011-09-06 08:30:17 +00:00
Lukas Toenne
82f7a5e3a2 Fix for #28517, group nodes losing all links from older files.
The reason was that group nodes tried to reconstruct sockets from the template lists, which are empty. Now the verification function checks if there are any sockets in the template lists, which are always empty for group nodes.
2011-09-06 08:28:06 +00:00
c94fe5e299 Grease pencil: non-blocking sketch sessions
- Implement own undo stack for grease pencil, so now there'll be no keymaps conflicts.
- Supported redo's during sketch session.
- Get rid of flag stored in Globals -- use undo stack to check if grease pencil session is active.
2011-09-06 07:59:18 +00:00
a41f45946f fix for error in strinc.c's BLI_strescape 2011-09-06 07:08:20 +00:00
fa32395b33 more minor doc fixes 2011-09-06 00:41:28 +00:00
c643363905 svn merge -r39930:39947 https://svn.blender.org/svnroot/bf-blender/trunk/blender 2011-09-06 00:31:00 +00:00
67712c10c4 fix for doc building after pepper merge, also WIP tips/tricks. 2011-09-06 00:12:34 +00:00
bf5a6531a6 replace define '#if FFTW3==1' --> '#ifdef WITH_FFTW3' 2011-09-05 23:46:08 +00:00
0991bed413 fix some complier warnings and add -Wundef to CMake's default GCC warnings. 2011-09-05 23:40:52 +00:00
Nathan Letwory
0c992c73a1 Typofix 2011-09-05 22:15:07 +00:00
271f069b85 SVN maintenance. 2011-09-05 22:04:30 +00:00
Lukas Toenne
82f19e8df2 Fix for blender player linker bug, missing a stub function used in RNA. 2011-09-05 22:04:23 +00:00
Nathan Letwory
3efe867051 Put dead zone printout behind debug. 2011-09-05 21:52:06 +00:00
Lukas Toenne
8e0fe8bff7 Merged the particles-2010 branch with node improvements into trunk.
This branch adds mostly organizational improvements to the node system by renaming the node folders and files. A couple of internal features have been added too.
Detailed information can be found on the wiki page:

http://wiki.blender.org/index.php/User:Phonybone/Particles2010
2011-09-05 21:01:50 +00:00
Nathan Letwory
6e9ff495eb Add parser error handler.
OpenCOLLADA is a validating parser, so is pretty strict about document form. The added error handler will print out any errors the parser finds. A pop-up will be shown too, advising the user to check the console for the error log.
2011-09-05 20:41:58 +00:00
59a823c48a Code cleanup: remove context from RNA update functions, only one left. 2011-09-05 19:34:27 +00:00
a6d9a5a972 Code cleanup: warning fixes. 2011-09-05 19:27:21 +00:00
76ddf6d2ee Fix #28404: certain keyboard shortcuts not shown in menus, e.g. move operators
in graph editor > channel menu. Problem was these did not inherit operator
execution context correctly.

Fix found by Sergey, also needed to fix logic operators which were not working
when invoked instead of executed.
2011-09-05 17:57:04 +00:00
5a3c6ccadb Merging r39847 through r39930 from trunk into vgroup_modifiers. 2011-09-05 16:27:25 +00:00
419042af55 Fix #28394: clouds texture error with high noise depth and blender original
noise, patch from Campbell,
2011-09-05 16:25:42 +00:00
4393df9320 VGroup Modifiers: added mapping options to proximity and edit.
*Added Smooth/Sharp/Root/etc. mappings to WeightVGEdit modifier, in addition to custom curve one.
*Added Smooth/Sharp/Root/etc. mappings to WeightVGProximity modifier, without the custom curve one!
*Factorized the common mapping code into MOD_weightvg_util.
2011-09-05 16:16:00 +00:00
59dbd53e72 Fix #28389: UILayout.menu function didn't emboss menu button correct in the
3d view tools region.
2011-09-05 15:55:53 +00:00
Nathan Letwory
cc1c8268f7 Left debug print accidently enabled. 2011-09-05 15:03:31 +00:00
d91587752c Fix #28504: lib linking errors were not shown when opening a file from
the splash screen.
2011-09-05 13:19:19 +00:00
919bd181b7 Partial revert commit 39878 "Fix #28280: Insert Hook wrong index"
Such load/make edit structures introduced regression into iterators
via object's geometry (vertices, edges, control points and so) when
adding hooks in the body of this iterator.

Fix for wrong index should be non-destructable for geometry.

This will fix #28506: Unusual behavior in curves.
2011-09-05 08:20:11 +00:00
cc906e0e2a correct float -> double promotion warnings 2011-09-05 05:43:01 +00:00
3b09c331fa Adding noise module by default in driver_namespace
http://www.pasteall.org/blend/8677
2011-09-05 05:42:49 +00:00
e5209c2059 - vertex group modifiers isDisabled functions were incorrect, need to check if the string is set: == NULL will never be true.
- was doing NULL checks on freeing memory in cases where the values were already accessed (blender would have crashed anyway), so remove the NULL checks.
- use deform.c api weight functions to replace inline weight lookups in some cases.
- change if checks in weightvg_do_mask() so its more obvious whats going on.
2011-09-05 05:28:32 +00:00
2c740a9b5e rename vertex group mix "vgroup, vgroup2" to "vgroup_a, vgroup_b"
also clamp more values between 0.0 and 1.0
2011-09-05 04:53:23 +00:00
e8346fa84c simplify get_vert2ob_distance, mat4_to_loc_rot_size isnt needed. 2011-09-05 04:00:08 +00:00
1ba71e2caf change proximity method since minimum distance of 0.0 wasnt working at all. 2011-09-05 03:53:26 +00:00
5fd8ffd242 - mask_tex_map_obj --> mask_tex_map_object
- dont allow negative min distances
2011-09-05 03:26:49 +00:00
57411d1c5f minor edits.
- init proximity to 1.0f
- min/max proximity dist were not being copied.
- minor edits to comments - use ascii chars in a few places.
2011-09-05 03:09:49 +00:00
Nathan Letwory
5c5b9cf4d7 Remove NULL-checks, as they might cause infinite loops while reading a DAE containing unsupported data, i.e. <lines> geometry. 2011-09-04 22:14:28 +00:00
f1eab8e853 Fix #28503: Selecting a Grease Pencil from the Properties panel does not update 3D View
Added missing notifiers.
2011-09-04 15:53:12 +00:00
Nathan Letwory
1cada203bc [#27884] Collada import: materials mismatch when 2 instance_geometry reference the same material
Reported by David Roy

Multi-materials used on different meshes would get ignored (resulting in white faces in textured view).
2011-09-04 14:31:23 +00:00
7f5c5f8eca Fix #28500: Reshape in multires modifier makes blender crash
Multires doesn't store displacement for base mesh and reshaping when
multires subdivision level is set to zero is crappy.

Add report that reshape can't work with base level and cancel reshape operator.
2011-09-04 11:38:53 +00:00
317908a330 Fix #28423: Screw-modifier crash in cunjunction with subsurf modifier
Problems was caused by angle=2*pi and steps=2 in screw modifier.
Such configuration produced duplicated geometry to close object
and it was confusing for subsurf cache.

Restrict steps=2 for screw modifier now, so now 3<=steps<=512.
2011-09-04 11:13:41 +00:00
Nathan Letwory
caa1acb6b1 Prevent potential crasher, commonEffects could be empty. 2011-09-04 02:12:03 +00:00
103b06d4df BGE animations: fixing initialization order issues for BL_ActionActuator and BL_ArmatureObject. Thanks to z0r for pointing them out and providing a fix. 2011-09-04 01:42:47 +00:00
70e3541f3a BGE animations: Fixing a potential crash when using camera IPOs. The IPOs were being created off of blendercamera->adt->action when they should have been using the supplied action. Thanks to z0r for pointing out the problem and a potential fix. 2011-09-04 01:27:16 +00:00
Nathan Letwory
cbc812b757 Fix [#28322] COLLADA imports messed up UVs
Reported by Chad Gleason

Imported index order could put mface->v4==0. We already know amount of verts, so use that instead.
2011-09-04 01:13:44 +00:00
Nathan Letwory
1764f2135d Some whitespace changes 2011-09-04 00:15:59 +00:00
1f8291f78d BGE animations: Adding a separate list to KX_Scene for animated objects. This makes scenes with a lot of non-animated objects faster. In my test scene with 8000 static, non-animated cubes my time spent on animations went from 1.5~1.7ms to 0.001ms. 2011-09-03 20:48:47 +00:00
8295480bbe BGE animations: Fixing a crash that would happen if the property for a property mode action actuator was invalid. 2011-09-03 19:33:07 +00:00
451136e7c0 warning fixes 2011-09-03 15:36:36 +00:00
a01ffbbddb minor edits to build on openbsd 2011-09-03 09:43:20 +00:00
a6a14d0a1e == CustomData ==
* Added comments for each entry in the LAYERTYPEINFO array noting the
  number and name of the layer type; was hard to tell before which
  entry was what
2011-09-03 08:18:43 +00:00
8cc307b4f2 PyC_ExceptionBuffer is now threadsafe, used for converting exceptions into reports. 2011-09-03 06:46:31 +00:00
60dcfe2526 fix [#28462] Tiled textures and 2D filters don't mix
patch by Juha Mäki-Kanto
2011-09-03 04:44:18 +00:00
0cd5dce245 whitespace edits 2011-09-03 02:15:49 +00:00
8e3d1084b2 Fix for grid lines drawing outside of histogram widget. 2011-09-02 19:25:32 +00:00
5193526aeb Add missed notifier when toggling object's force field. 2011-09-02 18:05:07 +00:00
87cb3f8519 Fix crash caused by recently added assert about if string was set properly.
Memory Estimate is actually 31 characters length, str[31] is a null-terminator.

Return length of 31 for memory estimate property. Returning proper length
would lead to slowdown because of 2x iteration through vertices.
2011-09-02 17:58:09 +00:00
2fb2075c5b Fix #28280: Insert Hook wrong index
Use quite easy and stupid approach like it used for shape keys:
re-make editmesh (editcurve or editlattice) before creating index array
for hook or storing vertex index in parenting object.

Even if hook was added in "current" edit mode, it should be re-mapped on
loading edit data because topology could be changed after it was created.
Such kind of re-loading edit structures is the easiest way for now to
update keyindexes to relevant state.

Also, fixed bug with not re-mapping indices for vertex-parented objects.
Really old error, not sure why it wasn't noticed yet.
2011-09-02 15:19:30 +00:00
6b4bdf621f Fix #28467: Crash while deleting objects in outliner too fast
Cleanup tree when handling object delete from outliner.
Prevents handling the same tree item twice when clicking fast.
2011-09-02 13:23:44 +00:00
3386563368 Bugfix [#28435] Key Visual transform and Parenting not working
After reviewing this code, it seems that this case can work after all.
However, several things needed to be tweaked:
1) Removed check which stopped parented objects from getting the
visual keying coordinates determined. This actually wasn't doing
anything, given that this case would never occur as...
2) Tweaked the visualkey_can_use() function to also consider parenting
as a cause for visual-keying to be necessary.
2011-09-02 12:26:57 +00:00
15afd240e0 paranoid check that RNA string functions set the string, would have helped solve keymap search bug.
disabled in release mode.
2011-09-02 10:43:51 +00:00
7a496bfbcf Partial fix for #28441: Tab width in texteditor ignored if used tabs as spaces
Scroll to cursor when displaying text datablock was changed.
This behavior was lost in 2.5x.
2011-09-02 09:39:21 +00:00
612e2d4dbe patch [#28473] Outliner Simple Todo
from Julien DUROURE (julien)

---

* right click --> rename, as proposed on http://wiki.blender.org/index.php/Dev:2.5/Source/Development/Todo/Simple_Todos

* implementation of Toggle visibility/rendarability/selectability on right click on Groups ( was in menu, but not implemented )
2011-09-02 08:35:46 +00:00
8276989f63 fix [#28460] SEGFAULT when trying to make empty display as image 2011-09-02 08:20:30 +00:00
1d9ddcd319 tweak to WM_operatortype_find to perform better when called with empty strings (as the keymap editor does a lot) 2011-09-02 08:01:01 +00:00
e6ff3df5b9 fix for keymap search, was using uninitialized memory when the keymaps operator couldn't be found. 2011-09-02 07:51:19 +00:00
dc7f56455c fix for error in recent commit, when audaspace is enabled 2011-09-02 04:34:58 +00:00
4280e0a04f BGE animations: adding a missing comma. 2011-09-02 03:57:37 +00:00
dc463db6c2 Credits generator which cross references with the patch tracker to credit the original authors.
the script has a unix-name <> real-name mapping which is not totally complete since I couldn't find everyones real names.

In this case the commit name is credited.

Also added a link to the credits page in the splash.
2011-09-02 03:42:16 +00:00
1f7b41775b minor warning fixes, also correct some float -> double promotions in shadeoutput.c 2011-09-02 03:32:57 +00:00
99d5fa70de BGE animations: This is an attempt to help smooth out some more compatibility issues with the new action actuator. It now has a similar pulse behavior to the old actuator. This has worked well in most of my tests, but YoFrankie still has problems, and it appears to have gotten a little worse. 2011-09-01 21:47:46 +00:00
0f2be67bbf BGE: Undoing r39729 and applying a simpler fix (ensuring that the viewport is correct for PostRenderScene()). This way both 2d filters and post_draw callbacks with with multiple viewports. 2011-09-01 19:53:14 +00:00
e4fd20c20c Merging r39652 through r39842 from trunk into vgroup_modifiers. 2011-09-01 17:49:57 +00:00
f940e5fdd9 Feature Request #28449: Pose Library poses can be renamed from
Properties Editor
2011-09-01 10:56:16 +00:00
a8e49cd55a use a fixed 32byte buffer for getting an rna string from python. gives a slight speedup when drawing heavy UI's 2011-09-01 09:47:21 +00:00
473292dcd7 fix for building without audaspace, since pepper merge 2011-09-01 09:46:07 +00:00
255a81c3bf wip doc for py api tips and tricks. 2011-09-01 07:07:18 +00:00
2365c64014 whitespace bge edits 2011-09-01 02:12:53 +00:00
00143a3d55 spaces -> tabs (configure you're editors right!) 2011-09-01 01:48:50 +00:00
a22dc764bb fix for error in patch from r39821. 2011-09-01 01:13:50 +00:00
Dalai Felinto
22676a434e making carbon to build again (note: NDOF is not working here)
- fix typo
- isolate NDOF callsi in #ifdefs
2011-09-01 00:03:20 +00:00
1ad8ed8a60 BGE animations: Updating some constant names. They were still the originally proposed names instead of the ones that are actually used now. 2011-08-31 23:46:31 +00:00
812d5d2e5c BGE Animations: The return type for KX_GameObject.getActionFrame() was an integer when it should have been a float. I've fixed this and converted the tabs in the new BGE animation docs to space. I have also added more info on return types for KX_GameObject.getActionFrame() and KX_GameObject.isPlayingAction(). 2011-08-31 22:32:14 +00:00
d8394b9d67 set OSX default python to static 2011-08-31 14:46:27 +00:00
5e8d191930 OSX/scons: fix compile with static python, my patch was a bit outdates, sorry 2011-08-31 14:15:14 +00:00
fde215025e patch [#28218] During-render callback functionality
from Jesse Kaukonen (gekko) 

--- text from the patch.

Recently Campbell Barton added callback functionality for Python's usage, but this only includes pre- and post-render callbacks. There are no callbacks for the duration of the render. This patch adds the few lines required for executing a callback while Blender Render is working. The callback resides in the rendering pipeline stats function, so whenever statistics are printed, the callback is executed. This functionality is required if one wants to:

1) Observe what is happening while Blender is rendering via the command line
2) Add custom statistics that Blender prints while the renderer works
3) The user wants to continue executing his Python script without the code halting at bpy.ops.render.render()

Personally I'm currently using this for printing out more detailed progress reports at Renderfarm.fi (such as CPU time, time spent rendering, total progress in regards to the entire rendering process). Tested on Windows, Linux and OS X.

Example on how to use the callback:

  def statscall(context): print("Thanks for calling!")
  bpy.app.handlers.render_stats.append(statscall)
  bpy.ops.render.render(animation=False, write_still=True)
2011-08-31 10:43:22 +00:00
Nathan Letwory
d0d82c69e9 COLLADA: Take parent bone length and direction instead of using bone pointing up with length 1. Looks much nicer and less confusing on larger armatures now. 2011-08-31 09:37:14 +00:00
f63d049adc BGE: Adding two new functions to bge.render to allow users to change the anisotropic filtering level used by textures:
* setAnisotropicFiltering(level)
  * getAnisotropicFiltering()
2011-08-31 05:51:51 +00:00
471c005137 typo fix: end of lines ;; --> ; 2011-08-31 01:07:55 +00:00
79249f8aed fix [#28430] Image with Stampinfo does not get saved correctly with alpha 2011-08-31 01:05:40 +00:00
2457c2134a OSX: additionally choice to link against python-framework again 2011-08-30 23:52:12 +00:00
2883e035c8 fix for error in my recent change to image save.
- relative path wasn't being made absolute.
- saving renders was always defaulting to multilayer exr, now use the output format set.
2011-08-30 23:37:46 +00:00
c58a0c5eb8 catch exception and report an error when failing to write exr files - was crashing with debug builds. 2011-08-30 23:08:38 +00:00
5ac81bfe9c SVN maintenance. 2011-08-30 19:38:32 +00:00
2475ad0ab9 When creating a multisample window for Win32, the first context created, which checks for multisample support, was never being deleted. 2011-08-30 17:30:35 +00:00
Nathan Letwory
c6f994062e Check for potential crasher.
Reported and suggested in [#27687] by Dean Giberson. Couldn't redo crash myself, but better safe than sorry :)
2011-08-30 15:43:00 +00:00
9eb9d9b7d2 Fix #28427: smooth faces flash momentarily when extruded using "extrude and move on normals" tool (E key)
Update normals just after extrude -- topology is changing when extruding
and normals for non-extruded faces should be recalculated after this.
2011-08-30 15:30:38 +00:00
131c2a3208 Fix for [#28425] when user prefs -> editing -> align to == "view" newly inserted objects do not show the applied rotation in the tools panel
Patch by Andrew Wiggin, thanks! :)
2011-08-30 14:41:23 +00:00
0de9af375b 2.5 Game UI:
*Fix for clutter after pepper merge, 3 booleans in one row, is 1 too much here ;-)
2011-08-30 12:45:56 +00:00
Nathan Letwory
24ea5fe424 Enable libsndfile by default on win32 too. 2011-08-30 12:40:15 +00:00
047e8224b1 Fix for my last commit. 2011-08-30 11:31:48 +00:00
b20c9b0ba3 minor edits, pep8 - also correct float -> double promotion for blf. 2011-08-30 10:49:58 +00:00
6c9ee34dd8 2.5 UI Files:
* Code cleanup after Pepper merge.
2011-08-30 10:44:02 +00:00
947d4a654b Fix for [#25062] Sound Actuator - Positional Audio.
Now all sounds that are not mono but have 3D checked automatically get reduced to mono during BGE conversion time.
Also removed the now unneeded function sound_get_channels and added a missing header file to audaspace's CMakeLists.txt.
2011-08-30 10:09:10 +00:00
b3704f45c4 Fixes for snprintf usage:
* replace by BLI_snprintf in various places, note _snprintf on windows
  does not properly null terminate the string.
* fix overflow in sequencer proxy code due to buffer being smaller than
  specified size.
* fix some usage of snprintf as strcpy, this is will go wrong if the
  string contains % characters.
* remove BLI_dynstr_printf function in gpu module, use BLI_dynstr_appendf
2011-08-30 10:07:50 +00:00
27ec8d5043 fix for some warnings with the recent merge, also tag unused args. 2011-08-30 09:50:31 +00:00
c7dcbdb830 Removing outdated files. 2011-08-30 09:26:59 +00:00
9424b1ceff Merging pepper to trunk at revision 39791.
Important note: I used rsync to do the local merge, as "svn merge --reintegrate ^/branches/soc-2011-pepper" doesn't work with our svn server right now!
2011-08-30 09:15:55 +00:00
43ab8e8624 * Merge trunk up to r39790.
* Subversion bump (also for init_userdef_do_versions).
* Minor fix for compilation without ffmpeg.
2011-08-30 08:22:03 +00:00
5b5e600db6 Last bunch of minor fixes before merge.
* Use NULL in AUD_Reference.h
* Use SETLOOPER in sound.c
* Move flags to the end of Speaker struct.
2011-08-30 07:57:55 +00:00
d049a722fe fix [#28413] bpy.ops.nla.bake can't bake from frame 0 2011-08-30 04:13:48 +00:00
099760cf1f Fix #28295 Outliner, mouse button on menu's pass through.
It was introduced in rev33603 with not good patch -- release event
was catching by outliner after clicking on menu item.

Use KM_CLICK instead of KM_RELEASE to deal with icon drag/drop.
This not changes drag/drop behavior, but prevents unneeded event be handled.
Also make consistent behavior of activating and extending selection.
2011-08-29 17:46:07 +00:00
88a538048b Fix #28347: VBO's highlights wrong faces when Mirror modifier is in use
Added callback to drawMappedFaces which checks if two faces have got equal draw options.

After discussion with Brecht we found it's nicest solution for now:
- Disabling VBOs in edit mode for this case wouldn't be nicer for this case -
  some additional flag stored in DM should be added in this case.
- Adding new callback in DM isn't nicer that this solution.
- Handling face selection in drawobject would lead to duplicated code
  which is also not nice.

Hopefully, this callback could handle all cases in the future.

Also, Brecht mentioned current VBO implementation isn't perfect, so maybe
when we'll redesign this area dealing with edit mode wouldn't be so tricky.
2011-08-29 16:07:44 +00:00
5bac37f6d4 * Reverting Titlecard commit r37537
* Reverting update recent files commit r37155
* Turning reference counts into unsigned ints
* Minor things
2011-08-29 15:01:55 +00:00
6cf447a29c Fix player build error after envmap commit. 2011-08-29 12:57:46 +00:00
296cc41b03 BGE Animations: Various changes to make code reviewers happy:
* Naming/style changes
  * Taking advantage of switch statements
  * Removing unneeded NULL checks
  * etc
2011-08-29 06:19:55 +00:00
Dalai Felinto
ea07e367c5 bge bugfix: [#28362] Controllers names appear incorrectly with a python query
the uniquename was never fully implemented for sensors and actuators, only for controllers.
at some point we either get rid of all of them, or bring them all on.

For now removing the "unique name" of controllers
2011-08-29 03:20:15 +00:00
c1eb0c3783 clear some warnings with new proxy code. 2011-08-29 01:00:14 +00:00
f712234009 SVN maintenance. 2011-08-28 23:44:43 +00:00
0e01fa4863 patch [#28355] Better Environment Map scripting
from Tom Edwards (artfunkel), with minor edits.

This patch makes the following improvements to environment map scripting:

* Adds a "is_valid" RNA property to envmaps. True if the map is ready for use, False if it needs rendering.
* Adds a "clear" RNA function to envmaps. Deletes any envmap image data.
* Adds a "save" RNA function to envmaps. Writes the envmap to disc with a configurable layout. (Defaults to the current hard-coded layout.)
* Updates bpy.ops.texture.envmap_save with configurable layout support as above.

These changes, particularly configurable layouts, make exporting envmaps to other software much easier.
2011-08-28 23:24:34 +00:00
c31b776dc9 SVN maintenance. 2011-08-28 21:48:52 +00:00
3dc817840b fix [#28401] OpenGL render option disables border clipping 2011-08-28 21:13:03 +00:00
80459d97c7 == Sequencer / proxies ==
fixed crash pointed out by blendervse:
100%-proxy could lead to a segfault under certain conditions.
2011-08-28 19:58:33 +00:00
28feca36d7 Missed notifier was found when looking at #28393 2011-08-28 18:54:02 +00:00
ca79dee61f armature object animation bug fix. 2011-08-28 18:30:18 +00:00
c07bd1439a == Sequencer ==
This patch adds:

* support for proxy building again (missing feature from Blender 2.49)
  additionally to the way, Blender 2.49 worked, you can select several
  strips at once and make Blender build proxies in the background (using
  the job system)
  Also a new thing: movie proxies are now build into AVI files, and
  the proxy system is moved into ImBuf-library, so that other parts
  of blender can also benefit from it.
  
* Timecode support: to fix seeking issues with files, that have
  a) varying frame rates
  b) very large GOP lengths
  c) are broken inbetween
  d) use different time code tracks
  
  the proxy builder can now also build timecode indices, which are
  used (optionally) for seeking.
  
  For the first time, it is possible, to do frame exact seeking on
  all file types.
  
* Support for different video-streams in one video file (can be
  selected in sequencer, other parts of blender can also use it,
  but UI has to be added accordingly)

* IMPORTANT: this patch *requires* ffmpeg 0.7 or newer, since
  older versions don't support the pkt_pts field, that is essential
  for building timecode indices.
  
  Windows and Mac libs are already updated, Linux-users have to build
  their own ffmpeg verions until distros keep up.
2011-08-28 14:46:03 +00:00
b4b046995b * Removing mocap GSoC (is an addon already).
* Fixing ffmpeg-0.8 errors.
* Fixing Ketsji paths.
* Removing DoSound from BGE.
* Fixing audio scene update to use only current scene objects.
2011-08-28 14:21:44 +00:00
8e12b7b054 Assorted comment clarification in response to code review notes 2011-08-28 11:39:18 +00:00
852a03a6af RNA_property_as_string now escapes the string (so operator redo can include strings with ", \n etc), also fixed a bug in string escape length limit. 2011-08-28 09:28:41 +00:00
fa2ba5fbf5 - use static vars and functions where possible.
- use NULL rather than 0 when used as pointers.
2011-08-28 05:06:30 +00:00
c73d5b939d check for unlikely error when freeing a library blend file from the BGE. 2011-08-28 05:01:16 +00:00
81ea1e7fcb remove implicit casts to doubles in the noise code, also use floating point math functions rather then double since the noise functions range is already limited by casting to ints in many places.
- gives a very small speedup.
2011-08-28 02:54:26 +00:00
4684df0830 fix [#28388] Clouds at high depth give artifacts.
http://projects.blender.org/tracker/download.php/9/498/28388/17476/screen_bad.png
2011-08-28 02:04:40 +00:00
752cb7485d Do not show confirm message when creating text block from menu. 2011-08-27 12:01:01 +00:00
01230b1374 fix [#28373] "Lock camera to view" doew not work with 3D-mouse 2011-08-27 11:52:59 +00:00
a347f0267b Fix [#28341] writing }(alt+n) in text editor creates a new file
Change hotkey for new textblock to Ctrl-N.
2011-08-27 11:41:48 +00:00
681d073d94 mistake in own recent commit broke op[encollada with mingw 2011-08-27 08:19:26 +00:00
909d74d124 - use python convention for headings
- use implicit examples rather than .. code-block::
2011-08-27 08:09:12 +00:00
cd0e92c5b7 fix for building with msvc, ssize_t is more correct but in this case its not going to give issues. 2011-08-27 07:06:44 +00:00
2e8771e987 bpy Gotcha's section on bones by Bassam Kurdali, with some edit.
added some examples & notes too.
2011-08-27 07:05:04 +00:00
ca1e9d2c18 replace octal 0177 with 127 to be more clear, no functional change. 2011-08-27 03:34:11 +00:00
c96f28a718 - use %u rather tham %d for unsigned ints in string formatting funcs.
- replace (strlen(str) == 0) with str[0]=='\0'
2011-08-27 03:25:02 +00:00
6926060185 - fix for BL_Shader::SetUniform() missing out the last part of the matrix.
- particle.c wasn't setting all components of the vector when reading cache and setting dummy velocity values.
- some functions incorrectly took a float[3] argument when the 4th value was set.
- remove a few redundant lines of code.
2011-08-27 03:20:32 +00:00
555f6cbe08 BGE: Post drawing callbacks are now done per viewport instead of per scene. This is handy for things like having a different HUD for each player in a splitscreen game. To figure out what viewport you're drawing too, check the scene's active_camera. 2011-08-27 03:19:46 +00:00
94b3e83b6c fix for bug with all rotation modes being treated as euler by the BGE, this bug is in trunk too but fixing here because this code will replace whats in trunk.
also make initializers less verbose for ipo transform assignment.
2011-08-27 03:13:54 +00:00
70c955c484 remove deprecated & unused sequencer transform vars 2011-08-27 02:59:43 +00:00
95c5611570 subtraction on unsigned values didnt work as intended for copying ID's. 2011-08-27 02:45:35 +00:00
9ae67bf380 bugfix for procedural textures used as bumpmap with osa not rendering right, also remove redundant assignment. 2011-08-27 02:04:29 +00:00
a05d4a729a remove deprecated & unused mat3_to_vec_rot and mat4_to_vec_rot functions. 2011-08-27 01:42:49 +00:00
974a06823e bge py api XK_GameObject.linVelocityMin was returning linVelocityMax. 2011-08-27 01:37:47 +00:00
2311e624d7 eek F4TOCHAR4 was assigning alpha twice too!, tsk tsk. 2011-08-27 01:24:05 +00:00
7c02ca7e8c F3TOCHAR4 macro was assigning the same value twice (setting the alpha, then overwriting with 255). 2011-08-27 01:20:55 +00:00
722be28d68 sub_v4_v4v4 was taking float[3] arguments. 2011-08-26 22:37:20 +00:00
a9dea3afe9 correct missing bpy doc references. 2011-08-26 18:48:48 +00:00
f10f4f570d added a section to gotcha's python bpy docs about unicode encoding problems. 2011-08-26 18:32:23 +00:00
8a619a3eee fix for crash when running a python script in a non utf8 blend path, inspecting the exception for the path assumed utf8. 2011-08-26 17:55:03 +00:00
1439ddccae Fix #28301: Sculpting a object with rotational have desface
Patch from Juha Maki-Kanto

- initgrabz was called with local space coord.
- Brush radiu was multiplying by 2.0 for grab and snake brushes.
  Not sure why this was needed. Made some tests and didn't notice
  any regressions without this multiplication.
2011-08-26 16:38:23 +00:00
cdbb904b32 code review fixes 2011-08-26 15:16:27 +00:00
1273a1133e Fix #28370: border select for curve and metaball did not update number of
selected vertices in info header. Patch by Julien Duroure, thanks!
2011-08-26 11:35:33 +00:00
e5ddaefecc when applying armature object transform now transform the bone roll too.
This means you can import a BVH, rotate 90d and apply the rotation, the animation will still work as expected - thanks to Benjy's script for showing how obvious it is that this works :)
2011-08-26 06:22:12 +00:00
e9ca846018 document some of the pitfalls in the blender python api (taken from frequent mails and bug reports) 2011-08-26 04:00:55 +00:00
566da26173 file-selector: when converting operator arguments to the file selector, wasnt making paths absolute (abs paths are made relative when converting the other way). 2011-08-26 01:32:07 +00:00
291ae8822d executing operators that changed the context from the console wasnt returning an operator set/flag. 2011-08-25 17:59:37 +00:00
9436769cd4 error when a python operator gave an incorrect return value was near useless, re-raise a more comprehensive error which includes the operator name. 2011-08-25 17:54:30 +00:00
166970f68e bpy-rna - simplify enum string/set parsing. 2011-08-25 17:01:33 +00:00
a244a787de sanity checks on operator exec/modal/invoke return values. 2011-08-25 16:42:42 +00:00
88ba2504c7 Fix for [#28304]
Show A: and B: drives in Windows file browser.
2011-08-25 16:41:08 +00:00
b7eac1edcf picky style edits with screen/view/drawing, also remove own bad example doc. 2011-08-25 15:49:52 +00:00
b44a82f3c4 ups, syntax error, missing : 2011-08-25 15:18:54 +00:00
d833d15608 OSX: refine logic for NDOF, if WITH_BF_3DMOUSE is disabled also never do weak-link framework, existing or not 2011-08-25 15:12:57 +00:00
8b6dfade4d OSX: fix condition for NDOF linking 2011-08-25 14:49:47 +00:00
3b1192431f OSX/scons: don´t link to system stubs with 10.7 sdk 2011-08-25 09:41:36 +00:00
44f7a8aee2 Fix for [#28239] Particles Billboard 3x3 Split Error.
* Patch by Alex Fraser.
2011-08-25 07:30:12 +00:00
38398d200f SVN maintenance. 2011-08-25 06:16:26 +00:00
50a9454e0f move wiki api intro and overview docs into the api reference docs.
Updated docs since some parts still were from beta still.
2011-08-25 04:25:33 +00:00
5f66f37e22 Patch for bug #28289
updated the logic behind node delete with reconnect.
When on input and output socket is connected, these two will be reconnected
see bug report for example.

http://projects.blender.org/tracker/?func=detail&aid=28289&group_id=9&atid=498
2011-08-24 20:48:37 +00:00
7fc26e0123 Committing patch #25675 "Make "Cast Buffer Shadows" option work in viewport and BGE" by me.
Description from the tracker:
"It's really handy to be able to prevent an object/material from casting a shadow. So, I made use of the Cast Buffer Shadows option in the material settings, and made it work in the viewport and the BGE."
2011-08-24 20:28:54 +00:00
81a8f3e885 part of a patch from Dan Eicher for cmake packaging. 2011-08-24 18:23:21 +00:00
18d66643f4 this should finally fix collada & ubuntu building with cmake 2011-08-24 18:13:11 +00:00
242035fa2d attempt to fix issue with opencollada + ubuntu ppa 2011-08-24 17:09:25 +00:00
9ad6434c4e opencollada find module. hopefully solves the problem where includes can in an /include subdir or not. 2011-08-24 16:04:35 +00:00
82e622f158 fix [#28356] Import export STL files, problem in script in version r39307
& correct some bad comments.
2011-08-24 14:22:41 +00:00
f9bffb3ca0 fix [#28340] Can't set image depth, quality from image save 2011-08-24 00:44:58 +00:00
3bb397be76 fix [#28351] active RenderLayer can be set to None, leading to crash 2011-08-23 20:54:44 +00:00
a35b3c5b50 fix [#28352] Deleting group name in particle system -> panel: Render crashes Blender 2011-08-23 20:49:06 +00:00
8470418b91 cmake: skip rpath (paths to libs) for portable distrobution 2011-08-23 20:19:08 +00:00
9a9513a9f0 fix for 3 bugs in bone renaming
- renaming a bone could crash if the area had to spaces in it (reported by Sebastian Koenig).
- renaming bones wouldn't  update inactive 3d views locked bone names.
- selecting locked bones in the UI didnt work in editmode.
2011-08-23 19:58:15 +00:00
f6a2b8d724 BLI_strescape for a basic, python like string escaping, currently only use for drag and drop ID's into the console but should eventually be used for the animsys too. 2011-08-23 15:08:54 +00:00
abff0032c4 Fix #28343: glsl error after derivative maps commit. 2011-08-23 13:15:18 +00:00
e890469073 Merging r39486 through r39651 from trunk into vgroup_modifiers. 2011-08-23 12:45:35 +00:00
cd6f93bdc9 vgroup_modifiers: Definitively removed addtionnal mapping/clamping options in WeightVGEdit mod, including from DNA struct. 2011-08-23 12:33:45 +00:00
6fd68b8d76 fix [#28336] Particles: setting to zero the count of all elements of a group crashes Blender 2011-08-23 12:09:20 +00:00
ba4fd78fac fix [#28344] for this file, the multires smiley has 2 materials, but only 1 loads 2011-08-23 11:46:16 +00:00
ff8daca1f1 Bugfix: Removing a sound from a speaker resulted in a crash. 2011-08-23 11:44:24 +00:00
75a63981cd add warning about misuse of ID.user_clear() since it can crash blender. 2011-08-23 11:28:18 +00:00
ce9e4472eb Make Ctrl+RMB in editmode behave like 2.4x, was re-using center option which worked but used center select too.
instead add 'object' option to VIEW3D_OT_select.
2011-08-23 09:05:12 +00:00
ed3d253c56 Fix for [#28339] Rev:39618 The revision part doesn't suffice.
NAN_BUILDINFO > WITH_BUILDINFO change from rev 39618 was missing in those files.
2011-08-23 08:02:48 +00:00
34b7bff44b change compression level for gzip saving to 1, approx twice as fast when saving a 194mb blend file and only slightly bigger. 2011-08-23 07:59:25 +00:00
4740dce4ec Revert a part of 39385.
Vertex Select Button got somehow into the Mesh panel.
2011-08-22 22:26:25 +00:00
f0d5abfcb2 Merging trunk up to r39637. 2011-08-22 20:31:46 +00:00
1d529d83a0 Missed a file in last commit. 2011-08-22 19:58:34 +00:00
6a374d266d glsl and render support for derivative maps 2011-08-22 19:57:54 +00:00
0e3b8ff6a5 Update rules for linux cross and mingw: list of DLLs for FFmpeg should be defined there. 2011-08-22 19:27:54 +00:00
c33e0c053a fix for buildinfo changes with blenderplayer 2011-08-22 19:13:26 +00:00
e39cb8a040 Forgot this in previous commit 2011-08-22 19:00:32 +00:00
a71c215f22 3D Audio GSoC:
Final GSoC commit.

* Bugfix: Negative frames crashed
* Bugfix: JOS sample buffer size prediction error (wasted memory)
* Optimisation: for JOS upsampling (around 12 % difference measured here)
* Optimisation: Better filter for JOS resampling
* Bugfix: Error in relative 3D audio code.
* Removed Attenuation
* Bugfix: Multiple scenes in BGE lead to errors, BGE audio now all relative, to support multiple scenes.
2011-08-22 18:59:56 +00:00
a9d9a8e569 actually, this if is still marginally good to have 2011-08-22 18:56:13 +00:00
a33a26ca07 FFmpeg library update:
- Update scons/cmake rules to use new versions of libs/dlls.
- Update rules for buildbot.
2011-08-22 18:49:42 +00:00
a937729f38 properly escape chars for pythons bpy objects __repr__ 2011-08-22 18:13:37 +00:00
7d316b70b8 rename NAN_BUILDINFO --> WITH_BUILDINFO 2011-08-22 16:54:26 +00:00
817273931a buildinfo is now quoted from the build systems, avoids stripping quotes on startup.
tested with linux/cmake linux/scons windows/cmake/mingw windows/cmake/msvc
2011-08-22 12:24:14 +00:00
5394cabe24 remove workaround for bug in python 3.2.0 loading web pages on *nix 2011-08-22 11:54:40 +00:00
ee40894c05 Bugfix [#28217] Moving multiple selected action strips causes strips
to scale towards zero

This is an attempted bugfix for a bug which seems to be very fickle to
reproduce (it only happens sporadically after quickly jerking the
strips around in a certain way). So far when testing, I haven't had
any more problems after applying this fix, though it may just be
unreliable testing.
2011-08-22 11:51:23 +00:00
1324173e99 pep8 edits and change '!= None' to 'is not None' 2011-08-22 09:01:49 +00:00
aa7545b0ea patch [#28320] Small change to trunk needed for Motion Capture Addon - GSoC 2011 - Pepper Branch
from Benjy Cook (benjycook)
2011-08-22 08:47:48 +00:00
a594196dc0 Bugfix: "Filters" toggle was being shown in Action Editor too, where
it was irrelevant
2011-08-22 02:30:43 +00:00
06ae5e4825 Reshuffling DopeSheet filter icons so that they appear more obviously
related to each other
2011-08-22 02:14:39 +00:00
2b0127a0c5 Rearrange anim channels - quick hotkey tweak
Use PageUp/Down for moving up/down, and Shift PageUp/Down for moving
to top/bottom. This is more comfortable than the old combinations
involving shift+ctrl.
2011-08-22 02:01:22 +00:00
cb05e40540 Improved hotkeys for frame/keyframe/jumping
Thanks pepeland and 3duan for the suggestions. I've been looking at
improving these for a while...

* Left/Right Arrow = Single Frame stepping as before
* Up/Down Arrow = Jumps to next/previous keyframe (used to be the
uncomfortable Shift PageUp/Down)
* Shift Up/Down Arrow = Jumps forward/back in 10 frame increments
(used to be Up/Down Arrows). 10 frame increment should get
customisable again as in 2.4, but need to find some UI space to put
that!
* Ctrl Shift Up/Down/Left/Right = Jump to start/end frame (used to be
Shift <Arrow Key>)
2011-08-22 01:22:14 +00:00
17c8621cc8 fix [bf-blender-Patches][27924] Redundant applying of SetNetworkDevice
noticed by Jorge Bernal (lordloki)
2011-08-21 21:17:55 +00:00
826614d66e name mandatory driver for OSX NDOF compile - testcommit same time 2011-08-21 21:11:26 +00:00
6b99cd05aa Armature object animations export. 2011-08-21 15:47:21 +00:00
4f75566672 export animations if a bone is in a deform group. ( on hold ) 2011-08-21 13:51:04 +00:00
36f20f162c Fix #28154: linux3-config.py doesn't exist
Change OURPLATFORM from "linux<major_version>" to simple "linux".
Since new policy for linux kernel versions that major version in
platform doesn't make much sense for building rules so the same
rules could be used for both of linux2 and linux3 now/

Tested on both of linux2 and linux3 systems.
2011-08-21 13:31:46 +00:00
ee938c3be8 Bugfix [#28309] pose lib too many keyframes in automatic keyframing
mode

Pose Library was checking in wrong place for what was selected and
what wasn't when determining what should get autokeyed.
2011-08-21 13:25:56 +00:00
4427c14683 Small fix, report in IRC by Olivier:
Click in Compositor on output node invoked a re-composite.
Only has to be done for inactive outputs.
2011-08-21 13:25:19 +00:00
bebee3fb60 new cmake doesn't consider CLang == GNUCC, set flags for clang explicitly. 2011-08-21 11:06:49 +00:00
8fcc8dd776 fix for out of bounds array access for shaded drawing in the UI, remove alpha blending for uiDrawBoxShade and uiDrawBoxVerticalShade. 2011-08-21 10:14:21 +00:00
be25346da6 Bugfix [#28308] Crashes when individual channels are moved in Action
Editor
2011-08-21 07:08:15 +00:00
f8ec017900 floats were being promoted to doubles in quite a few cases (using gcc's -Wdouble-promotion), went over render module and use float constants, gives small but consistent speedup - approx 3%. 2011-08-20 17:39:13 +00:00
bcadb6b939 small fixes and refactoring. 2011-08-20 16:48:53 +00:00
d4dec1c3bc use ghash for DNA_struct_find_nr(), gives ~18% speedup on loading sintel lite, will also speedup undo.
note: only works with CMake, wasn't able to get this working with scons, complains about same file being built in different environments.
2011-08-20 14:23:43 +00:00
a0a96a84fe fix for crash when loading a file from a script, and executing user modules in the newly loaded file. 2011-08-20 13:29:42 +00:00
5d88ba6165 remove over zealous undo's on operators that don't need it. 2011-08-19 20:25:25 +00:00
90d19ad883 py style change only - make property definitions consistent 2011-08-19 19:25:20 +00:00
3a81f23e09 warning cleanup for -Wdouble-promotion 2011-08-19 16:21:29 +00:00
ac3d785caa Animation exporter matrix source param fix. 2011-08-19 14:29:33 +00:00
2c1182664c minor speedup to python/rna api keyword argument lookups.
- dont use hash lookups in this case because converting the string to unicode and doing a hash lookup is slower then looping over the keys and comparing (which avoids creating and throwning away a unicode string).
2011-08-19 10:38:34 +00:00
561b49e925 minor style change 2011-08-19 10:35:47 +00:00
Nathan Letwory
c646519776 Export only objects on visible layers. This ensures we can hide for instance bone shapes. 2011-08-18 22:56:41 +00:00
0de9112102 store a pointer to the units system in the uiBlock since the button code was doing context lookups for the scene quite a lot. 2011-08-18 20:01:30 +00:00
2ee74be88c Blender tip profile for bones with 2 or more children. 2011-08-18 19:16:36 +00:00
042d4d3509 misc changes to unterface & undo
- operator strings were doing undo pushes (in fileselector text for example), this is dumb since the operators themselves handle undo.
- interface code checks rna props are arrays rather then checking the array length.
- disable properties window pin undoing.
- sequencer refresh was calling undo, disable since this is clearnign global data not handled by undo.
- added commented out code for drawing mesh vertex index/key index, useful for debugging shapekey - hook issyes.
2011-08-18 19:07:37 +00:00
238955070b minor change for operator OUTLINER_OT_item_activate
Noticed clicking anywhere in the outliner was doing undo pushes, even in empty areas.

- check if any selection is made before redrawing.
- don't do an undo push when selecting outliner items since only screen data is touched here.
2011-08-18 18:42:42 +00:00
ccdec67fec bugfix: genx and geny are not the image resolution. Texture space variant needs this. 2011-08-18 17:25:54 +00:00
39a46cd4ed disable undo for hard coded interface buttons:
- space type switcher.
- header menu toggle.
- properties window header buttons.
- various view3d manipulator buttons.
2011-08-18 17:09:23 +00:00
00426038d0 disable undo for screen & wm RNA buttons, changing shading mode via the UI for eg was doing an undo push. 2011-08-18 16:26:34 +00:00
feb8318143 fix for undo issues with generic, multi-purpose WM_OT_context* operators, operators now check if they modify certain ID data (not screne, wm, brush or scene) and only do undo in those cass.
- Zkey to switch shading was pushing undo's.
- Wkey to interactively edit camera, lamp settings wasnt doing an undo push when it should.
- Toggling settings (such as bone boolean options) now skips an undo push if there are no items selected.
2011-08-18 16:01:11 +00:00
aa4d5ccbed more minor changes to wm.py, get data_path's once at the start of each func and some minor style changes. 2011-08-18 15:25:18 +00:00
2bd016fe3f formatting edits, no functional changes. 2011-08-18 12:20:10 +00:00
83c090a555 fix for bad array access in transform operator, was assigning an array to a single float operator value. 2011-08-18 12:09:53 +00:00
Nathan Letwory
475e0b8c02 Apply [#28287] COLLADA fix for inverse bind matrix of skin controller
Patch by Pelle Johnsen
2011-08-18 09:14:27 +00:00
2dee23fad4 vgroup_modifiers: Minor update (names...). 2011-08-18 06:30:59 +00:00
591b087204 Fix for [#28216] particles objects rotation still wrong with r39287
* The emitter object's inverse matrix wasn't in global coordinates during rendering, so the surface normals of the hair emission locations were transformed with the wrong matrix.
2011-08-18 02:12:23 +00:00
5c20bc02ff BGE: Upon further investigation this should have been 8 since up/down and left/right both are just one axis each. So, in actuality, the number of directions = 2, not 4, and thus JOYAXIS_MAX/directions = 16/2 = 8. 8 was also the max used in 2.4x. 2011-08-17 20:44:15 +00:00
14d2d7c75f BGE: Upping the max Axis Number for the Axis event type on joystick sensors from 2 to 4. The BGE supports up to 16 axis. For Axis events (not Single Axis), you get for directions per axis (up, down, left, right). So, the max should be JOYAXIS_MAX/directions = 16/4 = 4. 2011-08-17 20:17:27 +00:00
a46f36c9b6 Animation export id bone animation + armature importer cleanup. 2011-08-17 20:15:40 +00:00
e86e922f5b Armature importer code cleanup. 2011-08-17 18:29:01 +00:00
f3c05e8eb2 armature animation export fix. 2011-08-17 18:28:01 +00:00
1719963a08 Fix #28207: animating pin option for cloth didn't work, solver doesn't support
it, so set the property as not animatable.
2011-08-17 15:55:42 +00:00
37f9d916fa Fix #28265: blender 2.59 not starting on OS X with old ndof driver.
Patch by Jens Verwiebe.
2011-08-17 15:01:26 +00:00
feb7afe671 Fix #28262: uv unwrap in sync selection mode unwrapped all faces irrespective
of selection. Changed the fix for bug #27198, live unwrap not working with
sync selection.
2011-08-17 14:43:11 +00:00
58af2c36ac vgroup_modifiers: Removed (commented out, for now) addtionnal mapping/clamping options in WeightVGEdit mod, leaving the only curve mapping stuff.
Also, updated all three modifiers with new foreachTexLink walking func.
2011-08-17 13:07:51 +00:00
8536209260 2.6 RNA:
* Remove some NULL RNA property update calls, they do nothing.
2011-08-17 13:04:28 +00:00
b6dcf3b1c2 Fix #28277: changing smoke border collision type did not reset cache, making
it seem like the option wasn't working.
2011-08-17 12:52:38 +00:00
0bac3e17df Fix #28194, #28269: proxy object was not showing pose mode as available in
3d view header mode menu.

A recent bugfix was incorrectly hiding pose and particle mode when the object
data was library linked, but these modes edit object level settings so should
be available.
2011-08-17 12:09:02 +00:00
236a94268e Merging r39199 through r39485 from trunk into vgroup_modifiers. 2011-08-17 11:11:43 +00:00
78b147fbc2 Commenting and pep8 compliance 2011-08-17 10:13:24 +00:00
db4071d2b6 BGE Animations: Lamp and Camera IPOs are now handled like object IPOs, which means lamps and cameras are no longer stuck to just their active action. However, the Blender UI seems a little restrictive in this area. 2011-08-17 09:38:50 +00:00
dd8d24ff9d fix [#28274] Cant select aditional object in edit mode.
missing feature from 2.4x
2011-08-16 22:44:12 +00:00
feb52de6b5 fix for error calling RNA_property_float_get_index on non array float rotations when displaying. 2011-08-16 22:18:24 +00:00
750e754604 Adding ANIM_validate_keyingset to stubs.c so the Blenderplayer builds again. 2011-08-16 22:14:55 +00:00
9b5c0f65aa BGE Animations: Increasing the max layer count to 8 as per a user request. Also, layer checks were checking for values between 0 and MAX_ACTION_LAYERS when they should have been checking for values between 0 and MAX_ACTION_LAYERS - 1. 2011-08-16 19:59:08 +00:00
0b7911cf0a Small change that improves usability to advanced retargeting 2011-08-16 19:12:36 +00:00
2cece7b221 Bugfix for [#28258] [UV editor] missing snapping option.
*Added back "snap_target" as we had in 2.4x.

I removed the "snap_element" though, as only Vertex Snapping is supported in the UV Image Editor.
2011-08-16 17:43:39 +00:00
d79967e164 Animation Exporter clean up. 2011-08-16 17:17:13 +00:00
f04fb5b6ea Finalizing. 2011-08-16 16:03:37 +00:00
87efb89901 Py fix for trunk to pepper merge. 2011-08-16 14:43:04 +00:00
23807d1fb4 Merging trunk up to r39447. 2011-08-16 14:11:58 +00:00
dddfb5e173 minor fix, armature selection outline was not being drawn for non-active, selected armature object when they were in pose mode. 2011-08-16 13:46:51 +00:00
6b1fd66e3b turns out recent commit made 'make' on its own fail. 2011-08-16 13:45:17 +00:00
e98074d327 remove support for deprecated Vector() * Matrix(), eventually this will be added back as row_vector_multiplication bu to avoid confusion for a bit just disable it altogether so script authors get an error on use and update their scripts. 2011-08-16 13:10:46 +00:00
45cf8d673e add numpad key input for ghost/sdl 2011-08-16 13:07:46 +00:00
02d2472baa 3D Audio GSoC:
Code documentation.

Also:
* Fix: rlint for MSVC.
* Minor other small fixes/changes.
2011-08-16 13:00:55 +00:00
f0259542e1 Front/Back togles should not disable when curve is 2D and bevel object is used
http://www.pasteall.org/pic/show.php?id=16449
2011-08-16 12:37:23 +00:00
b7302f9d5a Convenience targets for project files:
Project Files for IDE's
  * project_qtcreator - QtCreator Project Files
  * project_netbeans  - NetBeans Project Files
  * project_eclipse   - Eclipse CDT4 Project Files
2011-08-16 10:34:52 +00:00
c7f9e9a80f Fix #28273: Crash playing with Follow path+Bevel+Material
Crash was caused by old refactor of displists.
Added additional check to makeDispListCurveTypes.
2011-08-16 10:31:28 +00:00
989f67f522 'make help' message for the convenience makefile which lists optional targets. 2011-08-16 10:01:19 +00:00
93f135cfda added cmake configureation presets, so on *nix systems you can do...
# minal blender with debug info
 make debug lite

 # blender with no ui
 make headless

 # blender as a python module
 make bpy
2011-08-16 09:36:15 +00:00
b4df54151a 2.6 Node Muting:
* Removing check if Node is in between, so in-/output nodes can be muted as well. Useful for example if you want to temporarily mute a file output node.
2011-08-16 08:40:25 +00:00
a67562e73c Bugfix [#28267] keyframed values for shapekeys of copied objects are
linked

Shapekey actions weren't getting copied when their owner data was.

This was due to the IMO totally convoluted way in which the duplicate
action flags have been set up:
- the function to copy animdata takes a param to specify whether
actions are copied or not, but this is never touched (i.e. this always
just gets FALSE passed in)
- instead, we jump around in hoops later figuring out whether the
userpref wants copying to occur, then fixing up the links

IIRC, part of this may be due to a desire/need to not duplicate
actions when dealing with NodeTree copies for multi-threaded
rendering, but at the expense of complicating everything else.
2011-08-16 01:02:26 +00:00
a458de88b6 3D Audio GSoC:
High quality resampling on mixdown, linear for playback.

* Lots of improvements and fixes for the JOS resampler, now it works fine!
* High quality filter coefficients for the JOS resampler (sorry for the 5 MB source file).
* Fix for GE orientation bug. Note: moto uses x,y,z,w quaternion storage, while rest of blender uses w,x,y,z.
* Minor changes/fixes.
2011-08-15 21:50:09 +00:00
405218df6f the diffuse kernel I had first picked for dilation turned out to be not as great as I first thought. This kernel is a more basic one (trite but true) 2011-08-15 17:55:25 +00:00
cdb5d11c5f patch [#22523] Expose Object.parentinv matrix via RNA
from Balajee R C (balajeerc)
2011-08-15 17:29:07 +00:00
39cbcdf187 Window was losing focus when switching from full screen via Alt+F11
Fixes [#28243]
2011-08-15 16:26:37 +00:00
65ca89180a fix [#28227] join_uv and bake work wrong
added back ability to unwrap all selected mesh objects.
2011-08-15 16:25:05 +00:00
ae884d2e54 Code cleanup: add UNUSED_FUNCTION macro to avoid warning messages about unused
functions.
2011-08-15 16:18:04 +00:00
27b3695c4f Remove message "Info: Config directory with "startup.blend" file not found."
There's no reason to have it really, this situation is totally normal, and it
means a terminal window is opened on Windows as long as you haven't saved any
default settings yet.
2011-08-15 16:12:39 +00:00
f53143dc83 Fix #27718: driving modifier properties was missing updates, fixed depsgraph. 2011-08-15 14:05:04 +00:00
cbbbf31315 Restoring "Clear User Transforms" operator
This can now be found as Pose -> Clear Transforms -> Reset Unkeyed, or
via the operator search (known by its old name there)
2011-08-15 13:24:53 +00:00
b62951c0d5 Fix #28162: texture properties didn't show correct texture datablock chooser
in a particular setup with two nested material nodes. Material active texture
was looking also recursively into material node, but this was already done
outside of this function.
2011-08-15 13:17:39 +00:00
470b39608a Fix #27803: editing texture did not update compositing nodes using that texture. 2011-08-15 12:07:52 +00:00
87e8b853a6 Remove some unused code + warning fix 2011-08-15 11:51:42 +00:00
0745f31306 "Select Grouped" by Keying Set for Bones 2011-08-15 11:34:29 +00:00
674d1b8d68 Select by Keying Set...
* Split off code to refresh relative/builtin KeyingSets for the
current context before they get used to a separate function.
* Hooked this up to a new PyAPI/RNA function: KeyingSet.refresh().
Call this before checking the paths that a Keying Set has, especially
if it is not "absolute"

* Added option for "Select Grouped" operator (for Objects), which will
select all objects affected by the active Keying Set. This is probably
more useful for absolute KeyingSets, where changing the selection is
less likely to affect the result.
- The equivalent for bones is currently still in development, but is
likely to be more useful for animators, where rigs are the primary
animation entities they deal with
2011-08-15 10:37:26 +00:00
c8ae881b61 Added option to each retargeted bone to fix twist issues caused by variable bone rolls and unknown axis differences. Also made retarget operator a single undo 2011-08-15 10:18:02 +00:00
3237f39243 Small fix to autoloop due to changes in utility function by animation stitching 2011-08-15 10:17:04 +00:00
270ed82c7b Fix #28202: deactivating keymap items not saving properly. 2011-08-15 10:03:17 +00:00
551e8bc72c py api - optional sep argument for bpy_extra.io_utils.unique_name() since for some formats '.' is an invalid char. 2011-08-15 04:58:19 +00:00
e4f2234fff workaround [#28250] Append dialogue will ask to create new directory inside a .blend
directory button isnt library aware, for now disable it when a libraries loaded.
2011-08-15 04:11:55 +00:00
2c8e1e633c comment unused lines. 2011-08-15 03:41:31 +00:00
cc3b9aa467 blender extra parameter animation import ( on hold ); 2011-08-14 16:15:41 +00:00
e93444f816 Matrix transformation animation import for other objects under the new system. 2011-08-14 16:14:32 +00:00
fc0a5ede01 Cleanup 2011-08-14 16:13:35 +00:00
02b24e655b fix for bug where changing movie filepaths would reset the strip length.
also fixed possible & unlikely buffer overflow.
2011-08-14 14:43:11 +00:00
181104261d patch [#28247] Fix for: [#28236] Separate By Materials fails when some materials "available" to the mesh are unassigned
from Alex Fraser (z0r)
2011-08-14 12:02:01 +00:00
cad6ed9bc6 fix for fix r39388, this added checkboxes to buttons which are not supposed to have them.
now only add checkboxes when the background is not emboss - which works for menus but will work in more general cases too.
2011-08-14 11:38:17 +00:00
540f0c64b5 add in asserts for when array/non array RNA funcions are used incorrectly, would have made previous fix a lot easier to find.
also remove unused argument from RNA_property_array_check.
2011-08-14 10:28:18 +00:00
b8473d70e2 Bugfix [#28244] Setting vector handle in fcurve can fail
So apparently this was a regression from 2.4x, since vector handles
were one of the handle types which could be set independently for each
handle (vs both needing to be the same, for example, Auto Handles)
2011-08-14 10:19:21 +00:00
62fdee3d8a fix [#28245] Checkboxes in menu items fail for boolean arrays.
2 bugs with displaying boolean arrays.
2011-08-14 10:17:41 +00:00
8490d646b7 Fixing bug with editing keymaps when filter is enabled. 2011-08-14 09:12:43 +00:00
2187f6772c patch [#28246] Fix for [#28240]: selecting more than one object in the outliner with "shift left mouse" doesn't work anymore
from Alex Fraser (z0r)
2011-08-14 08:39:13 +00:00
0b23d378fb fix [#28225] Solidify Modifier creates wrong results when vertex group is attached
infact this is not really a bug, irrespective zero vertex group weights gave overlapping geometry which isn't useful, add an option to set the thickness factor for zero weighted verts.
2011-08-14 06:43:58 +00:00
656adc53b4 Show dopesheet summary for new DopeSheet editors
While I originally made these so that they wouldn't be on by default
due to concerns over the filtering used for these leading to reduced
framerates/interactive speed, I'd since found while doing some
profiling that this isn't the case.

Rather, decreased framerates were more likely to stem from trying to
perform the checks necessary for the long-keyframe drawing when many
"child" channels are involved (affecting other channels too).

So, since these are generally useful, they are now enabled by default
:)
2011-08-14 04:55:52 +00:00
Dalai Felinto
5e968e36c5 bugfix:[#25603] bad shadows in stereo mode - patch by Juha Maki-Kanto 2011-08-14 04:37:53 +00:00
fc128c970b - recently restored sequencer change data operator didnt reset the offsets after a hard cut, causing the new data to be trimmed.
- add change data operator to strip panel next to image file properties since editing every image manually isnt really usable.
- added new sequencer operator "Clear Offsets" (Alt+O), useful to reset the start/end frames around the strip data.
2011-08-14 03:59:22 +00:00
2fef8f13f0 Added argument to retargeting - step size. Allows retargeting every other 'step' frame, useful for previewing or faster retargeting. 2011-08-13 18:46:34 +00:00
65d9d2e3e0 2.6 UI Files:
* Code cleanup in the space_*.py files.
* Removed layout.column() statement in _MT_ panels, they are useless.
* Only define variables at the beginning of a function!
2011-08-13 17:52:13 +00:00
c86bcd5065 transform matrix animation import fix. 2011-08-13 16:22:14 +00:00
a4b6cfd872 light parameter export expansion. 2011-08-13 16:21:41 +00:00
c106f7bee9 Light blender profile param sid addressing 2011-08-13 16:20:28 +00:00
c83417b2e2 running bpy.ops.render.render('INVOKE_DEFAULT') would crash blender. 2011-08-13 14:24:53 +00:00
7866b63292 2.6 Release Cycle begin:
*BLENDER_VERSION_CYCLE set to alpha

Idea is to set it to alpha for the first 3 weeks (B-Con1)
Beta for B-Con 2 and 3 
RC for B-Con 4
Release for B-Con 5
2011-08-13 13:45:03 +00:00
aaeb498c26 Added a small operator to ease mapping. When used, the hierarchy mapping field is filled with the currently selected (pose) bone. 2011-08-13 11:09:42 +00:00
7c7fac2174 index_to_framebuffer (used for mesh selection) was being called 3x times per call to WM_set_framebuffer_index_color(), because of the cpack define. 2011-08-13 09:22:14 +00:00
c5ef9b62c1 BGE Animations: Adding an option to let users choose whether or not to lock animation updates to the framerate. If this option is enabled, animations are only updated at the same speed as the animation framerate. This can give a significant speed up in performance, but at the cost of smoothness in animations. I'm defaulting this behavior to off for now, which is the behavior seen in trunk. 2011-08-12 20:53:29 +00:00
83f0c6e569 Transform matrix Animation import fix. 2011-08-12 20:38:29 +00:00
a7dd264940 Nodes: make node set active function usable outside of node editor, and in doing
so fix a missing updating when activating a node with multiple node editors open.
2011-08-12 18:27:48 +00:00
0cb606a9bc Code cleanup: fix wrong doxygen file name. 2011-08-12 18:24:17 +00:00
a7de5fc191 Code cleanup: small glsl mesh drawing code changes, getting rid of an ugly macro. 2011-08-12 18:17:28 +00:00
ceb9dfbdac Code cleanup: remove seam drawing in face select mode, was left over from when
seams were edited there, now only needed in edit mode.
2011-08-12 18:13:55 +00:00
c265a686d8 Modifiers: add callback to loop over each texture assigned to a modifier. 2011-08-12 18:11:22 +00:00
24b18fd154 More work on Advanced Retargeting and some stride bone bugs 2011-08-12 18:10:31 +00:00
e4bdb6e95a Code cleanup: replace some manual setting of ob->recalc with DAG_id_tag_update,
is now just as fast anyway with delayed flush.
2011-08-12 18:06:05 +00:00
059bbee2da Drat... missed one 2011-08-12 07:22:29 +00:00
ebbd232555 Fixing compiler warning 2011-08-12 07:21:44 +00:00
db72192c22 Bye bye vile relics of extinct version control systems,
Causing a flurry of refresh file prompts post-commit,
Confusing local diffs and causing merge conflicts,
Stating the obvious; redundant and useless...

We shall not miss thou, blasted expand $keywords$
2011-08-12 07:20:49 +00:00
b374ab919a import common classes from bpy.types, saves ~1000 python getattrs on startup. 2011-08-12 06:57:00 +00:00
8fd246cb70 add bpy.types as a module for convenient imports, eg:
from bpy.types import Menu
2011-08-12 06:31:39 +00:00
ada88c8d8e sequencer todo: change sequence added back (C key)
split up into operators
- change effect input
- change effect type
- change file data

Change plugin is not ported back yet.
2011-08-12 06:08:22 +00:00
347f4fac74 add WM_FILESEL_FILES to WM_operator_properties_filesel, sequencer was doing this on its own. 2011-08-12 03:53:26 +00:00
a03b52af81 soft limits for add object rotation value, without cont. grab it would get to very large numbers with a small drag. 2011-08-12 03:18:04 +00:00
b1c04d379f un-inline GHash functions r26206, these are quite large functions to inline and increase binary size by 30kb, (tested on stripped, cmake release build).
Ran some speed tests and difference was close to the noise level, but inlining gives only ~2 - 3% speedup with build modifier which uses ghash a lot.
2011-08-12 02:23:06 +00:00
f1a8c26aa3 Additional work on animation stitching, now with auto-guess capability. Only a few bugs left, regarding animations translation 2011-08-11 16:46:27 +00:00
Nathan Letwory
3359b7d7b7 use correct libdir for buildbot win64. 2011-08-11 16:43:36 +00:00
c9216e390c Commiting patch from jensverwiebe for NDOF support on OSX 2011-08-11 15:59:19 +00:00
05b7ccb736 Optimizations following intensive profiling of retarget and other lengthy functions. Retargeting now takes ~30% less time 2011-08-11 14:50:19 +00:00
87e9c0ffaa Advanced Retargeting option: If the end user armature is complex, on the level of Sintel/Mancandy rigs, the user is requested to mark Advanced Retargeting, and constraints will be semi automatically configured to retarget the animation and then Retargeting will bake and remove these constraints 2011-08-11 13:47:49 +00:00
944cdf04dd Fix for crash when using undo during sketching session.
Currently, grease pencil conflicts with such operators
as undo and set object mode which makes behavior totally
unpredictable and crash for some cases.

The only way to solve this proper is to ger rid of pointers
to data which can chage stored in operator custom data.
2011-08-11 13:40:47 +00:00
9c9cd71a86 Fix #28180: crash running wm.keyconfigs.user.keymaps.new("My Keymap").
There isn't much point in doing this at the moment, but shouldn't crash.
2011-08-11 11:56:02 +00:00
fee7337249 3D Audio GSoC:
Adding a mono flag to mixdown non-mono sounds for 3D audio.

* Added mono sound loading.
* Bugfix: AUD_COMPARE_SPECS usage was wrong.
* Bugfix: JOS resampler = instead of ==.
* Bugfix: Change of a sound should apply settings in AUD_SequencerHandle.
* Bugfix: Memory leak when canceling open sound operator.
2011-08-11 11:41:24 +00:00
165e6dbc07 Adding a readonly length_squared property to mathutils.Vector. This is simply vector.dot(vector), so nothing new is really added, but it's nice for writing more intent revealing code. In other words:
if vec.dot(vec) > some_distance*some_distance:
    do_something()

might not be quite as obvious looking as:

if vec.length_squared > some_distance*some_distance:
    do_something()

As to why you'd want to use length_squared over length is that length uses a square root, which isn't always necessary for simple distance checks (e.g., closest object, checks like the ones above, ect).
2011-08-11 09:40:14 +00:00
2c2fa877be svn merge -r39286:39298 https://svn.blender.org/svnroot/bf-blender/trunk/blender, ensure some edits in trunk dont get merged back into pepper 2011-08-11 09:28:07 +00:00
99caa9470e fix [#28213] Imperial unit for 0.001 inches inconsistently displayed as mils and thous 2011-08-11 08:24:56 +00:00
78f89c3bbf BGE Animations: Animation updates are now handled separately from logic/physics updates. This allows the animations to be updated at the full fps specified by the user. Before, updates were not happening frequently enough. For example, a 30fps animation my only update at 20~30fps, which would cause some noticeable lag. This my not be the best solution since at this point we may be dropping frames (not being in the while(frames) loop), and we're not updating as often as the physics engine might want for bone parented physics objects. 2011-08-11 07:19:37 +00:00
80acfdc7a0 SVN maintenance. 2011-08-11 06:40:04 +00:00
a7663cc377 use ghash for operator and menu types, was doing string lookup in the operator list (containing over 1000 items) for each button draw.
gives small speedup for UI drawing and overall startup time.
2011-08-11 06:06:17 +00:00
0fac849d44 ifdef'd outliner code which is spesific to gsoc pepper with '// GSOC_PEPPER' so its obvious. this will keep merging pepper changes from conflicting and can be removed when its finally merged. 2011-08-11 05:50:05 +00:00
e97617e3fb merge outliner refactor so we dont have to keep outliner.c locked in trunk.
this wont build because of changes spesific to pepper, fix coming next.

svn merge source/blender/editors/space_outliner -r36830:38987 https://svn.blender.org/svnroot/bf-blender/branches/soc-2011-pepper/source/blender/editors/space_outliner
2011-08-11 05:46:18 +00:00
07e8bfd2f2 unlocking outliner.c and removing... (merging refactor from pepper but looks like this will take a few steps) 2011-08-11 05:43:20 +00:00
ef18ec335f svn merge -r39145:39286 https://svn.blender.org/svnroot/bf-blender/trunk/blender 2011-08-11 05:04:01 +00:00
17e88915fd BGE Animations: Updating BL_ActionActuator.frame to work with the new actuator. 2011-08-11 03:27:47 +00:00
fba1f50d0a Mostly finished implementation of animation stitching, with lock bone functionality, allowing the user to choose a bone that maintains its position during the blend 2011-08-10 20:37:57 +00:00
1eaeaf8cd8 Fix for previous commit, now a fake user flag is added when switching between retargeted animations, so they don't get lost on save 2011-08-10 20:36:52 +00:00
50277c48ba fix for regression for shape key UI, values are now editable again in the list, double checked this works for mesh/curve and lattice types. 2011-08-10 20:12:27 +00:00
7707140fd1 BGE Animations: Always update the localtime used for continuous animations. Previously this was only done on a positive or negative pulse, which could lead to some issues with a continuous flipper animation. 2011-08-10 20:05:30 +00:00
286a6d39c7 import only transform matrix animation method ( in progress ) 2011-08-10 19:43:40 +00:00
b5d556d432 Initial programming of stitch animation operator. WIP 2011-08-10 18:41:04 +00:00
8afad10f98 Continued changes to storing of retargeted animation data, making it possible to easily switch between all retargeted clips, and stitch them with the future operator 2011-08-10 18:40:14 +00:00
11d4cfaa71 Baked Animation re-Import fix 2011-08-10 17:51:18 +00:00
11aa9ff223 error in own recent commit. set subversion to 0 2011-08-10 16:05:20 +00:00
e8471be5f2 2.59 Splash screen by tomket7. Congratulations!
Chosen by the jury Ben Simonds, Reynante Martinez and Hjalti Hjálmarsson.
2011-08-10 16:03:45 +00:00
45d99da8a2 Version bump for 2.59 2011-08-10 16:02:02 +00:00
cff2caa8a7 fix [#28206] Motion Paths shown in 3DView even when Only Render option is enabled 2011-08-10 15:53:46 +00:00
Nathan Letwory
3758f125fc Fix for incorrect parameter amount. 2011-08-10 09:30:45 +00:00
036077ebc6 fix for error in template 2011-08-10 09:16:35 +00:00
958c468b07 fix [#28203] Misplaced string in bone constraints 2011-08-10 07:49:18 +00:00
Nathan Letwory
4da9a8959f Fix [#28195] Particles objects disappear in viewport, and 90° rotation
Reported by Jean Francois Sarazin

Lack of normal normalisation caused scaling issues. SIGGRAPH fix by jahka and jesterKing. Thanks to host dfelinto with entertainment provided by slikdigit.
2011-08-10 07:36:57 +00:00
3a9b288bc7 fix for [#28201] blender crashes when "mpeg" selected
2 changes
- When writing OGG only allow Theora encoding, this fixes the crash.
- When setting the MPEG preset, dont allow the 'Codec' to be left as Theora, this is just confusing.

* note that this is highly confusing for users and devs - there are 4 places to set the codec/format, with both python and C presets :S.
2011-08-10 07:36:44 +00:00
fafe6e3540 Gianmichele request: Pose Sliding tools show percentage indicator in
header
2011-08-10 00:46:20 +00:00
a10e00dc57 fix for crash undoing grease pencil session, last action would free entire frame which the session held a reference to. 2011-08-09 21:32:46 +00:00
3ddbc3869d fix [#28197] Undoing Grease pencil removes last 2 strokes 2011-08-09 20:33:35 +00:00
4262bd2906 fix [#28196] Unwrap tris in lightmap pack 2011-08-09 20:00:53 +00:00
0207d9ce27 style change, harmless changes while looking into bug [#28196] 2011-08-09 19:59:01 +00:00
944a891b48 sid addressing fix 2011-08-09 19:30:17 +00:00
ef40d8e4f0 Another error in last bigger commit. 2011-08-09 17:37:12 +00:00
407ec19431 temporary fix for quat rotations 2011-08-09 16:28:08 +00:00
22694c993a fix [#28186] textboxes properties not animatable 2011-08-09 14:50:40 +00:00
8655385c9e Fix for last commit: MSVC dislikes ;; 2011-08-09 14:34:42 +00:00
da6bc69ca9 fix [#28191] Exception when enabling a script for a newer Blender build 2011-08-09 14:16:22 +00:00
a672ab5e73 3D Audio GSoC:
Improved waveform drawing in the sequencer.

* Drawing the waveform of a sequencer strip is now independent from whether the sound is cached or not.
* Improved drawing of the waveform in the sequencer (especially speed!).
* Making it possible to vertically zoom more in the sequencer to better see the waveform for lipsync.
* Fixed a bug which crashed blender on loading a sound file via ffmpeg.
2011-08-09 14:10:32 +00:00
08e184f302 note to address issue raised by report [#28190]. 2011-08-09 13:50:27 +00:00
13249b925e 3D Audio GSoC:
Speaker objects fully functional!

Minor changes:
* Fixed three memory bugs found via valgrind.
* Fixed bug with jack transport crashing after file loading.
* Sound NLA Strips now start at CFRA instead of 0.
2011-08-09 08:38:14 +00:00
f98e2161d0 change doxygen string to 2.59 2011-08-09 07:48:40 +00:00
2dfc51388c Blender 2.59:
* Update the readme file
* Update link to release logs, they point to http://www.blender.org/development/release-logs/blender-259/ now
2011-08-09 07:33:51 +00:00
ffd5fa3eea off by 1 error with number keys in ghost/sdl 2011-08-09 07:09:49 +00:00
802f69df78 BGE Animations: Fixing issues with initialization order in BL_ShapeDeformer 2011-08-09 03:27:05 +00:00
88786f6fca BGE Animations: Fixing the Continue option when using the Flipper play type. Also removing a couple of debug prints. 2011-08-09 03:06:22 +00:00
97d4240911 Merging r38818 through r39198 from trunk into vgroup_modifiers. 2011-08-08 21:28:51 +00:00
e2c24bac6c vgroup_modifiers: Now clamping output values to [0.0, 1.0] range (and added min/max mapping values for Prowimity modif). 2011-08-08 21:12:51 +00:00
cbec4e2768 export bone transform matrix with sid. 2011-08-08 16:38:57 +00:00
85b77c931d fix [#28183] Wavefront OBJ import has no preset saving 2011-08-08 14:50:10 +00:00
60eec89cda Created property systems for multiple retargets on a single armature, for this type of use and animation stitching. Also contains some placeholder UI and code for animation stitching. 2011-08-08 11:09:56 +00:00
64a298645f report error on installign keymaps rather then raising an exception. 2011-08-08 09:09:44 +00:00
24acf58fc4 quiet harmless py resource warning - file opened but not closed. 2011-08-08 09:01:09 +00:00
cc0ec3aa33 fix [#28178] make single user copy of object data doesn't work 2011-08-08 08:22:01 +00:00
8eec116d0e add missing keys for ghost/sdl 2011-08-08 06:54:07 +00:00
349c838996 add missing header to cmake files (else some IDE's wont index it) 2011-08-08 05:43:04 +00:00
22d2764d50 use static sets rather then tuples, python optimizes this case.
minor change to lightmap unpack collecting unique meshes.
2011-08-08 05:21:37 +00:00
8883702f8a BGE Animations: Various compatibility fixes:
* Blendin for Loop End works even after a negative pulse. Flipper could still use some work in this area.
  * Continuous works a lot better.
  * BL_Action::SetFrame() should work a little smoother.
2011-08-08 04:28:30 +00:00
0160901c90 - update X3D and FBX testing checksums
- building with GHOST/SDL now adds the PREFIX
- image.external_edit operator errors out if the filepath isnt set (was annoying and loaded gimp while running tests)
2011-08-08 03:31:25 +00:00
fad243a4bf Mac Compile fix for ndof, by jensverwiebe. Thanks! 2011-08-07 22:48:04 +00:00
a8096ef0ac Updating CMake to install the correct ffmpeg libs. 2011-08-07 19:32:22 +00:00
3aa0953d95 COLLADA Armature bake animation export fixed( needs more testing ) 2011-08-07 19:22:39 +00:00
28ae6d85fe fixed typo 2011-08-07 18:57:39 +00:00
c095397c98 Armature bake animation export ( not as pose matrices. Still needs fixing ) 2011-08-07 18:15:40 +00:00
5681380db0 simplify x11 path code, had unneeded NULL checks and std namespace 2011-08-07 17:38:36 +00:00
f12df1e386 ndof data change: operators can access values as vectors or components, as both are handy 2011-08-07 17:22:47 +00:00
3a55da7616 removed old ndof transform code, to be replaced with modern stuff in 2.6 2011-08-07 17:01:44 +00:00
577293569a scons patch from jensverwiebe
fix a silly bug in version detection, - added an OSX sdk-check

jensverwiebe, needs to get commit access!, but will apply his patches for now.
2011-08-07 16:54:40 +00:00
479c203dad stricter WITH_INPUT_NDOF guards, general cleanup 2011-08-07 16:44:10 +00:00
6a0bbfd0e4 fixed ndof library detect for Mac SCons, ndof enabled by default (disabled if lib not found), minor cleanup 2011-08-07 16:29:05 +00:00
daab78bc61 Merging trunk up to r39145. 2011-08-07 15:25:06 +00:00
bf23acf3bb fix for building ndof with cmake on osx 2011-08-07 15:06:35 +00:00
0dea4df764 Changed do_version condition for noodle_curving.
It should be re-set to 5 for files saved in 2.58.1 release.
2011-08-07 14:57:25 +00:00
b057cf1bb1 Nla Sound Strips + Add Speaker
Second part of previous commit. Now, when speaker objects are created,
they are created by default with an NLA sound strip so that it is easy
to just start immediately using this to do cool stuff (i.e. timing
when you want the sound to start).
2011-08-07 12:43:44 +00:00
022e815fbd Sound clip NLA Strips for Nexyon
These are basically just for specifying when a speaker should fire off
it's soundclip, and as such, many NLA operations are irrelevant for
it. They can only be specified on object-level for speaker objects.

I've still got some UI tweaks I'll need to work on in order for these
to be able to be added even when the speaker doesn't have any NLA
tracks yet. (EDIT: while typing this, I had an idea for how to do
this, but that'll be for next commit). In the mean time, you'll need
to add a single keyframe for the object, snowflake that action and
delete the NLA strip before you can start editing.
2011-08-07 12:27:20 +00:00
2d884fc035 3D Audio GSoC:
* Pepper depends on ffmpeg 0.7.1 or higher now, windows and mac build systems set to ffmpeg-0.8
* Fixed orientation retrieval in OpenAL device code.
* Added stopAll() method to AUD_IDevice (also for Python) and call it on BGE exit
* Changed BGE to use audaspace via native C++ instead over the C API.
* Made AUD_SequencerFactory and AUD_SequencerEntry thread safe.
* Changed sound caching into a flag which fixes problems on file loading, especially with undo.
* Removed unused parameter from sound_mute_scene_sound
* Fixed bug: changing FPS didn't update the sequencer sound positions.
* Fixed bug: Properties of sequencer strips weren't set correctly.
* Minor warning fixes.
2011-08-07 11:54:58 +00:00
a02d7c1ba7 Fix #28169: keymap bug when using a preset configuration, e.g. object mode keymap
was also being used in edit mode.
2011-08-07 11:01:55 +00:00
4370099fb0 3D Audio GSoC:
Added a NULLHandle to prevent a crash in Python API when the device is the NULLDevice.
2011-08-07 06:22:50 +00:00
5cc0bb0d1b BGE Animations: The IPO conversion code relied on objects having an adt, but this isn't always the case. object->adt can be NULL, which causes a crash. Now BL_InterpolatorLists are cached by action instead of adt. 2011-08-07 04:57:23 +00:00
38280ba38e fix [#28172] Cannot restore Add-ons tab in user preferences after a failed attempt to install an add-on.
non utf8 addons would make the addon UI vanish, now give a message in the console and UI.
2011-08-07 04:55:58 +00:00
117ec4a91a comment unused vars 2011-08-07 04:22:33 +00:00
6c821f4078 stricter NDOF guards for Windows (forgot in earlier commit) 2011-08-06 23:13:36 +00:00
5dd2b3e06f fixed crash when NDOF operators were called without an NDOF_MOTION event 2011-08-06 22:31:16 +00:00
c334bf69a7 3D Audio GSoC:
Mixdown functionality.

* Mixdown possible via libsndfile and ffmpeg!
* Fixed some ffmpeg deprecation warnings
* Mixdown UI only shows working Container, Codec and Format combinations!
* Minor bugs and warnings fixed
2011-08-06 17:57:20 +00:00
79e359f92a rna/ui: avoid duplicate property gHash lookups by passing the property when its already been found.
added _prop suffix to ui functions which take a prop rather then a propname, may change this later since its not that nice but for gsoc branches this keeps existing UI functions working the same.
2011-08-06 16:00:00 +00:00
2f5809d831 make ui_def_but_rna into 2 functions, once which takes a prop, another which takes a propname, no functional change yet but lets us avoid duplicate hash lookups. 2011-08-06 14:57:55 +00:00
e73cf35f4a Graph Editor "Active Keyframe" settings
This commit makes some tweaks to the way that the "active keyframe"
settings in the Properties region in the Graph Editor work (for the
better, hopefully).

Basically, the problem was that previously, these were clunky and non-
intuitive to use, since they were just directly displaying the RNA
properties for those keyframes for editing purposes. But due to
limitations of RNA (i.e. from a RNA pointer to a keyframe, you
couldn't see which F-Curve you came from), several things were
impossible, notably:
1) Doing proper updates, including validating that the handles are in
a valid state - that requires access to the F-Curve to provide to the
F-Curve-based curve validity checking functions
2) Having the values of the keyframes display in whatever unit that
the property the F-Curve affects displays as - for this, you once
again need to know the F-Curve in order to resolve the property that
it affects; also the fact that only a single unit could be set for RNA
properties further limited things

This commit basically gets around these problems by moving away from a
layout-engine based approach to one where we attach custom update
callbacks and also override the units of the y-co widgets when
creating the widgets for these, thus allowing the buttons to work in
the ways that animators expect.
2011-08-06 07:01:07 +00:00
dc4dede802 for UI text drawing use BLF_ascender(fs->uifont_id) rather then BLF_height(fs->uifont_id, "2"), while profiling draw noticed that the hash lookup on the character and utf8 next were being called on every text draw, use BLF_ascender since it doesn't do any lookups. 2011-08-06 06:38:18 +00:00
d096f27151 Material ray trace transparency animation COLLADA export. 2011-08-06 06:11:31 +00:00
d78be1f762 remove copy modifiers function, now handled in link data operator. 2011-08-06 04:19:30 +00:00
7e0049d27a BGE Animations: Making the ping pong mode for action actuators behave more like trunk. The behavior is a lot closer, but there are still differences when interrupting a ping pong action. I'm still trying to decide if these are acceptable differences as they don't look all that simple to fix. 2011-08-06 00:35:16 +00:00
e6e4c7ef8b KEYMAP REFACTORING
Diff Keymaps

User edited keymaps now no longer override the builtin keymaps entirely, but
rather save only the difference and reapply those changes. This means they can
stay better in sync when the builtin keymaps change. The diff/patch algorithm
is not perfect, but better for the common case where only a few items are changed
rather than entire keymaps The main weakness is that if a builtin keymap item
changes, user modification of that item may need to be redone in some cases.

Keymap Editor

The most noticeable change here is that there is no longer an "Edit" button for
keymaps, all are editable immediately, but a "Restore" buttons shows for keymaps
and items that have been edited. Shortcuts for addons can also be edited in the
keymap editor. 

Addons

Addons now should only modify the new addon keyconfiguration, the keymap items
there will be added to the builtin ones for handling events, and not get lost
when starting new files. Example code of register/unregister:

km = wm.keyconfigs.addon.keymaps.new("3D View", space_type="VIEW_3D")
km.keymap_items.new('my.operator', 'ESC', 'PRESS')

km = wm.keyconfigs.addon.keymaps["3D View"]
km.keymap_items.remove(km.keymap_items["my.operator"])

Compatibility

The changes made are not forward compatible, i.e. if you save user preferences
with newer versions, older versions will not have key configuration changes that
were made.
2011-08-05 20:45:26 +00:00
7368298a45 Messed up char was causing problems on windows even though it was in the
comments.

Kent
2011-08-05 19:55:36 +00:00
6829b93c11 create_4x4_source function 2011-08-05 18:32:39 +00:00
4d319f8059 fix for GHOST/SDL key input with uppercase keys. 2011-08-05 17:39:44 +00:00
9747e5f2a0 2011-08-05 17:19:31 +00:00
3a82a690ab ifdef out support for for python owning and freeing BPy_StructRNA because this is only used for doc generation and it makes _every_ blender/python instance 4 bytes bigger - vertex/bezier point/object/scene/group etc. 2011-08-05 16:29:38 +00:00
85fe36ab61 pyrna - add own callable function type rather then using a standard python method, gives small speedup drawing buttons since every layout.prop/col/operator/menu etc creates and throws away one of these. 2011-08-05 16:21:37 +00:00
db319f8544 move the ndof menu into the userpref's since it adjusts preferences, also renamed VIEW3D_MT_ndof_settings -> USERPREF_MT_ndof_settings since it has no view3d specific settings. 2011-08-05 14:53:13 +00:00
d368716aed Timeline UI Nitpicks:
* "Only Selected channels" -> "Only Selected Channels"
* Use Keying Set icon for "only keying set" toggle for autokeying
2011-08-05 12:17:49 +00:00
a6b677c81d patch from jensverwiebe to scons to be compatible with gcc llvm. people who copy the darwin-config.py to their user-config.py should update. 2011-08-05 12:07:05 +00:00
861d157388 Bugfix [#28106] Missing 3D view update after copy of constraints 2011-08-05 11:31:41 +00:00
dca090abc8 Assorted loose ends for auto-clamped handles work
* Tweaked order of handle types to make it easier to find Auto/Auto-
clamped in the list
* Fixed a number of places which were still just checking for auto-
handles when they should have included auto-clamped too, including
handle rotation
2011-08-05 11:23:28 +00:00
a157112ac5 fix for icon scaling with the DPI setting
- icons were scaling by the sqrt(dpi)/8.48528, but infact they only need to be scaled by (dpi/72).
- UI_icon_get_width value was being used without multiplying by dpi scale.
2011-08-05 10:45:32 +00:00
ad7ea2f892 get a tad more vertical space in the toolbar. 2011-08-05 09:04:11 +00:00
9a9330d88c Post Retarget fixes - added an Update Constraints button, that recalculates all fixes. Useful for when the user makes some external change to the animation 2011-08-05 08:44:16 +00:00
63c7bacc7b Updated Vector/Matrix multiplication to new order as required by mathutils 2011-08-05 08:41:16 +00:00
b5e55ff44b Small fix to Path Editing - now mute's original forward motion curve 2011-08-05 08:40:06 +00:00
507dbeab45 3D Audio GSoC:
JOS Resampler: Fix for windows...
2011-08-05 07:01:54 +00:00
f48631e9a4 fix [#28160] Pressing Y on an image sequence to seperate the images takes them out of their meta strips
dont show a popup anymore, was silly because you had to change the value for before anything was done, can use f6 redo popup instead, sequencer should eventually have a view3d operator redo panel.
2011-08-05 06:26:54 +00:00
c946969bb9 fix for possible uninitialized RNA strings, when RNA_string_get property is not found, initialize the string to "". 2011-08-05 06:09:30 +00:00
82e863bdae fix [#28102] Typing 'C:' into the file selector's directory asks to make a new directory. 2011-08-05 06:06:15 +00:00
f77af0a8ce change BLO_library_append_begin to take a main argument rather then a context, means the BGE doesnt need to make a new empty context just to pass as an arg.
added doxygen description too.

this quiets the print when the BGE does linking.
2011-08-05 05:26:19 +00:00
74b94dcdf6 BGE Animations: Moving the do_versions code for the actuators back into the "put compatibility code here until next subversion bump" block. It got sucked into the 2.58.1 block during a merge sometime. 2011-08-05 01:21:08 +00:00
e9bd246e3b Clarifying tooltips on userpref keyframing options
These probably still need a good review (based on discussions I've had
with animators), but this should be a good stop-gap measure in the
mean time
2011-08-04 14:19:35 +00:00
900928f8bf Bassam Feature Request: "Auto Clamped" handles can now be set per
handle/key

This used to be a weird per-curve setting which would happen to get
applied/work correctly if handles were set to "auto", and was a source
of constant confusion for both old and new animators. The main effect
of this handle-type/option was really to just ensure that auto-handles
stayed horizontal, instead of tilting as the keys were moved.

This commit simply changes this from a per-curve to per
keyframe/handle setting.
2011-08-04 14:13:05 +00:00
2ed11158db Bugfix: Setting of new default settings for new Graph Editors was done
in wrong place, leading to loss of settings everytime the view changed
(i.e. after open/saving)
2011-08-04 14:06:30 +00:00
bc1650a226 3D Audio GSoC:
Implementation of Julius O. Smith's resampling algorithm for high quality audio resampling.

The filter currently is a sinc filter with a 0.9 cutt-off and windowed by a kaiser window (beta = 10).
Also includes minor changes in the linear resampler.
2011-08-04 13:47:15 +00:00
36bf4385c2 fix for building with clang. makesrna wasnt linking with sqrt 2011-08-04 13:22:38 +00:00
26fe903502 Typo when reading line curving. The subversion is 1, so smaller than 1 should be converted 2011-08-04 12:19:50 +00:00
cdea64e32c remove append to cursor code, wasnt used and made some naive assumptions about object locations. 2011-08-04 11:27:13 +00:00
9da70f74d3 UserPref/Node editor feature: Change the level of noodle curving.
Some people like curved lines, other hate them. This commit will let the user change the level of curving.

In UserPreferences=>Themes=>Node editor=>Noodle curving the level can be modified. Allowed range is 0-10 with the default on 5

The patch will default everything to the way blender works ATM.
File subversion has been increased otherwise older 258 files got straight lines.

The data is stored in the ThemeSpace.noodle_curving
the bezierdrawing is done in the drawnode. Also tested the Line cut tool
2011-08-04 10:05:14 +00:00
Dalai Felinto
f3c40df5e3 rst API doc fixes: literalincluding bge.texture and bge.constraints examples + bgl fixes 2011-08-04 09:47:40 +00:00
0578d55f1e when appending with a NULL context dont print warnigns about scene not being set - was annoying for BGE LibLoad. 2011-08-04 09:47:09 +00:00
af786843b0 patch from jensverwiebe to disable ndof if header is not found. 2011-08-04 08:46:17 +00:00
c284725a1a 3D Audio GSoC:
* versioning stuff for btheme->tv3d.speaker
* separating object.c speaker functions in own source file

Thanks Brecht for the suggestions.
2011-08-04 07:12:03 +00:00
a6fed14da4 stricter guards for disabling NDOF code (will test in 3.. 2.. 1..) 2011-08-04 03:14:00 +00:00
e5e6f91856 fix [#28114] Render Crash
existing check for driver to use GIL was not thread safe and could cause, details in the report.

This bug was caused by a check to avoid hanging, a fix for [#27683] that worked in 2.4x because the UI didn't use python to draw while rendering.

Apply a different fix for [#27683], when calling an operator, call PyEval_SaveThread(), then PyEval_RestoreThread() so the GIL can be aquired by threads started by the operator - in this case bake starting a thread that evaluates drivers.
2011-08-04 01:56:36 +00:00
ecd4b86982 Initial coding of path editing operator. Still needs some work, but all the basic functionality is there. Select a path and the stride bone (as active) and it will reparameterize the path to propel the armature forward in the same magnitude of the original 2011-08-03 22:26:59 +00:00
cbdc67e2e8 Find all key frames for baked animation export. 2011-08-03 19:12:18 +00:00
0031950a74 Fixed issue with IK toggle buttons and added operators for the new limit rotation functions 2011-08-03 18:17:33 +00:00
ab3fc2fa5c Added functions for toggling DOF Constraints on user rig based on range of motion in motion capture clip. Limit Rotation constraints are added based on the min and max of each DOF of each bone in its local space 2011-08-03 18:16:32 +00:00
b9039168fe Fixed coding style to conform to pep8 2011-08-03 18:13:44 +00:00
79c87852d2 Add .py extension if it is missing from keymap file.
This is for bug #28141
While not really a bug, it makes it a lot easyer to use if it 
has the exension.  (Isn't hidden from the user when they try to load it...)

Kent
2011-08-03 17:58:06 +00:00
9eef0646d4 Crash in MMB moves (etc): commit of today was reading NULL pointer. 2011-08-03 14:21:49 +00:00
48a699d15b enable NDOF by default with cmake again, but check if it can be found on OSX, if not disable.
I cant test this but at least if I made a mistake it will just not find the SDK and disable. an osx dev needs to test.
2011-08-03 14:18:02 +00:00
Nathan Letwory
d795a78cb7 Default to False for WITH_BF_3DMOUSE, since needs separate package installed. 2011-08-03 14:04:48 +00:00
fde1dc0fb2 Speaker Object icons, thanks Phil Gosch. 2011-08-03 13:34:49 +00:00
01b105faa5 Cmake: compile with NDOF default off. This is a dependency on code
that's not in our svn.
2011-08-03 13:31:33 +00:00
Nathan Letwory
289ef16fcf Add win64_scons builder 2011-08-03 13:00:11 +00:00
Nathan Letwory
36887bbc82 Add BF_BITNESS for win32/win64 2011-08-03 12:57:38 +00:00
eb9d591898 * Merging trunk up to r38981.
* Fixing a minor issue in a previous commit.
2011-08-03 12:44:52 +00:00
aac8bab172 Fixing terrible typo. 2011-08-03 12:20:07 +00:00
f1fb54e126 Switch slave_pack to use new FFmpeg for windows. 2011-08-03 11:47:03 +00:00
df6dfb93b2 Switch windows buildbot to new FFmpeg 0.8.1.
Hope it'll work because i haven't got buildbot slave by hand.
2011-08-03 11:10:19 +00:00
2c4357c1e1 - Move list of FFmpeg DLLs to be installed from SConstruct
to conficuration variable BF_FFMPEG_DDL.
  This would allow to use different FFmpeg in buildbot.
- Added some 3DMOUSE variables to list of command line options.
  Now 3dmouse related-settings can be set from command line.
2011-08-03 10:50:21 +00:00
461bb17d31 fix [#27965] VSE: no visual feedback on locked strips
added xpm -> opengl stipple conversion script.
2011-08-03 09:28:16 +00:00
6d7490632f 3D Audio GSoC:
* Minor audaspace library improvements.
* Considering location, velocity and orientation in AUD_SequencerReader and AUD_SequencerHandle.
* Bugfix: Maximum and Minimum volume weren't used before in the software device.
* Bugfix: Adding speaker objects via info space crashed.
* Listener settings now get updated in the audio system.
2011-08-03 09:25:40 +00:00
fd35ee8422 - Switch linux buildbot to FFmpeg-0.8.1
- Enable FFmpeg for blenderplayer for linux buildbot.
2011-08-03 09:07:30 +00:00
e320db1066 fix [#28135] Edge slide changes UV 2011-08-03 08:02:32 +00:00
d4909c5628 - Do not add GHOST_NDOFManager.cpp to list of sources if
NDOF is disabled in CMake.
- Added "default" section to switch in sendMotionEvent.
  It's what strict gcc rules don't like much and it's
  And it's good practice in general, imo.
2011-08-03 07:30:24 +00:00
Nathan Letwory
02ab2b473c Debug print removed. 2011-08-03 07:08:28 +00:00
3b541b259f removed attempted WITH_BF_3DMOUSE detection, fixed just one indention (left the others in their ugly new state) 2011-08-03 06:42:55 +00:00
9cf3bcd414 add note in scene.frame_current that frace_set() updates animation data. 2011-08-03 06:30:19 +00:00
6c9d0f2b7a whitespace edits. 2011-08-03 06:27:44 +00:00
a10245a1fa fix [#28151] export OBJ don't save the extension
also correct some typos
2011-08-03 05:32:07 +00:00
6233430c23 compensate for lack of 3D mouse calibration on Windows 2011-08-03 05:01:55 +00:00
2b446aa280 Animation channels can now be renamed by Ctrl-Clicking on them, as in
the Outliner

Channels which can be renamed include:
- Scenes, Objects, World, Material, Texture, etc. (i.e. "ID-blocks",
or the dark and light blue channels)
- Action Groups (green channels)
- Action expanders (i.e. "CubeAction", "WorldAction", etc.)
- Grease Pencil stuff

Channels which CANNOT be renamed, as they mostly use hardcoded values
or otherwise include:
- Drivers expander
- FCurves (they don't technically have a "name"; what is shown is just
a user-friendly representation of their rna_paths)
2011-08-03 01:22:31 +00:00
Nathan Letwory
dc4b104e60 typo fix. 2011-08-02 23:52:07 +00:00
Nathan Letwory
17133e1a1d Compile fix. 2011-08-02 23:49:07 +00:00
3af9651b90 ndof changes: turned off 3D mouse during transform, removed timing bug in image/uv, added option for zoom axis (up/down vs. forward/backward) 2011-08-02 22:50:06 +00:00
4fc56e39bd Patch by oenvoyage - olivier amrein, thanks a lot!
* Material Diffuse Ramp was not greyed out when shadeless was enabled.
2011-08-02 18:56:03 +00:00
Nathan Letwory
5c36b75324 Simple argument to be able to explicitely tell the bitness you want to build Blender in.
python scons\scons.py BF_BITNESS=32
python scons\scons.py BF_BITNESS=64

So from now on for Windows you don't have to run a specific win32 or win64 Python version
to get the Blender version you want. If you omit the BF_BITNESS flag the bitness as per
Python version will be used as before.

Note that this is an argument, so works *only* on the command-line, not in your user-config.py
2011-08-02 18:33:39 +00:00
a9b093d9eb Changes for buildbot rules to use propper spnav library path. 2011-08-02 18:16:48 +00:00
13eefec9dd More flexible configuration for 3dmouse library for scons.
Needed for release environment and buildbot.

Buildbot rules would be updated with next commit after
environment will be tested.
2011-08-02 17:59:43 +00:00
6a37c24115 fix for xvid encoding preset giving a python error 2011-08-02 17:40:27 +00:00
b2959e55f5 Fixes an issue with OSX Lion
Also cleaned up the python detection for OSX 

Kent
2011-08-02 17:35:07 +00:00
2f2a95efb8 Sane defaults for post-retarget fix's framing, and ui bugfix (active icon was showing opposite of real active state) 2011-08-02 17:10:01 +00:00
827f92497e Other bone functionality coded for point post retarget fix. You can now set the point to be offset from a second bone, i.e. follow other bone's path 2011-08-02 17:08:49 +00:00
9026dc6ee4 Fixed a few small typos.
Kent
2011-08-02 17:00:44 +00:00
Nathan Letwory
222190c618 typo fix 2011-08-02 14:45:35 +00:00
4e8e502c02 Merging trunk up to r38932. 2011-08-02 12:16:06 +00:00
de0db6c8da unit arg for FloatVectorProeprty 2011-08-02 10:56:09 +00:00
Nathan Letwory
7561d10c2e Don't include NDOF files when disabled. 2011-08-02 10:50:22 +00:00
Nathan Letwory
467475590e Some more silencing. Enable with BF_GHOST_DEBUG 2011-08-02 10:39:46 +00:00
Nathan Letwory
6bc101fa7e Indentation changes 2011-08-02 10:26:20 +00:00
08426ec2e7 fix [#28148] User Preferences Scripts Path not working 2011-08-02 10:21:25 +00:00
Nathan Letwory
69b4962fc0 Properly disable NDOF code when WITH_INPUT_NDOF is not define. 2011-08-02 10:20:47 +00:00
Nathan Letwory
c1cf646bb7 whitespace 2011-08-02 09:36:44 +00:00
Nathan Letwory
73fc78c5d8 Debug print removed. 2011-08-02 09:18:21 +00:00
Nathan Letwory
f1c68bdbec Don't show NDOF guide by default. 2011-08-02 09:12:58 +00:00
Nathan Letwory
1828e37794 Turn off ndof button debug 2011-08-02 09:09:07 +00:00
Nathan Letwory
28ed1b6745 tabs -> spaces 2011-08-02 09:07:24 +00:00
Nathan Letwory
9e0113890e 3D Mouse support on for windows/msvc by default. 2011-08-02 09:06:55 +00:00
078dff64d2 no functional changes.
style edits, also renamed ndof_to_angle_axis --> ndof_to_axis_angle
2011-08-02 08:12:50 +00:00
d4a6884fcf add back timer based redraw, not sure why this was removed r38908.
Zealous redraws now use commented define.
2011-08-02 07:49:34 +00:00
70b4758ff8 Made wmNDOFMotionData use a vector rather then xyz members, makes it nicer to use with math functions.
ndof_to_angle_axis and ndof_to_quat now use math functions.
2011-08-02 07:08:22 +00:00
2e860a3e85 - Blender could be build with scons again. 2011-08-02 07:02:40 +00:00
ed306416f5 replace WM_OT_ndof_menu with a key->menu assignment. 2011-08-02 06:40:40 +00:00
baa37b1b46 more cmake/x11 edits
- added includes for spnav
- added FindSpacenav.cmake which allows using spacenav from a nonstandard path.
- remove NDOF_LIBPATH, use a full library path instead.
2011-08-02 06:32:53 +00:00
fcd7d2b486 NDOF related edits
- fix for building without NDOF on X11
- quiet some warnings
2011-08-02 05:52:27 +00:00
f5cff8ad37 BGE Animations: Fixing a crash when an fcurve actuator is found, but the object doesn't have animation data (adt). 2011-08-02 05:49:11 +00:00
8f3016098d SVN maintenance. 2011-08-02 05:31:32 +00:00
56918978b7 3D mouse support from merwin-spacenav branch 2011-08-02 04:28:05 +00:00
db494472ac don't include fcurve modifiers when getting an actions frame range.
could too easily give a range of 600,000 which would make exporters hang.
2011-08-02 02:28:37 +00:00
dc2609da3d svn merge -r38814:38905 https://svn.blender.org/svnroot/bf-blender/trunk/blender . 2011-08-02 01:01:56 +00:00
03c1585e3a BGE Animations: BGEDeformVerts() now handles normals instead of relying on BL_MeshDeformer::RecalcNormals(), which BlenderDeformVerts() still uses. As expected, the BGEDeformVerts() version isn't as accurate, but it avoids a sqrt per vertex. This gives about a 15~20% improvement in time spent on the rasterizer in my test scene, which resulted in about 5 more fps. However, the main reason for the new normal code is it will be easier to do on the GPU (doesn't rely on neighbor information). 2011-08-01 23:02:10 +00:00
3e85ec432e 3D Audio GSoC:
Adds new speaker object type.

Notes:
* Needs some nice icons
* Quickily review by Joshua Leung (5 mins)
* Properties UI updated (with help of Thomans Dinges)
* Speakers have their own theme color
* No real audio functionality yet.
* Minor bug regarding lamps/lattices fixed in interface_templates.c

I personality tested:
* Creation, Deletion, Duplication
* Saving, Loading
* Library linking (incl. make local)
* Tracking
* Dope Sheet, Outliner
* Animation
* Drawing (incl. Theme)
2011-08-01 11:44:20 +00:00
c965d1d2cc fix [#28061] Texture (paint) bleeding on edges
respect clamp u/v image options.
2011-08-01 08:53:57 +00:00
2f3685615f fix for template 2011-08-01 06:55:05 +00:00
cd793378db fix [#28112] Vertex paint crash 2011-08-01 06:50:24 +00:00
dde50cc39f add sse flags for cmake/msvc 2011-08-01 06:11:41 +00:00
af39f26360 fix, uvproject modifier wasn't copying the uv layer name,
also edit var names from recent commit to better fit with other functions.
2011-08-01 05:25:30 +00:00
9da712a581 replace dutch variable name 'aantal' with 'tot' 2011-08-01 02:58:44 +00:00
f48b906261 fix for failure to create curve knots when both endpoint and bezier U were enabled.
use default when invalid settings given.

removed odd/annoying bit shifting of the flagu/v for such basic function made code hard to understand and would fail if new flags were added.
2011-08-01 02:52:08 +00:00
19b38034f9 support for older SpacePilot (sans Pro), minor tidying 2011-07-31 22:59:36 +00:00
5c8344bcc9 Bug fix: loading a file that had particles using a dupligroup from a liblinked file without the library file being present crashed 2011-07-31 16:26:02 +00:00
2620bd0ade fix for error in recent commit. 2011-07-31 12:46:34 +00:00
c74bb09584 fix for material slot removal (r38879)
- The object ID was being passed to the data_delete_material_index_id() from object_remove_material_slot(), rather then the object data. (so the material slot fix wouldnt run in that case).
- add support for fixing text object materials too.
2011-07-31 12:43:41 +00:00
Dalai Felinto
5b3bb37343 reverting part of #38876 (whitespace edits)
the new if/else nesting introduced in the previous commit makes no sense.
(since I was here I add a comment for extrainfo and did some small cleanup)
2011-07-31 11:21:48 +00:00
Dalai Felinto
432bd158fb bugfix [#28111] material.pop breaks mt->mat_nr
create a new parameter for materials.pop() to not remove material slot.
this way the mat_nr is still the old one.

for the default behaviour we now have material remapping (i.e. data_delete_material_index_id(id, index)).
This new function is brought from the material_slot remove function.
2011-07-31 11:12:38 +00:00
f4a1dc4c8d when converting curves from poly -> nurbs, dont enable Bezier-U flag.
Not sure why this was enabled, possibly from copy/paste with bezier->nurbs code?

If you have meny poly lines there was no nice way to convert these into a smoothed nurbs curve.
Ran into this when trying to convert generated ivy into smooth nurbs.
2011-07-31 07:58:50 +00:00
c7a1a19153 whitespace edits, had odd space/tab mix 2011-07-31 07:54:24 +00:00
c19e88ac26 fix for building without bullet 2011-07-31 07:45:54 +00:00
679b528177 fix for immobile camera (NDOF_SHOULD_ROTATE etc.) -- should revisit later 2011-07-31 06:26:03 +00:00
e8c3c4097a SVN maintenance. 2011-07-31 06:03:14 +00:00
f3c867c3db Camera Clipping animation COLLADA support fix. 2011-07-31 05:04:12 +00:00
f4293067c1 py api: sphinx doc corrections, pep8 cleanup and style edits, also added __all__ to some modules which were missing it. 2011-07-31 03:15:37 +00:00
4745e3da12 improved ndof fly: precision mode, camera position, camera animation 2011-07-31 03:06:00 +00:00
670f58023c == PBVH ==
OK, after that failure of committing a bunch of old junk, hopefully
this is what I actually meant to commit :)

* Added big comments to some of the fields in struct PBVHNode. I
  always forget the details of these, so finally wrote it down
  properly.

* Changed types of PBVHNode.face_vert_indices and PBVHNode.flag to
  better reflect their contents.

* There should be no functional changes here.
2011-07-31 02:34:53 +00:00
6c3bb8b903 EditMesh-based skin node drawing 2011-07-31 02:03:48 +00:00
cff57b14a1 Imported bsphere.c, mostly ifdef'd out for now 2011-07-31 02:03:39 +00:00
ccf186017a Added stub for Skin modifier UI 2011-07-31 02:03:33 +00:00
cae05598b1 Added DNA and RNA for skin modifier, stubbed in skin modifier functions 2011-07-31 02:03:28 +00:00
601eb68420 Added SkinNode DNA and customdata. 2011-07-31 02:03:21 +00:00
Dalai Felinto
dfc661565a patch [#27909] Added constants in bge.constraints by Solano Felicio (solano) + some changes in rst
I named all the BGE modules with their actual names (e.g. Rasterizer, Video Texture, ...). so in the API index.html page they look more like the other Blender modules.
I did the same for the bgl module.

For bge.constraints this patch exposes the constants values for debug mode and createConstraints (they were hardcoded innts before).

+ making all the "todo" and #comments into rst comments (.. comments)
Thanks Solano, it's great to get help to those tasks :)
2011-07-30 23:16:22 +00:00
6e788c37df Hides console on win32 even if python path is 2 or more lines
Adding tlhelp32.h header
2011-07-30 19:09:34 +00:00
d3edf274b0 BGE Animations: This should solve the issue with NULL not being defined in BL_ActionManager.cpp 2011-07-30 17:27:54 +00:00
4b5a371b65 3D Audio GSoC:
* Fix for sequencer strip IDs, only one strip played.
* Fix for PyAPI sample rate.
* Enhanced Double Reader to return more data if possible.
2011-07-30 16:24:11 +00:00
805a169f70 Bugfix #28121
Linked Library objects or object->data should not allow to go
to sculptmode. Also cleaned up mode menu with invalid entries then.
2011-07-30 15:45:27 +00:00
d163ce5595 bpy fix for crash/assert on running dir() on a non collection property + some other minor corrections. 2011-07-30 13:18:04 +00:00
681b26a48e Bugfix #28109
Old issue with OSX Cocoa code: shift+scrollwheel should send
a 'horizontal wheel' event to Blender. Blender only recognizes
scroll events in general though. The old code then just didn't
send an event at all, not passing on shift+scrolls.

Now the scroll event is sent anyway, relying on Blender's
keymapping to define what to do with shift+scroll.

This fixes things like shift+scroll to scale ListBox widgets.
2011-07-30 10:14:50 +00:00
f66ec41b6a quiet some compiler warnings & fix possible (but unlikely) crash.
also added GPLv2+ header to resources.c.
2011-07-30 09:24:10 +00:00
632f59c7bc improved visual rotation guide 2011-07-30 05:23:10 +00:00
73183abfa9 Removing some unused code - old gp editing stuff 2011-07-30 05:07:34 +00:00
e9fed9bd8c Bugfix: When only one handle was selected in Graph Editor, the line of
the other handle were not drawn

This only happened when the "only on selected keyframes" option was
enabled
2011-07-30 05:04:49 +00:00
387439390d BGE Animations: Fixing some warnings from GCC about initialization order. 2011-07-29 21:58:31 +00:00
29f214f7f3 Merging up to trunk r38834. 2011-07-29 21:28:18 +00:00
aec91c0cf5 ndof sensitivity operator follows power curve and respects min/max 2011-07-29 21:07:51 +00:00
6a27da310c While looking at the bug report, found some more issues...
This is the result of RNA renaming at it's glance. ;-)
2011-07-29 20:59:46 +00:00
99997ccd18 Fix for [#28117] Diffuse reflection IPO curve not imported correctly from 2.49b files 2011-07-29 20:46:30 +00:00
6b987910e4 Patch [#27925] by Andrew Cox and me
Modifier key sticks after Alt-tab on Win32
2011-07-29 20:21:37 +00:00
ce1c78e18b Changed name of Mocap constraints to mocap fixes, for user clarity. 2011-07-29 18:23:16 +00:00
ce20487fa7 Merging r38765 through r38817 from trunk into vgroup_modifiers. 2011-07-29 13:45:22 +00:00
a22f75606e vgroup_modifiers: Fixed last problems with WP mode, plus a small fix in weightvg_util.c.
It seems WeightVG modifiers can’t enable the eModifierTypeFlag_SupportsMapping flag...
2011-07-29 13:25:58 +00:00
Nathan Letwory
24def76ac8 svn merge -r38753:38813 https://svn.blender.org/svnroot/bf-blender/trunk/blender . 2011-07-29 07:58:03 +00:00
Lukas Toenne
fb738f4929 When relinking node group outputs from sockets of different type, automatically change the output to the source type. Feature request by Daniel Salazar. 2011-07-29 07:14:03 +00:00
e4a512351d BGE Animations: Save the deform number to pose channel map created by BL_SkinDeformer::BGEDeformVerts() so it isn't recreated on every update. This gives minor speed ups, but I mostly did it because I thought it was a little cleaner this way. 2011-07-29 01:59:36 +00:00
2658949752 pep8 cleanup, also print message when attempting to run in animation player mode. 2011-07-29 01:24:03 +00:00
f9ef37059d Material transparency animation COLLADA export. 2011-07-28 18:25:23 +00:00
336a47cdcf * Code cleanup
A row with alignment for 1 property = useless: ;-)
2011-07-28 18:19:15 +00:00
6d2754e07d Fix #27719: custom RNA properties fail to update drivers. Hopefully this is
not too slow, but now we do a dependency graph tag also for these in addition
to regular ID properties, not sure how to get around it.
2011-07-28 15:51:59 +00:00
eb7b1f0c58 This allows the game engine to build again, but I'm not sure if it's the best approach. Aligorith: feel free to revert this if there is a better solution. 2011-07-28 15:07:32 +00:00
b8dcf3a662 Fix part of #27944: color managment discrepancy in GLSL materials with nodes. 2011-07-28 14:28:27 +00:00
bd6ca0570e 3D Audio GSoC:
Implemented basic audio animation.

* AnimatableProperty: Propper cache writing and spline interpolation for reading (the solution for stair steps in audio animation)
* Animatable properties so far are: volume, pitch, panning
* Users note: Changing the pitch of a sound results in wrong seeking, due to the resulting playback length difference.
* Users note: Panning only works for mono sources, values are in the range [-2..2], this basically controls the angle of the sound, 0 is front, -1 left, 1 right and 2 and -2 are back. Typical stereo panning only supports [-1..1].
* Disabled animation of audio related ffmpeg output parameters.
* Scene Audio Panel: 3D Listener settings also for Renderer, new Volume property (animatable!), Update/Bake buttons for animation problems, moved sampling rate and channel count here
2011-07-28 13:58:59 +00:00
Nathan Letwory
d55f6c64a2 speed button mapping to ndof sensitivity change operator. 2011-07-28 13:44:36 +00:00
b948459031 fix [#28096] Custom gradient for weightpainting in mask mode not working properly. 2011-07-28 12:17:24 +00:00
2dc826f083 New option for multires modifier: Subdivide UVs
Enabled by default and also enabled for older filesm so
there should be no regressions.

In some cases it's useful to not use subdivided uvs for multires.
2011-07-28 11:16:10 +00:00
722474a7ea fix [#28095] Select Pattern don't select all the bone in edit mode
& some style changes.
2011-07-28 07:55:09 +00:00
b71ccf3e06 fix error in writing dupligroups for X3D export, may have effected other exporters too. 2011-07-28 07:10:39 +00:00
e2522cead2 report an error when user blender versions other then 2.4x for animation playback. 2011-07-28 05:09:31 +00:00
784a68e8f1 sequencer add strips now check for overlap by default (option can be disabled for python when this can become problematic for automation). 2011-07-28 03:44:17 +00:00
0facd795f8 automatically update the redirect from http://www.blender.org/documentation/250PythonDoc/ when uploading docs 2011-07-28 03:08:35 +00:00
a5631dba89 only initialize snap from the scene settings for view3d and image spaces since snap in the 3D view was enabling snap in the graph editor and sequencer without a button to disable it in those spaces. 2011-07-28 02:15:58 +00:00
fb99e23205 minor cleanup of rna
- use an rna enum-set for proximity vert/edge/face options.
- rename some flags.
- better conform to rna naming conventions.
2011-07-28 01:38:48 +00:00
Nathan Letwory
7e87165eea Don't write library_materials tag when there are no materials. 2011-07-28 00:08:03 +00:00
Dalai Felinto
f532ccedf5 refix for #27912: crash after mesh.materials.pop() (fixed wrongly on rev. 38299 - patch by Benoit Boilsee
bug spotted while reviewing a patch.
things are working now
2011-07-27 20:36:11 +00:00
90b64737f1 Material Diffuse Color animation COLLADA import. 2011-07-27 19:08:18 +00:00
b830c0e394 Merging r38740 through r38764 from trunk into vgroup_modifiers. 2011-07-27 18:57:57 +00:00
048eabf302 vgroup_modifiers: coded a way to test whether the dm needs to be copied (i.e. if the affected cdata layer is or not the original one).
However, as this piece of code tends to slow down things (see e.g. scene 5 of WeightVG test blend file), I deactivated it for now...
2011-07-27 18:48:23 +00:00
4a32691416 Material diffuse color animation COLLADA export. 2011-07-27 18:38:44 +00:00
7e466266d3 fix [#28098] Continuous Grab does not work for movement of the "Backdrop" in the Node Editor 2011-07-27 17:49:35 +00:00
41216990dc Material Specular Color Animation import. 2011-07-27 17:43:32 +00:00
5fc54a7ccc Material Effect Specular color animation Export. 2011-07-27 16:29:28 +00:00
3b6cb504b1 minor warning fixes for clang-static-checker 2011-07-27 13:03:56 +00:00
Nathan Letwory
73a9ce7ec0 svn merge -r38558:38752 https://svn.blender.org/svnroot/bf-blender/trunk/blender . 2011-07-27 07:42:53 +00:00
46cea37266 fix [#28066] Unchecking 'self project' messes up 'Snap to Vertex'
this option is useful for all non-grid snapping modes (when in editmode) so make available in those cases too.
2011-07-27 07:22:31 +00:00
48a64ffa70 more minor warning cleanups and improve error reporting if text fails to save. 2011-07-27 06:55:20 +00:00
f54068719f shift-motion to pan with 3D mouse 2011-07-26 22:43:07 +00:00
955ba3f7fb * Fixed a typo in the code (uiLayoutItemSplt -> uiLayoutItemSplit) 2011-07-26 20:22:54 +00:00
9a250bea61 Fix part of [#28088] bad button spacing with layout engine for menu items.
* Fixed a cut off text. 
* small cleanup
2011-07-26 20:05:17 +00:00
a460299b08 - bugfix for icon listview where the icons would only wrap once
- also quiet some clang warnings
2011-07-26 19:47:56 +00:00
af286ac95b vgroup_modifiers: Addressed most ideasman’s remarks and suggestions in his last review.
*Removed curve init code in readfile (no more needed since the split broke anyway compatibility with earlier WeightVGroup files…).
*Updated get_ob2ob_distance() code (much simpler – I’m not a matrices’ god!).
*Enhanced a few RNA names (Campbell has others in mind here, though, I think).
2011-07-26 18:51:35 +00:00
07dc73fa31 Merging r38694 through r38739 from trunk into vgroup_modifiers 2011-07-26 18:28:43 +00:00
40e36975ef Blender profile leaf bone tip import. 2011-07-26 18:28:07 +00:00
37aa6a5e3d onscreen ndof rotation guide (center + axis) 2011-07-26 16:17:00 +00:00
3e81de486a RNA: function calls with optional parameters were not giving correct default
values for arrays.
2011-07-26 16:01:09 +00:00
9077b8bffc 3D Audio GSoC:
Main: Complete rewrite of the sequencer related audio code to support 3D Audio objects later and especially adressing the animation system problems (see mailing list if interested).
Note: Animation is not working yet, so with this commit volume animation doesn't work anymore, that's the next step.

Minor things:
* Changed AUD_Reference behaviour a little to be more usage safe.
* Fixed bug in AUD_I3DHandle: Missing virtual destructor
* Fixed enmus in AUD_Space.h
* Fixed a warning in rna_scene.c
* Removed an unneeded call in rna_sound.c
2011-07-26 13:56:31 +00:00
c0373fb7ea startup.blend Theming/AnimEditor Defaults Tweaks
- Default size of Graph Editor handle vertices is now 4 (up from 3).
This "small" change seems to be enough to make a substantial
difference when it comes to actually differentiating between these

- "Only Selected" DopeSheet filter is enabled for new Graph Editor
instances by default. It helps hone in on the F-Curves of the data
most animators hope to just be refining the motion for (i.e. the
selected stuff)

- "Only Selected Keyframe Handles" is now enabled, to reduce clutter
from handles of nearby keys getting in the way.
2011-07-26 13:49:39 +00:00
ca293c835f correct misc warnings 2011-07-26 13:33:04 +00:00
785e634c23 F-Curve Drawing - Smoother curves
Bezier curves are now drawn smoother (i.e. less segmented), especially
for curve segments where there is a very large vertical displacement
over a short period of time (i.e. 120 degrees rotation over 1 frame)
and/or often when zoomed in a bit too.

- Made the resolution calculation take the vertical distance into
account too, instead of just the horizontal distance.
- Segment multiplier changed from 3 to 5, as this seems to give better
zoomed-in performance.
2011-07-26 13:09:10 +00:00
40353fe0d8 fix for NULL pointer crash with operator repeat, looks like error print got mixed up. 2011-07-26 13:05:22 +00:00
77e906cbd4 Experimental drawing tweak: make active F-Curve get drawn with thicker
line width

This should help make it stand out better from the background, though
it has the risk that values may not be so clearly picked up visually
2011-07-26 12:49:43 +00:00
06ae122f60 include menu ID's in tooltips when python tips are enabled, there was no way to find the ID of a menu which become annoying if you wanted to reference it from a script. 2011-07-26 09:19:51 +00:00
7c9033d606 Fix #28087: Opening files in the text editor ignores the last newline '\n'
It was tricky conversion of file buffer to text lines. Should work fine now.
2011-07-26 08:13:27 +00:00
9e1a553127 set the development cycle to 'beta'. 2011-07-26 07:41:14 +00:00
71692e802f py api:
- added menu templates
- move template menu into the header of the text editor (so users will find more easily)
- updated mathutils examples, switching the order of multiplication.
2011-07-26 07:39:00 +00:00
1f65b3b1a8 BGE Animations: Adding a new choice for vertex deformation for armatures, which can be found in the Armature's Skeleton panel by the Deform options. Before only Blender's armature_deform_verts() was used. Now users can choose a vertex deformation function that is optimized for the BGE. At the moment it is mostly a copy of armature_deform_verts() with various chunks of code removed, and the BLI_math code was replaced with Eigen2. In my test scene, the new function offered about a 40% improvement over armature_deform_verts() (17~19ms rasterizer to 11~12ms). The only current limitation that I'm aware of if that B-Bone segments are not supported in the BGE version, and I will probably leave it out. I would like to also limit the BGE version to 4 weights to make things easier for a GPU version, but this may just make things slower (sorting weights to find the top 4). 2011-07-26 06:10:05 +00:00
72f70874bb experimental onscreen rotation guide 2011-07-26 02:35:46 +00:00
5b3906728f Fix #28035: point density texture doesn't bake. 2011-07-25 16:37:10 +00:00
aec8d72ca7 Fix #28079: UV propertional editing was incorrectly influenced by the
mesh X mirror option.
2011-07-25 16:16:32 +00:00
62415cab05 Fix #28014: joystick sensor not working. Broke this with an earlier commit
trying to fix blenderplayer startup warnings. It seems we do need to init
the SDL video subsystem even if we only want events, thanks Juha Maki-Kanto
for pointing this out.
2011-07-25 15:44:41 +00:00
Dalai Felinto
fee1594a65 BGE BugFix for: [#23874] Custom projection matrix doesn't work in custom viewport
This was never highly tested, that's why I never committed (my patch for this was from September 2010).

But once again I got a report that this bug was a deal-break and the patch seems to work for this artist.
I believe it's working, but I will keep my eyes open for this.
2011-07-25 15:37:55 +00:00
1e2e080853 Adding WeightVG modifiers code. Still some points to tweak, though.
NOTE : Haven’t yet tested build with scons, will do asap (unless someone else does :) ).
2011-07-25 15:27:01 +00:00
110f6d81ec Branch for vertex group modifiers 2011-07-25 14:48:01 +00:00
e882925b49 more vector order switching. 2011-07-25 09:31:39 +00:00
799714fbc9 minor edits to animation playback operator
- remove own copyright from script
- print command before executing (helps troubleshooting)
2011-07-25 07:14:54 +00:00
4f4eeb826a style changes for operator scripts & some pep8 edits. 2011-07-25 06:40:16 +00:00
6065390f4c fix for DingTo's recent commit with the animation player, it ignored the case where the player is not an absolute path but found in the users $PATH (as is common on *nix systems).
now try and execute player, reporting the exception rather then checking the player file exists.
also made some pep8-80 style edits.
2011-07-25 06:38:21 +00:00
a07d7edb82 swap vertor multiplication order for add torus. 2011-07-25 06:09:39 +00:00
d4552034c6 edits to quick effects scripts
- use uv layer data api rather then operator.
- switch vector rotation order.
- made some style changes, use 80 width.
2011-07-25 05:54:32 +00:00
3e91de7ffd External image operators.
- use bpy.data.is_saved (was using a workaround from when before this attribute was added)
- fixed a bug where editing relative paths could fail.
2011-07-25 05:10:44 +00:00
5132be21d1 fix [#28075] After the correction of No.38528 is applied, the following phenomenon has been generated.
own fault in recent addition of bpy.path.basename() not supporting byte paths.
2011-07-25 04:00:11 +00:00
7f60ee6cb5 reverse vector multiplication order for some internal functions. 2011-07-25 03:59:01 +00:00
4b8233423b invert axes option affects trackball navigation 2011-07-25 03:13:15 +00:00
ced8f1dffc deprecate multiplication orders:
vector * matrix
 vector *= matrix
 vector * quaternion
 vector *= quaternion 

Use the reverse order instead, enable WITH_ASSERT_ABORT in cmake to promote the warnings into errors.
2011-07-25 01:44:19 +00:00
876e0c2a8b updated ndof popup menu (part 2 of 2) 2011-07-25 00:21:35 +00:00
c692351fdf added option to invert axes for orbiting (part 1 of 2) 2011-07-25 00:20:45 +00:00
e31fef1d94 set default values for all other ndof flags 2011-07-25 00:10:42 +00:00
73417bfbb5 spoof MOUSEMOVE after NDOF_MOTION event, added comments 2011-07-25 00:03:07 +00:00
abf658d367 removed old ndof transform stuff, added experimental ndof nav during transform (might disable for release) 2011-07-25 00:00:53 +00:00
1e0e0ff5c4 Blender profile for leaf_bone tip. (untested). 2011-07-24 20:27:27 +00:00
a22de3f73c Effector calculations are now thread safe.
* where_is_object_time was called for every effector evaluation only to determine the object velocity in some rare cases.
* Calculating the effector velocity is now done in the effector precalculation stage.
* Removing this makes the code thread safe and also should give some nice performance boosts when simulating a lot of points.
* Thanks to MiikaH for noticing this problem.
2011-07-24 17:44:22 +00:00
4ab7c6ae1a 2.5 World Buttons:
* Exposure and Color Range buttons were missing, added them back.
2011-07-24 11:24:30 +00:00
b401d09d8f * Minor code cleanup / comment changing. No functional changes. 2011-07-24 11:11:23 +00:00
b154b59938 New dilation function from Morten Mikkelsen (aka sparky).
This commit fixes very noticeable seams caused by margins
calculated incorrectly. This commit changes way margin is
calculated in and makes textures really seamless.

Also margin limited to 32 isn't good now -- artists are baking
really large textures nowadays so margin is now limited to 64px.

Thank you, Morten!
2011-07-24 10:26:22 +00:00
Nathan Letwory
6149526aac Default for ndof_sensitivity to 1.0 in case 0.0 is found on start. 2011-07-24 08:50:09 +00:00
Nathan Letwory
c4bda1370c Add mapping for front/right/top aligned to selected object. 2011-07-24 08:37:43 +00:00
1ca4f1ba1c sculpt/paint while using 3D mouse 2011-07-24 08:02:42 +00:00
6a392e8cb5 == RNA Property Updates get called by Animation System now ==
This fixes bug #26764 and several others like it, where modifier
properties (and others, but most visibly modifiers) would not do
anything when animated or driven, as modifier properties require the
RNA update calls to tag the modifiers to get recalculated.

While just adding a call to RNA_property_update() could have gotten
this working (as per the Campbell's patch attached in the report, and
also my own attempt #25881). However, on production rigs, the
performance cost of this is untenatable (on my own tests, without
these updates, I was getting ~5fps on such a rig, but only 0.9fps or
possibly even worse with the updates added).

Hence, this commit adds a property-update caching system to the RNA
level, which aims to reduce to the number of times that the update
functions end up needing to get called.

While this is much faster than without the caching, I also added an
optimisation for pose bones (which are numerous in production rigs) so
that their property updates are skipped, since they are useless to the
animsys (they only tag the depsgraph for updating). This gets things
moving at a more acceptable framerate.
2011-07-24 04:34:46 +00:00
cb2423e849 Add Push/Pull to toolbar 2011-07-24 00:59:03 +00:00
c2c62134cc minor cleanup of Mac ndof manager 2011-07-24 00:52:18 +00:00
ed232c756d ndof overall sensitivity is now live 2011-07-24 00:40:39 +00:00
43994ce213 2.5:
* Removed some old not used code.
2011-07-23 22:08:37 +00:00
b9f3ff5435 removed ancient ndof global, removed my own attempt at a C popup menu (the Python one works) 2011-07-23 21:55:52 +00:00
39edc53558 2.5 External animation player:
* Fixed an error when "Custom" was used and the path was empty (variable reference before assignment)
* The Operator now raises an error if there is no path or the path given is not available.
2011-07-23 21:45:22 +00:00
ff5a49b816 another CMake build fix (contributed by Kevin Cozens) 2011-07-23 21:33:04 +00:00
5fae765187 more cautious device detection, minor cleanup 2011-07-23 21:29:19 +00:00
c22f26d203 Material Hardness Animation Import Complete. 2011-07-23 20:49:26 +00:00
Dalai Felinto
742225d9b4 bugfix: [#28026] Copy Game Property broken
not exactly a bug, but the option to copy individual properties was not working from the SPACE menu.
I believe this was happening because we are using dynamic enums.

This commit makes the "merge" option to be the default one. So if you call it from the SPACE menu it will be the one used.
2011-07-23 18:03:01 +00:00
682cc63161 Merging with trunk up to r38631. 2011-07-23 16:34:30 +00:00
f4a30e473b Cherry pick merge: /branches/soc-2011-pepper/intern/audaspace/OpenAL:r38630
Original log: Corrected the OpenAL device's threading code. This is a bugfix for #27913, thanks to Juha Mäki-Kanto for helping to resolve this.
2011-07-23 16:08:37 +00:00
1193be6eaa 3D Audio GSoC:
* Reviewed and improved the linear resampler. Now it should work pretty good also for special cases that caused errors previously.
* Fixed a crash in the GE when a sound actuator doesn't have a sound assigned.
* Corrected the OpenAL device's threading code. This is a bugfix for #27913, thanks to Juha Mäki-Kanto for helping to resolve this.
2011-07-23 15:59:10 +00:00
8cbd88aeef 2.5 UI:
* Added back icon to open the Splash Screen in the info header, next to version string info.
* Removed an unnecessary toggle argument for particle mode select buttons. The Toggle argument is only intended for booleans, not enums.
2011-07-23 15:36:51 +00:00
fd79de0bb3 NLA Track for custom user tweaks is now added after retargeting 2011-07-22 18:46:59 +00:00
d959f77e79 UI makeover for mocap constraints panel. Now has the look and feel of regular Blender constraints 2011-07-22 18:46:13 +00:00
ffc490cbf1 Two fixes in drop-node-on-noodle:
- Intersection code was using undefined vector
  caused wrong lines to be picked
- Code now also copes with hidden sockets. 
  If all fails, is just unhides a good socket.
2011-07-22 16:39:06 +00:00
eed7702c99 Small fix in drop-node-on-noodle: intersect code only did 3 edges of
node.
2011-07-22 16:02:56 +00:00
89c062038a Let's try default High Quality for object align, it's slow but it's simply the correct way, users can disable while tweaking the align modes and then enable again for final result IF they are working on *dense* meshes 2011-07-22 15:54:54 +00:00
ea90544d65 Need some fun once a while:
On dragging a non-connected node on a noodle, it will insert it.
Functionality tweaks are possible, but it already feels non-intrusive.

Rules:
- Insertion only when a single noodle is intersecting with node.
- Default connects first matching socket type. 
- If no socket match, it connects the first.
2011-07-22 15:28:50 +00:00
Nathan Letwory
8c5f028f4a Fix compile error due to faulty merge. 2011-07-22 14:13:28 +00:00
75029e1119 Bugfix [#27990] Merge Bones freezes Blender
Recoded side-chain reparenting step to fix (as far as I've been able
to tell) infinite looping problems which were a bit intermittent here
using the test file. The fix here involves some tighter checks to
prevent corrupting the parenting of bones in the run of bones being
merged but also of any ancestors of those.
2011-07-22 13:52:31 +00:00
1e19f1cde1 Bugfix [#27959] Error on Paste X-Fliped pose
Paste pose no longer just does a blind "replace all properties" on
bones that it pastes on. Instead:
* when properties exist on the target already - only change the
properties in common
* when properties don't already exist - copy all properties
2011-07-22 11:53:20 +00:00
382050501d remove duplicate function for printing the current file:line of a python script in the BGE. 2011-07-22 11:21:01 +00:00
0adad30e3f Bugfix [#27984] CTRL+T doesn't work in Video Sequencer properly
Time-scale drawing wasn't respecting the time unit setting.

While working on this, I tried to tweak the grid drawing to a more
common setting. It's hardcoded to show lines at every 25 px = once
every 25 frames, which is only really fine when FPS=25. Anyways, this
works fine enough for the sequencer for now in general usage.
2011-07-22 11:20:14 +00:00
1ca2a6f24f Split up recalcData() function in transform_generics.c into smaller
functions based on editor types

This could be split up further in future if there's such a need, but
this should already be sufficient. Most notably required since the NLA
recalc stuff was taking quite a few lines within that block
2011-07-22 07:25:52 +00:00
0e933d089d fix [#27910] baking ambient occlusion, do not consider closer object for blender 2.58a 2011-07-22 05:33:06 +00:00
30da1336a8 patch [#28045] Straighten tool from Simple Todos
from Kyle Mills (khonkhortisan)
2011-07-22 01:21:20 +00:00
6040a28f03 missed this file when adding option to disable frameserver 2011-07-22 00:34:03 +00:00
03bae345be fix [#28053] New material tooltip 2011-07-22 00:31:24 +00:00
58895bee7b fix [#28052] PET: Shift-O cycling skips "random falloff" 2011-07-21 23:36:17 +00:00
e6604288c8 cmake - option to disable the frame server 2011-07-21 23:06:51 +00:00
Nathan Letwory
7b1bb26135 Show NDOF sensitivity field in userprefs 2011-07-21 22:26:58 +00:00
Nathan Letwory
32004f11aa Keymap editor now understands NDOF (button) events too. 2011-07-21 21:43:42 +00:00
407a2a8439 tweaked ephemeral ndof data types 2011-07-21 21:40:04 +00:00
Nathan Letwory
2258afc1be Handle NDOF events on RNA side for windowmanager. 2011-07-21 21:40:00 +00:00
6cd4716d1a enable CMake builds with spacenav (contributed by Kevin Cozens) 2011-07-21 21:34:28 +00:00
2c798fd86d Adding Shear transform to UV menu and Ctrl Alt Shift S hotkey (same as in 3D View) 2011-07-21 21:34:08 +00:00
4532bd731d Merge with trunk up to r38584. 2011-07-21 21:11:58 +00:00
Nathan Letwory
1cce0dd505 Prepare for NDOF event handling all the way to keymaps (and keymap editor). 2011-07-21 20:57:23 +00:00
Nathan Letwory
b326a6841e Simple ifndef guards, so we don't get redefines. 2011-07-21 20:54:47 +00:00
cf34f7509f 2011-07-21 18:31:01 +00:00
bbfe3c9c49 Bugfix #28034
Blender render optimizes alpha=0 materials away, unless it has
a number of properties... but there wasn't a check for material
being ray-mirror, it then should be rendered always.
2011-07-21 17:40:20 +00:00
3e9d1d7683 Corrected View Selected operator for image editor so now it works
fine for images with different X and Y aspect ratio.
2011-07-21 09:50:39 +00:00
Nathan Letwory
eea7c358c7 svn merge -r37276:38555 https://svn.blender.org/svnroot/bf-blender/trunk/blender . 2011-07-21 09:40:59 +00:00
e7669caf5a Fixed bug with multires baking to float buffers.
Was missed a flag to set rect marked as changed.
2011-07-21 08:10:34 +00:00
314fdb941e revert recent matrix multiplication patch:
[#28032] Python Mathutils: Matrix Multiplication Error

Since they ended up reversing the order we better keep old code unless its proven to be incorrect.
also change Matrix.__repr__ function args to evaluate correctly (need to be inside a tuple).
2011-07-21 02:00:29 +00:00
c608288d76 add tip that duplicator system doesnt support xray / transp object draw options since we keep getting reports about this. 2011-07-21 01:37:15 +00:00
98774eba0e fix [#28037] Missing orange selection lines (trivial)
From what I can tell there is no good fix for this bug, calculating the 2d/3d viewborder and then attempting to align them to be pixel perfect fails because of float imprecision.

Added a workaround, so the camera border is always drawn in 2d space,
since this workaround may cause problems later on its kept under the define VIEW3D_CAMERA_BORDER_HACK so we can get old behavior back easily.
2011-07-21 01:30:26 +00:00
28780342ed fix/workaround [#28040] float images reduced to 256 levels per channel upon save
Generated images would not be re-generated with a float buffer on load, even when selected on creation.
Now save the float buffer setting as a generated image flag.

This means you can enable before baking to enable baking to a float buffer.
2011-07-21 00:41:00 +00:00
74111ac11c Attempted bugfix: don't perform any keyframe remapping stuff if
rendering, to prevent any race condition problems

I've noticed some weird and random crashes recently while rendering,
which I suspect have been arising from having an Action Editor open
while rendering. Previously only the timeline was patched against
these problems, though the issues may be more widespread. Hence,
solving this problem at the root cause instead.
2011-07-21 00:07:07 +00:00
a08a510d65 Two new operators for easier retargeting: Auto scale performer, and a first attempt at auto hiearchy mapping 2011-07-20 21:03:06 +00:00
76e91d7a5f fix [#27922] using preset_paths() with an absolute path returns twice the same thing
raise an error when an invalid subdir is passed to preset_paths()
2011-07-20 15:33:27 +00:00
2c61949179 venomgfx request: Renaming handle 1/2 to left/right handles for
keyframes

This makes it easier to remember/identify which one you're dealing
with
2011-07-20 12:44:29 +00:00
4ad43aaf16 added bpy.path.basename because "//" prefix breaks os.path.basename. 2011-07-20 08:10:01 +00:00
8b5e7f2650 patch [#28032] swapped matrix multiplication order, reverse it back, tested with FBX, BVH import/export which are very sensitive to changes in matrix rotation. 2011-07-20 06:41:51 +00:00
60ae40a0ed patch [#28030] SCONS Build: Build Date reflects "1" instead of actual date of build
by Scott Giese (sgiese)

This bug effected windows and linux.
2011-07-20 06:22:16 +00:00
abb3f8c80b BGE Animations: Fixing a crash with "IPO" animations on an object with modifiers. 2011-07-20 06:20:49 +00:00
71eda5ca4d BGE Animations: BL_Action::m_action could be garbage, which can lead to odd problems. So, now I make sure it's set to NULL in the constructor. 2011-07-20 06:09:41 +00:00
74219d2704 patch [#28031] Minor typo in Blenlib
from Scott Giese (sgiese)
2011-07-20 06:05:47 +00:00
0ed523a8dd patch [#28032] Python Mathutils: Matrix Multiplication Error
from Scott Giese (sgiese)
2011-07-20 05:57:38 +00:00
69614a972f Add/Clear Fake Users from Outliner by RMB on ID blocks 2011-07-20 01:12:57 +00:00
57fe73b3ac View All/Selected tools for NLA Editor 2011-07-20 00:36:28 +00:00
c89379e7e1 ndof fly: better sharing of control between 2D and 3D mouse, compile fix for MSVC, lock horizon implemented 2011-07-19 22:40:22 +00:00
ddbfcacfa0 Added some simple feedback for long processes, currently being printed to the console 2011-07-19 16:52:47 +00:00
365ac2f9e3 Added tooltips to all operators in the Mocap panels 2011-07-19 16:33:28 +00:00
fd7825e7dc Speedup, do only one global matrix grab per obj 2011-07-19 15:30:19 +00:00
0936874695 update to patch from Andrew Hale - obj.closest_point_ob_mesh() now takes an optional max_dist argument. 2011-07-19 15:21:21 +00:00
1191c1ead9 Object Align operator: coudn't resist and added a high quality (slower) option to get perfect alighment on complex shapes with rotation/scaling :D
sexy example:
http://www.pasteall.org/pic/show.php?id=15171
2011-07-19 15:07:29 +00:00
c7d8d28939 Object Align operator now correctly computes a *global* bounding box for all objects. This makes rotated or scaled objects work like they should. Now it's still derived from object's bounding box so it will not be completly acurate on complex objects.. to solve this Id need to cycle over all verts. Don't think that's a good idea to do in py 2011-07-19 13:27:05 +00:00
4024b14b43 fix for [#28012] Mat ID messy with shader nodes
Issue was that the Shader tree execution changed the ShaderInput.
Changes are that the UI is updated that only the main material will have the pass_index this is displayed in the "render pipeline options" panel.
When the material is not a node material the pass_index will be shown at the "options" panel

To test enable nodes on the material
Add a new input material
change the pass_index of the material (render pipeline options)
Enable RenderPass material ID and use the compositor to read out the material pass

Jeroen
2011-07-19 08:31:53 +00:00
f4b6d00926 fix for bpy.path.abspath(), if a path was passed it would get the last directory cut off, broke copying images on export. 2011-07-19 05:05:54 +00:00
7f74abeaca translated ndof menu from C to Python, enabled helicopter fly mode 2011-07-19 04:12:49 +00:00
Dalai Felinto
d8e216833a cleanup of scene->gamedata DNA
xsch and ysch were originally planed to replace the scene->r.xsch/r.ysch
however in blender/3dview we still need to use the r. values. Therefore we can't really run
from using those values even in bplayer. So removed the values in gamedata.

The way it's now, render values (xsch and ysch) are responsible for aspect ratio and gamedata xplay and yplay are responsible for the size of the window.
2011-07-19 02:47:43 +00:00
Dalai Felinto
f2e055f4a4 bugfix: [#27348] blenderplayer showing a different viewport size in 2.57b
I believe this bug was there since we (me) moved the game settings to scene->gm
Since I was here I added support for x/y non square aspect pixels (i.e. anamorphic)
we were already using it for videotexture so I don't know why we were not here.

Tested in OSX, but it should be working in all OSs.
2011-07-19 01:41:45 +00:00
ce0ad0b40b fix [#28018] Sequence Swap Data Operator does not work 2011-07-19 01:36:59 +00:00
5f47123fde consistent Starting/InProgress/Finishing ndof events with dead-zone filtering 2011-07-18 22:42:09 +00:00
3ad978ea8e switched off ndof fly logging (receiving end) 2011-07-18 22:37:48 +00:00
Dalai Felinto
1f5d60ba01 patch: [#27783] "Problem with clock" at 18:39:00 by Daniel Dionne (mrzeon)
the overflow of the clock was causing crash in the game engine in Linux.
(on June 11 2011, 18:39:00 GMT)

running to the "where is waldo (wally)" bug award of 2011.
2011-07-18 22:28:42 +00:00
7c4aed7fa6 Even more bugfixes for retarget, for various types of special cases. 2011-07-18 19:33:11 +00:00
2fb7dbd60c Material Specular Hardness Animation import (ongoing) 2011-07-18 19:32:51 +00:00
0dcc7d05ab Bugfixing for retargeting - unconnected bones now retarget alot better. Also some placeholder code for a fix scale operator 2011-07-18 18:44:54 +00:00
a6e2fba994 Identifying Animation List for Material shininess. 2011-07-18 18:31:01 +00:00
Lukas Toenne
7de78a812c Missing struct keyword in function declaration causes compiler error with cmake/gcc. 2011-07-18 18:14:22 +00:00
bb49714310 Material Specular Hardness Animation export. 2011-07-18 17:33:03 +00:00
384831dd9d Bugfix #27927
This fixes assigning 'tweak' keymap option for border selecting in
Node editor. Thanks Perry Parks for the patch!
2011-07-18 14:41:59 +00:00
35ce13562d script to report deprecated functions of text and their age in days. 2011-07-18 09:49:26 +00:00
9fa20e6d88 fix [#28003] Unable to delete vgroup
still need to find how an invalid defgroup index is set, but at least dont show the vertex group as selected when its not.
2011-07-18 07:38:44 +00:00
ce00a32f05 fix [#27996] Smart UV Unwrap Still Results in Overlaps
real fix this time :S, I thought using old code from 2.4x would fix but quaternion needed to be inverted.
2011-07-18 06:44:41 +00:00
8dd72c476e fix [#28005] Python Add-Ons are constantly reloaded if twice in the path
Addons are checked for their timestamps and reloaded when it changes but this failed when, 2 addons had the same name since different times caused 2 reloads on every redraw.

Now when duplicate addons are in the path now give a error message in the UI and print path conflict in the console and don't thrash reloading.
2011-07-18 05:41:46 +00:00
13e82ff8e1 fix [#27971] Blender OBJ export with Z-Up setting produces an error and fails
changes to extensions coming up...
2011-07-18 05:07:54 +00:00
9469f0d0af Bug fix: particle cache should only be cleared on the exact first integer frame, not in the case of a subframe between the first and second frame. 2011-07-18 02:40:54 +00:00
7e72356b8d BGE Animations: Allow the Copy Transform constraint to work with external targets in the game engine. 2011-07-17 20:06:50 +00:00
Lukas Toenne
cf83cabb10 Modified behavior when replacing input links: The new target socket for the existing link is now chosen from available sockets that match the _target_ type, instead of the source type. This leads to more usable replacements, e.g. for toggling inputs on mix nodes. Still not a great solution to the mute/autoconnect problem, but a bit more intuitive for replacements. 2011-07-17 19:43:14 +00:00
44326c9fe9 Material Animation export. (on going) 2011-07-17 18:51:03 +00:00
Lukas Toenne
f62df587d9 Changed the default keys for duplicate-nodes-while-keeping-input-links to ctrl+shift+dkey, to avoid conflicts with alt+dkey for linked duplicates. 2011-07-17 18:17:35 +00:00
Lukas Toenne
756ef16e21 Little modification of the duplicate operator on artist request: The default behavior (shift+dkey) is now to copy nodes and internal links, but not the input links from unselected nodes. This feature is available with the alternate duplicate operator (alt+dkey). 2011-07-17 18:04:28 +00:00
b96d3fd70a Identify material Animations to export. 2011-07-17 17:30:41 +00:00
6b6c2bd17f Set material Sid addressing. 2011-07-17 16:39:19 +00:00
Lukas Toenne
b29b0acdce Removed the autoconnect call when adding new nodes, this hardly ever gives usable results and leads to annoyed artists. 2011-07-17 16:14:52 +00:00
7e4ccf9349 template for patch exporting objects in a scene. 2011-07-17 13:29:50 +00:00
c7532c5b81 update to cmake checker script to also check if our include paths are ok 2011-07-17 12:42:03 +00:00
ebf21a9848 patch [#28001] Find the nearest point on an object to the given location
from Andrew Hale (trumanblending)
2011-07-17 12:40:18 +00:00
a0b769ce0e Bugfix [#27412] PoseLib bug(maybe also corrupted data)
* Find first unused frame function was failing to correctly detect
conflicts with the lower bound due to the way that markers are not
stored in sorted order. Fixed by performing additional search passes.

* Fixed some update bugs where there were missing notifiers. Most
noticable when the poselib is being viewed in an Action Editor
2011-07-17 12:37:38 +00:00
7f850ff25d 'bgl' python module.
- add back slicing for buffers, (was previously in 2.4x but not working in py3):
  buf = bgl.Buffer(...)
  ls = buf[:]

- fix for crash with negative index access not being clamped.

- improve repr() function for multi dimensional buffers.

- add back 'list' attribute, but print deprecation warning.
2011-07-17 12:30:23 +00:00
8c11a26285 Fixed compile error on Fedora 15, when FFMPEG was enabled. 2011-07-17 10:28:31 +00:00
5792bd7cc7 cmake: cleanup include paths, some duplicates and going up some unneeded dirs. 2011-07-17 09:11:13 +00:00
c9ad903af2 Added notifier listener for node editor.
Now it behaves right on playback:

- Starting playback "Anim Player" button appears on header.
  It used to appear only on mouse hover before.
- Stopping playback triggers refresh on compositor, so
  actual result would be visible if image sequence/movie
  is used in nodes.
2011-07-17 08:38:04 +00:00
410c5e3cd2 cmake source definitions:
remove missing includes and use more strict formatting.
2011-07-16 23:01:14 +00:00
d54a014963 Fixed crash of multires baker when baking from sculpt mode.
Incorrect low level was used for this case -- it should be
sculpt level, not preview level.

Thanks to Morten Mikkelsen to point on this bug :)
2011-07-16 17:55:46 +00:00
19aaadcbab Small bugfix for prior commit - Removing constraints no longer causes an error 2011-07-16 13:48:43 +00:00
351a603874 Keyframing Motion capture properties now works for the Point constraint. Also, Floor constraint has been implemented, using Object's raycasting function in Python 2011-07-16 13:36:47 +00:00
2d8c1e60e6 print an error message if Python.h can't be found for cmake and scons since its such a common problem. 2011-07-16 06:55:45 +00:00
3ce8c9242d Bugfix [#27157] keyframing a constrained bone does not work as before
Visual Keyframing was broken by r.34685, which used another method
which, at the time, appeared to work perfectly fine. Apparently not.

Also, extend/fixed visual keying to work for axis-angle rotations too.
Needs some testing, but should probably work
2011-07-16 06:46:39 +00:00
9fa6e32d5c BGE Animations: Updating the python docs. 2011-07-16 05:29:15 +00:00
c9c51776ee BGE Animations: Some updates to the Python api:
* Adding methods KX_GameObject.stopAction() and KX_GameObject.isPlayingAction().
  * Made all layer arguments optional. This means I had to change setActionFrame(layer, frame) to setActionFrame(frame, layer=0). This seems a little backwards to me, but I guess that's what you get with optional arguments. Also, this will break existing scripts.
  * Made sure to check user supplied layer values on all action methods. Previously this was only done for playAction().
  * Fixed a few newline issues.
2011-07-16 05:25:15 +00:00
4ca88c99be fix for crash with edit armature buttons when no bones were selected (uninitialized pointer) 2011-07-15 23:55:20 +00:00
729498ab2d Fix for [#26712] Particle group instance 'Use Count' value gets reset on file-load.
* New object pointers can't be loaded properly for library linked groups, so the weight groups now store an index to the group objects at save time. This index is used at load time to set the objects without relying on the old pointers.
* If the library linked group is modified the indices can be wrong, but this can't really be avoided easily as there's no way to relate objects in a linked group between loads.
2011-07-15 13:32:02 +00:00
7984e338db fix for linking on mingw/scons with recent changes to mathutils 2011-07-15 10:10:25 +00:00
04e028a0c5 Bugfix: Retargeting now works when user rig bones are not connected to their parents. 2011-07-15 10:07:02 +00:00
3a6158a8bf move mathutils into its own lib. 2011-07-15 04:01:47 +00:00
5ff9acfd28 Fix for [#27307] Blender crashes when loading a new scene while baking fluid dynamics
* Fluid bakes didn't respect the job stop flag.
* Also made msvc happy with some casts.
2011-07-15 00:39:49 +00:00
b0c8abf04e removed unused ndof code 2011-07-14 22:01:09 +00:00
cc1ba4569c more consistent and modal-friendly ndof events, fly mode v1 2011-07-14 21:20:45 +00:00
b3714ec8ed Bugfix: Baking mocap constraints now works for user created IK bones 2011-07-14 13:26:23 +00:00
b028cba0e4 many mathutils exception types were wrong, went over all exceptions in mathutils and double checked the're correct. 2011-07-14 09:54:03 +00:00
Nathan Letwory
f70f167237 Shuffle code so it compiles with MSVC too. (Array of unknown size otherwise). 2011-07-14 08:20:19 +00:00
ad08de4c2a BGE Animations: Now animations are only updated based on the set animation speed. This offers a significant performance increase (about 2x fps in my animation stress tests) for cases such as the defaults: 60fps logic and 30fps animations. This means that animations now only have to be updated half the time. I've also added Animations as a profiling category. This is the time spent in Blender's animation code, and not in the BL_ShapeDeformer (the mesh deformation). I'd like the add the deformation too, but right now it's counted in the rasterizer, and I don't see an obviously clean way to have it counted as animation instead. I'll investigate more. 2011-07-14 07:03:33 +00:00
d838d82151 3D Audio GSoC:
MSVC compile fixes.
2011-07-14 05:56:47 +00:00
44d2e6eb10 disable old ndof fly (new stuff en route from another machine) 2011-07-14 03:28:31 +00:00
b2eb2a00f1 introduce variables for ndof settings 2011-07-14 03:27:33 +00:00
4da4943b5c formatting changes for python mathutils module. 2011-07-14 01:25:05 +00:00
0a46f9a737 rename bgl.Buffer attribute list to a method, to_list() as used for IDProps, also made repr function nicer. 2011-07-13 23:45:47 +00:00
aef6f15b49 minor changes to bgl.Buffer py class
- use getset rather then getattr
- remove verbose Buffer docstring, better use sphinx docs for this
- replace bge.Buffer with the Buffer class and add a __new__ function to the class so it can be called.
- improve error messages
2011-07-13 23:24:21 +00:00
609933208d dont include the preview.blend in headless mode 2011-07-13 19:27:42 +00:00
6551d4a265 use linked duplicates in preview.blend to save some space. 2011-07-13 19:20:50 +00:00
c3fcd6c4c7 reuse USER_SAVE_PREVIEWS to not save thumbnails into blend file header 2011-07-13 19:16:25 +00:00
1fd33b6e77 cmake option to build without smoke sim: WITH_MOD_SMOKE 2011-07-13 18:40:21 +00:00
f94c9d5d61 Fix python error in image sampling panel drawing when
there is no texture slot available.
2011-07-13 18:07:30 +00:00
74536efa91 Fix #26704: activating a texture node inside material nodes did not show that
texture in the texture properties.
2011-07-13 17:52:23 +00:00
5e841e4b4a fix for animation playback and build error when compiling without WITH_AUDASPACE 2011-07-13 17:24:33 +00:00
91a6e43485 Adding Child Of constraint "inverse parent matrix" to rna, so it
can be set via Python.
2011-07-13 17:20:20 +00:00
49d01fb30d Fixed Color animation import( support for Maya ) 2011-07-13 16:53:36 +00:00
f12614234a 3D Audio GSoC:
* Fixed a warning in AUD_DoubleReader.cpp
* Removed some unneeded includes
* Fixed a bug resulting in a crash when stopping a sound
* Fixed a bug where a NaN resulted in a horrible memory error
* Fixed a typo bug which caused crackling in audio playback and export
* Added memory debugging code (ifdefed)
2011-07-13 12:16:45 +00:00
fa78d3271f Bugfix: DopeSheet + Graph Editors were referring to wrong operator for
their "Duplicate Keys" menu entry
2011-07-13 12:02:39 +00:00
83ca561b62 Fix #27951: armature edit mode transform panel shows "nothing selected" even
when something is selected.
2011-07-13 11:52:37 +00:00
cf485cd963 Advanced CMake option to build the player without blender: WITH_BLENDER 2011-07-13 08:15:06 +00:00
b0ffa7fc58 patch [#27950] Patch to add the ability to generate random points on mesh faces
from Andrew Hale (trumanblending)
2011-07-13 07:50:21 +00:00
44e45e54c5 - don't build ghost's event printer unless ghost debug is enabled.
- use char rather then STR_String for the event printer.
- added option to build WITH_GHOST_DEBUG for cmake
- renamed WITH_SDL_GHOST --> WITH_GHOST_SDL
2011-07-13 06:04:54 +00:00
0fc6aac3dc make X11's getModifierKeys more compact and don't run XKeysymToKeycode 8 times for call. 2011-07-13 05:22:21 +00:00
74494dbcd2 SVN maintenance. 2011-07-13 00:49:22 +00:00
41f37cff93 changes to ghost/sdl
- mouse coords made absolute
- window position set
- building with SDL 1.2 gives an error.
2011-07-13 00:31:08 +00:00
a557773f46 Bokeh blur in the blur node is wronlgy calculated.
when using the node on a single white pixel on black background, the output should look like as the bokeh image.
being a round image, but it looked like a donut.

the make_gausstab used dist/rad and bokeh used (dist/rad)*2 - 1
I changed it to reflect the correct bokeh circular image
2011-07-12 19:21:38 +00:00
b724c7f27e Add delete with reconnect feature.
this will reconnect nodes as if the deleted node is muted.
Operation is added to the space_node node menu and to the keymap as CTRL-X

to test this just add some nodes to the space_node
select one or multiple nodes and press CTRL-X

It should reconnect the nodes as they were muted

limitations:
1. it performs a delete and reconnect per node. It does not evaluate all selected nodes as one whole
2. mute only supports Value, Vector and Color data types, so does this feature
3. not usable for nodes where input and output does not match (like colorToBW)

Where reconnect could not be preformed the links will be removed from the model.

Undo works with this delete with reconnect.
2011-07-12 18:59:54 +00:00
9eb1b26312 Fix for recent GHOST SDL commit.
SCons rules haven't been changed to deal with new option.
2011-07-12 18:39:46 +00:00
f7b9418d25 build option to use SDL 1.3 for GHOST rather then X11/Win32/Cocoa api's,
This opens up the option for blender to be more easily ported to other devices, OS's.

TODO
- continuous grab.
- text glitch with multiple windows (was a bug in X11 too for a while, will check on this)
2011-07-12 13:17:54 +00:00
208b69e3a7 3D Audio GSoC:
Software 3D Audio implementation.
2011-07-12 13:11:00 +00:00
d9cf985730 Merging trunk up to r38329. 2011-07-12 13:09:22 +00:00
b90535cc33 correction to cursor enum and make GHOST_SystemX11's convertXKey into a static function. 2011-07-12 12:53:23 +00:00
9132754dc1 Timeline Drawing - Time cursor draws extra wide in timeline so that
keyframe lines are wrapped up nicely by it

Ideally it could be made so that it only became wide when it is on a
frame with a keyframe, though that could end up causing performance
problems, so this will have to do (if a bit "chunky" looking at
times).
2011-07-12 12:13:23 +00:00
7dd6926b22 Bugfix [#27548] Timeline view - 2D drawing issues
* Keyframe lines were being drawn too short when frame number box was
enabled. The code for drawing this was modifying the View2D view-space
to get it's stuff in the right place, but the timeline code was not
accounting for this.

* In order to make the time ticks more visible outside the frame
range, I've moved the start/end frame drawing stuff in timeline to
occur after the grid drawing, and to draw semi-transparent, just like
the preview range curtains in the other animation editors
2011-07-12 12:04:27 +00:00
8d78e10b69 NLA Drawing - More prominent communication of the "solo" feature
* When a track is being solo'd, all other channels for that block are
drawn darker
* Strips in non-solo tracks are drawn flat shaded instead of with
shading
* Mute toggles are hidden (they wouldn't affect the result)
2011-07-12 11:27:35 +00:00
0a8d4d1e10 CMake fixes for r38303 (splitting up the outliner code). 2011-07-12 10:09:14 +00:00
d0e4fb393b RNA: fix some text datablock property UI names. 2011-07-12 09:30:40 +00:00
1ab2e0d40e NLA Drawing Tweak - New icons for "solo" toggles
Added some new star icons for the "solo" toggles in NLA editor.
Unfortunately they look a tad scruffy alongside some of the other
icons, although they should hopefully turn out to be more descriptive
(especially when combined with some drawing tweaks I've got in the
pipeline...)
2011-07-12 07:03:25 +00:00
d585ad2e3f Bugfix [#27650] graph editor -> drivers -> Delete Channels (X) deletes
wrong entries if obdata selected

In this case, the problem was that there were some lingering F-Curves
that were unselected by still had "active" flags set (a problem caused
by the old filtering channel visible vs list visible bug). Now,
"active" flag is treated separately from "selected" flag (bringing
this back into line with bones), leaving no confusion.
2011-07-12 03:59:06 +00:00
2fd3ae7539 Bugfix #27881: Motion paths don't correctly update with pose sliding
tools
2011-07-12 03:02:53 +00:00
de69b6819d Further Outliner code cleanup - Split out tree building stuff for ID
blocks and Objects from add_element

These two chunks were significantly large that they really needed to
be placed into their own functions to allow for easier source
navigation.
2011-07-11 13:36:38 +00:00
3e8712bf63 == The great Outliner code split up ==
As per my proposal (http://lists.blender.org/pipermail/bf-
committers/2011-July/032553.html), I've split outliner.c into several
new files based on the purpose of the relevant code.

* outliner_tree.c - building outliner structure
* outliner_draw.c - outliner drawing (including toggle buttons and
their handling)
* outliner_edit.c - all operators for toggling stuff, and/or hotkey
accessed operators. Also KeyingSet and Driver operators go here
* outliner_tools.c - all operators and callbacks used for handling RMB
click on items
* outliner_select.c - stuff for selecting rows, and handling the
active/selected toggling stuff

In a few cases, the split hasn't been totally clear-cut due to cross-
dependencies and other spaghetti. However, in a few cases, I have
managed to remove the need for some of the prototypes that were needed
in the past by judicious reshuffling of functions, which also makes it
easier to actually find what you're looking for.
2011-07-11 10:59:53 +00:00
e645068aa0 Fix #27928: avi raw writing failure, after earlier bugfix for big file sizes. 2011-07-11 09:47:13 +00:00
9fb2e5dde7 Fix #27930: many modifiers crashed when used on a lattice with a vertex group. 2011-07-11 09:15:20 +00:00
7dfe34864e Fix #27912: crash after mesh.materials.pop(). 2011-07-11 09:08:08 +00:00
8ca556a32a Fix #27921: optimal display with 2 subsurf modifiers fails. 2011-07-11 09:05:10 +00:00
dbc9e36f72 make python3.3 compatible, __class__ is no longer in the class methods namespace. 2011-07-11 05:50:49 +00:00
897cbe4b42 Fix for [#27398] Particle systems with animated groups render incorrectly in viewport
* Hmph.. depsgraph and group duplication == illogical.
2011-07-10 23:49:59 +00:00
2ebc5cbe75 Fix for [#27293] Group Instance of particle system is rendered wrong
* Silly mul_m4_v3 had turned into a mul_m4_v4 at some point!
2011-07-10 23:24:15 +00:00
add56df7ca -OpenEXR fixed so enabling if user has enabled
-Added Iex to lib list, was causing link time errors
2011-07-10 20:04:56 +00:00
80eb1eae42 run WM_exit(C) when blender as a python module exits 2011-07-10 18:54:02 +00:00
1f6a79ecb5 Fix #27926: autokey not working with auto IK, broke this with an earlier bugfix. 2011-07-10 18:21:40 +00:00
2fb4a37baa Fix for [#27289] Hair: Render Option - Object does not point objects to end of "hair path"
* Objects are now always rotated in the directions of the hair paths
* Secondary fix: particle size wasn't updated for hair particles, so dupliobject size couldn't be change after the hair was edited
2011-07-10 17:30:31 +00:00
301e5b4ea0 fix for various python bugs and remove unused var. 2011-07-10 17:26:15 +00:00
de7592b489 Fix for [#26873] Animated displacement modifier on an object doesn't work with hair particle objects
* Noise is now considered an animated texture as it changes with every frame
* Converted a few places in particles code to use the particle system's own random table instead of BLI_frand.
2011-07-10 17:04:56 +00:00
b62a956cc8 cleanup for python scripts - unused vars and imports 2011-07-10 12:51:37 +00:00
6160bc596f 2011-07-10 07:34:11 +00:00
a5b37a8a0c Bug Fix. 2011-07-10 06:21:39 +00:00
c749a42a8e Some optimizations and coding style improvements across the retargeting and constraint scripts 2011-07-09 21:52:25 +00:00
7370ba1839 fix for NULL pointer usages 2011-07-09 19:59:32 +00:00
daddbc62df 2011-07-09 19:33:02 +00:00
65d1e27ff5 fix for using uninitialized value in gpu_shader_material 2011-07-09 19:16:32 +00:00
d5984b2d50 fix [#27683] Blender hangs when baking a particle system when a driver is present 2011-07-09 17:41:39 +00:00
2bb08ee48e Wrong tooltip for OBJECT_OT_make_links_scene() operator. 2011-07-09 17:09:28 +00:00
de10ffab75 Bugfix #27761
Material nodes: when no output node was active, it sets one.
Not common to happen anymore, only for deleting output nodes
without clicking on nodes.
2011-07-09 17:03:35 +00:00
c50b5ee320 ghost multi-test builds again, now uses BLF font library 2011-07-09 16:18:15 +00:00
eb452225ce Improvements to import system. Ability to include more parameters. 2011-07-09 15:15:17 +00:00
c314ac8ce3 Fix #27888: Render artifacts in 2.58.1
It was a regression introduced in rev36301. Average normal calcilation
used to fail due to triangular faces which are too slight.

Do not use triangles with too small area for average normal calculation.
2011-07-09 15:10:12 +00:00
905d04ef9d fix [#27915] Relax Pose crashes blender on bone with ChildOf constraint in linked rig 2011-07-09 14:33:28 +00:00
5506d18fa8 Fox #27866: Curve handle snaps/locks when it shouldnt
It was a precision error in calchandleNurb. Do not align handles
along handle which si too short.
2011-07-09 14:22:52 +00:00
767c7f24dd Ctrl-R sets rotation mode for Pose Bones 2011-07-09 01:14:07 +00:00
d044ecea10 Compiler warning fix 2011-07-09 01:11:09 +00:00
abdf420a6d == GPU Buffers ==
This patch attempts to clean up and document the GPU buffers
code. There are a few bug fixes as well.

Patch reviewed here: http://codereview.appspot.com/4631052/

Summary:

* Bugfix: make GPU_buffer_copy_normal convert from shorts to floats
  correctly, also fixed the use of cached face normal CustomData.

* Bugfix: changed the `mat_nr' field of GPUBufferMaterial from char to
  short.

* Changed color buffer setup to not alloc a temporary copy of color
  data, just passes the MCol data in directly.

* Changed the GPU buffer pool code to make clearer what operates
  specifically on the global pool.

* Lots of refactoring for GPU_drawobject_new; should operate mostly
  the same (except got rid of one unecessary allocation), just split
  into more functions and without macros now.

* Converted some #defines into enumerations.

* Made some stuff private, pulled out of header file.

* Deleted unused function GPU_buffer_pool_free_unused().

* Removed GPU_interleaved_setup and related #defines. (I think this
  was used for editmode VBOs, but those were disabled.)

* Added lots of comments.

* Added a few comments in the code signed `--nicholas' to note places
  where I am unsure about design or usage, would be good to address
  these better.

* Code formatting changed to be more consistent with the rest of
  Blender.

* Renamed some fields and variables to be more consistent with
  Blender's naming conventions.

* Renamed some fields and variables to use more descriptive names,
  e.g. renamed `redir' to `mat_orig_to_new'.

* Removed print outs with DEBUG_VBO -- don't feel too strongly about
  this one, just not used elsewhere in Blender, could be easily added
  back if others disagree though.

* Moved the PBVH drawing code down to the bottom of the file, before
  was sitting in the middle of the other VBO code
2011-07-08 19:58:02 +00:00
a6bb0f93ad Fix #27897: mesh with negative scale disappears while sculpting, clipping
planes were wrong in that case.
2011-07-08 15:58:00 +00:00
a5906de7c4 Fix #26962: softbody collision doesn't respect subsurf+displace modifiers.
Softbody was still using a flag to determine if it should use the final or
deform derivedmesh, but this wans't exposed in the UI. Others systems use the
collision modifier, now softbody uses it also to get vertices and faces, but
with own collision code.
2011-07-08 13:22:58 +00:00
5b592f01da Constraints RNA - More Head/Tail stuff
Added for Damped Track and Locked Track constraints
2011-07-08 12:48:43 +00:00
668323d701 Fix #27900: file browser filter, sort, .. parameters were not saved. This is
useful if you have a screen setup with a file browser editor.
2011-07-08 12:22:48 +00:00
9159afe77a Fix #27891: IK stretch gives inaccurate results. Tweaked translation segment
convergence weight a bit to match angles better at typical scales.
2011-07-08 12:18:54 +00:00
579efb097d Deleting Grease Pencil layers from Action-Editor works again 2011-07-08 11:57:25 +00:00
aa7b843b1c Fix #27902: autokey bones with individual origins transform not working. 2011-07-08 11:43:35 +00:00
05d6b555e8 Limit Distance contraint can now use Head/Tail setting for bone
targets too
2011-07-08 10:25:26 +00:00
a79fefee8c BGE Animations: Adding constants for the action play modes to bge.logic:
* KX_ACTION_MODE_PLAY
 * KX_ACTION_MODE_LOOP
 * KX_ACTION_MODE_PING_PONG
2011-07-08 07:32:45 +00:00
5a0f3690d0 BGE Animations: Fixing a crash when animating non-armature objects that didn't have shape keys. 2011-07-08 07:31:40 +00:00
Dalai Felinto
936737b70f example of Physics Constraints module :)
+ some small fixes in other docs.

A topic for later(soon?), I think we should name the modules according to the rest of Blender modules. So instead of:
Game Engine bge.logic Module

We would have it:
Game Logic (bge.logic)
...
2011-07-08 06:51:12 +00:00
30d41ac9cb NLA - Adding new actionclip strips no longer appends "Act: " to the
start of the names. It should be clear enough what they are without
this.
2011-07-08 03:31:40 +00:00
357afe06bc fix issue raised by [#27819] Unwrap Menu (U) -> Lightmap Pack throws Python Exception. But use a different fix. 2011-07-08 03:07:51 +00:00
6aae2698ac patch [#27885] bge.constraints documentation
by Solano Felicio (solano)
2011-07-08 02:59:25 +00:00
7ab90056c7 fix for example 2011-07-07 21:14:36 +00:00
074ac7c09b Add ED_object_pose_armature to stubs.c. This should fix compilation
issues with blenderplayer.
2011-07-07 21:02:31 +00:00
46f938e70b Added baking/unbaking functionality to constraint system. Retargeting now adds/manages 2 new NLA Tracks as planned. Modified bl_operatores/nla.py slightly to use it instead of creating my own bake function (now supports baking to a specific action, vs always creating a new one), but this does not break using the function in the old way. 2011-07-07 20:46:35 +00:00
9a0de18a52 bge.texture doc, needed whitespace to format correctly. 2011-07-07 19:35:55 +00:00
af27622a87 some corrections to bge.texture docs 2011-07-07 19:23:51 +00:00
6f5b5ac3c9 Camera clipend animation export 2011-07-07 18:40:46 +00:00
be918954bd Fixed Camera Ortho scale animation import 2011-07-07 16:56:56 +00:00
c57ac39f7f Merging trunk up to r38193. 2011-07-07 16:34:19 +00:00
99736f373c Allow pose matrix to be set for Benjy Cook's GSOC project.
this uses the same function as pose mode snapping.
2011-07-07 16:09:57 +00:00
c9d6989098 Animation Goodie: Cyclic "Extrapolation" can be toggled from the "Set
Extrapolation" tool again

Added "Make Cyclic" and "Clear Cyclic" options to "Set Extrapolation"
tool (found from Channels menu) in Animation Editors. These options
simply add or remove (respectively) Cycles FModifiers from the
selected F-Curves, making them have cyclic extrapolation with a single
click, instead of having to go through the FModifiers UI (or Graph-
Editor only "Add FModifier" operator), which should make it easier to
do this apparently common chore.
2011-07-07 13:59:28 +00:00
Nathan Letwory
5e6abb8004 Fix compile with scons, after thread commit in r38185 2011-07-07 13:57:20 +00:00
bc9432b905 Grease Pencil ActEdit Mode: Filtering Cleanup
* Ported filtering code for Grease Pencil frames editing to the newer-
style refactored stuff
* Decoupled active status of layers from selection status, bringing
this into line with everything else again
2011-07-07 11:29:36 +00:00
4d7449b336 Fix part of #26811: absolute shape keys should not show influence value in list. 2011-07-07 11:01:36 +00:00
4e7417e9fd The Blenderplayer wasn't freeing GPU_Textures since according to BLI_threads, GPU_free_image() was never being called from the main thread. Calling BLI_threadapi_init() when the Blenderplayer starts sets the current thread as the main thread and solves the problem. 2011-07-07 10:37:46 +00:00
ccc56a6570 Tiny tweak: hierarchy lines in outliner were nearly invisible. Color is
blend between backdrop and text color (black), made it blend 0.4 instead
of 0.2
2011-07-07 09:56:06 +00:00
242ca1bdce NLA Drawing - Second attempt at providing options for streamlining the
view for transforming strips

When the "Include animation data blocks with no NLA data" toggle
(action icon) is off, action lines are only shown if they have
keyframes. So when this option is off, only NLA blocks that have NLA
tracks will be shown, and of those, only those which currently have an
active action with keyframes will have their red action lines shown.

Combined with the vertical-space tweak when show control curves is
turned off, this should be good enough for most cases.
2011-07-07 05:28:09 +00:00
2791e12e71 NLA Strips cannot have their actions changed while the "tweakmode" is
on, otherwise things could screw up
2011-07-07 05:17:36 +00:00
5817f1347c Remove unnecessary line from previous commit which slipped through 2011-07-07 04:47:47 +00:00
cff7c61ddb Patch [#23682] Add sort+move to bone group list in panel
Thanks  Torsten Rupp (rupp)   for the patch!

This patch adds the abilities to sort the bone group list in the
properties panel and to move bone groups up/down in the list (similar
like for vertex groups)
2011-07-07 04:31:53 +00:00
0eacdc94ba BGE Animations: Removing unused code and adding some more comments. 2011-07-07 03:53:24 +00:00
d00a3c8ddf Outliner RMB Menu - AnimData mangement
* When clicking on "Animation" items in the Outliner, there's now a
menu containing from which you can change the action used, and
refresh/delete all drivers.

* Moved action-setting logic for AnimData actions to a single utility
function in anim_sys, since this was starting to be done in too many
places already.

* Fixed Outliner refresh bug after changing the active action
2011-07-07 03:35:48 +00:00
Nathan Letwory
5b4bffba52 [#27854] Collada import doesn't handle UVW mapping
Reported by David Roy
Patch by Brecht van Lommel

UV import code wasn't taking possible stride into account (always assuming stride==2), thus reading UV coords totally wrong.
2011-07-06 21:37:31 +00:00
34c5784f99 Merging trunk up to r38167. 2011-07-06 20:26:56 +00:00
44220bba7a camera ortho_scale (COLLADA xmag ) animation export 2011-07-06 19:00:40 +00:00
50ef78cdb8 various fixes to enable MSVC build, removed crusty old Win32 ndof code 2011-07-06 18:50:59 +00:00
a0d4a95ff7 Camera lens animation import. 2011-07-06 18:34:01 +00:00
6c88a16b3a Camera lens animation Identifying 2011-07-06 18:09:36 +00:00
1e14e2f465 camera lens (COLLADA xfov ) animation export 2011-07-06 17:41:14 +00:00
e3c89a127d refitted old ndof fly code for 2.5, removed crusty old code 2011-07-06 17:10:38 +00:00
a83c3c0b14 The material index did not work when FSAA was turned on.
The information was written in the temp exr files, but was not read back.
After checking I saw that the pass was not merged back in the rendercore.

After adding this it worked. tested with all FSAA settings.
2011-07-06 16:08:24 +00:00
eb6ac55e93 pep8 compliance for python scripts 2011-07-06 14:20:38 +00:00
2367220108 Changed creation of original location targets to be created only if needed for IK (i.e. user's decision) 2011-07-06 14:19:54 +00:00
120e5a3417 Cosmetic changes to UI. Also, added option to mark which bones should be planted when calculation new root translation (i.e. which bones are feet) 2011-07-06 13:31:13 +00:00
ebbcae36b3 Coding style and cosmetic changes to mocap constraints module 2011-07-06 13:29:31 +00:00
89d7b9a0a6 Added a small useful operator: Fix Armature Rotate. It fixes the common issue with mocap files that sometimes are rotated around the wrong axis 2011-07-06 13:27:40 +00:00
e1b060486f Fix #27879: sequencer didn't draw overlapping strips well, selected were drawn
under unselected, and active strips red border color for active strips was not
clear enough.
2011-07-06 13:15:22 +00:00
cf71712bba Fix #27883: object actions did not get duplicated on full scene copy. 2011-07-06 12:33:33 +00:00
03b81a5c80 Ergh! first compile and test then commit! 2011-07-06 12:22:36 +00:00
9f25b85168 Making Blender compile for C90 standard, var declared after code :)
Also cleaned a line of code that was horribly spread over 4 lines.
2011-07-06 11:44:27 +00:00
ed897750ca Fix #27880: sequencer separate images operator lost strip properties like
blend mode, opacity, etc.
2011-07-06 10:58:23 +00:00
eaa63eadf2 Bugfix [#27825] Pose Mode Armatures different fill colors
Old light-blue colouring for "keyed" bones is no longer applied, even
if the flags were set in earlier versions of Blender.

This was a legacy feature used to get around some ancient issues,
which isn't needed anymore. Instead, it ends up causing confusion, so
removing.
2011-07-06 10:45:25 +00:00
11645e7a3f Fix #27877: writing .avi files > 4 GB not working on windows.
Solution is to replace "long" by "int64_t" and "fseek" by "_fseeki64", because
long on 64 bit windows is still 32 bit.
2011-07-06 10:19:04 +00:00
29f2cbdd8f Fix #27876: particles instancing a whole group didn't take group offset into account. 2011-07-06 10:05:27 +00:00
5470326c3b Fix #27875: different texture nodes result after decompose/compose. 2011-07-06 09:58:29 +00:00
febce577ba Fix #27873: nan pixels in render with degenerate faces. 2011-07-06 09:15:18 +00:00
Dalai Felinto
4260258bb3 an example for blf - a basic Hello World (for bge, not blender) 2011-07-06 08:29:20 +00:00
Dalai Felinto
2691c6a84f new example for bge.texture, a basic texture replacement
fresh simple and didactic example straight from my bge book, enjoy it ;)
video texture documentation online ... tears dropping.
2011-07-06 07:26:04 +00:00
Dalai Felinto
b9810ffdde moving bge.texture example to an external file 2011-07-06 07:15:56 +00:00
Dalai Felinto
26d75618ef patch [#27871] bge.texture documentation from Solano Felício (+ changes from me) it still needs work
... and I can't test rst in windows so for now let's pretend it builds. If someone can generate the docs and see how it goes please let me know.

(plus a small fix for bge.logic rst)
2011-07-06 07:05:29 +00:00
82b17039ed NLA Drawing - When "Show Control Curves" option in View menu is
disabled, the strips are drawn so that they take up less vertical
space.

Originally, the primary reason why these were taller than those in the
other animation editors was really so that these control curves could
be visualised adequately. So, when these aren't shown, we can afford
to collapse the strips vertically.

This should make it possible to fit more strips on screen to retime
them. in some staggered fashion.
2011-07-06 01:34:10 +00:00
eb55fd1b17 BGE Animations: Fixing a typo: fram -> frame 2011-07-05 22:33:01 +00:00
c1715223b9 BGE Animations: Updating the bge.types docs to include the three new methods to KX_GameObject: playAction(), getActionFrame(), setActionFrame(). 2011-07-05 22:32:10 +00:00
e7878389bb Fix #27865: weird mouse warping with continuous grab on OS X. 2011-07-05 20:15:29 +00:00
959cd0fe69 Fix #27777: vertex color disabled when in a reused node material. 2011-07-05 19:45:26 +00:00
e15fd7df6c Patch #27829: fix X11 compile problem due to missing XF86XK_AudioForward define
on Debian Lenny. Patch by "dungeoneer".
2011-07-05 19:10:28 +00:00
87c2842630 Patch #27842: build fix for solaris, missing finite(). Patch by A. Hettinger. 2011-07-05 19:04:38 +00:00
81ad6fa4e6 Fix small part of #27815: recognize m2ts as video file extension. 2011-07-05 18:54:16 +00:00
9fca591c2b Spot Light spot_blend animation im/export. 2011-07-05 18:02:08 +00:00
33afa06412 Fix #27848: sequencer strip hard cut looses soft trim on second strip. 2011-07-05 16:31:21 +00:00
Nathan Letwory
c78cee8e27 Fix compile for msvc (broken in r38119) 2011-07-05 14:53:37 +00:00
3f3c6f5f1f Merging from trunk up to r38119. 2011-07-05 13:54:25 +00:00
ccd31900ab Fix #27855: crash on enabling high resolution smoke.
Wavelet tile generation code was reading outside of array bounds, and as a
result could give a noise.wavelets file with nan values. Now that problem
is fixed, and existing files with nan are ignored.
2011-07-05 12:25:56 +00:00
887fd19894 Added access to denoising and new constraints functionality to UI script 2011-07-05 10:57:29 +00:00
04c03db6af Added One-Sided distance constraint. Also fixed some bugs and syntax in constraint and retarget scripts 2011-07-05 10:56:34 +00:00
90e8b83b45 Added denoising function. Uses a type of median filter to smooth out spikes, typical of sensor noise in motion capture data 2011-07-05 10:55:35 +00:00
495ce5c88b Fix part of #27858: crash trying to apply subsurf modifier as shape key,
fix found by Bastian Schreiber.
2011-07-05 10:35:48 +00:00
ef0f475f20 Fix #27826: bone envelope head/tail radius not dynamically updated in viewport. 2011-07-05 10:04:40 +00:00
7950ac791b Fix #27846: time extend / E key not work in sequence editor. 2011-07-05 09:47:09 +00:00
962c1606fc Fix #27810: bones drawn blue in 2.49 file, was still checking stride bone
flag for drawing even though that feature is no longer in 2.5.
2011-07-05 09:35:38 +00:00
3d5ae95986 Fix #27863: converting curve spline type from python crashes. 2011-07-05 08:57:11 +00:00
1ff54f91ff Fix: #27861 bevel angle limit at 90° wasn't working well on cube, tweaked
epsilon value to be a bit smaller.
2011-07-05 08:28:54 +00:00
61fc839200 fix [#27862] OpenGL render animation don't respect .png RGB option. 2011-07-05 07:46:25 +00:00
ceabc6d119 BGE Animations: Various fixes and bits of cleanup to get the action actuator to behave more like it did in trunk. The Pepper version is still more sensitive to pulses than the trunk version, but this is more accurate. I might try to address this, but I'm not sure. 2011-07-05 05:22:02 +00:00
db2d737f0e Fix for [#27182] particle/collision kill interacting strangely
* Particle die time wasn't taken correctly into account in certain situations when calculating dynamics.
2011-07-05 02:56:14 +00:00
35965308a8 Fix for [#27579] Particles Cache Problem
* Horrors from the ancient world of deprecated code: object animation offset can't really work correctly with particles unless point cache takes full control of particle system timing.
* Disabled the non-working offset control from effecting particles so that for now particles will work consistently and the offset is only applied to the object.
2011-07-05 02:18:55 +00:00
afd77d081a Reduce duplicate code 2011-07-05 01:55:03 +00:00
a0fa8c3cd2 Bugfix #27856: Transforming Grease Pencil frames in Action Editor
didn't perform updates

* This problem was caused by a typo when adapting old code
* Fixed crash where keyframes-update was being called in Grease Pencil
transforms too

Todo:
Outliner/Datablocks Viewer doesn't update that nicely when these
keyframes get modified. Outside of gdb, I managed to get a few non-
repeatable crashes here; while debugging though, there was only some
lagging oddness if panning before the tree updated.
2011-07-05 01:54:01 +00:00
0dcc370f3b Fix for [#27347] Particle x-axis mirror editing not working as expected.
* The x-mirror editing didn't mirror strand lengths.
2011-07-05 01:49:34 +00:00
Dalai Felinto
355cb26ff3 blenderplayer bundle in OSX doesn't need script folder (untested)
I can't test this here, somehow blender+scons is failing in my building env.
but it should work. Basically it skips the copy of the script folder for the blenderplayer.app

I will test it once buildbot get pass this review ;)
2011-07-05 00:30:27 +00:00
e66b778fd6 BGE Animations: Updating some copy+pasted license blocks. 2011-07-04 21:21:49 +00:00
1b7ebd3857 BGE Animations: Adding preliminary support for blend shape actions on different layers. This, and shape action blending in general still require more work though. 2011-07-04 21:19:11 +00:00
fa6d80c13b 2011-07-04 19:41:33 +00:00
af5d852857 Light(spot) spot_size (fall of angle in COLLADA) animation support completed. 2011-07-04 19:30:58 +00:00
830fe8af84 Updated the indent, sorry! 2011-07-04 19:22:37 +00:00
e814f2c71d ====== Proposal: Nodes property windows enhancement ======
===== Situation before this patch =====

in the current situation inside the node editor there is a properties panel (press 'n'-key). This pabel displays some information about the node, backdrop and grease pencil. The UI of the property panel is typically vertical oriented. Nodes in the other hand are not oriented in a direction. Both area's are draw via the same draw function.

With some nodes this will create not user-friendly UI. Try the color-balance for instance). The 3 color circles are drawn next to each other, it would be better to draw them below each other.

When creating more complex nodes you don't want to display all handles in the node-panel and in the properties panel. For instance fine-tuning handles you only want to appear in the property panel to reduce place in the node itself.

===== Situation after this patch  =====

This patch separates the draw functions of the property panel and the node panel.
When no special draw function is created for the property panel, the draw function of the node will be used as 'fallback'

===== Impact =====

==== BKE_node.h ====

add a new uifunc (called uifuncbut) to the bNodeType struct. The definition is the same as the uifunc.

==== node_buttons.c ====

if the uifuncbut is set, call it. currently calls the uifunc method

==== drawnode.c ====

static void node_composit_set_butfunc(bNodeType *ntype). set the uifuncbut function where needed. When at the end of the method uifuncbut is still empty, set uifuncbut to the uifunc. 

===== Final note =====

! PS. this is not limited to the compositor it also works for Materials and Textures !
! PPS. For other branching creating their own node-tree. Please make sure that your uifuncbut is set NULL or a valid draw function !
2011-07-04 18:48:36 +00:00
c4491f558b Current situation
A mesh can consist out of multiple material. Take a character with clothing's. the skin can be a different material as the different clothing's. During compositing it is a common use-case to only do a part of the composit on only a specific material. Currently this can not be done.

In blender movies this feature is known to be implemented, but until now it never got integrated into trunk.
Proposal

With material index the Blender internal renderer will be capable of creating a buffer containing the material indexes of the first pixel-hit. This will be implemented in the same manner as the object index.

In the compositor the ID Mask node can be used to extract the information out of the Render pass.
Impact
User interface

On the properties-space the next changes will be done

    Scene⇒Render layer⇒Passes⇒Material index will be added
    Material⇒Options⇒Pass index will be added

DNA

    Material struct will get an new field called “index”. this will be a short-type.
    Material struct the field pad will be removed.
    A new Render-layer pass will be added (bit 1«18)

RNA

    Material RNA is updated (based on “pass index” from object)
    Render layer RNA is updated (based on IndexOB)

Blender internal renderer

The Blender internal renderer will process the render pass as a copy of the Object index.
Blender compositor

The render layer input will get a new output socket called “IndexMA”
Usage

An example on how to use material index can be found at:

https://svn.blender.org/svnroot/bf-blender/trunk/lib/tests/compositing/composite_materialindex.blend

This is also example of a commit message longer than the commit itself :)
2011-07-04 18:14:41 +00:00
ab369227fb light SpotLight blend and size parameters animation export. on going. 2011-07-04 15:33:39 +00:00
7c15143449 bind marker camera now uses active object rather then scene camera (was requested a few times) 2011-07-04 15:09:02 +00:00
796c6a9467 Fix #27849: 3D manipulator widget lost on mesh in edge mode.
The manipulator was always using vertex selection flags, but those are only
valid in vertex mode, as selection flag flushing only happens in the direction
vertex -> edge -> face. Now use edge/face selection flags when needed.
2011-07-04 13:48:18 +00:00
7e36a75b45 Paths: remove some temporary code that was only needed for 2.57. 2011-07-04 13:33:47 +00:00
398807e235 Fix #27785: blenderplayer + eltopo linking error. 2011-07-04 13:03:41 +00:00
a552d8e610 Finished Freeze constraint, and target space option for Freeze and Point constraints. 2011-07-04 11:35:29 +00:00
5918521959 Bug report (IRC)
Knife cut with long mouse trails failed, increased max amount of input points
4 fold (1024).
2011-07-04 11:28:39 +00:00
ca2c319649 Fix #27850: keyboards with a comma instead of a dot on the numpad now get
converted to a dot when typing into number buttons, for easier number entry.
2011-07-04 10:56:59 +00:00
Nathan Letwory
cf43e48fc7 Apply patch 4636051. COLLADA: Export selection.
Original patch by Jan Diederich, adapted by Pelle Johnsen. Review assistance by Daniel Tavares.

This patch adds an option to export only the selection.
2011-07-04 08:59:28 +00:00
aa1668c6f8 fix for own error in intersect_line_sphere_2d(), using 3d function on 2d vectors 2011-07-04 08:13:27 +00:00
0e0eba9f79 fix for crash when setting layers or saving when there is no active scene - only really happens when running python scripts on startup. 2011-07-04 05:23:36 +00:00
de1c4fafc7 First stages of easier "expressions" creation...
It is now possible to create "scripted expression" drivers by simply
clicking on some property, and typing some short Python expression
prefixed with a '#'. This will result in a scripted expression driver,
with the typed-in text being created.

For example, you can click on X-Location of the default cube, and
type:
#sin(frame)
and a new driver will be created for the x-location of the cube. This
will use the current frame value, and modulate this with a sine wave.

Do note though, that the current frame is a special case here. In the
current implementation, a special "frame" driver variable, which
references the current scene frame is created automatically, so that
this simple and (assumed) common case will work straight out of the
box.

Future improvements:
- Explore possibilities of semi-automated extraction of variables from
such expressions, resulting in automated variable extraction. (Doing
away with variables completely is definitely 100% off the agenda
though)
- Look into some ways of defining some shorthands for referencing
local data (possibly related to variable extraction?)
2011-07-04 03:12:28 +00:00
e358064704 Added smoothing variables to constraint creation, and now Active checkbox is functional.Also initial work was done on the freeze constraint. 2011-07-03 21:25:54 +00:00
775ab37ad5 Fixed some issues with stride bone and original empty creation and parenting. Now there is no longer a constraint cycle issue when using IK constraints 2011-07-03 21:23:41 +00:00
d29d3a89e4 fix for building WITH_PYTHON_MODULE 2011-07-03 19:15:46 +00:00
d40b9e2e1c As per discussion: allow bone transforms again for proxy'ed bones. 2011-07-03 18:21:37 +00:00
1f4fca3654 Light Color Animation Import Complete. 2011-07-03 17:26:02 +00:00
5913179f85 CMake file to build ghost tests again. 2011-07-03 16:17:38 +00:00
613e9b9926 changed the max decimal points to show from 7 to 6, since with float precision problems the median point of a selection could be 0.0000003 2011-07-03 13:20:21 +00:00
aa295bb551 AnimationType flag. AnimationType Enum update. 2011-07-03 13:01:52 +00:00
9f99e5cc1e AnimationType Enum. 2011-07-03 12:33:52 +00:00
b6c1490359 Experimental depsgraph tweak:
Objects with drivers are now treated as needing updates when the
current frame changes. This assumption has been documented in the
code, and should at least mean that users who try to use drivers for
creating simple time-based expressions that this should work.

Note:
- It is still recommended to create a "cfra" driver variable instead
of actually inlining bpy.context.scene.frame_current into the
expressions. Not only does the latter look rather nasty to type/have
in the expression, but it is also less future-proof for when I get
around to actually working on a beefed-up depsgraph (nothing official
on that front yet...)
2011-07-03 11:56:24 +00:00
c922b41374 find_frames() calls removed. 2011-07-03 11:28:40 +00:00
a632091176 Light Animation Identification. 2011-07-03 11:07:34 +00:00
fe62b62cb0 fix 2 bugs in project from view from a camera object
- panorama mode was scaled 2x too high.
- scaled camera objects would incorrectly effect the result.
2011-07-03 10:48:18 +00:00
78c43d18fc fix [#27839] UV 'Project from view' ignores camera lens shift 2011-07-03 07:37:33 +00:00
abb21a4da0 fix for python error when pinning a non mesh object in mesh editmode. 2011-07-03 07:21:33 +00:00
22bb09d018 fix for error when moving module, broke fracture tools and select internal face operator. 2011-07-03 04:28:41 +00:00
46d12b480e BGE Animations: Making the action actuator's loop end play mode work better. 2011-07-03 02:57:50 +00:00
5d7921691b BGE Animations: Reimplementing support for the "Flipper" play mode of the action actuator. 2011-07-03 02:51:14 +00:00
5f4f75c51a BGE Animations: Adding in layer weights to allow for layer blending. 2011-07-03 01:59:17 +00:00
8c3f2923fd Early commit of mocap constraint work. Still very much a WIP, but Point constraints should work - but buggy. 2011-07-02 18:24:05 +00:00
3ee2cb9cdb fix for error in cmake files 2011-07-02 07:55:06 +00:00
87030e6a32 Light Sid addressing edited. 2011-07-02 05:05:03 +00:00
14c72f379c implemented ndof 'dead zone' around home position, fixed X11 active window determination, removed old X11 ndof code 2011-07-01 21:51:44 +00:00
228be10722 fix for building headless 2011-07-01 15:15:22 +00:00
bd81fde1ff Packaging variable named 'a' for release 2011-07-01 14:46:14 +00:00
c2e12d33bd update checksums for x3d tests 2011-07-01 13:39:35 +00:00
dcd8933b95 quick explode failed if executed with no active object 2011-07-01 13:26:20 +00:00
590682bac1 uv mirror poll function wasnt checking UV's were available on the mesh. 2011-07-01 13:25:00 +00:00
cf05777bc0 cmake was installing text as a directory rather then coping the files within it. 2011-07-01 13:10:49 +00:00
2c66ab12e9 minor pep8 edits 2011-07-01 12:33:34 +00:00
52784d7e30 NLA Strip Drawing Tweaks
* Removed frame-number display from NLA strips. Indeed doing so makes
things look cleaner/easier to identify.
* When transforming NLA strips, the "temp-metas" (purple strips) get
their frame extents drawn on either end, like in the sequencer, which
seems to be easier to read than the ones inside the strips.

---

The downside of this tweak is that there is no longer any visual
feedback for which strips run reversed instead of forwards, as that
used to be shown using the frame extents stuff.
2011-07-01 12:21:13 +00:00
01550f880e add 'bgl' OpenGL doc to sphinx 2011-07-01 11:16:42 +00:00
5916309ac9 moving BGL to rst format, first move file. 2011-07-01 11:13:26 +00:00
1072ba66e0 fix [#27820] foreach_get on bpy_prop_collections returns weird results 2011-07-01 08:48:00 +00:00
1f2c93f9f7 Fix #27816: Outliner does not update when parents are cleared
Added NC_OBJECT|ND_PARENT notifier to OBJECT_OT_parent_clear operator.
2011-07-01 05:58:28 +00:00
abd4a881db ndof device detection now visible in log 2011-07-01 03:54:23 +00:00
893bf5f81a verbose ndof event trace for a tester 2011-07-01 03:44:03 +00:00
415761d508 own change to cmake files broke MSVC2010 with Debug configuration, reported by Alex K 2011-07-01 03:40:12 +00:00
3eec91f4d7 Keying Set UI - Icons for Paths in List
The Keying Set paths list now shows the icon of the type of ID-block
that a path item refers to. This make it easier to make snese of the
paths shown in the list.
2011-07-01 03:35:59 +00:00
77dbc5c914 Icons!
Animation Editor toggle tweaks:
* By popular request, curve visibility toggles in the Graph Editor are
now represented using the eyeball icons
* Muting is now represented by a speaker icon (a speaker for this
purpose seems fairly common?)

New icons:
* Keying Sets now have their own icons (as found in a proposal on
jendrzych's "Pixel Sized" blog)
* Drivers also have their own icon now. This is just a hacky one I've
devised which doesn't look that great. Suggestions on this are very
welcome.
2011-07-01 02:37:44 +00:00
20de4f27b6 ndof popup menu (experimental (mostly harmless)) 2011-07-01 01:00:20 +00:00
e41a7b6f63 tiny compile fix for PowerMac 2011-07-01 00:58:47 +00:00
b4b26b735c BGE Animations: Fixing a bug where an action actuator could update a frame property when it wasn't active. 2011-06-30 20:08:05 +00:00
12596969af BGE Animations: Shape drivers are now working again. 2011-06-30 19:33:13 +00:00
038feabedd Light color parameter animation export support. 2011-06-30 18:24:45 +00:00
093af18bfd fix for own error in script edits, broke bpy_extras.mesh_utils.ngon_tesselate 2011-06-30 16:06:30 +00:00
7f1fe0fdc2 fix for own mistake with key shortcuts r37850 2011-06-30 15:43:38 +00:00
06fcf2e6ef Todo item:
Closed regions didn't always draw the (+) icon right place, confusing
for users.

Next to that, I think this icon is using a bad metaphor or visual language,
Illustrated best if you close a header in outliner or buttons. Icons are
UI widgets, for screen/editor layouts different controls can be stylized.

My preference is something that aligns visually to the seperators between
regions; for testing and hacking pleasure I've added two quick versions,
a small tabbish thing and a triangle. Enable these with debug menu,
ALT+CTRL+D, values 1 or 2.

This is simply drawn with opengl now. An image for it can be made as well.

Previews:
http://www.blender.org/bf/closed_regions1.png
http://www.blender.org/bf/closed_regions2.png
http://www.blender.org/bf/closed_regions3.png

There's other design ideas to explore as well, like making region deviders
8-10 pixels wide, with a 'drag me' dot on it or so. That takes some screen
estate though, and will require to add big editor-dividers too...
Fun stuff for the mockup-mafia to check on, we have time :)
2011-06-30 15:02:03 +00:00
a6270b0204 Animation Channels Filtering Refactor - Part 5
Channels can now be used as "animation containers" to be filtered
further to obtain a set of subsidiary channels (i.e. F-Curves
associated with some summary channel).

The main use of this is that object and scene summary channels can now
be defined without defining the filtering logic in three different
places - once for channel filtering, once for drawing keyframes in
action editor, and once for editing these keyframes.

An indirect consequence of this, is that the "Only selected channels"
option in Timeline will now result in only the keyframes for a
selected bones getting shown (when enabled), instead of all keyframes
for the active object. This was requested by Lee during Durian, and is
something which has only become possible as a result of this commit.
2011-06-30 13:56:47 +00:00
Lukas Toenne
f2c7cb0912 When duplicating nodes in a tree, also copy the links between selected nodes, as well as input links from non-selected to selected nodes. 2011-06-30 12:37:59 +00:00
85dc00e254 Fix for undefined "index" in key.c.
Probably forgotten to be remaned to defgrp_index after
recent commit here.
2011-06-30 07:35:41 +00:00
2a85eff40c Bugfixes:
* After changing driver target settings, the driver F-Curves now have
their "disabled" flags cleared, so that they will be updated
immediately instead of needing a manual "Update Dependencies" flush
* Little comment tweak to appease my text editor
2011-06-30 04:38:27 +00:00
66b565a376 improve error report [#27775] External Image Editor Preference does not work
also correct tooltip typo.
2011-06-30 04:32:59 +00:00
5c3e73fd56 replace inline loops for get_weights_array with calls to defvert_find_weight() 2011-06-30 03:04:39 +00:00
c490baceed minor change in logic for adding a new hook, ignore zero weight verts in a vgroup. 2011-06-30 02:52:13 +00:00
acc69b87d7 fix/workaround [#27807] bake malloc loop if Deep Shadow && strand && children
render strands use the window matrix and window size which were both zero while baking, this caused divides by 0 and eternal malloc loop.
So set unit window matrix and dummy view size.
This is more a workaround then a fix but avoids crashing.
2011-06-30 02:02:16 +00:00
bad785cce4 minor edits, no functional change. 2011-06-30 01:40:20 +00:00
8d4ea1b155 Tweak to the toggle to show/hide datablock filtering items in
animedit headers
2011-06-30 01:13:15 +00:00
97e4681217 Some tweaks to naming of channels in animation editors - thanks Matt
* F-Curves no longer show the name of the datablock of the property
they affect if this is an ID-block. For example, transform curves for
a cube won't get the "... (Cube)" suffix anymore. In these cases, it's
relatively clear that these belong to the parent datablock, so doing
this should be fine (and reduces clutter).

However, for non-id data (i.e. subsurf modifier settings) or bones,
this info still gets shown. In these cases, there is some ambiguity.

* "ActiveAct: <...>" is no longer shown for NLA action channels (i.e.
just the name of the action gets shown). This should make it easier to
see at a glance what action is being used.
2011-06-30 01:07:03 +00:00
6582d30c26 Fix windows cmake build, this line got accidentally removed in variable renaming. 2011-06-29 17:56:32 +00:00
7f70f78376 Addon UI: button for removing addons which are installed to user/home paths, this is not displayed for system addons, or ones which come with blender. 2011-06-29 15:56:22 +00:00
333e825798 Created UI and Group Property for Motion Capture constraints, to be used to fix up animation after retargeting 2011-06-29 14:29:52 +00:00
8f89e7a309 incorrectly had CMake storing directory names as filepaths
also correct compiler warning for collada and remove print from own last commit.
2011-06-29 13:16:11 +00:00
2710c567b9 Animation Editors - Small Visual Tweaks for Usability
== Datablock filters in the headers are now hidden by default ==
This has been done because users were generally not frequently
toggling these, so quick access vs screen-estate cost wasn't really
worth it to have these always showing and taking up space on the
header.

Usage notes:
- To show these again, click on the "Filter more..." toggle.
- The "Filter more..." button DOES NOT affect whether those filters
apply.

Design notes:
- I tried many other button/icon combinations, but those were either
too space-hogging, vague, or had wrong button order.
- I also tried putting a box around these, but there was too much
padding.
- The ordering of the filters has also been modified a bit so that the
group/fcurve-name filters occur earlier in the list, given that
they're used more frequently

== Graph Editor - Use Fancy Drawing ==
Renamed this option to "Use High Quality Drawing" as suggested by
Matt. "Fancy" isn't really descriptive enough.

== Icons for Mode Dropdowns ==
The mode dropdowns in the DopeSheet and Graph Editors now have icons.
- These were important enough (compared to the auto-snap mode) that
some visual decoration was perhaps warranted.
- It makes it easier to see at a glance what mode the view is in

Icon choices:
- In some cases, the icons seem like quite a natural fit IMO (i.e.
outliner<->dopesheet, key<->shapekey editor, grease pencil, fcurve
editor)
- Action Editor uses an "object" icon to indicate that this is object-
level only for now (though I hope to find a way to address this
soon/later). This will be kept like this until then.
- There isn't any icon for drivers, so after trying a few
alternatives, I settled on area-link icon, since it ties together two
entities using some link.
2011-06-29 13:00:19 +00:00
d86d68d4e6 console autocomp import now excludes '_' prefixed variables and the results are sorted. 2011-06-29 10:47:43 +00:00
d8eb704784 Corrected link to FFmpeg homepage. 2011-06-29 09:46:00 +00:00
e0e9c81c94 fix [#27800] Tooltips for shading mode options the wrong way round. 2011-06-29 06:14:15 +00:00
c19d2d2da2 bug [#27779] Python console completion broken
modified auto-completion, though this may need to become a preference.
The problem is:
- including _all_ text as a prefix can take a lot of space, and isnt too readable.
- including only the previous word is error prone because detecting delimiters can fail when editing strings.

so I've set it to only include the last part of the string but align to the cursor to make it more readable.
2011-06-29 06:06:59 +00:00
2f10ded896 Compiler warning fixes 2011-06-29 05:07:12 +00:00
2f60a5030f Actions can now be made single-user from the Outliner
* Use the same method as from unlinking actions to do this.
* Split off the make single-user code used for the ID-browser into a
function in blenkernel which can be used elsewhere. Getting materials
to also work using this method proved to be a bit too tricky (due to
the whole messy ob vs obdata situation), so I haven't done that.
2011-06-29 04:34:20 +00:00
b85e0c3e85 BGE Animations: Moving the BL_Action::IsDone() implementation from the header file to the source file. 2011-06-29 02:45:08 +00:00
3afe0e9c88 BGE Animations: Beginning work on layer blending. Blending armature actions works, but needs more testing. Also, currently the mode is forced to ADD and the weight to 1. 2011-06-29 02:42:46 +00:00
d122f24c1a BGE Animations: Fixing a bug with priority and non continuous animations. 2011-06-29 01:53:17 +00:00
de3c95a09c BGE Animations: Adding blendin for Shape Actions. 2011-06-29 01:05:12 +00:00
bca3da4fb0 updated build script for SpaceNav on Linux -- was foolishly relying on user-config.py 2011-06-28 21:20:47 +00:00
40a15a04be 2.5 Image Buttons Template:
* Added missing greying out for "fields_per_frame" Property, reported by lmg on IRC. Thanks!
2011-06-28 20:05:18 +00:00
caef67eb92 Set Edit bone roll on Armature Import.
+ Light->Color Sid for testing.
2011-06-28 19:30:00 +00:00
c2bd746fac own error in recent cmake edits 2011-06-28 16:57:25 +00:00
8ddd2db648 RenderEngine API: add self.report() error reporting function for render engines,
works the same as for operators. Also includes some refactoring of render error
reporting code to use ReportList.
2011-06-28 16:25:07 +00:00
4178b662cc enabled pan/zoom in rotation-locked 3D views + small cleanup 2011-06-28 15:59:46 +00:00
446be52164 made Pascal string less intrusive to build systems 2011-06-28 15:57:39 +00:00
3211bea679 CMake: campbell already added default build type as release a few hours
earlier in a different way, missed that, so reverting my change.
2011-06-28 15:43:03 +00:00
a05b66defb CMake: set default cmake build type to Release. Without that you would
get a build that has neither debug symbols nor optimization, now it
will build an optimized blender by default.
2011-06-28 14:42:11 +00:00
3c43e8e50a fix [#27782] Tileable displacement map issue in Blender 2.58
this bug was introduced in 2.58 (r37342), when adding filtering support to imagewrap(), the problem is boxsample was getting float values which were not wrapped as int values are.
2011-06-28 12:48:39 +00:00
0b41c479e4 Action-Management from Outliner - Unlinking Actions
It is now possible to use the Outliner for managing the active action
of an ID-block (provided that it appears in the Outliner), which
should be a bit better than having to go through the NLA Editor.

So far, this only allowing unlinking actions, using some existing
operators. To use:
1) Navigate through the Outliner tree to find the
Object/Material/Lamp/etc. that the animation belongs to. (NOTE: this
doesn't work in Datablocks mode, but should in the normal "All Scenes"
and related modes)
2) Expand the "Animation" entry below this
3) Right-click on the Action entry below this, and select "Unlink"
from the RMB menu

In the process, I've fixed problems with some data-blocks not showing
their animation data in Outliner.
2011-06-28 11:21:12 +00:00
57f4844c43 make drawing faces in the UV editor an image space option, re-using the mesh option was lazy and doesn't make much sense. 2011-06-28 09:42:17 +00:00
Nathan Letwory
fdbae99668 Explicitly turn off JACK so it's clear it's not supported. 2011-06-28 06:56:39 +00:00
b4682414c2 fix [#27787] Smart UV Unwrap Results in Overlaps
added optional face area weighting (from 2.4x) since this can result in overlapping faces.
2011-06-28 06:51:55 +00:00
c4e28f999b Outliner Bugfixes:
* Mesh Animation-Data was not shown. Other data types would get this
shown.

* Added attempted fix for the problem where when you try to expand the
last item in a RNA list or so, you often end up expanding the first
item (and then have to close and try again, at which point the expand
works as you expected the first time round). More testing needed, but
seems to work better already
2011-06-28 05:17:17 +00:00
661c55b78a Refactoring code for filtering actions
- This is still quite convoluted unfortunately...
- I can't quite figure out what a bug note I left in the code was
about anymore. Removed.
2011-06-28 05:02:00 +00:00
c0a83d24e9 cleanup for cmake msvc build options, reference some libs directly, fix conflicting flags /Ob1 and /Zi for debug 2011-06-28 02:49:49 +00:00
cf90b9497f VBO:
Fix for bug found by psy-fi.

* gpu_buffers.c was using GL_ARB_vertex_buffer_object to check for VBO
  support, should be using GLEW_ARB_vertex_buffer_object.
2011-06-28 00:40:39 +00:00
30b4ff8949 first attempt at CMake fix (untested) 2011-06-27 23:24:24 +00:00
5c2e4318b5 Windows ndof now uses blender view coordinates 2011-06-27 21:52:33 +00:00
798f59fe68 Mac ndof using blender view coordinates + small but important typo fixed 2011-06-27 20:44:23 +00:00
0f8a1ed8af removed unneeded cleanup code on Linux 2011-06-27 20:18:04 +00:00
edd5980436 now using blender view coordinates for ndof input -- core and Linux in place 2011-06-27 20:12:10 +00:00
e4f7b24e20 disable opencollada and openexr for msvc2010, gives linking errors 2011-06-27 16:33:59 +00:00
8e90ba3b20 Fix last part of #26850: OS X game player did not react to quit event. 2011-06-27 14:34:58 +00:00
49f84ef9ed Fix part of #26850: OS X game player was showing _NSAutoreleaseNoPool()
error messages on start. These were coming from initializing the SDL video
subsystem as part of Joystick init. We do not need this, as video stuff is
covered by GHOST, most likely this was conflicting.
2011-06-27 14:06:11 +00:00
24c0f1873e Fix part of #26850: Cocoa OS X game player was not working, two issues:
* Unlike blender, the game player draws only on windows update callbacks,
  and those wer not implemented.
* Going fullscreen for player was not implemented correct, it expected an
  existing window but actually it should create one.
2011-06-27 13:57:27 +00:00
a961d62653 initialize cmake's CMAKE_BUILD_TYPE to 'Release'
add reference to cmake cache for convenience GNUMakefile
2011-06-27 13:18:08 +00:00
26b7d513f1 Small bug fixes:
* Removing the last of the owner/ownertype stuff. The bulk of this
stuff was removed in Part3 of the refactor, but it seems I forgot to
actually remove these struct members at the end of that.
* Texture datablocks without animdata aren't skipped immediately
anymore. This could lead to texture nodetrees on animdata-less
textures getting skipped.
2011-06-27 13:04:21 +00:00
ff5dbbe1b8 Some bugfixing and tweaking for retargeting. Script works now regardless of world transform on performer and end user rigs. This breaks stride bone functionality, will be addressed in next commit 2011-06-27 12:48:30 +00:00
46a4f47a5d Added more IK functionality to UI. You can now toggle IK for selected bones. 2011-06-27 12:46:53 +00:00
4dd18f7e6f fix for editmode option toggle 2011-06-27 11:40:15 +00:00
f10f3d3651 Bugfix #27768
On clicking in a non-active Blender window (when you activated others),
the mouse position of the first click was still the old position.

Problem is in GHOST; it sends out the 'activate window' event after the
mouseclick event itself. Code now checks for this case and reads the
correct mouse position.
2011-06-27 11:21:25 +00:00
a1abdf1c1c fix [#27778] Set Bone Flags - No Scale - Toggle seems not to work.
Toggling options on the selection is better done as a generic operator.
Replace ARMATURE_OT_flags_set and POSE_OT_flags_set with WM_OT_context_collection_boolean_set and use menus to access it with specific settings.

This way its easy make a key shortcut which toggles any boolean on any collection - sequences, metaballs, objects, bones etc.
2011-06-27 07:51:52 +00:00
93bb6238e0 remove some unused flags and correct aud example heading 2011-06-27 07:44:59 +00:00
Dalai Felinto
9dbec62bc0 basic sound playback example for audspace module
(I'm on windows at the moment so I can't test it. Hopefully it should be fine)
2011-06-27 05:12:03 +00:00
ae49f6deb0 fix for a leak in sound_read_sound_buffer(), used when drawing the sequencer waveform. 2011-06-27 05:03:58 +00:00
69ff819a2e print the help message if running from python directly. 2011-06-27 04:50:08 +00:00
489ca86b59 Texture Nodes AnimEdit support 2011-06-27 04:46:03 +00:00
fd3c5bef7e Bugfix: Selecting nodes now updates animation editors
Noticed while testing the material nodes commit
2011-06-27 04:24:59 +00:00
e1ba5c8167 moved modules added to changelog (this isn't detected by the changelog generator) 2011-06-27 04:21:53 +00:00
308cd73d8b scenes now adjust brush usercounts on copying and freeing, pointed out by Jason Wilkins 2011-06-27 04:05:19 +00:00
b6bc47eb09 AnimChannelFiltering - Material Nodes support
Animation for Material nodes is now shown in Animation Editors :)
2011-06-27 03:54:33 +00:00
d7cea716c5 == Multires ==
Fix for bug #27710, 'Multires lost from 2.49 file in 2.5x'
Reported by Gaia Clary.

Problem was that the old multires data didn't flush changes to
vertices out to the Multires structure on filesave. So, recent bits of
sculpting could be lost if the multires level wasn't changed before
filesave.

We already had code to deal with missing multires vertex data, which
simply copies the Mesh vertex data into the multires vertex data if it
matches the number of vertices in the highest level. Moved this code
up a bit so that we always make this copy if the numbers match up.

Was able to reproduce the bug fresh in 2.49b, and confirmed that the
fix works. However, this does not help if changes were sculpted on a
multires level other than the highest level and saved without a
subsequent level change.
2011-06-27 03:54:22 +00:00
33e554799b Minor warning cleanup & fix
- comment/remove assignments from values to themselves.
- add case break statements (no functional change but some source code checkers notice).
- fix python errors when the sculpt brush is None.
2011-06-27 03:36:14 +00:00
17da597cc8 Added IK functionality to retargeting. If rig contains an IK constraint, in addition to FK retarget it will place and keyframe the IK targets correctly 2011-06-26 19:54:29 +00:00
87f242fab0 set_pose function completed. Algorithms to be checked.
(Still not the desired results )
2011-06-26 18:56:06 +00:00
4b1cceddbd fix for building with msvc/cmake take 2 (think its correct this time)
also sync build flags with scons.
2011-06-26 17:18:37 +00:00
31f0b6639a more compact code for recent sphere/line intersection functions. 2011-06-26 17:16:06 +00:00
1186bdfc08 Putting back blender.org and release number in info header.
Worked always great for tutorials in past, to check what's been used.
2011-06-26 17:01:10 +00:00
12e5d69af0 pose channel -> pose matrix import ( in progress ) 2011-06-26 15:35:02 +00:00
10d775df3d AnimChannels Filtering Refactor - Part 4
This commit is aimed at cleaning up the filtering code by changing the
filtering idiom/pattern used. While the old code used a "check then
do" approach, the new code does a "grab then assimilate".

The main benefits are that:
* the code duplication that used to exist has now been removed, making
it easier to add new channel types for data
* a recursive "peeking" ability now means that the old problems with
data existing deep in the tree (i.e. figuring out whether a channel
should be shown based on whether it will have any descendents) should
now work much better than before.

In the process, I've found and fixed a few previously unnoticed bugs
with how some channels were constructed, so hopefully things work a
bit better now.

TODO's:
* Action-Group filtering stuff hasn't been refactored yet. This was
causing some grief in the past, so I still need to check this
carefully.
* Material Nodes support (missing in trunk) should be easy to slot in
now :)
2011-06-26 14:50:19 +00:00
933a65a76f 2d version of line/circle intersec function. 2011-06-26 11:08:12 +00:00
Dalai Felinto
913738a042 Fix in texts for Mesh.materials.pop()
found by accident while studying how to append materials from python ;)
2011-06-26 09:10:54 +00:00
3de7a67562 This solves the issue of having symlinks in the LIBDIR path (CMAKE Windows). Hopefully it doesn't break other things. 2011-06-26 08:42:00 +00:00
8eb119a5cd renamed math functions and made public
lambda_cp_line --> line_point_factor_v3
 lambda_cp_line2 --> line_point_factor_v2

correction to previous commit function name
 isect_seg_sphere_v3 --> isect_line_sphere_v3
 ... since its not clipped.

added a clip argument to the python version of the function.
2011-06-26 08:07:09 +00:00
540c2eee56 math func to find the intersection(s) between a segment and a sphere for C/python.
from python:
  i1, i2 = mathutils.geometry.intersect_line_sphere(l1, l2, sphere, radius)
2011-06-26 07:21:19 +00:00
83000d8504 Allow the lib dir to be a symlink, pointed out by Mitchell Stokes. 2011-06-26 06:05:56 +00:00
5663d85e56 Some bugfixing and coding styles changes suggested by ideasman_42. 2011-06-25 23:50:50 +00:00
b8e8f8064d NDOF zoom for orbit modes (trackball/turntable) in 3D view 2011-06-25 18:53:06 +00:00
e61063f042 NDOF pan/zoom/fit working in image/uv editor 2011-06-25 18:51:29 +00:00
651df035f7 baby steps toward an NDOF popup menu 2011-06-25 18:50:03 +00:00
ec48695de1 suppressed annoying log in Mac NDOF system 2011-06-25 18:48:53 +00:00
c414d3e460 fix incorrect ui text for is_runtime 2011-06-25 17:36:33 +00:00
08cf05d8d5 Bugfix #27765
Thumbnail save for .blend crashed, when being in editmode for a mesh
that has other object users as well. Derivedmesh confusement...

Thanks to Sergey for finding the cause!
2011-06-25 15:54:20 +00:00
418bce9341 fix for building with MSVC release, some edits I made didnt work as I expected but still built for debug 2011-06-25 14:10:46 +00:00
75f572ebb8 Bugfix #27761
Default startup theme used same node header color for "in/out" nodes
as for "inactive or undefined" nodes. This made it impossible to see
which of the output nodes in node setup was 'active'. Made the active
in/out color a slight blueish shade of grey now.
2011-06-25 13:23:14 +00:00
c863cdcaf3 Fixed issues with unit conversion and animation channels. 2011-06-25 07:23:23 +00:00
d888b4d11d wrong rna func type used 2011-06-25 06:54:11 +00:00
da79ab5acc GHOST Cocoa: some changes to Y coordinate conversion in previous commit,
to fix continuous grab being broken (bug report #27760).
2011-06-25 02:10:13 +00:00
826ed5ed1d Fix [#27748] undeterministic behaviour of volumetric renderer
* Made clearer in the UI that the approximate multiple scattering always enables light cache
* Fixed a potential problem in anisotropic scattering
2011-06-25 00:33:36 +00:00
a03707d408 SVN maintenance. 2011-06-24 23:14:26 +00:00
6c33d3f00d Bugfixing and modification to ensure functionality when called from UI. Related to previous commit, 37796. 2011-06-24 17:11:54 +00:00
b437f3fab9 UI and bugfixing for mocap retargeting. Still a WIP, UI/py work will modified to fit coding styles in the future. 2011-06-24 17:05:53 +00:00
12e02fd474 own patch [#27752] Python Callback (Scriptlink functionality)
Python:
 * adds bpy.app.handlers which contains lists, each for an event type:
   render_pre, render_post, load_pre, load_post, save_pre, save_post
 * each list item needs to be a callable object which takes 1 argument (the ID).
 * callbacks are cleared on file load.

Example:
 def MyFunc(scene): print("Callback:", data)
 bpy.app.handlers.render_post.append(MyFunc)

C:
 * This patch adds a generic C callback api which is currently only used by python.
 * Unlike python callbacks these are not cleared on file load.
2011-06-24 16:54:30 +00:00
74520bd1ef move callbacks file out of intern (only contains 1 function but re-using it for new callback api) 2011-06-24 15:10:34 +00:00
05fb0e2d61 First commit to make "Style" settings saved in startup.blend
Usage currently is limited to:
- Panel text, widget text and label text style:
  point size, shadow effects

Setting individual fonts to these is not possible yet, it uses the
default for it.

Access goes via outliner now; check "User Preferences". UI team could
add this in userpref scripts :)
2011-06-24 14:00:15 +00:00
fdb932370b 3D Audio GSoC:
Fixes for crashes reported by Moguri.
2011-06-24 06:39:03 +00:00
ebff5d5fb2 free_bvhtree_from_mesh was incorrectly useing sizeof() when clearing memory. 2011-06-24 05:34:03 +00:00
fd60b73b7b fix [#27742] Smart UV project no longer works in 2.58
failed with active, unselected objects.
2011-06-24 04:12:01 +00:00
3cf2e6b7dc fix [#27747] Modal operator in Special Menu (W) ignores continues grab 2011-06-24 03:59:41 +00:00
734a4aa428 fix [#27746] Black and White Render doesn't work and/or Saves as a Blank screen
convert to grayscale when saving renders rather then only writing the red channel.
2011-06-24 03:49:56 +00:00
fc95ebbc55 W special menu for changing orthographic camera lens scale was missing
btw continues grab doesn't work with this modal ops.. whats up?
2011-06-24 03:41:07 +00:00
a165ad251e BGE Animations: Removing no longer used code and variables. 2011-06-24 00:31:13 +00:00
f969b813a4 BGE Animations: Making BL_Action::SetFrame() not so dependent on timing. This should smooth out things like setActionFrame(). 2011-06-23 23:19:39 +00:00
12ca476b8b BGE Animations: For KX_GameObject.setActionFrame(layer, frame), frame should be a float, not a short. 2011-06-23 23:18:53 +00:00
ea47125f16 BGE Animations: Exposing KX_GameObject's GetActionFrame() and SetActionFrame() to Python. KX_GameObject.setActionFrame() seems to still have some issues, which I suspect to be a timing thing. I may need to find a better way to set the local time. 2011-06-23 22:44:24 +00:00
Dalai Felinto
0c8311fdf9 revert commit 27133: Committing patch [#27133] "Fix for for Object Color in BGE" by Kupoman
This was causing a lot of backward compatibility problems and side effects.

It has to be done properly, linked with Material ObjectColor shader_flag or at least the TF OBCOLOR (which apparently worked at some point so I've been told).
If you need to use OBCOLOR simply keyframe the obcolor and it will work as before.
2011-06-23 22:29:02 +00:00
7996d04474 BGE Animations: Shape Action Actuators are now converted to Action Actuators and new Shape Action Actuators cannot be created. 2011-06-23 22:23:46 +00:00
f1a2d46aa0 BGE Animations: Adding the concept of priority back. Priority is handled on a per layer basis. 2011-06-23 22:12:49 +00:00
0fbca841ef BGE Animations: Making the play modes for the Acton Actuator behave more like they have in the past. The only one that still needs work now is Flipper. Property, Loop End, Loop Stop, Play, and Ping Pong should all now be behaving as they used to. 2011-06-23 22:00:54 +00:00
c518aa1383 GHOST Cocoa: move y origin top/bottom conversions out of windowmanager module
and into GHOST. Also fixes a problem where e.g. the user preferences window
would not open under the mouse cursor correctly.
2011-06-23 19:55:47 +00:00
545bf50e1d BGE Animations: Adding shape actions to BL_Action. This means Shape Actions now work through the Action actuator. I still need to handle blendin for shape actions though. 2011-06-23 19:49:53 +00:00
a014886c57 Fix typo in addon user preferences menu. 2011-06-23 19:42:54 +00:00
8d179ca920 BGE Animations: BL_Action now creates a PointerRNA only when constructed instead of on each Update() call. 2011-06-23 19:20:28 +00:00
2d2aa95227 BGE Animations: Making shape actions work again:
* BL_DeformableGameObject is no longer responsible for handling keys, BL_ShapeDeformer is
  * BL_ShapeDeformer also creates a copy of the key on construction and puts it back on the mesh when destructed. This avoids us permanently modifying Blender data.
  * I'm not too fond of clearing out the key every frame, but this works and I can't think of another alternative at the moment (something may be possible with some key juggling)
2011-06-23 19:09:09 +00:00
Lukas Toenne
587b51831d More flexible size options for particle billboards. This adds scale factors for width and height of billboards, relative to the particle size. It's useful when the particle size is primarily used for collision and the like, so the billboard appearance can be adjusted independently. Also allows non-square billboards.
In addition the billboards can be scaled by the particle velocity with optional head and tail factors (similar to line drawing options). This allows for pseudo-motionblur effects.
2011-06-23 18:59:47 +00:00
413bc87e4f Merge with trunk r37757. 2011-06-23 17:30:56 +00:00
Nathan Letwory
e7c6b535b0 Remove unnecessary check. OpenAL, SDL, JACK don't depend on samplerate. 2011-06-23 17:29:18 +00:00
0767779387 fix for building mingw in debug mode 2011-06-23 16:33:59 +00:00
99253abef8 allow building with ffmpeg but not aud 2011-06-23 16:10:48 +00:00
bb3742fe91 correction to recent commit & made ffmpeg includes only add when enabled. 2011-06-23 15:58:41 +00:00
c3e48219e6 mistake in own commit. 2011-06-23 15:12:05 +00:00
2023db70a8 cmake option to build without an audio library. 2011-06-23 09:27:56 +00:00
9c2aa3d0ff fix for function before definition in own recent commit. 2011-06-23 07:50:28 +00:00
cc246eaca7 3D Audio GSoC:
- Fixes for MSVC compiling.
- Fix for ffmpeg audio export with timebase, which fixes vorbis encoding (the only codec using this).
2011-06-23 07:16:06 +00:00
2afa7e4944 Merge with trunk r 37746. 2011-06-23 07:14:37 +00:00
53bf66a579 checks in rna range functions that the max value cant be less than the min.
also fix for invalid rage for FILE_OT_filenum.
2011-06-23 06:13:21 +00:00
353cd44301 fix for building on arch linux with ffmpeg version:
LIBAVCODEC_VERSION_MAJOR 52
 LIBAVCODEC_VERSION_MINOR 122
2011-06-23 06:11:13 +00:00
f511409697 fix [#27726] Driven properties not checked for legal UI bounds
The rna set function clamps to the property range however properties with range functions were ignored when set by python or the animation system.

Now call the range function for ints and floats when setting.
2011-06-23 05:58:44 +00:00
5021dd3476 Bugfixes for recent commits:
* Insert Key on Selected Channels in Action Editor was broken
* Transform/Select All tools in Action Editor were broken as result of
filtering changes.
* Set Visibility operator, when used from Graph Editor now does
similar things to the TabKey lock/unlock operator with regards to the
flags it uses for filtering
2011-06-22 13:30:59 +00:00
c48e146738 Bugfix [#21276] The Tab key is not working in the Graph Editor when
the list of animated curves is closed

At long last, this old bludger can be put out to pasture. I figured it
would involve some of the visibility-filtering stuff I added, but this
required a bit extra effort than anticipated.
2011-06-22 12:54:26 +00:00
fb1ded6572 update automatic rna changelog 2011-06-22 12:05:24 +00:00
ab2026bf42 Animation Channel Filtering Refactor - Part 3 (Visibility Flag Split)
* This (big) commit is aimed at cleaning up the filtering flags used
by the animation channel filtering code. The list of filtering flags
has been growing a bit "organically" since it's humble origins for use
in the Action Editor some 3 years (IIRC) ago now during a weekend
hackathon. Obviously, some things have ended up tacked on, while
others have been the product of other flag options. Nevertheless, it
was time for a bit of a spring clean!

* Most notably, one area where the system outgrown its original design
for the Action Editor was in terms of the "visibility" filtering flag
it was using. While in the Action Editor the concept of what channels
to include was strictly dictated by whether the channel hierarchy
showed it, in the Graph Editor this is not always the case. In other
words, there was a difference between the data the channels
represented being visible and the channels for that data being visible
in the hierarchy.

Long story short: this lead to bug report [#27076] (and many like it),
where if you selected an F-Curve, then collapsed the Group it was in,
then even after selecting another F-Curve in another Group, the
original F-Curve's properties would still be shown in the Properties
Region. The good news is that this commit fixes this issue right away!

* More good news will follow, as I start checking on the flag usage of
other tools, but I'm committing this first so that we have a stable
reference (of code similar to the old buggy stuff) on which we can
fall back to later to find bugs (should they pop up).

Anyways, back to the trenches!
2011-06-22 11:41:26 +00:00
1309f17103 cmake was installing .bfont.ttf in ~/.blender/VER/config, use ~/.blender/VER instead (as with scons) 2011-06-22 08:43:01 +00:00
be94dc10c1 split cmake check configuration out 2011-06-22 05:30:06 +00:00
11c0ee5c76 Merged with trunk r37717. 2011-06-21 21:10:36 +00:00
2d3d025e8c 3D Audio GSoC:
- Sequencer dynamics: Now it's possible to change the output channels and the resampling quality also increased (previously maximum quality was 44,1 kHz)
- Changed two buffers to use ffmpeg allocation, not sure if that helps somehow.
2011-06-21 20:39:41 +00:00
8e6b5598e0 3D Audio GSoC:
Adapting all readers to maximally support dynamic resampling/rechanneling, introducing a DynamicIIRFilter for example.
2011-06-21 20:35:09 +00:00
6d5b224184 3D Audio GSoC:
Removing unneeded AUD_ResampleFactory.
2011-06-21 20:32:25 +00:00
fba07308bf 3D Audio GSoC:
- Converting AUD_SampleRate to a double
- Removing AUD_DefaultMixer
- Introducing AUD_ResampleReader as base class for all resampling readers.
2011-06-21 20:29:02 +00:00
d5eaffda23 3D Audio GSoC:
Dynamic resampling for libsamplerate and linear resampling.
2011-06-21 20:25:48 +00:00
c89b4e4b66 3D Audio GSoC:
- Implemented a nice rechanneling solution with unofficial speaker arrangement standards similar to what OpenAL soft has
- Renamend AUD_Channel in the C API to AUD_Handle
- Removed the unlogical 7.2 speaker configuration, that's a hardware only config
2011-06-21 20:24:40 +00:00
044887b5a4 3D Audio GSoC:
- Created Handle classes
- Changed Reference counting completely
- Fixing some streaming bugs
- Completely disabled OpenAL Buffered Factories (they were unused anyway)
2011-06-21 20:21:43 +00:00
cc71dcc218 3D Audio GSoC:
Streaming improved.
2011-06-21 20:14:53 +00:00
7ba4362c72 3D Audio GSoC:
Memory bug fix.
2011-06-21 20:14:07 +00:00
3d932ba496 3D Audio GSoC:
Buffer.assureSize - a function that should long have been there.
2011-06-21 20:13:27 +00:00
f2ceca4eb0 3D Audio GSoC:
Code cleanup: rewriting some functions to static methods.
2011-06-21 20:12:39 +00:00
Nathan Letwory
3c8056a40b Bump version in Doxyfile. 2011-06-21 19:31:06 +00:00
eaae38551f pep8 compliance 2011-06-21 17:17:51 +00:00
d33b63c5d8 update cmake checker to ignore file list and add some headers to the source list. 2011-06-21 17:00:34 +00:00
22c68cd748 New 2.58 splash image. Thanks Rogério Perdiz!
(Judge committee Sebastian_K && FrancoisGFX)
2011-06-21 16:54:34 +00:00
20e273a695 Upping the release number to 2.58 2011-06-21 16:38:28 +00:00
8a335767d5 Snapping/Project
Disable editmesh as target if proportional edit is on (that was messed up incorrectly in revision 33233)
2011-06-21 15:28:13 +00:00
5dd76a3f4e 1 pixel tweak to have outliner icons + selection circles align
for default DPI. Problem now is that icons/text are scaling
and drawing with pixel units, whilst other items draw subpixel.
This makes not every dpi size result in perfect aligning yet.
2011-06-21 13:02:21 +00:00
2145005e5e Fix for [#26939] Hair Combing intersects emitter when combed fast
* Hair combing now uses substeps to apply the combing when the mouse movement exceeds 0.2 of the brush radius.
* This could make combing a bit slower on fast mouse movements, but the increase in combing quality is definitely worth it.
2011-06-21 11:15:37 +00:00
a50aa13fac py api: make all classes __init__ functions in a readonly state, except for operators.
In bug [#27701], the panels __init__ function (which runs on every draw), was adding new rna properties.
2011-06-21 08:09:42 +00:00
418d2ce49e allow rna to set vertex parent indices, blender checks for invalid values on access.
build blenderplayer by default on linux with scons.
2011-06-21 07:41:49 +00:00
b73caa63c0 correct FSF address, as pointed out by Dave Plater 2011-06-21 05:01:54 +00:00
a48a4270dc fix for PLY import using directory only select, operators which define 'files' but not 'filename' or 'filepath' would use the directory selector.
also made code less confusing.
2011-06-21 04:03:26 +00:00
24ca3eb4c4 AnimFiltering Code Cleanups - Part 2
* Changed all int's to size_t's, where the int's were used for size of
channel list returned
* Object vs Base is now passed to filtering functions - was relic from
old owner/ownertype code which required access to bases
* Found bug in NLA code where filter was being overwritten and then
used again as input for some other function unintentionally
* Found bug where trying to select a NLA strip would crash if lamp
data was around
2011-06-21 04:01:51 +00:00
a4178b7a6a Bugfix: Fix for autokey menu in Timeline
The mode items were only enabled correctly when auto-keyframing was
enabled.
2011-06-21 02:31:12 +00:00
6a039f1a5c fix [#27707] Script error for UVs->Copy Mirrored UV coords 2011-06-21 02:16:22 +00:00
ccc112a857 fix for error in swizzle assignment leaving an unhandled exception. 2011-06-21 02:15:07 +00:00
3cad2a72b5 Animation Channel Filtering Refactor - Part 1
* Removed list-expanders for Materials, Textures, and Particles. So
instead of:
  Object
     Materials
        Material 1
             ... material 1 anim data ...
  we now have
  Object
     Material 1
         ... material 1 anim data ...
 This makes it faster+easier to get to these items. If you don't want
to see all of these, you can still use the data-block filters from the
header to hide these.

* Internal cleanup - removed "owner" and "ownertype" settings from
bAnimListElem. The purpose of these was muddled, and more of a hassle
to maintain than doing anything useful - it was only really used for
the stuff above.

* Removed need for "sa->spacedata.first" casts all over the show for
animation editor tools which needed access to editor data. This can
now be retrieved directly.
2011-06-21 01:41:39 +00:00
207911bdb3 Merge with trunk r37677 2011-06-20 22:55:18 +00:00
Dalai Felinto
768184753a fix for build with cmake (patch by Joerg Mueller) 2011-06-20 22:44:35 +00:00
4030f82aad ndof trackball works... somehow 2011-06-20 21:34:23 +00:00
Nathan Letwory
d10b247c78 Set Player building to True by default. 2011-06-20 20:51:12 +00:00
ed3dadf489 Blender 2.58 release preparations:
* Update of Release Log Links to point to: http://www.blender.org/development/release-logs/blender-258/
2011-06-20 20:21:52 +00:00
8ff6bd8828 Blender 2.58 release preparations:
* Updated readme file.
2011-06-20 20:15:02 +00:00
761015e6ef == CMake ==
* added same definition used for compiling openjpeg with SCons, was causing issues when linking
2011-06-20 18:16:46 +00:00
c849a938a0 fix for crash drawing zero length motion path and a leak with zero length paths. 2011-06-20 17:50:59 +00:00
203e02f9d7 Fix related to #27689: unwrap, pack island, minimize stretch now cancel
operator if there are no uv's selected.
2011-06-20 17:28:25 +00:00
f6d899af05 Bugfix #27692
Render + compositing error:
When adding renderlayer nodes in a composite, without having own
scene render, the renderlayer nodes were not tagged as changed,
causing compositing to give previous result.
2011-06-20 16:38:21 +00:00
692e0ebc13 fix for incorrect bake api usage. but not a bug. 2011-06-20 15:20:33 +00:00
11014defdb since render branch isnt planned to be merged now, enable strict warning flags for cmake and tag unused vars. 2011-06-20 15:17:02 +00:00
Nathan Letwory
0faeffb8a5 Compile fix. Note that var introduction must happen at start of code block. 2011-06-20 13:04:11 +00:00
Nathan Letwory
d278637337 Fix [#26912] [Collada] Screw up with names/ids on import
Reported by Valeriy Firsov

Use the node name if it exists, fall back to id otherwise.
2011-06-20 12:43:10 +00:00
Nathan Letwory
81f5679ff5 Fix [#26821] Import Collada: instance_node still incorrectly handled
reported by David Roy
patch submitted by Camillo Dell'mour
2011-06-20 10:50:17 +00:00
Nathan Letwory
201052a3ff Apply Patch [#27454] Add simple Transparency texture import for COLLADA
submitted by Steffen Ohrendorf.
2011-06-20 10:28:37 +00:00
Nathan Letwory
bb851003b5 Remove redundant e usage. Energy is already multiplied into exported light. Fixes potential bug (e used uninitialised, reported by Campbell Barton on IRC). 2011-06-20 10:22:39 +00:00
78ea4561a4 fix for python ABI search, was missing 'd' 2011-06-20 09:39:14 +00:00
Nathan Letwory
dbe7488c43 Fix [#27474] Blender crashes on collada import if input_set is missing
reported by Rebin Cornelius.

This needs patch from upstream report http://code.google.com/p/opencollada/issues/list?thanks=164 applied to OpenCOLLADA. lib/windows/collada and lib/win64/collada have already been updated. Ensures we don't read past array boundaries.
2011-06-20 09:34:35 +00:00
c27fa83cf7 Fix #27703: reflection texture coordinates + nodes not working right in GLSL. 2011-06-20 09:08:41 +00:00
57ed59eac2 fix [#27700] Add effect strip ignore channel argument 2011-06-20 04:09:33 +00:00
3e76245eb2 small fix, This enables correction of the tangent when normal mapping is in use and tangent lighting will be used 2011-06-20 03:37:41 +00:00
09fc9257e1 fix [#27664] startup.blend - manipulator user-prefs
regarding issues in the report
 1) fixed in previous commit.
 2) intentional leaving as is.
 3) left 'handle size' as is IMHO acceptably general, edited 'hotshop' tooltip/
 4) corrected default values.
2011-06-20 03:24:07 +00:00
4ce97c5ed4 changes to startup.blend
- enable manipulator option, applies to new 3d views (not sure why it was disabled) - reported in [#27664]
- remove rigify and netrender scene ID properties
- set console scrollback to 256, was 128 which could sometimes cut off output of help()
- enabled syntax highlighting and line number in the text editor for game logic and python screens
2011-06-20 03:10:02 +00:00
97a85fe100 - add example for python rna property update
- edit the copyright for blender specific cmake find modules
2011-06-20 02:54:56 +00:00
6d7e3509a9 small safety fix for recent commit to normal mapping (uninitialised variables) 2011-06-20 02:37:13 +00:00
015b0ea00a small fix to turntable mode, first attempt at trackball code, ndof now respects view locking and updates 'User Persp' etc. 2011-06-20 01:54:49 +00:00
dd364944d1 By Morten S. Mikkelsen; this adds support for tangent bump shading
left: legacy bump, righ: sparkybump

http://pasteall.org/pic/show.php?id=13875

bugs [#26320], [#27506]

there's still an issue with texture OSA as you can see
2011-06-19 20:41:41 +00:00
b1b8284f9b fix for python include in msvc 2011-06-19 15:55:49 +00:00
c6eaa2300a cmake: add find jack module 2011-06-19 15:03:50 +00:00
a8d4c1f8a9 cmake: add find jemalloc module 2011-06-19 14:55:51 +00:00
56c0f69071 fix for building opencollada + msvc 2011-06-19 14:14:29 +00:00
29977893d3 since cmake new auto-detects many features, print a summery of the configuration on first run. 2011-06-19 13:49:20 +00:00
6790dbe9db cmake: fix for recent break in msvc+collada, also dont cache duplicate python include/library variables. 2011-06-19 13:06:21 +00:00
e7c8169086 add back PYTHON_LIBPATH, needed for installing on python 2011-06-19 11:04:15 +00:00
77698421b3 fix for building with msvc 2011-06-19 10:19:10 +00:00
8eb375048e removing python includes for blenkernel since pynodes are commented. 2011-06-19 09:32:37 +00:00
def6bcd4e5 cmake add module for finding fftw3.
also allow debug blender to build with non debug python
2011-06-19 08:57:34 +00:00
167bcc2b67 cmake: add libsamplerate find module 2011-06-19 08:20:02 +00:00
b15a2b0ffc cmake: added FindOpenJPEG module. 2011-06-19 07:46:24 +00:00
adb81a0351 Fixed Armature Import Without Skin controllers. Armatures and animations get imported. Some inaccuracy remains with bone transforms. 2011-06-19 07:43:43 +00:00
145944d66f cmake:
new macro file_list_suffix() for adding a suffix to every file in a path before the file extension.
 useful to create names for debug libs on windows.
2011-06-19 06:57:56 +00:00
28f0d96bea 2011-06-19 04:20:43 +00:00
f31bae0aab fixed possible use of uninitialized variable. 2011-06-19 01:23:50 +00:00
31093223cd SVN maintenance. 2011-06-18 23:22:55 +00:00
85051eff69 disabled debug logging now that a workaround is in place (Win32 ndof buttons) 2011-06-18 20:32:14 +00:00
e46e2d9d54 resolved collision among WM event types, ndof no longer encroaches on keyboard turf 2011-06-18 20:30:09 +00:00
412da91a47 SpacePilotPro has 31 buttons, not 29 -- '+' and '-' work again 2011-06-18 19:40:30 +00:00
598c54f0e9 ndof device detection on Windows, safer button handling 2011-06-18 16:50:54 +00:00
2c68bdb03e cmake: make python search into a find package module. 2011-06-18 15:53:47 +00:00
5e59d0c8bb make better use of cmake builtin funcitons for finding python library/header 2011-06-18 15:15:31 +00:00
968b2a8afb rename cmake include/libraries to conform with suggested cmake names 2011-06-18 14:12:54 +00:00
549c2c58a1 added FindSndFile cmake module to replace inline checks. 2011-06-18 12:12:19 +00:00
2d01cb5b27 fix for error caused with module relocation - broke loading ngons in OBJ files 2011-06-18 11:40:44 +00:00
1283b07409 use ascii drawing function where utf8 isnt needed. 2011-06-18 09:01:26 +00:00
82216030e9 py-api: store frequently used strings as unicode PyObject's to avoid creating/distroying every time.
also fix for cmake warning
2011-06-18 08:45:45 +00:00
f7e22c729e throw an error if preprocessor definitions are used for DNA array lengths (previously would fail silently & not work right). 2011-06-18 03:14:24 +00:00
ebc2f7064d tiny fix for Linux 2011-06-17 22:45:33 +00:00
56e312a88e filled out USB product IDs for all 3Dconnexion devices 2011-06-17 22:19:16 +00:00
64d02584e1 fix fileselect for images from sequencer
* recent code to provide directory only fileselect broke selection of images with 'A' (rev. rev. 37552.)
2011-06-17 21:24:05 +00:00
d53801e8f6 updated Mac code to work with latest 3Dx beta driver -- all buttons work now 2011-06-17 21:04:23 +00:00
3f0e480ba9 unskinned armature import improved but unfinished. 2011-06-17 20:01:24 +00:00
e7591d177b finished Mac NDOF device detection, moved core device ID to base NDOFManager, clarified info/error messages 2011-06-17 19:48:26 +00:00
c9b0ce8693 creating armatures for bones which are not skinned( in progress ) 2011-06-17 18:41:43 +00:00
b13e12a7bb NDOF device detection on Mac -- phase 1 2011-06-17 16:10:06 +00:00
f69d805338 Bugfix, irc report:
Adding new material in active node didn't update the material
properties buttons.
2011-06-17 13:57:41 +00:00
5dcb853ed9 Fix #27660: texture space panel was missing for curve & metaballs, now they
have same panel as mesh. Patch by Ronan Ducluzeau, thanks!
2011-06-17 13:53:47 +00:00
b306566a44 fix [#25598] projection surface snap issue
Excuse the thrashing, this is from r35438, reverted r35444 under the _wrong_ impression Martin considered unacceptable.
2011-06-17 13:02:23 +00:00
68a12c74b6 fix [#26621] Memory leaks when creating popup window.
also fixes memory leak when cancelling a popup dialog (new image for example).
2011-06-17 12:48:33 +00:00
c9360a4c1e Added calculation to determine change in root translation when retargeting - needs cleanup/optimization 2011-06-17 11:47:45 +00:00
46ef1bb170 adding .m4a video extension 2011-06-17 08:50:47 +00:00
758450ee49 BGE: Camera.getScreenPosition wasn't working because of an unhandled exception when called with a non vector argument (object or object name). 2011-06-17 07:27:27 +00:00
1563ae8098 aiff too 2011-06-17 07:18:51 +00:00
28f347dc42 Adding .aif to known audio extensions so it doesn't get hiden by default 2011-06-17 07:15:36 +00:00
775ea4de92 fix for memory leak converting an idproperty group into a dict 2011-06-17 05:56:17 +00:00
7cbc4c0dd7 IDProperty python module update
- add support for IDProp array slicing, but not resizing.
- rename array attribute type to typecode and use chars 'f', 'd', 'i' which match pythons array module. (was using int's which only have a meaning internally).
- rename function 'convert_to_pyobject' to 'to_dict' and 'to_list' for IDProp group and array types respectively.
- remove 'len' array attribute, calling len(array) is fine.
2011-06-17 05:45:46 +00:00
ac089ddd15 fix for drawing bones names twice in object with viewport 'Outline' option enabled. 2011-06-17 03:17:07 +00:00
897b570c1a ulti line formatting for PyErr_Format calls (no functional change) 2011-06-17 02:26:34 +00:00
1356082063 fix [#27681] Python: crash assigning a 'set' to an array 2011-06-17 02:22:38 +00:00
Nathan Letwory
1d3a025e0a Fix [#27666] Python/Windows issue: "import uuid" results in an error popup
submitted by Gaia Clary

Ignore msvc runtime libs while linking. Tested on win64.
2011-06-17 00:30:04 +00:00
18b5dac5ca Standard views (front, top, etc.) work from buttons on SpaceExplorer and SpacePilotPro. Linux can now determine which NDOF device is plugged in. 2011-06-16 19:45:38 +00:00
d240733ae2 Reverted Exporter unit conversion modifications.
Animation Importer Code Cleanup.
2011-06-16 19:25:21 +00:00
5ef551c97e Small todo item: outliner display actions were sending undo pushes, not needed
for UI stuff.
2011-06-16 17:14:38 +00:00
30823cbb87 Python Docs: update layout.html to match blender.org development submenu changes. 2011-06-16 16:13:26 +00:00
dce577ad85 use directory selector for properties defined as PROP_DIRPATH, user preferences 'File' buttons for eg. 2011-06-16 15:28:39 +00:00
6aa524f357 AnimationExporter - Quaternion to euler conversion ( in progress )
AnimationImporter 
- Action group assignment to bones
- Revert to conversion of angles from deg to rad.
2011-06-16 15:04:37 +00:00
fd24c99b5d directory only filesel for operators which don't have a filepath or filename property. 2011-06-16 15:01:22 +00:00
216ba20942 fix [#27671] Transforming sequencer effects strips crashes 2011-06-16 12:48:25 +00:00
a90d30c863 3D Audio GSoC:
GameEngine Python access sound actuator's sound (with setting! :-D).
2011-06-16 09:13:29 +00:00
f227c4a064 fix [#27675] Bones shift out of place when leaving edit mode
- float precision issue, details commented in the source.
2011-06-16 07:59:22 +00:00
3ede710a3c fix for baking actions for objects with no animation data. 2011-06-16 07:48:22 +00:00
4a5a9dc71c fix for own error in r37542 2011-06-16 07:02:33 +00:00
0a998decb6 fix [#27673] Value sliders >1 do not represent numerical ratios right
the soft limits for array buttons not take into account the min/max of all array elements
2011-06-16 06:47:54 +00:00
051dedeeec minor speedup for UI draw code, noticed ui_get_but_val() could be called 3-5 times per button draw,
for RNA buttons this gets the entire array for each call so its not great to call many times.
2011-06-16 06:00:02 +00:00
2e8ca6d196 include some extra search paths for cmake openexr 2011-06-16 02:55:26 +00:00
0575c05eb0 fix to FindOpenEXR pointed out by Sergey Sharybin,
also added check for IlmThread and marked individual library cache variables as advanced.
2011-06-16 02:48:07 +00:00
cfcc4b4fcd == Simple Title Cards for Sequencer ==
This commit adds an experimental effect strip to the sequencer: "Title
Card".

This is useful for adding simple one-line text section headers or
"title cards" (i.e. title + author/contact details) to video clips,
which is often seen in demo videos accompanying papers and/or
animation tests.

See http://aligorith.blogspot.com/2011/06/gsoc11-simple-title-
cards.html for some more details on usage.

Code notes:
- There are a few things I've done here which will probably need
cleaning up. For instance, the hacks to get threadsafe fonts for
rendering, and also the way I've tried to piggyback the backdrop
drawing on top of the Solid Colour strips (this method was used to
keep changes here minimal, but is quite fragile if things change).
2011-06-16 02:46:38 +00:00
4ef1e67ce8 BGE_Animations: Removing the Fcurve Actuator as a possible actuator type, but keeping a lot of the code around as reference. 2011-06-16 02:14:01 +00:00
65af1dcecd BGE Animations: Making sure the Action Actuator has a valid action before attempting to play. 2011-06-16 01:59:50 +00:00
47b061609d BGE Animations: FCurve Actuators are now converted to Action Actuators in do_versions(). Note: The fcurve actuator still needs to be removed from menus and such. 2011-06-16 01:57:39 +00:00
c02006bc2b BGE Animations: Adding the ipo flag options to the action actuator. This still needs more testing. 2011-06-16 01:18:52 +00:00
1c0a6c6468 Blenderplayer: Setting G.main to NULL after it's freed to avoid issues later with GPU_free_images() 2011-06-15 23:43:02 +00:00
d7ef491845 cleaned up event logging, added HID -> function table for SpacePilot PRO 2011-06-15 20:56:42 +00:00
d5cafb808f fixed typos, renamed the HID -> function lookup tables 2011-06-15 19:57:10 +00:00
060e2b295b mapping HID button codes -> functions, for SpaceNavigator and SpaceExplorer 2011-06-15 19:45:00 +00:00
a3e296fc40 Committing patch #25676 Anisotropic filtering in viewport and BGE by me.
This patch adds anisotropic filtering of textures in the viewport and the BGE. The quality of the filtering is adjustable in the user preferences under System. For more information on anisotropic filtering:
http://en.wikipedia.org/wiki/Anisotropic_filtering

One current limitation of this setup (having the option a user preference) is it makes runtimes more troublesome. Runtimes don't have user preferences set, so for now the blender player defaults to 2x AF. Options will be added later to change this value (probably a command line option).
2011-06-15 18:59:22 +00:00
49f7a4d8f8 3D Audio GSoC:
Temporary fix for MSVC.
2011-06-15 18:52:52 +00:00
04584806cc handle up to 32 buttons (up from 16), for SpacePilot PRO 2011-06-15 16:05:10 +00:00
08c155845d remove unused arguments 2011-06-15 14:06:25 +00:00
04c5f054d8 error in recent commit 2011-06-15 14:00:50 +00:00
c02121b708 use full library paths for openexr & msvc, also remove unneeded exr includes 2011-06-15 13:54:57 +00:00
bb6e0834e0 cmake: combine debug/optimized into one target_link_libraries() call. 2011-06-15 13:42:02 +00:00
4f3936083a replace own inline cmake include search logic for a typical FindXXX.cmake module. 2011-06-15 12:09:02 +00:00
2164847928 fix for openexr include path, for both cmake and scons a custom openexr install wouldn't work since it expected BF_OPENEXR/include and BF_OPENEXR/include/OpenEXR to be in the search path. 2011-06-15 11:50:45 +00:00
39443dcb53 Code cleanup: remove reference to workob global that no longer exists. 2011-06-15 10:19:35 +00:00
aaf7dae5f1 Code cleanup: remove unused shaded draw mode code. 2011-06-15 10:17:06 +00:00
5e41807135 Fix #27654: vertex parenting not working with constructive modifiers.
Vertex parents were not requesting the original index layer, now do this as
part of depsgraph building, and make constraints with vertex groups use the
same system. Fix is based on patch by Campbell, but with some changes.
2011-06-15 09:45:26 +00:00
b09bb948ee fix [#27658] Bake action operator error on non armature objects
add support for baking object transformations too, also add option to clear constraints (off by default).
2011-06-15 06:25:05 +00:00
6aa7777144 removed temporary debug logging 2011-06-15 02:40:25 +00:00
1669ab6648 correction for own commit r37492 2011-06-15 02:17:39 +00:00
b89924f5dd de-duplicate multires image filter function. (no functional change) 2011-06-15 02:14:38 +00:00
1d41694e69 fix [#27662] Storing png/tga images ignore Alpha settings
- don't clear alpha when baking RGB images
- when baking results in partial alpha. set the depth to 32.
2011-06-15 01:56:49 +00:00
62ba2d4c68 Changes to quick explode
- fix python error when the object had an empty material slot
- initialize start frame from the current frame
- set frame range to 300000 max (which is blenders own maximum)
- mesh order was arbitrary, instead use selected -> active, removed invert option.

also fix for missing include in bpy_extras.view3d_utils
2011-06-15 00:16:30 +00:00
f8212f4e03 3D Audio GSoC:
Removing unneeded const from Factory::createReader.
2011-06-14 21:22:22 +00:00
f3f3bcc45e New Animation Import system. Only Mesh object animation import support implemented for now. 2011-06-14 20:42:01 +00:00
3fe26d7093 RGB curve widget follows user preference DPI now too. 2011-06-14 17:48:42 +00:00
cc2c511207 Nodes display now follow 'DPI' user pref too 2011-06-14 15:55:46 +00:00
d8974a60f6 3D Audio GSoC:
Changed Readers to top-down architecture instead of bottom-up.
2011-06-14 12:13:19 +00:00
8ff0c2e107 Merge with trunk r37475. 2011-06-14 12:06:21 +00:00
23e2bfed23 fix [#25423] Mirror clipping is ignored with single vertex extrusion when using Face Snapping. 2011-06-14 11:18:00 +00:00
7272bb643c Bugfix: Distance DVar doesn't work with new Local Space
Fixed references in UI to the old property, and adapted the backend
code to work for the new options too.
2011-06-14 11:01:36 +00:00
113d653edb Bugfix #27573
Sculpt and Paint undo steps kept hanging in the sculpt/paint modes.
Now undo will switch back to global undo, and redo enter the mode 
again. Just like weight/vertex paint.
2011-06-14 09:55:38 +00:00
ce914e51ab fix [#27659] Segfault when adding None to a group 2011-06-14 09:41:29 +00:00
214f4e8c03 include some useful info in bge docs, by ZiauddinMK on IRC. 2011-06-14 07:46:38 +00:00
5fd9bd8bc9 Fixed weird assignment inside condition statement. 2011-06-14 07:33:25 +00:00
f4452b2ee7 revert own fix for [#27648], looks like this needs to work differently to be fixed. 2011-06-14 05:19:16 +00:00
991634c147 own mistake in recent mask commit. 2011-06-14 04:19:00 +00:00
c0dc197257 edit DAG defines to make it easier to add more & modify. 2011-06-14 04:05:58 +00:00
d3dbd2f5b4 mask modifier: replace bone hash lookup with a boolean array to quickly check selection state.
simple test gives ~28% speedup in building the vertex hash. (no functional change)
2011-06-14 02:26:43 +00:00
dd3b729d62 mask modifier was taking into account zero weighted verts. 2011-06-14 01:54:03 +00:00
e6b0a77956 fix [#27648] Weird shading behind grayed out negate checkbox 2011-06-14 01:04:11 +00:00
1243992f27 cmake: correct uninitialized vars 2011-06-14 00:24:50 +00:00
519111514f Since scene sequence strips use the 'use_sequencer' setting, make it available in the sequencer panel. 2011-06-13 21:35:24 +00:00
975a78bb4f 2.5 Camera:
* Increase "Ortho_scale" maximum from 1k to 4k, Request by francoisgfx.
2011-06-13 20:21:48 +00:00
Dalai Felinto
a2dda7c74d BGE Patch: [#27425] Allow to change the damping of the camera actuator
##########
original name: "Allow to change the strenght of the "go behind" constraint of the camera actuator"

The camera actuator is an actuator that drive the camera to follow an object, with a set of constraint.
Currently, when the object followed rotate on himself (like a person, or an helicopter), the camera is really slow to go behind (at least 10 seconds).

This patch gives the UI to tweak the strenght of the 'go behind'[named damping] constraint.
###########

epydocs (rst) updated too
2011-06-13 17:08:33 +00:00
Nathan Letwory
0af94b45e4 Fix [#27463] COLLADA light quadratic attenuation exported wrong?
Reported by Pelle Johnsen
Fix falloff import. Point light and Spot light always were set to inverse quad, instead of choosing the proper one based on imported values.

The
2011-06-13 15:07:36 +00:00
4ca197ba59 Fix #27540: bug with bump mapping + reflection texture coordinates + nodes. 2011-06-13 14:56:47 +00:00
aff9f8ce81 Fix #27570: apply button for modifiers required the modifier to be enabled, we
now just enable the modifier before apply.

Patch Bastien Montagne (with some tweaks), thanks!
2011-06-13 14:11:29 +00:00
a4216cb1d4 Transformation Channel Driver Variables - "Proper Localspace"
By popular demand, the "Transformation Channel" driver variable type
now has a "local space" transform space option which uses the same
magic that constraints use for defining local-space. This is what many
bug reporters and feature requesters have moaned about for a while
now, so after reviewing several of the bug reports which lead to the
current situation, here is what has been much-wanted for so long!

In order to implement this, I've:
- renamed the old "Local Space" option here to "Transformation Space",
in order to prevent old rigs breaking. This has also been kept, as it
is useful for #21384 (though perhaps with this new option it isn't
needed anymore)
- reviewed my fix for #20870 (IIRC, a Durian-era bug), which related
to the non-uniqueness of matrix->euler decomposition
2011-06-13 13:54:21 +00:00
97b966f2d6 Fix #27594: non-active object in weight paint mode doesn't free memory.
Also removed some commented out 2.4x code that is already replaced.
2011-06-13 12:03:13 +00:00
a6b23a00a4 Bugfix #27537
Using texture properties, the material nodes now re-render previews too.
2011-06-13 12:03:05 +00:00
e8eefbf757 Fix #27635: GLSL filter uniform variable not set for group instance.
The problem was that SCA_2DFilterActuator was defining and using a
variable called "m_gameObj", when it should be using "m_gameobj" as
defined by SCA_ILogicBrick. The way it was, reparenting did only half
the work required to duplicate the actuator.

Patch by Alex Fraser, thanks!
2011-06-13 11:36:25 +00:00
Nathan Letwory
1b1fdd7ecf Turn off Quicktime support by default. Will be phased out soon. 2011-06-13 09:33:27 +00:00
fedc811014 minor updates to the cmake checker 2011-06-13 03:09:14 +00:00
ef1824cdcb Elbeem / Fluidsim:
a) Also fixed an "upcomming" bug in regard of gravx,y,z now converted into an array.
b) Little typo fix
2011-06-13 00:02:23 +00:00
5745f99dee Elbeem / Fluidsim update:
a) Enable the possibility to remove the "air bubble" around submerged collision object. This feature is enabled as standard for new files. The code was found in elbeem by nudelZ, coded and provided by Nils Thürey (thanks!)
b) Old baked files gets deleted if a new bake gets started (were overwritten before and resulted in weird old bake + new bake mixture) (idea by nudelZ)
2011-06-12 23:51:30 +00:00
f96769ef0a Fix/Workaround for [#27643] drawing glitch:
* Removed the Icon of the menu, when an icon is used, it draws a triangle icon, assuming it is a sub menu.
2011-06-12 20:27:28 +00:00
f6de4fecfa Bugfix #27519
Full Sample AA (FSA) was failing in cases. Bug report was an empty
scene (with compo nodes) linking in another .blend scene (with render).

That case gave warning "FSA not supported with rendering". That now is
allowed.

Then I noticed FSA was giving corrupt sample buffers or crashes in cases, 
especially on first buffer, this appeared to be a missing compo tag on 
first sample buffer.

Lastly, to make FSA render a tiny bit less frustrating: added render window
statistic to show which of the FSA steps is being done.
2011-06-12 13:35:17 +00:00
e8a1d03570 Quick Explode operator:
* Sets up a particle system and an explode modifier.
* In "blend" mode requires two selected objects and creates "crossed keyed" particle systems between the objects for a simple blend effect where the first object explodes and then recombines as the second object.
* Also renamed the other quick effect operators as "Quick ..." to bring some consistency to the operators (also nice that now you can just write "quick" to the operator search and get all these operators).
2011-06-12 11:14:28 +00:00
09492d9072 Bug fix: keyed physics didn't work properly if the first key wasn't the keyed particle system itself
* Also some nicer rotation handling for the explode modifier
2011-06-12 11:09:39 +00:00
982eb9942c 2.5 Image Buttons:
* Code cleanup, removed some unnecessary code.
2011-06-12 11:03:21 +00:00
1d40ca4860 2.5 Image Buttons:
* Fixed an alignment issue, left column had unnecessary row declaration.
2011-06-12 10:24:47 +00:00
Dalai Felinto
6c15d28db2 Logic: clear "Script" when setting Script Controller mode to "Module"
The text datablock was linked to the controller. So even if the script was set to 'module' and saved, once linked/appended the object the script would come together.
If someone wants to implement this "clear" only once the file is saved, please go ahead. But I believe it's ok to  loose the script if you change it for module (and with the new datablock lookup it's straightforward/quick to reassign a textblock)

-- bug not reported anywhere, from my own list
2011-06-12 08:34:53 +00:00
9095612b85 remove some warning for unused struct members 2011-06-11 17:05:20 +00:00
90d8fcb522 improved autocompleation when there is a common prefix 2011-06-11 17:03:26 +00:00
3d7dc49e3e warning fix for gcc 2011-06-11 15:37:16 +00:00
Lukas Toenne
fbd5b4eb53 Fix for edge mesh BVH: The edge distance callback for leaf nodes was calculating actual sqrt'ed distance, while needing squared distance to be compatible with bounding box checks. This also solves previous concerns about performance when using sqrt in the comparison callback. 2011-06-11 14:08:46 +00:00
e0dee9b41d Bugfix #27105
Node editor: collapsed node didn't allow to size it using the
right hand side grab thingemabobs.
2011-06-11 13:12:57 +00:00
3361ae0271 Bugfix #27138
Theme color fix for button type "Value slider".
On text editing mode, the selected part of the text was invisible.
2011-06-11 12:10:01 +00:00
81946b9138 fix for recent commit, this stops makesdna from working right:
/* ... // ...  */
2011-06-11 10:09:56 +00:00
a3101de7be remove backbuf from internal struct's (unused in 2.5x) 2011-06-11 08:55:29 +00:00
c2e1f3a1e2 fix for using system includes, the include macro wasn't un-setting the previous include list so system includes could be mixed up with non system includes.
Also workaround for CMake 2.8.4 & GNU-Make which doesn't set CMAKE_INCLUDE_SYSTEM_FLAG_C
2011-06-11 06:00:28 +00:00
450f176a8f split Win32 NDOF manager into 2 files to fix Mac scons build 2011-06-11 02:26:28 +00:00
8e85491ab7 BGE Animations: Adding a layer option to Action actuators. 2011-06-11 01:03:03 +00:00
6c7daf58be one small change -- SpaceNav works on Windows 2011-06-11 00:58:49 +00:00
7b124242e7 SpaceNav works on Linux 2011-06-11 00:25:48 +00:00
e67edaf6ac BGE Animations: KX_GameObjects now only instantiate a BL_ActionManger if they need one. 2011-06-11 00:22:35 +00:00
c431863312 BGE Animations:
* Adding BL_Action::Play() and BL_Action::Stop()
  * Making BL_ActonManger reuse BL_Actions instead of recreating them all the time
  * Making the Property play type work for the Action actuator.
2011-06-11 00:14:47 +00:00
6fb82a85c9 * Code cleanup 2011-06-10 21:06:59 +00:00
a4aa7abd65 suspiciously consistent typo 2011-06-10 20:59:48 +00:00
6c343e7b61 2.5 Modifier UI Script:
* Tiny improvement, no need to have split declaration outside of if branch.
2011-06-10 20:41:22 +00:00
ce3f040e14 fix [#27627] Strange behavior with solid open gl lights
disable turning off all lights in the user preferences.
2011-06-10 16:59:15 +00:00
753623d1d7 Bugfix #27136
Ending localview - which is similar to layer change - should send
update similar to change layers too. Needed for example when loading
a file saved in local view or when changing time in localview.
2011-06-10 14:03:51 +00:00
9d5f436d75 Alignment tweaks to F-Modifier header buttons.
I was going to include this change along with support for moving
FModifiers around on the stack, though that looks like it might be a
bit more involved than first though. To be dealt with later...
2011-06-10 13:06:51 +00:00
44bce3b876 Adding properties to Keying Sets via the Scene properties will now set
"entire array" property on by default, making it easier to add
transforms to Keying Sets.

This doesn't affect Keying Set paths added via Python or any other
means.
2011-06-10 12:51:07 +00:00
f4b2e9b91d Added operator to make importing Keying Sets from files easier.
This can be found from the dropdown below the Add/Remove buttons in
the Properties Editor -> Scene -> Keying Sets panel.
2011-06-10 12:43:06 +00:00
ff5fb2f4ef Bugfix: Text Editor operators crash when invoked from Python/Console 2011-06-10 12:08:55 +00:00
eeba877926 fix [#27607] Scene's render.filepath gets cropped to 159 characters
use 240 char limit, remove backbuffer path which wasn't used.
2011-06-10 10:13:50 +00:00
9cf0bbb95c added a check to console auto-compleation for pythons struct_seq type, so bpy.app and sys.float_info autocompleate their attributes rather then bring treated as a typle. 2011-06-10 09:44:27 +00:00
1f56eee953 fix [#27495] Incorrect result of image name autocompletion 2011-06-10 07:22:35 +00:00
30fb5710b6 Made WinXP or later required, SpaceNav (almost) working on Windows 2011-06-10 01:34:53 +00:00
c8a654c41c add includes for windows. 2011-06-09 18:28:58 +00:00
13465fd817 update for tests, error out when duplicate modules are found, all ctest tests pass again. 2011-06-09 16:20:00 +00:00
10082b7986 Bugfix #27081
Displacement mapping didn't do linear interpolation between pixels,
causing render artefacts. Now it uses for image render without AA
a default interploation filter of 1 pixel size.

Fix provided by Miika Hamalainen. Thanks!
2011-06-09 16:12:10 +00:00
Lukas Toenne
55c488abf0 Fix for GLSL material node inside groups. These were using the GPULink point from the input stack argument, but this only exists for directly linked nodes. If a node is linked directly to a group socket, which is not linked externally, the stack argument is actually the external group input. 2011-06-09 16:05:34 +00:00
3a51735fbe Bugfix #27078
Added notifier to make material preview update when selecting a face
in editmode with a different material than displayed.
2011-06-09 15:54:44 +00:00
cede08e1e2 Bugfix #26886
Operator redo: F6 menu didn't work for macros yet (like Duplicate-grab).
2011-06-09 15:26:05 +00:00
15d0d3f41e replace log() calls with constants 2011-06-09 14:27:51 +00:00
d4ae38cc6c fix for own mistake & fix some comments. 2011-06-09 13:46:34 +00:00
ee71338724 Bugfix: Setting action for AnimData via RNA didn't change the
usercounts.

Cheers to Atom on BA for noticing this.
2011-06-09 12:44:38 +00:00
e4500096a5 retarget.py updated with function to complete the retarget to the end user, with inheritance and bone roll taken under account 2011-06-09 12:30:24 +00:00
21f5a87999 fix for memory leak re-binding meshes. 2011-06-09 11:19:34 +00:00
75dcc2a7dd Fix [#27378] ASC-CDL Color Balance Node does not allow for full range of values
Report title is incorrect, it does allow for the full range, but actually allows too much, so clamping slope and power min at 0.
2011-06-09 11:09:46 +00:00
09e96f6b56 RNA properties - expose values as radians rather then degrees
- sequencer wipe angle
- mesh autosmooth
- bevel modifier angle
- edge split angle
2011-06-09 08:58:27 +00:00
152b06dc82 use a better method for finding the precision to use for float buttons, about 4x faster to calculate and will show for eg, 0.0108 rather than 0.01, but 0.0100001 still displays as 0.01. 2011-06-09 07:40:30 +00:00
252f7c9af8 fix [#27616] Appending an object from a file brings all existing group links to scene
When appending from a blend file which had an object already linked, _but_ was not in any scenes.
- the linked object would be instanced.
2011-06-09 04:28:53 +00:00
912db4cdb5 [#27615] Box select of mesh object disabled or translated due to curve object
ED_view3d_init_mats_rv3d was calling glMultMatrixf() which was mostly harmless but could also lead to confusing bugs (2 reported previously).
Looked into this and every call to ED_view3d_init_mats_rv3d except for object drawing, doesn't need this so made a second version of ED_view3d_init_mats_rv3d - ED_view3d_init_mats_rv3d_gl which does the matrix multiplication, remove confusing checks in selection code.
2011-06-09 03:56:32 +00:00
e7e1bc4ca1 add foreachIDLink function for cloth, remove cloth specific newlibadr calls in readfile. 2011-06-09 02:47:22 +00:00
e75ff53452 migrated NDOF code from soc-2010-merwin, SpaceNavigator now works on Mac blender 2011-06-08 21:18:03 +00:00
43ec34f054 Bugfix #27601
Revision for previous fix; fast gaussian now survives on images
with a dimension smaller than 3 pixels!

Thanks Bastien Montagne for patch.
2011-06-08 16:08:57 +00:00
65ec26ab83 fix for own error r35918, generalizing looping over modifier ID links
broke loading smoke group references because they already had calls to
newlibadr_us() elsewhere, removing those assignments fixes loading.
2011-06-08 16:00:52 +00:00
17becc751d Bugfix #27601
Scaling in compostior down to 1 pixel size crashed gaussian blur.
2011-06-08 15:17:38 +00:00
Nathan Letwory
05b54bec3b Apply [#27477] COLLADA export support for textures mapped to COLSPEC
Patch provided by Pelle Johnsen
2011-06-08 13:00:25 +00:00
Nathan Letwory
899f2776db Shuffle some build code around to ensure debug builds on Windows actually run too.
* creator/SConscript is now empty, code is moved to an emitter function in Blender.py
* make sure COLLADA debug libs are used when BF_DEBUG=True
2011-06-08 11:53:07 +00:00
cec102e781 Bugfix [#27586] P for setting playback range is clamped to > 0
Thanks for the patch Bastien Montagne. Was just legacy code from 2.4x
2011-06-08 10:57:24 +00:00
Dalai Felinto
40c171a69f fix of fix :| [real fix for #36787 -- it was wrongly fixed on #36964]
I guess I tested the fix outside the camera view (which always worked). duhhh
Working now.
2011-06-08 09:01:41 +00:00
9dd066eb65 cmake: remove python include in the wm module, set opengl as a system include. 2011-06-08 05:39:58 +00:00
42ece56e91 don't write file history in backgound mode (running ctest would overwrite all my recent-files.txt), and add an error about mingw/quicktime being unsupported. 2011-06-08 01:53:12 +00:00
7fd1fe9fc8 draw sequences with invalid effect frame ranges pink to highlight they are invalid and wont render. 2011-06-07 18:34:33 +00:00
299602b360 fix for vertex group copy to selected
- was using un-initialized stack memory if the source / target object had no vertex group.
- if the target object had no vertex groups it would fails silently (not a bug but not very good functionality)
- added an error message if any copying fails.
2011-06-07 18:04:03 +00:00
d16c1f3665 fix for sequencer transform with effects strips where the effects could be moved to invalid times to avoid overlap but would immediately refresh back to overlapping locations after. 2011-06-07 16:47:25 +00:00
e44ae2c2a9 disable the readonly state while rna property callbacks run. 2011-06-07 16:08:49 +00:00
53939ee4e9 Fix: correct spacing for file select items, using font size + dpi. 2011-06-07 15:33:01 +00:00
9c8cc9fe60 rna option not to save certain properties for redoing later, currently only used by operator presets. 2011-06-07 10:54:57 +00:00
3cd3cc892f fix for edge slide snapping values being incorrect (reported by Nether Hound).
Also dont call the value a 'Percent' and clamp the range displayed in the header.
snap range being
2011-06-07 09:35:20 +00:00
617a08162f update ctest md5sums for import/export to match changes to the scripts, also some minor formatting change for bpy_props.c 2011-06-07 08:47:33 +00:00
8ae4476fc4 getting useful results out of the round compo node was tricky, use the second value to determine how much to round by (can be used like a posterize filter) 2011-06-07 08:16:42 +00:00
044ae5e3c8 error pointed out by Jeroen Bakker with the math nodes round function. was incorrectly using the output rather then the input. 2011-06-07 07:57:26 +00:00
82a0461361 fix for glitch in previous commit with 0.00002 displaying as 0.000020, this uses 2 calls to double_round which I'd rather avoid but at least it now works right for users. 2011-06-07 05:26:10 +00:00
06c3756db8 smarter precision calculation, so 0.000001 isn't displayed as 0.00.
there is a minor problem with this commit:
 0.00001 --> 0.00001 # good
 0.000015 --> 0.000015 # good
 0.0000199 --> 0.00002 # ok
 0.00002 --> 0.000020 # wrong, has trailing 0

Tried to fix this but the case is hard to check for without more calculations which Id like to avoid.
2011-06-07 04:06:10 +00:00
34b0c217f8 Move UI float precission calculation into its own function. 2011-06-07 02:39:40 +00:00
b9abe6211f BGE Animations: Removing some redundant pose copies from BL_Action. 2011-06-06 23:35:24 +00:00
474d9c0274 A line of code -can- wreck your day. Should work now, :) 2011-06-06 23:19:25 +00:00
b481524fde fix for float projection painting, now updating correctly.
This fix also allows for partial update of the image, speeding up painting. 
The different code path implemented will be used to upload high resolution images to OpenGL when onion branch is merged.
Due to conversion of float textures to/from sRGB, corrections made to brush color sampling to take account of the image profile. This is not 100% correct yet as texture images used for projection painting strokes are not converted to/from sRGB yet(This has been decided due to loss of precision for 8-bit formats). It will have to do for now, though.

last-minute update, exr image loading is broken, will fix asap
2011-06-06 22:10:05 +00:00
e2e0bc2c44 clean branch for spacenav/ndof/3D mouse integration 2011-06-06 20:53:58 +00:00
9088b69f7a UI: fix render properties panel order, it didn't match order in startup.blend,
so was different when opening a new property editor.
2011-06-06 20:04:58 +00:00
841c988179 UI: rename mesh Settings panel to Texture Space, since it only contains
settings related to that. Also close by default.
2011-06-06 19:44:28 +00:00
13dbae76e6 One more debug line was deleted from multires bakers.
Now it would work really fast.
2011-06-06 19:33:38 +00:00
fff0592738 Fix for new baker and float images. Also removed code used for debugging. 2011-06-06 19:06:44 +00:00
5fca1aa323 2.5 todo:
User setting "DPI" now works for outliner too.
(todo: color picker, brush menu, nodes, fileselect path buttons, view2d sliders, ...)
2011-06-06 18:04:57 +00:00
8cee328546 Support for update callbacks in python defined RNA properties as discussed last meeting.
This means script authors can perform actions using these callbacks rather then on drawing which puts blender in a readonly state.

Simple example:

import bpy
def up_func(self, context):
    print("test")

bpy.types.Scene.testprop = bpy.props.FloatProperty(update=up_func)
bpy.context.scene.testprop = 11

# prints -> test
2011-06-06 17:50:20 +00:00
0c1298f972 avoid cd'ing with the makefile stub 2011-06-06 16:00:32 +00:00
4d254f23ca Keymaps: fix keymap items created in python being added with the python
operator names instead of the internal names. This wasn't really noticeable,
expect that it broke automatically looking up shortcuts for display in menus.
2011-06-06 13:35:43 +00:00
111b0bf698 2.5 Text Editor:
* Added back Red Alert for "Resolve External conflicts" warning.
2011-06-06 12:52:26 +00:00
fc6dcdf17f bug [#27582] Screen Editing > Split and Join area don't work.
added 'INTERNAL' operator flag so operators which are only meant to be called by other operators or internal use are not displayed to the user.

Currently only use this flag for the operator search toolbox, is ignored in debug mode.
2011-06-06 11:56:54 +00:00
a43309e8d4 Added cancel callbacks to modal operators which allocates memory
in invoke callback. This prevents unfreed memory blocks when quiting
Bledner with modal operator running.
2011-06-06 11:04:54 +00:00
4d0026f7b9 fix for 2D paint being off by 1 pixel on x/y axis, most obvious when zoomed in. 2011-06-06 10:08:27 +00:00
6a1e74418c use the same stippled drawing for colorband background as alpha color swatches, with low DPI would look squashed, also use the same colors for both. 2011-06-06 09:12:03 +00:00
2f5c7623b0 fix/workaround [#27559] Color picker fails with a very small brush
fade out small brushes so the brush wont interfere with the color directly under the cursor.
2011-06-06 08:43:17 +00:00
7b9eabb6f2 fix from nico_ga on IRC, building on MSVC with jack but not ffmpeg. 2011-06-06 08:40:47 +00:00
e8bc3fe0e3 object-mode lattice bounds were not taken into account when calculating min/max.
effected view-selected, center-origin & local view.
2011-06-06 07:29:57 +00:00
e55833a094 fix [#27572] Mirror Shapekey and Mirror vertex Group not working for Lattice. 2011-06-06 06:40:09 +00:00
e18bea1cfc BGE Animations: Getting the Frame Property option of the Action Actuator working again. 2011-06-06 06:31:42 +00:00
dd4f0f0b9d Resolve 2 theme issues
[#27056] default active and selected colors need to be visually different
[#27584] Please change sharpness/seam color
2011-06-06 03:53:22 +00:00
7c9d76199c spelling corrections 2011-06-06 00:48:10 +00:00
e4bb5403d3 fix for crash opening the file selector twice with multiple windows open (when the mouse was over the inactive window). 2011-06-06 00:42:36 +00:00
Dalai Felinto
7da45bcbcb replacing -> arrows by proper ASCII arrows on Transformation Constraint
Note: Text Editor doesn't support this chr(187) properly. I hardcoded and commented the ui file. I hope it's fine.
2011-06-05 23:38:11 +00:00
5922b69501 Fix [#27438] Volume Material Density Inaccuracy
Lower density limit for shading optimisation was set too high
2011-06-05 22:35:37 +00:00
ef5f78ecc7 3D Audio GSoC:
Making it possible to access blenders internal sounds via Python.
2011-06-05 22:06:29 +00:00
a1c22262fe Bake from multires mesh
=======================

Added option to baked named "Bake From Multires" which is avaliable for
normals baking and displacement baking.

If this option is enabled, then no additional hi-res meshes and render
structures would be created . This saves plenty of memory and meshes
with millions of faces could be successfully baked in few minutes.

Baking happens from highest level against viewport subdivision level,
so workflow is following:
  - Set viewport level to level at which texture would be applied
    during final rendering.
  - Choose Displacement/Normals baking.
  - Enable "Bake From Multires" option.
  - You're ready to bake.

Displacement baker had aditional option named "Low Resolution Mesh".
This option is used to set if you want texture for realtime (games)
usage.

Internally it does the following:
  - If it's disabled, displacement is calculated from subdivided
    viewport level, so texture looks "smooth" (it's how default
    baked works).
  - If it's enabled, dispalcement is calculated against unsubdivided
    viewport levels. This leads to "scales". This isn;t useful for
    offline renders much, but very useful for creating game textures.

Special thanks to Morten Mikkelsen (aka sparky) for all mathematics
and other work he've done fr this patch!
2011-06-05 20:54:04 +00:00
f2daf2ca6b Add new animation export features.
- Bone animations are also exported as f-curve animations now. As a result euler rotaions of bones are also exported. All animations with BEZIER, LINEAR or STEP ipo are exported. 
- Quaternion rotations export.
- Object parented with armatures, animations to Armature Objects as a whole are also exported.
2011-06-05 18:58:22 +00:00
a580b5ec80 fixed warning, signed/unsigned mismatch, blo/readfile.c line 1742 2011-06-05 18:00:24 +00:00
68a3303013 operator buttons get a red highlight when alert is set for the layout 2011-06-05 17:02:57 +00:00
68d4c64db8 own commit r37199 gave problems with duplicating objects, use different fix. 2011-06-05 15:29:50 +00:00
08f44adba9 file selector now scales with DPI better 2011-06-05 14:00:06 +00:00
56befd2666 colorband and image header were ignoring DPI size 2011-06-05 13:20:30 +00:00
485a89f5d3 Bugfix: new DPI-controlled UI size code was setting 'view2d re-init'
flag on ED_area_initialize(). This however was causing 2 problems;
- the view state got reset (popping window view back)
- the view2d operator polls failed (sliders didnt work)

This re-init was only needed for the headers though, limiting it
to these types of regions solves it.
2011-06-05 12:57:09 +00:00
619df86fad panel headers were not scaling with DPI properly 2011-06-05 12:47:17 +00:00
24292793a0 scale the file selector UI with the DPI, the region size can still be wrong though. 2011-06-05 10:05:13 +00:00
1d236097ab workaround for supremely annoying UI glitch where you could accidentally hide the file selector header by accident.
using the logic - that a header taking up the full screen-area height will not have an action-zone added for resizing.
2011-06-05 09:22:14 +00:00
07619d8fc0 with the new scalable UI. hard coded values were still used for resizing the headers, with DPI of 56 the headers could not be un-hidden. 2011-06-05 09:00:36 +00:00
50d24425ce py/drivers disable dont interning strings, no need really since this isnt done on every execution. 2011-06-05 08:18:37 +00:00
b727202921 compile without splash and icons when WITH_HEADLESS is set. 2011-06-05 07:55:18 +00:00
3a6adc0ed3 fix [#27554] vertex group names
- duplicate vertex group names were not being checked for.
- also made the first duplicate end with .001 rather than .000
2011-06-05 04:52:32 +00:00
a79072c80d SVN maintenance. 2011-06-05 00:10:20 +00:00
bd0d5247f4 Changed "Convert" to "Convert to" since the first one is incorrect. Removed some dots at the end of tooltips following the standard 2011-06-04 23:02:44 +00:00
88676349a4 Code holiday commit:
- fix: user pref, window title was reset to 'Blender' on tab usage

- Undo history menu back:
  - name "Undo History"
  - hotkey alt+ctrl+z (alt+apple+z for mac)
  - works like 2.4x, only for global undo, editmode and particle edit.

- Menu scroll
  - for small windows or screens, popup menus now allow to display
    all items, using internal scrolling
  - works with a timer, scrolling 10 items per second when mouse 
    is over the top or bottom arrow
  - if menu is too big to display, it now draws to top or bottom, 
    based on largest available space.
  - also works for hotkey driven pop up menus.

- User pref "DPI" follows widget/layout size
  - widgets & headers now become bigger and smaller, to match 
    'dpi' font sizes. Works well to match UI to monitor size.
  - note that icons can get fuzzy, we need better mipmaps for it
2011-06-04 17:03:46 +00:00
4a59928484 CMake option 'WITH_HEADLESS' to build blender in headless mode (no x11/xlib) with NULL ghost classe. 2011-06-04 14:12:55 +00:00
a440679c57 edits to make these cmake files compatible with my own basic cmake parser which checks for correctness in our files. 2011-06-04 11:06:41 +00:00
c6f3fabd16 fix [#27568] Segmentation fault in Sequencer when adding an effect strip with python
disallow negative length effect strips.
2011-06-04 10:39:04 +00:00
86f2f425bf UI for texture space in mesh/curve/mball data properties
http://pasteall.org/pic/show.php?id=13244
2011-06-04 08:09:34 +00:00
185663b52b FModifier Influence/BlendIn-Out
Following on from my commit to introduce frame ranges for FModifiers,
those frame ranges can now have blend in/out values. By setting a
blendin or blendout value, you're specifying the number of frames for
the modifier's "full influence" to take effect or fade out relative to
the start/end frames.

The "full influence" above needs a little clarification.

When the "use influence" setting is enabled, "full influence" is taken
from the "influence" slider (a new setting). Otherwise, it uses 1.0
(i.e. unmodified influence, same as old behaviour before the
introduction of influence controls). The influence slider basically
says how much the modifier's effects are allowed to contribute to the
final result.

---

Notes:
- This opt-in "Use Influence" approach is really forced upon us
because there are heaps of old files for which we cannot easily
version patch without spending some effort going through all the data
in the file, hunting out the F-Modifiers.
- interpf() seems to use a backwards order compared to everything else
2011-06-04 06:22:01 +00:00
1915f1b1e2 quiet 2 compiler warnings and update man page 2011-06-04 03:07:56 +00:00
e27fe1c049 Actions are no longer created with Fake Users
Due to overwhelming support from animators, Actions are no longer
created with fake users by default. If you're mainly creating action
libraries (the primary use case and argument for having this, mostly
used for creating a set of motions for games or perhaps to use in
NLA), you're really in the minority here.

For the most part, fake users just lead to heaps of "dangling" actions
in files which newbies (and even experienced users) may often be
unaware of. Since Fake Users are really more of an "opt-in" system
everywhere else (i.e. when creating Material Libraries), the same
should applied for Actions and creating Action Libraries.
2011-06-04 02:23:17 +00:00
56e20eafe9 User Pref to not overwrite Recent Files list everytime you open a new
file

This is just a more formalised version of a local hack I've been
running locally for the past year now. It's especially useful when you
want to maintain your own set of recently opened test files (or
perhaps current project files), but then be able to quickly open some
.blend files downloaded from the web (i.e. checking out some bug
report, or how someone else sets up some node setup) without
loosing/polluting your existing recent files list as a result of doing
so, and having to either resort to some nasty methods to get it back.

Of course, this is still really hacky, as for instance, it means that
the currently opened file will not show up in the recent files list
for quick reload. However, that's why this is a userpref :)
2011-06-04 01:54:34 +00:00
d1c542ce05 3D Audio GSoC:
Memory management improvements.
2011-06-03 23:28:57 +00:00
cd04cff180 Merge with trunk revision 37149. 2011-06-03 23:24:01 +00:00
71419c4647 Building fix: added missing include. Aligorith: would be nice to include needed headers for functions you use... 2011-06-03 23:12:34 +00:00
d84c6a3cdb Fix for linux buildslaves. Now they should be able to compile branches. 2011-06-03 21:36:39 +00:00
06ca703737 BuildBot: various changes to support building branches. 2011-06-03 20:44:23 +00:00
05a1c144ad Experimental Feature: Frame Range Masks for FModifiers
Using this feature, it is now possible to for example have different
noise-profiles for different parts of a curve, which makes it possible
to do animate camera shake for example.

Or perhaps, for having greater control of mixing and matching
different parts of F-Modifier effects, such as combining several
generator modifiers to get multi-case functions for instance.

See http://aligorith.blogspot.com/2011/06/gsoc11-fmodifier-range-
masks.html for details.
2011-06-03 13:34:02 +00:00
Dalai Felinto
ed072f2fef BugFix: [#27556] Replace mesh for gfx in "Edit Object" actuator act illogically + other booleans that are flipped
Now I think we are all good. We still have a few actuators that were using TOGN before but that I didn't make as negative_boolean.

All fixed now:
- parent actuator
- edit object actuator
- action actuator
- shape actuator
2011-06-03 07:53:55 +00:00
6480ab10db Fix for [#27461] Particle Instance modifier doesn't work correctly with Hair Dynamics.
* Wrong matrix used for dynamic hair.
2011-06-03 05:51:39 +00:00
7ee9becfa3 disable python/string enum duplication from last commit because the array of duplicated strings can be freed and the pointers to the strings referenced still, the problem with python freeing strings that RNA references remains. 2011-06-03 04:39:18 +00:00
089d997cbc when making the C/RNA copy of the python enum, duplicate all strings since theres no guarantee python wont free them immediately after, though in practice this isn't so common. 2011-06-03 04:21:41 +00:00
5332c602c9 pre-allocate the array when converting py/rna enums, also fix for memory leak with bad values. 2011-06-03 03:19:22 +00:00
60f5b51484 Fix for [#27562] audaspace not playing files in blenderplayer
blenderplayer wasn't initialising ffmpeg

This might also fix [#27558] GE Sound works in Blender but not in runtimes
2011-06-02 23:25:38 +00:00
45093f50bc Quiet warnings for picky compilers. 2011-06-02 23:10:05 +00:00
83609edd51 Fix related to #27309: group nodes with a linked datablock that was missing would crash. 2011-06-02 17:34:01 +00:00
fbff066a70 2nd commit of mine. Contains retarget.py, which has functions for retargeting an animated armature to a second one, given a user mapping of the hiearchy. Currently creates an intermediate skeleton that solves some of the major issues. WIP 2011-06-02 17:19:07 +00:00
32368aac43 Fix #27241: crash with point density texture when using particle age/velocity
fallof for object vertices.
2011-06-02 16:59:12 +00:00
dd0522242a addons now show expanded list again (since Brecht's commit now makes it fast)
also add utility function for getting cleaned, unique names from python: bpy_extras.io_utils.unique_name(...)
2011-06-02 15:21:47 +00:00
7138fef58a UI: fix two issues with expanded enum property buttons:
* they were too slow for dynamic python enums, calling the callback
  to list the items for each button, to get a tooltip
* enum tooltips sometimes were showing the same description twice
2011-06-02 14:18:51 +00:00
e3a46d05a7 Added operator to remove all useless unused actions from the current
.blend file.
* From operator search, find "Clear Useless Actions"
* "Action library" actions are preserved by this operator. It targets
actions without any F-Curves
* By default, only actions which are single-user (where that user is a
Fake user) will be targeted. This can be changed to have it target any
"dangling" action that doesn't have any F-Curves
* A save/reload cycle is still required to fully remove such Actions
from the current file. Though at least now it's a simpler process to
have these semi-automatically removed ;)
2011-06-02 13:03:46 +00:00
b4872b84c8 fix for [#27410] Manual save kills actual .blend file if disk space is low
- moved do_history into WM_write_file after successful write of .blend@ temporary file
- Added new file flag, to avoid writing history on writing the startup.blend, autosave files and undo.

Thanks Campbell, Brecht for review!
2011-06-02 12:44:59 +00:00
02c6cb8039 Deleting keyframes usability tweak:
There won't be dangling "empty" actions left behind anymore in the
DopeSheet channel list after you've deleted all their keyframes (and
don't want to add keyframes to them anymore).

Of course, this poses problems with more actions getting created if
you then go and keyframe those objects again. If this does turn out to
be an equally bad problem, then another approach from the channel
filtering code side (probably aided by the restructed code) will help
(though doesn't solve the problem where people complain of having
heaps of "empty" actions dangling from objects they no longer want
animated).
2011-06-02 12:21:55 +00:00
072d350aab Time-Slide Fix:
Second attempt at fix for only having a single-key selected. In this
case, it just uses the start/end frame as it's min/max
2011-06-02 11:58:13 +00:00
b41427c66b Bugfix: "Time Slide" tool broken
Dunno how long this has been broken for (*), but the Time Slide
transform tool in DopeSheet no longer did anything most of the time.
It appeared to be be caused by some blotched indexing code from ages
ago. I've fixed this problem, as well as preventing the case where it
would also give errors when only a single key was selected.

(*) Does anyone actually use this tool? IIRC, this was added during
Orange, though I can't find the commit for this anymore or why it was
added. Probably it might be better to just let it go...
2011-06-02 11:51:38 +00:00
1ba4550d27 committed this by mistake. 2011-06-02 09:04:07 +00:00
ab2450a58d fix [#27557] Linked object (camera) should not be able to set position by using camera to view operator 2011-06-02 08:55:26 +00:00
dbe1f07c76 fix [#27553] Weird resulsts when animating opacity on (color) strip 2011-06-02 08:45:28 +00:00
d46da5a09d mathutils support for color arithmetic, also some minor whitespace edits. 2011-06-02 08:29:16 +00:00
211cd99cbc Fix #27539: Sculpt data is lost after editing base mesh
Face's totdisp was set to correct value, but memory hasn't been
allocated for disps. Handle this in multires_topology_changed(),
so the whole MDISPS layer wouldn't be totally re-allocated when
applying displacement.
2011-06-02 04:58:27 +00:00
97d7496c96 update to glew 1.6 from 1.5.8 2011-06-02 00:05:54 +00:00
22ca037c58 uninitialized variable was used when ensuring mirrored vertex groups. 2011-06-01 23:55:49 +00:00
81982140b8 Fix #27550: texture node editor header was still showing texture datablock
selector even if there is no active texture slot or node, now it's disabled
in that case.
2011-06-01 16:17:38 +00:00
f50fb549db UI: template_ID now takes into account if the property is editable. 2011-06-01 16:13:48 +00:00
36cbd78bc3 Fix #27490: export key configuration gave error when trying to export
properties from an unknown (e.g. removed) operator.
2011-06-01 14:35:14 +00:00
7b4aac3e34 Fix #27481: windows uninstaller could remove files unrelated to blender
when installing to a folder that already existed. Now the uninstaller
will remove only the files it has installed, and leave any other files
in the installation directory intact.
2011-06-01 13:13:55 +00:00
a180bfe267 Fix #27541: f-curve generator modifier file read missed endian switch,
found by Guillaume Roguez.
2011-06-01 13:10:37 +00:00
dd43faa855 * Fix compiler warning from previous commit
* For new themes, size of handles in graph editor is now 4. Allows
them to be seen better. (TODO: .b.blend needs updating)
2011-06-01 11:55:28 +00:00
39bbf3854a BGE Animations: Reimplemented the continuous function of the action actuator.
* To do this, I've added Get/SetFrame() functions.
  * I've also cleaned up a little bit of the wrap around logic in BL_Action.cpp.
2011-06-01 07:42:40 +00:00
6394261e54 BGE Animations: Removing guards that prevent the action actuator from being used on non-armatures. Object animation works through this actuator now too. :) 2011-06-01 06:43:10 +00:00
23888be423 Usability Tweak [#27469]
Adding/Rename markers (M/Ctrl-M) were restricted to only being
available when the mouse was hovering just over the time scroller at
the bottom of animation editors, as otherwise we'd get nasty keymap
conflicts where markers keymap would block all the primary function
keymaps.

However, in the case of Adding/Renaming markers, there are no other
keys which currently conflict with these in such cases. Hence, it is
fine to let these ones be able to be run from anywhere within the
animation editors, which should make it easier to add markers for
lipsyncing purposes again for example.
2011-06-01 06:26:54 +00:00
c6dbb0b201 Bugfix [#27535] Insert delta key via IKey menu doesn't work well
Index needed to be incrememented regardless of whether Keying Set is
able to be shown, otherwise lookup fails with wrong Keying Set found
2011-06-01 06:09:34 +00:00
38d87ee48e BGE Animations: Beginning work on the new action actuator.
* Converted BL_ActionActuator::Update() to use the new action api (still just armatures)
  * Not all of the functionality of the old Update() have been ported (Lood end, continued animation, etc)
  * Things are still pretty messy. Once have things more flushed out, I'll start stripping more of the old actuator out.
2011-06-01 05:48:37 +00:00
54a37ba855 BGE Animations: Adding more functions to BL_ActionManager and KX_GameObject:
BL_ActionManager:
    * IsActionDone(short layer) - Checks to see if the animation on the given layer has finished.

  KX_GameObject:
    * PlayAction(...) - Adds an action to the object's action manager
    * StopAction(short layer) - Remove an action from the object's action manager
    * IsActionDone(short layer) - Check if an action has finished playing
2011-06-01 05:46:19 +00:00
b31385f3bd BGE Animations: fixing a crash with looping armature actions. 2011-06-01 05:40:48 +00:00
Lukas Toenne
cc7a154fac Material nodes were checking the nodestack->hasinput flag to determin whether the original material settings or the node input data would be used. This causes trouble when the input data is not the direct input constant of the node nor a direct link in the same tree (i.e. a group socket). Just checks if sockets are linked now (not very nice, but not hackier than the rest of that node).
Fixes bug #27511.
2011-05-31 17:54:48 +00:00
8d2e4cf42f fix [#27514] Fix Bug 27510 Color key hue flipping error (composite node) 2011-05-31 14:06:29 +00:00
a8a36f31bd Button value reset:
* shortcut key changed from numpad 0 to delete.
* fix missing undo push, now it calls the operator.

Patch by Damir Prebeg, thanks!
2011-05-31 09:56:38 +00:00
f51c9fa496 fix for mistake in case insensitive image load. 2011-05-31 09:55:50 +00:00
b434550edc fix for recent cmake changes 2011-05-31 09:27:33 +00:00
Nathan Letwory
90d3a3eac8 Make sure correct path separator is used. 2011-05-31 08:50:20 +00:00
348f947d80 tag unused rna args. 2011-05-31 02:14:25 +00:00
09da9d4393 cmake maintenance
blender_add_lib now takes a separate include argument to suppress warnings in system includes (mostly ffmpeg & python).
also only build wm_apple.c on apple+carbon configuration.
2011-05-31 01:15:44 +00:00
dcd55cef86 startup.blend: default ffmpeg output audio bitrate changed to 192. 2011-05-30 18:57:28 +00:00
884b9d1557 BGE: fix bug #26775, crash when physics constraint is defined on non-active objects. Patch provided by Sergey Sharybin, verified and applied. 2011-05-30 15:40:01 +00:00
c141ed0aa9 missed this import when moving load image function. 2011-05-30 12:19:30 +00:00
337e74963b Fix #27522: crash when closing new render window with render error message
showing in the main window.
2011-05-30 11:44:28 +00:00
5a3aaf1fd1 cmake formatting adjustment, no functional change. 2011-05-30 10:51:37 +00:00
b92e6985cf fix for cmakes windows install target, was extracting python 4 times, note install(CODE... doesnt support CONFIGURATIONS setting. 2011-05-30 10:39:18 +00:00
c61d39ef6c Add support for exporting F-Curves with BEZIER and STEP INTERPOLATION types. 2011-05-29 19:27:30 +00:00
221472f7b5 Moving the letterbox clear for the embedded player so it only clears when it needs to. Thanks to Juha Mäki-Kanto for the tip. 2011-05-29 18:09:38 +00:00
a72f101ac8 [#25886] Skeleton Sketching - Unclear UI for converting sketches into bones
Thanks Ronan Ducluzeau for the fix and Jason van Gumster for the report.
2011-05-29 16:04:09 +00:00
e1466b8ca2 Fix #27392: boolean intersect's
It was lag of optimization logic, which always retuns object's derivedMesh
if one of of boolean operation's meshes has got no faces.

Actually, result depends on operation and which mesh has got no faces.

Added small utility function to handle this.
2011-05-29 15:53:38 +00:00
57d190ee10 3D Audio GSoC:
Changing converter functions to work when input and output buffer are the same.
2011-05-29 11:25:05 +00:00
11014aa34b access pythons code object directly rather than attribute access. 2011-05-29 11:05:52 +00:00
ebdca474b5 Fixing the initglobals leak in the Blenderplayer (G.main reference was being reassigned before it was freed). 2011-05-29 04:15:35 +00:00
9cfd093a93 Merge with trunk r36987. 2011-05-29 00:48:03 +00:00
fc3904d7b3 General error in coderivative for orthogonal camera. Culprit of new bump failing on orthogonal cameras; bug #27492
Commiting bug kill by Sparky
2011-05-28 21:53:07 +00:00
d635a2b143 Disabling xinput wasn't done completely. 2011-05-28 15:34:02 +00:00
5ca36915a6 Silence some unused-but-set-variable warnings.
And small optimization for text search function :)
2011-05-28 14:52:28 +00:00
628a8151da Fix #27505: Text Editor always indent next line when a " is found (which is not always correct)
Do not indent if there's any non-space character after colon.

This only makes life a bit easier, but it's still not 100% correct indentation
strategy. For example when colon is inside non-closed string or so.
Also there's not indentation for { and un-indentation for }.

Handling such cases would require much smarter strategy..
2011-05-28 14:40:42 +00:00
ce8467ffd3 == FFMPEG ==
Did some fine-tuning for AVOption -> AVOption2 crazyness
2011-05-28 14:16:56 +00:00
9b5800bcd7 fixed "rather then" -> "rather than" typos all over the place 2011-05-28 13:11:24 +00:00
844d6f0ac0 rearranged previous patch to compile with C89
conversion to double probably not needed
better comments
2011-05-28 12:33:53 +00:00
Nathan Letwory
43385394ed Introduce vars before using them, otherwise compile fails (reminder: with C, present all
your vars at the begin of the scope _before any other statement_).
2011-05-28 12:11:39 +00:00
97d553c471 wrong rna access function used in node UI 2011-05-28 12:04:56 +00:00
7154b424e9 Fix: The radial control would fail, in sculpt mode, to set size if object-space sizing was enabled.
This was caused because a small part of sculpt's radial control code did not make it into the new version.  The old code would set a new object-space size by scaling it proportional to how much the new screen-space size was changed.  

The solution I implement here is to do the same scaling inside the RNA callbacks.  This way, users of those properties do not have to worry about inconsistency.

I added a comment warning that brush_set_size, brush_set_unified_size, brush_unprojected_radius, and brush_set_unprojected_radius do not guarantee consistency because it is not always possible to precisely know what the new unprojected radius is in all contexts where you might set the size.  

I would implement the consistency check at the lower level (in those listed functions) but at this time I think it needs to be looked at to make sure that won't cause problems.  In addition, I am not sure that scaling by the ratio of change is strictly correct in all cases.

In any case, this at least fixes the immediate problem.
2011-05-28 11:30:21 +00:00
8246f94317 better error reporting for seq_swap() 2011-05-28 09:59:34 +00:00
a9dd90be78 move load_image into image_utils and add some docstrings to bpy_extras module. 2011-05-28 09:34:45 +00:00
Dalai Felinto
245d36b706 bugfix for: [#26753] PhysicsConstraints ID trouble on 64bit (linux at least).
[the problem also affected OSX]

PhysicsId are Long, not ints (see PyObject* KX_GameObject::PyGetPhysicsId() )

There is a reference in the code to use PyCapsule instead of int. I'm not sure
about that. This patch at least stops the crashes
(update: I talked with Campbell and he repeated that PyCapsule are better, but if long is working it's fine for now).
2011-05-28 08:16:34 +00:00
ecf2d1ff4e - generate sphinx docs for bpy_extras module
- add in support to doc generator for automatically generating docs for submodules.
2011-05-28 07:47:58 +00:00
07dca94476 BGE Animation:
* Adding IPOs to BL_Action
  * Adding a "speed" option to adjust the playback speed by some factor
2011-05-28 07:15:27 +00:00
20ae95422e include ffmpeg_compat header in cmake source list. 2011-05-28 04:53:17 +00:00
Dalai Felinto
d580ae1087 fix for embeded BGE viewport broken when not using letterboxing
this was broken after rev.36787 (api rewritten)
own reported bug, nowhere in the track (just to mess up with the bug fixing statistics)
2011-05-28 01:29:56 +00:00
3ca0bfdd66 == FFMPEG ==
Small fix for a very old bug in swscaler color space support detection.
2011-05-28 00:07:33 +00:00
ac034e1732 == FFMPEG ==
Revert of "SVN commit: /data/svn/bf-blender [36957]
trunk/blender/source/gameengine/ VideoTexture/VideoFFmpeg.cpp: fix for
ffmpeg linking in BGE ( patch by Jens Verwiebe (jensverwiebe) over IRC)"

Sorry folks, that patch breaks current ffmpeg GIT version.

Good news: it's all handled now automagically by ffmpeg_compat.h in 
intern/ffmpeg

so: everything should be fine and dandy for very old and very new versions.
2011-05-27 23:46:47 +00:00
42121590f4 == FFMPEG ==
Added central compatibility header file, which enables blender to compile
against very old ffmpeg versions as well as very new versions using the
*NEW* API. (Old API functions are simulated using macros and inline functions)

Added a whole lot of additional checks, tested against 6 different versions
down the timeline, hopefully, now finally all is well.
2011-05-27 23:33:40 +00:00
Dalai Felinto
a9467182fb fix for ffmpeg linking in BGE (patch by Jens Verwiebe (jensverwiebe) over IRC)
-	av_parse_video_rate(&frameRate, rateStr);
+	av_parse_video_frame_rate(&frameRate, rateStr);
2011-05-27 21:13:44 +00:00
18ff3d5200 Attempted fix for #27482: game engine running slow due to revision 36698 which
fixed frame colors for letterbox drawing (happens when in camera view).

Cause is unclear, seems some sort of strange graphics driver thing on 32 bit.
Changes are a fix for the incorrect usage of glViewport, and avoiding the extra
clear if it's not needed.
2011-05-27 16:20:49 +00:00
d369a6aaaf Windows installer and Path changes, fixing various issues:
* Windows installer not working for non-admin users and multiple users
* Addon scripts not installing next to user configuration
* Portable install not being taken into account in all places

The main problem was the windows installer was installing system scripts in
AppData next to the user configuration directory, which is not shared between
users. Now these are installed in ProgramFiles, and only addon scripts added
by the users go to AppData.

On all platforms, addon scripts were sometimes getting installed between
system scripts, because the scripts folder in the executable directory was
given precedence over the user configuration folder, that is no longer done
now. So addons now behave like user configuration, they are preserved even
if you download a newer build of the same blender version.

If you have an installation of 2.57 on windows, the addon install location
will not change until we do the version bump to 2.58, to avoid conflicts with
the existing the installed 2.57 version.

The old behavior of giving precedence to the local folder was done to support
portable install, where all configuration is written to the local folder. This
is now implemented differently: if and only if a "config" folder exists in the
local folder, portable install will be assumed, and files will only be written
to that local folder.
2011-05-27 09:57:53 +00:00
bd5f78d1a0 Moving BL_Action and BL_ActionManager to Ketsji to avoid linking issues with gcc 2011-05-27 08:45:48 +00:00
0381c444fd == FFMPEG ==
Fixed and added additional ffmpeg cruft checking. Oh dear.
2011-05-27 07:47:42 +00:00
50289e62cb == FFMPEG ==
... and another funny version patch, since OpenSuse obviously used some version "in-between"
2011-05-26 23:51:02 +00:00
72499b070a own recent commits caused crash with the grease pencil in camera view, always pass rv3d argument now.
also found a bug where hex_to_rgb could use un-initialized memory.
2011-05-26 23:29:40 +00:00
f1d3982bf6 == FFMPEG ==
Added some API compatibility code again, since some API-changes weren't even documented 
(they even didn't do a proper version-bump, arghh!)

If it breaks again, please tell!
2011-05-26 23:19:15 +00:00
e070975ae4 missed this in recent commit. 2011-05-26 22:48:06 +00:00
d9fa6db75b weight paint mirror, move duplicate code into a function. 2011-05-26 22:20:29 +00:00
4b9a63c6d3 == FFMPEG ==
* removed a lot of old cruft code for ancient ffmpeg versions
* made it compile again against latest ffmpeg / libav GIT
  (also shouldn't break distro ffmpegs, since those API changes
  have been introduced over a year ago. If it nevertheless breaks,
  please send me an email)
2011-05-26 21:57:02 +00:00
78b8e4a437 remove BLI_streq() since it was hardly used, also replace string search with BLI_findstring(). 2011-05-26 21:04:01 +00:00
06fea1a0ff split BLO_library_append_named_part into 2 function, one that adds objects into the scene and another that just links/appends. 2011-05-26 20:45:19 +00:00
78d41d061b sphinx docstrng formatting (some lines were getting really long) 2011-05-26 19:13:01 +00:00
c6705e464f use a dynamic enum for addons, annoyingly the enum was being generated from python for each of the addon buttons (~14 times per draw) which was noticeably slow, so disabling 'expand' for now.
Eventually it would be good to have the expanded buttons all using the same result from itemf().
2011-05-26 18:11:59 +00:00
93e992c5d9 AnimationExporter class refactoring.
Exported AnimationExporter class to a separate set of files.
2011-05-26 17:07:38 +00:00
57c3c9e70f support for dynamic items in bpy.props.EnumProperty(), the items keyword argument can optionally be a function rather then a list. 2011-05-26 16:07:28 +00:00
155d589333 add the property as an argument to enum item functions, not used yet but needed for dynamic python enums. 2011-05-26 13:38:16 +00:00
36a720606e New experimental drawtype for armatures: "Wire"
This is equivalent to using B-Bones which are all scaled to have
xwidth=zwidth=0, which can be useful to see how some limbs will bend,
without the overhead of blocks blocking the view or having to scale
down bone sizes first.
2011-05-26 12:34:53 +00:00
Nathan Letwory
df823d8896 Since we don't support win2k or older anymore, remove old shortname code. Finally nice full names. 2011-05-26 12:23:11 +00:00
e6d396d17d fix for installing blender as a python module with cmake. 2011-05-26 12:15:42 +00:00
10c30bda08 Bugfix: Label for "Local With Parent" constraint space was broken by
tooltips patch applied a few weeks ago in trunk
2011-05-26 12:09:21 +00:00
514de547ac update to build system excluding parts of the python bundle. 2011-05-26 11:45:25 +00:00
d7f42721f8 Fix #27465: used light groups did not get linked in with materials automatically. 2011-05-26 10:25:51 +00:00
0f1f6e448d Fix #27480: armature multimodifier was not working in edit mode. 2011-05-26 10:21:09 +00:00
042a3ff382 Fix #27445: various operators missing with some non-english system languages.
In the case of this bug e.g. material.new became MATERiAL_OT_new, due to
different capitalization of "i" in Turkish. Fixed by not using the locale
dependent toupper/tolower functions.
2011-05-26 09:58:22 +00:00
686859afad Use proper checking for image source 2011-05-26 09:46:51 +00:00
26252bb315 correct spelling error and some pep8 changes. 2011-05-26 09:33:51 +00:00
Dalai Felinto
ea19f15400 BUGFIX: Sequencer strips.elements was broken when strip was trimmed (personal bug report, no number)
When trimmed the seq->len was being reduced from the offsets (initial and final). This was the length passed to the elements.
This had two problems:
1) it would not allow you to change the elements not visible (although you likely want to change them as well).
2) the element[0] was always the seq->strips[0].stripdata[0], regardless of the initial trim.

Anyhoo it's all working now.
Thanks Campbell for helping out with this one.
2011-05-26 09:20:30 +00:00
6466673a62 move less common mesh operations out of bpy_types into bpy_extras.mesh_utils 2011-05-26 07:16:56 +00:00
9af390ab67 fix [#27485] Create new shapekey on lattice 2011-05-26 06:34:31 +00:00
dec09f2a3b fix for mistake in selecting vertex groups (own recent commit) 2011-05-26 05:40:00 +00:00
9a556fd69b fcurve/boolean evaluation, values below zero are no longer evaluated to true. 2011-05-26 05:35:30 +00:00
433cc15527 Code Cleanup in DocumentExporter.cpp. (Test Commit) 2011-05-25 17:14:31 +00:00
80e2f6c68c Swapped hotkey for setting interpolation from Shift-T to TKEY, since
this is more commonly used that the TimeSlide tool (which is DopeSheet
only).

Noticed that this does bring this out of line with the hotkey for
setting extrapolation, but then again, extrapolation is a per-curve
setting.
2011-05-25 13:10:07 +00:00
1f1481841d fix [#27478] Crash on image editor after loading exr images
patch from Ryakiotakis Antonis (psy-fi) with minor change.
2011-05-25 11:06:30 +00:00
655fcfbcc0 First commit of mocap_tools.py, contains functions for Fcurve simplification and loop detection of anims 2011-05-25 10:42:57 +00:00
49ad7345af fix [#27479] Missing 'Select vertex groups under the cursor' in weight paint mode
really todo :) but still needs to be done.

Split this into 2 operators, works like 2.4x
- Ctrl+LMB samples weight.
- Shift+LMB selects vertex groups.
2011-05-25 10:07:59 +00:00
3cfa9a2163 cmake's install target now works for the python module on *nix. 2011-05-24 18:34:07 +00:00
9f1a021068 remove some warnings and possible use of un-initialized vars. 2011-05-24 17:25:11 +00:00
15289c6048 use PyDoc_STRVAR macro, so its possible to build without docstrings. 2011-05-24 16:05:51 +00:00
357ce16958 loading data with bpy.data.libraries.load(), now swaps out the strings in the list to load with the actual datablocks, this is convenient because it saves the script author having to find them after.
also raise warnings rather then errors if the datablock can't be found.
2011-05-24 15:21:14 +00:00
a8cb91e64a BLO_library_append_named_part now returns the newly linked/appended datablock. 2011-05-24 15:02:46 +00:00
6a4a8854b5 lookup table for axis conversion was wrong in some places. 2011-05-24 12:55:29 +00:00
435229e3b3 Bugfix [#27453] Copy Paste fcurve modifers is broken
Wrong poll was getting used
2011-05-24 12:24:05 +00:00
f920df3ce7 Bugfix: Limit Distance constraint could be doing divide-by-zero in a
few cases, especially if the object and target are at the same
location when the constraint is created.

This manisfested as the constrained object disappearing when the
constraint was added, only reappearing after transforming it a bit.
2011-05-24 12:20:02 +00:00
1788bc298c = Limit Distance Constraint - 'For Transform' Option =
The Limit Distance Constraint now has a "For Transform" option just
like all the other Limit constraints. This option controls whether the
constraint gets applied to interactive transforms in the 3D View too,
preventing controllers from getting large values without the animator
knowing.


Additional code changes:
* Split code to get constraint targets and grab their matrices for
solving out to a separate helper function:
get_constraint_targets_for_solving()
* Fixed a bug where "found constraint ...." prints would appear in the
console. Looks like some warning print that was forgotten

TODO:
* While coding this, I noticed potential division by zero bugs with
the Limit Distance constraint. Looking into these after this commit.
2011-05-24 12:12:12 +00:00
Nathan Letwory
a751c48b5f clamp delta to prevent cases where strength is a huge number. Very high values would lead to scale problems of objects. 2011-05-24 11:20:33 +00:00
4ac88bd16f Fix for mingw 64bit fix. 2011-05-24 11:19:11 +00:00
a5b07c0934 == Animated Transforms to Deltas ==
Added operator to convert animation for standard object transforms
(i.e. loc/rot/scale) to delta transforms.
This can be accessed from the Object -> Transform -> Animated
Transforms To Deltas menu entry in the 3D View.

Since the situation which causes this is quite common (especially for
motion-graphics type applications), where users animate some object
first and then decide to duplicate this and place it around the place
in different locations, it's probably important that we have some
support for this kind of thing. Newbies with the "help, all my anmated
duplicates disappear" problem are recommended to use this operator
from hereon in.

For reference of rationale, see:
http://blenderartists.org/forum/showthread.php?219126-Move-Existing-f
-Curve-to-delta-equivalent
2011-05-24 11:15:21 +00:00
3e62e518ec Attempt to fix mingw 64 bit compile error. 2011-05-24 11:01:39 +00:00
3ccbfef6be == Paste Poses ==
"On Selected Only" option is now on by default. Stored poses only get
pasted on to bones that are selected when pasting, instead of on the
bones that were selected when copying.

(First GSoC11 commit. Yay!)
2011-05-24 10:15:02 +00:00
4a989282d4 bpy_extras.io_utils.axis_conversion() was returning wrong matrix. 2011-05-24 08:11:51 +00:00
017fa2c19f BGE Animations:
* Adding a BL_Action and a BL_ActionManager
  * Each KX_GameObject has a BL_ActionManager, which can control up to for BL_Action objects at a given time
  * Currently, the only interface to BL_ActionManager is through KX_GameObject via Python
  * Only armature animations are currently supported
2011-05-24 07:52:29 +00:00
2ccdcca7f5 fix for option WITH_CXX_GUARDEDALLOC with msvc 2011-05-24 06:44:39 +00:00
e1a7ecb5ae fix for using uninitialized vars in own recent commit. 2011-05-24 05:22:58 +00:00
dc33976fc2 fix for cmake/msvc when the path name contains spaces, patch by Kupoman on IRC 2011-05-24 05:21:51 +00:00
1e00590f1c Fix #26728: crash with load/save on Mac, on files that close & open a window
when loading them. Custom cursor shown during load was not freed correctly
when closing the old window, which resulted in unpredictable crashes later on.
2011-05-23 15:56:26 +00:00
6357b12641 fix [#27462] Linked Object (camera) can be moved by Lock Camera to View 2011-05-23 15:46:09 +00:00
d0e4f7b9f2 remove unused code, comment some that may be useful (maintainers can remove). 2011-05-23 15:23:31 +00:00
b69c1e8f1a CMake changes
- don't allow building if the LIBDIR is not found on mac/windows.
- by default use -O2 rather then -O3 for GCC release flags, was crashing some GCC versions and blender releases are supposed to use -O2.
2011-05-23 14:56:14 +00:00
9296060082 Fix print_rctf not printing y max correct. 2011-05-23 14:51:31 +00:00
c6881d08e5 Creating GSoC 2011 pepper branch. 2011-05-23 13:20:13 +00:00
3d5ba20f66 fix [#26618] StringProperty with sub_type of FILE_PATH not updated correctly from icon 2011-05-23 10:14:07 +00:00
f5ec4cf4e9 fix own mistake [#27451] Flip to Top / Flip to Bottom menuitems on right click on header not working
also get rig of more shadowed vars (-Wshadow).
2011-05-23 08:14:29 +00:00
af49b5f6c9 own recent commit broke zoom to mouseloc 2011-05-23 02:59:29 +00:00
b222863336 fix [#27459] Flymode moves parent
for durian we had camera rigs which needed to have the parent transformed rather then the camera, for this reason I made fly mode fly the parent rather then the camera its self.

Make this a preference and use this for view camera/view locking too.
2011-05-23 02:53:30 +00:00
0d26333eb5 fix view3d_persp_mat4, which gave incorrect translation, rename to ED_view3d_to_m4. added doxygen docs. 2011-05-23 02:23:03 +00:00
bf65ed9447 fix [#27443] "Make single user Material+Tex" doesn't work for textures 2011-05-22 17:10:24 +00:00
d02480cdaa remove / comment unused code, patch by nico_ga on IRC with some edits. 2011-05-22 16:29:51 +00:00
04e157304a - view dolly now quits on pressing escape (if activated from the search menu).
- adding new bones now makes them active.
2011-05-22 11:36:56 +00:00
b07bdf367c file had non utf8 characters. 2011-05-22 05:36:11 +00:00
6e39d908a9 quiet compiler warnings for -Wundef 2011-05-22 04:25:31 +00:00
b1ddf90239 fix [#27458] Links for Logic Bricks no longer work
event->mval wasn't being set in some cases by the event system.
2011-05-22 04:05:09 +00:00
6727ed1ca4 correct a tooltip misspell 2011-05-21 23:44:36 +00:00
e038b25579 view3d function naming, no functional changes. 2011-05-21 08:56:37 +00:00
b1025f2a30 fix [#27437] Appending armatures with custom bone shapes brings no custom objects into scene.. impossible to edit
previous fix unintentionally made linking groups also add objects to the scene,
tested this more throughly, its ensured only to run on append and not to conflict with group linking/appending.
2011-05-21 07:15:36 +00:00
6c4cd8d9f3 no functional changes, make give_base_to_objects() arguments less confusing. 2011-05-21 06:48:19 +00:00
1890b7f431 Bugfix [#27452] Wrong linking of character groups
Linking in groups also ended up adding those objects to the current
scene that we're linking the group in to. This is a regression. It
leads to more work (and/or confusion) from animators when just trying
to get a character into a shot file to start animating it (see my
notes on my blog for the proper workflow regarding this).

Reverting r36762, which caused this mess.
2011-05-21 06:04:44 +00:00
4c37fe91f3 patch [#27449] bpy_script_paths() return path reversed [patch]
from Dan Eicher (dna)
2011-05-21 05:34:20 +00:00
2aa9c000ed Fix for [#27333] Translation constraint is broken.
Committing here a patch by Bastien Montagne (mont29), a more understandable Translation Constraint UI. 
Before: http://www.pasteall.org/pic/12578
Now http://www.pasteall.org/pic/12258

From the description: 
"When you set “X” under the Destination’s “Z”, it does not mean that the Z transform of the source should affect the X transform of the destination, but rather that the X transform of the source should affect the Z transform of the destination…"

The new UI should make it a bit more clear.
2011-05-20 18:26:44 +00:00
d16da799fb change transform to round at 0.5 for fcurves.
this gave noticeable issue when transforming int/fcurve's below zero.
2011-05-20 18:19:29 +00:00
9563743f4e was using the wrong rna type for GRAPH_OT_select_leftright 2011-05-20 18:00:19 +00:00
8d8e42a451 2.5 Particle UI:
*In Particle Mode, there was no way to see what p-sys is being edited in the 3D View Tool bar, when having multiple ones. 
Changed List type to normal (with limit to 3 rows). Request by venomgfx. :)

* Removed redundant text info about disconnected hair from Particle UI.
2011-05-20 17:08:09 +00:00
259582235c error in recent commit. 2011-05-20 16:43:23 +00:00
b100f9d79d edit gp_stroke_convertcoords not to modify the mval passed to it & make some mval args const elsewhere too. 2011-05-20 14:11:05 +00:00
363bfdc46a use consistant arguments to ED_view3d_win_* funcs, a single float vector rather then 2 floats. 2011-05-20 13:50:41 +00:00
a8ef6ffd17 typo in previous commit 2011-05-20 13:10:40 +00:00
53d5761c94 function rename to give clearer meaning that they change from window to 3d coordinates.
some functions had vague names, I even ended up re-writing some of these functions by accident!
also added doxy comments.

* ED_view3d_win_to_3d (was window_to_3d)
* ED_view3d_win_to_delta (was window_to_3d_delta)
* ED_view3d_win_to_vector (was window_to_3d_vector / viewvector)
* ED_view3d_win_to_segment_clip (was viewline)
* ED_view3d_win_to_ray (was viewray)
2011-05-20 13:09:34 +00:00
e721d31b5d buildbot:
ffmpeg was compuled with faad now (aac support which keeps
libs gpl2 compatibile).
Updating library dependencies for buildbot rules.
2011-05-20 13:06:19 +00:00
c833fff638 replace checks with rv3d->persp with rv3d->is_persp since in these cases it only matters if its a perspective view matrix, this wouldn't work right for camera views. 2011-05-20 11:15:44 +00:00
4916c44af8 simplify window_to_3d_vector() and call it from viewline()
also update python view function to match.
2011-05-20 10:28:40 +00:00
2999d0fad9 rename mul_project_m4_v4 to mul_project_m4_v3. 2011-05-20 10:09:03 +00:00
Nathan Letwory
3ddaaa3784 Remedy compile error on windows/msvc introduced in r36787. 2011-05-20 08:52:52 +00:00
9f766c71b0 use event->mval rather then subtracting ar->winrct.x / y from event->x / y 2011-05-20 07:40:05 +00:00
2338765726 renaming bones didnt update update the view3d lock bone name. 2011-05-20 05:39:56 +00:00
170716ca53 use BKE_area_find_region_type in place of inline loops (no functional changes). 2011-05-20 05:27:31 +00:00
984d2e42e4 make api functions for converting rv3d->camzoom, so the odd logic for this isn't inlined all over. 2011-05-20 04:14:29 +00:00
c07012b41e int values were not drawing curve handles, yet the handles could still be selected and transformed, and different handle types set. disable this check and draw curve handles for int fcurves. 2011-05-20 01:02:00 +00:00
c672b3fb67 [#27439] Console window doesn't hide on startup when presets are used (Windows)
only print preset load messages in when debug is enabled.
2011-05-20 00:21:38 +00:00
b181368f52 SVN maintenance. 2011-05-19 20:22:35 +00:00
2f4813500c - mousewheel zoom now zooms camera area when the camera is locked and in ortho view.
- remove secret apricot feature now dolly is its own operator.
2011-05-19 17:19:05 +00:00
0942e62bc4 move rna property area.active_space --> area.spaces.active 2011-05-19 15:18:40 +00:00
79e7a89c38 formatting changes only. 2011-05-19 13:50:53 +00:00
fbe541d1a8 modify fcurve evaluation for bool/enum/int values. was converting from a float to an int which means 0.9x evaluates to 0.0, negative numbers are also rounded up.
Round at 0.5 instead & treat negative numbers the same.
2011-05-19 12:39:57 +00:00
e088f592bd Fix some compile warnings. 2011-05-19 11:54:03 +00:00
417b7836ec UI tweak: properties editor header now has same size as other headers again. 2011-05-19 11:45:06 +00:00
525f4e226e Fix for preview render, lamp and world now also get localized like material and texture. 2011-05-19 11:37:08 +00:00
54b97c1d9d Code refactor: split code for render updates and opening render view into
separate files, no functional changes.
2011-05-19 11:34:11 +00:00
ae0c552bd1 Fix crash when accessing mesh from python while a mesh with a subsurf modifier
is in editmode.
2011-05-19 11:24:56 +00:00
3aaa03e1f8 Add localize_lamp and localize_world functions as already existed for materials
and textures, unused still.
2011-05-19 11:21:37 +00:00
4c28693ae3 UI: fix direction properties not showing the right direction editing widget,
code was there but in the wrong location. This makes the opengl lights in
the user preferences show that widget again as in 2.4.
2011-05-19 11:18:09 +00:00
7603c8a2fb screenshot operator can now be executed directly.
so python can screenshot with: bpy.ops.screen.screenshot(filepath="some_image.png"):
2011-05-19 11:13:35 +00:00
d77b9af609 UI: fix menus getting closed too quick when moving mouse not exactly towards
them, noticeable for the vertex groups or material slot utility menus.
2011-05-19 11:05:34 +00:00
fbdd33f62d py/ui edit: change InputKeyMapPanel to be a mix-in class only (not a subclass of Panel), it messes up re-registering panels. 2011-05-19 09:52:11 +00:00
1dad9bf0bc change window_to_3d to take screen coords as floats. 2011-05-19 07:55:48 +00:00
31d3e8d214 converting grease pencil now works in the camera view. 2011-05-19 07:43:10 +00:00
863b60e1b8 fix [#27432] [2.57/scripts/modules/bpy/path.py:169] can't concat bytes to str 2011-05-19 06:27:39 +00:00
1ce0958369 fix [#27437] Appending armatures with custom bone shapes brings no custom objects into scene.. impossible to edit 2011-05-19 06:17:44 +00:00
32793a1395 add python access to mathutils.intersect_line_plane, update view3d_utils module to use it. 2011-05-19 04:28:09 +00:00
391dbde03d added math function isect_line_plane_v3(), use for window_to_3d rather then having it inline. 2011-05-19 03:49:57 +00:00
c04f9b779c fix [#27158] Appending crash with preview.
* fixed incorrect reading of PreviewImage struct from .blend 
* fixed memory leak, PreviewImage data wasn't correctly free'd
2011-05-18 19:42:30 +00:00
91bd739a09 use window_to_3d for armature_click_extrude operator. 2011-05-18 18:14:59 +00:00
7282f8cf98 window_to_3d() wasn't working at all (only used by grease pencil/path conversion), now works in ortho and perspective view, initgrabz() is no longer needs to be called first. 2011-05-18 18:01:01 +00:00
f4d8be977f there wasn't a good way to know if a RegionView3D was perspective or not (without having the View3D too and checking its camera values), added struct member 'is_persp', set with the view matrix. 2011-05-18 17:52:26 +00:00
0c41635f85 fix for python module region_2d_to_vector_3d and region_2d_to_location_3d functions in ortho mode. 2011-05-18 15:57:20 +00:00
6266e62170 python mathutils.Matrix.is_orthogonal readonly attribute. 2011-05-18 15:31:00 +00:00
d2b0954b2a UI: fix access of freed memory in buttons handling code. 2011-05-18 15:23:40 +00:00
a6fe2f1e18 RNA: some compile fixes for C/C++ api. 2011-05-18 12:56:58 +00:00
66f51ba5d1 RNA: make mechanism used by operators to keep python instance alive more generic, to be used by render engine later. 2011-05-18 11:21:10 +00:00
178ba76b09 RNA: pass Main rather than Context to register/unregister callbacks. 2011-05-18 10:56:26 +00:00
304ce06a5a fix remaining crash from [#27035] 3 problems: crash and enum "REGION" not found in ('VERTS') 2011-05-18 09:58:17 +00:00
0454c817ef fix a crash when getting the value of an enum. 2011-05-18 09:26:07 +00:00
ebe47add08 fix for one of the issues in [#27035] 3 problems: crash and enum "REGION" not found in ('VERTS')
now constraint macro argument shows as 'NORMAL' rather then '<UNKNOWN ENUM>'
2011-05-18 09:07:15 +00:00
5f32094bce use ED_operator_screenactive rather then ED_operator_screenactive so transform works in background mode. 2011-05-18 08:36:06 +00:00
2fe3840780 2 minor glitches
- removing bone groups didnt set the next one active.
- removing poselib was using int for enum rna property.
2011-05-18 08:16:33 +00:00
7e6520c080 additional bake modes
(refined patch #23430)

+ specular color
+ specular intensity
+ mirror color
+ mirror intensity
+ alpha (tranparency)
+ emission (glow)
2011-05-18 07:46:54 +00:00
c92c3758a8 - check paths are not empty strings before making blend file paths absolute or relative.
- when saving blend file with 'Remap Relative' enabled, don't try make paths absolute if the internal filename is invalid.
- use case insensitive path comparison on windows when checking if path remapping is needed & for comparing next/prev dirs in the file selector.
2011-05-18 06:48:52 +00:00
37178ab0fd cleanup only
- rename 'name', 'dir' --> 'filepath' where these actually represent a file path to avoid confusion.
- bugfix for possible (but unlikely) uninitialized string.
- remove commented script append function, now we have a python api for this.
2011-05-18 06:27:32 +00:00
edb9045824 fix [#27405] Append objects with linked materials they dissapears after save
when linking in files to an unsaved blend file, make all library paths absolute.
2011-05-18 05:21:44 +00:00
dc50003824 This fixes:
[#27422] Strobe setting does not work with effect strip
[#27421] Some Settings of Adjustment Layers are not Functional.
2011-05-17 18:37:44 +00:00
Nathan Letwory
2eed2a7f58 fix for r36723 - putting extern Material inside code like that results in wrong linking. Move to proper place so that linking goes right. 2011-05-17 16:20:07 +00:00
3929753794 added other addon category. 2011-05-17 09:13:14 +00:00
1294504603 fix for warning 2011-05-17 06:51:31 +00:00
0858904571 fix [#27414] no-material renders differently in View3D vs BGE
when a texface layer exists this still overrides the default material.
2011-05-17 02:44:52 +00:00
c4dca3890b RNA glitch: particle path step values had soft & hard limits the wrong way around. 2011-05-16 20:48:14 +00:00
079caae727 code cleanup: icon creation
* changed stupid miplevel/MIPMAP naming in icon code, it was really the icon size (small icon or larger preview) that was meant there.
2011-05-16 18:37:54 +00:00
4023427fe0 set clip_start value minimum to 0.001, since 0.0 makes the viewport go very strange. 2011-05-16 18:04:19 +00:00
ff884f4179 == Sequencer ==
This fixes one part of [#27353] VSE crashes on large M4V

StripData was alloced in full length for MOVIE and SOUND-tracks, which only
use the first element for filename storage. (StripData as an array is only
used in IMAGE strips).

Fixed the crash and documented accordingly.
2011-05-16 17:54:55 +00:00
70b832589a [PATCH] == Sequencer ==
This patch adds adjustment layer tracks to the sequencer and does some cleaning
up of the code.

What's an adjustment layer?

Think of it as an effect track, which takes no explicit input, but alters
the output of everything down the layer stack.

So: you can add several stages of color correction with it.

And: you can even use it with metastrips to group several adjustments together.
2011-05-16 17:14:47 +00:00
b434e7f933 LCMS code removed, was an experiment but never finished. 2011-05-16 13:34:42 +00:00
Nathan Letwory
37e95c525d Remove artificial limit, now HDR textures can be used to displace. 2011-05-16 11:46:16 +00:00
5cfc13a11d fixed incorrect jemalloc library & updated netbeans project to ignore __pycache__. 2011-05-16 10:34:40 +00:00
68dbfe6ac9 move generic bpy helper modules into bpy_extras. 2011-05-16 07:51:02 +00:00
6c8317ae8f new empty package to move bpy utility modules into. 2011-05-16 07:48:43 +00:00
9b236a7a12 SVN maintenance. 2011-05-16 06:11:14 +00:00
617d69a627 rename wave texture_coordinate_object -> texture_coords_object to match Displace and Warp modifiers. 2011-05-16 05:50:04 +00:00
80c2582f0e enable game panel even if the BGE is disabled since its settings effect the viewport.
also remove unused function in creator.c and minor edit to search menu poll function.
2011-05-16 04:55:31 +00:00
0460a68ae7 made generic module for generating project files from cmake,
added netbeans project file generator.
2011-05-16 04:04:06 +00:00
7459133648 Patch [#27344] 300+ New/changed tooltips by Davis Sorenson (dsavi). Thanks a lot!
Reviewed by Tom Musgrove and myself. 

From the patch description:
ValterVB on #blendercoders submitted a long list of missing tooltips in Blender, and I went through the list and added all I knew. After that I crowdsourced the rest by putting a spreadsheet on Google docs and having people fill in the missing ones that I didn't know. So if there's some weird tooltip in there that doesn't make sense, that's why.

Thanks to Wolter, spacetug and others on BlenderArtists for contributing tooltips.
2011-05-15 17:59:48 +00:00
f60528687f Fix for [#27142] manipulator in particle mode does not work
* Manipulator operator wasn't registered in particle mode.
2011-05-15 16:42:39 +00:00
b0ced3ef83 Fix for [#27131] particle system BUG - one particle generated twice at vertex (e.g. 9 particles generated at 8 locations)
* The tiny offset value used in particle distribution code was actually too small, so that floating point errors got the best of the calculations.
2011-05-15 15:51:17 +00:00
ca3b61f578 homekey in camera view now fits the view scale as well as centering the camera. 2011-05-15 14:07:24 +00:00
19eb07c63d Do not remove MDISPS customdata layer when removing multires modifier
and there are still another multires modifiers in the stack.

Helps to prevent loosing sculpt data when you occasionally added another
multires and reomved it with "X" button.
2011-05-15 13:13:51 +00:00
d05b26c635 BGE:
This fixes frame colors not showing up right when using letterbox in the embedded player. Frames are drawn by clearing the whole canvas and then changing the viewport to be within the frames. The problem is that the embedded player's canvas is setup to be within the frames. This means that the extra that would normally be cleared and filled with the frame color is instead the gray color of Blender's region since nothing is actually drawn there by the BGE. To solve this, I just handle the frames in BL_KetsjiEmbedStart.
2011-05-15 08:48:43 +00:00
6744123881 remove redundant (and confusing) register flag. 2011-05-15 06:29:52 +00:00
b8be69c568 camera composition guides:
removed diagonal golden rule (not very common), added harmonious triangle and golden triangle options.
2011-05-15 05:43:59 +00:00
99b7960781 remove some unused view3d members & added RV3D_VIEW_USER define.
Aligorith: replaced v3d->keyflags with ANIMFILTER_KEYS_LOCAL since v3d->keyflags couldn't be set anywhere and wasn't initialized.
2011-05-15 03:42:28 +00:00
36bec40fbc fix for bug with camera locking, view dolly and rotate with 'about selection' preference enabled would offset the camera. 2011-05-15 03:07:07 +00:00
baa64d1751 fix for user reported issues
- camera object movement was missing a notifier
- auto perspective now works when rotating the view.
- shift+b now zooms.
2011-05-15 02:39:36 +00:00
7e5ff01f4a Button for adding shape keys now creates shapes from base mesh instead of
from the current shape mix.  The old behavior is still accessable from the
menu as "New Shape From Mix".

Checked with Sergey and Bassam that this is a good change.  New users
expect the add shape button to simply add a new blank shape, and get
confused when that is not the case.  It is also really easy to
accidentally have other shape information in a new shape when the
"from mix" behavior is default.
2011-05-14 20:23:05 +00:00
Nathan Letwory
12fecba3ae Remove files that were intended for shader branch. 2011-05-14 18:54:56 +00:00
e7db080565 option to have the view controls apply to the camera view (and camera object).
- follow rotate/pan/zoom/dolly operators.
- auto-depth preference works.
- smooth view navigation supported.
- view selected, all & numpad operator work too.

TODO
- deal with camera transform locked axis
- find a way to move/zoom the frame while the camera is locked (if it turns out to be a problem).
2011-05-14 17:50:33 +00:00
93bc463f6d action editor was setting wrong rna type on Ctrl+RMB 2011-05-14 15:44:56 +00:00
da7f700749 Fix #27390: Shift for activating Smooth Brush broken in sculpt
Smooth brushes at requires face map which haven't used to be created for
simple meshes (without modifiers).

Use corrected need_fmap flag at stroke initialization, so face map
is created properly for "temporary" smooth brushes and simple meshes.
2011-05-14 12:32:15 +00:00
28608b9281 fix for view dolly not working with auto-depth & zoom to mouse location when no depth was found. 2011-05-14 10:35:11 +00:00
99113b8541 These two files didn't get added when I created a branch from my working copy. 2011-05-14 06:32:25 +00:00
d25be80320 stubs.c update: ED_view3d_from_m4() 2011-05-14 06:24:29 +00:00
c213b9525f minor changes to view3d operators, add View3D to 'ViewOpsData' 2011-05-14 05:42:58 +00:00
054eb2897c object_mat3_to_rot wasn't correctly accounting for the euler delta rotations, so setting the matrix of an object would fail in this case (rotational jump). 2011-05-14 04:59:37 +00:00
4b7d981c91 view3d api edits, no functional changes.
rename v3d functions
* view3d_to_ob -> ED_view3d_to_object
* view3d_apply_ob -> ED_view3d_from_object
* view3d_apply_mat4 -> ED_view3d_from_m4

Changed ED_view3d_to_object() not to temp modify the view rotation and don't overwrite the objects recalc.
2011-05-14 04:25:47 +00:00
daa3dd0e9b using the viewmatrix to position the camera could be problematic if the view wasn't yet recalculated, use the quaternion instead. 2011-05-13 18:32:27 +00:00
47569160d7 rename setcameratoview3d to view3d_to_ob & add to ED_view3d.h so others can use. 2011-05-13 18:05:30 +00:00
62cd927f57 made BLI_edgefill returns the list length since some callers count directly after, also remove 2 unused flags from ScFillVert struct. 2011-05-13 16:04:20 +00:00
05d004fd14 support for reading/writing image resolution (dpi), for PNG and TIFF,
only RNA access currently 'image.resolution'.
2011-05-13 14:27:12 +00:00
6786f92fe5 Use jemalloc in buildbot for linux targets 2011-05-13 12:57:54 +00:00
8941cc626a Option to use jemalloc when building with scons under linux.
Disabled by default.
2011-05-13 12:08:34 +00:00
91bddf2b13 remove imbuf crect and profile_filename when building without LCMS 2011-05-13 04:53:20 +00:00
b73fe01295 * Enabled rna access to fluid sim velocity vectors
The main purpose for this is to allow rendering motion blurred blender fluids in external renderers (eg. http://vimeo.com/21870635 ).

Python code snippet for interpreting this data here: http://www.pasteall.org/21577 . Cleaned up some ugly hacks in this area too

* Also added read-only access to scene.subframe to RNA - setting current frame and subframe should still go via scene.frame_set()
2011-05-12 22:52:30 +00:00
57c626d11c Forgot to close clipboard when lock fails.
Thanks to jesterKing!
2011-05-12 18:04:24 +00:00
1d6278f80a Fix #27359: Pasting long text crashes blender
Actual problem was caused by insufficient buffer size
in ui_text_leftclip()

Also fixed possible invalid memory write in GHOST_SystemWin32::getClipboard
which was caused by accessing clipboard buffer after closing
clipboard. This mustn't happen.
Also fixed possible crush when buffer was failed to be locked.
2011-05-12 16:49:53 +00:00
5f5cdf9d00 for bug [#27358] Transform bug when transform > 500
mouse coords would with cont. grab would wrap at short.
use mouse coords as int rather then short.

this problem still happens on linux because of XTranslateCoordinates
2011-05-12 16:47:36 +00:00
2ca7ded51d Bugfix #27181
2D view panning and zooming is now fully keymappable, you can set a
keyboard key to it too (hold key -> move mouse -> release key).
2011-05-12 13:49:47 +00:00
424a0cca27 option to link with jemalloc on *nix, off by default. 2011-05-12 11:16:32 +00:00
754c134e09 Fix #27279: IK bone rotation limits set to 0 disabled the limit, this was
unintentional, since there is already a toggle to enable/disable it.
2011-05-12 08:34:31 +00:00
2f08309ffe window_to_3d_vector was incorrect but dolly view operator was accounting for it. fixed so result isnt negated and mouse coords dont need to be adjusted. 2011-05-12 06:52:24 +00:00
a131ce066a python utility module for converting between 2d/3d region/world coordinates. 2011-05-12 06:32:21 +00:00
910220be47 == Radial control ==
Patch to make the radial control more generic with RNA. Patch was
reviewed here: http://codereview.appspot.com/4280080/

Prior to this update, the radial control code in trunk had generic
parts of the radial control implemented as an incomplete operator
within WM. Then each different user of the radial control had to
implement a separate operator to actually pass in specific brush data
-- e.g. sculpt's brush size, vpaint's brush size, etc.

This patch removes all the extra operators and makes the WM operator
do everything. It now takes several RNA path strings as its properties
-- the only required property is data_path, which specifies the data
to be modified by the radial control. The other paths affect display
in various ways, e.g. rotation, color, etc.

In addition to decreasing some duplicate paint brush code, these
updates make it pretty easy to enable radial control for other
purposes (and it can be set up entirely though python or keymaps, no
extra C code needed.)
2011-05-12 01:57:47 +00:00
040f65f6c2 2.5 Smoke UI:
* More generic tooltip for "strength" property as it can be FFT as well. 
Discovered by tobkum in IRC. :)
2011-05-11 20:23:55 +00:00
3a34dcde68 Code cleanup: remove readblenfile module, only contained some utility functions
to read .blend files from runtimes, folded those into blenloader.
2011-05-11 19:29:23 +00:00
fcc85eea12 recent camera border drawing glitch fix needs to be applied to the top right sides too. 2011-05-11 09:42:46 +00:00
a3ab7c01bb fix for glitch with drawing the 2d camera border over the 3d camera.
seems arbitrary and may be driver specific, but this value is in the middle of what works well on mesa software GL & my nvidia.
2011-05-11 00:59:22 +00:00
Nathan Letwory
56c5d71f1c Apply patch from Ryakiotakis Antonis as posted on ML
Should fix MingW build problems - mingw users, please test too :)
2011-05-10 23:54:15 +00:00
Nathan Letwory
fab1ee1f78 MingW apparently doesn't know about RIM_INPUTSINK, define it if it isn't already. 2011-05-10 23:38:40 +00:00
2e3538cf24 patch from Dan Eicher for cpack rpms 2011-05-10 21:59:11 +00:00
0c990fba6e Bugfix #27305
RGB color node supports to set alpha too but never put alpha in the output.
Report + fix provided by Dani G. Thanks!
2011-05-10 16:30:03 +00:00
f1f1dde1c8 Bugfix #27311
Physics Gravity property now has UI range of 0-25, but real range goes
to 10000 to allow scaled scenes.
2011-05-10 15:13:03 +00:00
89a166d0de remove some duplicate declarations 2011-05-10 14:48:06 +00:00
1d53ea0a65 Fix #27217: Bézier control points moves bizarre
Re-calculate handles after applying transform matrix on curve object

This commit is'n fixing changing of curve shape whe nyou're deforming it (as
it was intially reported) but just adds needed handles recalculation.

Handles are calculated correct in that "unneded deformed" curve.
2011-05-10 14:38:55 +00:00
eabb444106 minor cleanup: make functions static, use NULL for pointer comparisons,
also fixed a possible bug assigning incorrect DPX function types to
imbuf.
2011-05-10 13:11:36 +00:00
6d5f0bfac6 Typo in composition guides 2011-05-10 05:20:18 +00:00
2a14b0b327 entering non utf8 text in filepaths in the file selector would get incorrectly stripped. 2011-05-10 05:07:24 +00:00
2889f5ae2c camera composition guides: center, thirds, golden rule 2011-05-10 03:03:53 +00:00
Nathan Letwory
14c3714b81 Revert rename of r36578, breaks scons compile. 2011-05-09 21:34:52 +00:00
d143eca2fc Fix #27346: When The FONT object is blank, the dimensions are calculated wong.
This commit fixes boundbox for empty curve-typed objects. Because of strange
reason (-1,-1,-1) and (1,1,1) was used as boundbox. Now it uses zero-sized
boundbox (as it's done for meshes).

This commit makes nothig with that single space character text from the report.
2011-05-09 20:14:34 +00:00
c87b5f8dfb SVN maintenance. 2011-05-09 20:13:48 +00:00
885141c9de patch [#21740] Image support for Empty Objects
from Andy Braham (andybraham)

This adds support for empties to reference images and draw in the 3D view.

Modifications from the original patch.
- use an empty draw 'image' type
- use image aspect ratio for non-square-pixels
- when the image is not found, still draw the frame.
2011-05-09 16:31:54 +00:00
1e0c3d315b minor cleanup, no functional changes. 2011-05-09 14:41:44 +00:00
18e9d9c3e2 Recreate mipmaps after undo in image editor 2011-05-09 13:13:16 +00:00
88a13d7395 fixed scrolling lists with the mousewheel for some X11 windowmanagers.
some WMs not only send 'crossing' events when really moving from one
window to another, but also when mousewheeling.
distinguishing those events 'mode' property fixed this.

brecht++ for figuring out the details.
2011-05-09 12:46:59 +00:00
99ee18c684 Fix for memory leak caused by re-making mipmaps
Problem was caused by different limits for "last" mipmap: it was 1x1
for mkaing mipmaps and 2x2 for re-making.

2x2 should be enough for mipmap.
2011-05-09 10:03:06 +00:00
4c71d9efb5 set svn end of lines to native 2011-05-09 08:15:38 +00:00
763adbc7b9 Code cleanup: warning fixes. 2011-05-09 08:01:48 +00:00
30155e958b Code cleanup: remove unused image window code, already implemented elsewhere. 2011-05-09 07:54:21 +00:00
f8f4f73cc5 Bug fix own collection:
- Recreate mipmaps if they're dirty when drawing background image
   (this prevents "delayed" update of background image when you're paiting on it
    in image editor).
 - Mark mipmaps as dirty when inverting image channels.

TODO: there's memory leak caused by IMB_remakemipmap, but it'll be
      anuther bugfix commit after discussion with other devs.
2011-05-08 20:21:31 +00:00
b432520799 fix [#27324] WindowManager.invoke_search_popup() crashes blender and does not work
also minor formatting fixes.
2011-05-08 12:51:05 +00:00
d4e540dff3 comment some unused code. 2011-05-08 10:29:40 +00:00
Nathan Letwory
ed3fd72210 Apply second half of [#21590] .dds textures: fix for DXT1n format + sync with upstream nvtt
submitted by Amorilia

This updates the DDS module with upstearm nvtt (r1042).
2011-05-08 09:05:52 +00:00
aaa93c58b3 Fixes for bugs noticed during previous fix:
- In Drivers mode of Graph Editor, expanders for sub-object data were
not working at all. This was because they were getting overriden by an
errant ob-level drivers check
- Adding drivers from py-api didn't update Graph Editor
2011-05-08 05:41:57 +00:00
85b1b459ed RNA Bugfix:
The following script would fail:
#ob = bpy.context.active_object
pb = bpy.context.active_pose_bone
pb.bone.driver_add("hide")  # <--- exception here

The RNA-path function for Bone assumed that when it got called, it's
"id_data" (or owner-idblock-pointer) would only be ID_AR (i.e. an
armature). However, in the above example, pb.bone has ob as its
id_data, resulting in an invalid RNA path getting created. Added check
for this case, since it's likely to be common
2011-05-08 05:18:40 +00:00
2aea765d6e Committing patch [#27133] "Fix for for Object Color in BGE" by Kupoman
The tracker description:
"This patch fixes this bug:
http://projects.blender.org/tracker/index.php?func=detail&aid=25487&group_id=9&atid=306

This was accomplished by making sure the KX_GameObject's object color gets set during the conversion process in the method gameobject_from_blenderobject. Otherwise all the values for object color default to 0. The reason adding an IPO worked as a work around is because it set the object color."

The bug report mentioned is bug [#25487] "BGE: Object Color only works when it has a keyed frame"
2011-05-08 03:42:24 +00:00
Dalai Felinto
0b03268c17 Patch [#26799] embedded blenderplayer not receiving keyboard input by Sebastian Korczak
(patch co-reviewed by Nathan Letwory)

Overview: GHOST using rawinput for keyboard input. GHOST window receives WM_INPUT only when it is the active window. Child window cannot be active, so when embedding blenderplayer, WM_INPUT is consumed by top level parent window (for Burster it is the web browser window). Patch register raw input device as 'inputsink' - it makes GHOST window receives all keyboard messages. Window procedure check if GHOST window is active or focused.

::TranslateMessage(&msg) generates WM_CHAR etc. messages from WM_KEYDOWN, WM_KEYUP etc. Because of using RawInput only WM_INPUT messages are processed, so we doesn't need WM_CHAR, WM_KEYDOWN etc. [this is why ::TranslateMessage is no longer getting called].

Note: It's responsibility of the parent window (aka the wrapper) to send WM_SETFOCUS to child window (embedded blenderplayer).
However some parent windows (e.g. webbrowsers) will not send WM_SETFOCUS to the child window when someone clicks on it.
In those cases the blenderplayer needs to be patched to call setFocus(&msg); in the event of WM_LBUTTONDOWN (see GHOST_SystemWin32.cpp)
2011-05-07 22:28:56 +00:00
Nathan Letwory
3fe841597b Apply part of [#21590] .dds textures: fix for DXT1n format
Submitted by Amorilia.

DXT1 .dds textures with 1-bit alpha channel have their alpha channel imported in Blender.

The patch also makes change to contact info for the patch submitter.

I left the sync with upstream nvtt for another commit.
2011-05-07 20:53:49 +00:00
471c28f91c Fix #27319: Text editor "Find" does not locate words.
Added new option to find panel of space text which toggles
case-esensitive search.

Additional changes:
- Send NC_TEXT|NA_EDITED when removing markers in find_and_replace modifier
  this prevents "sticked" markers which disappears on first redraw when
  search text wasn't found
- Do not show "Text wasn't found" error when text to be searched is contained
  in the end of buffer and it's selected. Replacing/marking used to happen, but
  this popup message was really annoying for this case.

TODO: It's incorrect to use UI_GetThemeColor4ubv from this operator
2011-05-07 17:52:44 +00:00
e239085f70 io_utils.axis_conversion(...) utility function to easily convert the forward & up axis between different apps on import/export. 2011-05-07 11:25:59 +00:00
770119d16f patch from Dan Eicher, CPack/RPM working again 2011-05-06 23:59:15 +00:00
7a5b16d175 missed updating warp modifier UI, gave a py error when selecting texture UI layer. 2011-05-06 23:54:40 +00:00
ca419b47a4 fix [#27298] Alt + RMB always extends selection 2011-05-06 23:46:24 +00:00
309bb2937d Forgot to mention that for scons, I've disabled install of the texture and
sequence plugins, as was already done for cmake, they don't work in 2.5.

This is a fix for last commit, this file shouldn't have been included.
2011-05-06 20:21:20 +00:00
cb12337363 Code cleanup: remove source/kernel module, this wasn't really the kernel of
anything, only contained a hash map and functions to pass command line args
to the game engine. Moved those to container and BlenderRoutines modules.
2011-05-06 20:18:42 +00:00
4eb1b5256e Code cleanup: PIL_dynlib, renamed to BLI_dynlib, and other tweaks. 2011-05-06 15:17:42 +00:00
e26b0c68a4 patch [#27205] Infinite recursion inside resolve_ncase() when passed a driver letter on Windows that does not exist
by Brandon Ehle (azverkan)
2011-05-06 11:27:04 +00:00
576035f9e1 Patch #27225: blenderplayer resource compilation error fix for cmake + mingw,
patch by Ryakiotakis Antonis.
2011-05-06 08:16:44 +00:00
ba5d18b41f py/rna debugging option (defaults to off), which quickly exposes errors with RNA functions holding string pointers by making a temp copy of the string and freeing after the function is called. 2011-05-06 03:29:55 +00:00
22c22d4961 fix [#27304] uiItemsFullEnumO: operator missing srna ''
python strings are not static so dont hold pointers to them within blenders UI.
2011-05-06 02:55:09 +00:00
8751d1d927 [#26715] Blender2.57 crash when opening in Windows, non-latin char in path
this isn't a fix but GetModuleFileName is returning a name that doesn't exist, so finding python after this isn't working.

Show a popup that the path has an invalid name so at least the user can move it.
2011-05-06 01:03:36 +00:00
53096ebad5 add zlib include dir for cmake too. 2011-05-05 22:41:49 +00:00
Dalai Felinto
dfedec8a2c fix to scons after exotic was removed (patch from jms) 2011-05-05 18:50:17 +00:00
2137e2ecec Fix for [#27294] Subframes cause dampened particles to behave differently
* The unphysical particle damping wasn't scaled according to the timestep.
2011-05-05 17:07:20 +00:00
53a2f11148 fix [#27285] Renderslot missing
scale fixes size header buttons by DPI
2011-05-05 15:21:43 +00:00
05a78baa87 sphinx api docs: fix for addons linking to the wrong operator SVN url's.
also change from blender from 'release' back to beta so new docs don't overwrite the 2.57b release docs.
2011-05-05 14:45:24 +00:00
3e949dd12f remove exotic.c, there was no operators to access these formats and they were not well maintained. 2011-05-05 14:21:31 +00:00
fbe17e09a3 alternative to joe's commit r36451.
loopcut now follows 'Release confirms' user preference.
2011-05-04 20:42:34 +00:00
5ed5c7441c new rna api call: RNA_struct_idprops_unset(op->ptr, "someprop"), added to allow un-setting operator properties. 2011-05-04 17:36:13 +00:00
015a32d01c new BLF functions
- BLF_height_max
- BLF_width_max
- BLF_descender
- BLF_ascender

use for tooltip and image stamp.
2011-05-04 15:09:48 +00:00
d000103e80 Own TODO item: sculpting on constructive modifiers
- Constructive modifiers are enabled by default in sculpt mode.
- There's option to disable all constructive modifiers in the "Options"
  panel of toolbox in sculpt mode,
- Use one column in options panel to make strings easier to read
- No modifiers would still be applied on multires
2011-05-04 13:15:42 +00:00
5d1fdb73ce drawing in 3d camera view conversion between mouse/camera view border was broken. 2011-05-04 12:59:24 +00:00
b9076b87d2 pass colors to glColor as vectors where possible. 2011-05-04 12:00:11 +00:00
5a0dca41e5 fix 2 bugs with addon installation
- installing an addon which creates a new script directory didn't add this to the sys.path.
- installing the addon was meant to set the search string to the addon name but was broken.
2011-05-04 08:44:08 +00:00
7c5d6c9c39 workaround [#27276] Full Screen toggle for Save Screenshot ignored
don't show the option in the file sel, it only has effect when set before invoke.
2011-05-04 06:08:14 +00:00
ff7ae1d4f4 rna object constraint remove function wasn't calling ED_object_constraint_update(). 2011-05-04 05:56:26 +00:00
ea5b43d862 fix [#26920] working with bones causes segmetation fault.
ITASC IK solver data wasn't being cleared when constraints were removed, would access freed memory and crash.
2011-05-04 05:52:14 +00:00
b5c2598a6b use UNUSED in some more function args, no functional changes. 2011-05-04 04:00:53 +00:00
41dbd19b4d fix for crash executing sculpt via python. 2011-05-04 03:34:55 +00:00
Dalai Felinto
c56fe3efe6 Patch [#26799] 2.5x blenderplayer (BGE) anti-aliasing & embedding by Sebastian Korczak (with some small tweaks) + adding GHOST_PRINTF
The patch can also be found in http://codereview.appspot.com/4431072/

##############
This patch fix anti-aliasing (multisampling) implementation for win32 platform. It also gives opportunity to embed blenderplayer inside parent window.

Usage:
blenderplayer.exe -i 123456 -m 16 file.blend

where:
123456 - parent window handler (integer, default: 0)
16 - multisample level (integer, default: 0, max: 16. Put there maximum level you want. If not supported, player will automatically try 15,14,13,...,3,2,1)
##############

This patch was originally created as part of the Burster (aka webplugin) project but benefit any one embedding the bge in a custom OpenGL context. By the way, to embed the BGE in a .Net application is really straightforward now =)
The Multisampling work for blenderplayer as a whole.

Missing functionalities:
- to expose the multisampling to the ui (so far it only works in console)
- window focus and keyboard messages for embedded blenderplayer (supported in their previous patch for 2.49, yet to be ported over)
- handle resizing (to be investigated, indeed the changes in getState() in GHOST_WindowWin32.cpp are going to get in the way of that if I'm not mistaken. To be addressed together.

Doxygen documentation to be added whenever I sort out how to do so. Sorry Nathan too many stuff to deal with at the same time. The sooner this patch gets in, the sooner the missing functionalities can be patched on top of that.
2011-05-04 01:50:17 +00:00
8df1a51c19 Do not lock key whn undoing to another shapekey while sculpting 2011-05-03 18:47:16 +00:00
Dalai Felinto
905289eb60 bplayer stub update + remove some tabs 2011-05-03 18:31:01 +00:00
aca6c426f0 fix [#27160] Shaded checkbox is not working. 2011-05-03 15:30:16 +00:00
23f1f26e7b fix [#27271] Going into sculpt mode causes crash 2011-05-03 15:01:55 +00:00
12a78aceee fix [#27218] Tooltip text renders incorrectly. 2011-05-03 13:12:47 +00:00
80d94babe0 fix [#27268] 2.57b Global Pivot Option not functional. 2011-05-03 12:37:15 +00:00
0a2a138d86 remove player runtime writing functions, this is now an addon. 2011-05-03 08:45:40 +00:00
cd2728ea0d fix [#27143] Cannot import key configuration with systemwide install 2011-05-03 08:21:11 +00:00
809252664b correct url [#27252] Help link "Manual" in blender still points to 2.49 documents. 2011-05-03 07:51:07 +00:00
0a415b6e71 replace OBJECT_OT_location_apply, OBJECT_OT_scale_apply, OBJECT_OT_rotation_apply with OBJECT_OT_transform_apply with 3 boolean options.
added back menu item from 2.4x to apply Rotation & Scale.
2011-05-03 07:09:02 +00:00
08a914095e change ghost/x11 toggleConsole to use dummy function in the header. 2011-05-03 07:05:01 +00:00
e601dee168 take 3, fix [#26727] Make Proxy ignores group offset 2011-05-03 05:41:16 +00:00
2865e072c9 fix [#27266] EdgeSplit + RemoveDoubles + MoveView = Crash 2011-05-03 04:18:23 +00:00
b0cd0a0577 auto-merge was incorrectly subtracting the doubles removed from the meshes total face count, remove doubles handles this. 2011-05-03 04:09:56 +00:00
03734f5c58 =trunk=
Recommitted eltopo collision code (but disabled by default)
with Genscher's permission.

To use, you need to install liblapack and libblas
2011-05-03 01:48:15 +00:00
Dalai Felinto
1fdc760bfe bugfix: empty proxied (Ctrl+Alt+P) doesn't maintain draw type and size
reported by me in my Blender ranting sessions with myself
2011-05-03 00:13:01 +00:00
d8eafe14c6 fix [#27148] *Invalid Path* in all "operator presets" dropdowns 2011-05-02 17:29:30 +00:00
a9b066a9c6 Fix for recent glsl commit, forgot to include this file. 2011-05-02 15:59:24 +00:00
2938695b17 remove dos/unix conversion scripts, enough editors and utilities can do this.
update debian spec for new icon location.
2011-05-02 15:56:52 +00:00
e910bf1ef5 fix for building windows/mingw 2011-05-02 14:18:47 +00:00
14d7d480df Fix #26807: glsl diffuse/specular was not clamping negative values, giving
some inconsistent results with the renderer.
2011-05-02 14:01:45 +00:00
7f4b4bbaf0 Fix #26697: glsl color management + vertex color was not working right. 2011-05-02 13:52:41 +00:00
08d8914b3d reverse string lookup listbase function BLI_findstring counterparts, added BLI_rfindstring, BLI_rfindstring_ptr, these search from the end of the listbase (like pythons rfind). 2011-05-02 13:35:04 +00:00
6baa456dfd Potential fix for #27257: menus disappear particle edit mode wireframe draw.
Depth test got re-enabled without check if it was necessary.
2011-05-02 12:50:26 +00:00
354ca130f6 enable face mask selection in texture paint mode again (worked in 2.4x). 2011-05-02 12:32:28 +00:00
a2941a464b Fix #27098: missing 3d view updates when editing GLSL material nodes. 2011-05-02 12:31:09 +00:00
e23e125c34 Fix for revision 36403, using BLI_findstring. This loop looks for the last
found entry, not the first, made this a bit more explicit in the code now.
2011-05-02 12:07:07 +00:00
c2f18383f9 Fix #27165: uvedit mesh selection sync did not handle click / shift+click
for switching selection modes in the header.
2011-05-02 11:34:57 +00:00
b0ed43c581 Image Editor: remove toolbox menu, was an experiment and not in any other space. 2011-05-02 11:32:38 +00:00
438f604d15 UV Edit: move uv vertex buttons code to uvedit module. 2011-05-02 11:11:57 +00:00
02fbaede8f workaround [#27203] Crashes with some high-res image thumbnail generation
skip generating thumbs for images over 100mb.
also pass string lengths as size_t rather then int for path_util.c functions.
2011-05-02 10:22:49 +00:00
1357443e48 Fix #27230: texture paint face selection mask did not work on multires. It
seems the support mapping flag was removed for disabling in edit mode, but
this wasn't necessary.
2011-05-02 10:21:07 +00:00
bee2523a41 Related to bug #27004: there is now an option to disable color management for
GLSL. I've tried to find a quicker way to do it that still looks the same, but
couldn't find a formula that didn't have major color shifts.
2011-05-02 09:08:43 +00:00
5aef2f1ae2 Fix #27243: missing seed button for halo materials. 2011-05-02 08:56:53 +00:00
Nathan Letwory
aecb892e19 Also add build fix for OSX (not-tested, so OSXers, please do test). 2011-05-02 08:39:17 +00:00
3986896500 copying/freeing node trees now adjusts grease pencil user count.
also NULL freed texture node socket data incase its used again by accident.
2011-05-02 08:37:44 +00:00
e9e9f89f1a x11 builds again. 2011-05-02 08:36:00 +00:00
Nathan Letwory
d197ec74e3 Fix [#26981] Command window is not opening in 2.57.0
Reported by Thomas Engel
Fix [#26938] Blender Zoom not working after startup (Windows)
  Reported by Ilija Boshkov

by applying patch [#26881] Fix for console disappearing in debug mode [Windows]
  Submitted by Alexander Kuznetsov (AlexK)

The patch moves console toggling code into GHOST and improves on the toggling behaviour.

The patch changes handling of WM_SYSCOMMAND so that alt-key toggling isn't a problem anymore.
2011-05-02 08:07:24 +00:00
1745113639 Use enum menu for angle source in sculpt mode -- rake toggling wasn't
working due to it's 3 possible sources.
2011-05-02 08:04:05 +00:00
474fe33301 fix transform code using a node space as an image space, accessing unallocated memory.
also remove bullet patch which has now been applied.
2011-05-02 05:24:59 +00:00
07ee0dcc74 build system changes to eltopo, re-applied. 2011-05-02 03:44:02 +00:00
4548063f97 SVN maintenance. 2011-05-01 23:16:16 +00:00
088899236b =trunk=
Recommitted eltopo collision code (but disabled by default)
with Genscher's permission.

To use, you need to install liblapack and libblas
2011-05-01 21:39:13 +00:00
7cc98cbb0b warp modifier, using negative strength inverts the transformation matrix but the location it gave wasnt useful when rotation was used too, just negate the translation. 2011-05-01 16:07:18 +00:00
6b0d932c0d warp modifier, added in the render branch for durian.
simple modifier, almost like a hook, except it can deform with 2 object source -> target, has option to preserve rotation and use different falloff types.
2011-05-01 15:16:59 +00:00
5440b57432 improve image sequence usability, problem was when the image didn't load there was no way to know the frame that blender was attempting to read.
added a label for image sequence images showing the image file's frame, even when not able to load, this also gives realtime feedback to the user while dragging the frame offset/start/duration buttons about so they can better understand how these settings work.
2011-05-01 14:02:40 +00:00
1093f69e50 Style Cleanup
- duplicate cases in if/else
- calc inside sizeof(...)
- redundant NULL checks.
- assignment to self.
- fix error getting text prefix for screen ID button.
2011-05-01 10:14:09 +00:00
b6ec6e5ca5 tweak image stamp, was 1px overlap and text was drawn too far up. 2011-05-01 09:39:32 +00:00
75494ea5b4 - remove UV_OT_select_inverse, instead use invert option for UV_OT_select_all.
- fixed INVERT option for UV_OT_select_all.
2011-05-01 09:21:45 +00:00
76d4c75881 - Description of texture angle sources and stroke methods
- Fixed bug with empty tooltip for some ENUMs
2011-05-01 08:50:09 +00:00
05538a7c54 Fix #27239: "A" menu in Sculptmode fails
Simple incorrect property accessing fix (enum_items vs. items).

Additional change: removed hotkey to toggle airbrush in sculpt mode
TODO: incorrect hotkeys are shown in stroke method menu, but it's how
      hotkey string detecting works now.
2011-05-01 07:39:21 +00:00
22c2aef77c replace inline string searches with BLI_findstring(), strcmp(..., ""), with char comparisons. 2011-05-01 06:34:40 +00:00
81dabf76d7 copying texture point density was using inline dupalloc rather then BKE_copy_pointdensity() which NULL's runtime pointers. 2011-05-01 05:51:21 +00:00
84d55542c3 fix for r36399
- missing copy, free calls to curve falloff.
- missing localizing call for texture preview.
- also moved versioning into do_versions()
2011-05-01 05:41:08 +00:00
9736061c07 =trunk=
Made some improvements to the point density texture.  Added support
for tweaking the falloff with a custom curve.  Also coded new
falloff types based on the age or velocity of particles.

Also added a test break check to the volumetric shade cache code,
to avoid nasty hangups from the preview render (on render, exit,
etc).
2011-05-01 03:57:53 +00:00
4734a33215 Fix #27224: Extrude Repeat Mesh doesn't have options
Poll function was too strict for this case that's why there was
no options in operator panel.

Additional changes:
- Added 'direction' parameter to operator so now extruding
  could be made from script by providing direction vector.
- Fill this direction vection in operator's invoke functions
  so abjusting offset/steps in operator panel gives better visual
  feedback -- direction stays unchanged so user could easily see
  final result.
- Made some tweaks to soft limits, so adjusting values by mouse
  drag isn't such confusing now.

Tested in normal mode (from 3d view), as script and in background mode.
Haven't noticed any regressions.
2011-04-30 18:47:06 +00:00
f86565c90e whitespace edits for bpy api, split some really long lines. 2011-04-30 13:58:31 +00:00
d2218cb7f3 Fix one more crash introduced with r36384: trying to bake resulted in a segfault
Also, use tabs for indentation in previous fix for the same crash
2011-04-30 13:47:25 +00:00
dfa69dad3a fix crash using freed memory with SCREEN_OT_screen_set while the current screen has a full area. 2011-04-30 11:28:09 +00:00
d2c5aa5e71 fix for render stamp text drawing too low. 2011-04-30 11:21:46 +00:00
14e2ac09eb fixed a crash introduced in r36384
where the preview render was calling getCam before setting the scene.
2011-04-30 10:02:23 +00:00
03c362f1ab fix [#27221] stamp text bug in lower lines 2011-04-30 08:54:06 +00:00
ed76b3cb77 normalize quaternions when setting the view axis - some old files had non-normalize view rotation. 2011-04-30 06:40:39 +00:00
d995d641f3 scene sequencer strips now work when camera override is used even if the scene has no active camera. 2011-04-30 06:22:02 +00:00
e7ffd32a61 use camera render argument to avoid temp overwriting the scene camera.
also fix for mistake with rendering stars from previous commit.
2011-04-30 05:42:37 +00:00
c4c22d4e9f - pass the camera to the render stamp function.
- add BKE_write_ibuf_stamp() since saving environment maps & screen shots shouldn't have stamp.
2011-04-30 05:26:09 +00:00
abcdf9573a add back support for rendering local view camera. 2011-04-30 04:29:36 +00:00
9b1e70140d fix for minor glitch when setting the camera in local view (camera could try to smooth view into its self). 2011-04-30 03:36:59 +00:00
3be303aa3e corrections for redundant null checks & transform printing a string into its self. 2011-04-29 06:59:18 +00:00
2cdb79239b fix [#27199] Copy Mirrored UV Coords missing the reverse option 2011-04-29 05:32:27 +00:00
1a7a623c56 fix [#27057] In cam perspective, world-axis-locked xform of an obj at cam loc fails
when constraining the axis, ensure central point of the transformation is not too close to the view origin since this fails.
2011-04-29 05:01:50 +00:00
f3a9b7580e spelling corrections. 2011-04-29 04:43:36 +00:00
70829f05da fix [#27198] Missing Live LSCM Update after Aligning of pinned vertices (W)
UV Sync Select was failing with live unwrap.
2011-04-29 03:01:58 +00:00
e45328f1b6 fix [#26727] Make Proxy ignores group offset 2011-04-28 17:19:32 +00:00
696512f8cc Added tooltip note that parent curve 'Follow' needs to be enabled for track axis to do anything.
also show both enum descriptions in the tooltip (the enum properties description and the individual enums).
2011-04-28 13:01:29 +00:00
e6604d77f5 Twitter report fix :)
More clear naming for image "source" type.
"Single Image" and "Image Sequence" and "Movie File".

Thanks @hjalti for poking!
2011-04-28 12:43:28 +00:00
2cd78c385d fix [#27196] Traceback caused by preset selection 2011-04-28 09:52:16 +00:00
b95a24c2cc fix [#27201] icosphere normals problem 2011-04-28 09:50:57 +00:00
7c125b9cf4 Bugfix [#27194] Difficulty selecting bones with boneshapes enabled and
some bones made un-selectable

Pose Bone selection (like object selection) used OpenGL to draw
wireframes with different colours into an offscreen buffer and then
from that identify which item was clicked on. The bug here was that
unselectable bones were getting drawn for this step too, so they were
getting caught instead of the control bones that were selectable.
2011-04-28 09:46:53 +00:00
06dc54837d fix [#27193] view/camera/set active object as camera sometimes "disabled" in gui (grayed out)
When in quad split view, operators that only apply to the unlocked region can now be accessed from menus and when the mouse is over a locked view.

Applied to:
- VIEW3D_OT_object_as_camera
- VIEW3D_OT_view_persportho
- VIEW3D_OT_view_orbit
- VIEW3D_OT_viewnumpad
2011-04-28 08:26:49 +00:00
49238a323d smooth view now takes the v3d and region as arguments. (no functional change) 2011-04-28 07:55:29 +00:00
d97a1da261 Mwahahahaha! I think I've found the cause of that awful purple/pink
"glow" that was appearing on bones drawn using "octahedral" from
certain angles. It seems to have been caused by a typo in the code
used to "clear spec colour"
2011-04-28 07:10:13 +00:00
11305bd688 CMake build option for security report: CVE-2009-3850
Nothing is changed by default but some linux distributions want to have executing python be opt-in.

This keeps the same functionality but disables auto-run from factory settings and in background mode unless its enabled as a command line argument.

This CMake option is marked as advanced and wont show in the regular options list so its less likely to be enabled by people that like to turn everything ON without reading descriptions :)
2011-04-28 06:20:47 +00:00
7a2d6482e3 skip some calculations with the wave modifier - when the vert has no vgroup weight or 0.0 falloff. 2011-04-28 05:34:11 +00:00
f280f8384f fix [#27186] Wave modifier falloff
regression from 2.4x (own fault)
2011-04-28 05:19:17 +00:00
fca91f550b rename duplicate header defines & remove unused var. 2011-04-28 05:15:47 +00:00
9e6cdf54a3 fix for fix, was incorrectly looping over regions. 2011-04-27 14:53:45 +00:00
2a7e70ba15 remove .Bfs, its not used anymore. 2011-04-27 13:13:07 +00:00
16bd053555 buildbot: switch to ffmpeg 0.6.3 2011-04-27 12:50:47 +00:00
da9d559f36 Fix #27176: Creating a new UV layer in edit mode fails to copy previous one
Implemented copying data from active MTFACE layer to newly created.
Also, fixed the same bug with vertex colors layer.
2011-04-27 08:35:03 +00:00
bc6828426d fix [#27174] World Starfield Generation causes crash
allow escaping from render if generating stars takes too long.
2011-04-27 08:32:20 +00:00
7a44c65ce3 fix [#27164] uv unwrap stretching 2011-04-27 07:36:34 +00:00
6e35c08356 comment regarding bug [#27175] UV faces show incorrect image in object mode (VBO's) 2011-04-27 05:12:07 +00:00
ee2ddfc58a remove normalize call in derived mesh GetNormal, its not done anywhere else. 2011-04-27 04:57:57 +00:00
1860c0c565 Fix for bug #26590, `Texture preview fails when path to custom brush
icon is set'

* Main problem was calling BKE_icon_changed too much, blocked previews
  from updating
* Also fixed clearing the icon when it's not a valid image path

Review link: http://codereview.appspot.com/4356045/
2011-04-27 01:16:24 +00:00
f9cb8f80e7 fixed some issues with the new "shadow only + shading" code.
patch from MiikaH.
2011-04-26 15:29:12 +00:00
64a37fadf0 Adding support for adding copies of existing drivers to other animdata
blocks via PyAPI/RNA

For example:
ob = bpy.context.active_object # assumes default cube has some drivers
added already before running script
dst = bpy.data.objects["Camera"]

adt = dst.animation_data_create()
for driver in ob.animation_data.drivers:
    new_driver = adt.drivers.from_existing(driver)
2011-04-26 13:49:40 +00:00
Nathan Letwory
481aed1d0e Bump version for imminent 2.57b tag. 2011-04-26 12:24:08 +00:00
b12d46f73e - fix for player linking
- added notes to release todo's.
- renamed view3d view transform matching functions.
- added assert in edge split modifier to make a certain bug easier to spot.
2011-04-26 10:38:18 +00:00
e4cc1c3f2c fix [#27178] Material links lost when making mesh data local
- making local object data - Curve/Mesh/MBall lost references to linked materials.
- joining a linked mesh object into a local one lost the link.

As well as these reported bugs, checked all local functions for consistency/correctness and found other cases which would also fail.
- making local metaball didn't ensure unique ID name.
- make_local_armature() was missing check for object users - main body of code would never run.
- local particles didn't set the dupli-group or textures to extern.

checked all local functions for consistency/correctness.
2011-04-26 07:17:21 +00:00
461a7c5c81 fix [#26993] Edge Split Crash 2011-04-25 16:24:38 +00:00
7bedbde536 indentation changes only. 2011-04-25 16:02:53 +00:00
d6e03d2c56 2.5 Interface:
* Implemented a new operator "WM_OT_properties_context_change" to switch to a different tab inside the properties window.
* This is used now inside the Modifier tab for Simulation Modifiers. Based on a mockup by Janne Karhu:
http://www.pasteall.org/pic/11261
http://www.pasteall.org/pic/11262

Rather than having a delete button there anymore, the button changes the context to Physics/Particles, where you can edit the settings and delete the actual simulation.
2011-04-25 13:47:15 +00:00
70d059161b workaround/fix [#27162] Running commands in python console crashes blender 2011-04-25 12:39:53 +00:00
739359faab Fix for [#27112] Boid Particles get Z clamped to 0.0 when "Allow Flighting"
* Boids that can only fly shouldn't care about ground unless there's actually a collision object below them.
2011-04-25 12:26:33 +00:00
f5ed60016c fix [#27139] Value Slider, some colours are two coloured 2011-04-25 11:52:42 +00:00
dd00e1f4c6 fix [#27121] Normals always recalculated when adding a mesh in Edit mode 2011-04-25 10:04:07 +00:00
16ba377026 fix for a crash with the following steps.
- open file sel
- save user defaults
- new file
- ctrl+u (crash)

wasn't type checking the space file, passed info space to ED_fileselect_exit().
2011-04-25 09:28:52 +00:00
bd80f19c22 fix [#27140] Negative Subdiv level in the operator panel.
when relative option is disabled, don't allow setting the subdiv value to a negative number.
2011-04-25 06:44:43 +00:00
8fec90e220 Displace Modifier - Optimisation Tweaks for jpbouza and ZanQdo
- When strength is 0, there's no need to perform any of the
calculations at all
- When the vertexgroup weight for a vert is set to 0, skip evaluating
the modifier for that vertex as it should result in no-change to the
final result
2011-04-25 06:27:32 +00:00
bdbf0abe60 rna api
- allow RegionView3D.view_matrix to be set.
- RegionView3D.view_rotation was inverted.
- add C function view3d_settings_from_mat()
note, intentionally removed NULL checks, double checked this is ok with callers.
2011-04-25 03:02:26 +00:00
262eec84cd 2.5 UI scripts:
* Small cleanup of code and descriptions.
2011-04-24 20:59:19 +00:00
fd45310dfe fix crash [#27158] Appending crash with preview. 2011-04-24 14:45:49 +00:00
8fdebf24f4 harmless changes to quiet clang static check warnings.
- made EXPANDED_AGRP take bAnimContext as an argument.
- remove unneeded NULL check drawFacesColored functions.
- comment some vars which are set but not used.
2011-04-24 10:51:45 +00:00
Lukas Toenne
5c4743b9ee Another fix for node groups: Internal socket stack did not get complete initialization of the sockettype value, leading to wrong b/w outputs. 2011-04-24 05:13:35 +00:00
040a049fb1 Fix #27048: text + SimpleDeform modifier = weird render result!
It's not real fix, just patch which makes things better by using average
normal for each displist separately. There are still some artifacts with
quite highly deformed letters "O" or "g", but correct fix would need
to calculate derivative of modifiers, which isn't implemented yet.
2011-04-23 15:27:35 +00:00
d6d2f09dd9 quiet some clang warnings & fix for bugs in exceptional cases.
- ghost C api, BLI_get_folder_version() could assign garbage values.
- pointcache ptcache_find_frames_around() had a superfluous NULL check which would have crashed anyway if actually NULL.
2011-04-23 12:57:03 +00:00
7f56023e9b Bugfix [#27126] Ctrl 0/1/2/3/4 not working in edit mode
Keymaps for subdivision_set operator were only added for Object mode.
Since this is useful for meshes in particular, added these in EditMode
keymap for mesh editing too.
2011-04-23 11:20:30 +00:00
2060a26139 Bugfix [#27134] Minor bug in the name: property Constraint.is_valid
has label "Disabled"

"is_valid" RNA property for constraints had the property name
inverted, but the displayed name and tooltips were not inverted too
2011-04-23 11:13:36 +00:00
855a3e6ce3 Small type-tweaks (int being returned as float) 2011-04-23 11:09:24 +00:00
d730610457 Fix #26959: change selection of shapekeys in edit mode causes mesh deformity of a key
Vertex offset, which was used to update referenced keys was calculating between
editmesh (which represents shapekey data) and base mesh (ob->mesh) which represents
Bases key.

This commit fixes bug with incorrect ofsset calculation for case when some keys
got other (not Basis) keys as relative key by calculating offset using EditMesh
(new shapekey data) and keyblock data (which was used to create EditMesh when
entering edit mode).

This commit shouldn't lead to regressions, but maybe there's something else
which should be fixed for such kinda complicated cases -- more testing would
be welcome.
2011-04-23 09:25:34 +00:00
ef14d310a0 Sculpting on shapekeys
======================

All this work with sculpting on armatured/deformed mesh allowed to
implement sculpting on non-locked keys very easy -- just use the same
approach of propagating offsets from deformed PBVH to "sculpting layer".

- If key is locked, then old logic would be used.
- If there's multires modifier enabled, sculpting would happen on multires.
2011-04-23 09:07:46 +00:00
8ca9dc3cfe Send NA_EDITED notifier when changing tab width in text space properties
Now text editor refresh correct and there's no more glitches with messed up
syntax highlighting.
2011-04-23 08:52:27 +00:00
Lukas Toenne
f69825e8e8 Color info in node editor backdrop now supports color management. 2011-04-23 08:30:28 +00:00
176e45f88e fix for possible (but unlikely) crash.
added NULL check in case nodeAddNodeType() is given an invalid type or the dynamic node cant be found.
2011-04-23 08:02:29 +00:00
7faa531a62 fix for possible crash using an un-initialized pointer when getting a vertex weight from a non-mesh/lattice object. 2011-04-23 07:28:30 +00:00
Lukas Toenne
6b4cecc466 Fix for group output memory leak, bug #27104. This happens when an internal node in a group has multiple output buffers, but only some of them are used. Then all the buffers would be created, but the unlinked outputs were not correctly tagged for freeing after group execution. 2011-04-23 07:21:10 +00:00
25974319db skip pose slide if the RNA value isn't found. 2011-04-23 07:04:50 +00:00
d494c97b58 fix for using enter on menus which load files:
commonly Ctrl+N,Enter or Ctrl+O,Enter
2011-04-23 03:31:27 +00:00
1518d43f27 cancelling bake wasn't freeing the bake mask. 2011-04-22 16:47:17 +00:00
e520c498d2 View Dolly Operator: Ctrl+Shift+MMB.
Recently there were 2 reports about zoom not working right because at some point you can't zoom in any further.

This is not actually a bug with zoom but a limitation in blender that there is no way to move the viewpoint forward (unless you count rotate 90d, pan, rotate back which is a crummy workaround).

So adding view dolly operator:
- Supports zoom to mouse position setting.
- Supports dolly hoz/vert, invert setting.
- Moves by a fraction of the view 'dist', so the zoom distance my be roughly in proportion to the scale of objects in the scene.

only used in perspective view since this is not useful in camera/ortho view.
2011-04-22 15:34:07 +00:00
ee9ea98e48 zoom operator.
- continue zoom now uses the same options as dolly (hoz/vert & invert).
- remove event mouse coord hack to bypass touchpad zoom invert, instead pass invert as an argument.
2011-04-22 14:47:35 +00:00
05c7db95b6 buildbot:
Fixed typo for 64bit blenderplayer which caused undefined symbol gzopen64
2011-04-21 19:01:31 +00:00
b52637270d bugfix [#27091] Add new vertex at wrong position ( bpy.ops.mesh.dupli_extrude_cursor() ) 2
Ctrl+Click on mesh or curve view was using the selected points location or the cursors.
if either of these was behind the view it would add the point at (0, 0, 0).

now fallback to the view orbit pivot, added this option as an argument to view3d_get_view_aligned_coordinate().
2011-04-21 18:33:30 +00:00
284a0d3610 pass even mouse coords value as const so its not edited, view3d_get_view_aligned_coordinate() could modify the event->mval. 2011-04-21 17:25:58 +00:00
9646f8e5b1 ack, should have done this before tagging else bpy.app.version_char will be incorrect. 2011-04-21 16:16:12 +00:00
f9f771cd01 converted more mixed tab/space indentations to tabs. only whitespace changes. 2011-04-21 15:53:30 +00:00
210ee1ade4 whitespace only, no functional change mixed tabs/spaces --> tabs. 2011-04-21 13:11:51 +00:00
2e9982f420 Bugfix [#27095] B-Bone doesn´t resize correctly with numeric input
B-Bone resizing was acting more like translation than resizing when using numeric input. Added the flag to set all xyz values to same value when using numeric input
2011-04-21 12:48:07 +00:00
c7536d558b patch [#27094] Fix for property names in sunsky presets
from Ejner Fergo (ejnersan)
2011-04-21 12:14:10 +00:00
aa7106e4cb patch [#27070] cmake fix for nmake builds 2011-04-21 12:07:40 +00:00
96d04bd9ea re-compress png's (save some space)
optipng -o7 -zw 512 -zm 9 -i0 *.png
2011-04-21 10:03:45 +00:00
c605091b09 Fix for fix for the bugfix :)
Just cleaned the code/order here and added comments why this works.
I should have known it... thanks Andrea for quick action!
2011-04-21 09:43:38 +00:00
20d3022076 following on from last commit r36263.
copying metaball, lattice and armature datablocks while in editmode could segfault when they were freed, NULL these pointers on copy.
2011-04-21 09:38:09 +00:00
62a02764ab fix [#27096] Segmentation Fault trying to export DirectX with specific model
copying a mesh in editmode didnt NULL the edit_mesh pointer.
2011-04-21 09:03:04 +00:00
cb06c4eee1 remove checks on deprecated multires pointer. 2011-04-21 08:55:10 +00:00
c3d1e1f3e9 cmake - install icons into $PREFIX/share/icons/hicolor/ rather then $PREFIX/share/pixmaps/, also move blender icon into 'apps' dir. 2011-04-21 06:37:54 +00:00
817c6eebe4 patch from Jakub Steiner for freedesktop icons [#27086] install a high resolution launcher icon 2011-04-21 06:27:39 +00:00
6bb626f253 minor changes
- remove some warnings
- fix typos
- cmake allow in-source build (when WITH_IN_SOURCE_BUILD is defined)
- cmake, use an explicit list of rna files (don't glob)
2011-04-21 05:49:47 +00:00
18e4f7de4f Bugfix [#27090] Available keying set fails in armature pose mode
A change in the poll callback that Available KeyingSet used to use
restricted its use to Object-mode only, while this could also be
useful in Pose Mode (though it would only affect all channels there).

Made this use a custom poll callback now that tests for whether the
active object has an action. This does mean that if you select a bunch
of objects with animation data, but the active object doesn't have it,
then the keyingset will fail to fire, but that's been marked as a todo
in the code.
2011-04-21 01:21:28 +00:00
26916206f8 fix [#27084] Crash when chosing non-voxel data file in voxel data texture input
also found loading voxel textures wasn't closing files it opened.
2011-04-21 00:28:05 +00:00
831cc31482 fix [#27083] Crash on setting Voxel resolution below -3 in 8bit raw texture settings 2011-04-20 23:21:26 +00:00
2d9c94604a fix crash with lots of operators when running "blender -d". Easy case to reproduce, just try to delete default cube.
Temporary hack to prevent crasher, likely caused by rev. 36242.
2011-04-20 20:46:02 +00:00
Lukas Toenne
a6c2d8680b Internal need_exec tagging for group nodes, fixes #27034. Non-compositor node trees (texture and material) only use the need_exec flag to exclude cyclic dependencies, ugly double use of that flag. Oh well, hopefully can replace this altogether one day ;) 2011-04-20 20:31:43 +00:00
290a641c32 Bug fix: "make fur" gave errors with multiple selected objects.
* Also some code changes for "make smoke" and "make fluid" to suppress some python messages that were printed to the console.
2011-04-20 17:51:56 +00:00
66b605ec93 Fix for [#27075] Explode Modifier - Apply as Shape impossible
* Explode modifier was flagged as "nonconstructive", so the "apply as shape" option was shown. And yes I know exploding things probably isn't usually considered as very constructive, but.. :P
2011-04-20 17:15:33 +00:00
5bd110c6ba Bugfix #27026
Outliner objects showed "active" or "selected" in confusing
ways. Now the display is simply binary, and more in line with
how other items in outliner draw:

- text is white = item is active
- color circle behind icon: shows selection state
2011-04-20 16:19:49 +00:00
8a7dce5301 update tooltip since this fixes paths from newer versions. 2011-04-20 14:47:00 +00:00
7e3d044bdd fix [#27072] Calling bpy.utils.blend_paths(True) results in segmantaion fault since 2.56 2011-04-20 12:55:42 +00:00
85480f320f Bugfix #27044
Enter or exit localview changes bitflags (layers) in Objects, and should get an
undo push for that reason.
2011-04-20 12:30:13 +00:00
7a7df3bfe8 avoid calling newdataadr() on NULL vertex groups, gives a small speedup on loading with files that have many empty groups. 2011-04-20 12:06:23 +00:00
Nathan Letwory
01fced7e35 Fix [#26884] Console is not hidden when start blender
reported by Michael R

Don't print the error message, as it isn't very useful. If there is no Quicktime in Blender GUI in a build that has support enabled, it means that the user hasn't installed Quicktime.
2011-04-20 12:04:07 +00:00
069a3c193c Bugfix #27058
Top bar: Add -> Mesh -> UV Sphere + Enter crashed.
It didn't crash with leftmouse, but that was coincidentally working.

Menus were freeing modal handlers in Window, while handlers were still 
in use. Fix provides to tag handlers for being freed now.

Will add on my attention list for more elaborate checking work here, for
upcoming 2.57a I rather stick to minimal change in code here.
2011-04-20 11:15:58 +00:00
141be02c90 tested with a very large blend file 600mb. - from [#27002].
without this check the file took 4m, 40sec to load, with the check it takes ~3.3sec.
2011-04-20 10:50:56 +00:00
a4ebe848d9 Bugfix [#27054] 2.57 icons and buttons aren't perfectly centered
This seems to make things look a bit better. What a difference 1px
makes...
2011-04-20 10:10:07 +00:00
Lukas Toenne
38a192031f Upgrade for pixel color info in image editor and compositor backdrop. Next to the RGB color values there is now a small rectangle displaying the actual color under the mouse cursor. In addition to that the HSV and luminance values are also displayed. 2011-04-20 09:49:32 +00:00
0da889dff5 while looking into [#27057] noticed when the view and the transform center are 0,0,0 it gives NAN values. 2011-04-20 09:46:45 +00:00
e0a81dd1a8 This was causing too many problems. Better to just not enable this for
now. There are really many good uses for this anyway.
2011-04-20 09:41:44 +00:00
661d6ff7e5 Fix #27014: ctrl-A, ctrl-C, ctrl-V breaks formatting of script
This bug was caused by tabs->spaces conversion. Change pate-ing logic to
paste buffer AS-IS (without any conversions).

This commit also fixes undo-ing  block deletion which contains tabs when
"Tabs as spaces" is toggled on. Also, markes shouldn't be moved after
pasteing new buffer.
2011-04-20 07:44:42 +00:00
66f5ac408e edit definitions to use const for non modified args, also correct incorrect definition for clip_line_plane(). 2011-04-20 06:47:16 +00:00
b5a2d7f15e Bugfix for #26795 and #26917, Fix a bug that cause the radar sensor to break
Never memset(&ob, 0,sizeof(class)) when there is a constructor, it overrides all memory.
The problem was that the memset(0) was setting the scaling to (0,0,0), the height of the cone became 'infinity' 
so GJK would iterate 'MAX_ITER' without converging due to this #NAN value
2011-04-20 04:55:58 +00:00
37fcffd0ac fix [#27006] Apply Scale at a B-Bone Skeleton causes rescale of B-Bones and offset of attached objects 2011-04-20 04:11:12 +00:00
791aa327e1 bugfix where separating the armature would also separate the active-unselected bone because editmode enabled the selection when toggled. 2011-04-20 03:05:19 +00:00
33b8d53224 minor cleanup & replace inline armature separate pchan searches with BLI_findstring(), no functional changes. 2011-04-20 02:56:51 +00:00
6931decd23 fix for crash when loading testfile from report [#27002].
error in r36222, also move AnimData *adt definitions inline to ensure they don't get mis-used across different ID types.
2011-04-20 01:21:55 +00:00
fde9ecbfbd fix [#26967] separate mesh with p crashes blender
copying ID properties assumed each property was allocated separately which isnt the case for IDP_Arrays.
2011-04-19 23:52:14 +00:00
be17466942 Fix for [#27038] Bugs when linking particles/collision/softbody modifiers
* Collision modifiers are disabled here by intention, but particles and softbody were copied the wrong way over :)
* On a further note I don't really get this whole "link modifiers" thing as it just copies the modifiers. As modifiers aren't ID blocks there's no sense in calling this linking!
* Secondly I don't think particles, smoke etc should be considered as modifiers here at all, meaning they shouldn't be linked/copied. These "modifiers" only read the mesh data at a certain location of the stack, but don't actually modify the mesh in any way (more info here http://wiki.blender.org/index.php/User:Jhk#Modifier_Stack_proposal).
2011-04-19 16:30:55 +00:00
Lukas Toenne
6cb761f10c Corrected updating inside edited groups, fix for #27018. This was caused by edit updates being restricted to the actual node. Edit functions now should use the generic snode_tag_changed, which also updates all instances of the currently edited group. 2011-04-19 15:15:50 +00:00
9abd711304 Bugfix 26936
EditMode mesh: tool "Mesh Rip Move" shouldnt be in the toolbar.
The tool was coded to use the mouse position next to the selection.
The rip then happens correctly after pressing V and move mouse away
from selection.
2011-04-19 14:36:26 +00:00
8266c602b4 Bugfix [#25960] .1 Action Editor header doesn't update when entering
tweakmode on NLA Strips
2011-04-19 13:17:16 +00:00
b282655088 Fix for [#27008] Replacing particle hair with group objects - viewport does not match renderoutput.
* Object size was determined from the first and second last cache key by accident, when it should have been first and last cache keys that were used.
2011-04-19 13:06:08 +00:00
aa00bbe484 Whitespace/typos 2011-04-19 13:02:49 +00:00
94b99b5d4a Bugfix [#25960] Action/NLA Editor issues with animdata context
Actions now get tagged with an ID-code, which is used to determine
what ID-blocks they can be assigned to. This ensures that material
actions cannot be assigned to the object-level for example.

* Action lists in general will now show only the actions that can be
set for that particular slot. This prevents selection of invalid
actions, and helps cut down the list of actions.
** An exception here is the Add Action Clip in NLA Editor, which will
show all actions but will only add where appropriate. This is because
it's not easy/possible to tell in advance which blocktypes to filter
for when building this list. (TODO?)

* The "Action Editor" is now strictly for object-level action
editing+setting now. This avoids repeateded confusion by people who
try using this to view their shapekey actions, which should go to the
Shape Key Editor instead!
** A context switcher for the legitimate times where this capability
might come in handy is still being investigated.

* "Floating" actions (i.e. actions in some action_library.blend) are
NOT able to be automatically tagged until they are assigned to some
datablocks (i.e. loaded onto the rig + played back once). It is
possible to write scripts that check for certain RNA-paths and "guess"
what datablocks they work on, but it is recommended that you load up
the Datablocks Viewer, and go through such actions by hand, setting
the "ID Root Type" property as appropriate per action.
2011-04-19 13:01:50 +00:00
c4debb1c64 Bugfix #26977 + Patch by Harley Acheson
Using search for operators showed ambigious names like "Duplicate" or "Delete".
Default names should give at least a descriptive label. In case operators
are collected in a group name-shortening should be handled separaly.
2011-04-19 11:17:29 +00:00
a8185f4cc8 patch [#26978] Minor Spelling Mistakes in Editor Operators
+ some errors I noticed.
2011-04-19 10:35:24 +00:00
5b920bc2ff Some strings to store ID names were too small, could cause stack corruption.
corrected these and replaced 'sizeof(((ID *)NULL)->name)-2' with 'MAX_ID_NAME-2'.
2011-04-19 06:59:49 +00:00
6a91cf9adb noticed a problem with rendering non-active scenes in the node editor.
- the frame from the current scene wasn't used - whereas with rendering it is, set the current frame as is done when node rendering.
- camera switching also failed, added a call to it.
2011-04-19 06:37:29 +00:00
217d1aa461 fix [#26900] Problem with active camera between scenes 2011-04-19 06:15:13 +00:00
1d536da57e fix [#27016] Add new vertex at wrong position ( bpy.ops.mesh.dupli_extrude_cursor() )
also found curve click-extrude was always aligning the new points depth to (0,0,0), now work the same as mesh edit - align to the selected point or the cursor if none are seleted.
2011-04-19 05:34:05 +00:00
ba229e3859 fix [#27011] executing a script crashes Blender 2011-04-19 04:19:09 +00:00
6bdb5e75ce fix [#27015] RNA Bug: Unpacking sounds with a long ID name fails: sound ID length wrong?!
also fix for OBJECT_OT_proxy_make and RENDER_OT_render using incorrect lengths for ID names.
2011-04-18 15:20:19 +00:00
5f08bfd46c Fix for [#26990] Loading file w packed audio crashes
FFMPEG was reallocating buffers it didn't own and wasn't allowed to. This workaround should work now flawlessly.

Also fixing a bug regarding unpacking sounds, the UI stated unpacking to //audio/filename while it was unpacking to //sounds/filename
2011-04-18 14:24:36 +00:00
54f3167270 Bugfix #26901
Compositing, lens distortion node: it delivered RGBA out with alpha zero,
making it not draw previews, violates both premul or straight alpha usage.

Now it just sets alpha to 1 for entire output. 

Cleaned code readability a bit as well.
2011-04-18 11:22:01 +00:00
c84e26cb91 fix for part of this report [#27006] Apply Scale at a B-Bone Skeleton causes rescale of B-Bones and offset of attached objects
bbones now get scaled too, but the attached objects still get offset.
2011-04-18 10:40:06 +00:00
9dda11e0f1 correction for windows. 2011-04-18 10:18:35 +00:00
fae253a428 Fix for [#26949] problems opening 2.49 files with audio (relative path problems?)
When I wrote that code main.name wasn't set correctly and I had to use G.main.name; now it seems to be the other way round :-)
2011-04-18 10:04:28 +00:00
0814cdf54e fix [#26951] blenderplayer and runtimes will not load
blenderplayer wasn't finding bundled python, eg: ./2.57/python/lib
2011-04-18 08:27:50 +00:00
75e1104d92 cmake
- allow building blenderplayer with redcode.
- when ffmpeg is enabled remove strict compiler errors for imbuf and blenkernel since its hard to avoid these warnings across ffmpeg versions.
2011-04-18 07:11:40 +00:00
ea5baccbf8 fix for own mistake in recent commit: [#27000] Spotlight spot shape size, lamp object data - numerical entries are interpreted as radians though displayed in degrees in SVN 36199
now apply units after python evaluation for unit buttons.
2011-04-18 03:27:15 +00:00
66bf6487df object.collision was allocating on access for all object types - camera could get collision data for eg.
now check for mesh types only.

any other type will return None.
2011-04-18 01:45:28 +00:00
d95e572227 fix [#26995] Crash on bpy.context.object.collision
use object.collision rather then object.modifiers[...].settings
2011-04-18 01:40:45 +00:00
8b2a3c250a Fix [#26896] Displace Node crashes Blender when connected to Z-Buffer
Clamped the maximum displacement distance to 4 x the input image dimensions - prevents hanging when vary large values are mistakenly plugged in, such as Z buffers,
2011-04-17 22:47:23 +00:00
f261a22263 Committing patch [#26960] bu MiikaH, fixes bug:
[#26945] Hue Correct doesn't Hue But Rather Saturate

thanks!
2011-04-17 22:11:23 +00:00
0862abf68b change unit evaluation only to do try the units replacements if evaluating with python fails, in rare cases its possible a valid python expression could get units applied to it. 2011-04-17 12:47:20 +00:00
d00f664ee0 Fix #26989: Smooth tangent Iteration field in Curve panel not responding.
Not sure what's the uint of step argument for RNA_def_property_ui_range, but
i just set the same values as in other cases used (like Camera.draw_size)
2011-04-17 12:13:02 +00:00
163dbded30 == Sequencer ==
Fixes Fix for [#25713] VSE shows and renders wrong straight alpha gradient even after convert to pr
(see revision: 34540, fix by Janne)

By not breaking the seqcache interface API.

Added comments to header file, so that it is easier to understand, how the
cache API is supposed to work.
2011-04-17 10:05:27 +00:00
69f9104ea7 fix #26957
spotlights halo and intensity tooltip had "(buffer shadow)" in there,
while it works just fine with no-shadow and ray-shadow.

the volumetric "step" property is only visible with buffershadows
anyways.
2011-04-17 08:38:27 +00:00
11caf24c55 buildbot:
Use BF_NUMJOBS from user cinfigs rather than passing it as
command line argument.
2011-04-17 06:17:37 +00:00
bf591017b3 buildbot:
- use cores+1 threads
- do not clean build directories
- separate build directories for blender and blenderplayer

This should make compilation much faster and buildbot rebuild tag could
happen more often
2011-04-16 21:23:05 +00:00
99aec11acf changing the gl texture limit wasn't updating the displayed sizes. 2011-04-16 10:19:34 +00:00
dbf509237e Fix for IRC reported bug from Dalai:
Text editor used to add extra indentation when inserting new line from
line with dictionary. Also, fixed extra indentation when comma is inside string.
2011-04-16 09:58:50 +00:00
71f571a54d fix [#26955] GL Texture Size doesn't work.
Brecht: reverting this change you made r22532, which I cant see a reason for.
2011-04-16 09:26:45 +00:00
7f598451fc fix [#26906] Panorama Button (Camera Data Properties)
- render check for ortho/panorama combination wasn't working since the flags were not initialized at the time of checking.
- disable panorama button in ortho mode.
2011-04-15 12:08:17 +00:00
1fc9fabfbf possible fix [#26930] Blender 2.57 Shuts down when trying to edit 3D text
can't test but this avoids using strncat which is giving problems.
2011-04-15 03:47:54 +00:00
c8798090a7 style changes & replace some memset's with zero initializers. 2011-04-15 01:43:30 +00:00
a41c0c324a fix [#26937] Radio button text truncation should start at beginning of string
ensure start of text is always visible.

- also left in test for fix [#26933] which left it broken.
- quiet warning in AUD Py API.
2011-04-15 01:32:37 +00:00
d3e4c2243d correct typo 2011-04-14 22:15:43 +00:00
a4cc295000 float value reader in compositor backdrop (Alt + LMB Drag) should be 4 decimals like in image editor 2011-04-14 20:30:54 +00:00
5e26763b40 fix [#26933] Render Crash with Decimate Modifier 2011-04-14 17:22:05 +00:00
3ac68d7975 no functional change, avoid making stack arrays for the purpose of indexing. 2011-04-14 17:06:55 +00:00
d9c2497859 no functional change, avoid making a 4 pointer array just for an index lookup for tangents, orcos and normals. 2011-04-14 16:41:17 +00:00
5d850c16bf fix [#26902] Raytracing black dots
derivatives from reflected duplis were not taking object instance transformation into account.
2011-04-14 16:13:32 +00:00
31bd412447 Fix #26932: When I enable multires, and start sculpting, some parts of the mesh just disappears.
Redraw issue was caused due to different redraw rectangles used for 3d view redraw and
gathering PBVH nodes to be re-drawed. I moved redraw rect expansion with rect from
previous step into sculpt_get_redraw_rect, so now redrawing works as it was planned
some commits ago -- redraw everything to which is inside currect rectangle and rectangle
from previous stroke step -- this still prevents artifact caused by fast strokes but
mesh doesn't disappear.

Brecht, Nicholas: it's the simpliest fix i could suggest atm. I've got some more
ideas with additional node flags, but it looked more complicated for me and
made code more difficult to understand. If you could see something better (like
revert all this redraw fixes for fast strokes) please tell me.
2011-04-14 15:53:33 +00:00
5175d509ab fix [#26931] Shift+Alt+RMB only selects loops, can't deselect them - 2.57 official
own fault with fix [#26885] for selected edges having de-selected verts in some cases.
2011-04-14 15:03:28 +00:00
822debf304 fix for help menu docs linking to the wrong page, created a redirect so 2.57 release doesn't get 404's. 2011-04-14 14:13:04 +00:00
b1cc8ea18a incorrect documentation spotted by macouno. 2011-04-14 12:19:31 +00:00
f02b9b37f2 api to support different kinds of relative paths on export, including copying the files to a subdir. 2011-04-14 08:47:47 +00:00
6019b007a8 A better fix than r36151 for the Grease Pencil drawing issues in the
Image Editor.

There's already a flag in use for tagging the "special drawing in
Image Editor" case, so make use of that now.
Most of the changes here are just whitespace tweaks...
2011-04-14 04:22:52 +00:00
fa63c29775 work-around for grease pencil single points in the image view drawing really large (bigger then the image). 2011-04-13 15:30:26 +00:00
9ba543a522 minor improvements to sphinx doc main page 2011-04-13 14:43:11 +00:00
5fbfbd4470 fix [#26904] Crush while open file !
commit r28002 was attempting to run do-versions on an invalid pointer.
2011-04-13 14:40:50 +00:00
Nathan Letwory
2215bd601f Remove unnecessary lines. 2011-04-13 09:09:37 +00:00
8a238fb8f9 disable engine info until report popup bug is fixed. 2011-04-13 09:08:55 +00:00
Nathan Letwory
04af4f7c23 Version bump for doxygen. 2011-04-13 08:47:35 +00:00
cacc6b5ecf fix [#26895] STL import in Win 7 64bit
fixes python non-utf8 path access for file selector 'files' property.
2011-04-13 02:47:52 +00:00
b68c911931 fix for mistake checking engines on load. 2011-04-13 00:51:48 +00:00
84e793a6f9 Crap, there was still a old Link to Release Logs. Maybe retag, after this and last commit (Tooltip error in Splash Screen) ? 2011-04-12 21:17:31 +00:00
656dd38f0d Fixed a copy and paste error in "Copy Previous Settings" operator. ;-) 2011-04-12 21:00:53 +00:00
d78220549b fix for compile issue on MSVC 2008 due to macro expansion differences with gcc. 2011-04-12 17:58:54 +00:00
771390793f fix for crash when pressing 'Copy Startup Settings', was using out of date main database. 2011-04-12 17:18:02 +00:00
2ed8b5f679 reference the release PDF correctly 2011-04-12 16:56:15 +00:00
2a0d8a4dfb edits to blender version data. 2011-04-12 16:36:14 +00:00
4239d7c1a5 The Epic Blender 2.57 first stable commit! :)
Let's do a quick last check if things work, call for release will be done
shortly on bf-committers.

Thanks everyone for making it possible!
2011-04-12 16:24:24 +00:00
f0b45cc1fb - fix for cmake when there is no version character.
- link to release docs correctly from the splash page.
2011-04-12 16:20:41 +00:00
d14738a560 report missing engines on file load. (request from Martin). 2011-04-12 15:55:38 +00:00
bfa332e275 changed image texture filters description from 'Area filter' to
'selected filter'.
2011-04-12 15:55:04 +00:00
a1b6e077fd add randomize transform & object align back into the menu. 2011-04-12 15:12:05 +00:00
b636418bd9 ignore the local blender folder when displaying the copy old settings button. 2011-04-12 14:57:02 +00:00
b3a04b4ea7 Fix crash for Intel G45 video cards
This video card need a bit different approach to buffer swapping.
Patch provided by nico_ga from IRC.
2011-04-12 14:31:59 +00:00
a475368deb Fix #26860: uv snap/weld/stitch did not take live unwrap setting into account. 2011-04-12 14:22:52 +00:00
62c0dfbb46 fix [#26888] 3D viewport shading broken after solidify modifier 2011-04-12 12:59:37 +00:00
6e98c791af fix [#26885] transform option disapears when deselecting loops
deselecting edgeloop & edgering would leave the verts de-selected even if other edges had them selected.
2011-04-12 12:49:54 +00:00
ba03e5023e less alarming warnings about the python api not being stable in online docs and remove from interactive console. 2011-04-12 12:09:38 +00:00
a42bf45333 revert Joseph Eagar's eltopo commits r36073, 36075 (& some minor edits)
discussed with Janne, Ton, Nathan and we agreed this kind of change at least needs discussion with module owners.

Its also too close to release to be making these kinds of changes.

commands used:

  # reverse merge
  svn merge -r36073:36072 .
  # for some reason this gave a lot of property changes
  svn revert `svn st | grep "^ M" | awk '{print $2}'`
  # reverse merging didn't work here, removing while dir.
  svn rm extern/eltopo/


  # manually fixed conflict in
  # ./source/blenderplayer/CMakeLists.txt
  #
  # also manually removed 2 lines from
  # ./CMakeLists.txt
2011-04-12 11:09:10 +00:00
b7269aa36e Fix #26879: Some sculpt brushes does not work when sculpting corrective shapekeys
It was simply missed crazyspace correction for shape keys when mesh is
deformed by modifiers and current tool is smooth/layer (they need special
approach due to they don't use proxies)
2011-04-12 10:16:00 +00:00
618690b05e modify the method for calculating ghost alpha.
* ghost frame 1 did nothing (alpha 0.0).
* was subtracting alpha from the existing alpha which could end up with negative alpha.
* with larger frame ranges the frames on each size would get too close to being the same as the active frames alpha, use 66% alpha for all non-active frames as well as time based falloff.
2011-04-12 10:13:09 +00:00
Nathan Letwory
8937d4f9e5 small patch from Dobz to clean up non-functional multiuser code for now, and ensure admin level is requested on starting. 2011-04-12 08:41:26 +00:00
8fd1d53a31 change behavior of restoring old settings
- only attempt to restore old 'user' settings (not local), since bundled blender's always use their own settings.
- only automatically run 'bpy.ops.wm.read_homefile()' after copying files if the user hasnt alreadt started making changes in the blend file.
2011-04-12 04:23:38 +00:00
3a73a75e84 enable blenderplayer library sorting on windows, (was already enabled for blender), resolves linking issue on windows 2011-04-12 01:56:03 +00:00
e210d82f17 FIx crash when opening User Preferences even with NVidia card
This crash was discovered by Dalai and this happened because of
unset current context (as result of call wglMakeCurrent(NULL, NULL)).
In this case glGetString(GL_VENDOR) returns NULL. Rather than add check
for vendor != NULL before string comparison, I've changed a bit logic of
context creation:
- Create context and set it as current
- If it's crappy Intel card -- delete this context and
  share the only one context between all Windows
- Otherwise, use initial logic (with sharing lists and so on)

This could also fix crash when opening userprefs from a menu with Intel card.
2011-04-11 19:22:43 +00:00
9699592628 py api: bpy.data.is_dirty wasn't working like image is dirty, instead is would return if the file was saved or not.
- rename to 'is_saved' (and negated).
- add 'is_dirty' which is true when the files edits are not saved to disk.
2011-04-11 15:31:05 +00:00
66419dcc12 operator & splash button to copy over old settings when blender version changes. 2011-04-11 15:13:06 +00:00
f8c09b37d4 api changes needed for for copying old settings to new.
- py: bpy.utils.resource_path('USER', 2, 56)
- C: BLI_get_folder_version(id, major, minor, check);
2011-04-11 13:56:58 +00:00
d4d88de2b0 fix [#26856] Can't change target object in modifier by Ctrl+V 2011-04-11 05:33:43 +00:00
2d1e663440 patch [#26861] Spelling, Typos, and Grammar
- also fix own bad assert from yesterday & remove testing cmake print.
2011-04-11 01:18:25 +00:00
cfc2b0b01f fix for one of the [#26854] UV issues
- add back UV X/Y number buttons, the report points out they are missing.
- set the 2D cursor's subtype to PROP_COORDS (so buttons say x/y now)
2011-04-11 00:49:08 +00:00
e37dc17991 Fix for [#26652] "Audio Muted" in Time Line Editor is not working
-> The feature was completely missing o_O
Also fixed an ffmpeg seeking bug.
2011-04-10 22:40:37 +00:00
2afae38019 Bugfix #26842
Compositor: when using RenderLayer nodes from other scenes and FSA,
Blender crashed because these nodes didn't get a 'tag' for refresh.
2011-04-10 18:15:24 +00:00
dbd3009108 - background job style cleanup.
- assert if material assignment is called with lib. (so the callers can be corrected).
- correct example docs
2011-04-10 15:24:05 +00:00
1c11e40cb7 Use the same LLIBS set for cmake at Win64 platform as scons uses.
This fixes linking errors occurred recently for me (kinda of SDL
and registry stuff)

Now it works perfectly, thanks to Campbell for tip :)
2011-04-10 14:44:57 +00:00
f2b9dfe9f7 Redid the previous startup.blend changes by Thomas
(icon for material, 1 console). 
A windows tmp path crept in somehow...
2011-04-10 13:14:34 +00:00
e137a3a081 Fix [#26827] Blender Crashes when it opens corrupt jpeg
* memory corruption when skipping over long marker (was attempting to read over end of file)
* also updated internal jpeg macros to be the same as in jpeg lib
2011-04-10 11:36:29 +00:00
f8124d6db7 [#26848] Keyed Particles seems to be broken
* Explode modifier wasn't updated properly when keyed particles were used.
* Explode modifier didn't get correct locations for grid distributed particles.
2011-04-10 11:24:29 +00:00
28594bc742 minor pep8 edits, also added 'test_pep8' & 'test_cmake' to the GNUmakefile for convenience. 2011-04-10 10:45:56 +00:00
1c6956a4d6 quiet msvc/mingw compiler warnings. 2011-04-10 09:37:04 +00:00
2d677efb3b Startup blend:
* Default material missed the mat preview icon.
2011-04-10 08:29:17 +00:00
e0c759ece3 Startup blend:
* Removed the second console in the "Scripting" Screen Layout.
2011-04-10 07:53:18 +00:00
3815017c95 Labelling fix 2011-04-10 07:05:22 +00:00
74f3d03969 disable new cloth solver by default. 2011-04-10 06:06:26 +00:00
7aed432fc8 eltopo cloth solver couldnt be enabled from cmake, also dont use globbing. 2011-04-10 05:43:34 +00:00
Nathan Letwory
4d469265dd Enable WINDRES only for MinGW, otherwise we get multiple manifest errors for ie. vs2008 2011-04-09 23:25:52 +00:00
0a60bc14d6 =cloth collisions=
Plugged the eltopo library into the cloth solver.
I was playing with it earlier, and it's so easy to
use I decided to quickly put it in (trunk's) cloth.

See http://www.cs.ubc.ca/labs/imager/tr/2009/eltopo/eltopo.html
.  The authors are on the bleeding edge of continuous collision
detection (one of them did ILM's cloth sim).  
I
don't really have to time to plug it into softbody, particles,
bullet, fluid, etc, but doing so would be pretty straightforward.
I'll leave that up to someone else.

To use, turn on USE_ELTOPO (in cmake) or WITH_BF_ELTOPO in scons.
2011-04-09 23:19:11 +00:00
Nathan Letwory
28478967f4 doxygen fix 2011-04-09 19:46:17 +00:00
Nathan Letwory
b344fe05ec whitespace 2011-04-09 19:23:49 +00:00
66cee63665 Fix crash for Windows+Intel video card configuration
Intel video cards don't work fine with multiple contexts and
have to share the same context for all windows. This could work
incorrect with multiple video cards configuration, so suppose
there'll be no such situation (Intel cards are mostly in portable
devices like notebooks and laptops, where there's actually no
dual video cards). Anyway, it should work much better now.

Non-Intel cards behavior was kept unchanged.

Thanks to Ton for debug session :)
2011-04-09 18:29:43 +00:00
5457c871ef change in how cmake works with CMAKE_C_STANDARD_LIBRARIES / CMAKE_CXX_STANDARD_LIBRARIES.
if not defined (first run) these are now set blank but can be defined later.

the problem is that scons & cmake builds would link against different libraries since cmake added its own defaults.
now, by default, scons & cmake have the same libraries.

This fixes an obscure crash in MinGW where cmakes default linking with -ladvapi32 would crash on string formatting which used float precision as an argument, eg:
  printf("%.*f", 3, value);
...without giving a useful backtrace or pointing to the line of code doing the string formatting.
2011-04-09 11:16:37 +00:00
Nathan Letwory
d13df6cffc Print out reports on console too (debug and up) as fix for [#26708] "INFO" reports are not displayed
reported by Tom Edwards

Showing of certain reports (ie. info) is very hidden. At least print these to console.
2011-04-09 02:23:39 +00:00
161927e27e remove -mwindows flag for scons/mingw, enable manifest & winblender.rc for all windows builds except for msvc2010 2011-04-09 00:10:29 +00:00
Nathan Letwory
9feb70d390 Add missing defines for .rc file. 2011-04-08 22:07:17 +00:00
1728c20a63 Fixes related to using Library files:
- Assigning local materials to library objects disabled
  (crashes on undo/redo cases)
- Disabling options in Material buttons to add/remove slots
  on library data
- Drawing Object ID template in Object properties, this
  allows browse active Object, but especially shows library
  status then.
2011-04-08 16:56:44 +00:00
Nathan Letwory
626c268096 Fix small typo in resource define. 2011-04-08 15:00:53 +00:00
Nathan Letwory
a0b172215d Clean up linking flags for win32. 2011-04-08 14:56:31 +00:00
Nathan Letwory
4d2562fb47 Clean up linking flags for win64. 2011-04-08 14:40:43 +00:00
20dea8c108 Fix for compilation under non-windows platforms -- missed check for
platform before WM_console_toggle call
2011-04-08 14:04:59 +00:00
70cd0803ab add new subtype PROP_COORDS, for generic coordinates that are not to be changed by units. 2011-04-08 13:32:56 +00:00
Nathan Letwory
2b95549079 Apply console part of patch [#26044] Windows thumbnails and improved filetype registration
submitted by Tom Edwards

This patch introduces a switch -con and its longer version --start-console. When giving this on cmd-line you'll get the black console window. The new behaviour is to hide it by default. We'll still see briefly the console at startup and during exit, but that's something that cannot be changed.

If you start blender from a cmd.exe, the console will not be hidden.
2011-04-08 12:49:38 +00:00
0f5959abd9 fix [#26674] Inconsistency in snapping CursorToSelection between UV_Editor and 3d_View. 2011-04-08 12:28:59 +00:00
Lukas Toenne
50969c24a6 Minor bugfix in initTransInfo: SpaceImage used even if space type is SPACE_NODE. 2011-04-08 12:02:30 +00:00
5ada3999ca Fix for [#26800] Particle Render "Use Group Count" is shared between different Particle Settings datablocks
* Copying particle settings didn't copy the dupliweights.
2011-04-08 10:28:16 +00:00
Nathan Letwory
08bb4bed94 doxygen comments, removal of superfluous backslash. 2011-04-08 09:31:13 +00:00
ed7f0c603f fix [#26803] Libs paths are case sensitive in windows
another case was exposed by this report, making relative paths wasn't case insensitive on windows.
2011-04-08 06:47:41 +00:00
e6c30a41ea can't include titles in function examples. 2011-04-08 05:03:02 +00:00
fefb044293 for thumbnail generation only scale the byte buffer. (was scaling float & byte). 2011-04-08 03:56:15 +00:00
b305a26d2f fix for own assert with image scaling, wasnt working with float images. 2011-04-08 03:53:40 +00:00
b0d6c0fdee fix [#26830] Blender crashes when opening this file
was linking NLA fcurve modifiers as fcurves (wrong function call).
2011-04-08 02:21:43 +00:00
6b3f5ecd18 change to fcurve keyframe coords broke simplify addon since the property
was no longer wrapped by python as a vector. now fixed size float arrays
with PROP_NONE subtype are wrapped as vectors since its convenient to
have x/y access.
2011-04-08 01:40:54 +00:00
ba44bf522c Bugfix #26812
On anim-render, a click in timeline stopped render completely.

The reason for this was a bit wacko code to cope with frame-step 
feature (steps of multiple frames).

I thought of fixing that, but instead decided to block any operator 
in Blender to change a frame while a render is in progress. 
Both render engine and UI are accessing (writing to) the same 
data then, which is a bad conflict.

Still a serious weakness of threaded render, but I'll keep
trying to allow this as far as possible :)
2011-04-07 15:48:33 +00:00
545b0a483d Bugfix #26748
Boolean modifier should be restricted to Mesh objects only.
2011-04-07 13:14:08 +00:00
5c2b8baa4b Minor fix, own collection.
Knife cut operator was using int_get where enum_get was meant.
2011-04-07 12:36:24 +00:00
3e5e49d902 add margin access [#26806] Missing pack margin for pack islands in UV editor 2011-04-07 08:54:43 +00:00
24d6192f53 fix [#26816] P(separate) an object messes up logic brick links 2011-04-07 08:23:00 +00:00
24b012c978 Sphinx RNA API changelog generator.
- lists added and removed functions and properties.
- lists renamed properties (does fuzzy comparison using min/max, description, type)
- lists functions with arguments changed.

Committed change log from 2.56 -> 2.57:
  http://www.blender.org/documentation/250PythonDoc/change_log.html
2011-04-07 07:53:28 +00:00
8d100c032e Updating BGE dynamic loading docs:
* Adding load_action and verbose keyword args for LibLoad()
  * Adding LibList()
2011-04-07 04:00:56 +00:00
Dalai Felinto
4fb7f6a706 build fix after commit 36036 reported by Tom Edwards over mailing list 2011-04-06 22:03:02 +00:00
0a9ec053c0 Fix for Image.pixels set, buffer was not tagged as modified, patch by Domino Marama. 2011-04-06 12:54:47 +00:00
dbe3369ae2 Name unification commit for console toggling operator.
Requested by Dalai, approved by Campbell. Other requested from Dalai
changes were rejected by our Python Departament.
2011-04-06 12:30:07 +00:00
11efce450d Fixed incorrect RNA access when changing type of sequencer view 2011-04-06 07:24:58 +00:00
56968bb580 dfelinto noticed text editor section was missing. 2011-04-06 06:47:04 +00:00
696e7a311a include needed for windows 2011-04-06 06:29:10 +00:00
083f8d3a0a cmake/windows, temporarily build without winblender.rc until its fixed, was giving linking error with msvc2010 and isn't essential info. 2011-04-06 06:11:39 +00:00
a7507e945d fix [#26803] Libs paths are case sensitive in windows
use case insensitive path comparison on windows: BLI_path_cmp
2011-04-06 06:03:48 +00:00
5c7bed92d4 fix for cmake glew includes (tested with mingw), also made qtcreator project generator work with mingw again 2011-04-06 03:02:40 +00:00
1c8d311287 missed setting WITH_BUILTIN_GLEW on non *nux OS's
also made WITH_PYTHON advanced.
2011-04-06 01:51:43 +00:00
4b15fcf497 fix [#26801] Undoing Animation modifiers undoes 2 steps.
also found grease pencil layer operators were not flagged to use undo.
2011-04-06 01:13:01 +00:00
751bbd0b6a update test checksums (change in normals caused this). also make all imports write blend files so its easy to check what the imports look like. 2011-04-06 00:46:06 +00:00
d00501dfd0 SVN maintenance. 2011-04-06 00:22:44 +00:00
ca254dd37b add option WITH_BUILTIN_GLEW, so linux packagers can disable to use their own glew library. 2011-04-05 23:31:01 +00:00
d5d9c56cb5 minor edits to keyingsets script. 2011-04-05 12:31:55 +00:00
b6a1df337d tooltips were part way of the bottom of the screen (timeline play button for eg) 2011-04-05 12:05:47 +00:00
b2753f6af9 "Bugfix" (i.e. feature request in disguise!) [#26772] Delta Scaling,
Rotation and Location don't have Keying Sets

Added Keying Sets for Delta Loc/Rot/Scale settings (aka dLoc/dRot).
These settings could already be found in the Object properties, under
the collapsed "Delta Transforms" panel.

I've added these to the end of the Keying Sets list, since adding any
earlier will end up breaking active Keying Set setting in older files.
Besides, these settings aren't that frequently used either...
2011-04-05 11:49:58 +00:00
bbf82877cf Bugfix [#26792] blender crash when scaling action strip in NLA
Two part bug:
Part 1) NLA Editor menu was calling wrong operator
Part 2) r35829 broke NLA scaling, since it only checked that the
transform mode used was allowed in the Action Editor (probably
confused by Part 1)
2011-04-05 11:04:00 +00:00
165a40e742 add support for installing addons to custom script path [#26751] installing addon to custom script directory doesn't work 2011-04-05 09:33:28 +00:00
1f45f5c15d fix [#26793] Is the Convert function of Grease Pencil normal?
disallow grease pencil conversion in editmode, was setting a new active object.
2011-04-05 08:54:13 +00:00
61933ec4b9 comment menu item causing crash [#26792]. 2011-04-05 08:43:16 +00:00
8f4343cb30 fix for render only drawing wire curves in wire view. 2011-04-05 07:26:22 +00:00
2b90eb18e2 Commit r33378 adds a red alert to search buttons which have items which are not in the list.
Disable this for pointer buttons since this was intended for vgroups & uvlayers.

Pointer buttons often reference ID's which can be in the 1000+, lookups like this on each button draw is not useful since invalid pointers here will likely crash on scene evaluation.
2011-04-05 07:13:23 +00:00
dcb26e4e47 fix [#26782] Missing settings in some texture nodes.
also rename noisebasis_2 --> noise_basis_2
2011-04-05 06:05:55 +00:00
db6ea4d3a5 utility function for getting the vector direction the mouse is pointing in a perspective view. 2011-04-05 02:58:19 +00:00
162d02bf50 quiet warning & minor pep8 edits. 2011-04-04 22:42:43 +00:00
b3bc0040d8 fix [#26785] Curve shows in 3dview regardless of "Only Render" 2011-04-04 22:40:56 +00:00
257c408f46 == filebrowser ==
Small fix for recent folders in filebrowser, didn't save correctly when too many folders in the list (more than the currently allowed 10), now skips the oldest entries.
Reported on IRC.
2011-04-04 20:32:39 +00:00
83931775a1 Descriptions for some of curve operators 2011-04-04 20:31:01 +00:00
6f20760818 buildbot: static zlib linking
Force link to zlib for all platforms/tragets to be sure there'll
be no gzopen64 symbol undefined (it was in some dependend library, so
blenderplayer wasn't working in fedora 13 32bit)
2011-04-04 19:39:47 +00:00
3303b838c6 Fix for the fix, making hurried last minute changes is not a good idea :) 2011-04-04 17:28:31 +00:00
7b9fed7392 Fix for slow Image.pixels, make it a flat instead of multidimensional array. 2011-04-04 17:10:48 +00:00
35c934af79 Fix mistake in recent commit to revert some normal changes. 2011-04-04 17:09:22 +00:00
89e4de45e4 Startup.blend update:
- Clip in 3d window now 1000 (2nd try :)
- Raytrace "Instances" default
2011-04-04 16:58:17 +00:00
6f5f4283fd Fix #26781: Assigning multiple Materials to Text seems not to work correctly
Problems was in 0-based numbering vs. 1-based. Fonts are getting converted to
displists when they're displaying and here base conversion happens, so no need
in conversion when assigning material to selected text.

This makes indices more inconsistant, but saves compatibility in both of
directions. Maybe in further releases we'll make indices consistent.
2011-04-04 16:19:18 +00:00
e8ea4411f8 Fix for redraw issues when making fast strokes with grab tool in sculpt mode
Join redraw rectangles from previous step and current during one stroke
and reset previous rectangle when stroke is finished. This shouldn't cause problems
with viewport changes during the sculpt session and this should emulate
object boundbox merging for states "before step" and "after step".

At leastm it's more logical because boundbox could not only grow up during
stroke, but it could also shrink down.
2011-04-04 15:15:45 +00:00
25976b7b87 crash fix: screen context editable_bones & visible_bones were not checking for armature type object first. 2011-04-04 15:13:37 +00:00
8d1a04a2bb UI fix:
On dark menu backgrounds, the labels for Option buttons were not using
the theme colors for 'text on menu backdrop'.
2011-04-04 15:01:22 +00:00
2f3758e6d1 Bug fix: The quick effect operators got broken a bit by the new material slot behavior.
* The operators now add new materials and assign them to the created material slots explicitly.
2011-04-04 14:35:22 +00:00
f2fd9d11bc Bugfix #26761
Texture preview render now doesn't increment/decrement material->texture
user counts anymore. Blenders library.c code could use some overhaul
once to support data relinkage and copying around better. :)
2011-04-04 13:47:34 +00:00
36858f6342 Fix for [#26747] Crash accessing dynamic hair RNA
* Removed hairkey.co_dynamic. The hairkey access is now simplified so that hairkey.co are the dynamic coordinates whenever the hair is dynamic.
2011-04-04 13:47:28 +00:00
5b996e04d2 Fix for [#26750] Particles Can Only Address first 16 Material Indexes
* The rna maximum hadn't been updated when the maximum material count was increased.
2011-04-04 13:33:31 +00:00
709e4b309e Revert mesh recalculation change that gives different vertex normals based
on smooth/flat flag on faces. This does give better results for low poly
game models, but there's just too much functionality that depends on this
(modifiers, displacey, editmode tools, extrude, ...), that there's not
enough time to fix these before the release.
2011-04-04 13:02:12 +00:00
265cdf29fb fix [#26754] Live Edit and Editing UI scripts don't work 2011-04-04 10:13:04 +00:00
dfa3a6fc84 fix [#26774] Grease Pencil error?
own error with recent change to grease pencil.
2011-04-04 09:22:06 +00:00
fad71850e4 minor edits to view3d toolbar 2011-04-04 08:47:31 +00:00
57d020f061 fix [#26756] "Release confirms" breaks marker functionality in Timeline 2011-04-04 07:42:08 +00:00
233d8594fc [#26768] 2.57 - sys.path not initialized properly
we should document this properly (we only have general design docs atm), for now just correct the tooltip.

also update api example docs.
2011-04-04 05:47:04 +00:00
4ea7e562f8 rename mathutils.Vector/Quaternion difference() method to rotation_difference() since its too vague when applied to vectors. 2011-04-04 05:17:23 +00:00
188d830385 fix [#26765] seperate selection removes all seams from the new /seperated object.
patch from Sergy to copy the draw flags, also copy smooth threshold and other flags todo with editing / draw settings.
2011-04-04 04:54:41 +00:00
91769a65f2 remove unused DNA from mesh, effects list & cubemap size. 2011-04-04 04:47:18 +00:00
a3cc6c73e8 noticed image color info text was impossible to read at 25% alpha with some images, set alpha level higher. 2011-04-04 04:14:25 +00:00
37007a7bc8 disable continuous grab in the header, its more annoying then useful.
also NULL texture's point density tree data when copying to prevent possible double free.
2011-04-04 03:25:05 +00:00
b344d80726 fix crash with previewing point density colorband, it wasnt being copied with the texture but was freed, making blenders own data point to freed memory.
found in bug report [#26767].
2011-04-03 23:35:20 +00:00
65b13c8089 fix [#26757] Python console: help() doesn't work anymore
also quiet some warnings & add docstrings to bpy module which was shaowing the GPL header in its help() message.
2011-04-03 23:11:00 +00:00
9decca10e0 missed renaming after api modification, used to cycle proportional edit falloffs with Shift+O. 2011-04-03 22:28:33 +00:00
c118d644d9 fix [#26760] Crash on voxel data image sequence file datablock unlink 2011-04-03 22:24:05 +00:00
a30ebdeb68 Fixed invalid RNA access in radial brush operators (like strength/size abjustment) 2011-04-03 20:00:19 +00:00
3fb74f8e59 Startup.blend update
- make outliner search unrestricted
  - clip-end not on 5000 (zbuffer errors), but on 1000
  - disabled continious grab
  - "duplicate action" default on
  - addon svg import default on
2011-04-03 16:55:58 +00:00
993e9d4c46 Image pixel acces, through Image.pixels as floating point values.
It's not the most efficient solution, but this can be optimized later. It's
best to copy out all the pixels at once into a list, rather than accessing
them one by one.
2011-04-03 16:17:39 +00:00
480b9dca64 Add material slot now adds no material in the new slot.
It's obviously much better than the two previous behaviors, since you don't
get confusing linked materials, and you don't have useless added materials.
2011-04-03 16:11:21 +00:00
4c44a1fc04 quiet warnings. 2011-04-03 13:17:07 +00:00
5932cec2c6 temp fix for building with msvc2010, this changes recently and gave mingw/msvc2010 troubles 2011-04-03 12:31:53 +00:00
0298d223cc quiet various warnings, also disable -Wdouble-promotion with cmake since it gives warnings with variable length args. 2011-04-03 10:04:16 +00:00
744a3b9cb2 fix cmake for when BLENDER_VERSION_CHAR is not set. 2011-04-03 07:48:33 +00:00
5c8234c81c replace while loops with angle_wrap_rad() 2011-04-03 05:29:58 +00:00
21bd7fd8d5 patch [#26606] Debian spec: Bump to Python 3.2
also update pacman spec.
2011-04-02 21:51:05 +00:00
90326c4c6e buildbot:
- Remove packed to buildbot_archive.zip archive file to keep scons install
  directory as clean as possible (if i understood correct, this file isn't
  actually needed in the future, so we could remove it just after packing rather
  than cleaning install directory before packing as it's done for cmake)
- No need in scripts installation for linux slaves when preparing archive
2011-04-02 21:11:22 +00:00
2c3b4a91dc Committing patch [#26740] Interface improvement for toolbar by Brecht. Thanks!
This patch makes the bool properties inside the toolshelf more compact, only 1 row per item now. :)
2011-04-02 16:45:17 +00:00
447c73d639 IRC report: Proportional editing tooltip lacked, and missed info for
the menu items.
2011-04-02 16:29:33 +00:00
b85013e1ec Bugfix #26736
Operator "New Image" cannot be redone simply, undo system keeps images
around, and each redo will create new block. Removed it from being
registered for redos.

Also: fix up for default operator names to be complete, and not just
"new" or "load". If we want contextual shortening of operator names
(like in Image menu), that should be handled seprately, automatically,
or anything we can sanely come up with that will suit any possible
language as well.
2011-04-02 15:30:58 +00:00
371a7b477d Fix register method order. Was broken when Campbell moved it to the C implementation.
register has to be called AFTER the type is registered while unregister has to be called BEFORE it's unregistered.
2011-04-02 14:58:58 +00:00
89dea61c17 Bugfix #26731
Hotkey operator "Toggle full screen layout" restored previous layout
wrongly when mouse in was top header.
2011-04-02 14:11:13 +00:00
6a841ef3a1 Readme.html and Link to Release Log:
* Ready for release!
Note: JesterKing: Release notes now point to http://www.blender.org/development/release-logs/blender-257/
Would be cool, if we can use that one.
2011-04-02 13:18:33 +00:00
a5804c2e60 [#26719] Fix AAO Tooltips by Sergej Reich (sergof). Thanks! 2011-04-02 12:54:17 +00:00
d85279e58c move grese pencil layers[i].active (boolean) -> layers.active (GPencil Layer). 2011-04-02 11:06:41 +00:00
3bc59fe771 fix [#26732] Colorband bug with compositing.
reported on IRC but submitted to the tracker for example file reference.
2011-04-02 07:04:34 +00:00
7690086d20 pep8 fixes for buildbot 2011-04-02 05:53:42 +00:00
f1b42a129f add angle wrapping functions: angle_wrap_rad(), angle_wrap_deg().
use with mathutils.
2011-04-02 03:05:49 +00:00
69bd72c3b6 quiet gcc float -> double promotion warnings. 2011-04-02 02:08:33 +00:00
fb994b3c85 fix [#26727] Make Proxy ignores group offset 2011-04-02 01:36:40 +00:00
3f6158eedc 2.5 Particle UI:
* Missing colon and not worth a commit message ;-)
2011-04-01 22:41:02 +00:00
1f7ed6a931 2.5 Weight Paint UI:
* Added menu entry for "Set Weight" Tool. Request by venomgfx :)
2011-04-01 22:19:03 +00:00
6d4f57bc3a Oops, i've forgot that archive is preparing by scons, so stripping should
happpen before calling scons (hope, binaries wouldn't be overwritten by it)
2011-04-01 21:38:04 +00:00
c729c1a997 3D View Toolbar:
* Code cleanup
2011-04-01 21:37:40 +00:00
485229b7db Initial support of linux 32/64 bit for buildbot:
- Use the same config as we're using for release builds
- Added stipping (maybe it should be generalized)
- Not software gl packing, bot would be easy to add

Note, that you should have special environment to create
proper linux builts (which would work for everybody)
2011-04-01 21:22:19 +00:00
367cf47dd6 2.5 UI:
*Brush option "size" had different naming in 3D View / Image Editor.
Ported back name "Radius" to RNA (Brush and ParticleBrush) 

Discovered by Bart Crouch. Thanks!
2011-04-01 20:36:27 +00:00
d40b0dfb75 Comments for mesh normals calculation from Mortem Mikkelsen (aka sparky).
We hope it'll help for further workers in this area!
2011-04-01 18:35:49 +00:00
18fd4d3137 Partial fix for #26673: sss + normal map wasn't compatible with previous versions. 2011-04-01 16:01:29 +00:00
3ddbb36fa7 modification to api docs so release point to:
http://www.blender.org/documentation/blender_python_api_2_57b_release

Development versions point to:
   http://www.blender.org/documentation/blender_python_api_2_57_0

This way updates to api docs after release wont overwrite release docs.
2011-04-01 15:13:58 +00:00
339c6c4a51 Bugfix #26691
"Theme default" missed a couple of new colors still.
2011-04-01 15:08:45 +00:00
b94a5e7f02 fix problem with recent commit [#26717] X-Ray conflict (X-Ray Grease Pencil and Object X-Ray) 2011-04-01 14:14:37 +00:00
a4193184bf - bpy.app.release so python scripts can check if the release is stable or not.
- edited pose bone matrix description.
2011-04-01 14:04:26 +00:00
00fe87c84b Bugfix #26672
Minor glitch: Add Camera operator showed option "view aligned", 
but that doesn't work for camera. Is now hidden.
2011-04-01 13:56:01 +00:00
e725f1cf95 Bugfix #26654
A lot of UV tools only work in Image editor, but the operator polls
allowed them to be used in 3d window too, causing crashes in cases.

Also added a poll() check in F6 redo menu.
2011-04-01 12:51:04 +00:00
2bd22ec559 Animation Editors: Name-based filtering
I'm finally yielding to months of feature requesting, and adding
support for filtering F-Curves by name, where the "name" here is the
text which is displayed for each F-Curve in the Animation Editor
channel lists.

To use, just enable the magnifying-glass toggle on the DopeSheet
filtering settings, and enter a snippet of text to find within the
names of channels you wish to filter. This is case insensitive, and
currently doesn't support any wildcard/regrex fanciness.

Some examples:
loc  <--- location curves only
x loc <--- x location curves only
x eul <--- x rotation curves only
rot <--- rotation curves only
etc.
2011-04-01 12:21:41 +00:00
94ec34fb04 xray option for grease pencil (on by default), sometimes its nicer not to have lines draw through the mesh. 2011-04-01 11:55:21 +00:00
3556da255a fix for memory leak when freeing metastrips from the clipboard. 2011-04-01 09:00:16 +00:00
6d3546069c fix [#26713] Video Sequencer: Audio mute after making meta strip copy/paste
was not recursively restoring sound strips on paste.

also found many duplicate functions were defining the transform mode as in int but getting as an enum, use enum for both now.
2011-04-01 08:51:12 +00:00
308f813f3a workaround for building blender with mingw, was giving syntax error, for now just dont include blender version in the exe for mingw 2011-04-01 06:56:45 +00:00
9999c958c8 fix for cmake / windows from mont29 on IRC. 2011-04-01 06:39:19 +00:00
d2a3005dd0 Add back sculpt mode brush keys.
Operator for switching brushes based on type, cycling through brushes when multiple exist.

This has the advantages over the old method that it doenst rely on hard coded brush names and if there are multiple brushes of the same type it cycles between them.

also fix error in previous commit which broke number buttons changing brushes.
2011-04-01 06:14:39 +00:00
d4a9bc1c21 while looking into adding back brush tool keys found mixed texture/image paint rna vars, using 'image paint' internally. 2011-04-01 04:22:30 +00:00
c8652b301f pep8 checker, mostly pedantic style changes but also found an error in mesh_utils.mesh_linked_faces() 2011-04-01 02:41:15 +00:00
14e94d742e using wrong RNA type in sculpt update. 2011-03-31 17:54:23 +00:00
5d02ce8a7b Bugfix #26687
Using "New scene" operator was setting the screen->scene pointer
after the undo-push, messing up redos or undos immediate after.
2011-03-31 17:14:31 +00:00
cd9b42871c remove bpy python api from blenderplayer, it was being linked but not initialized/available. 2011-03-31 15:28:53 +00:00
6e14661ad0 Bugfix #26651
If greasepencil became active, making Blender area full or restore
screen from full, the greasepencil handler was still running, using
outdated area pointer. This crashed Blender.

Now greasepencil modal() ends on the case its own stored area does
not exist anymore.
2011-03-31 15:26:51 +00:00
76d7a3562c blender had no option to add a new scene from the UI, only to copy the existing one.
added a new scene option which doesnt copy any render settings from the previous.
2011-03-31 14:33:59 +00:00
2900557568 examples for keyframing nested paths. based on report from user der_On's report [#25746] 2011-03-31 12:45:54 +00:00
e4c656c7bf Fix for [#26694] Quick effects problems: Make Smoke/Fluid on a flat object creates flat domain. On a subdivided mesh create no domain.
* Fluidsim has to be before any constructive modifiers.
* Also a bit nicer domain size calculation + a warning message for using flat objects as fluid objects.
* Some code cleanup and clarification too.
2011-03-31 11:49:01 +00:00
c7183d2622 library linked modifiers were not having their ID linked expanded properly.
was missing array cap ends, wave map object and shrinkwrap objects.

use modifiers_foreachIDLink() rather then having to list all modifiers ID's in this function.
also add foreachIDLink() for smoke domain.

This fixes a bug where a linked object has as a modifier using an indirectly linked object for the missing cases mentioned above.
2011-03-31 11:21:21 +00:00
75cd392a57 fix for own error r35877, was ignoring #'s in file path by using the digits value passed rather then the number of digits in the string. 2011-03-31 10:31:14 +00:00
d7dd2154a1 fix for issue #2 in report: [#26695] Two fail cases with modifiers targeting linked assets
also fix for scene.objects.link() not setting library data as being directly used.
2011-03-31 08:49:52 +00:00
278e2bc3a4 use poppups for python UV unwrap operators (since they are too slow to be realtime). this change was lost when moving the menu items about. 2011-03-31 08:46:41 +00:00
e339acf3a9 fix for a crash when loading a new blend file which had a scene with the same name as the old one, the freed backbuffer image from the previous blend file would get reused.
also NULL the bakebuf just incase its accessed in future though at the moment this isnt causing any problems.
2011-03-31 05:20:48 +00:00
7cb68f89ed fix for using freed memory in ED_area_newspace() caused by loading webskategirl_bullet.blend and rendering which created a new image space. 2011-03-31 04:55:57 +00:00
66a1259153 fix for crash when running blender with define WITH_PYTHON_SAFETY & no startup.blend was found.
was calling python function when python was not initialized.
2011-03-31 04:43:26 +00:00
077f8520da Pose Propagate - Further Tweaks:
- Pose Propagate and Pose Sliding tools now work in the same way as
Pose Library previewing, with regards to selections. If some bones are
selected, then only those will be affected. But if no bones are
selected, then the whole rig gets affected.
- Added a "On Selected Markers" option, which only propagates poses to
frames where there's a selected marker. Animators can combine this
with a "select markers whose name contains..." operator to get an
effective way to manage hand-keyed walk cycles, etc.
2011-03-31 01:37:42 +00:00
531d3e410f Propagate Pose Tweaks:
- Renamed "Last Keyframe" mode to "Before End". This mode still just
copies the pose to all keyframes starting from the current frame until
the last one encountered per F-Curve
- "Last Keyframe" mode (new one) now copies the pose to the last
keyframe. This is useful for making animations cyclic (i.e. go to
first keyframe, edit, then Pose->Propagate->To Last Keyframe (Make
Cyclic))
2011-03-31 00:45:52 +00:00
9c01b94148 py/rna Operator.cancel method didnt have return defined. 2011-03-30 16:44:18 +00:00
37f3bbae90 didnt mean to commit to Eigen2 since its externally maintained. 2011-03-30 16:21:35 +00:00
bb1f20a534 includes for building with gcc 4.6 on fedora.
patch from Richard Shaw
2011-03-30 16:14:54 +00:00
cc87bf16a1 quiet gcc implicit float -> double warnings & use floats in places. 2011-03-30 16:11:16 +00:00
4f29bc2594 fix [#26685] Cannot exit from "edit mode"
this does not fix the underlying problem that once in this state you cant exit editmode, only that the layer key bindings dont let the state come about.

Looked into fixing properly but its not so simple since currently object mode operators all use "active_object" which is supposed not to be set when in a hidden layer.
2011-03-30 15:28:38 +00:00
9ba57b6518 pass pep8 checker. 2011-03-30 15:02:02 +00:00
ce2be37026 Small update to the quick effects operators:
* "Make fur" now creates a basic fur material for each object (smaller strand tip width and a little bit of surface diffuse)
* If fluid/smoke emitters aren't rendered the objects are also set to draw only in wire mode so that the fluid/smoke can be clearly seen.
2011-03-30 13:35:54 +00:00
a462f7880b disallow rna paths resolving to upper case X/Y/Z/X / R/G/B/A, python cant resolve these. 2011-03-30 11:51:06 +00:00
Nathan Letwory
2b79378f81 COLLADA lights:
* simplify export and import, now that we have blender profiles for lights. The vanilla import is now more in line with the specs. If a blender profile is found, skip normal import, use the profile data instead.
* multiply energy into color rgb export (common profile).
* recalc distance taking metrics in account
2011-03-30 10:51:01 +00:00
22abd53c7e Quick effects operators:
* A couple of operators to quickly create effects that would otherwise take some time to set up.
* Nice to use for demoing functionality or as a starting point for more complex effects.
* "Make Fur" - Gives every selected mesh object particle fur with a desired density and length.
* "Make Smoke" - Makes each selected object a smoke emitter and creates a new domain object around the emitters with the correct material to render the smoke.
** Has style options for "stream": constant smoke flow, "puff": only create smoke once from the volume of the emitter object, "fire": enable high resolution smoke and set a secondary fire color texture for the domain object.
* "Make Fluid" - Makes every selected object a fluid object (normal/inflow) and has the option to start fluid baking immediately.
* This should provide a nice base for extending these / adding more operators for different effects.
2011-03-30 10:29:32 +00:00
bfadd7c9aa modify error when python is not found so as not to confuse users who don't build blender.
+ minor edits.
2011-03-30 07:21:41 +00:00
206e5b7179 print warning on windows/mac when bundled python is not found, suggesting to build the 'install' target. 2011-03-30 06:27:39 +00:00
Nathan Letwory
5b19ec3559 Apply patch [#26660] Scons build on OSX fails to create Info.plist file fix
provided by Mike Sloman

from the patch report:

When building on Mac OSX with SCONS the Info.plist file is zero length and thus OSX cannot identify icons and file type associations.

The problems was in the execution of the "date" command to add times in the modified bundle name strings passed to sed. This failed and thus the info.plist file was overwritten with 0 length file.
2011-03-30 05:44:01 +00:00
f8b42877b0 update blender release cycle ID. 2011-03-30 05:08:52 +00:00
4052ef1667 quiet gcc's float/double warnings. 2011-03-30 05:07:12 +00:00
91881dce85 - include for BGE joystick sensor
- remove print from numinput and get rid of some float/double warnings.
- nicer align line-number in text  editor.
2011-03-30 04:58:45 +00:00
70162a4abd fix [#26682] Accessing weight sometimes crashes blender
also replace object type check from vgroup_edit_lattice() with an assert since all callers check for lattice type.
2011-03-30 02:59:32 +00:00
77e3eac389 Fix for old bug with subsurf not initializing normals for edges that had no faces,
Noted that a floating point exception caused by this r28953.

With the render engine using DerivedMesh normals this came up as a memory error when rendering some files.

for now zero the normals, could interpolate between vertex normals if needed.
2011-03-30 02:05:10 +00:00
3170074011 Fix for [#26646] Hair particle density texture prevents strand render on linked assets
* Linked particle textures weren't expanded during file load.
2011-03-29 21:00:42 +00:00
952aa9804f fixes in Bullet stuff, roll influence for raycast vehicles was broken,
enable the setPhysicsTicRate for BGE Python
2011-03-29 18:44:18 +00:00
973ce364a4 fix [#26623] script/console windows: BACKSPACE does not work when SHIFT is held 2011-03-29 16:52:26 +00:00
f4ba9495c5 fix [#26667] Can't import scripts when using blenderplayer
- move import override initialization to bpy_internal_import.c so the player and blender can both call.
- remove ineffectual & unused sandboxing code.
2011-03-29 16:12:25 +00:00
c0ab420a73 apply patch for body suspend/resume
See also issue #26614
http://projects.blender.org/tracker/index.php?func=detail&aid=26614&group_id=9&atid=306
2011-03-29 15:46:02 +00:00
e124c47713 Fix #26653: changed DPI setting in user preferences is not saved as default.
Clamping on load did not match RNA property min/max.
2011-03-29 14:39:39 +00:00
b84a6c4d7e use less verbose string formatting for units and interface. 2011-03-29 14:36:55 +00:00
e020c1504e fix [#26657] Smart UV Project missing from Unwrap menu in 3D Viewport 2011-03-29 14:13:11 +00:00
3d9c666f58 fix [#26656] video sequence editor rendering stops at frame 9999 2011-03-29 14:07:07 +00:00
5c79bbe2d8 fix [#26666] Snapping the cursor to selected in UV Image Editor when unwrapping causes an assert. 2011-03-29 13:48:28 +00:00
0297b6c8c6 Fix #26637: another problem with recent normals change, objects with negative
scale did not get correct render normals.
2011-03-29 13:37:16 +00:00
4b96f15cb3 Fix for [#26664] Some particle panels disappear when pinned
* Too strict poll functions for render & display panels.
* Like said in the report cache & vertex groups are a part of the particle system (not particle settings) they can't be shown when the settings are pinned.
2011-03-29 13:00:59 +00:00
Nathan Letwory
e4e78d4754 Apply [#26044] Windows thumbnails and improved filetype registration
submitted by Tom Edwards
Fix [#25473] 64bit Windows installer for version 2.56 is not working
patch submitted by Caleb (Dobz)

The thumbnail patch adds a thumb handler DLL that adds .blend thumbnail support in Windows Explorer. A -r option is added to do registration in background. The patch also improves icon building and metadata for blender.exe.

Caleb fixes and cleans up our installer to an acceptable state. The patch uses the new -r option to do the .blend extension and thumbnailer registration.

Thanks to both Caleb and Tom for their efforts!
2011-03-29 13:00:03 +00:00
74e044065b Fix for [#26665] Force field absorption does not work
* Old bug fix led to all kinds of wrong behavior with "plane" shaped effectors, now things are working properly again.
2011-03-29 12:50:43 +00:00
Nathan Letwory
e4ef822ecd build target was changing into wrong directory. 2011-03-29 12:10:41 +00:00
aa2269e065 remove DEBUG flag from OpenNL with cmake, was giving too many prints in the console when unwrapping. 2011-03-29 11:50:37 +00:00
7a252d9824 Fix for [#26658] Permeable colliders stop particles
* Forgot this exception from the collisions rewrite. Don't check collisions with the same face twice.
2011-03-29 10:27:31 +00:00
dbd13d67b1 Bugfix [#26645] Crash when duplicating an object with driver
Missing null check for "improper" driver variables.

------

Also, this commit includes some WIP NLA evaluation reshuffling which
should be harmless. I had originally intended this for a later
commit...
2011-03-29 09:37:53 +00:00
0f7f203257 Bugfix [#26650] Reset to Default Theme doesn't reset Bone Color Sets
Bone Color Sets weren't set in the call used here. This seems to be a
newish operator that didn't exist in the past, so this error didn't
really show up in the past.
2011-03-29 09:28:46 +00:00
9fc6256c66 add rna read-only width/height for screen areas. 2011-03-29 05:49:34 +00:00
887a61897e use RNA_warning() rather then printf() so we get the python line number. 2011-03-29 05:10:36 +00:00
6e5ce953da use 'is None' rather then '== None' as suggested by python docs & mis-spelling. 2011-03-29 04:16:55 +00:00
e72c278f47 2 fixes for un-initialized memory uses, when running testfile: teapot_envmap.blend
boxsample() expected talpha to be set beforehand, also dont set the int value as a float since its confusing.
2011-03-29 01:47:03 +00:00
5f5ec9ec3c SVN maintenance. 2011-03-28 21:30:41 +00:00
1c88199a71 "Error totblock" renamed into "Error: Not freed memory blocks" 2011-03-28 18:56:43 +00:00
b2ac8ff1e1 Maintenance:
Gave the report-timer (in top header) an own TIMER define, to not
confuse with timers in use for UI. Easier for debugging. :)
Also gave better malloc names to regions in 3d window.

All this for testing proper buffer drawing in Intel cards... which
is still unsolved.
2011-03-28 18:51:27 +00:00
9b9c4184c8 misc nodes & editors: floats were being implicitly promoted to doubles, adjust to use floats.
+ minor update to demo_mode
2011-03-28 17:08:33 +00:00
faf07c3e2b transform: floats were being implicitly promoted to doubles, adjust to use floats.
also use macros RAD2DEGF & DEG2RADF.
2011-03-28 17:06:15 +00:00
859d22467d 2.5 3D View Properties UI:
Show text "Nothing selected" in "Transform" panel (edit mode) rather than only the empty panel.
2011-03-28 15:01:19 +00:00
d766111632 example operator that uses a timer. 2011-03-28 13:53:53 +00:00
bf1e2ce41e color gamma (such as theme colors), were not being wrapped by python as 'mathutils.Color' types 2011-03-28 13:47:39 +00:00
Nathan Letwory
3916b0270e Address [#26641] Texture Quick Edit kicks up error when Editor can't be found
reported by Keith Boshoff (Wahooney)

Instead of a confusing backtrace popup, tell the user the image editor cannot be found, and where to set the path to it.
2011-03-28 13:44:56 +00:00
713f976918 Bugfix, irc report:
Entering editmode crashed, missing v3d properties storage, which got
accidentally removed.
2011-03-28 12:16:20 +00:00
ca38366732 particles & vector-font: floats were being implicitly promoted to
doubles, adjust to use floats.
2011-03-28 11:21:39 +00:00
Nathan Letwory
fee4cc34cc Add missing header for *nix machines. 2011-03-28 11:04:38 +00:00
76ad75b1bb Crouch on IRC noticed inconsistency between name COLOR_SETS & attribute bone_color_sets 2011-03-28 11:01:24 +00:00
Nathan Letwory
bd9854e7d1 Import light blender profile if it exists. 2011-03-28 09:31:44 +00:00
e5bf21898e Fix for [#26617] convert hair particles to mesh crash rev:35787
* Hair to mesh conversion wasn't making sure the hairs had valid keys
* Patch by Sergey Sharybin
2011-03-28 08:27:19 +00:00
72b4bf2fda Bug fix: particles emitted from a moving emitter exploded with verlet integration
* Verlet integration didn't like moving emitters, so now the first step for newborn particles with verlet is actually done with euler integration.
2011-03-28 08:08:59 +00:00
Nathan Letwory
fd72840587 Add stubs for the new timer add and remove functions. 2011-03-28 05:37:25 +00:00
412eed6a27 RNA functions for adding timer (needed for demo mode, also useful for python modal operators).
- timer = WindowManager.event_timer_add(time_step, window=None)
 - WindowManager.event_timer_remove(timer)

Still TODO, is a way for python to check the timer identity.
2011-03-28 04:55:24 +00:00
dd56ebe607 blenkernel: floats were being implicitly promoted to doubles, adjust to use floats. 2011-03-28 04:22:50 +00:00
ac1cb5ee05 - quiet new warnings with gcc 4.6
- use BLI math funcs for normal float/short conversion.
- correct some un-intentional float/double promotions.
2011-03-28 02:34:55 +00:00
cf40220e54 set CMake's GCC warnings for GCC4.6.
-Wdouble-promotion -Wno-error=double-promotion
 -Wno-error=unused-but-set-variable
2011-03-28 02:11:51 +00:00
e567feab64 uvedit: floats were being implicitly promoted to doubles, adjust to use floats. 2011-03-28 02:09:10 +00:00
89c2357892 Bugfix: One more place still using the old "keys" instead of
"key_blocks"
2011-03-27 23:19:32 +00:00
84befe2056 [#26622] Blender crashes when calling transform operator
Add cancellation checks for time* transforms that only run in specific spaces.

Hide Transform Mode operator property (it shouldn't be modified after the operator is run), made default mode Translate, not the useless Dummy.
2011-03-27 22:15:37 +00:00
Nathan Letwory
3c67374f50 Revert r34026, which in it turn reverted r33039. Removal breaks renderers that use COLLADA as their format through render() callback. 2011-03-27 22:02:54 +00:00
47f9b496b1 [#24658] Switching to "maya" via interaction preset breaks when switching back
[#25045] User Preferences Input, not enough menu choices
[#26525] Saving the Maya preset and another key configs

Untangle keyconfig presets and interaction presets (maya keyconfig would set interaction setting, blender interaction would set keyconfig).

Preset menu on slash screen now displays a list of available keyconfigs (as before) but will also set the correspondant interaction presets, if it exists)
2011-03-27 21:45:37 +00:00
3598882f0e Proper traceback when addons fails AST parsing setp 2011-03-27 20:52:50 +00:00
Nathan Letwory
45f9dd4bd9 COLLADA lamp blender profile: add the remainder of the lamp variables to export. 2011-03-27 17:57:14 +00:00
a73c3fe5c9 subsurf, derived mesh and other misc files: floats were being implicitly promoted to doubles, adjust to use floats. 2011-03-27 17:22:04 +00:00
9c8f1e2ef4 imbuf, mathutils & readfile: floats were being implicitly promoted to doubles, adjust to use floats. 2011-03-27 17:12:59 +00:00
4237c0393a view3d / object drawing: floats were being implicitly promoted to doubles, adjust to use floats. 2011-03-27 15:57:27 +00:00
59cdbfd884 math lib and UV project: floats were being implicitly promoted to doubles, adjust to use floats. 2011-03-27 15:54:20 +00:00
617e6a83bc object/paint/misc-files: floats were being implicitly promoted to doubles, adjust to use floats.
- also UV angle stretching was using radians->deg which wasn't needed.
2011-03-27 14:59:55 +00:00
8d7c3f8a7e interface: floats were being implicitly promoted to doubles, adjust to use floats (in most cases) otherwise cast to double. 2011-03-27 14:52:16 +00:00
Lukas Toenne
0b9f67061c Fix for [26631] relative blur decimal value from 2.49 is not correctly converted to percentage value in 2.5
This will not work for file saved between the blur node patch and subversion 2, those will still have to be update manually.
2011-03-27 13:49:56 +00:00
9997c3c895 modifiers: floats were being implicitly promoted to doubles, adjust to use floats. 2011-03-27 13:49:53 +00:00
Nathan Letwory
3cb6f52eec Add blender light profile. 2011-03-27 09:46:20 +00:00
4ec9d47de3 option not to restore the original frame when canceling the animation, use in demo mode. 2011-03-27 08:31:10 +00:00
b11f29c8ac clear some c++ warnings. 2011-03-27 07:56:29 +00:00
587bbc4213 fix [#26616] Line of code make Blender crash 2011-03-27 06:56:37 +00:00
9b19c564ef fix for 'View Docs' with inherited properties, eg: "Object.name", is inherited and needs to open the URL of "ID.name". 2011-03-27 06:15:55 +00:00
50a06eccff pep8 cleanup 2011-03-27 05:23:14 +00:00
7ccfec1ff3 fix (own bug) [#26628] "FCurve/Driver Version Fix" Incorrectly Clobbers Array Indexing
also escape strings properly now.
2011-03-27 03:14:14 +00:00
4b5819a5af SVN maintenance. 2011-03-26 23:55:54 +00:00
7beca3d142 Bugfixes due to recent RNA renaming:
* Driver F-Curves were not getting fixed by the "FCurve/Driver Version
Fix" tool. This was causing problems such as shapekey drivers from
older (2.56 compatible rigs) failing to run. As well as renaming the
paths for these Driver F-Curves, the "disabled" flags also get cleared
from these drivers so that they can be run again

* "Revive Disabled F-Curves"  operator in Animation Editors can now be
used to revive disabled drivers too.
2011-03-26 23:42:51 +00:00
121075ec15 One more fix for recent normals re-calculation change 2011-03-26 17:43:07 +00:00
1fa04dce8c fix for transform using the wrong RNA type 2011-03-26 15:24:59 +00:00
5aec085da0 Fixed memory access in mesh_calc_normals(). Now it uses much less memory. 2011-03-26 09:48:03 +00:00
f141c81b5b - fix for editfont using an enum func on boolean property.
- updated FBX export test hash.
2011-03-26 09:36:45 +00:00
ac2d935a32 Update cmake & scons scripts to use new Collada includes for building with latest blender collada updates 2011-03-26 09:09:00 +00:00
76fd7a90ad Fix for Mac addon install, unzipping could create __MACOSX folder which
we don't need, just remove it if it gets created.
2011-03-26 08:41:21 +00:00
63e40dbe0e Fix #26582, #26586, #26613: recent normal calculation changes didn't take
into account that some tools use normals for things other than display. Now
we properly initialize vertex normals at flat faces too.

Also fixed a normal refresh issue, and deduplicated CDDM/mesh normal
calculation code.
2011-03-26 08:28:24 +00:00
02a7063a09 fix for blenderplayer crashing on exit.
the event consumer was being freed twice, once when going out of C++ scope, another when freeing the system.
2011-03-26 08:13:42 +00:00
d53a0cd48f Bugfix:
Recent renaming of Key.keys to Key.key_blocks broke converter for old
files.

Campbell Alert: However, more seriously, it has broken many current
rigs, especially those with heavy usage of (driven) Shape Keys
2011-03-26 05:52:18 +00:00
cae59a78d8 print guarded-alloc memory leaks on blenderplayer exit. 2011-03-26 04:50:59 +00:00
04e32be958 optparse module is deprecated, use new argparse module in background job template.
correction to example in doc too.
2011-03-26 03:42:59 +00:00
bc88e61efa "Fill Deformed" option for curves isn't dependent from bevel object,
so it shouldn't be grayed out even if bevel object is set.
2011-03-25 22:02:50 +00:00
6bc3b99016 Forgot to add to log of previous commit:
The purpose was to set a wait-cursor draw on 3d windows. I tried for
but it keeps failing... inside threads you can't do UI stuff. Needs
further thinking, probably something via jobs system.
2011-03-25 17:16:22 +00:00
11920f7880 Bugfix #26195
When rendering, during processing scene data, drawing in 3d window
is now locked. Can get extended to more areas in UI easily.

At least this solves all crashes with conflicting memory access in
render && 3d drawing. Deleting objects via operators or delete 
modifiers isn't locked yet.

Also fixed: crash on quitting a renderwindow when it was rendering.
2011-03-25 17:11:32 +00:00
Lukas Toenne
fb2fd88463 Moved temporary drag operator link drawing from node tree to node space function. Otherwise these links are redrawn for each node group.
Changed selection flag used for the selected_nodes context property from SELECT to NODE_SELECT. These are just incidentally the same, but NODE_SELECT should be used for nodes.
2011-03-25 16:53:07 +00:00
62beafdd19 incorrect rna type for the BGE ui. 2011-03-25 14:32:47 +00:00
77a1a2f14e use size_t rather then int for passing lengths to string functions since this is what guarded-malloc uses as well as stdlib.h. 2011-03-25 13:40:44 +00:00
21e0eff897 fix [#26600] TexturedSolid + Curve: Specular affecting other materials 2011-03-25 13:37:50 +00:00
f08a227f93 include gcc builtin defines in qtcreator project file (__VERSION__, __x86_64__, __linux__ etc) 2011-03-25 12:42:33 +00:00
3d5898f3dc Fix for [#25932] Video Sequencer: F-curve insertion failure after un-meta
* Copying/pasting sequence strips didn't properly check for unique names between the copied/pasted strips, so the rna paths of copypasted strips couldn't always be checked properly.
2011-03-25 11:45:55 +00:00
Nathan Letwory
32abf5eca8 Add ExtraTags class for handling tags inside an extra block. 2011-03-25 11:07:57 +00:00
6d08597688 fix [#26610] Pressing the ENTER key while editing a Text Object crashes Blender. 2011-03-25 10:41:53 +00:00
Nathan Letwory
c5c4b31d6b Mostly formatting commit, small elaboration in extra handling API (take pointer to importer). 2011-03-25 09:52:36 +00:00
5f5d091554 Switched the fluid fix from yesterday into using the existing compatible eulers function rather than a custom function. Thanks for the tip Campbell! 2011-03-25 08:47:41 +00:00
8b6b5341a5 move object re-linking into a function. 2011-03-25 08:43:41 +00:00
d8e6dd705f fix [#26607] blender won't duplicate or assign new drivers on duplication 2011-03-25 07:34:44 +00:00
06b04fa886 dont return a system path if cmake's 'WITH_INSTALL_PORTABLE' is enabled. this way portable builds wont find scripts in /usr/share. 2011-03-25 05:23:58 +00:00
5f8fa29755 add cmake option to build without xinput (tablet support) 2011-03-25 04:56:48 +00:00
2c04bab116 SpaceImage.curves --> curve for consistency. 2011-03-25 04:37:59 +00:00
a21f46b6d4 new function RNA_warning(), replaces printf with function which may be called via python.
Now this gives the line number of the scripts thats running, eg:

uiItemFullO: unknown operator 'some.operator'
/c/bin/2.56/scripts/startup/bl_ui/space_view3d_toolbar.py:73
2011-03-25 04:36:10 +00:00
16e736b7db Graph Editor: Euler Filter ported from Py to C
Ported joeedh's Euler Filter code from Python to C so that this is
more in line with the other Graph Editor tools - i.e. joeedh's version
only worked on the active bone's curves, while standard tools could
work with multiple bones/objects at the same time.

To use this new version of this operator:
1) Select all the F-Curves for all 3 of the components (XYZ) for the
euler rotations you wish to clean up. In the Graph Editor, they must
be one after the other (i.e. you can't have "RotX, RotY, something
else, RotZ")
2) Activate the operator from the Key menu in the Graph Editor


In an old test file I have floating around, this method did not appear
to be good enough to fix a very clear discontinuity in the middle of
the action, so I'll test some additional methods too
2011-03-25 03:58:21 +00:00
0c03fa78c1 fix [#26601] Python error when use of autocomplete
Was a naming collision with 'keys' python method, reserve keys/items/values/get for python.
Updated animsys_update.py for shapekey data paths.

renamed:
  Particle.hair --> hair_keys
  Particle.keys --> particle_keys
  Key.keys --> key_blocks
  EnumProperty.items --> enum_items
  KeyMap.items --> keymap_items 

noted:
  http://wiki.blender.org/index.php/Dev:2.5/Py/API/Updates#Since_2.56a
2011-03-25 02:12:44 +00:00
b510019602 fix for incorrect prints with RNA errors (own fault, CONTAINER_RNA_ID was incorrect) & close keymap file after running. 2011-03-25 01:55:00 +00:00
fcc5b5c48c fix for blenderplayer using un-initialized mathutils types. 2011-03-25 00:34:28 +00:00
737ca9ad5f BGE player was using un-initialized variables for initializing the canvas color. 2011-03-25 00:23:02 +00:00
561b6e34f0 Bugfix:
[#25725] Transform bone constraint & 'local with parent' as owners
space
[#26014] ChildOf Bone Constrain (influence) works in wrong workspace

Moved the influence calculation stuff outside of the space conversions
(i.e. so that it is done in worldspace only) fixes these problems,
which seem to arise when a constraint doesn't work in worldspace AND
doesn't need to apply inverse correct for this space conversion when
it's done, hence resulting in mismatch between spaces for old and new
matrices resulting in all the weird behaviour.

Patch to fix this from Jahka. Cheers!
2011-03-24 23:34:43 +00:00
Dalai Felinto
70d7884792 Logic Editor UI: sensor frequency active only when one of the triggers is on. Removing text "Action" from Action and Shape Action Actuators.
I still would love to see a change in the action actuators (Action, Shape and FCurve) even if only a rename or unifying them in a single actuator (I do have some patch for that). Anyways
2011-03-24 21:07:54 +00:00
22ea604c6f Bugfix 26578
"Warp" texture map option didnt work for new bump methods yet.
Also fixed to not grey out bump menu for this mapping option.
2011-03-24 18:39:54 +00:00
dee8ba8ba1 UI clarification: "local coordinates" option for fluid inflow objects doesn't have any effect when "export animated mesh" is selected
* Grayed out the "local coordinates" option in this case to avoid confusion.
2011-03-24 17:17:44 +00:00
3e9293f1a1 Further fix for parented fluidsim objects
* The rotation values determined from ob->obmat have to be continuous as fluidsim interpolates between these values internally.
2011-03-24 17:15:43 +00:00
db421408ce Bugfix #26584
- Colormanagement code was gamma correcting non-RGBA buffers in composite.
  (Like vector buffers). 
- Crash on using "use Color Management" button during composites, because
  it was freeing all node images. Added code to stop first jobs before
  freeing. It sends notifier for recomposites after free anyway.
2011-03-24 14:31:58 +00:00
d5e839d2ab Bug fix: Fluidsim didn't take parent objects into account when calculating the inflow velocity in local coordinates.
* The object rotation was based on ob->rot (which only includes object's own rotation) instead of ob->obmat, which includes parent rotations as well.
2011-03-24 14:19:12 +00:00
422f1674bb fix for using uiItemIntO for an enum, added uiItemEnumO_value function. 2011-03-24 12:36:12 +00:00
da4023b655 fix [#26598] zoom view and scaling odd vertices circle 2011-03-24 12:17:24 +00:00
c2ee06a4b2 Particle charge effector wasn't working properly.
* Probably just forgot this code somewhere a long time ago.
2011-03-24 12:12:54 +00:00
7735eccc54 fix [#26545] Crash when changing values for properties after changing max-min
tried doing this smarter by validating the property exists in UI code before access but this ended up making it too complicated and also hard to account for possible access without checking every time.

for now just redraw all areas when a user property is changed.
2011-03-24 11:38:20 +00:00
19819dcbc7 write project files into the build dir. 2011-03-24 10:54:42 +00:00
3ebb9676c1 fix for incorrect array use when freeing fcurve modifier envelope points, array also wasnt NULL'd on freeing which gave memory errors later on. 2011-03-24 09:59:02 +00:00
2fcc3628d2 ZanQdo Bugfix:
Envelope FModifier data points were getting saved in a non-portable
way. Apparently this broke when trying to read files with this data on
PPC machines if the files were saved using Intel machines.
2011-03-24 09:53:39 +00:00
b3d70cbcba RNA & interface functions for checking if RNA in a button uses valid rna property (not currently used). 2011-03-24 09:27:41 +00:00
0c9488b2f3 the script is now creating 2 project files:
Blender.creator
Blender_Python.creator

.glsl files have been added to the former
latter contains everything .py
2011-03-24 08:33:42 +00:00
b07f94d87b tag variable as unused. 2011-03-24 03:28:18 +00:00
d2614c62eb Pose Menu Tweak: Moved keyframe management items into sub-menu like in
Object menu
2011-03-24 03:23:30 +00:00
3b0a42f898 Reshuffled utility function to keyframe drawing API, removing some
duplicate code
2011-03-24 03:19:30 +00:00
eef811a095 Animation Tool: Propagate Pose
This tool automates the process of copying a pose to successive
keyframes, making it easier for animators to go back and change the
pose for some controls which remain "static" for periods of time.
Previously, animators would need to do a "{Ctrl-Pageup Ctrl-V} *
number_of_static_keyframes" dance for each set of controls that this
happened on, which is not too good ergonomically speaking.

There are two modes exposed via the menu (Pose->Propagate):
- "Pose Propagate" - also known as the 'WHILE_HELD' mode, which
propagates to all keyframes that are holding the same value
- "To Next Keyframe" - which only propagates the pose to the closest
keyframe in the occurring after (but not including) the current frame

Additionally, there are a few other modes that can be used, though
they are less useful for direct use from the UI, though they can be
used via the PyAPI as need be.

---

Also, I did some cleanups in the "Pose" menu to bring it more into
line with the Object mode one. There are some more tweaks that could
still be done here, such as bringing the keyframing operator entries
under a submenu too (as in the Object mode version) to get the length
of this under control.
2011-03-24 03:02:34 +00:00
c210b3991a support for blender as a module on win32. 2011-03-24 00:14:49 +00:00
261f74115d Fix #26571: slow approximate AO with zero area faces. 2011-03-23 23:07:09 +00:00
26dd18e7ce fix [#26591] File browser: select multiple files for Library append/link broken
* added check for valid files a bit too eagerly in Rev.35654. Solved now by
  setting correct type for .blend file contents. Objects are now tagged as
  regular files, while the list (Mesh, Material, ...) (no idcode given) is
  tagged as directory.
2011-03-23 18:51:31 +00:00
7cef4ea008 IRC bugreport:
Splitting/joining editors (areas) was possible in full-screen mode.
That's not possible, crashes on going back to previous.
2011-03-23 16:36:41 +00:00
a94e9c5955 fix [#26456] weightpaint mode with armature modifier, armature mode
disable bone selection in weightpaint mode when the armature is not in pose mode.
2011-03-23 16:05:35 +00:00
9019d3b1f2 Additonal fix for r35724
(bugfix #26573, #26574 and #26551)

Layer visibility code for hotkeys uses different code still, added same
new DAG_on_visible_update() in this operator.
2011-03-23 15:15:42 +00:00
2c4999eccb missed committing this before 2011-03-23 15:14:21 +00:00
66670b8f7f fix for building collada on linux 2011-03-23 15:07:30 +00:00
Nathan Letwory
3c45a2d298 COLLADA: supporting barebone class for <extra> support (incomplete). 2011-03-23 14:25:35 +00:00
392829c6ea fix [#26588] In render view, Blender crashes when collapsing an opened split render pane if you have the histogram tab open in the pane your collapsing. 2011-03-23 14:24:13 +00:00
edc5cf1f96 Fix #26573, #26574 and #26551: objects on layers not visible on load or undo
restore, would not get their dependencies updated when they became visible.
It happend with a shrinkwrap modifier in these reports, but could happen with
other modifiers too.

Now we keep track of which layers have ever been updated since load, and tag
objects on them to be recalculated when they become visible.
2011-03-23 14:06:44 +00:00
72fe34efb2 tweaks not to load webbrowser or math modules on startup. 2011-03-23 13:04:35 +00:00
f87b37b3ef allow unregistered rna classes to have rna properties assigned before registration.
this is useful for the register() class method which is called before the class gets structRNA assigned.

eg:

class MyClass(bpy.types.PropertyGroup):
    @classmethod
    def register(cls):
        cls.name = StringProperty()  # assigned but registration is delayed.
2011-03-23 12:44:22 +00:00
f35c396676 Fix for 1. in [#26212] ParticleSystem.particles issues
* Exposed dynamic hair data in rna to allow exporting hair dynamics.
2011-03-23 10:57:45 +00:00
f64f979a10 Fix wrong CINE_SCOPE_24FPS RNA enum identifier. 2011-03-23 10:33:06 +00:00
9b1ee158e5 Bugfix:
NLA Header was broken by recent Py UI-script changes
2011-03-23 09:22:28 +00:00
Nathan Letwory
82f99a0db0 Adding header for offsetof() 2011-03-23 09:18:09 +00:00
55b6315166 Fix for [#26580] Rekey deselects active verts
* Just a missing flag after rekeying.
2011-03-23 08:52:53 +00:00
6984924b96 fix implicit declaration 2011-03-23 01:50:14 +00:00
95173a4ae8 minor changes to master unpack script. 2011-03-23 01:08:10 +00:00
Nathan Letwory
4470783264 Fix [#26474] double_sided wrong in COLLADA Export
reported by Juan Linietsky

The export was not really wrong, but Maya expects their profile to be present inside <geometry>. Added this for mesh with ME_TWOSIDED flag set.

Ideally this will change in the future to be controllable through options to the exporter (like current Google Earth and 3DS Max extensions for <double_sided>).
2011-03-23 00:19:38 +00:00
Nathan Letwory
ee99cf5aa5 Wrong extension tag: show_double_sided -> double_sided 2011-03-23 00:03:52 +00:00
Nathan Letwory
de89e78589 Fix [#26475] <instance_material> wrong in COLLADA export.
reported by Juan Linietsky
fix by Imran Syed (freakabcd)

Use material index suffixed to material name to create symbolic name.
2011-03-22 22:51:02 +00:00
Nathan Letwory
60b94886c8 Small tweak to material export: only export as <lambert> when spec intensity is 0.0 and diffuse shader is set to Lambert. Other cases will be handled in due time, until then phong. 2011-03-22 22:00:26 +00:00
Dalai Felinto
a4e2ece786 Logic rna: actuator --> renaming Motion Actuator to 'MOTION' and tooltip fix
internally it's still called Object Actuator, but for the user at least it's better motion.
2011-03-22 19:39:53 +00:00
c7f37b84d8 remove constructors, they cause compile errors under Fedora 2011-03-22 16:30:46 +00:00
Nathan Letwory
f78e11dc38 [#26476] <specular> and <shininess> missing from Colada
reported by Juan Linietsky

Export <specular> for <phong> and <blinn> shaders, <shininess> was already being written for these.
<lambert> shader doesn't have <shininess>.

Right now we write <phong> when blender spec is phong, <blinn> when blender spec is blinn. When spec is
any other shader, and diffuse shader set to lambert, we export as <lambert>. Any other combination defaults
right now to <phong>. This will change when Blender specific profiles have been created for the shader
combinations in Blender.
2011-03-22 15:28:56 +00:00
e5eed21a6b Buildbot master tweaks: use generic builder for scons win32, unpack fixes. 2011-03-22 15:25:18 +00:00
636ceed094 Bugfix #26562
Keymap fix for UV/Image editor: the modal zoom/pan functions were checking
for hardcoded events to end. Now it uses the key from keymap.
2011-03-22 15:20:25 +00:00
287a185e90 found text editor X/Y selections coords were booleans and corrections to operator calling script from last commit. 2011-03-22 14:37:45 +00:00
f40d33f24b Added CTest to run most operators in background mode under various conditions to see if any crash.
used this to find quite a many errors already.
2011-03-22 14:09:07 +00:00
fc7c3c663e - weight paint poll would crash if no area was found.
- don't print a line for each operator run when in background mode.
- extrude was using an invalid type for RNA access.
2011-03-22 14:04:47 +00:00
a69524358b Bug fix: Fluidsim crashed after clicking "bake" multiple times
* Fluid baking didn't check if there was already an ongoing job before starting a new job.
2011-03-22 13:30:50 +00:00
ddb9893ca9 some more corrections to incorrect rna get/set types. 2011-03-22 13:30:20 +00:00
04a63cb393 Buildbot updates: working windows scons build, and run slave_*.py scripts
to compile/test/package directly from svn, easier to make changes this way.
2011-03-22 13:05:05 +00:00
5528781f79 add BLI_assert() type checks for RNA property get/set functions, since there ended up being quite a lot of these in blenders source.
These wont be compiled into release builds, and will only print errors by default (unless WITH_ASSERT_ABORT is enabled at compile time).
2011-03-22 12:56:57 +00:00
Nathan Letwory
e8dc841199 Version and platform name were in wrong order. 2011-03-22 12:54:13 +00:00
a79820d284 properties were being used with wrong type functions, this resulted in bad memory access when getting int from an enum. 2011-03-22 12:53:36 +00:00
4c3899ca09 Fixing the particle emitter interpolation (#25385 & #26493) further
* The interpolation should only be done if the dynamics were calculated, since otherwise animation keys can't be set after parenting.
2011-03-22 12:53:18 +00:00
a2acecc9d2 allow system info operator in background mode. 2011-03-22 11:44:46 +00:00
82d13ad999 add missing mem-free on vertex group sorting & dont crash when calling fullscreen in bg mode. 2011-03-22 11:19:02 +00:00
Nathan Letwory
d2a721cfd5 Add buildslave target for builder.blender.org integration 2011-03-22 10:26:53 +00:00
d485a54b59 crash fix for Normalize All VGroups on a lattice without vgroups (probably other tools too - bug was in ED_vgroup_give_parray).
Also fix for crashes running operators in bg mode by using setting poll functions: WM_OT_search_menu, MESH_OT_extrude_repeat, SCREEN_OT_new
2011-03-22 10:13:42 +00:00
cfc904f3f1 - support transform operators running in backgruond mode (was crashing)
- fix for crash getting the extrude mode enum value when a non-mesh edit object was active.
2011-03-22 09:14:27 +00:00
Nathan Letwory
a1567aa7c0 Printing error message would fail on exception. 2011-03-22 08:58:49 +00:00
481b4842cf Blenderplayer: Fixing import issues. Using PyImport_ExtendInittab() for the Blender modules allows them to be imported in the Blenderplayer. 2011-03-22 08:35:56 +00:00
91e4a1bdf8 fix for crashes moving armature layers and applying loc/scale/rot in armature editmode. 2011-03-22 08:30:07 +00:00
a5867232b1 poll functions were for keymap operators were still raising errors in some cases.
remove unused script dirs.
2011-03-22 08:21:16 +00:00
1b80538fea fix [#25688] undocumted functions in pyapi
expose collection function docs.
2011-03-22 04:28:51 +00:00
3384679aec BGE Dynamic Loading:
* Adding keyword arguments to LibLoad
   - load_actions (Default: False) Ensures that all actions are loaded. Otherwise, just actions used by objects in the scene are loaded.
   - verbose (Default: False) Turns on extra prints (eg SceneName: MyScene).
 * Also making error reporting better for when an invalid group/idcode is given.
2011-03-22 02:39:08 +00:00
2299d674f4 operators called from python were not getting their reports back into python errors.
eg:
- console calls operator
- operator calls report
- report went into header rather them back into the console as an error.
2011-03-22 02:38:39 +00:00
a503713d6c Moving netrender to addons 2011-03-22 01:40:22 +00:00
f3686b5885 py/api registration:
move calls to the classes register/unregister function into register_class() / unregister_class() and add docs.

also other minor changes:
- remove face sorting keybinding, was Ctrl+Alt+F, this is quite and obscure feature and face order normally doesn't matter, so access from Face menu is enough.
- add commented out call to mesh.validate() in addon template since its useful to correct incomplete meshes during development.
2011-03-22 01:38:26 +00:00
74a996c869 fix [#26385] operator edit_properties return error 2011-03-21 23:53:19 +00:00
d781ecff75 fix for grease pencil conversion to bezier curve reading past the end of the array. 2011-03-21 23:30:56 +00:00
4bca2e455d use spaces rather then tabs + minor pep8 edits. 2011-03-21 22:37:08 +00:00
379f55f54c fix for error printing class register error, remove an unneeded check. 2011-03-21 22:17:01 +00:00
2304256a6c quiet warning 2011-03-21 22:10:24 +00:00
67cbf22211 Bugfix #26549
Using environment map type "load" increased user counter on each
preview render.

Also noticed that this type of envmap use wasn't threadsafe, causing
imbufs being allocated for all threads. Also fixed that.
2011-03-21 17:10:55 +00:00
9a75ba4463 Buildbot initial configuration files, for http://builder.blender.org
Maintained in svn to make it easier for others to contribute changes,
actually updating builder.blender.org requires manual update on the
server.
2011-03-21 16:46:26 +00:00
f0d7fbc4b7 CMake package_archive target to create a .zip/.tar.bz2 package on mac/unix,
to be used by buildbot.
2011-03-21 16:42:21 +00:00
2513b194a2 pedantic edit, no need to initialize var. 2011-03-21 12:40:06 +00:00
2e6a02438e move script directories for internal blender scripts.
ui/ --> startup/bl_ui
op/ --> startup/bl_operators

scripts/startup/ is now the only auto-loading script dir which gives some speedup for blender loading too.

~/.blender/2.56/scripts/startup works for auto-loading scripts too.
2011-03-21 12:35:49 +00:00
28d39473fc Changed the particle physics "timetweak" value to a more descriptive "timestep" value, which is in seconds.
* Done purely in rna, internally particles still use the timetweak value.
2011-03-21 10:53:29 +00:00
Nathan Letwory
e1a44e9ae6 COLLADA: small tweaks to directional light import. 2011-03-21 09:50:30 +00:00
ae530c23c1 Fixing a typo: "Unknown erro reading file" -> "Unknown error reading file" 2011-03-21 09:37:20 +00:00
500f393bda BGE Dynamic Loading: Fixing a particularly nasty leak that occurred if LibLoad() errored. 2011-03-21 09:32:54 +00:00
1f52d83a99 BGE Dynamic Loading: When given a relative path (starts with "//") for LibLoad(), make the path absolute. This helps resolve relative paths inside the library. 2011-03-21 09:29:28 +00:00
4a305e7edb Half way fix for [#25385] Particles Emitter only interpolates IPOs & [#26493] Particle system animates incorrectly when emitting mesh is parented
* Particle emission now updates all parent objects too to the exact emission time.
* This only does object level animation as updating the object data for every particle would be too slow.
* A better fix could be to interpolate the emission location directly from the current particle emission location and the location from the previous frame, but for this some point cache changes have to be made, so it will have to wait.
2011-03-21 08:47:04 +00:00
599bd1cbda patch from Martin, call classes register/unregister functions.
Modified to only do one lookup.

from Martin: 
 "Basically, what it does is allow you to add register and unregister class methods to rna types, this way you don't have to rely on module register/unregister methods to setup your types properly (and it makes them easier to move around when reorganizing code and easier to understand what a type does when reading code). This is especially nice for PropertyGroup classes that are added as properties to existing types, you can easily see in their register methods where they are added and removed in their unregister method. Obviously, those two methods are optional, so current code still works fine."
2011-03-21 06:22:09 +00:00
6031744c35 fix for use of un-initialized pointers in file_sfile_to_operator(...) & remove unused vars. 2011-03-21 03:22:33 +00:00
8908d55907 == file browser == Code cleanup
* Remove direct access to file->selflag in file_ops.c
2011-03-20 15:15:05 +00:00
b71efb4152 Fix #26557: dots near alpha borders on textures. Tweak threshold in alpha
de-premul for image textures to avoid float precision issues.
2011-03-20 15:03:13 +00:00
549b5e1222 Fix/change in normal computation, now the viewport uses the same angle
weighted normals as the render engine, and the render engine will copy
normals from the mesh rather than always recalculating them.

Subsurf/multires still use regular vertex normals, but they are expected
to be sufficiently high resolution to not need this.

This means that normal maps displayed in the viewport actually match the
render engine exactly and don't have artifacts due to this discrepancy.
It of course also avoids unexpected surprises where your render normals
look different than your viewport normals.

Subversion bumped to 4 for version patch to recalculate normals.

Patch by Morten Mikkelsen, with some small changes.
2011-03-20 13:35:35 +00:00
a50cdf713a Added "Bake Sound to F-Curve" operator to the "Key" menu in the graph editor. 2011-03-20 12:19:21 +00:00
85970c39bf == file browser == Code cleanup
* Remove deprecated variables from FileSelectParams
2011-03-20 11:40:29 +00:00
6be2d3aff9 == filebrowser == Code cleanup
* remove commented out code
2011-03-20 11:27:28 +00:00
e73a2020dd == filebrowser == Code cleanup
* Separate out selection flags from file type flags, was bothering me since forever ;)
* Also renamed ACTIVEFILE to SELECTED_FILE to better reflect actual usage in code.
* Fix crash introduced with last commit, better check for valid selection
2011-03-20 11:16:59 +00:00
5325f3b2e9 == file browser ==
Patch from Alexander Kuznetsov: Toggle selection rather than just extending.

Implements behaviour that unintendedly was available with previously using macro operator for selection. This was removed and now the functionality is properly implemented.

Patch accepted with minor changes:
1. Used enum rather than #defines and added value for removing from selection (deselect)
2. Moved if (select) outside file_select_do and improved check for whether last file in selection is actually selected. (Necessary since toggle can deselect and toggle select should still make file active)
3. Additionally fixed check in file_select_invoke to be consistent with border select.
2011-03-20 10:22:51 +00:00
5442e725a5 print how many times the operator failed. 2011-03-20 09:38:25 +00:00
790e47768a fix for crash when running WM_OT_read_factory_settings() from a script and then importing. 2011-03-20 07:23:17 +00:00
35cee79a37 fix so the batch importer can run with addons passed as arguments. 2011-03-20 06:02:47 +00:00
283bac0073 fix for --addons startup argument, string length was too short. 2011-03-20 04:44:03 +00:00
733b736e9e CMake, check for clang++ compiler and disable WITH_IK_ITASC and WITH_MOD_FLUID until there supported.
possibly allows builing with Xcode4.
2011-03-20 01:49:15 +00:00
ef9356043e == file browser ==
Patch from Alexander Kuznetsov: Real-time File Selection, thanks for the contribution.

Still made a few minor changes from latest patch:
1. Rename SELECTEDFILE to HILITED_FILE, since we are not actually selecting the file, but previewing/highliting the possible selection.
2. Also made this clearer by not drawing the files as selected, but just highlight them.
3. Removed the Select/Deselect toggle when clicking on file, will be committed separately soon.
2011-03-20 00:34:08 +00:00
35dbf67c00 Fixing the other crash mentioned in bug #25083. m_current_scene isn't always pointing to valid memory by the time LinkBlendFile is called. So, use the supplied scene_merge scene instead. Scene LibLoad was already doing this, so I just made Mesh and Action follow suit. 2011-03-19 22:47:51 +00:00
815a795be9 Fixing 1/2 crashes mentioned in bug #25083. This crash happens when LibLoad tries to grab bad mesh data from a previous Load/Free via FindGameMesh(). FindGameMesh() makes use of m_map_mesh_to_gamemesh, so the mesh needs to be removed from this on free. 2011-03-19 22:37:27 +00:00
647f4246da Todo item:
Improving UI visualization of using Material nodes:
- Property editor: the context top line now shows the linkage path
  (in material and texture view mode)
- Activating new material node refreshes preview in property editor
  when in texture mode.

This should make editing textures with node materials a bit more clear.
2011-03-19 18:23:21 +00:00
5179a0c477 Code comments only
Tried to resolve todo item "Layer change in 3d view header doesn't update
dependencies on changed previously visible objects". Code is too much spread
around now though, and the 3d view header shares RNA code for changing layers.

I'll let this be a "glitch" for now.
2011-03-19 16:30:52 +00:00
e134e0139f ugh, left in a debug print in the previous commit 2011-03-19 13:36:43 +00:00
074f584cd2 Bugfix #26547
Missing DAG_id_tag_update() on tool "Align Camera to View".
2011-03-19 13:36:36 +00:00
f15c12a0d2 Fix for [#26546] Particles leak through deforming quad mesh
* Slightly too strong optimization in the new collisions code, the "edges" in the middle of quads weren't checked at all.
2011-03-19 13:33:03 +00:00
cadc1218c8 C, style changes (mostly white space edits), no functional change. 2011-03-19 11:12:48 +00:00
ff1656175a Fix #26543: lamp sky settings were missing soft/linear light blend types,
made enum items shared with material ramp and mix node.
2011-03-19 10:26:15 +00:00
e9005b985e remove some redundant vars, assignments & checks. 2011-03-19 05:06:06 +00:00
3b8d4aa25f 2 tests for ctest.
- script_load_addons: loads and onloads all addons, error if any cant be enabled or disabled.
- script_load_modules: loads all blenders modules, error if any modules raise an exception or if any modules in the scripts dir are not tested (except for presets and templates).

These are useful because lazy module loading means a module can have an error which isnt raised until the tools used. This gives a way to detect basic errors that used to happen on startup or when enabling the addon.
2011-03-18 23:58:13 +00:00
5f8e8f2251 Safety checks for macro defines 2011-03-18 23:14:24 +00:00
Nathan Letwory
21b2f94235 Fix [#25480] Unable to use Windows titlebar icons after Loopcut
reported by Georg K
with patch [#26469] Windows mouse fix
by Alexander Kuznetsov

The amount of mouse grabs wasn't properly balanced with ungrabs, thus preventing from using proper mouse input outside client area.
2011-03-18 21:59:45 +00:00
e44da6b695 hide addon_utils in bpy.utils & tag/remove unused vars in recent commits. 2011-03-18 20:57:32 +00:00
b66f7a471c Fix for [#25878] UV Scale/Rotate/Grab break with non grid snapping.
* The selected uv-vertices (the ones being transformed) weren't being disregarded as snapping targets, so moving two verts that were in the same location together was impossible.
2011-03-18 16:35:42 +00:00
eeb94697d5 Bugfix #26462
Using "search menu" for browsing ID data (material, texture, brush)
wasn't sending an undo-push after use. This messed up undo or redo.
2011-03-18 16:09:29 +00:00
60ce95f562 New particle collisions code:
* The old collisions code detected particle collisions by calculating the
  collision times analytically from the collision mesh faces. This was
  pretty accurate, but didn't support rotating/deforming faces at all, as
  the equations for these quickly become quite nasty.
* The new code uses a simple "distance to plane/edge/vert" function and
  iterates this with the Newton-Rhapson method to find the closest particle
  distance during a simulation step.
* The advantage in this is that the collision object can now move, rotate,
  scale or even deform freely and collisions are still detected reliably.
* For some extreme movements the calculation errors could stack up so much
  that the detection fails, but this can be easily fixed by increasing the
  particle size or simulation substeps.
* As a side note the algorithm doesn't really do point particles anymore,
  but uses a very small radius as the particle size when "size deflect" isn't
  selected.
* I've also updated the collision response code a bit, so now the particles
  shouldn't leak even from tight corners.

All in all the collisions code is now much cleaner and more robust than before!
2011-03-18 15:31:32 +00:00
Nathan Letwory
7e53769d09 COLLADA conformance: don't write empty libraries for effect, image and animation 2011-03-18 14:06:13 +00:00
Nathan Letwory
b4743ccd8f Fix for crasher on Win XP, submitted by Kanttori.
size is 32 on XP, while sizeof(ri) gives 40. Pick the smaller one to pass to memcpy to prevent crashes.
2011-03-18 13:36:52 +00:00
879be45bb5 fix for building on ubuntu 11.04 (pre-release), also remove WITH_INSTALL from cache. 2011-03-18 12:12:53 +00:00
0a52b86d50 fix for [#26533] didnt take scene strips into account, tested copy/pasting scene strips now works with audio. 2011-03-18 10:35:17 +00:00
ac1fa5bb42 fixed [#26533] Audio strip mute after copy/paste 2011-03-18 08:40:19 +00:00
1fec2d179f fix [#26510] Crash when changing an object's property value 2011-03-18 06:36:57 +00:00
2c13a6fab8 while looking into a problem in interface.c, noticed ui_get_but_val() is called frequently when the return value isn't used (no functional change). 2011-03-18 05:42:16 +00:00
a0c8727b34 fix for using freed memory with modal grease pencil draw. 2011-03-18 02:44:40 +00:00
faafd4634a fix for error in r35590, ARRAY_LAST_ITEM was returning one item over the end of the array. 2011-03-18 02:09:59 +00:00
25d4515181 fix [#26532] Does not save in specified format
old bug from r6568 (or before) in BKE_write_ibuf(), when passed TAGA format it would use whatever format the image buffer already had.
expect this is exposed by updated image saving code in 2.5x.
2011-03-18 00:12:51 +00:00
35dae4f0b5 add sphinx api reference note that menu's layout.operator_context defaults to EXEC_REGION_WIN rather then INVOKE_DEFAULT. 2011-03-17 22:49:46 +00:00
Nathan Letwory
a84e43c48b COLLADA: Don't write empty libraries for geometry, lights, cameras, controllers 2011-03-17 16:40:53 +00:00
27abad190a Bugfix #26483
Two small draw fixes to make the giant preview-image search-menu draw
correctly. (previews were drawing over a button)
2011-03-17 14:52:01 +00:00
e0871e07df bugfix [#26502] segmentationfault on pressing button to browse existing images for UV window
really old one!, since initial commit blender would crash scaling down large sizes eg: 60962 -> 128 (width or height).

the problem is scaledownx/y doesn't check buffer endpoints, with really large images theres a loop on a float value which can fail with large image sizes.

previous commit added asserts if the buffer runs over (assuming it doesnt crash),
This commit changes an epsilon value, tested this with random small images as well as images over 200,000 px, and it works fine, this is still flakey though and for really really big images it probably still fails.
2011-03-17 11:08:25 +00:00
172f3337ce BLI_assert's for when scaledownx / scaledowny don't use the buffer correctly (theres a buffer overrun here [#26502]). 2011-03-17 10:37:48 +00:00
Lukas Toenne
4c3dea8a2e Small tooltip change to better indicate the purpose of the node name string and moved the node label button to the top, since this is usually what user will want to edit instead of the identifier name. 2011-03-17 10:31:20 +00:00
Lukas Toenne
afd8865181 Added an optional label string to nodes. As pointed out by Sebastian Koenig, some nodes (in particular render layer nodes) need custom labels, but it is not possible to make any useful generic abbreviation. The label string can be used as a custom user-defined label in this case, without the ugly .xxx extensions needed for unique node names. When the label string is empty, the default type label will be used. 2011-03-17 10:11:12 +00:00
e3842d1ca4 Bugfix [#26505] zoom in selected keys on graph editor
Not really a "bug", but it was on my todo anyways. Based on patch
[#26508] by Campbell, with a few modifications including extending
this to the Action/DopeSheet editor too.
2011-03-17 10:02:37 +00:00
58c8dca7a6 missed removing WITH_INSTALL reference. 2011-03-17 09:09:48 +00:00
33047585ea add cancel() method for python defined operators. 2011-03-17 07:02:02 +00:00
0277073579 error with TIMEIT util define. 2011-03-17 06:57:12 +00:00
719afd2622 changed short's to int's image scale and flip functions (images can be bigger then short range) 2011-03-17 05:15:54 +00:00
197e903efc fix for [#26524] Api autocomplete more errors
problem was caused by change in python behavior, now hasattr(val, attr) only suppresses attribute exceptions.
2011-03-17 04:43:58 +00:00
63099d41b5 Bugfix: Grease Pencil paint didn't clean up properly after error-exits
This manisfested as an inability to draw any more strokes after trying
to draw a stroke while the active layer was locked and then unlocking
that layer to try and draw on it again.
2011-03-17 02:53:56 +00:00
3ac925b7d1 fix own error - missing NULL check [#26523] Crash when load factory settings ( linked to rigify add-on ? ) 2011-03-16 22:25:31 +00:00
dc5a78ac25 fix own error [#26522] Api autocomplete return many errors
collections were getting __call__ attribute from the StructRNA, now ignore all starting with '_'
2011-03-16 21:58:45 +00:00
4f5e20aeb4 remove cmake WITH_INSTALL option since its a target now. 2011-03-16 21:32:20 +00:00
6c972d634e BGE PhysicsConstraints.exportBulletFile improvement: also export the object names to .bullet files. 2011-03-16 21:20:24 +00:00
67c7fa46db == filebrowser ==
People had trouble finding the 'Create New Directory' operator button in the file browser. Changed this to show the text as well and make button bigger.
2011-03-16 21:05:24 +00:00
6dda182a76 Fix for [#26520] Point Density turbulence not accessible in Texture Properties.
* Mistake in the ui file.
* Also found a possible memory leak.
2011-03-16 18:21:31 +00:00
bcee2343ea Mac OS X cmake changes and bundle fixes
For cmake users, you should now use "make install" instead of "make". This was
already changed for Linux and Windows. Same for Xcode, use the install target.

Changes:
* CMake install mechanism, resulting bundle was verified to be indentical here.
* For cmake, include Info.plist in bundle using builtin mechanism for that.
  There was some code in packaging.cmake, but it wasn't correct as these
  properties need to be set on the executable.
* For scons, fix app bundle version, was still using removed release/VERSION.
* Remove unused blendercreator.app and blenderpublisher.app.
* Fix Info.plist being set as a binary file in svn, should be plain text.
2011-03-16 15:44:17 +00:00
6e4be608ff Bug fix: Changing volume texture properties after render crashes (reported by mats on irc)
* Preview render copied the volume texture, but not the actual volumedata, so normal render and preview render clashed.
2011-03-16 14:21:35 +00:00
8b9615caa0 Fix for [#26516] Blender crashes for Particle Physics Path Editing.
* Silly own mistake from some previous code cleanup.
2011-03-16 13:03:05 +00:00
c32ca47c6f redo panel now runs check() function when defined, filesel and popup dialog were already doing this. 2011-03-16 12:21:20 +00:00
1787fdbeed update x3d test md5s for recent changes, also ensure directory is created or export tests fail. 2011-03-16 12:06:12 +00:00
da18391ac4 api function added for [#26481] Export to X3D of IndexedFaceSet should use X3D 's DEF USE mechanism
Object.is_modified(scene, 'PREVIEW') function for python exporters to check if any modifiers or shape keys are applied (weather the original mesh can be used for exporters).
2011-03-16 08:53:35 +00:00
934c2a06fe Fix nan / black dots in image textures in some corner cases. 2011-03-16 01:16:43 +00:00
6588bcbbe0 CMake, GCC: replace -Werror=strict-prototypes with -Wstrict-prototypes, some external headers cause this. 2011-03-15 22:30:07 +00:00
2b5f8c94d0 changes to icon loading
- look for icons in datafiles/icons (was looking in datafiles)
- was loading all images in datafiles/ on startup to check if they were the correct icon size, commented this since its unnecessary disk overhead on startup & images are checked for correctness when used anyway.
  when running blender from the source dir would load splash.png every time.

also add missing NULL pointer check if the icon couldn't be loaded and ensure no buffer overflow check on icon path creation.
2011-03-15 22:24:47 +00:00
Lukas Toenne
6864fcba30 Small safety fix: clear temporary link list in node space when copying. 2011-03-15 19:55:45 +00:00
b8f96b191b "Fix" #26445: edit mode vertex distortion
Discussed with Campbell, it's not actually bug and it's more about limitation
of topology mirror. It will work properly when both sides of mesh have matching
unique topology.
Added note to tooltip, so now unpredictable behaviour shouldn't confuse users
so much.
Also gray out "Topology mirror" when "X Mirror" is disabled.
2011-03-15 09:04:26 +00:00
2bd375dd52 fix for crash with textbox add poll function, missing NULL check. 2011-03-15 08:38:08 +00:00
b65a56ccb5 fix [#26494] Auto run Python scripts option in User Preferences problem
- opening a file with blender by passing it as an argument would and loading it once in blender left script auto execute flag in a different state.
- command line args --enable/disable-autoexec were being overridden by the user prefs.
2011-03-15 08:04:11 +00:00
b332a27429 use defines for BKE_read_file, no functional change. 2011-03-15 05:00:10 +00:00
5aa76a8c88 fix [#26507] Rename bone -> segfault 2011-03-15 03:38:15 +00:00
2113450ac5 fix [#26504] Deselection of vertices not working in UVs editor 2011-03-15 03:13:17 +00:00
ed0167175b bugfix [#26505] zoom in selected keys on graph editor
measure uv vertex distance in screen pixels rather then image.
2011-03-15 03:02:12 +00:00
fe529d43fe fix for building on some configurations. 2011-03-15 01:48:01 +00:00
3d0a7fdccb workaround for problem compiling with glu 1.5.8 on windows 2011-03-15 01:31:07 +00:00
1e60d5136a upgrade glew 1.5.1 --> 1.5.8, from the release logs changes are mainly for maintenance & supporting new opengl functions, this also fixes FreeBSD compile error. 2011-03-15 00:08:16 +00:00
4c3b8f0f7d fix [#26503] Copy Mirrored UV coords exception 2011-03-14 23:52:50 +00:00
82783cd0cd pep8 edits and remove commented code from last commit. 2011-03-14 23:17:52 +00:00
f2b1645a75 fix/disallow [#26502] segmentationfault on pressing button to browse existing images for UV window
creating RNA within draw functions can free existing RNA, crashing blender when this is already used in the UI.
disallowing this so it raises a python exception.

This was being used to dynamically generate addon categories so for now they are hard coded and we need proper enum-functions for python to do this.
2011-03-14 23:02:47 +00:00
eb53b0fb4c quiet warning for GCC 2011-03-14 22:16:35 +00:00
af66a4630d fix [#26478] New image extension is appended to the old one instead of replacing it
Note: 
Extension is replaced with the new extension if it's a known image extension.
Brings back old behaviour, a little bit refined.
2011-03-14 21:13:30 +00:00
41c27cd6ef == filebrowser ==
Cleanup of selection code.
Also fixed bug where selection outside the tiles was clamped and file in last column was selected.
2011-03-14 19:56:13 +00:00
d789484dc7 Fix for [#20171] Properties of Hair are not animateable
* Don't know when this got broken again, but now the "regrow hair" option works like it's supposed to again.
2011-03-14 17:37:51 +00:00
1c952cd933 GNUmakefile: do number of cores detection same as BSD, system_profiler apparently changed between versions. 2011-03-14 16:11:56 +00:00
Ken Hughes
f4e16def46 Build system
------------
Allow BF_PYTHON_ABI_FLAGS to be specified on the command line for scons.
2011-03-14 16:10:35 +00:00
c13947fe33 Fixes for GNUmakefile on Mac:
* Don't use "make install", doesn't work yet.
* Use total number of cores rather than number of processors.
* Quicker number of cores query, by not asking for all system info.
2011-03-14 15:40:07 +00:00
7e69bad1c3 Bugfix #26498
CTRL+L "Make Links" operators were not using a correct poll(), causing
crash on using it without active object.
2011-03-14 14:00:15 +00:00
7609370d50 Bugfixes:
- Sync Markers option works for local markers (or any other list of
markers in future) too now.
- Apply Pose to Restpose operator now displays a warning if an action
was found (warning about the action now being invalid)
2011-03-14 10:45:42 +00:00
2d1ef275f2 bpy.types.libraries.load sphinx doc & examples (doc system needed some updates).
http://www.blender.org/documentation/blender_python_api_2_56_3/bpy.types.BlendDataLibraries.html#bpy.types.BlendDataLibraries.load
2011-03-14 10:31:50 +00:00
Lukas Toenne
80d1bb5fcd Measure of precaution: clear the list of temporary links in the node space after loading, in case the file was saved during active modal linking operators. 2011-03-14 07:30:49 +00:00
b0a9dbf9c8 auto-complete was moving the selection. 2011-03-14 06:48:51 +00:00
4a747bebf4 fix [#26489] Auto completion in console broken
own mistake in r35492.
2011-03-14 05:39:07 +00:00
e8174fb3cd move mathutils api changelog into wiki. 2011-03-14 05:03:53 +00:00
7283e7cf11 change addon defaults.
- export uv layout enabled.
- 'render_netrender' enabled (still needs being made into an addon).
- export camera data disabled.
2011-03-14 03:49:38 +00:00
aee5f0e20f patch [#26495] Adjustable outline width for selected objects 2011-03-14 03:34:57 +00:00
e263657df7 tag var as unused. 2011-03-14 03:33:21 +00:00
f96a1546c0 Bugfix: "Sync Markers" option in Action Editor is now a bit more
useful.

Instead of only working for the "extend" transform mode, standard
transforms now work too now (i.e. grab and scale).

TODO:
This currently only works on Scene markers, though it should be
possible to make this work on a provided list of markers instead...
2011-03-14 03:10:23 +00:00
bd1c5d48f2 RNA API Rename
'create' was used as prefix and suffix, change dupli list functions to use as suffix, this matches obj.animation_data_create() & obj.animation_data_clear().
 obj.create_dupli_list() --> obj.dupli_list_create()
 obj.free_dupli_list() --> obj.dupli_list_clear()

Don't use 'create' for object to mesh function since other uses of this are for createing data which stays attached, instead use mathutils style naming convention.
  obj.create_mesh() --> obj.to_mesh()
2011-03-14 01:37:18 +00:00
9ec2dfe0df add dir() function for library objects, also was missing call to clear temp flag on exceptions. 2011-03-14 01:00:41 +00:00
6cab58c8b9 Readme file:
* 2.56 > 2.56a and 1 grammar fix.
2011-03-13 22:35:54 +00:00
Lukas Toenne
05b2a75bfe Group tree sockets were not being freed after removing. 2011-03-13 22:13:42 +00:00
Lukas Toenne
24f72abf67 Fix for crashes due to links without fromnode pointers. This can happen with "unfinished" links created during the modal linking operator or when creating links from group tree inputs.
In addition don't store unfinished links in the nodetree->links list any more. This makes code a bit safer because all links in that list can be considered valid now. The temporary bNodeLinkDrag structs used by the modal linking operator are now also stored in a list in SpaceNode, so these links can be drawn too (this separation also allows different display of temporary links, e.g. currently they are drawn on top of all nodes).
2011-03-13 22:07:55 +00:00
1e4010cad6 * Small code cleanup/removal 2011-03-13 20:39:15 +00:00
Lukas Toenne
2907826d8c Fixed the node_recurs_check function used to define the order of nodes in ntreeSolveOrder. This was creating equal node levels in some cases (auto-linking viewer to nodes further downstream), leading to falsely detected circular dependencies. 2011-03-13 17:23:44 +00:00
70340503d8 fix mistake from commit rev. 33868. The variable icon was a pointer, not an integer icon id (ICON_NONE). 2011-03-13 17:20:52 +00:00
5f7126c96f Fix "make test" on Mac, couldn't find executable. 2011-03-13 13:09:18 +00:00
128bed8480 RNA: use a different method to set DNA types for BlendData* collections, to
solve issues with c++ api.
2011-03-13 13:01:02 +00:00
280592be9f Replaced RNA code in previous commit with a version which should be a
bit safer (less likelyhood of float <-> int corruption)
2011-03-13 12:26:53 +00:00
2144b23f51 Pose Sliding Tools - Custom Property Support + Other bugfixes
- Custom properties are now affected by the Pose Sliding tools too.
This is now more important to support, given that modern rigs use
these a lot for facial expressions/posing. By and large, this should
work fine, though discrete integer values may experience a bit of
trouble

- Fixed potential bugs with the code which detects which F-Curves are
relevant to a PoseBone's transforms (+ custom props). This was prone
to being tricked by certain setups if the names of the bones contained
some of the keywords these were searching for.

- Shuffled some code around: moved bulk of logic out of vec3 case into
new function for single-value, since it was really doing per axis
already
2011-03-13 12:22:57 +00:00
4cfa5d55e6 rna/api: new bezier keys added via fcu.keyframe_points.add() now use auto handles and bezier interpolation. 2011-03-13 09:52:49 +00:00
cf8cc39d4c Make BF_PYTHON_ABI_FLAGS a scons option. Default flags are empty.
Made changed to linux2-config and freebsd*-config. Windows/MacOS are kept
unchanged.

I'm not sure which flags should be used for freebsd systems, so flags for
them also kept empty. Maintainers of this platform, please check which
flags should be used and make changes to rules.
2011-03-13 09:29:47 +00:00
0c734577f4 Bugfix [#26484] delete keyframe in pose mode --> segmentation fault 2011-03-13 09:27:28 +00:00
42c2654d0e Inconsistent use of array_index vs index with animation keyword args.
Settle with 'index' even though the attribute is array_index.
2011-03-13 06:44:40 +00:00
ca95a6f415 - lightmap pack wasnt reporting no mesh errors properly.
- cleanup headers.
- cmake on *nix was always writing to /bin/./2.56
2011-03-13 06:02:20 +00:00
6559209dbf [#26482] Solidify / Animation Opengl render. no texture.
workaround for view3d datamask not being correct on opengl render.
2011-03-13 02:44:25 +00:00
25a2eb4675 py/library api: raise an error if a requested member isn't found. 2011-03-13 01:15:14 +00:00
60a2994435 SVN maintenance. 2011-03-13 00:26:46 +00:00
ed81c7755a quiet stricter compiler warnings/errors. 2011-03-12 23:41:57 +00:00
15063f0602 Bugfix [#26473] Keyframe values for F-Curves were incorrectly wrapped
in RNA as "translation" values, which implies dimensionality is
incorrect here as F-Curves do not specifically "know" about the type
of the data they affect
2011-03-12 23:07:00 +00:00
d190304c82 Fix for compilation error after bullet upgrade.
There was a typo in source file list.
2011-03-12 22:05:33 +00:00
5e374328a8 update Bullet physics sdk to latest trunk/version 2.78
add PhysicsConstraints.exportBulletFile(char* fileName) python command
I'll be checking the bf-committers mailing list, in case this commit broke stuff
scons needs to be updated, I'll do that in a second.
2011-03-12 20:34:17 +00:00
8c526e79e3 library loading api.
this is not well suited to RNA so this is a native python api.

This uses:
  bpy.data.libraries.load(filepath, link=False, relative=False)

however the return value needs to use pythons context manager, this means the library loading is confined to a block of code and python cant leave a half loaded library state.


eg, load a single scene we know the name of:
  with bpy.data.libraries.load(filepath) as (data_from, data_to):
      data_to.scenes = ["Scene"]


eg, load all scenes:
  with bpy.data.libraries.load(filepath) as (data_from, data_to):
      data_to.scenes = data_from.scenes


eg, load all objects starting with 'A'
  with bpy.data.libraries.load(filepath) as (data_from, data_to):
      data_to.objects = [name for name in data_from.objects if name.startswith("A")]

As you can see gives 2 objects like 'bpy.data', but containing lists of strings which can be moved from one into another.
2011-03-12 16:06:37 +00:00
ce5c1466a1 2.5 Fluid UI Python Script:
* Code cleanup, no UI changes, reduced code from 1244 lines to 1228 lines.
2011-03-12 15:24:16 +00:00
90d42e114c py/rna: BPy_reports_to_error() now takes the exception type as an argument and returns -1 as an error value 2011-03-12 15:18:08 +00:00
a5e59ede6e pass report list along to BLO_blendhandle_from_file(), avoid unlikely crash in the append operator. 2011-03-12 15:15:40 +00:00
f6b21ecf84 More on bug #26432
More undo-push disabling for switching render slots.
Also added 'undo push' print in debug mode (blender -d)
2011-03-12 15:09:29 +00:00
a416949382 - BKE_idcode_iter_step() - function to step over all ID codes.
- BLO_blendhandle_get_datablock_names() now takes an arg for the total items in the list, saves the caller counting.
2011-03-12 14:38:00 +00:00
c678bd2d7d py/rna, ability to have python static methods in collections. 2011-03-12 14:32:30 +00:00
460bdf1f59 tag/comment unused variables. 2011-03-12 14:21:04 +00:00
3c86933886 Bugreport #26464
Added more clear tooltip to render as B&W file option.
This only works now for PNG, JPEG, TGA and TIFF
2011-03-12 14:14:19 +00:00
9b2f0dadb9 Fix uvedit unwrap tool not taking selection into account. 2011-03-12 13:15:09 +00:00
5b75593c23 Completely refactored sph fluid particles. Only the very core of the algorithm remains
the same, but big changes have happened both on the outside and on the inside.

New UI:
* The old parameters were quite true to the underlying algorithm, but were quite obscure
  from a users point of view. Now there are only a few intuitive basic parameters that
  define the basic fluid behavior.
** By default particle size is now used to determine the interaction radius, rest
   density and spring rest lengths so that it's easy to get stable simulations by simply
   emitting particles for a few frames and adjusting the particle size (easy when the
   particle size is drawn) so that the fluid appears continuous (particles are touching
   eachother).
** Stiffness - in reality most fluids are very incompressible, but this is a very hard
   problem to solve with particle based fluid simulation so some compromises have to be
   made. So the bigger the stiffness parameter is the less the fluid will compress under
   stress, but the more substeps are needed for stable simulation.
** Viscosity - how much internal friction there is in the fluid. Large viscosities also
   smooth out instabilities, so less viscous fluids again need more substeps to remain
   stable.
** Buoancy - with high buoancy low pressure areas inside the fluid start to rise against
   gravity, and high pressure areas start to come down.

* In addition to these basic parameters there are separate advanced parameters that can
  either be tweaked relative to the basic parameters (or particle size) or defined
  independently.
** Repulsion - the stiffness parameter tries to keep the fluid density constant, but this
   can lead to small clumps of particles, so the repulsion keeps the particles better
   separated.
** Stiff viscosity - the normal viscosity only applies when particles are moving closer to 
   eachother to allow free flowing fluids. Stiff viscosity also applies smoothing to
   particles that are moving away from eachother.
** Interaction radius - by default this is 4 * particle size.
** Rest density - by default this is a density that the particles have when they're packed
   densely next to eachother.
** Spring rest length - by default this is 2 * particle size.

* There are also new options for 3d view particle coloring in the display panel to show
  particle velocity and acceleration. These make it easier to see what's happening in the
  fluid simulations, but can of course be used with other particles as well.

* Viscoelastic springs have some new options too. The plasticity can now be set to much
  higher values for instant deletion of springs as the elastic limit is exeeded. In addition
  to that there is an option to only create springs for a certain number of frames when a
  particle is born. These options give new possibilities for breaking viscoelastic fluids.

New in the code:
* Most of the fluids code is now thread safe, so when particle dynamics go threaded there
  will be a nice speed boost to fluids as well.
* Fluids now use a bvh-tree instead of a kd-tree for the neighbor lookups. The bvh-tree 
  implementation makes the code quite a bit cleaner and should also give a slight speed
  boost to the simulation too.
* Previously only force fields were calculated with the different integration methods, but
  now the fluid calculations are also done using the selected integration method, so there
  are again more choices in effecting simulation accuracy and stability. This change also
  included a nice cleanup of the whole particle integration code.

As the internals are pretty stirred up old particle fluid simulations will probably not
work correctly straight away, but with some tweaking the same level of control is still
available by not using the "relative versions" of the advanced parameters (by default these
are not used when loading old files).
2011-03-12 12:38:11 +00:00
60fe23b100 cmake, search $HOME/py32 for python now too. 2011-03-12 04:39:43 +00:00
42e9796c04 builder reports MSVC was setting stack size to 2gig. 2011-03-12 04:31:28 +00:00
bbf6603961 == Sculpt ==
* Removed some fields from struct SculptSession:
  - Fields drawobject, projverts, and previous_r were completely
    unused
  - Field `ob' was really unnecessary, changed sculpt functions
    to pass the object rather than the SculptSession

This removal of `ob' from SculptSession should should make it a little
easier to continue generalizing paint/sculpt functionality.

There should be no visible changes from cleanup.
2011-03-12 02:12:02 +00:00
80de27914d Bugfix [#26222] Alt-O (smooth) in Graph editor destroys fcurve handle
type and data

Recoded Keyframe Smoothing operator to work better for continuous
curves (i.e. ones with monotonically increasing slopes in sections) as
opposed to hypothetically jagged ones.

The old method assumed that handles should be flat as otherwise, you'd
often get unsmooth curves just because you went and tilted some of the
handles for local extrema, causing some unkeyframed overshoots, which
also leads to changes in timing, which in turn often means unsmooth
motion. Hence, the code took advantage of this to do things with less
extra data.

However, now we have a proper "flatten handles" tool (under snap ->
horizontal) so this functionality is not needed in the general case
where it will lead to stair-stepping artifacts.
2011-03-12 01:09:40 +00:00
c786a2c805 edit scons to use py3.2 on all os's and use 'm' abiflag on linux since this is the most common. 2011-03-12 01:03:15 +00:00
a001b3f072 set 2mb stack for mingw too. 2011-03-12 00:50:34 +00:00
06a763f9d7 Fix #25931: strand render + ray traced AO give tile image. The random numbers
for sampling were not consistent, now the RNG is seeded per strand, and some
tweaks were done to make the jittered sampler cache return consistent sample
numbers for strands.
2011-03-12 00:16:55 +00:00
Nathan Letwory
92665b0a51 Fix [#25659] crash when unwrapping specific mesh
Reported by Jan Hohoho

Running the unwrap causes stack to overflow. Double the size from default 1MB.
2011-03-11 23:27:15 +00:00
c30708c47c Fix #26035: fix crash building raytree with inf/nan values in raytree. There's
many different checks here, but I couldn't handle all cases in fewer lines.
2011-03-11 23:12:58 +00:00
9dfda4b002 Fix #26203: crash with empty raytree, all types should survive this now.
Also added a check for -inf/inf bounding boxes, just to be sure.
2011-03-11 22:27:06 +00:00
Nathan Letwory
60a4c9d09e Some explicit casts to silence warnings (unsafe to mix int and bool in comparisons). 2011-03-11 22:06:18 +00:00
977fdc5a56 Fix #25654: strand render with instanced objects was not working right,
some coordinates didn't have the instance matrix applied, while others had
it applied twice.
2011-03-11 21:37:17 +00:00
44692c70ae Bugfix, irc report:
Pressing ESC on material icon preview changes made it stop updating
the icons. Was caused by default 'break' callback testing ESC and
not resetting it. Now it uses same break callback as other previews.
2011-03-11 17:59:40 +00:00
719bf206b4 Bugfix #26444
Double click in File Window also loaded a file on double-click at
a directory.

The operator for it was using a Macro mistakingly here. On any double
click, it selected the item first and then executed load.

By default, any double click action has to rely on the first click 
being properly handled before. Simply removing this macro, and assign
the "exec operator" to the double-click event works as expected.
A double click on a directory then just shows the dir (because the exec
requires an 'active' file item).
2011-03-11 17:01:29 +00:00
01b547f993 Fix for [#26457] Physics Size attribute affects hair particle DupliObjects while hidden
* Forgotten settings for the "simple hair" ui.
2011-03-11 11:15:35 +00:00
a62f7422ff move do_version code under latest subversion bump. 2011-03-11 09:35:16 +00:00
102c5e0ad4 2011-03-11 07:59:43 +00:00
bfe5a6ed8f fix [#26448] Solidify Modifier makes mesh texture missing in OpenGL render 2011-03-11 05:23:56 +00:00
ffb4cf6b32 Bugfix [#26167] Animating inside group nodes behaves strangely
One node update call (for nodes within group nodetrees) was using the
wrong nodetree (node-editor's nodetree, not the group) which meant
that the wrong RNA context for such nodes would get used, resulting in
errors when trying to keyframe such nodes.

Hopefully this is the last time I have to fix these bugs...
2011-03-11 03:27:38 +00:00
Nathan Letwory
dec585cb94 Fix a typo in defines. Patch by Alexander Kuznetsov
The typo resulted in bad keyboard input handling in MinGW builds.
2011-03-11 02:58:37 +00:00
d7257a983f bugfix [#26454] WITH_PYTHON_SAFETY crash. 2011-03-11 02:43:30 +00:00
bc97f88576 Better progress info for physics baking:
* Using the job system for physics baking is not yet in the near future, so here's some good old console based progress info to all point cache based physics baking.
* The info contains current total bake time, baking time for the current frame, and a simple estimate of completion time.
* The info is only shown if the estimated total time for the bake is higher than one minute, so quick bakes don't suffer any performance hits due to console printing.
2011-03-11 02:00:05 +00:00
9c032756e9 when checking for windows check sys.platform starts with "win" rather then '== "win32"' & avoid importing platform.
also add some notes to CMake options.
2011-03-11 01:24:16 +00:00
1008137f72 simplify BLI_path_abs by using BLI_cleanup_path 2011-03-11 01:06:16 +00:00
d6ca95b1a3 fix [#26451] Little problem when selecting relative output path
BLI_path_rel() no longer strips trailing slashes.
2011-03-11 00:30:51 +00:00
cda0460c89 Bugfix [#26438] : While grabing a marker with G, cancelling with Esc
does exit cancelling the translation (as expected), while RMB doesn't,
it works same as LMB

This should fix the remaining issues with marker tweak-grab mappings
(hardcoded for right-mouse for now)
2011-03-11 00:18:10 +00:00
6959536abe fix [#26452] Problem with key properties when OnlySelectedCurveKeyframes option enabled. 2011-03-10 23:55:22 +00:00
b79762a7c3 Bugfix [#26438]: Hotkey conflict between add meta-strip and add marker
The sequencer made it's own copy of the Markers keymap, which was
inconsistent with the rest of Blender, making things confusing to use.
I've removed these duplicate keymap entries, and also changed the
conflicting hotkeys for Metastrips.

Metastrips now use the same hotkeys that their NLA cousins use:
Shift-G to add, Alt-G to remove; These were chosen since in user-
terms, metastrips are more like "strip groups"
2011-03-10 23:26:59 +00:00
ef8aa6cc6a fix [#26436] Operator.draw(): UI redraw; UI trimmed 2011-03-10 22:22:47 +00:00
Nathan Letwory
d6b43fed31 Fix [#26446] Quick extrude (Ctrl+LMB) works only one time
Reported by Michael R

This was one thing I didn't test when accepting patch [#26364]. It is important to not
send repeats of modifier keys.
2011-03-10 18:56:19 +00:00
efc697b481 Bugfix #26443
Node compositor crash:
When you very quickly unlink a socket *right* after connecting it
(within 0.1 second), the compositor started with a noodle without
valid connections, which was not foreseen to happen.
2011-03-10 18:17:20 +00:00
9a622f18ac Bugfix #26424
More problems with Undo and Render Slots (Image editor)

- Undo storage for operator is now back, but only when new
  buffers were added (not when viewing existing)

- A real bug: On undo/redo, the stored buffers were never
  retrieved, but always freed entirely.

Note however that when you undo back to a state before you
rendered (or added slots), the render buffers that didn't
exist back then also get freed. A redo doesn't bring it back.
2011-03-10 17:34:27 +00:00
a836390426 Todo:
Fixed name and tooltip for new "render output" option. It does draw output,
but just doesn't change your UI layout.
2011-03-10 16:36:16 +00:00
1c3679a5b0 fix [#26442] blender crash when turning off antialiasing fonts
ASCII lookup table wasn't being freed when when the rest of the glyphs were.

Also found own bug where mesh stat text was using wrong sized array (char[3] as char[4]).
2011-03-10 13:49:46 +00:00
188c4ae055 Bugfix #26442
Very bad crashing in using "Not AA fonts" and drawing length info
on EditMesh. This uses the call BLF_draw_ascii() which apparently
corruptes then badly. Disabled the call for now, and wait for fix.

In the course of testing, added proper strlen storage for draw
in this code.

Added strlen
2011-03-10 12:52:18 +00:00
f13ae69bcd Fix for [#26441] Child Hair Crash
* Silly mistakes in my last particle distribution code commit.
2011-03-10 12:36:11 +00:00
695f35387b Bugfix irc report:
With draw method "Overlap", the preview line for menu "Split area" was not
correctly visible.
2011-03-10 11:47:36 +00:00
476eadbcb1 Bugfix #26437
- Tooltip-hanging fix made the 'active' button be removed when mouse
  enters another subwindow. Caused by commit of a week ago.

- Reverted the eventsystem change that sets 'active subwindow' before
  it calls modal handlers. This made editors become active on using
  menus, buttons, or other modal ops.

  Side effect is that for transform operators called via toolbar, the
  overlay-extra draw with helplines now gets skipped. Will check on
  good ways for it.
2011-03-10 11:11:26 +00:00
0e74ed5952 fix [#26406] Projection Paint, Occlussion Problem with Intersections in perspective mode. 2011-03-10 08:51:41 +00:00
d59e208216 also enable edge-seam unwrapping when running the mark_seam operator. 2011-03-10 06:06:55 +00:00
3ad8fd44c4 request from Jedrzej Slewczuk's:
Option for tagging creases (Ctrl+RMB) to also re-unwrap the mesh.
 In 2.42 this could be done by setting rt==8 (very hidden), now its a little less hidden (in the toolbar).
2011-03-10 05:52:16 +00:00
6a32442855 revert r35438, Martin doesn't like having this option tacked on. 2011-03-10 00:38:23 +00:00
f3a455fd22 CMake should find python now without manual options being set on linux.
cmake on *nix detects python ABI flags for debug and release mode.
searches /usr /usr/local /opt/py32
2011-03-10 00:25:35 +00:00
Nathan Letwory
2336612075 Fix small error in chdir + cmd combination. 2011-03-10 00:21:36 +00:00
Nathan Letwory
4ef2d32b72 untarring of Python 3.2 tarballs would fail if CMake was installed into path with spaces. Slightly
change how the extraction commands are presented (old BUILD_TYPE was empty all the time here) and
ensure also that python/lib subdir under versioned dir gets actually created.
2011-03-10 00:12:06 +00:00
17564249bb better default python ABI flags for *nix, 'm' default, 'd' for debug.
give a CMake error if Python.h isn't found.
2011-03-09 23:27:26 +00:00
Nathan Letwory
239a6f9de7 Some small fixes to the install part for windows. 2011-03-09 22:45:43 +00:00
1110c80696 add option requested [#25598] projection surface snap issue
for retopo workflow you don't wan't to project the mesh onto its self, added option not to.
2011-03-09 22:45:34 +00:00
Nathan Letwory
ca63b15131 Apply [#26364] New Windows keyboard handling
Submitted by Alexander Kuznetsov

Fixes [#25279] Shift-Numpad Combinations fail to align view to selected
and addresses [#26328] Blender uses global keyboard message hook which hurts system responsiveness on Windows

A whole new way of handling keyboard input improves greatly both code readability and event handling. Thanks for the great patch, Alexander!
2011-03-09 22:10:51 +00:00
63e37a6133 - CMake, print message to run 'make install', this is new and should help avoid confusion: [#26425] SVN release can't find scripts/modules and doesn't start properly
- remove extension from icon to match spec: http://standards.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.htm
2011-03-09 21:19:15 +00:00
Nathan Letwory
58fbef0a19 Don't try to copy gnu_gettext.dll when building 64bit Blender - it's linked statically on win64. 2011-03-09 20:58:26 +00:00
108d150032 From the todo:
Hanging Tooltips solved!

It appeared to be that an active button remained in that state when
another region/editor became active. It then kept the button-activate
state, and therefore also the optional tooltip.

This only happened on fast moves, when a mousemove event was not passed
on anymore to the previously active subwindow.

It has been solved with a new notifier (SWINACTIVE), which gets sent on
new active regions. The screen listener then calls uiFreeActiveButtons()
to find out if buttons were still active somewhere else.
2011-03-09 18:42:35 +00:00
2b8fca93aa From the OFTL: Pad-period refreshes File browser. 2011-03-09 15:19:53 +00:00
f0b40cbd0d Todo item: defaulting newly created Property editors to vertical.
(At least until horizontal layouts work acceptable)
2011-03-09 15:12:33 +00:00
4fc83c8efa Fix for [#26420] F-Curve key handles affected by NLA strip position
* NLA timing was only applied to fcurve keys, but not handles, so strange things happened.
* This time tweaking was missed in selections too, so fcurve handles couldn't be selected properly either if the NLA strip was moved from frame 1.
2011-03-09 15:04:09 +00:00
f89fc824aa Fix for [#26372] Objects as PS Hair displays and renders differently
* Grid distribution isn't really suited for hair, so this is now disabled.
* Setting a jittered distribution with particles/face = 1 now creates particles on the center of faces.
* Quite a bit of cleanup of the whole particle distribution code.
2011-03-09 14:18:33 +00:00
Nathan Letwory
3e8c838a99 Fix [#26012] Import Collada: instance_node incorrectly handled
Reported by David Roy

When <instance_node>s where read, their transformation matrix got overwritten with the transform matrix
of their own node, not taking into account the parent node transformation. Instead of doing
that we now get the parent node transformation matrix and apply it to its own, and prevent
caller from overwriting this new transformation matrix.
2011-03-09 14:16:21 +00:00
a23351fbb2 Bugfix #26424
Image Editor: Jkey 'swap render slot' should not be in the undo
system.
2011-03-09 13:47:54 +00:00
94a8435124 make python UV functions use a popup UI rather then redo UI, they are not fast enough. 2011-03-09 11:01:44 +00:00
897c2ede13 py/ui: ensure extensions which add draw functions for menus/headers/panels always get the default operator context, not the one that was last set. 2011-03-09 10:57:56 +00:00
2b88ba069f lightmap pack: made into an operator & added to UV calc menu 2011-03-09 10:49:12 +00:00
c9dbef90b1 working with bpy 2.5x api, convert into operator next. 2011-03-09 08:35:17 +00:00
e5ee4faad3 update for blender as a py module & python 3.2 2011-03-09 04:58:44 +00:00
44648fdf99 update for py3.x syntax and mostly pep8 compliant 2011-03-09 04:08:38 +00:00
bf4323ab6a copy from 2.4x, update to 2.5x next.
svn cp https://svn.blender.org/svnroot/bf-blender/branches/blender2.4/release/scripts/uvcalc_lightmap.py release/scripts/op/uvcalc_lightmap.py
2011-03-09 04:01:40 +00:00
b629256d42 moving to addons & splitting for lazy loading of eps/png/svg
TODO, add to defaults when startup.blend is updated.
2011-03-09 02:07:44 +00:00
b74a84a470 add stddef.h include for offsetof macro for gcc 4.6 compat. 2011-03-09 02:06:21 +00:00
53139432dd image.depth, 96/128 for float color images, was 24/32 for byte images.
also use <> for system includes
2011-03-09 01:25:59 +00:00
Nathan Letwory
3f9bbde4a6 Fix [#26037] Import Collada crashes Blender
Submitted by David Roy

Multiple nodes can reference the same geometry, and specify the same materials. This lead
to the import code overwriting material mappings of faces in a destructive way. Instead of
just writing the material bindings always we now keep book of what geometry+material mapping
we've already handled.
2011-03-09 01:13:28 +00:00
b3ad45aef6 CMake
- temp disable installing plugins dir, since its not used for 2.5x
- OSX wasnt getting text copied.
2011-03-09 00:23:26 +00:00
1eb57bcbc7 disable openexr and collada for mingw, give linking errors. 2011-03-08 23:12:45 +00:00
65273cf82f - correct python3.1 warning message.
- for new shadow only enum, use humanly readable RNA enum values.
- update cmake unix example for custom python.
2011-03-08 22:11:15 +00:00
Nathan Letwory
94b5fd6eb9 Skip materials that are invalid. 2011-03-08 20:41:43 +00:00
Nathan Letwory
ed8719bd1f Apply a small patch from mikktspace author Morten Mikkelsen (cosmetic changes). 2011-03-08 20:39:32 +00:00
a193b14c25 Prevent memory corruption when using fixed texture and fast strokes with
big spacing. Not sure if it's the best solution or it should be fixed when
calculating new areas.

It'll be cool if somebody else familiar with this area will check this.
2011-03-08 20:31:45 +00:00
1dc1b01c2a Fix #26408: [texture paint] brush spacing
Implemented non-spacing strokes (which are making paint step at each
mouse-move event).
2011-03-08 19:52:35 +00:00
3e43b5b72e Fix for [#26322] x-mirror gives wrong results while editing hair particles
* Tsk! Particle mirroring was working fine for the case where subsurf modifier was before particles (orcos are transformed in this case), but not the other way around (unnecessary inverse transform of orcos).
* Not really satisfied with having to check for the CD_ORIGINDEX layer, so if Brecht or somebody else knows a better way then please change this :)
2011-03-08 16:52:10 +00:00
3a43e08deb Bugfix & Feature fix: Only Shadow Material options
Patch from Miika Hämäläinen.

The old Material "Only Shadow" used an ancient 'best guess'
formula using Lamp Distance and some averaging for converting
shadow values to alpha.
A couple of bug reporters already complained about the not
very predictable renders. Miika fixed this by adding two
new options, to only give the true shadow factor exclusively,
or to give a result including light intensity values.

More info:
http://projects.blender.org/tracker/index.php?func=detail&aid=26413&group_id=9&atid=127
2011-03-08 16:08:43 +00:00
Nathan Letwory
3d05311d3c Apply [#26383] Triangle fans support for COLLADA importer
Submitted by Alexey Zakharov

This patch adds support to Blender for reading geometry data that's
represented as triangle fans.
2011-03-08 13:26:41 +00:00
eaeb8004f4 Bugfix #25422
In some cases the User Preferences UI was "vibrating" on redraws.
Could only be redone by some, but this fix is confirmed to work.
2011-03-08 13:02:26 +00:00
95ed5355b7 CMake: removed blenderplayer from install target by accident with recent commit. 2011-03-08 09:01:22 +00:00
Nathan Letwory
65da16a5c1 Apply [#26311] Collada Exporter Crash on Win64 build
Submitted by Filiciss Muhgue

Selecting COLLADA export after starting blender into default scene Blender would crash, due to misreading the path string (no file saved yet, so it was zero).
2011-03-08 08:33:52 +00:00
092c3d8a85 fix bug [#26315] Background and 3D view mistakes
The bug is caused by a fix for [#22111], commits r29356, r28545.

exiting localview would set the rv3d->view but use the original rv3d->viewquat.
2011-03-08 07:44:30 +00:00
ae57e8c8c1 needed removing here too 2011-03-08 07:33:26 +00:00
c7609a27b3 remove unused RegionView3D retopo pointer and set quat printing to const args. 2011-03-08 07:31:42 +00:00
97edca3bc9 Old IDProperty bug, (from original commit r8916),
found crash while changing operator string size.

Shrinking arrays never worked right.
rather then "newlen * sizeof(...)", it would memcpy "newlen * oldlen * sizeof(...)" which always goes over the array bounds.
2011-03-08 03:14:59 +00:00
b9db9e147e ui_textedit_delete_selection() could access past the array bounds. 2011-03-08 02:24:29 +00:00
471c0c1afb py-api utf8/filepaths:
in function PyC_UnicodeAsByte(), replace code copied from python with PyUnicode_EncodeFSDefault(), new in py3.2.
2011-03-08 01:28:10 +00:00
e713d76f0e patch [#26404] UnicodeDecodeError
from user: perfection cat (sindra1961)
2011-03-08 01:23:42 +00:00
efb5f6008f temp workaround [#26397] Console error when selecting certain entries in the Help Menu (Report a Bug)
bug in python 3.2, reported upstream: http://bugs.python.org/issue11432
2011-03-08 01:03:27 +00:00
988886a73d Fix keymap operator polling functions to be a bit safer. 2011-03-07 23:53:08 +00:00
df3688a05d CMake/OSX: Bugfix [#26375]: Add default values for the OSX architecture: x86_64 (also used to select the python dynlibs that'll be bundled with the application).
Set deployment target to be 10.5 by default.

Fix broken build introduced by recent source/creator/CMakeList.txt cleanup
2011-03-07 21:28:36 +00:00
Dalai Felinto
c39a109dae BGE internal cosmetic changes - Replacing hardcoded values with new defines
---------------------------------------------------------------------------
The Rasterizer code was relying in the values defined on TF_ DNA files. I'm working in the recode of TexFace, bringing the options to the material panel and ran into those cases. They are hard to spot and add a lot of the "magic" effect to the code. Hardcoded values are at least easy to spot. We (still) have a few defines duplicated, relying on each other (a flag previously defined in the code is checked later on but using a different define (although with same value. (e.g. TF_BMFONT and RAS_RENDER_3DPOLYGON_TEXT). It's hell =)
I'm adding some comments to help on that.

Things will be revamped anyways, but it's nice to keep the code a bit more coherent before the real feature commit. That's all, thanks for listening.
2011-03-07 19:14:17 +00:00
aa6c975fa8 Bugfix #26394
Using Marker menu (dopesheet) didn't work, the operators themselves
were checking Y coordinate of event.
Handlers also support boundbox checks. For this case it needed a bit
special handling. But works :)
2011-03-07 18:05:41 +00:00
2818add586 From the OFTL:
Arrows-move-cursor is back!
It now works for any running modal operator that doesn't handle own
arrow keys. Might need to become more restricted though, some modal
ops don't need it. Want to investigate that still where conflicts are.
2011-03-07 14:56:19 +00:00
c9685af1ff use set's, since pythons 3.2's optimizer converts these to frozensets, lookups are also faster then tuples (though this isn't a bottleneck). 2011-03-07 13:23:45 +00:00
cfd9d6d190 Drop support for python 3.1.
for building py3.2 on *nix see:
  http://wiki.blender.org/index.php?title=Dev:2.5/Doc/Building_Blender/Linux/Troubleshooting#Python

also fixed possible buffer overrun with getting the fake filepath for a blender textblock.
2011-03-07 11:53:40 +00:00
daff7a447e Bugfix #26388
Actually a todo item I forgot:

Material nodes previews now follow the scene "color managenent"
setting.
2011-03-07 11:51:09 +00:00
c544d3ffb8 Py/Operators: FBX Exporter setting order was still randomized.
Some lines removed recently I thought were are needed were there so classes that use mix-ins keep the argument order.
2011-03-07 08:57:35 +00:00
db066592b7 PyAPI: allow subclasses of io_utils.ExportHelper to set when the extension is enforced. 2011-03-07 08:01:38 +00:00
e7bf671e25 se BLI_snprintf() for msvc compat, cleanup CMake file, some bad comments left in.
also on only try build RPM's on linux.
2011-03-07 03:57:04 +00:00
e1649ecda9 use install target for CMake Windows (msvc and mingw), for MinGW you now need to run 'make install', for MSVC the 'INSTALL' target needs to be enabled in the project file 2011-03-07 03:33:33 +00:00
Nathan Letwory
12ec60ca46 Ensure gpu_extensions.c compiles with MSVC -> include BLI_winstuff.h 2011-03-07 00:49:21 +00:00
627c764e3c bug [#26329] Project Paint not working
we cant ensure that a requested buffer can be allocated so report opengl errors when failing to allocate the buffer (rather then printing to console).

this is common enough and generic error isn't too helpful to users.
2011-03-06 23:12:12 +00:00
f1e0ef1d12 fix [#26368] Solidify breaks EdgeCrease
Make edge crease additive rather then overwriting existing values.
There are other problems pointed out in this report but they are unrelated to solidify.
2011-03-06 22:10:33 +00:00
d49bafe957 Fix #26324: proportional editing and armature applied to editing cage during edit mode works strangely
Not sure why proportional editing used to disable crazyspace corrections,
but from that time hwn it was done transform stuff was changed a lot.
I've made several tests (with file from report and sintel from durian
data files) and it worked nice.
2011-03-06 17:03:25 +00:00
Lukas Toenne
8a312979ef Applied patch by Alexander Kuznetsov for bug 26373: math node 'round' mode was not working correctly for negative numbers. 2011-03-06 13:11:57 +00:00
a803fb095c update 'make' GNUmakefile stub to run 'make install'
update packman and debian for to disable portable install option.
2011-03-06 12:04:59 +00:00
6106d919c3 CMake: Linux/Unix Only,
use 'install' target rather then copying files with post-build commands.

Main change is that you need to run 'make install', which copies files to ./bin by default
unless WITH_INSTALL_PORTABLE is OFF, where CMAKE_INSTALL_PREFIX is used for a typical unix-system install.
2011-03-06 11:41:30 +00:00
a9f08f6310 use tar.gz for windows python zipfiles rather then .zip,
since cmake can only extract tar's
2011-03-06 11:18:57 +00:00
a2b128aa35 Final step for texture nodes/threading issue fix: make needed
initialization on sculpt brush stroke init and free used resources
when stroke is finished.
2011-03-05 17:47:24 +00:00
7fb14d9138 Bugfix #26367
Previous fix I did to make texture-node-paint work, accidentally
cleared tags for compositing nodes to be done while editing.
2011-03-05 17:04:30 +00:00
3d0390a518 Bugfix #26317
Dopesheet: shift+d duplicate is now a macro too, allowing a single undo.
2011-03-05 14:03:29 +00:00
3a590b4ec7 patch [#26366] More detailed Python error reporting for the BGE
from Alex Fraser (z0r)

    Now object name is shown with python error.
2011-03-05 11:08:22 +00:00
2610881e9c sculpt undo struct was using an array of char pointers rather then a char array. 2011-03-05 10:37:59 +00:00
c7fccc84bf use NULL rather then 0 for pointer assignments & comparison, modifier, imbuf & editors. 2011-03-05 10:29:10 +00:00
Dalai Felinto
10373238c1 blenderplayer building again in CMake + OSX (and Linux I guess) patch from IRIE Shinsuke 2011-03-05 09:27:14 +00:00
98b608bfdb workaround for crash (not an actual fix) [#26316] Mirror and EdgeSplit - Grab Vertex do crash 2011-03-05 07:17:19 +00:00
91f4a4d7e1 fix [#26323] Crash when adding to a vertex group with a raw in 2011-03-05 05:02:37 +00:00
8f6e577620 Utility defines for quick timing tests.
for most cases:
 TIMEIT_START(my_test)
 ....
 TIMEIT_END(my_test)

prints time, test name, function name and line number.
2011-03-05 04:35:36 +00:00
6288eb2ef7 2.5 Armature Panel UI Script:
* Code cleanup, no layout changes.
2011-03-04 19:57:05 +00:00
882514d28f Bugfix #26270
Transform started with button in Toolbar was drawing the helper
line badly.

This needed two fixes:
- helper line now has poll() callback to check for correct region
- event system needs to set 'subwinactive' for modal handlers too

The latter might fix issues with cursor/overlay drawing in other
cases?
2011-03-04 18:39:58 +00:00
9d5c6bbe3d quiet warnings and fix building without python. 2011-03-04 17:01:33 +00:00
7006038b02 Bugfix #26317
Shift+D in graph editor was an operator calling internally an operator.
Better is to make it a Macro, then Undos and Esc work nicely.

Note for API users: the operator "graph.duplicate" will now just
copy the selection and not run transform. Nicer too :)
2011-03-04 16:02:42 +00:00
Nathan Letwory
9834aea031 Forgot this one from previous commit.
For now people should extract the python32(_d).zip in the lib/win*/release dirs into similarly named directories.
2011-03-04 14:16:43 +00:00
Nathan Letwory
8bc0033cb0 Move CMake on Windows to use Python 3.2 2011-03-04 14:15:46 +00:00
24fa1d1f04 Two additional fixes for node-tree + texture paint:
- "need exec" flag was cleared in wrong tree for preview renders
  (it should clear it in the copy, i did in original).
  This fixes projection paint on images with previews open
- Previews for nodes were copied always, now only for previews 
  invoked by node editor itself.
2011-03-04 12:59:09 +00:00
Nathan Letwory
5b6223fdeb Py_hash_t is new typedef in Python 3.2, typedeffing Py_ssize_t. Changing to that to keep "slow adaptors" happy ;) 2011-03-04 11:08:22 +00:00
Nathan Letwory
292f633698 long hash caused stack corruption in _PySet_NextEntry. This wanted a Py_hash_t, so made hash into such. 2011-03-04 10:37:49 +00:00
98d444109e change mingw-scons to use python 3.2 2011-03-04 10:19:02 +00:00
Nathan Letwory
a97f920e2f Bump OSX SCons to use Python 3.2. Remember to update your lib/darwin* directory. 2011-03-04 09:08:47 +00:00
afc468c655 Bugfix [#26312] Wrong text in a button in the Stretch to constraint
This looks like a simple Copy+Paste typo
2011-03-04 06:34:41 +00:00
Nathan Letwory
f7ed83647d Move Windows SCons system to build Blender against the new Python 3.2 libs committed in r35340 and r35341.
Platform maintainers and release builders, please update your systems also to Python 3.2.
2011-03-04 00:59:45 +00:00
95f74f3442 Fix for [#26254] Rendering problem with group-instances of particle-instances
* Render level derived mesh (needed for proper hair rendering) was only calculated before duplication code if the particle object was a level 0 duplicator, so particles creating objects inside a dupligroup didn't work.
* I really don't see the need for the level == 0 check, so I just removed it and after some quick tests can't see any negative effects. If the check is needed for some case though then a more complicated test is needed to handle all cases.
2011-03-03 19:07:27 +00:00
18afcbcb7d bugfix #26267
ImageWindow + 3D view texture paint + texture preview render + texture nodes.
Threading hell! But it works now :)
2011-03-03 18:53:07 +00:00
3c184def72 use NULL instead of 0 for pointers, (editors) 2011-03-03 17:59:04 +00:00
709c727c51 replace 0 with NULL when used as a pointer 2011-03-03 17:58:06 +00:00
3326c0ca75 fix for invalid empty string check in uniquename callback. 2011-03-03 17:23:59 +00:00
caf84b49f6 patch [#26235] debian/watch: Update for change of versioning 2011-03-03 16:12:32 +00:00
aec6020376 added support for windows/mingw 2011-03-03 15:38:29 +00:00
b18870e6da Bugfix #26307
Blender crashed on repeatedly pressing "reload image" or "unpack" and
other image options, with a material/texture preview running.

Solved with a signal to stop preview render before doing the action.
2011-03-03 15:18:35 +00:00
3074529c7f Fix #26273: mirror mod. + armature mod. + rotated armature == wrong reference axis for moving verts (when mirror comes first)
Do not overwrite coord of vertices in mapped vertex array used for crazyspace
corrections. This should make stuff use position of mesh vertex after
deformation, not possible generated images of this vertices.
2011-03-03 15:17:57 +00:00
e197cc95e6 fix crash from own recent changes [#26271] Crash when accessing bpy.data.node_groups 2011-03-03 13:55:15 +00:00
36db7f8eb7 Fix #26261: blend from shape operator "add" option was not working correct. 2011-03-03 13:26:55 +00:00
2f741e4dde fix for own error [#26310] "Randomize Transform" operator has widgets jumbled
the correct order was being overwritten.
2011-03-03 13:23:40 +00:00
e8c322ee85 Py/RNA API: WITH_PYTHON_SAFETY
compile time option which enables extra safety checks.
since this is noticeably slower I rather not enable by default yet.
2011-03-03 12:00:35 +00:00
c7dc8ddf7d fix error in qtcreator project file arg checking and check for cmake files. 2011-03-03 11:22:54 +00:00
b6b77b8426 Py/RNA api:
fix for crash when iterating over a collection which allocates the collection and frees on when finished.

The ability for BPy_StructRNA to hold a reference to other PyObject's was added to support this.
2011-03-03 09:16:06 +00:00
57436f3013 fix for own error made r35267. 2011-03-03 08:01:11 +00:00
3a2ce2be83 Py/RNA api - real collection iterator
Previously the api just converted the collection to a list and got the iterator from the list to return.

This has the advantage that it uses minimal memory on large collections where before it would make an array.

Though the main reason for this change is to support a bugfix for collections which free memory when they are done, this currently crashes the python api since once the list is built, the data is freed which is used by the list items in some cases (dynamic enums for eg).
2011-03-03 07:41:09 +00:00
b535c738d9 further reading, need to untrack tracked PyObjects before clearing their trackable vars. 2011-03-03 06:14:55 +00:00
c42f3b4e59 support for mathutils GC wasn't complete since PyObject_GC_Track is supposed to be called once the fields are filled in. 2011-03-03 06:01:31 +00:00
5f5fb5061b formatting edits. (no functional changes) 2011-03-03 05:42:16 +00:00
a18e1043e8 solidify material offsets for 2nd surface and rim faces.
run do_versions() on use_rim_material option so Sintel's jacket loads ok.
(request from Bassam)
2011-03-03 05:09:07 +00:00
385c5f0755 minor correction for r35312, check the operator returns finished.
use lambda for uv.py (no functional change).
2011-03-03 04:25:14 +00:00
Dalai Felinto
13d5f6005e BGE: Material Force Field renaming + reorganization
the old FH setting was blended with the other physics settings (friction and elastic)
Also in the Physics panel it was saying "Use Material Physics" but the button is only for Force Field.

Since I was here I decided to change the Constraint FH ui name from Fh to Force. I don't think users really understand what FH is (I for once don't).
Thanks to Carsten Wartmann for pointing that out.
2011-03-03 01:47:17 +00:00
5e75835524 Shrinking the marker mouse-y tolerance again. It was a bit too high,
making normal transforms get caught too often. I've got a few more
methods that I'll be trialling in the near future
2011-03-02 23:40:32 +00:00
a19e917782 Bugfix [#26269] Initiating a duplication with shift D and cancelling
in dope sheet/ graph editor leads to duplicated keys

The old hack using the transform "undostring" didn't work anymore, as
this wasn't set. Instead, I've added a special mode transform mode for
this that the duplicate operators can set to get this functionality.
2011-03-02 23:39:08 +00:00
Dalai Felinto
9f397b3a3d Logic Editor: link a Sensor with an Actuator and automatically creates an And Controller linked to them
-------------
Given the code perspective this is a hacky solution. However it's self-contained and documented one.
Ended having a talk with Ton and he agreed that this can acceptable in this case.
Zero chances of crashes (I've been using this myself for more than 6 months now).

Give it a shot. Although the code is +- for the user it's a really nice addition.
At the moment it makes more sense to put energy into the future Nodal Logic.
Yet, it's nice to give the current Logic Editor the love it deserves.
2011-03-02 22:32:13 +00:00
Dalai Felinto
0699c21f01 Logic UI: reverting back the PROP_ANGLE props
The Logic Bricks that use angles (Radar Sensor and Constraint Actuator) do so in degree.
Reverting for the time being. Ideally we want to make them to use radians internally (that requires at least a doversion and a convert from radians to degree in BGE Converter routine).

If someone feels like helping on that, please go ahead.
2011-03-02 19:08:48 +00:00
b8c85abc1c tag unused var 2011-03-02 19:06:09 +00:00
9c45fed287 Change RNA weakref code to use a ghash rather then a PyList, removing items from the list was far too slow. 2011-03-02 18:59:43 +00:00
356fb2524c Tsk! glGetFloatv() gives alpha too for GL_CURRENT_COLOR, so a four long vector is needed! 2011-03-02 17:49:02 +00:00
e6a5715773 Fix for [#25326] FCurve rotate gives strange results.
* The fcurve points changed their order when rotating, but the transform data wasn't updated properly for this change so some curve handle pointers got lost.
* Also found a second bug while fixing this: The fcurve handle type pointers weren't updated at all when the order changed, so some auto handles could turn into aligned handles even if the transform was canceled (no undo possible in this case!).
2011-03-02 17:32:01 +00:00
415e8df10e simplify rna internal weakref use. 2011-03-02 16:56:13 +00:00
dd2c7fa908 Bugfix #26226
ImageWindow: hotkey "P" for Scopes was in conflict with Pinning.
Remapped it to "T" for time being, although it's not a toolbar...
2011-03-02 16:52:09 +00:00
0abffe22c2 align weakref list for rna (properties were using wrong pointer) 2011-03-02 16:22:04 +00:00
Lukas Toenne
4453439254 Removed tests for existing node pointers in RNA function for new links. Group node sockets don't have any specific node they belong to, so no node pointers are found. 2011-03-02 14:13:05 +00:00
361b8017d2 From the OFTL (old fart todo list)
Right Mouse on area edges has menu to Split or Join. Works like 2.4.

Code needed cleanup and upgrade; operators were hardcoded tied to using
the area corner widgets only. In theory this is getting py ready even,
but that might need some additional testing. :)
2011-03-02 14:09:54 +00:00
7159bc0b1c minor fixes to weakref validation before making bigger changes 2011-03-02 06:56:21 +00:00
54b654c18f fixed compile problem intruduced in r35295
one import was missing, another one used twice.
2011-03-02 06:47:08 +00:00
58eb5ffc28 SVN maintenance. 2011-03-02 05:06:43 +00:00
3c3997f050 replace references to old arithb library 2011-03-02 05:05:12 +00:00
e2304a4dbb move anim functions out of bpy_rna.c, its getting too big. 2011-03-02 04:51:43 +00:00
21067886aa update for changed exception type 2011-03-02 04:16:57 +00:00
Dalai Felinto
4a48bb3cf5 Logic Editor: "Python Controller" NOT "Python Script Controller"
The "Script" was added in the original rna commit but for no apparent reason the controller was renamed from the original 2.49 name.
Spotted/reverted in time.
2011-03-02 01:42:14 +00:00
Nathan Letwory
299d1552af Remove superfluous () 2011-03-01 21:55:51 +00:00
0e8d313f0e Fix #26218: texture paint
- Added option "Fixed Texture" to the UI. Because of strange reason,
  this feature was implemented but hidden from users.
  Would be cool, if somebody familiar with 2d texture paiting check.
- Fixed some issues in existing code of fixed texture paiting.
  It now handles brush radius and curve correct.
- Also fixed issue with paiting with texture from node tree - it used
  to be painted with regular brush color instead of texture.
2011-03-01 17:58:12 +00:00
f2f52a578a UV layout export: EPS format
Pass an iterator function rather then the iterator its self, allows to loop over the faces twice without making a list.
2011-03-01 17:32:17 +00:00
2be3a334e2 fix [#26257] Colored UV-Map on export
- EPS now exports material colors and face fill doesn't overwrite edges (draw in 2 passes).
- added opacity option for EPS/SVG/PNG
2011-03-01 17:22:27 +00:00
d23a7574a0 Bugfix #26243
Not sure if it fixes the bug, but an RNA boolean was read as int...
Related to default for "Blend from Shape" tool.
2011-03-01 17:00:01 +00:00
32d87359e1 Bugfix #26249
Paint strokes now can be mapped to any key. The operators now store the
event it was started with, so it ends with a release. Even hotkeys work 
(while hold).
2011-03-01 16:26:37 +00:00
acd69b9c3f Bugfix #26251
Logic editor: click in active text input buttons didnt work.
2011-03-01 15:54:49 +00:00
Nathan Letwory
ef648f617e Fix [#25476] Pan view not always works with shift+alt+LMB in Blender 2.56
Reported by Mihail Konoh

Applied patch submitted by Alexander Kuznetsov (to [#26208]). Thanks for long-standing head-ache :)
2011-03-01 15:14:59 +00:00
623822626a Py/RNA Stability: don't allow python to reference freed ID's and crash.
Second method for not having python crash blender on invalid access (ifdef'd out ATM, so no functional change).

This uses a weakref list per ID, and invalidates all members of that list when the ID is freed.
the list is not stores in the ID pointer but using a hash table since storing python in DNA data is not acceptable.

This is more correct then the previous method but shows down execution of scripts significantly since its always adding and removing from lists when data is created and freed.
2011-03-01 14:53:26 +00:00
f0f639f8b8 Typo in last commit, changing variable name for more readable code... 2011-03-01 13:56:33 +00:00
Nathan Letwory
900199d215 Fix [#26207] Render.exe mangles paths in mysterious and awesome ways
Reported by Edwin Amsler

The function for extrapolating the template name with the frame number didn't properly NULL-terminate the
resulting string, this causing broken names and weird paths (if you were lucky - totally unusuable names
detected while stepping through the code).
2011-03-01 12:52:00 +00:00
5bf1bf645c Bug fixes #26236 #26237
- Linking logic buttons had draw glitch, caused by reading
  data from free'd buttons
- Doing an undo with mouse-over Curve Widget caused crash or
  corruption.

Both related to code that tries to keep the "active" button in
memory. On each redraw of UI, buttons are re-created, which makes
it all tricky... hope we're safer now.

Also: added back undo pushes on adding links in logic editor.
2011-03-01 12:25:55 +00:00
Lukas Toenne
1c0b9dfdf1 Small fix for node drawing: nodes with no sockets now have a minimum height to avoid opengl drawing artifacts. 2011-03-01 10:08:09 +00:00
c9ee017fb5 Py/RNA API test code to prevent crashing blender when python references freed ID's.
This uses pythons GC so its no overhead during runtime but makes removing ID's slower.

Commented definition 'USE_PYRNA_INVALIDATE_GC' for now, so no functional change.
2011-03-01 09:02:54 +00:00
c8de6195c8 fix [#26252] Py error when installing addon through UI
Py3.1 for windows doesn't have os.path.samefile(), has been added in 3.2.
2011-03-01 08:28:37 +00:00
b4246549e7 select PoseBone attribute was made only available on bone. 2011-03-01 07:52:13 +00:00
244f456a3c fix for error in recent cmake edits 2011-03-01 07:21:52 +00:00
7b636c717d bpy/rna support for invalidating objects.
access will raise an error.
2011-02-28 22:56:29 +00:00
55268331f6 missed these last commit. 2011-02-28 21:06:09 +00:00
Dalai Felinto
12f77ddb9e BGE fix: complement to recent patch for Rigid Body Constraint. patch by Juha Mäki-Kanto (kanttori) 2011-02-28 20:22:28 +00:00
fa42cf671a git users complain this breaks for them 2011-02-28 19:48:56 +00:00
7348a50d79 change return values from mathutils callbacks to match pythons (-1 is error), so error macro's can be used in both. 2011-02-28 18:42:41 +00:00
506e8aa437 Bug fix: Render and 3d view conflict over ob->imat
* For rendering every object's inverse matrix "ob->imat" needs to
  be in render view coordinates, but for drawing in 3d view it needs
  to be in global coordinates. Originally (way back in historical
  times) ob->imat was only used for rendering, but over the years
  other uses came up too. Before 2.5 this wasn't a problem as
  rendering was a totally blocking operation, but with the new
  "interactive ui while rendering" the problems started. Basically
  any update that redrew the 3d view while rendering (like rotating
  the scene with mouse) updated the inverse matrix into global
  coordinates thus invalidating it for the render, leading to all
  kinds of strange discontinuities with textures and volumetrics.

* Problems were very easy to achieve using orco/object coordinates
  for pretty much any textures (bump, point density, volume, sky),
  for examples see bug reports 24906 and 25229. Render baking normals
  in object coordinates was wrong most of the time too.

* Now there is a separate inverse matrix ob->imat_ren that's
  calculated at the beginning of rendering and is used in all places
  inside render code where it's needed. This way the original ob->imat
  can change at will during rendering without causing problems.
2011-02-28 15:42:15 +00:00
13b617c78f 2.5 Netrender UI File:
* Code cleanup.
2011-02-28 14:34:13 +00:00
cbf976e7a6 2.5 UI scripts:
* Removed some unused code.
2011-02-28 14:25:40 +00:00
Nathan Letwory
82b21ba166 Fix [#26213] Collada exporter id's not unique
Reported by Kevin Yoon

<material> could get same id as <node>, prevent that by suffixing -material.
2011-02-28 14:24:52 +00:00
Nathan Letwory
9234cb6e30 Make sure python.zip is extracted only once. This prevents erroring build on the unzip stage. 2011-02-28 13:18:00 +00:00
a40bb7e205 fix for inconsistency reported as bug [#26245] bpy.data.keys collides with the built-in func keys() 2011-02-28 12:05:43 +00:00
Nathan Letwory
e62063bd5c Cleanup paths after move to dir. 2011-02-28 09:58:53 +00:00
5ef65a0a3b build system now exclude config-*, turtledemo when copying system python.
also remove __pycache__ dirs when cleaning (new in python 3.2)
2011-02-28 05:59:44 +00:00
e09189cf50 complete lazy loading of py modules to use to a reduced set of pythons modules, gives ~40% speedup on cold & warm start (without netrender).
- use own OrderedDictMini class, pythons collections.OrderedDict is overkill, 179 sloc. replaced with own, 11 lines.
- remove code which stored the class file & line per RNA subclass, this was useful but would raise its own exception every time to generate a stack trace to get the class info so we could use of the class failed to register. the class stores its module & name which can be enough to find where it was defined.
2011-02-28 04:37:24 +00:00
ea5664c0d1 remove unused vars. 2011-02-28 03:17:53 +00:00
3919c46a09 minor change for image invert operator
- dirty var wasn't being used.
- only call IMB_rect_from_float if there was previously a rect buffer.
2011-02-28 03:17:20 +00:00
Nathan Letwory
1af13dea62 move doxygen files into own subdir. 2011-02-27 20:46:25 +00:00
Nathan Letwory
5fe1c42575 doxygen: update for tagged modules. 2011-02-27 20:44:37 +00:00
Nathan Letwory
9960f697a6 doxygen: blender/avi tagged. 2011-02-27 20:43:42 +00:00
Nathan Letwory
b9e70c743b doxygen: blender/blenfont tagged. 2011-02-27 20:42:42 +00:00
Nathan Letwory
0ff06e21cd doxygen: blender/blenkernel tagged. 2011-02-27 20:40:57 +00:00
Nathan Letwory
7900b5949f doxygen: blender/blenlib tagged. 2011-02-27 20:37:56 +00:00
Nathan Letwory
cfd54244cc doxygen: blender/blenloader tagged. 2011-02-27 20:35:41 +00:00
Nathan Letwory
1e141725c5 doxygen: blender/blenpluginapi tagged. 2011-02-27 20:32:12 +00:00
Nathan Letwory
caf9fb6cce doxygen: blender/collada tagged. 2011-02-27 20:30:35 +00:00
Nathan Letwory
95100afc12 doxygen: blender/editors tagged. 2011-02-27 20:29:51 +00:00
Nathan Letwory
93b144548d doxygen: blender/gpu tagged. 2011-02-27 20:25:53 +00:00
Nathan Letwory
13a540a41d doxygen: blender/ikplugin tagged. 2011-02-27 20:24:49 +00:00
Nathan Letwory
192ab99b5c doxygen: blender/imbuf tagged. 2011-02-27 20:23:21 +00:00
Nathan Letwory
a47ca06502 doxygen: blender/makesrna tagged. 2011-02-27 20:20:01 +00:00
Nathan Letwory
19a9cffdf0 doxygen: blender/nodes tagged. 2011-02-27 20:13:22 +00:00
Nathan Letwory
5a760e22fc doxygen: blender/python tagged. 2011-02-27 20:10:08 +00:00
Nathan Letwory
92ea5eda90 doxygen: blender/quicktime tagged. 2011-02-27 20:01:38 +00:00
Nathan Letwory
a100993878 doxygen: blender/readblenfile tagged. 2011-02-27 19:59:59 +00:00
Nathan Letwory
a61c41c7a5 doxygen: blender/render tagged. 2011-02-27 19:31:27 +00:00
Nathan Letwory
c1fee0a1dc doxygen: fixes 2011-02-27 19:29:07 +00:00
7ddfd39b28 == CMake Win ==
* remove copying of libjack dll's, libjack is statically linked now.
2011-02-27 18:47:03 +00:00
4ed5cd6cef == UI icons ==
* Change ICON_NULL --> ICON_NONE to avoid two #defines with the same meaning.
2011-02-27 18:03:19 +00:00
7a4ca6a36d == UI icons ==
* Moved two #defines out of the enum to make code more readable.
2011-02-27 17:50:12 +00:00
7cc0cd7814 Bugfix, own collection.
Curve widget editing used bad pointer, unsure in which cases it
would crash though...
2011-02-27 17:23:00 +00:00
da27e6889a Info > Help Menu:
Finally, the Blender icon can be used for the splash screen menu entry, on own todo for almost 1 year!
Thanks to elubie for fixing this in the code. :)
2011-02-27 17:11:56 +00:00
b39f09e962 == UI icons ==
* Moved ICON_BLENDER away from (0,0) spot in blenderbuttons, since ICON_BLENDER=0 define is conflicting ICON_NULL define as well as with logic checks for nonzero icon id.
* This solved bug where ICON_BLENDER can't be set from Python as well as when using new UI functions from within Blender.
2011-02-27 16:58:37 +00:00
b1ef977eff Fixes for undo when suclpting on deformed mesh:
- Invalid shape when deformation mesh was disabled befoe undoing
- Crash when deformation modifier was enabled before undoing

Still got problems with undoing multires changes when toggling modifiers.
2011-02-27 16:49:28 +00:00
fc0c016940 replace import *'s with named imports (using * is convenient for some scripts but considered bad practice by python devs) 2011-02-27 15:25:24 +00:00
52f92b4cb1 lazy load modules for more scripts. 2011-02-27 14:16:32 +00:00
87acf919a5 lazy load pydoc module. move help() replacement into console code rather then on startup since importing pydoc pulls in lots of other modules too. 2011-02-27 14:08:33 +00:00
4ab33ae859 2.5 Transform Operator:
* Added a NC_OBJECT|ND_TRANSFORM notifier to it, so we get a refresh when using the operator from python console. Issue reported by calli in IRC.
2011-02-27 14:01:09 +00:00
b51fb00654 2.5 particle UI File:
* Code cleanup and some assignment names fixes. 
We still have the code guidelines. http://wiki.blender.org/index.php/Dev:2.5/Py/Scripts/Guidelines/Layouts

So please only use subsub if absolutely necessary!
2011-02-27 11:06:01 +00:00
77959fe893 2.5 Constraint Ui File:
* Minor fix for my commit yesterday, label in FLOOR constraint was missing for location property.
2011-02-27 10:47:32 +00:00
Dalai Felinto
bc52b996e3 small UI cleanup - "Mouse Cursor" instead of "Show Mouse" and s/subcol/sub and a new line in the end of constraints ui file 2011-02-27 09:36:29 +00:00
Dalai Felinto
ac1b08a928 BGE patch: [#26223] Some RigidBody joints fixes (ui angles, conetwist/hinge limits etc) by Juha Mäki-Kanto + ui changes pour moi
From the tracker:::
Issues fixed:
- ConeTwist-constraint's params weren't making it to the CcdPhysicsEnvironment, also added Hinge's params.
- UI wasn't using angles where applicable.
- btHingeConstraint's constructor can create frame-matrices which don't align so the hinge doesn's start at 0 degree tilt.
This is an issue when setting limits.

Changes:
- UI: Hinge limits can be set (and disabled).
- UI: ConeTwist only has max-limits and only the twistX can be disabled
- PyApi via rna_constraint.c: added the functions limit_xyz_min, limit_xyz_max (for 6dof), limit_angle_xyz_min,
limit_angle_xyz_max (for 6dof), limit_angle_x_min, limit_angle_x_max (for hinge).
- PyApi: dropped python-function limit_cone_min. 

.:. Extra:
UI Changes:
- renamed "RigidBody Joint" to "Rigid Boidy Joint" 
- reorganized UI to conform with other parameters (e.g. Limit Rot)
- added dis/active all over the place :)
2011-02-27 09:21:13 +00:00
2e5eb41522 pedantic warning cleanup, also remove texspace_edit() since its been added using a different method. 2011-02-27 08:31:10 +00:00
f73c993b16 - use Py_CLEAR for python internally referencing other PyObjects (supposed to be safer).
- detect includes for qtcreator projects as well as the ones from cmake (it didnt return all of the right paths).
2011-02-27 04:01:58 +00:00
a11c80d3bb cyclic gc support for KX_PythonSeq 2011-02-27 03:59:17 +00:00
484ab618a7 Grease Pencil stroke smoothing cleanup - making this less susceptible
to sequential error by adopting a two-pass smoothing strategy instead.
This seems to give some minimal reductions in the amounts of unwanted
shrinkage that occurs
2011-02-27 02:08:32 +00:00
1cbdc6c4d4 Small animation tweaks:
- Fixed problem where just trying to replace existing keyframes would
result in the intepolation set on that keyframe to get lost. This was
mostly an issue if trying to re-block some animation in the middle of
a shot, with the rest of the keys set to Bezier, but the first
keyframe in this new segment needing to be Constant so that we don't
get sloppy automatic interpolation in the way

- Hooked up Media-Play/Stop/Next/Prev controls to animation playback
and keyframe jumping functionality in default keymap in addition the
existing controls. I'm also considering whether to migrate Next/Prev
Keyframe key mappings off the Ctrl-PageUp/Down keys for a more
ergonomic option (i.e. shift <, shift >)
2011-02-27 01:53:05 +00:00
039940e1e9 Image Editor:
* Added back selector for active UV texture. IRC Request by _BigWings_ :)
2011-02-26 19:18:02 +00:00
7a313265e1 Sampling float colors in Image Editor only showed 3 digits precision.
Let's make it four! :)
2011-02-26 18:39:21 +00:00
2f0d93ba56 clean whitespace 2011-02-26 16:27:58 +00:00
91e6fd1828 port of function from 2.4x's BPyMesh.py thanks to 'merlin_' on IRC. 2011-02-26 16:13:14 +00:00
ab9490f8ea 2.5 UI Scripts:
* More code cleanup.
When removing the narrow_ui feature, a lot of split functions were kept. Changed them to rows, which are more easily readable. Check out properties_data_lattice.py for a good example.
2011-02-26 16:04:14 +00:00
a5eba49ccb Bugfix #26231
Mesh editing: operator "Blend From Shape" had blending off as default.
A bit weird... so let's change :)
2011-02-26 15:42:59 +00:00
61235fcc8a fix for 'live edit', running python scripts as you type
- errors would jump to the line which gets in the way.
- the window wouldn't always redraw.
2011-02-26 15:30:38 +00:00
a12315e4ec use const char for return values of getenv(). 2011-02-26 15:28:56 +00:00
38bd8dcf05 Bugfix #26221
Two bugs in one:

- Lukas commit monday for new group/socket handling accidentally removed
  to set socketype in stacks, which as used by (texture) nodes to detect
  whether value, color or vector had to be read.
  Result was that all texture nodes were rendering as B&W

- Old 2.5 bug: preview renders for texture nodes didn't call a 
  NodeEndExec function, which gave crashes on deleting nodes.

The change in interface_hanlers.c is only a comment to explain
how keymaps are being found.
2011-02-26 13:53:15 +00:00
457aba9d1b fix [#26227] "Sequence must have 2 items total, not -2" 2011-02-26 12:26:01 +00:00
34abccc0ab qtcreator project generator now includes defines and correct include paths. 2011-02-26 11:18:36 +00:00
abecdac41e Bugfix: In Action Editor, when "show pose markers" was enabled, all
markers were always drawn as local pose-markers, even when they were
not.
2011-02-26 10:41:59 +00:00
7a55884b62 Added operator which makes selected scene markers into local 'pose'
markers.

This is useful for when working with lipsync shots, where you've used
markers for noting down key syllables and want to separate these out
into chunks to manage things better.
2011-02-26 06:28:24 +00:00
6a25ecb799 recent changes to svn broke rpm builder, also include rpm version info 2011-02-26 06:27:54 +00:00
2198cfdb2d SVN maintenance. 2011-02-25 19:23:23 +00:00
ce81cce75d Fix #26158: The layer hight of the layer tool cannot longer be controled by the strength of the brush, as it was in 2.49
Layer height used to be controlled with brush radius, quite confusing decision.
Added new property for brushes - height for adjusting affectable brush height
(it could be not only layer height in the future).
2011-02-25 16:54:09 +00:00
d6f69a2c19 Bugfix #26174
Shift+A "add primitive" menu didn't allow to set shortcuts on the
sublevels.
2011-02-25 16:32:03 +00:00
bc15e0e295 add NDEBUG to scons release flags + some pep8 cleanup for examples. 2011-02-25 16:19:50 +00:00
b25db7c8cb pep8 cleanup 2011-02-25 16:06:14 +00:00
24685d3967 Bug fix, irc report.
Menu Help -> Operator Cheat Sheet crashed, calling function with NULL context.
2011-02-25 16:05:26 +00:00
f2ab4dd6a7 use flag _DEBUG, not DEBUG. 2011-02-25 15:46:43 +00:00
965c46b1d3 follow up on patch [#26215], not all weakref references were ifdef'd 2011-02-25 15:07:25 +00:00
e06eea4fba fix for scons with recent change to how BINRELOC is enabled via cmake.
also add WITH_PYTHON define to qtcreator project generator until we get a way to add them properly.
2011-02-25 14:45:45 +00:00
2cf20fde1b patch [#26215] Python weak reference (weakref) support for game objects
by Alex Fraser (z0r)
2011-02-25 14:32:35 +00:00
Nathan Letwory
60b22c5d12 doxygen: blender/windowmanager tagged. 2011-02-25 14:04:21 +00:00
Nathan Letwory
caa7bea1c5 doxygendoxygen: blender/modifiers tagged. 2011-02-25 13:57:17 +00:00
Nathan Letwory
1bb465141d doxygen: tag blenderplayer stubs. 2011-02-25 13:46:54 +00:00
Nathan Letwory
6f6fac63ff doxygen: gameengine/VideoTexture tagged. 2011-02-25 13:39:34 +00:00
Nathan Letwory
b188223ee4 doxygen: gameengine/SceneGraph tagged. 2011-02-25 13:39:04 +00:00
Nathan Letwory
2d3209c4b3 doxygen: gameengine/Rasterizer tagged. 2011-02-25 13:38:24 +00:00
Nathan Letwory
8476f26bc6 doxygen: gameengine/Physics tagged. 2011-02-25 13:37:23 +00:00
Nathan Letwory
dd26551ab7 doxygen: gameengine/Network tagged. 2011-02-25 13:36:49 +00:00
Nathan Letwory
bb6e7faf72 doxygen: gameengine/Ketsji tagged. 2011-02-25 13:35:59 +00:00
Nathan Letwory
94f3851840 doxygen: gameengine/GamePlayer tagged. 2011-02-25 13:35:11 +00:00
Nathan Letwory
344caea0b3 doxygen: gameengine/GameLogic tagged. 2011-02-25 13:32:11 +00:00
Nathan Letwory
34eeeb9115 doxygen: gameengine/Expressions tagged. 2011-02-25 13:31:23 +00:00
Nathan Letwory
ab523e91d0 doxygen: gameengine/Converter tagged. 2011-02-25 13:30:41 +00:00
Nathan Letwory
90917f78da doxygen: gameengine/BlenderRoutines tagged. 2011-02-25 13:29:48 +00:00
Nathan Letwory
7184ed446b doxygen: kernel/ groups added. 2011-02-25 13:28:22 +00:00
Nathan Letwory
b59efe828b doxygen: kernel/gen_system tagged. 2011-02-25 13:25:53 +00:00
Nathan Letwory
b414c6e08d doxygen: kernel/gen_messaging tagged. 2011-02-25 13:24:53 +00:00
Nathan Letwory
710d79925b doxygen: add missing group definitions. 2011-02-25 13:14:27 +00:00
Nathan Letwory
48dba3bbde doxygen: add bsp group 2011-02-25 11:53:23 +00:00
Nathan Letwory
058441e04f doxygen: intern/string tagged. 2011-02-25 11:51:19 +00:00
Nathan Letwory
b8e7f89003 doxygen: intern/smoke tagged. 2011-02-25 11:50:46 +00:00
Nathan Letwory
b07988274e doxygen: intern/moto tagged. 2011-02-25 11:49:19 +00:00
Nathan Letwory
f5419aec80 doxygen: intern/mikktspace tagged. 2011-02-25 11:47:49 +00:00
Nathan Letwory
65687c32fb doxygen: intern/memutil tagged 2011-02-25 11:47:18 +00:00
Nathan Letwory
b52453e8d6 doxygen: intern/itasc tagged 2011-02-25 11:45:16 +00:00
Nathan Letwory
c6f228c485 doxygen: intern/iksolver tagged. Leaving out TNT, since we have it in multiple locations. 2011-02-25 11:43:19 +00:00
Nathan Letwory
56a4b21695 doxygen: intern/guardedalloc tagged 2011-02-25 11:41:12 +00:00
Nathan Letwory
b15161a2d3 doxygen: fixup and tag intern/ghost. 2011-02-25 11:28:33 +00:00
09e8a8222c needed for building without python 2011-02-25 11:25:11 +00:00
e7101e21e1 bugfix #26211
render-result doesn't get an ibuf with BKE_image_get_ibuf
added a poll method to grey-out entries if !ibuf for now.
2011-02-25 11:00:38 +00:00
Nathan Letwory
05c0eec5ff Small fix from sambler. 2011-02-25 10:58:04 +00:00
Nathan Letwory
d14216ed04 doxygen: intern/elbeem tagged 2011-02-25 10:51:01 +00:00
Nathan Letwory
34dd520466 doxygen: intern/decimation tagged 2011-02-25 10:47:28 +00:00
Nathan Letwory
48f1858cad doxygen: intern/container tagged 2011-02-25 10:45:31 +00:00
Nathan Letwory
2401fad12a doxygen: intern/bsp tagged 2011-02-25 10:44:20 +00:00
Nathan Letwory
83d6e06af5 doxygen: update Doxyfile and split doxygen.main 2011-02-25 10:34:04 +00:00
Nathan Letwory
bd610e942a doxygen: intern/boolop tagged 2011-02-25 10:32:33 +00:00
Nathan Letwory
4e51512d0b doxygen: opennl tagged.
renamed BLO_sys_types.h to superlu_sys_types.h
2011-02-25 10:24:29 +00:00
Nathan Letwory
45ed5f53f6 doxgyen: audaspace tagged. 2011-02-25 10:21:56 +00:00
Nathan Letwory
6aae3bb5c8 doxygen: small fixes and tag adding 2011-02-25 10:20:37 +00:00
Nathan Letwory
3cd4110f78 fix #if errors, add defined() in proper places
doxygen: add file tags
2011-02-25 10:01:33 +00:00
47d2353f26 Fix for [#26205] Crash when duplicating window
* Timeline duplication code freed the original time caches too.
2011-02-25 08:40:57 +00:00
5005853d40 Fix buildinfo, as pointed by IRIE Shinsuke.
Added a note about doubtful "copy if different".
2011-02-25 06:03:01 +00:00
8a1cff54ce internal operator/wm/macro function: dont crash if operators are not found (warning will be printed). 2011-02-25 04:15:45 +00:00
aa9c91f01a Make buildinfo not fail with git-svn as suggested by Nicholas Bishop.
Improve formating and comments a bit.
2011-02-25 04:02:58 +00:00
18c7354bd2 remove warning left in by mistake and comment unused function. 2011-02-25 02:27:54 +00:00
4b4281f2e2 SVN maintenance. 2011-02-25 00:02:08 +00:00
b8e3f4ee30 fix for cmake not having the correct svn revision in buildinfo, now generate a header every build with the time, date, svn revision. 2011-02-24 17:57:35 +00:00
197a57db69 face-paint mode operators were not ported from 2.4x yet hide/reveal/sel-swap
also added hide-unselected option to armature mode.
2011-02-24 16:04:36 +00:00
Lukas Toenne
04d04f6401 Fixed memory leak in group nodes. Only buffers from exposed sockets should remain after group execution. 2011-02-24 15:48:09 +00:00
d00b5736a5 remove unused functions, aligning to selection can be done with Shift+Numpad, uses manipulator code. 2011-02-24 15:31:38 +00:00
4c6b1d9df2 patch [#26187] Cleaning #include <malloc.h>
from Shane Ambler (sambler)

    didnt include change to superlu, prefer to leave external libs out of cleanups.
2011-02-24 14:05:41 +00:00
8ce6da76b6 patch [#26178] build_debian.sh: Use BLENDER_VERSION_CHAR
from Shinsuke Irie (irie)
    also apply to pacman.
2011-02-24 14:03:29 +00:00
acf8a9c6ec Fix for [#26197] High resolution smoke cache not available due to pointcache update. Please reset the simulation.
* Backwards compatibility code wasn't forwards compatible :)
2011-02-24 13:37:53 +00:00
cd615f6fcc found moving verts in pythons 2.5 api is approx 10x slower because the multi-dimensional array assignment reads the array 3 times (typecheck, length-check & for-real).
the length check was running sequence checks on every number which would fail, small speedup by avoiding this.

should eventually get this working faster by reading once into an allocated array.
2011-02-24 08:47:58 +00:00
31c7d694e0 remove 2 unnecessary checks for array type before assignment. 2011-02-24 07:25:47 +00:00
fbd9364944 revert part of own commit r35117 which modified mathutils initialization functions, found this could be done in a better way which doesnt have to deal with partly initialize instances being freed. 2011-02-24 05:46:57 +00:00
b357033f5e remove unused vars. 2011-02-24 05:41:03 +00:00
b1639dc118 support pythons cyclic garbage collector for mathutils types. 2011-02-24 04:58:51 +00:00
Nathan Letwory
9aa9ade42a doxygen: some more license block fixes. 2011-02-23 23:22:25 +00:00
2158d05866 adjustments to recent commit:
* inv_ -> inverted_
* flagged image dirty after invert.
* restored properties accidently cut out of unpack operator.

brecht.beers[lmg]++
 thanks for paying attention! :)
2011-02-23 19:40:24 +00:00
3bee6abb74 Fix for [#26133] Explode modifier doesn't care about UVs (Option "split edges")
* This is basically a total rewrite of the edge split algorithm. The old one didn't handle tris at all and quads were cut wrong in some cases too with the addition of not handling uv coordinates at all.
* This new algorithm uses a flag system to categorize different splits and the identical but rotated cases in a similar way to how marching cubes indexes different cases.
* It cuts quads and tris and creates proper uv's for the new faces too.
* I also renamed the option to "edge cut" to differentiate if from the edge split modifier and added an option to override a uv-channel in the exploded mesh with particle age as x-coordinate so that the shrapnel can be faded out nicely etc.
2011-02-23 19:29:59 +00:00
00c05c8404 Clean up headers a bit more. 2011-02-23 18:03:40 +00:00
962a4386bc Bugfix #26188
Having 2 or more windows open, a render in another window made the
other (active) window fail badly on F11 key (show render).

Now things should go smoothly. If a render is being shown in 
inactive windows, they get popped to the front nicely.
2011-02-23 15:52:05 +00:00
Lukas Toenne
4fe21e0b4f The material "Dynamic" node (disabled anyway) had incomplete base type initialization, which made it appear as an empty item in the input node category. 2011-02-23 13:50:41 +00:00
65bb4ff8d1 py/rna api:
ifdef'd out weakref for blender/py api, worth testing to see if it adds much overhead.
2011-02-23 13:43:45 +00:00
f0f3d9a2ff added image-editor operators:
Invert Image Colors (RGB)
--
Invert Red Channel
Invert Green Channel
Invert Blue Channel
Invert Alpha Channel

mostly because of the recent changes in normalmap channels,
so users can adopt old bakes quickly.
though they might aswell prove useful in other situations.
2011-02-23 12:02:43 +00:00
d7c29a0310 since the introduction of 'newbump' blender
was exporting normal maps with red and green channel inverted
relative to the geometry it actually exports.

This change makes blender export normal maps 
which are very similar to most tools out there.

patch by Morten S. Mikkelsen
2011-02-23 11:58:36 +00:00
Nathan Letwory
5b607701a7 doxygen: prevent GPL license block from being parsed as doxygen comment. 2011-02-23 10:52:22 +00:00
5a70edc4af Possible fix for [#26190] Changing particle amount crashes
* In some cases fluid particles could be born at the exact same locations. Now these cases are just ignored and such particles don't effect each other.
2011-02-23 10:42:27 +00:00
9416daf97e remove unused functions,
note: BPY_class_validate() could come in handy later if we need to check classes for properties/functions but for now there is no point in keeping it in.
2011-02-23 09:12:55 +00:00
9349374359 add back view 1:1 operator from 2.4x (Shift+PadEnter) 2011-02-23 06:48:47 +00:00
2f472ccd60 add back 2.4x mesh vertex sort/randomize operators, were called xsort and hash in 2.4x.
available from vertex menu.
2011-02-23 05:17:29 +00:00
0a7fecac8f add 2.4x posemode & weightpaint feature as an operator - Flip Active, Shift+F. 2011-02-23 04:58:08 +00:00
aeeb09bd56 fix [#26164] bpy.ops.transform.translate ignores AutoIK mode
auto-ik updates are done by notifiers at the moment which are ignored when running bpy.ops.transform.translate(), so add an special_aftertrans_update() check for this case.
2011-02-23 04:03:58 +00:00
43007d7fed - fix python error for poselib UI when none is active.
- add info to create_dupli_objects rna function docstring.
- transform snap had bad define, disabling BVH accelerated snap (own fault).
2011-02-23 03:08:14 +00:00
8378aa74fa python console namespace fix, merging namespace dicts was no good, since it pulled in private vars. use normal import command. 2011-02-23 01:20:40 +00:00
Nathan Letwory
3f96359d5a doxygen: make sure license blocks don't interfere. 2011-02-22 23:40:06 +00:00
698f9948d8 Adding "frame" to print in background rendering for
"Calculating previous (frame) vectors"
now it fits better with
"Calculating next frame vectors"

@jesterking: yes you are

@jesterking: yes you are!!
2011-02-22 23:32:29 +00:00
Nathan Letwory
33ceadb2a6 "I must be an idiot" 2011-02-22 23:14:27 +00:00
Nathan Letwory
ce717ff355 doxygen fix, otherwise file doesn't show up in module section. 2011-02-22 23:10:51 +00:00
2fd60d9719 error in own recent moving addons functions into its own module. addon_utils.reset_all failed. 2011-02-22 22:24:50 +00:00
Nathan Letwory
8e3fcf007a doxygen: add Audaspace C API entry 2011-02-22 21:58:43 +00:00
Lukas Toenne
2d7b4d1579 Empty groups are now displayed with some basic spacing in edit mode. Long socket lists don't outgrow the group box any more; the box height is adjusted to fit the length of the socket list instead. 2011-02-22 21:22:27 +00:00
Lukas Toenne
e7750aa6ed Convenience fix: Exposing internal sockets now copies the default input value to the group sockets. The "expose" function on group inputs/outputs has an optional parameter "add_link", which can be used to prevent the automatic linking. 2011-02-22 20:49:34 +00:00
692b711bf4 SVN maintenance. 2011-02-22 20:47:17 +00:00
Lukas Toenne
b3c60ef3ea Added RNA functions to group tree inputs/outputs for exposing internal sockets or adding custom sockets by name and type (fixes #26171). Changed a few function names for groups for consistency. 2011-02-22 20:24:06 +00:00
Nathan Letwory
1f4fc992ef doxygen: bge scenegraph and videotexture 2011-02-22 19:30:37 +00:00
86e6c39f60 Material UI, patch by Ervin Weber (lusque). Thanks!
Now we have the old UI again, as suggested by several developers on the Mailing List. 
At least for simple materials. For Node Materials we keep the new Pipeline panel.

This should make both sides happy. :)
2011-02-22 19:22:27 +00:00
ca930c3208 Bugfix #25967
Node Materials: option "Front/Back" in geometry node failed for
"full osa" case in ZTransp.
2011-02-22 17:19:02 +00:00
354fc0076e Fix for [#26160] Blender Crashes when undoing
Was trying to free audio data from sequencer strips that don't even have audio. Corrected the error in several ways so this will definitely not happen again :-)
2011-02-22 16:32:05 +00:00
Nathan Letwory
5e41760a15 doxygen: add bullet to extern libs, some small changes in page names, and fixes around license blocks 2011-02-22 16:12:12 +00:00
32c13137f5 disable some conflicting options WITH_PYTHON_MODULE 2011-02-22 14:27:46 +00:00
bde2f96257 blender as module - workaround for not knowing __file__ when the module is initialized. 2011-02-22 14:19:09 +00:00
Nathan Letwory
79f79e0cac doxygen: BGE Network, Physics, Rasterizer 2011-02-22 12:42:55 +00:00
eac95abdf2 missing deps for pacman 2011-02-22 12:36:36 +00:00
ef91644d5a Type in snapshort ;) 2011-02-22 12:25:31 +00:00
99d3b68d70 fix for uninitialized stack variable in displaying the modifier template. 2011-02-22 12:19:27 +00:00
8089f857ad Too many ifdefs made me miss the fact variables were declared inside
function...
2011-02-22 12:17:45 +00:00
1ad603c39e No idea why this goes wrong, but I can't get preprocessor output with
cmake here.

Somehow in OSX a function call doesn't return but enters a next function.
Will find around if someone else can make an OSX preprocessed version
of this C file. With this commit things go fine, and it's a sane check
anyway.
2011-02-22 12:01:57 +00:00
Nathan Letwory
148eb5ca9c remove unused code. 2011-02-22 11:43:50 +00:00
d60a5cfc55 feature back from 2.4x where a python error moves the cursor to the error line, added moving to exact column for syntax errors too. 2011-02-22 11:32:29 +00:00
ef6cbc3da0 Fixed crash when sculpting on deformed mesh with smooth brush:
vertex iter should be declared inside omp block or it'll be
thread-unsafe otherwise.
2011-02-22 10:56:49 +00:00
Nathan Letwory
5138615554 doxygen: entries for blenderroutines, converter, expressions, gamelogic, gameplayer, ketsji 2011-02-22 10:33:14 +00:00
7729ecc98f Fix for [#26163] New Texture selectors don't update Texture preview
* Send texture notifier instead of generic property space notifier when texture context is changed.
2011-02-22 10:27:32 +00:00
fdf60eaca1 Bug fix: Fluidsim paths were not handled properly
* Tsk! Using sizeof(string) to determine string length works if the string is a char array, but not if it's a pointer to a char array!
* Now the fluid code uses the actual size of the string directly.
2011-02-22 09:34:43 +00:00
36c6c13a55 missed updating this when modifying addons module. 2011-02-22 09:14:29 +00:00
8186ba15ab last commit used py3.2 function, inline for py3.1 2011-02-22 08:29:25 +00:00
Lukas Toenne
d82ff93fa5 Small fix: reset the NTREE_DO_VERSIONS flag, so new node trees don't get updated in future. 2011-02-22 08:22:06 +00:00
Lukas Toenne
8b5d019139 Fixed missing initialization of node stack entries. 2011-02-22 07:58:49 +00:00
1e120098fc pyapi, use direct access to the frame rather then python attributes. 2011-02-22 07:57:18 +00:00
Lukas Toenne
91357ae2ea Fixed sloppyness bug, used wrong pointer names when calling lib_nodetree_do_versions_group. 2011-02-22 06:45:47 +00:00
12e4c52c5a cmake was using dna source list with the variable out of scope, possibly causing dependency problems. 2011-02-22 06:23:07 +00:00
d13470ba72 patch from sambler on irc, writes version info for OSX. 2011-02-22 06:05:08 +00:00
44e33571ca part of a patch from Dan Eicher with some edits.
- clean svn string: 35042:35051M -> 35051
- debian and pacman build with threads by default.
2011-02-22 05:49:21 +00:00
dd8383e469 make doc generation close files (py3.2 complains about this),
minor formatting changes for C docstrings.
2011-02-22 05:23:20 +00:00
a8f04dfb52 bugfix [#26126] Transparency panel label issue 2011-02-22 05:16:04 +00:00
93d562b7b6 correct example 2011-02-22 04:42:21 +00:00
12d62831b8 fix [#26172] Lattice vertice selection by border selection ( shortcut B ) doesn't update vertice number ( in info header )
missing notifier.
2011-02-22 03:19:58 +00:00
4b859e91cb bugfix/workaround [#25629] Add torus with autmatic edit mode duplicates mesh after >Aling to View.
adding meshes in C does:
 Add Empty Mesh -> Enter Editmode -> Create Mesh

while python does:
 Add Generated Mesh -> Enter Editmode


problem with this is there is no empty undo state for undo-redo to use so it always gave a duplicate mesh on redo-ing.
workaround by adding an empty mesh, do an undo push, and join the generated mesh into the empty one.

this would be fixed if undo stack spanned modes.
2011-02-22 02:47:59 +00:00
36618a0996 operator ED_OT_undo_push, needed for editmode undo/redo glitch fix, (coming next). 2011-02-22 02:42:19 +00:00
b5e3d2a2ea Bugfix #25803 (LibLoad'ed scene objects don't have timer property updated)
The KX_Scenes' SCA_TimeEventManagers were not being merged. These handle the timer prop
2011-02-21 23:44:11 +00:00
648dec3411 Fix for bug #25804 (LibLoad'ed scene objects material CRASH when doing mat.getShader())
X_Material's mScene member variable wasn't properly set on merge if it didn't have an mBlenderShader defined. This patch always makes sure it gets set on merge.
2011-02-21 23:41:47 +00:00
ea20a27240 Editbone length was still using "normalize()" instead of "normalized()"
for setting length, which was thus failing and erroring out.
2011-02-21 20:26:37 +00:00
8327333b40 Accidentally left in a print for commit 34912 2011-02-21 18:18:55 +00:00
Lukas Toenne
4fb730d6d0 Fixed do_versions for node groups which contain nodes that have changed sockets. do_versions is running before the lib_verify_nodetree function updates socket lists of nodes. This means that when adding unlinked sockets in do_versions to restore older node groups, the new sockets are not taken into account. To fix this a temporary node tree flag has been introduced, which delays actual group socket do_version until the group tree internal nodes have been updated. After that the unlinked group sockets are exposed (like old node groups did), then the external sockets look up the new index, so that external links to group instances are preserved. 2011-02-21 18:18:37 +00:00
33887fa41d Bugfix #26116
Node materials with 'ray transparency' set now work again.
Fix provided by Ervin Weber, thanks a lot!
2011-02-21 18:06:52 +00:00
Nathan Letwory
3459c1b26c Finally got around to fixing priorities, so cleanup in stubs.c can be done. blenderplayer builds again with cmake. 2011-02-21 16:41:36 +00:00
b30e59aa71 patch [#26146] debian/rules: Avoid unnecessary downloading
--- from the tracker
It's annoying that build_debian.sh downloads the source tree to create tarball every time we build a deb package.

fix_debian_rules_avoid_downloading.patch modifies debian/rules so that the tarball will be created from local repository if possible.
2011-02-21 13:59:42 +00:00
Lukas Toenne
1c7a422f78 Big node groups improvement patch. Node group trees now have their own lists of input/output sockets. Those can be linked to internal nodes just like links between regular nodes. In addition group sockets can be renamed and have a defined order, which can be modified, and they can be removed again.
More details can be found in the patch tracker description (#24883) and on the code.blender.org development blog.
2011-02-21 13:47:49 +00:00
9ef0eed4b6 build python module without binreloc, add dummy argv[0] to initialize bprogname. 2011-02-21 13:13:08 +00:00
Nathan Letwory
ef60ae9521 And the last one. hopefully. 2011-02-21 13:00:38 +00:00
Nathan Letwory
e2dccc4f33 And another one. 2011-02-21 12:58:16 +00:00
Nathan Letwory
cff782e5f1 Missed this in battle against BLO vs MEM storm. 2011-02-21 12:54:40 +00:00
Nathan Letwory
322ff7dfe4 I swear, it was just an innocence change in guardedalloc!
The butterfly wing flap, causing a nice storm in the rest of blender.

Now all dependencies should point ok again. CMakers, do double-test.
2011-02-21 12:35:04 +00:00
c14aca0e95 add includes to cmake files 2011-02-21 12:18:34 +00:00
Nathan Letwory
d9563f5e2b doxygen: some code shuffle to prevent clashing file names, ensure MEM_guardedalloc.h also shows in docs 2011-02-21 11:38:55 +00:00
e46da7166b remove BGE's PyObjectPlus.isA method docs, was removed in favor of built-in isinstance(), report [#26080]. 2011-02-21 10:15:19 +00:00
cbf44397a9 Fix for [#26105] Key mapped Rotate equals crash (Windows/MSVC only)
* Transform info text array was too short for all cases, so some characters got written to invalid addresses.
2011-02-21 09:28:11 +00:00
Nathan Letwory
212d67734c doxygen: add guardedalloc and AVI 2011-02-21 09:23:34 +00:00
Nathan Letwory
b276624f33 doxygen: footer template 2011-02-21 09:09:27 +00:00
Nathan Letwory
bcec824299 doxygen: COLLADA entry 2011-02-21 08:38:53 +00:00
72d5d692ea better macro for getting the blender version from BKE_blender.h, also re-run CMake if BKE_blender.h changes. 2011-02-21 08:31:00 +00:00
b26a4dc4af fix [#26093] Install Add-On Fails and deletes script
problem was on installing a file which was already installed, when the source and target paths match python deleted the file.

now check if the selected file is inside any of the addon search paths and abort with an error.
2011-02-21 07:33:59 +00:00
Nathan Letwory
8172207d20 doxygen: editor entry 2011-02-21 07:25:24 +00:00
eee4a62e87 move addon utilities into their own module, these were getting mixed between bpy.utils and space_userpref. 2011-02-21 07:07:44 +00:00
Nathan Letwory
8c8ae3dedf doxygen: entry for gpu, modifiers, nodes, python and render 2011-02-21 06:58:46 +00:00
ff84ad3151 fix for cmake with last commit. 2011-02-21 05:28:22 +00:00
848d60caee Move blender version info into BKE_blender.h so we only have the info in one place and so package building scripts can extract it in a more usable way.
this also means we can have a version string like '2.56a-beta' without using buildinfo.

release/VERSION was only used by scons, NSIS installer.

Possibly helps to fix bug [#26062] too.
2011-02-21 04:45:47 +00:00
1e4c17a82f missed updating this when editing registration,
netrender wasn't registering its RenderEngine subclass.
2011-02-21 02:45:13 +00:00
d7bee4ce2c bugfix [#26156] Opening .blend files through OS ignores "Load UI" flag 2011-02-21 02:40:48 +00:00
2ef296dc4c bugfix [#26118] Getting 'Error Totblock' when using sub-properties from a PointerProperty
blender wasnt freeing ID-Properties when freeing the material copy.
Checked that this isnt a problem for other preview types - texture/world/lamp.
2011-02-21 02:07:26 +00:00
54dd0f57cf bug [#26089] editbone.transfrom() seems to mess up bone roll (by more than float precision error)
This is intentional behavior but add options not to transform the bones scale & roll.
2011-02-21 01:29:35 +00:00
7809d7d0c8 fix [#26152] Blender File for Image too Small
disallow 0% rendersize.

also mark new cmake vars as advanced: RPMBUILD, X11_XF86keysym_INCLUDE_PATH
2011-02-21 01:02:30 +00:00
Nathan Letwory
958b5c1d8d Make sure we can build without the optional new WITH_PYTHON_MODULE option. Looks like a #ifndef was meant around the blender_esc implementation. 2011-02-21 00:45:54 +00:00
c30149991c Experimental option to build blender as a python module, rather then blender embedding python.
CMake build option WITH_PYTHON_MODULE, will build ./bin/bpy.so

This allows 'bpy' to be imported from python or other applications/IDE's which embed python, eg:
   python -c "import bpy ; bpy.ops.render.render(write_still=True)"

This runs in background mode and has similar restrictions to running a script:
   blender --background --python test.py

TODO:
 - install to site-packages with blender scripts
 - add support for imp.reload()
2011-02-20 23:39:29 +00:00
55a0e21a03 Revert r35003. It was just an extra semicolon 2011-02-20 23:21:15 +00:00
187f9c5874 Fixed compilation bug in r35002: C90 forbids mixed declarations and code. I've changed the order of variable declarations. 2011-02-20 22:03:49 +00:00
38e7084179 Bugfixes:
- Fix for crash with Keying Sets when a Keying Set path has no ID-
block to target
- Info window now indicates the types of the reports shown by
colouring their entries if the entries are not selected.
2011-02-20 21:32:21 +00:00
06aee2ef0e misc warnings/fixes
- WITH_OPENJPEG wasn't defined for creator.c with CMake.
- remove shadowed/redefined vars.
- remove some unused RNA report args.
- re-arrange IMB_FILE_TYPES so IRIS is not the first format tested, since its not very common test JPEG and PNG first.
2011-02-20 15:48:01 +00:00
8c4e95da48 Fix for crash when sculpting on multires object during playback
- Restored BLI_pbvh_grids_update stuff;
- Marc all nodes as changes in ED_sculpt_modifiers_changed, so
  draw_buffers would be keept correct.
2011-02-20 15:35:01 +00:00
c37884b015 Add XF86keysym.h detection and use to CMake system, for r34983. 2011-02-19 23:51:55 +00:00
43d362fcc8 Bugfix #26150
Crash in hovering over the menu "Pose -> Poselib" sub-items.
NULL context passed on to function and read before the test.
2011-02-19 18:53:08 +00:00
9d81d5f7ac Todo item:
Option menus (like Mapping options in texture) now show a tooltip on
the button itself, explaining the selected option.
2011-02-19 17:18:38 +00:00
e3cc8f00cc From the todo:
New render output option "No Output", which renders without
forcing an editor to show an image. Nice for people who
prefer to setup composites with background image view.
2011-02-19 16:55:01 +00:00
e86b787bcc Bugfix #25967
Shader nodes: option "backface" failed for materials using 
full oversampling.

The usage of shi->flippednorm in render code is heavily messed
up... also flipping vertexnormals themselves feels wrong. 
Marked it in code with XXX for future fixups.
2011-02-19 16:24:14 +00:00
6481921b9a Bugfix #26015
A very Bad Bug!

On every draw-object, a function free_old_images() was called which 
was freeing "unused" images during renders/bakes

This was a left-over from 2.4x code, missed it altogether.

I'm sure this fix will solve a lot of render crashing... :)
2011-02-19 14:32:34 +00:00
e1575e5b58 add 'make debug' option for stub cmake makefile. 2011-02-19 13:46:08 +00:00
65ce537c6c Rename global_ft_lib and make it static.
Remove the XXX code from blf_glyph.c and use the pointer
inside the FontBLF struct.

If still have problem, let me know.
2011-02-19 13:43:22 +00:00
9ee1b3930f set main() argv functions to be const char *
also set minimum cmake version to 2.8
2011-02-19 12:05:20 +00:00
48f232df73 Bugfix #26009
Paint cursors were drawing on top of pop-up menus in 3D window,
only in triple-buffer mode though.
2011-02-19 11:59:01 +00:00
863ac9e07f change shrinkwrap modifier cull front/back options from 2 booleans into an enum since it makes no sense to have front and back enabled at once. 2011-02-19 09:53:38 +00:00
c09e8b3434 fix for string wrap backface culling not working when one of the objects was rotated.
also skip calculating the dot product if its not needed.
2011-02-19 09:01:28 +00:00
e4a69ffb60 fix [#26104] Context Set Boolean op fails [34892i]
could give better feedback but these operators are mainly for internal use.
2011-02-19 04:28:07 +00:00
8cde7ef020 Correct report [#26139] Documentation is incorrect
also remove Irix from list of supported OS's, add FreeBSD.
2011-02-19 00:58:46 +00:00
bb2d0eb230 Add media keys for XFree86/Xorg based X11.
TODO: setup build systems to define WITH_XF86KEYSYM.
2011-02-19 00:12:34 +00:00
d36a89c8f4 Audaspace:
* Adding play method to the device classes to play back a reader (not used yet, preparation for a later feature).
* Using a linear resampler in case SRC is disabled.
2011-02-18 23:50:27 +00:00
020c03bc05 Relicensing audaspace under GPL 2 or later. 2011-02-18 23:47:37 +00:00
346f749a57 Adding support for the "media" play/pause/stop/next/prev buttons
available on many keyboards these days, so that they can be used for
animation playback (giving more options over alt-a and alt-a ad-
infinitum).

Currently, this is Windows only as I don't have a Linux/Mac system to
test on (it should compile with both mingw and msvc, at least using
scons). Maintainers for those systems can probably easily add this in
once they find out the relevant mappings for those systems.
2011-02-18 22:42:03 +00:00
65aac7c506 Fix for building math nodes provided by DustyDingo 2011-02-18 22:15:43 +00:00
24d7606cb8 SVN maintenance. 2011-02-18 19:33:19 +00:00
ce49489da5 Fix #26140: Text to 3D object (one object & one object per line) has the same shortcut
Applying patch provided by Jorge Bernal (lordloki). Thanks!
2011-02-18 19:10:14 +00:00
7a8a9b4875 Bugfix #26101
Node editor: icons in header sometimes were on wrong locations.
The click hotspots were also off...
2011-02-18 17:53:11 +00:00
7a29a44cf4 Bugfix 26131
Option "Align view to selected" only aligned to the last activated
item in editmode. This whilst code comment even said "use alignment
from Manipulator in normal mode".

Now it does what it's (apparently) meant to do, and what brazilians 
think it should! ;) It aligns to selected!
2011-02-18 16:47:10 +00:00
ac35ee4bd5 Bugfix #26135
User Preferences
Using "no AA font" crashed, caused by commit to make static variables.
However, how this was ever meant to work... using such globals has to be
treated carefully. Fixed for now with XXX warning for Diego :)

Thanks to reporter Susanne H. to point at the right code!
2011-02-18 16:13:13 +00:00
13f9715e1c Bug fix: with bigger than 1 cache step dead particles didn't alway stay dead
* Particle die time wasn't properly taken into account when reading from the cache.
2011-02-18 15:21:52 +00:00
a0b88e1c49 Fix for #26111, #26112 & #26121, "only first button click worked in windows"
* In windows the old button was tested to be equal to the new button (ui_but_equals_old()) even if their optype wasn't the same. Adding a check for optypes fixes all three reported issues.
* For some strange reason this didn't happen on other platforms.
2011-02-18 15:06:02 +00:00
0f661b154f Text space fixes:
- Bring back cursor set to PRESS event - block selection wouldn't
  have correct start position;
- Undo stack push was missed in cursor_set operator;
- Remove unneeded cursor moving at set_selection operator;
- Fixed bug with scroll bar - it shouldn't use EVT_TWEAK;

There could be still small issues with selecting single character by
mouse (due to EVT_TWEAK threashold), but this operator is for block
selection, not single char. So shouldn't be big pain here.
2011-02-18 14:55:42 +00:00
Nathan Letwory
71e80f606c Remove #ifdef __cplusplus, as it caused C2732 (differences in linkage). Compiles and runs fine without. 2011-02-18 14:50:49 +00:00
Nathan Letwory
75bcf5b0b1 Remove header include, conflicts otherwise with BLI_math.h 2011-02-18 14:30:36 +00:00
251d27110b examples for bpy.props 2011-02-18 14:27:18 +00:00
Nathan Letwory
d9bca3d491 declare round() and copysign() when on windows. Implementations for them already where in math_base.c 2011-02-18 14:22:46 +00:00
Nathan Letwory
b97ad119b9 doxygen: add blenlib under core as module. 2011-02-18 13:58:08 +00:00
8856b598fd Another small text space usability: option to show right margin (aka print marign) 2011-02-18 13:57:54 +00:00
5531f3093a render engine example thanks to dougal2. 2011-02-18 13:40:13 +00:00
Nathan Letwory
22638e22ea doxygen: blenkernel under core as module. 2011-02-18 13:05:18 +00:00
beed8cfc43 Bugfix #26127
Buttons drawing of floating point values still was using 4 digits
as maxumum precision. RNA definitions for float allows 7 easily.
2011-02-18 12:53:46 +00:00
538ad31bfb Bugfix #26128
Compositor/texture nodes: math node now allows to use pow() for
negative raising too, but only when that value is near-integer.
For other negative cases result is zero.
Patch provided by Aurel W
2011-02-18 12:34:31 +00:00
Nathan Letwory
b74601078d doxygen: readblenfile part of data group 2011-02-18 10:35:37 +00:00
Dalai Felinto
11e3b6b0b5 BGE Expressions: convert "\n" to real \n
example of usage:

0) Game Properties: text (String) and log (Boolean=True)
1) Keyboard Sensor set to AllKeys with log as logging and text as Target
2) Expression Controller: text=="quit\n"
3) Game Actuator: Quit Game

[1] <-> [2] <-> [3] .:. this will quit the game when you write quit + Enter

4) Keyboard Sensor: set to Return
5) And Controller
6) Property Actuator: Assign text property to "" 

[4] <-> [5] <-> [6] .:. this will reset the string everytime you press Enter

# # # # # # # # # # # # # # # # # # # # # # # 
Since the change is in the InputParser.cpp it actually affects all the text
input fields in the Logic Editor. So for instance you can use it in the
assign Property Actuator.
# # # # # # # # # # # # # # # # # # # # # # #
Connect an expression controller: text="idclip\n" with an actuator to disable
the Collision of your walls and you can re-create Doom with only Logic Bricks (:
2011-02-18 10:10:48 +00:00
Nathan Letwory
708df39935 Check the os.environ at the start of the build process.
Print any variable that contains a value with non-ascii
characters, then abort build.
2011-02-18 09:39:15 +00:00
063a7f217b python api docs & examples for registrable Menu/Panel/Operator/PropertyGroup classes. 2011-02-18 08:47:37 +00:00
c4d7bb80f5 "Fix" for [#26130] Turbulence Force Field seed does not look to generate a new texture when the seed changes via IPO keyframe
* Small force field ui changes to make things a bit clearer.
2011-02-18 07:42:38 +00:00
bb05b25942 fix own mistake [#26125] Command line render, absence of CRLF on certain lines 2011-02-18 07:28:10 +00:00
d17df68c24 - clear some warnings
- rename layout.operator_enums -> operator_enum (since we have operator_menu_enum, only called in 4 places)
2011-02-18 06:07:41 +00:00
6524d27462 py api was raising SystemError exception incorrectly, this is intended for internal interpreter problems.
Replace most with RuntimeError.
2011-02-18 06:04:05 +00:00
1dc4db7775 Fix for [#26120] Particle Grid options available when shouldn't 2011-02-18 00:40:15 +00:00
fd155103a2 Particle fluid settings weren't copied when particle settings were copied.
* Also removed some unnecessary null checks.
2011-02-18 00:21:19 +00:00
6a9734821d Particle textures didn't use original coordinates properly for grid distribution. 2011-02-18 00:17:46 +00:00
Nathan Letwory
9e6e34df6c Bring blenloader module under data group. Rename the group to look a bit more sensible in the output. 2011-02-17 23:34:07 +00:00
f77051c2fc fix for build warning with openCOLLADA svn833 reported by Dave Plater.
Also fixed duplicate header define between 2 includes.
2011-02-17 22:57:56 +00:00
a241ce1fd1 patch [#26056] fix for ValueError when no addons are present
by Amorilia (amorilia), fix modified.
2011-02-17 22:38:51 +00:00
27e812d697 Clear some compiler warnings by commenting some functions, adding others to headers.
left in warnings where functions obviously need to get ported to 2.5x still.

Also, render stamp seq strip works again.
2011-02-17 22:34:41 +00:00
456ca98564 malloc() comes from stdlib.h per K&R ANSI C, C89 & C99.
If some plataform really needs malloc.h, that is the exception to get #ifdef.
2011-02-17 21:14:54 +00:00
Nathan Letwory
22dbae84e5 DNA header files are now grouped under the same module. No further documentation done. 2011-02-17 20:48:12 +00:00
8bd04b4c6d One more small text space usability: select work by double-click on it
- Change cursor changing from mouse press to mouse click. A bit "delayed"
  UI feedback, but otherwise we'll be unable to use double-click events here
- Change clinebacks to callbacks in comment for select_line operator.
  Or it was supposed to be clinebacks?
2011-02-17 19:26:59 +00:00
10601a70d5 Simple re-order of first/last point checking when adding point to
NURBS spline. Need to make new point be last in array.

Beziers already has the same behaviour, so things would be more uniform now.
2011-02-17 19:03:12 +00:00
0abc0e0468 Split cursor_set into two operators:
- cursor_set which just sets cursor position immediatelly
- selection_set which could be used to select block of text

Now there're could be operators binded to mouse double-click event
2011-02-17 18:55:17 +00:00
Nathan Letwory
f697247f0e Start simple intros for intern and extern libs.
Some reorg of modules/pages, start makesdna and makesrna.
In many places license block needs to be changed to not start with /**, because otherwise documentation will go weird.
2011-02-17 16:17:40 +00:00
8a63ee46ba Spall text space usability:
Use shift-del to cut, ctrl-ins to copy and shift-ins to paste

Most of editors support this hotkeys and it's annoying when you
trying to use them in text space.
2011-02-17 15:24:43 +00:00
1b25f48542 clear some unused warnings 2011-02-17 12:05:09 +00:00
cf6f6c1c5e patch [#26063] Fix deb package versioning (Patch for #26062)
from Shinsuke Irie (irie),
also updated pacman
2011-02-17 11:49:54 +00:00
0927ad8f4c CMake: remove workaround for cmake 2.8.3 problem testing -Werror=strict-prototypes flag (now 2.8.4 is out).
This is harmless, CMake 2.8.3 just wont build with -Werror=strict-prototypes which is nice for picky devs.
2011-02-17 11:38:02 +00:00
8cbdf89695 OpenGL playblasts now respect Preview Range, making it easier to
render out short segments of shots to be previewed with accurate
timing.
2011-02-17 10:18:14 +00:00
538d9180d3 apply fix [#26117] Recent changes to "mikktspace.c" broke building on FreeBSD. Patch attached.
also check for NetBSD.

note: we probably should use define HAVE_MALLOC_H, seems common for other projects.
2011-02-17 08:35:15 +00:00
Nathan Letwory
fb496b6bad Add missing file from r34923 2011-02-17 08:01:59 +00:00
2ae5c3932d Change to how python classes are initialized when blender calls them.
Annoyance was that operators that defined and __init__ function would need to do...
    def __init__(self, another_self):
        ....

py/rna was calling the class directly with PyObject_Call() but needed to pass the pre-allocated object only so __init__() would run .
This works OK internally but becomes messy since __new__ and __init__ always get the same args there was no way to avoid a superfluous self argument to __init__.
2011-02-17 07:21:44 +00:00
73df566b4a error case not being handled when calling python classes from RNA 2011-02-17 06:56:24 +00:00
c6a0df59e1 incorrect type passed to BKE_free_animdata() 2011-02-17 06:23:16 +00:00
Nathan Letwory
f336b80d7f Starting work on doxygen cleanup. Many things still to be done. 2011-02-17 05:57:18 +00:00
812f238494 pep8 cleanup and remove unused vars/imports 2011-02-17 04:35:41 +00:00
f7295ad6d9 Bugfix: "Tweaking" Markers was working incorrectly
WM_modal_tweak_exit() was making incorrect use of the user-pref option
"Release Confirms Transform", indicated by confused coder comment
(<quote>"XXX: WTH is this?"</quote>).

This manisfested when moving markers by just click-dragging and
existing marker, and having it "drop" whereever the mouse was released
regardless of the user-pref option. This was quite confusing as it was
inconsistent with the way that all other transforms worked when this
option is off, where you would usually start the transform (click-
drag), release the button, move around a bit, and then finally click
to end.
2011-02-17 01:24:52 +00:00
2c4fb98522 Bugfix [#26106] No instant visual feed back for Dupliframes, parenting
problem and crash

- It turns out we still need the "copyob" still, if for nothing other
than making sure that the unkeyed transforms can get restored. This
was removed originally as I thought that just reevaluating the
animation would work.

- Removed a buggy line of logic that was causing crashes when there
was no animation data. It's better to just assume that if animation
data exists, that something exists there.

- Make Duplicates Real was not clearing data such as the new animation
data or constraints.
2011-02-16 21:54:41 +00:00
8ead7b327c 2.5 UI Interface Scripts:
* Code cleanup, seriously we have a lot of unnecessary code!
* Small modification for OpenEXR buttons.
2011-02-16 20:29:23 +00:00
Dalai Felinto
230aed6242 BGE: Action and ShapeKey Actuator PingPong playmode.
I have no idea why this hasn't been implemented before (the DEFINES were even there already). But since the Ipo (Fcurve) Actuator supports it I don't see why Action and ShapeKey shouldn't.
More than a new feature or a bugfix this is actually a step forward into unifying them.
2011-02-16 19:53:39 +00:00
0ea7f1ce15 Material UI: Code cleanup.
Please, don't use a split function if you just have 2 properties in one line, a row is all you need here. ;-)
2011-02-16 19:52:32 +00:00
878c8f47d8 Commit patch [#25939] material panel proposal by Ervin Weber (lusque). Thanks!
From the patch description:
"A new panel is proposed to bring togheter all the properties of a material that belong to the render pipeline level.
Such properties are currently not mixable with node materials, as nodes operate on a shader level."

Commiting this patch as approved in the sundy meeting.
2011-02-16 19:39:45 +00:00
9d168f7337 Bugfix #26096
Switching layers reveiled hidden objects in wrong positions, changes
are currently not being handled for hidden objects. 
Only way to fix it is by completely update newly visible objects...

(Also fixed a typo and a compile warning)
2011-02-16 18:04:03 +00:00
aed7eaf0d9 sphinx doc gen: multiple examples possible and include the scripts docstring inline in sphinx.
also tag unused vars
2011-02-16 17:31:04 +00:00
6b12fa8fed Bugfix #26103
Halo texture: disabling texture slot with [] button didn't work.

Note: halos only allow 1 texture slot, UI allows to add more. This
rna template stuff for texture slots I rather don't touch though...
2011-02-16 12:34:08 +00:00
1c32356b4f Marker Drawing Bugfix:
Removed superfluous blend-mode change which was causing some weird
white lines to appear, especially when using some markers that don't
have any names.
2011-02-16 12:00:53 +00:00
f6911cfe38 Fix for [#26102] Particle Texture mismapped on Multires (in some modes)
* Particle modifier didn't check for particle textures using uv-coordinates properly.
2011-02-16 11:38:28 +00:00
d6da81be38 Forgot to actually hook up this operator... 2011-02-16 11:28:25 +00:00
ef920a50da Particle settings can now be pinned too:
* Particle system's are comparable to texture slots, which can
  only exist within an id block. Particle settings on the other
  hand are idblocks which should be pinnable just like textures.
* When particle settings are pinned only properties that make
  sense without the actual particle system are shown in the
  particle panel.
2011-02-16 10:57:58 +00:00
d450e35f21 Added full texture idblock controls for displace and wave modifier. 2011-02-16 10:23:27 +00:00
e6879c7646 Correct texture pinning:
* Now texture pinning works consistently for all textures.
* The only problem is that there is no way to pin textures if there are
  no textures in the context path, so it's for example impossible to pin
  the texture of a displace modifier without adding a texture somewhere
  else and selecting that texture first. I my opinion this is quite
  counter productive so perhaps a dedicated "only textures" texture
  context option is needed after all.
2011-02-16 10:22:19 +00:00
430bb75749 enum-flag arguments were incorrectly documented. 2011-02-16 10:19:14 +00:00
ac1e2fc977 Bugfix [#22535] Dupliframes with keyframe Anim are broken
So, it turns out that dupliframes weren't that bad to restore... the
old version didn't do truly accurate transform freezing as it didn't
update ancestors too. However, as a modelling tool, this will probably
suffice.
2011-02-16 09:59:29 +00:00
b7d349e09c The modifications in mkktspace broke compilation on gcc 4.2.x
This is a patch proposed by sparky_ on irc.
2011-02-16 08:49:27 +00:00
437bdbc96c PoseLib Bugfixes, Cleanups, and Missing Operators
* All the various index-related issues should finally be sorted now.
It seems you cannot just partially implement some of these active
index getter/setters...
* Standardised the call used by PoseLib operators to get the Object
from which they get the active PoseLib data from
* PoseLib operators which require some existing data to work now use a
poll() which checks for this
* Added back the operator used to make standard actions into ones
usable by PoseLib
* Added a dummy operator for the apply active pose button which really
just calls the same backend functions as "Browse Interactive", but
which has a nicer frontend (naming + description) for the purpose of
being used in this way
* Also, removed some useless code from here
2011-02-16 06:18:20 +00:00
7748860aeb doc generation support for excluding some modules, without this a full rebuild takes too long to test changes.
also include own function definitions for blf_dir.c.
2011-02-16 05:18:10 +00:00
85edbd5f8d fix from mikes for building on apple with gcc 4.2.1 2011-02-16 05:03:33 +00:00
4c35d8d5a8 rename IDPropertyGroup to PropertyGroup
also renamed IDProperty to PropertyGroupItem (these are not referenced for common usage and we already have 'Property' defined).
2011-02-16 02:51:56 +00:00
fee5363912 bugfix [#26094] Going to Bone Roll menu brings up python error
also correct for pep8 warnings.
2011-02-16 02:25:03 +00:00
78c135d93e Fix for compiler warning: forgot to hook up a poll callback I defined
for unlinking PoseLib data
2011-02-16 02:10:26 +00:00
7756da34c9 PoseLib UI and Bugfixes:
- Added operator button to show the current pose. This runs on top of
the interactive pose browse functionality, so the tooltip may be a bit
obtuse...
- Specifying a pose for the Pose browse functionality to set now works
correctly. Previously, some old depsgraph hacks were actually
interferring with correct updating (only the armature updated
correctly, but deforms didn't occur)
- Fixed a case of accessing freed memory, which I'm surprised no
static checkers have reportedly picked up on yet, or that nobody has
really had issues with (probably due to low memory "turnaround" so
far)
2011-02-16 02:05:41 +00:00
669cffdb1e fix [#26098] python API: quaternion.rotate never seems to work. 2011-02-16 02:05:36 +00:00
f5217afd18 Ugly hack to get PoseLib UI working ok (problem mentioned in log for
r34883).

Full description:
When defining an operator button in the UI layout code, trying to set
the value for such an operator's enum properties, where said enum uses
a dynamically generated list of items (which depends on using context
info), will "fail". No context info will be passed to the callbacks
used to generate this list of items, as PROP_ENUM_NO_CONTEXT is still
set on the operator properties (it seems these will only get cleared
when the operator actually runs, which is far too late already for
this usage) so RNA_property_enum_items() will pass NULL instead of a
context pointer *even* when one exists!

I'm not sure of why we even need this flag. It seems to have caused a
few other rounds of problems already, from quick searches I did on
this matter...
2011-02-16 01:46:32 +00:00
c39aba0f82 Bugfix: Browing Pose Libs should work now... RNA wrapping was missing
an "editable" flag there
2011-02-16 00:19:54 +00:00
147309e3c5 Pose Lib: Start of PoseLib UI in Armature buttons
This presents a UI from which PoseLibs can be assigned/removed from
Objects. From here, it is also possible to see the list of poses and
add/remove poses from this list.

Known Issues:
- [Py/RNA/Operators BUG ALERT!] If after immediately starting Blender
you try to remove a pose from the PoseLib using the UI buttons, you'll
get a an error the first time you do so (but not for subsequent
attempts). This seems to be caused by the "pose" enum (dynamically
generated) of the POSELIB_OT_pose_remove operator, which does not seem
to be getting initialised when the operator's exec gets called without
the invoke having been called previously
- Changing the active Pose Library still seems to be broken (to be
fixed soon)

Todos:
- Operator button to make the selected pose get shown in the 3d view
- Restore the "validate action" operator and add that to this panel
- Rename pose access
2011-02-16 00:17:22 +00:00
c195e68e8e small correction to BGE as recent commits broken normal mapping in the GE 2011-02-16 00:04:37 +00:00
Nathan Letwory
b94be2aa14 Fix from sparky for compile problem with older GCC 2011-02-15 19:57:33 +00:00
610917d52e removed some more magic constants
another fix: the patch for #25806 was submitted by Riakiotakis Antonis and not by Andrew Wall
2011-02-15 19:22:08 +00:00
e9ff1b98cb - Do not use old anchor toggling operator. It used to set brush flags to
unawaliable state.
- Also changed dynamic space bar menu, so it now also wouldn't allow to
  set brush stroke flags to unavaliable state.

Also tried to remove use_anchor, use_space, use_restore_mesh and
use_airbrush, so user would be unable to set flags to unavaliable state,
but it was quite difficult for non-sculpt paint modes. They don't support
all of stroke methods, so brush.stroke_method can't be used for them.

Keep this area unchanged for now.
2011-02-15 19:19:36 +00:00
c461a7ea4d patch from IRIE Shinsuke, use systems openjpeg on *nix. 2011-02-15 19:04:51 +00:00
7fba9eab47 added more code comments and removed some magic constants 2011-02-15 19:04:00 +00:00
15570631fd a fix for bug #25806
http://projects.blender.org/tracker/index.php?func=detail&aid=25806
Thanks Andrew Wall for the report and the patch
2011-02-15 18:36:42 +00:00
52c08fa4d3 CPack packaging support from Dan Eicher, tested to build redhat RPM's, a Mac bundle also defined. 2011-02-15 18:33:05 +00:00
8845163574 menu to select an enum from an RNA path:
eg,
   bpy.ops.wm.context_menu_enum(data_path="scene.tool_settings.vertex_paint.brush.stroke_method")

This saves us defining operators only for menus.
2011-02-15 18:12:41 +00:00
35c03e85ef - Use the same logic as for BEZIERs when making segment of between
first and last NURBS' control points (toggle cyclic flag)
- Show U/V selection menu only for surface objects. There's no
  much logic in asking U/V direction for simple curves.
- Set active spline when two segments were joined.
2011-02-15 16:37:44 +00:00
c4ad7b4ebe Fix #26087: in a curve, can't make segment if Fkey was pressed 2 times before on a single vertex
- Disallow setting cyclic flag for single-point segment when this lonely
  segment is selected
- Clear cyclic flag for single-pointed segments when finding segments which
  can be merged
2011-02-15 16:09:53 +00:00
cb12d708c7 Doc generator now makes 'bpy.context' api reference.
http://www.blender.org/documentation/250PythonDoc/bpy.context.html

strings are extracted from blender to ensure all values are included, currently there is no type info so this is stored in the doc generator.
2011-02-15 15:37:40 +00:00
78bb53a1bf Fix for [#26083] Animated Particle Textures have no effect
* Duplicating particle settings didn't duplicate texture slots.
2011-02-15 15:03:49 +00:00
86cf6b4016 moving dir strings into global namespace for doc access (coming up) 2011-02-15 14:38:43 +00:00
efb21625bf ...and for blenderplayer 2011-02-15 12:43:34 +00:00
f94256ea5c fix for building with make on linux from recent new lib. 2011-02-15 12:37:15 +00:00
e63b51a9ab PoseLib: Adding support for custom properties
Custom properties are now supported by Pose Library. They will get
saved and restored correctly during previewing and pose adding.

To do this, I've changed PoseLib over from using the "LocRotScale"
Builtin Keying Set to the "Whole Character" one instead. One
consequence of this, is that now entire poses are stored in the Pose
Lib, irrespective of whether you only selected part of a pose to store
(i.e. facial controls only, or hand poses only). If this is enough of
a problem, I'll make a second Keying Set that does take selections
into account, and use that here instead.
2011-02-15 11:47:09 +00:00
d5316768c3 corrention for bpy.props docstrings. 2011-02-15 11:43:35 +00:00
Nathan Letwory
3ce233e28d Move mikktspace code to own library, so it is clear that it is also
intended as a standalone library for use in other applications that
want the same tangent space as Blender.

This also keeps blenkernel clean(er) from extra math functions.
2011-02-15 09:24:35 +00:00
be8c8942f4 fix for own error with image info display, also dont draw if the mouse is outside the image. 2011-02-15 04:06:13 +00:00
07e9cfef81 fix warnings. 2011-02-15 03:20:12 +00:00
b47bfd85e8 UI Tweaks: Text field in Rename Markers popup now gets focus when the
popup appears, saving an extra click

I've separated out the "XXX"-'d event-adding-hack section from the
search-menu code into a separate API function (as recommended there).
This call is used to make sure that textboxes in popups can get
activated by default, to allow typing immediately.
2011-02-15 01:24:12 +00:00
dab76a3ccf Ctrl-0 can now be used to just reset a single component of an array to
its default value instead of resetting the entire array
2011-02-15 00:53:20 +00:00
Nathan Letwory
d4ebace149 Tweak priority so link error on Linux is solved. Reported by Hypercrush on IRC. 2011-02-14 21:00:49 +00:00
ba0d167d2a more vars made static 2011-02-14 18:20:10 +00:00
20553d4064 This commit will switch blender to use tangent space generated within
the two files mikktspace.h and mikktspace.c. These are standalone files
which can be redistributed into any other application and regenerate the
same tangent spaces. The implementation is independent of the ordering
of faces and the vertex ordering of faces.
2011-02-14 18:18:46 +00:00
8b7482892b made most variables which are only used in a single file and not defined in header static for blenlib, blenkernel and editors. 2011-02-14 17:55:27 +00:00
d7e2607f96 Fix #26082: Fkey in a curve witch was empty before
Stupid error in own previous commit to addvert_Nurb -- empty spline
had been added to spline list.
2011-02-14 17:17:05 +00:00
c66ce21a86 Bug fix #26021
Very nasty UI code issue: since every button is re-defined on a
redraw, having UI redraws while using a button was not possible.

This was solved long ago by copying over data from previous button.

However, this fails when buttons have callbacks with its own (or
a parent button) pointer. 

This bug reporter found crashes in draw-overlap UI mode, this 
draws entire UI over for every menu redraws, making previous button
pointers invalid. (for triple buffer, the UI is not redrawn, only
the menus).

In general: all systems falling back to old swapbuffers would have
suffered some instability because of this.

Fix is that now the old button gets lifted out from the previous
list and inserted in the new list. Works fine, but needs some tests!

Also in this commit: TIFF endian switching not needed for 16 bits tiff.
2011-02-14 17:09:02 +00:00
8ee0c96f4b Previous commit to small optimization of sculpting broke smooth and layer
brushes. They aren't using proxies, so deformation wouldn't be propagated
in sculpt_combine_proxies().

So, maye idea of getting rid of "extra" memory allocaiton/disposing was not
such cool due to it lead to such exception ways?
2011-02-14 16:54:52 +00:00
2b9c9e3ad9 First modifiers with deformMatrices callback used to be applied twice when
building crazytspace. Not sure why this worked.
2011-02-14 16:06:15 +00:00
d845d6308a comments for how py-rna calls api new classes. small speedup for StructRNA.__new__(...) used for creating new classes and corrected exception type. 2011-02-14 11:30:35 +00:00
a3c2ad34b1 improve py/rna exception messages. 2011-02-14 08:14:52 +00:00
a6765280f9 py rna api: turn class.is_register into a class property rather then a class method.
eg:

if MySybclass.is_registered:
    ...
2011-02-14 07:26:07 +00:00
44be05f7f9 convenience targets for makefile
clean, test, package_debian, package_pacman
2011-02-14 06:15:23 +00:00
665a0ff789 Revert incorrect fix for 26062 made in svn rev34828. 2011-02-14 06:04:40 +00:00
7b201c7693 SVN maintenance. 2011-02-14 04:47:55 +00:00
72bc3f22b7 python api renaming and added headers for some files which didnt have one, no functionality change. 2011-02-14 04:15:25 +00:00
54190dd8e5 Bone Colour Sets (theme ones) can now be edited from the User
Preferences UI again
2011-02-14 03:43:28 +00:00
0c2099086b Active spline number should also be stored/restored by undo stack.
It could point to nowhere otherwise.
2011-02-14 03:36:15 +00:00
8ea0b4685c misc small changes:
- rename rna collection structs Main prefix to BlendData: eg, MainObjects --> BlendDataObjects
- printing python collection now prints its type (when available)
- renamed shadowed vars in bpy_rna.c.
- when making functions static I also made debugging/test functions static, reverse and add definitions to headers instead.
2011-02-14 03:15:55 +00:00
35abb674b2 Forgot NLA Editor support for this... 2011-02-14 03:04:59 +00:00
b8a19d3a43 Graph Editor part of the changes in the previous commit... 2011-02-14 02:50:52 +00:00
52525a00f7 DopeSheet: Add menu entries and hotkeys to select all keyframes
left/right to current frame in dope sheet

This commit separates out this selection functionality out of the
click-selection operator into a separate operator, so that hotkeys and
menu entries can be assigned to it.

This is based on an idea+patch (#23738) submitted by Torsten Rupp
(rupp), though I've ultimately decided not to go with the suggested
implementation as I don't think this fits that well under the "column"
select operator.

Todo: Graph Editor support will be coming shortly...
2011-02-14 02:30:33 +00:00
650916941e fix for string copy error in own recent commit 2011-02-14 01:31:44 +00:00
4ca2905ead Fix #26062: build_debian.sh gives unappropriate deb version
Added subverison number to debian package version. Quick tests run ok,
but haven't checked if deb version comparation also goes fine.
2011-02-13 19:47:57 +00:00
3224f8197f Fix #26072: ctrl+LMB on an empty curve make Blender crash
Crash was caused by keeping active segment index even when this
segment had been deleted. Fixed this and also changed behaviour
of creating new CV for case nothing is selected: new segment with
BEZIER type would be created.
2011-02-13 19:04:01 +00:00
59f1640ae5 warning cleanup.
- fix mistake with grease pencil UI (&& was intended but & used).
- use (void) rather then () across _all_ blenders code.
- a few minor edits, don't shadow stack variables in roll calculation & avoid running memset() for VBO vertex map.
2011-02-13 15:02:21 +00:00
0852278ce7 Patch 26068
Fast-gauss node didn't respond to socket-input "Size" factor.
Thanks Philipp Oeser for the fix!
2011-02-13 14:55:39 +00:00
4124804b4e many functions in blender are not marked static but should be.
most local modifier,GPU,ImBuf and Interface functions are now static.

also fixed an error were the fluid modifier definition and the header didnt have the same number of args.
2011-02-13 14:16:36 +00:00
63cc6b44e7 Bugfix #26066
Shader node "Mapping" had buttons assuming it stored radians, drawing
the values converted wrongly. In this case the storage has degrees...
2011-02-13 13:55:41 +00:00
7b4c4183f3 Small addition to particle grid distribution:
* New option to distribute particles in a hexagonal grid.
* This is much more stable for fluids than normal grid distribution and looks quite nice otherwise too :)
* Also some small scale code cleanup of grid distribution code.
2011-02-13 13:50:19 +00:00
c68a59175e corrected error from commit r34810. 2011-02-13 13:07:12 +00:00
b4eb7fd4c0 fix for error building. 2011-02-13 12:50:40 +00:00
7eb51a012b Some more fixes for particle textures:
* Moving a texture slot didn't keep the moved slot active.
* Copy & paste for particle textures didn't work.
* New textures weren't freed properly.
2011-02-13 12:35:26 +00:00
fed5393043 Fix for [#26053] Blender Crash with Particules Textures
* Particle textures weren't handled properly on texture slot move operations.
2011-02-13 11:45:04 +00:00
cc41de09a0 Added an operator warning for missing material & texture in response to [#26051] "Noise" not working. 2011-02-13 11:32:47 +00:00
0955c664aa fix for warnings from Sparse static source code checker, mostly BKE/BLI and python functions.
- use NULL rather then 0 where possible (makes code & function calls more readable IMHO).
- set static variables and functions (exposed some unused vars/funcs).
- use func(void) rather then func() for definitions.
2011-02-13 10:52:18 +00:00
f3bd89b1b7 Related to #26061: Camera does not appear selected in outliner when it is
Draw higlighting circle for active camera in outliner
2011-02-13 10:34:24 +00:00
dfb1395fa5 Fix #26064: blenderplayer is broken
This changes were forgotten in svn rev34810. Should work fine now.
2011-02-13 10:28:40 +00:00
9ac8c5315e Fix #26059: select_vertex_path fails when vertices aren't selected 1 by 1 in gui
Cicrcle and border selection doesn't add entry to EditSelection. Use cycle
through vertices rather than EditSelection stack to find two selected vertices.

No slowdown for case two vertices are selected (use this cycle to clear temporary
flag too), minor slowdown for unsupported selections.
2011-02-13 10:25:12 +00:00
90f543ba3a Reverting part of 34810
The changes here were breaking old rigs, for example the right eyeball
in the Sintel rig (which uses the Mirror Modifier and its vertex-group
mirroring functionality)
2011-02-13 07:39:43 +00:00
51d78b43de Fixing compiling on windows 2011-02-13 06:19:15 +00:00
867fc4b463 enforce string limits (reported by pedantic checking tools & some developers).
mostly replace strcpy with BLI_strncpy and multiple strcat's with a BLI_snprintf().
also fix possible crash if CWD isnt available.
2011-02-13 03:21:27 +00:00
9e03a0d476 remove unused var 2011-02-13 02:55:23 +00:00
93f061fac3 wrong length used with strncmp when comparing RNA path. 2011-02-13 01:59:16 +00:00
373fea6662 Small update for billboards:
* Renamed the old split uv's animate option "time" to "age" and added a new option to change the used split frame by frame. These are good changes were suggested/implied by Hannu Hoffren over 3 years ago in his tutorial video! (oh my how time flies)
* Also cleaned up the billboard ui quite a bit. For example now the uv channels can be properly chosen from the existing channels.
2011-02-12 23:25:03 +00:00
54b2127fad Fix for [#25857] create_dupli_list incorrect behaviour with particle systems
* Particle duplis are now always created with render percentage if G.rendering is set.
* This is not yet a perfect solution (hair for example won't yet work correctly), but
  it's good to have even partial functionality here until a proper way to handle this
  is implemented.
2011-02-12 21:54:50 +00:00
0a83817672 Small particle effectors update:
* Greetings from farsthary: particle rotation is now taken into account for particle effector direction.
** This gives all kinds of new possibilities as he shows in his blog http://farsthary.wordpress.com/2011/02/08/vortex-particle-simple-tut/.
**The only modification I made to his patch was to use the actual rotated particle direction as the effector direction as this defaults to the particle velocity vector, so no actual new options are needed.
* I also added an "effector amount" setting for particle effectors so that only a part of the particles can be considered as effectors. This makes it possible to create simple "farsthary vortexes" with only one particle system.
* Also some tiny reorganization of the falloff min/max values for a nicer ui.
2011-02-12 17:54:24 +00:00
d909e61d99 Sculpting on deformed mesh
==========================

Removed limitation of armatured-only objects for sculpting -- now all
deformation modifiers are allowed in sculpt mode. Use crazyspace corrections
like from transformation modules was used to support all deformation modifiers.

Internal change: all crazyspace-related functions were noved to crazyspace.c

P.S. Brush could make quite unexpected deformation for meshes which are
     deformed in specified way. Got patch for this and discussing with Brecht
	 if it's really needed or maybe it could be done in better way.
2011-02-12 17:51:02 +00:00
673ac43f2e Save one memory block allocation/disposing when propagating changes from
deformed PBVH to the base mesh.

It's not real bottleneck, but crazyspace corrections looks nicer now.
Real bottleneck is normals re-calculation, which calls plenty of
fsqrt's. We could avoid this for some modifiers (which don't use
normals), but such checking would make code less controllable.
2011-02-12 17:28:37 +00:00
55f68c3657 fix for more warnings.
- modifier code was using sizeof() without knowing the sizeof the array when clearing the modifier type array.
- use BLI_snprintf rather then sprintf where the size of the string is known.
- particle drawing code kept a reference to stack float values (not a problem at the moment but would crash if accessed later).
2011-02-12 16:54:24 +00:00
9eee1f962d Warning fix to my previous commit. Thanks to nazg-gul for noticing! 2011-02-12 16:06:27 +00:00
62602c797d Fixing a recounting bug so KX_Scene.pre_draw.append() and KX_Scene.post_draw.append() work. 2011-02-12 15:44:09 +00:00
fafbd9d71b Particles todo item: particle textures
* Effecting particle properties with textures was possible in 2.49,
  but not in 2.5 anymore.
* Now particles have their own textures (available in texture panel
  for objects with particle systems), which are totally separate from
  the material textures.
* Currently a basic set of particle properties is available for
  texture control. Some others could still be added, but the whole
  system is not intended as an "change anything with a texture" as
  this kind of functionality will be provided with node particles in
  the future much better.
* Combined with the previously added "particle texture coordinates"
  this new functionality also solves the problem of animating particle
  properties through the particle lifetime nicely.
* Currently the textures only use the intensity of the texture in
  "multiply" blending mode, so in order for the textures to effect
  a particle parameter there has to be a non-zero value defined for
  the parameter in the particle settings. Other blend modes can be
  added later if they're considered useful enough.
2011-02-12 14:38:34 +00:00
c8c86aa6a1 - fix leak on STL loading if realloc fails.
- transform code was using sprintf reading and writing the same string (undefined behavior).
- softbody had unneeded NULL check.
2011-02-12 14:25:54 +00:00
6e47ffcc0d fix for uninitialized value in BLI_path_cwd() if PWD wasn't defined and the CWD was longer then 160. 2011-02-12 10:37:37 +00:00
9e9e028f05 access past array bounds in layerInterp_mdisps, also make some vars const. 2011-02-12 10:18:21 +00:00
3396f73c17 fix for possible (but unlikely) problem with strncpy not adding \0 and then extending the string with strcat. use BLI_snprintf instead. 2011-02-12 09:58:28 +00:00
5af9e5fda9 - resource leak in pointcache, opendir without closedir()
- reading pointcache was using an incorrect, always NULL variable.
- commented NDof code, was giving warnings and isnt used now.
2011-02-12 09:09:52 +00:00
e70ca00f71 - move keyingsets_utils.py into modules.
- add gplv2 header
- define __all__ so when importing '*' it wont being in locally defined vars.
2011-02-12 08:12:00 +00:00
9bd57cd302 update templates for registration changes 2011-02-12 08:04:32 +00:00
0a4eb24ca0 fix for building with opencollada 833 on linux. 2011-02-12 06:25:04 +00:00
92672d0c1c quiet some clang warnings. 2011-02-12 05:12:26 +00:00
5470a7af5d render stats_background() was giving clang warning about unused argument and wasn't checking for buffer overrun (though this would be very unlikely).
write to the stdout directly rather then building a string and writing that. (no functional change).
2011-02-12 01:02:21 +00:00
6554ae1460 SVN maintenance. 2011-02-11 19:36:58 +00:00
8e7a61b1c4 Bugfix #26021
On certain buttons, and only when not in triple buffer, pressing
RMB "Add shortcut" crashed Blender. NULL check missing.
2011-02-11 18:29:52 +00:00
91b967c79a Fix #26039: Relative Shapkeys have wrong coordinates after inserting vertices
There was invalid memory access for newly created vertices.
Added checking of keyindex value when calculating verticies offsets.
2011-02-11 17:56:25 +00:00
7f5dbb7de0 Fix #26040: Crash converting curve to mesh
Really stupid mistake :)
2011-02-11 17:43:56 +00:00
f9fb95b9c1 Made some function from DerivedMesh.c be avaliable from other modules.
Some naming changes to make naming more uniform. No functional changes.

It's necessery for further crazyspace changes and improvenments.
2011-02-11 15:15:35 +00:00
dcf7642f76 Bug fix for problem 2 in [#25973] Bake End Frame Not Configurable
* External caches didn't load for smoke straight away. Smoke caches store all necessary info in every file, so no need to try to look for an info file.
2011-02-11 14:59:19 +00:00
c50bf404d2 patch [#25978] mathutils fixes for bpy_types.py and vertexpaint_dirt.py
from Filiciss Muhgue (filiciss)
2011-02-11 12:30:17 +00:00
875f554cff patch [#26030] Debian spec fix (Patch for #26028)
from Shinsuke Irie (irie)
2011-02-11 10:29:47 +00:00
Lukas Toenne
69e72ea427 Removed the internal_select parameter from ntreeCopyTree. This was used just in one place when duplicating nodes, which is not an actual copying of the tree. The node duplicate operator now copies selected nodes itself. 2011-02-11 09:37:58 +00:00
a3d142fce0 update pacman spec for newer python and match naming convention to debian spec.
also pre-compile python modiles.
2011-02-11 09:28:11 +00:00
Lukas Toenne
9fea58ca91 Made group label callback function static. 2011-02-11 07:46:06 +00:00
7f6946d4f7 add torus script wasnt registering. 2011-02-11 03:42:36 +00:00
65b922ad88 cls.is_registered() class method for python subclasses of internal types.
Synonymous with ('bl_rna' in cls.__dict__)
2011-02-11 02:40:14 +00:00
17efeb310d bpy.utils.register_module() generator could go into eternal loop. 2011-02-11 01:27:00 +00:00
2f4f046b6f UI functions added to existing UI classes (operators adding their own menus for eg),
would stop the entire menu from drawing if they raised an exception.

now print the exception and continue.

Also added a verbose argument for bpy.utils.(un)register_module() to help test whats being registered.
2011-02-11 01:12:01 +00:00
b1cdf5c344 use weak references for the internal metaclass typemap,
this should help with blender leaking memory with python classes though the bug is still not fixed.
2011-02-11 00:39:07 +00:00
fb8c135584 minor python register changes.
- KeyingSetInfo classes are now collected like Panels, Operators etc so bpy.utils.register_module() can be used.
- move bpy.types.register() to bpy.utils.register_class
2011-02-11 00:11:17 +00:00
Dalai Felinto
8fd81ab9e6 BGE: frame start/end in action/fcurves/shapekey to support floats
after discussion over the mailing-list it seems that it really makes no sense to restrict that. Specially since we have the "Property" playback mode that usually will be a float.

Since there is no need for do_version or whatoever I don't see a problem. Any Thoughts? Maube to allow it only through the Python API?
2011-02-11 00:03:26 +00:00
4612034cf4 patch [#25809] Auto-Registration as utility function.
This removes auto-registration, committed by Martin r30961.
Realize this is a contentious topic but Brecht and myself both would rather opt-in registration.

TODO:
- addons need updating.
- class list will be modified to use weakrefs (should have been done for existing system too).
- will move bpy.types.(un)register functions into bpy.utils.(un)register_class, currently including these functions in a type list is internally ugly, scripts which loop over types also need to check for these.
2011-02-10 23:48:22 +00:00
Lukas Toenne
46bb5643b7 Different method for blur node aspect correction. Now the user can still set different sizes for x/y blurring in relative mode, but choose to use aspect correction on either of the axes. 2011-02-10 20:54:02 +00:00
Lukas Toenne
cbe53cc48d More options for the blur node filter size. This can now be pixel based or relative to both axes or just either width or height. 2011-02-10 18:54:49 +00:00
f7595e9882 Bugfix #26013
Good discovery this one. 
It appeared that "pose mode" changes were not registered in our undo system.
That way the first operator you try to redo after exit posemode fails.
2011-02-10 17:23:00 +00:00
d505b745fc Bugfix #26001
Adding a byte rect to float ImBuf was always freeing the mipmap levels.
Removed this convention since it crashes renders + image texture draw.

Proper ownership handling of ImBuf is high on the wish list :)
2011-02-10 15:47:55 +00:00
d240206c88 fix for crash with GLSL material when image couldn't be loaded.
also quiet pep8 warnings.
2011-02-10 14:59:17 +00:00
1817a045b4 mesh validation remove duplicate faces didn't always work, now it _should_ all work correctly. 2011-02-10 14:13:13 +00:00
7daabec534 mesh validation: bugfix for removing doubles, another fix coming... 2011-02-10 12:34:52 +00:00
763e8d0bec Bugfix [#26004] compositor: backdrop zoom factor too small
The backdrop zoom factor for new node-editor instances was not set
(i.e. was default initialised to 0). Now, this gets set to 1.0.

Also, set the property default in RNA to match this.
2011-02-10 10:24:05 +00:00
5dffb64675 Bugfix [#26002] Outliner Visible layers + Single object & data = broke
conections

It seems that some of the Outliner hacks used while building the tree
was causing problems, as Make Single User (and potentially other code
working with ID-data, specifically with the "newid" value there) was
making use of the variable used there for other purposes, leading to
memory corruption.

This bug also occurred in 2.4x, though when I tested there, it crashed
immediately.

Ton, you may want to double-check this bug!
2011-02-10 10:14:12 +00:00
fc3b29b637 Small consistency fixups 2011-02-10 09:39:55 +00:00
264c8c2162 mesh.validate() now returns True if any corrections were made.
tested that correcting invalid meshes works by generating random meshes and checking that only the first call to mesh.validate() makes changes.

found 2 bugs in mesh validation.
- face sorting array wasn't assigned correct indices.
- removing invalid edges used wrong comparison.
2011-02-10 09:29:31 +00:00
0356e3b69f script to build debian packages directly from svn, using blender version and svn rev for package name. 2011-02-10 07:22:56 +00:00
1eb7d3bd9e debian package spec [#26007] Debian spec
by Dan Eicher (dna)
2011-02-10 06:11:16 +00:00
c397e8b4e0 Bugfix [#25831] Sorting channels broken
Recoded animation channel sorting code. In particular, the old code
didn't handle "islands" of selected items well (i.e. a chain of
several connected items in a row), with some of these cases having
unpredictable results.

There were also some bugs in the way some of the rearranging methods
worked, allowing some invalid operations to be performed. Some of
these probably triggered errors such as some channels getting stuck,
and so on.
2011-02-10 05:15:05 +00:00
30ada8fdd3 fix [#26003] Twice applied modifier with Convert to mesh with several multi-user objects
convert_exec could do with a re-write, getting quite confusing.

update md5's for ctest results and some renaming in mesh_validate code.
2011-02-10 04:48:49 +00:00
0ebf448bee small fix so older files are loaded with merge on in the mirror modifiers 2011-02-10 00:44:26 +00:00
cbe544fb6c Set default for merge mirror to ON 2011-02-10 00:25:00 +00:00
446299db1c small feature request from zanqdo, merging in the mirror modifier is now optional, simply turning town the merge limit just simply do anything, and merging is off by default as this seems more logical behaviour 2011-02-10 00:05:03 +00:00
ea50e5f587 Update mesh normals when undoing sculpt stroke to prevent shading
artifacts in some cases (enter edit mode/disabling modifiers after undo)
2011-02-09 15:38:49 +00:00
97c57abfa3 fix [#25994] Meshes with no vertices gets NaN location on setting origin to geometry 2011-02-09 15:32:39 +00:00
5aa72b8726 BKE_mesh_validate() now corrects invalid meshes (optionally), added access for python so it can correct for bad imported geometry - mesh.validate(). 2011-02-09 15:13:20 +00:00
38e5081839 Restoring the old behavior of switching texture context based on active tab:
* Once again switching to texture panel from material, world or lamp data tab sets the texture context automatically to the "parent context".
2011-02-09 11:03:11 +00:00
81a00cf2eb use static functions rather then defines for internal matrix__apply_to_copy() and similar.
+ other minor internal changes.
2011-02-09 09:20:17 +00:00
0884147698 fix [#25968] Crash on changing merge distance in array modifier with edgesplit modifier in chain 2011-02-09 04:45:53 +00:00
f6733d90e5 bugfix [#25523] Face extrude will crash Blender if array and subsurf modifier are added to mesh object
test_index_face() failed to fix indices like (6,0,0,6), making it (0,6,6,0).
2011-02-09 03:49:59 +00:00
5e1eb9b4d3 SVN maintenance. 2011-02-09 03:48:40 +00:00
3e8ddef8e5 move validation into blender kernel so it can be called by internal modifier funcs more easily. 2011-02-09 02:28:11 +00:00
30552f9f46 patch [#25972] blender-thumbnailer.py: GVFS support
from Shinsuke Irie (irie) with some minor edits.

Shinsuke's description from the tracker:
---
I have implemented GVFS framework support of blender-thumbnailer.py which allows some file managers like Nautilus and Thunar to show thumbnails in trash or network directories. If Python's gio module is available, the thumbnailer uses it to access to filesystems mounted via GVFS. This change shouldn't affect desktop environments other than GNOME and XFCE.

A function gvfs_open() in this patch is defined to solve a stupid incompatibility between Python file object and GIO Seekable object.

On Ubuntu 10.10, I confirmed thumbnails can be generated for file://, trash://, sftp://, and smb://.
2011-02-09 02:09:30 +00:00
4eb76a1a90 Graph Editor: Added option to turn off AA drawing for performance
gains when using really heavy files
2011-02-09 02:09:25 +00:00
fdf60ba4a6 mesh validation function to report errors and help debug bad data generated by modifiers.
detects...
- invalid vertex range for edges/faces
- duplicate indices in edge/face
- duplicate edges/faces in mesh
- missing edges data in faces

At the moment it doesn't correct errors, but eventually it will do this.
2011-02-09 01:27:46 +00:00
2a67a126e8 Fix for rendering procedual bump maps, mapped in world space, since the new bump map kernel uses direction, this bug became a real issue, with bumps suddenly changing direction
Fix provided due to a long session on IRC with Morten S. Mikkelsen (sparky_)
2011-02-09 01:21:03 +00:00
f56d1a5e2c Old animation conversion code cleanups:
- Tidying up some inconsistent formatting
- Names of old IPO blocks are now included in the names used for new
actions. These are included after a "CDA:" prefix, (i.e.  "_C_onverted
_D_ata _A_ction:"), which makes it easier to browse through these
actions later.
2011-02-09 01:16:11 +00:00
99c1a9a427 Bugfix [#25987] Duplicated markers naming issue
One-liner fix - a missing "OPERATOR_FINISHED" on the select operator
was causing problems renaming markers and potentially with other
operations too!

To find this bug, I added debug method to dump the list of markers to
console. This has revealed some troublesome things about the way
markers are organised, which IMO need to be addressed.
2011-02-09 01:05:40 +00:00
adfbb83cdf Bugfix: When removing the "only insert for active keyingset" option
for Auto-keying from the UserPrefs, I forgot to remove the option from
the UI there.
2011-02-09 00:52:53 +00:00
aff23c92cc Bugfix [#25990] backward compatibility with ShapeKey Actions :: 2.49
-> 2.50

Actionified ShapeKey IPO-blocks (i.e. "Shape Key Actions") would have
an action channel with the hardcoded name, "Shape", and this action
would be assigned to Object level (although ShapeKey blocks had their
own IPO-block slot, only Objects could have actions, so actionifying
ShapeKey IPO-blocks would wrap a ShapeKey block's IPO's to an Object-
level action).

Hence, the path conversions code would wrongly interpret this action
channel as referring to a Pose Channel instead, thus creating some
invalid paths with a 'pose.bones["Shape"]' prefix wrongly getting
tacked on. To ensure that the converted animation can work out of the
box, a 'data.shape_keys' prefix is now used instead so that these
actions can still be Object-rooted while still being able to correctly
control the Shape Keys. This is because there's no easy way to
identify and then shift such action from Object-level to ShapeKey-
level within the conversion code. The consequence though is that such
converted ShapeKey actions CAN ONLY BE USED THROUGH OBJECT LEVEL (i.e.
via Action NOT ShapeKey editor).

Secondly, the Action/ShapeKey editor version patching code has been
modified so that if a ShapeKey editor view was active when loading an
old 2.4x file, the action gets cleared from the view. This is because
of this didn't make semantic sense: the ShapeKey editor is for
ShapeKey-rooted actions, while the Action Editor is for Object-rooted
actions. The converted files though let Object-level actions be shown
in either one.
2011-02-09 00:51:30 +00:00
711ba795f7 ignore __pycache__ dir for scons and cmake installation (py3.2 caches modules here). 2011-02-09 00:45:16 +00:00
32e3aac6bc use update() rather then update_tag(), needed for making edge data. 2011-02-08 21:32:26 +00:00
4ac2d60800 jahka IRC fix
pinning the texture properties gave python errors.
2011-02-08 16:24:00 +00:00
496a78a593 bugfix [#25969] GLSL missing an update on texture slot change
what did I learn from this?
"if at first you don't succeed..
   you're not kaito." ;)
2011-02-08 14:33:08 +00:00
811a1b910c Texture context selector for texture panel:
* Texture context was previously determined by going to the appropriate panel, for example "world panel -> texture panel" to access world textures. Additionally there was a separate button to access brush textures.
* Now the texture context can be selected directly through an expanded icon menu, which shows the available context options.
* This context selector is now at the top of the texture panel, but this could later be perhaps integrated to the context path somehow to be more intuitive.
2011-02-08 14:29:48 +00:00
9e73ac2b9f Bugfix #25957
RMB click in InfoWindow "console log" was missing call to set subwindow,
needed because it uses opengl picking to find active lines.
Result was that entire UI was glCleared, for some buffer swap methods.
2011-02-08 13:48:06 +00:00
1bfd780456 fix: latest shader wasn't working on itel gfx-cards
couldn't use 
a = ( float_function() < 0 )? b: c;
for whatever reason.
2011-02-08 13:40:54 +00:00
Lukas Toenne
24db3d17aa Per-type node labels and customizable names. The label displayed in the node header is now by default the node type string. A custom label callback can be implemented to display more detailed information. This is currently used by group nodes, which display their internal tree name, and math, vector math, mix and filter nodes, which use their internal operation sub-type. Also the node tree selection/naming box for groups is now displayed only on open groups, to make it clearer that this is the internal type of the group and get a cleaner main tree. 2011-02-08 12:54:32 +00:00
cd95dd42d7 fix own recent error [#25977] Torus disappears when adding "Subdivision Surface"
ID's and meshes both have update functions, call the meshes rather then update_tag() for recalculating edges.
2011-02-08 11:20:19 +00:00
e511f9fac4 add back options for loading a renderlayer to offset the image when copying the buffer to a smaller renderlayer.
This was reverted by Brecht r22541 because its inefficient but there is no way to work around this with povray at the moment so adding it back as optional args.
2011-02-08 10:31:47 +00:00
71ec3f03fb Text Editor Bugfixes:
The poll() callbacks used in the Text Editor for scrolling and text-
block unlinking operators were too restrictive when the text block was
lib-data.

- Scrolling lib-linked texts is useful for just checking out parts of
the linked-in file that aren't visible on screen already. For example,
checking the specific rig that some UI panels script will work on, or
reading a "README.txt" linked in with notes on which layers various
controls are on. It should be fine that this temporarily modifies the
linked text-block (but for view-settings which will can be reset
later/on file load without any real consequences).
- Unlink operator should be able to be run, otherwise it would be very
difficult to remove linked files from a file (?)
2011-02-08 09:57:51 +00:00
Lukas Toenne
37f55ec194 Group node type info is now also initialized with helper functions. 2011-02-08 09:14:18 +00:00
Lukas Toenne
803c7fb4d4 Finished the node type definition cleanup started in r34682. All static node types should now use the node_type_* definition helpers to initialize their bNodeType structs. 2011-02-08 09:02:16 +00:00
914e2ee01f problem with blender and python 3.2
- python 3.2 does 'import site' on startup which now tries to parse pyconfig.h which isn't copied. so for now just run without importing 'site', alternative would be to copy the header file for posix systems.
- cache PYTHON_VERSION variable so it can be set to 3.2, needed for copying python installation's other then 3.1.
2011-02-08 06:22:06 +00:00
9d6f9e74d4 Bugfix [#25814] ChildOf constraint: double transformation in object
mode with drivers

ChildOf constraints added using the PoseBone.constraints.new() method
via Python scripts instead of using the operator (this latter method
is still the preferred/recommended method) were not getting some
critical flags set, causing errors arising from space conversions
being performed more than once.
2011-02-08 05:51:20 +00:00
53afd19808 fix [#25975] Quaternion/Vector.negated() isn't available
theres no need for value.negated(), better use -vec / -quat. however -quat didn't exist.
2011-02-08 03:37:49 +00:00
0242a96f3b Change in behavior to shrinkwrap modifier's offset value with negative enabled.
- negative ray casts would invert the offset direction.
  this meant if positive and negative were enabled at once and the mesh was slightly inside & outside the object it wrapped,
  the offset would be applied in opposite directions.
  This way the offset is always along the vertex normal.

- allow negative offset from RNA, could be useful and no benefit to disable.
2011-02-08 02:09:59 +00:00
89bb5e6423 [#25693] Netrender "shadow" images with last frame always appear
Render engine postprocess property was not named properly
2011-02-08 01:56:36 +00:00
98268ba40f fix [#25801] Shrinkwrap Offset problems with Project mode.
The positive result from the previous ray-cast is used again, inadvertently negating the offset from the first hit (acts as if no offset is applied).
2011-02-08 01:43:16 +00:00
1befe8ba4a un-initialized flag used with commit r34695. 2011-02-08 00:18:00 +00:00
33265983da fix own error in recent commit [#25970] cannot create scale matrix after mathutils updates 2011-02-08 00:10:30 +00:00
6c21f4713b mailed Stani Michiels and he's ok to switch his console autocomplete to GPLv2 or later. 2011-02-08 00:01:15 +00:00
d454d6c6bc Bugfix: Constraint target validation code was broken
While testing Apply Visual transforms last night, I noticed that
setting a constraint to use its owner as its target was allowed and
didn't trigger any warnings. This clearly doesn't do any good and is
different from the old behaviour.
2011-02-07 23:21:28 +00:00
0d8416acc7 minor edits, no functional changes.
- BGE was getting MCol array and not using it.
- use list lookup functions for getting constraint from pose bone.
- use const char * in more places.
2011-02-07 22:48:23 +00:00
16160f5fcc GLSL shader part
bump-mapping update to properly support
multiple textures in different bump-spaces.
2011-02-07 21:57:40 +00:00
a6baee5298 bump-mapping update to properly support
multiple textures in different bump-spaces.

kudos to M.L.Mikkelsen (sparky) for helping with the math! :)
2011-02-07 21:55:54 +00:00
Dalai Felinto
462b5823f4 Logic UI: Game Actuator options renaming
After talking with Ton Roosendaal we agreed on making those changes.
I wonder if we should go for "Start Game" instead of "From File". But Space is not a constraint here so be it.
2011-02-07 18:42:07 +00:00
Dalai Felinto
0a55958196 Logic UI: Armature Actuator + general Captalizing 1st letter of UI text
- Armature Actuator now only shows the "Secondary Target" option when the Bone Constraint supports it (IK only now).
-- that may be overkill I don't know. It shouldn't slow down the UI considerably, so it should be fine. Easy to revert if needed though.

- renaming things such as "Start frame" to "Start Frame"
2011-02-07 18:24:15 +00:00
c8be8a7c6d Bugfix 25965
New "auto render" now prevents calling anim-updates, that's
not needed (and popped back transformed keyed objects).
2011-02-07 18:09:27 +00:00
5c421c328e Todo/feature request
When using masks or other simple 3D elements in composites, doing
a layer re-rendering on a node is a bit clumsy all the time.

This commit does two things to help:
- new hotkey "Z" in node editor automatically finds render layer
  that changed and re-renders it + composites
- option "Auto Render" does same, but then after every transform
  edit in 3D window

The latter is experimental; real & proper system for this requires
full threaded render support (like previews). But it works!

Demo file:
http://download.blender.org/demo/test/auto_composite.blend

Important fix:
After any render, all the render layers were tagged "changed", which
caused any edit to first totally recomposte everthing. Now it only
composites changes.

Implementation notes

- DAG scene flush now sets 'changed' flags in render layer nodes
- Added notifier for 'transform finished' to trigger the update,
  this is temporarily.
2011-02-07 16:41:57 +00:00
831ce612e9 Fix for [#25963] Show mouse option in wrong Panel.
Did some reorganization of the Game buttons, made a new "Display" Panel.
2011-02-07 14:53:40 +00:00
bd023c443b remove mat_nr from MVert struct, saves 4 bytes per vertex.
used to be used for halo's
2011-02-07 13:02:44 +00:00
3fab280c61 Argh! This code is haunted... (line 666) compiler here isn't barfing
on these errors tonight :/
2011-02-07 12:37:14 +00:00
926f168e44 AnimSys Todo: Scene/CompoNode Driver Hacks
Drivers for Scene, World, and Compositing Nodes now "work" (well,
sort-of)! Previously they were strictly restricted to object-
accessible data only; now they can function across the board (give or
take some weak spots).

Although there is still no depsgraph support so that these properties
update properly when their source controls are changed (this will
probably require a lot more work), they can still update under other
circumstances (i.e. frame change and/or manual refresh flushing via
mouse movement, etc.)

As the depsgraph tagging support is lacking, these just get always
executed for now, which might potentially be quite sluggish, though it
is hoped that there are so few of these top-level datablocks with
drivers hooked up that this is barely an issue in practice. At least I
haven't noticed any substantial slowdowns for animation playback, so
it should probably be fine.
2011-02-07 12:28:04 +00:00
7710d82007 fix [#25926] lattice + projection on surface snap issue 2011-02-07 12:07:26 +00:00
ea012a3340 Bug fix: adding force fields from the add menu didn't sort the depsgaph, so hair didn't update straight away to force field settings changes. 2011-02-07 11:55:24 +00:00
a399e8c7bb Compiling commit for previous commit... 2011-02-07 11:51:28 +00:00
44fb6bd1fa Hair ui simplification:
* There were a lot of settings in the particle panels that made no sense for simple hair and only cluttered up the ui.
* Now these settings are hidden by default unless "advanced" hair options are shown.
* Without advanced options the particle velocity controls are replaced by a simple "hair length" value, which actually corresponds to the grown hair length in blender units.
* Some hair effector options that are actually very useful were not shown in ui. These are now found in the "field weights" panel.
2011-02-07 11:43:33 +00:00
a17d81cabf add access to radius for game objects (static objects can have radius) as well as anisotropic friction. 2011-02-07 11:42:49 +00:00
fd422e58a8 Visual Keying Code Tweaks:
Moving this code to the same method as is used for Apply Visual
Transform (for bones case), which uses standardised decomposition
methods instead of the improvised ones used here before. This was in
an attempt to get IK chains Visual Keyed correctly, though this
doesn't seem to have improved the situation much.

Also, the decompositon for objects here now takes care of euler
rotation modes.
TODO: other rotation modes should get included here too...
2011-02-07 11:38:57 +00:00
cddaa815d6 Fix for [#25955] Hair paths under force field influence look jagged
* Effectors were applied wrong for hair.
2011-02-07 10:54:55 +00:00
1dc11c4fdf Bugfix [#25934] "Apply Visual Transform as Pose" not working?
Simplified the code for Apply Visual Transform as Pose.

This makes it work for IK chains now, since there aren't any
recalculations of the pose involved now, which were contributing to
the pose getting incorrect as the applying process went on, since the
IK chain was getting calculated differently with each successive
change to the chain.
2011-02-07 10:50:35 +00:00
Lukas Toenne
2070356a32 A simplified way of defining bNodeType structs. Instead of doing full struct member initialization for each node, this uses a couple of helper functions now. This will make it easier to change and extend the bNodeSocket interface in the future. Two examples (normal and mapping shader nodes) included, the rest should be converted too. 2011-02-07 09:33:36 +00:00
d272b70ee0 rename ID.update() --> update_tag() since this function only tags for updating and scene.update() executes the update. 2011-02-07 08:13:28 +00:00
ad8c79405a Type checks for internal ID-Property UI min/max/tip & use defines to get values from ID-Props.
Probably wouldn't cause a problem but manually editing these types through python could easily crash blender.

also changed cmake, stub-makefile default build dir to be lower case and leave out architecture string, easier for documentation.
Use ../build/linux/ rather then ../build/Linux_i686/
2011-02-07 05:05:41 +00:00
a018bfba9a comment unused var 2011-02-07 01:45:52 +00:00
a4f0c29a23 PoseLib Bugfix:
When using Pose Lib with a search string, if the search fails after
typing a character and then you try to backspace to get back to the
previous search string, the pose does not refresh until you type in
another valid letter such that the search works again.

Did a logic reshuffled in the get next preview pose function so that
this is dealt with properly
2011-02-07 01:28:47 +00:00
6165508bc5 patch for building blender with CMake, OpenEXR & MSVC2010 by Peter K?\252mmel 2011-02-07 01:23:18 +00:00
c9acbc6404 - own error with sound unpack operator using NULL pointer
- make stub now creates 'Release' build by default.
2011-02-07 01:13:21 +00:00
55da733eba PoseLib Preview/Browse Bugfixes:
- [#25951] Hardcoded Keys in PoseLib modal operator register twice per
use
Now only the KM_PRESS events are handled. KM_RELEASE events for these
are ignored...

- While checking the above, I also found that the view-manipulation
while previewing functionality was broken. This was one of the
benefits of this UI approach over a fixed screenshot-only listview.
Fixed now :)
2011-02-06 22:20:26 +00:00
c03064b187 Bugfix #25953
Fix in crashing displacement last friday, assumed wrongly that
the old 'new bump' failed for displacement too. It still did
work (somewhat). This restores the situation again.
2011-02-06 18:38:53 +00:00
216f9af08e Two in one:
- Bugfix #25937
  Child-of constraint now behaves like regular parent-child
  relationship when all options are set. This prevents the 
  errors that can happen when decomposing non-uniform matrices.

- Todo item
  The area corner hotspots for splitting/merging were far too
  narrow. Now it uses a circular distance to detect whether
  the hotspot is active. Also cleaned up drawing code for it.
2011-02-06 17:36:42 +00:00
0ea9271f43 Bug fix: Particles in dupligroups were mostly drawn properly in 3d view, but rendering them was a real mess.
* After countless different bugs particles should now render correctly inside dupligroups.
* Only particles with metaball visualization are still problematic, this is mostly due to the ancient metaball code.
* I'll also add a test file for some of the situations, so that hopefully these cases stay fixed :)
2011-02-06 15:50:00 +00:00
d9aa3f66a6 mathutils.Matrix.Scale(factor, size, axis)
- 'axis' arg was not coerced from a tuple like other args now do.
- 'axis' arg was being modified in-place (VERY BAD).
- also made new function matrix_3x3_as_4x4().
2011-02-06 11:17:22 +00:00
1cdab667bc - cmake was missing an inclide (IDE's wouldnt index)
- made doc generation always sumlink newly built docs to static URL. http://www.blender.org/documentation/250PythonDoc/
2011-02-06 10:18:20 +00:00
c82da98f3d bugfix [#25824] Quats + Camera + Fly = Madness
ensure quat, delta rotation is set to a unit quaternion on older files.
2011-02-06 09:01:01 +00:00
967299ad97 fix [#25947] Smart Project is broken SVN r34664
own recent mathutils updates broke this script.
2011-02-06 06:59:11 +00:00
48a8cba7a9 fix [#25948] blender-thumbnailer.py does incorrect checking for the number of arguments
noticed by Shinsuke Irie (irie)
2011-02-06 06:54:19 +00:00
6705d5c7e7 SVN maintenance. 2011-02-06 00:49:58 +00:00
dd924bb93b [#25693] Netrender "shadow" images with last frame always appear
More debugging info with -d

Also fix some conditions that didn't check the proper list in the ui.
2011-02-05 22:46:59 +00:00
2ed0ddef04 todo list item:
3D View:
In quad-view mode, the options to set back/bottom/left views were
blocked. Now they work again.

Note: the oparator polls don't have a check for properties... so it
cannot be finegrained here. Checks are inside code.
2011-02-05 19:07:54 +00:00
00d95fb4bf Another fix for the raytracing commit, forgot that it also included vertex
reordering to be consistent with the rest of the render engine. That means
the self intersection issues with non-planar quads should also be gone now.
2011-02-05 17:54:00 +00:00
6011bac989 Bugfix #25944
Save image (F3) didn't remember the last saved path on 2nd use.
2011-02-05 16:32:56 +00:00
dbce60448f This fixes: [#25608] Video Sequence Editor: problem using cut on a strip with a custom proxy file. 2011-02-05 15:11:29 +00:00
626de1f3a2 Bugfix, own todo
Saving a file for the first time (after opening blender) didn't
use the last directory as saved/loaded from in a previous session.
2011-02-05 15:05:17 +00:00
04299657a7 Raytrace modifications from the Render Branch.
These should not have any effect on render results, except in some cases with
you have overlapping faces, where the noise seems to be slightly reduced.

There are some performance improvements, for simple scenes I wouldn't expect
more than 5-10% to be cut off the render time, for sintel scenes we got about
50% on average, that's with millions of polygons on intel quad cores. This
because memory access / cache misses were the main bottleneck for those scenes,
and the optimizations improve that.

Interal changes:

* Remove RE_raytrace.h, raytracer is now only used by render engine again.
* Split non-public parts rayobject.h into rayobject_internal.h, hopefully
 makes it clearer how the API is used.
* Added rayintersection.h to contain some of the stuff from RE_raytrace.h
* Change Isect.vec/labda to Isect.dir/dist, previously vec was sometimes
  normalized and sometimes not, confusing... now dir is always normalized
  and dist contains the distance.
* Change VECCOPY and similar to BLI_math functions.
* Force inlining of auxiliary functions for ray-triangle/quad intersection,
  helps a few percentages.
* Reorganize svbvh code so all the traversal functions are in one file
* Don't do test for root so that push_childs can be inlined
* Make shadow a template parameter so it doesn't need to be runtime checked
* Optimization in raytree building, was computing bounding boxes more often
  than necessary.
* Leave out logf() factor in SAH, makes tree build quicker with no
  noticeable influence on raytracing on performance?
* Set max childs to 4, simplifies traversal code a bit, but also seems
  to help slightly in general.
* Store child pointers and child bb just as fixed arrays of size 4 in nodes,
  nearly all nodes have this many children, so overall it actually reduces
  memory usage a bit and avoids a pointer indirection.
2011-02-05 13:41:29 +00:00
90cf78eb54 Fix bones moving when changing between editmode and posemode.
Patch #25901 by Tobias Oelgarte.

Bone transformations would be converted back and forth between different
representations when changing modes, which due to numerical errors could
lead to bone transformations slowly changing as you edit the armature.

Now the editmode head, tail and roll values are stored in bones and used
directly when entering edit mode. Head and tail were already there but
now we ensure they are the exact same value, roll was not yet there, so
we have a version patch for it.

The sub version was incremented to 1 for the version patch.
2011-02-05 13:19:14 +00:00
fe99f35210 Renamed texture.c in render module, to prevent debuggers to
complain about the same named file in blenkernel.
2011-02-05 13:10:20 +00:00
df9fade564 Bugfix 25871
Using displacement with new bump caused NaN values or crashes.
Since displace code doesn't provide derivatives, it now falls
back to "old bump" by default.
2011-02-05 13:07:51 +00:00
311f5a8d78 accidentally left scaling code commented out when testing. 2011-02-05 11:46:44 +00:00
d694115ac4 mathutils fixes noticed when refactoring.
- comparing eulers was ignoring the order.
- printing Euler()'s now prints the order too.
- un-orderable types (all except for Vector's), were not raising an exception when compared with >=, >, <, <=.
2011-02-05 10:40:42 +00:00
998198a041 mathutils rotate functions for Euler/Quaternion/Matrix/Vector types.
each accept Euler/Quaternion/Matrix types.

eg:
  Euler.rotate(Quaternion(axis, angle))
  Vector.rotate(Euler((pi/2, 0, 0)))

matrix.resize_4x4() and euler.make_compatible() were still returning an instance of themselves, now return None.
2011-02-05 09:57:02 +00:00
8b52087d83 update for changes in mathutils. 2011-02-05 07:04:23 +00:00
dd08305e75 Rename python mathutils functions and split in-place methods from those that return new values.
http://wiki.blender.org/index.php/Dev:2.5/Source/Python/Mathutils
This completes the changes proposed.

This will break scripts (fixing coming up next), for full list of changes see mathutils.c comments.
2011-02-05 06:14:50 +00:00
Dalai Felinto
f2a6395e21 Logic UI: multiple fixes on Constraint Actuator
1) damping factor is not percentage (it's in frames, who would know that)
2) angles as degrees (cleaning the tooltips for those too)
3) setting Direction to None when changing from Loc and Fh Consts to Ori - negative axis is not supported in Ori Const. Buggy since ever (2.49).
2011-02-04 21:25:57 +00:00
25044dfa1b - Drivers should now be updated correct when curve changes topology
- Fixed regression with keeping alive f=curves for deleted CVs
  (was a mistake in previous commit in this area)
2011-02-04 21:10:27 +00:00
849ce60a32 Fix #25923: Active area of text editor line numbers too big
Area with width 60px was used for determing should we jump to line or
input new cahacter. Reduce this area to actual line numbers margin width.
2011-02-04 16:28:19 +00:00
4925581820 Fix #25933: Drag Dog stroke method uses Jitter if set for other stroke method, but no jitter available.
Manually disable jitter usage for anchored and drag dot brush stroke metdhods.
Jitter slider is hidden in UI for this strokes so users can't set it to 0 by hand
and even if this slider would be visible in UI jitter gives wierd result for
this stroke methods.
2011-02-04 16:10:30 +00:00
4e8a8d1e8f Improvements for particle grid distribution:
* Particles that aren't shown are now actually deleted (huge memory savings for flat objects).
* Grid distribution for flat objects is now done on the surface object surface without offset.
* Invert grid option wasn't in ui and it didn't work for non-volume grids.
* New parameter to randomize the grid point locations.
* Resolution soft/hard limits changed to even 50/250.
2011-02-04 15:48:13 +00:00
Nathan Letwory
b407702c5f Fix [#19997] Duplicating window results in graphics corruption in UI
reported by Micael Dias (and many others, see duplicates list)

On closing the first ("main") Blender window the very first OpenGL context
got deleted too. This context needs to be retained, since we share quite a
bit of OpenGL data through it to the newly created contexts (new windows).
Thanks to Ton Roosendaal for thinking out loud while trying to figure out
what the actual cause was.
2011-02-04 13:22:02 +00:00
Nathan Letwory
f3a19f4324 small typo fix 2011-02-04 13:18:44 +00:00
deefe52821 Quick Animation Feature: Paste Pose "Selection Mask" option
After discussions with ZanQdo, it was agreed that the current workflow
for making a pose symmetrical was a bit too cumbersome, especially
when auto-keying was enabled, requiring pasting the flipped pose on
another frame so that the changes could be merged back in without
overwriting the "good" half of the rig.

This option for the Paste Pose operator makes things easier, by adding
an option which will make the pose only get pasted on to selected
bones instead of overriding the entire pose. By default this option is
turned off, but can be easily enabled either from the toolbar
(operator properties) or through the F6 popup.

The intended workflow with this option for making a rig symmetrical is
now:
1) Copy pose
2) Select "bad" bones
3) Paste Flipped
4) Enable "On Selected Only" for the operator

If there is sufficient interest, this option can even be enabled by
default. But, we'll see about that later
2011-02-04 11:43:30 +00:00
2ef93b1d92 swap Matrix.Shear(...) arguments so matrix size is the second argument, matching other constructors. 2011-02-04 09:41:59 +00:00
feed9c3d1f mathutils.Matrix.OrthoProjection(plane, size, axis), merged axis and plane args. since axis was only allowed when plane was 'R'.
This was already done with Matrix.Rotation().
2011-02-04 09:35:20 +00:00
736a7b7a22 pep8 cleanup 2011-02-04 09:27:25 +00:00
f0eb3b56de hard- and ui-limit for particle grid resolution were vice versa. 2011-02-04 09:02:47 +00:00
a155d8895d Moved Auto-Keying "Insert for KeyingSet only" option from UserPrefs to
Scene (Toolsettings, i.e. alongside "layered" option for using NLA
while doing auto-keying)

This option makes all Auto-Keying operations use the active Keying Set
to carry out keyframing operations instead of picking and choosing
their own Keying Sets to use, thus cutting down on the number of
unwanted keys.

Warning: if the older userpref option was enabled in an old
startup.blend, it may be difficult to turn this option off.
2011-02-04 08:33:07 +00:00
ce5dc02c8c fix for make stub, readlink was used incorrectly and building didn't work on BSD because of CPU detection. 2011-02-04 04:12:24 +00:00
4be9583894 small mathutils changes.
- fix for returning empty slices (was returning list rather then tuple).
- report invalid type when mathutils_array_parse_fast() fails.
2011-02-04 03:39:06 +00:00
36786c18d7 PyAPI: coerce mathutils values. (vectors, quats, eulers) as proposed here:
http://wiki.blender.org/index.php/Dev:2.5/Source/Python/Mathutils#Coerce_Method_Arguments
2011-02-04 03:06:23 +00:00
9d24a17422 SVN maintenance. 2011-02-03 18:57:53 +00:00
b64811b330 - Fixed bug with disappearing curve animation data created in edit
mode for case there was no animation at object before enter editmode
- Fixed memory corruption for case of fcurve groups
- Fixed bug with incorrect re-naming "spline[%d].smth" pathes

TODO:
  - Also update drivers' curves
  - Enable I-key menu and autokeying

  Will do this after consultation with Aligorith, shouldn't harm atm.
2011-02-03 17:03:37 +00:00
54aa4fa3a2 Bugfix #25912
Render bug in spothalo (weird horizontal line).
Appeared to be precision error... even for doubles,
before doing division a check for FLT_EPSILON works
better than DBL_EPSILON (if there's an alternative).
2011-02-03 16:31:03 +00:00
6a23716957 Applying patch #25898 by Shinsuke Irie for rendering total external reflections
* Tracing objects with IOR < 1.0 (like air bubbles under water) wasn't working correctly as a refraction was always assumed to be the first thing that happens for transparent materials.
* This fix is ok, but the fact that the internal renderer is not a physically based one is starting to show, as for example blurred reflections in this case are not really possible nicely without some slightly heavier modifications to the ray code.
* Also some cleaned up logic and better comments for my previous total internal reflection commit.
2011-02-03 15:05:43 +00:00
376e0ae2a3 Audio Bugfixes:
* [#25638] 'Insufficient thread locking' for sounds
  - Actually a workaround for an msvc bug, msvc STL containers are buggy
* [#25922] Sound does not play in BlenderPlayer(r34579)
  - Windows OpenAL doesn't seem to have clear context error state on initialising
2011-02-03 13:25:05 +00:00
1e3ec65edc remove unused variable
also clear scene data before running batch import (utility script).
2011-02-03 11:02:02 +00:00
07e688125a Makefile for convenience on *nix systems.
Running 'make' starts an out of source build with CMake in ../build/OS_CPU, creating the dir and configuring CMake if necessary.

So casual users can just run this without changing dirs:
 'svn up ; make'
2011-02-03 10:07:15 +00:00
fc0d85ac59 Bugfix #25913
Compositor: using "read sample buffers" after load file, without
render layers in composite, crashed blender (NULL read)
2011-02-02 14:36:00 +00:00
f79f9115f2 Fix for [#25899] Renderer can't trace successive total internal reflection
* This was wrong since 2006!
* Raytrace code assumed refractions to go "air -> glass -> air -> glass -> air.." so actually only the first total internal reflection was calculated correctly, but everything after that was wrong.
* Now after a total internal reflection there needs to be an actual refraction before the ray escapes the "glass" object.
2011-02-02 12:04:23 +00:00
a7af789864 Added Read Render Layers and Read Full Sample Layers to node editor menu 2011-02-02 10:33:29 +00:00
14ef1e2d96 Keymap conflict in node editor. Read Render Layers is now Ctrl R to
leave R for rotate
2011-02-02 10:26:14 +00:00
691f2abad1 fix [#25684] Grease pencil strokes with "Surface" option attach erratically to curves.
added new functions
- view_autodist_depth_segment()
- plot_line_v2v2i(), which takes a callback and plots x/y points.
2011-02-02 03:32:58 +00:00
b04bccd44e Bugfix [#25907] Impossible to "select all" on narrow action editors
Marker selection operators now use a special poll() callback which
checks that there are some markers before trying to run them. This
means that when there are no markers, the full screen range is
available, instead of just those areas above the region masked off for
markers which can be quite slim when trying to save space by only
showing the summary channel.
2011-02-02 03:12:39 +00:00
c57cd7c5bd bugfix for setting the worldspace matrix of an object which used quaternion rotation and deltas, was subtracting the values rather then multiplying by the inverse.
effected 'Apply Visual Transform' & pythons obj.matrix_world = mat
2011-02-02 01:01:01 +00:00
95df65f1b5 - some parts of the code to remove rotation were not removing axis/angle rotation (only functional change of this commit).
- use BLI_math functions for removing rotations from objects and pose channels.
- add unit_axis_angle() to avoid setting the Y axis inline anywhere rotation needs removing.
2011-02-02 00:40:55 +00:00
19efa4301a fix crash from report [#25746] Adding keyframes to nested custom properties (IDProperties) of a bone causes segfault
though keyframing still doesn't work, it gives an error instead.
also use const char * in more parts of the py/rna api.
2011-02-01 23:53:54 +00:00
501703020a "Batch-Edit" Code cleanup: Renaming ED_operator_ipo_active to
ED_operator_graphedit_active
2011-02-01 23:51:52 +00:00
efd1d0f901 Bugfix [#25902] alt+a over 3D view don't up date dropesheet editor
Migrating "redraws" settings from TimeLine view data to per Screen.
The options are now still shown in the TimeLine "Playback" menu
though.

This means that whatever redraw settings you set in a TimeLine editor
will be used throughout a screen (i.e. editor layout) to determine
which editors will get updated during playback, instead of only
certain editors doing certain things at vague times.

---

Also, I moved some version patches pre 2.56 version bump into a
version-check for 2.56. These must've been missed when doing the
release...
2011-02-01 23:41:01 +00:00
b8d9d10a65 Action Editor UI Tweaks:
While animating, I realised that actually the 'only selected' and
'include hidden' DopeSheet filtering options are also useful in the
Action Editor, especially while tweaking the animation for some
characters, where you'd like to focus only on some of the character's
control (i.e. eyelid tweaks, hand tweaks, etc.).

The other DopeSheet filtering options aren't so relevant here, so I've
excluded them from this.
2011-02-01 22:21:43 +00:00
bc36e39c23 fix issue #2 raised by report: [#25894] Problems with properties across files 2011-02-01 21:24:59 +00:00
1c2bb084ac partial revert for r34590, exclude render() from enabling the read-only state.
will re-open [#25845] and assign to Brecht.
2011-02-01 20:38:24 +00:00
f5e2669444 Icons in outliner were jittering a bit on sizing of the area.
Subpixel position issue... when is this ever correct? :)
2011-02-01 17:54:02 +00:00
482af562eb Fix #25884: Crazy behaviour of the rotate brush
Rotation brush used to be crazy because it depends on normal of area
under brush, which is used as axis to rotate vertexes around and
this normal used to change during stroke.

Calculate normal from original mesh state for rotation tool too.
2011-02-01 15:51:40 +00:00
4037eda069 Fix for [#25879] Particle Duplication issue with Linked in Objects from Groups.
* Only the first object (in scene object order) that instanced a dupligroup was rendered properly, because particle instances were checked for only after creating the render object (and even this check was done wrong).
* Now the actual render object is created only after both object and particle instances have been checked.
2011-02-01 15:02:25 +00:00
67b1cdd953 Bugfix #25891
Info header: option to switch scenes or add new ones has to be hidden
for "full screen" mode. Current full-screen code doesn't allow to 
browse screens or switch scenes nicely.
2011-02-01 13:35:21 +00:00
0d3cf5c8a6 Script to test import operators, so a single command can execute an operator on all files in a directory and optionally save out blend files for inspection.
This comes in handy for testing importers against 100's of files, quickly showing breakages and easier to setup then unit tests.

Example usage:

  blender.bin --background --python source/tests/batch_import.py -- \
              --operator="bpy.ops.import_scene.obj" \
              --path="/data/testfiles/obj" \
              --match="*.obj" \
              --start=0 --end=50 \
              --save_path="/tmp/test"


Also found my name was spelt wrong in some places :)
2011-02-01 12:47:50 +00:00
ffe7bde02c correct fix for bug #23871, __main__ module was being overwritten in nested functions, so on returning from calling operators the __main__ module could be cleared and imported modules turn into None
calling
  bpy.ops.wm.read_factory_settings()
... would clear a scripts namespace if running directly, not in a module.


Fix by backing up and restoring the __main__ module.

Also found BKE_reportf wasnt printing all reports in background mode as BKE_report() was doing.
2011-02-01 12:37:53 +00:00
86f3ba24e4 Bugfix: Graph Editor menus were missing an entry for the "Smooth
Keyframes" operator

Probably this was missed off, since the DopeSheet doesn't have this
functionality
2011-02-01 11:54:05 +00:00
f4dcc2ffe1 Bugfix: Renaming Keying Sets didn't update timeline
Keying Set RNA props were missing update notifiers
2011-02-01 11:39:51 +00:00
1b371fd28d New Keyframe Type: "Jitter"
While doing some animation work over the past few days, I found that
it would be useful to be able to tag keyframes as a another type yet:
"jitter" for fill-in secondary motion (i.e. blinks/hand-keyed camera
shake). Of course, what you really use these for is up to you, but
this is one more option when you need it :)
2011-02-01 11:35:27 +00:00
549b190566 own fix for bug #23871 (r33277), crashes when running multiple operators in a batch script with a double free.
Cant see why this happens but this different fix doesn't crash so using it instead.
2011-02-01 09:02:49 +00:00
c6d43a02cb bugfix [#25767] Addons cannot be upgraded through the UI
added option to overwrite.
2011-02-01 06:48:19 +00:00
6f0aa2cb0e Targetless IK Bugfixes + Tweaks:
- "CONSTRAINT_IK_AUTO" flag for targetless IK constraints was being
set in the wrong place. This is for the IK constraint data's flag, not
the generic constraint's flag
- Converting stack var "targetless" from type bConstraint to
bKinematicConstraint (i.e. constraint baseclass -> specialised data),
since it was only used in one place with a cast used there.
- When using targetless IK with no specified chain length, bone
rotation locks are taken into account too, saving a bit of extra setup
work
2011-02-01 05:15:32 +00:00
0362d19f2d Pythons path functions - os.walk(). os.path.exists(). etc support bytes for paths as well as strings, support this with blender/rna too.
- bpy.data.*.load() functions were only accepting UTF-8 paths.
- rna functions/properties now accept byte values rather then strings for file paths.
- bpy.path.resolve_ncase now supports byte objects.
2011-02-01 04:24:47 +00:00
b17bbf9d95 fix for 2 segfaults running in background mode.
- operators which reload G.main would crash blender if called from python and then accessed bpy.data.*
- WM_read_homefile_exec was setting the contexts Scene to NULL as a signal for the event system, this didnt work in background mode, crashing when property update functions expected scene to be set.
2011-02-01 02:54:29 +00:00
339d3bf05f reverting the new button in node editor.. will need to create a new
operator to get the correct behavior for center backdrop
2011-02-01 01:32:12 +00:00
7b3a49af8c Added Center button to backdrop controls in node editor's side panel
Inlined backdrop's zoom ui limits and hard limits so that
going to minimun and going back to 100 works
2011-02-01 01:18:16 +00:00
dc8078e667 Bugfix [#25885] Auto IK ignores full rotation locks
... actually, this was just an off-by-one bug again.
2011-02-01 00:43:28 +00:00
6fcc13a786 disable assert [#25877] Driven shapekeys: incorrect assertions in depsgraph.c 2011-02-01 00:41:15 +00:00
11d61383fa workaround [#25845] Empty UI panels
- now writing to RNA is disabled when inside render() call.
- disallow calling operators when writes are disabled.

Rendering runs in a thread so running operators from the thread is not safe unless rendering becomes a blocking operator again.
2011-02-01 00:32:50 +00:00
e8f7f42c1d bugfix [#25846] Strange behaviour if index of render.layers[] is out of range 2011-01-31 23:54:51 +00:00
329e2d8037 Todo issue: sculpting on deformed mesh
Used a crazyspace approach (like in edit mode), but only modifiers with
deformMatricies are allowed atm (currently shapekeys and armature modifiers only).
All the rest modifiers had an warning message that they aren't applied because
of sculpt mode. Deformation of multires is also unsupported.

With all this restictions users will always see the actual "layer" (or maybe
mesh state would be more correct word) they are sculpting on.

Internal changes:
- All modifiers could have deformMatricies callback (the same as deformMatriciesEM but
  for non-edit mode usage)
- Added function to build crazyspace for sculpting (sculpt_get_deform_matrices), but it
  could be generalized for usage in other painting modes (particle edit mode, i.e)

Todo:
- Implement crazyspace correction to support all kinds of deformation modifiers
- Maybe deformation of multires isn't so difficult?
- And maybe we could avoid extra bad-level-stub for ED_sculpt_modifiers_changed
  without code duplicating?
2011-01-31 20:02:51 +00:00
55865239a2 Bugfix #25874
Area split error: if the first split position was exactly aligned
with another 'edge' it merged the edges, causing the subdivision
layout to go haywire. Only happens in rare occasions, good find
this report :)
2011-01-31 17:28:03 +00:00
Lukas Toenne
31b78fd72e Removed OpenGL blending from node editor backdrop images in alpha channel mode. This is a pure b/w image that doesn't need blending. 2011-01-31 16:34:56 +00:00
996d35afd4 Indentation fix. 2011-01-31 16:17:34 +00:00
05034fb91f Node UI:
* Added Backdrop Panel inside the "Properties" area.
* Hard limit for the "zoom" value. Negative values doesn't make sense. 
* Added a missing notifier for the Node backdrop move operator.
2011-01-31 16:16:15 +00:00
Lukas Toenne
fefe3daf24 Small fix for color info in node editor: ACTIONMOUSE click was already used for node moving. Now ALT+ACTIONMOUSE must be used to get color info from the backdrop image. 2011-01-31 15:18:30 +00:00
1393523d41 Scons blenfont include for recent Node Backdrop commit. 2011-01-31 14:48:17 +00:00
Lukas Toenne
56962346be Added backdrop image color information to the node editor. When clicking on empty space in the node editor, the pixel color values will be displayed on the bottom like in image editor. 2011-01-31 14:42:55 +00:00
Lukas Toenne
7215e5085e Changed alpha blending mode for image editor and node previews. This was using the sum of the image and alpha-faded background, leading to almost-white transparent areas. New code uses correct GL_SRC_ALPHA for the source image. 2011-01-31 11:57:37 +00:00
97002c2d90 Bugfix [#25876] bpy.ops.constraint.childof_set_inverse has no effect
This was a two-part bug: a user error + API error.
* User Error: before calling bpy.ops.constraint.childof_set_inverse()
for a constraint defined on a bone, you firstly need to explicitly
make that bone the active bone. To do that, you do
armature.bones.active = posebone.bone # or something similar

* API Error: active bone setting was a bit too strict. It only allows
setting the active bone if the new bone comes from the same armature,
but was overlooking the fact that RNA pointers may have been created
through the object using the armature instead.
2011-01-31 11:19:23 +00:00
Lukas Toenne
48fc6f5698 Added transparency feature to node editor backdrop, similar to image editor. Alpha blending can be enabled by a button when "Use Backdrop" is selected. 2011-01-31 11:17:50 +00:00
Dalai Felinto
e5cbc0307a Logic UI: Servo Control (Motion/ObjectActuator) default options + camera actuator tweak
In 2.49 we had this implemented in the logic_windows.c. I think I skipped this when porting the new UI. I probably didn't know how to do it back then or was waiting for something. Anyhoo, it's all good now.

For the records, the Logic Bricks that I haven't gone over to make sure everything is 100% are:
Filter 2D, Constraints and Animation (action, shapekey, fcurve)

I'm going over them this week, so the Logic Bricks are close to receive a "revisited review check-up" ISO 9000 :)
2011-01-31 07:52:45 +00:00
d5c7231339 [#25693] Netrender "shadow" images with last frame always appear
Better handling of FSAA when downloading results and on slaves.
2011-01-30 22:15:50 +00:00
14d8921fff Total displacement levels should be set in multires_topology_changed 2011-01-30 17:55:48 +00:00
cc8fc51636 Bugfix #25859
Outliner: click on 'restrict' options also selected/deselected the
item itself. Fix provided by Alexander Kuznetsov. Thanks!
2011-01-30 17:03:01 +00:00
1b28e8c162 moved texture_space scaling factor from glsl to C. 2011-01-30 16:57:28 +00:00
d5da54e1e6 bugfix #25867
fix for objectspace bumpmapping
2011-01-30 16:24:23 +00:00
658f86b016 Bugfix #25870
Operator "Select linked flat faces" didn't initialize the default
angle. That made it fail being called via menus.
2011-01-30 16:19:08 +00:00
17f8bceaf1 Removed bad copied UI strings and comment from texture slot rna code. 2011-01-30 16:17:08 +00:00
89c617a116 remove nan-makefiles 2011-01-30 15:29:22 +00:00
9400f4309a Fix for object-space bumpmapping in GLSL. Fix provided
by Morten Mikkelsen in IRC.
2011-01-30 14:43:24 +00:00
a550cca5d8 Bugfix #25855
New bump code: option "Texture space" only works for image textures.
It appears this option is some kind of "fake normal map" actually.
Needs nicer name... maybe "Image space".

Now it ignores the option when no image texture is used.
2011-01-30 14:19:12 +00:00
02458c0d4b Bugfix #25840
UI bug: when a button has an open menu, the menu closed on any 
mouse-over of other buttons in this panel. That's not too bad,
but it didn't check for whether the mouse was already inside the
menu itself (respecting safety region).

The bug showed error on zoomed in UI, using FPS presets, in case
the menu-button was drawing aligned with other buttons. A real
boundary case... :)
2011-01-30 13:51:02 +00:00
c7834e0e6e And here's a decent fix for correctly recognizing the the
.blend1 etc backups. 
Proves again that lazy coders only make bad code :) 

Implementation note:
The filewindow now recoginizes .blend version backups as
a special type, so filtering for .blend files themselves
ignores it. However, they're recognized correctly as valid
.blend files, and draw an icon as .blend file when filtering 
is off. Can become a distinct icon if we want...
2011-01-30 13:12:03 +00:00
9d0b8486c8 Stupid error in commit to allow .blend1 and .blend2 being dropped in
window caused .blend itself to be not seen :) Mea Maxima Culpa!
2011-01-30 12:26:16 +00:00
811897c5ba Better property names for backdrop RNA 2011-01-30 07:04:12 +00:00
706d79f52d RNA for node editor backdrop zoom and offset. Thanks Moguri for help 2011-01-30 06:58:36 +00:00
4d308dd921 Added handy option to delete all vgroups in the dropdown menu 2011-01-29 23:51:42 +00:00
abf483b947 Bugfix #25750
CTRL+L link modifiers (actually, it copies!) didn't call an update
for new dependencies.
2011-01-29 18:37:40 +00:00
83cb3b1fe7 Todo item:
When dropping image on an object, it now sets view to show texture in
solid view mode. Nicer interaction, and good for dummies & demos. :)
2011-01-29 17:56:34 +00:00
ff58fc3e86 Todo list fix: .blend backup files are recognized as such now;
for drop inside Blender window and icons. (.blend1, .blend2, etc).
2011-01-29 17:47:22 +00:00
aef4356909 Bug report #25722
Allowing IOR smaller than 1.0.
This is for people who want to trace air bubbles under water :)
2011-01-29 16:27:48 +00:00
bcacaa3901 Fixes for GLSL bump code; it was using calls not supported for
older GLSL versions (< 1.3)

Thanks Matthew M:
- adding mat3 from ma4 function
- removal of transpose()

And I've hacked in myself a textureSize() replacement, the image
size gets passed on to function now.
2011-01-29 16:13:15 +00:00
28e91fcd28 ISO C90 fix 2011-01-29 12:09:11 +00:00
50d434f2f4 matching 3Dview GLSL shaders for the new bumpmapping methods 2011-01-29 12:01:11 +00:00
c709524dc9 new bumpmapping options for the renderer
oldbump -> original
newbump -> compatible
 *new*	-> default (3tap)
 *new*	-> best quality (5tap)

the latter two have an option to apply bumpmapping in 
 viewspace - much like displacement mapping
 objectspace - default (scales with the object)
 texturespace - much like normal mapping (scales)
2011-01-29 11:56:11 +00:00
e7e5fa0630 "Whole Character" KeyingSet Bugfix: RNA paths for custom properties
were getting formed wrongly

Although the RNA paths for the custom properties could get evaluated
correctly, keyframe status highlights in buttons didn't always work
correctly, and would lead to a duplicate F-Curve for the same setting
getting created.
2011-01-29 09:47:48 +00:00
1439ebb6b1 Character Animation Goodie: "Whole Character" Builtin Keying Set
This commit introduces a new Keying Set: "Whole Character", which is
specially designed for character animators blocking out their
animation. It should make animating with rigs such as the Sintel rigs
(and other "mainstream" setups, though others may also work with a few
modifications) much easier.

It automatically determines which properties on every bone in the
active rig should be keyframed, avoiding an initial set up step where
properties may be missed, or non-animatable properties are also
needlessly keyframed. To do this, it relies on several rules:
1) All bones in the armature, regardless of visibility status are
considered, so that hiding some layers on some keyframes then
keyframing them later won't create problems with earlier poses
changing
2) Bones starting with certain prefixes, i.e. DEF, MCH, VIS, etc. (the
full list is available in the code for this, and can be/is meant to be
modified by riggers in their own versions as they see fit), so that
some bones on hidden layers which shouldn't be seen by animators are
not keyframed
3) Locked transforms AREN'T keyframed
4) All custom properties ARE keyframed - currently this is the best we
can do, as it's hard to tell if they're needed or not, or even if
they're already driven.
2011-01-29 03:01:51 +00:00
f11424d644 Fix for [#25825] Boolean doesn't work in command-line rendering (2.56)
* DAG_on_load_update wasn't called at all for background rendering, so any non-animated object data wasn't updated properly.
2011-01-28 15:24:02 +00:00
3a5e08ad58 Small feature request: using texture buttons (mapping) now updates
GLSL view of texture as well.
2011-01-28 14:51:03 +00:00
73f48ef3f8 Fix for [#25843] Multiple Scene Strip in Sequencer, bad scrubbing for armatures in viewport
* Sequencer didn't restore the scene properly after drawing a frame other than the current frame.
2011-01-28 13:14:01 +00:00
Nathan Letwory
7769c00385 First step towards having a 2-pass reading of COLLADA .dae files. 2011-01-28 12:56:30 +00:00
Nathan Letwory
037920caff Make version check more future proof. 2011-01-28 08:51:15 +00:00
53b83262c5 Fix for [#25713] VSE shows and renders wrong straight alpha gradient even after convert to premul is checked
* Caching of the start and end stills were just referencing the original imbuf (which got premultiplied after the caching), so as a result most of the time the premul was applied twice.
* Now the start and end stills are stored in the cache as duplicates of the original (non modified) imbuf.
2011-01-28 00:59:42 +00:00
b445467f15 In the Timeline, keyframe lines are now drawn in front of the frame
indicator. This is so that it will be possible to see if there is a
keyframe on the current frame by just looking in the timeline.
2011-01-28 00:52:31 +00:00
0b6c130937 [#25783] Network rendering fails with windows paths
Potential fix. Absolute windows path weren't detected as absolute on linux.
2011-01-28 00:45:53 +00:00
185f774385 [#25671] Network Render freezes/blocks blender
Decreasing timeout and increasing refresh period
2011-01-28 00:00:10 +00:00
a68a44817a More logical ordering of Empty draw types. Made Plain Axes default for
new empties
2011-01-27 21:05:01 +00:00
Nathan Letwory
7c31042c6e And on your left you can see something much nicer (while I fix this here on your right). 2011-01-27 19:49:43 +00:00
Nathan Letwory
71cb745941 Commit to cope with API changes in OpenCOLLADA (latest for Windows right now r827). 2011-01-27 19:39:06 +00:00
ba9dacbd3d Silly mistake in own previous commit, now we have particles again! 2011-01-27 17:29:22 +00:00
ce7f7d6e5f r34526 removed a line which had an unused return value but still needed to run. 2011-01-27 12:36:48 +00:00
8fa9a91639 Fixing some clang reported issues in particle code.
* Not really bugs, but some code cleanup and clarification.
2011-01-27 12:21:14 +00:00
40b4471de7 fix for gcc 4.6 commit: this is needed for osx too. 2011-01-27 11:17:23 +00:00
f10e44884e gcc 4.6 compatibility commit r34520 broke OSX, this should work now. 2011-01-27 09:40:20 +00:00
45fc590835 internal changes, script writers won't notice.
disable getattr metaclass forwarding attributes from the python class, eg:
  bpy.types.Scene.foo != bpy.types.Scene.bl_rna.properties['foo']

... This was convenient but too tricky to properly maintain with attribute assignment and attributes defined within the class.
avoid doubles in dir() by converting to a set and then back to a list.
2011-01-27 06:48:14 +00:00
18aece4424 Bugfix [#25823] When objects are parented to the same objects that
they have some rotation-affecting constraint (i.e. Track To and Copy
Rotation) targetting, transforming the objects (directly, using GKEY
-> grab) becomes unreliable.

This was caused by a typo in some code checking for some
OB_NO_CONSTRAINTS under "flag" instead of "transflag"
2011-01-27 01:29:40 +00:00
6a2e5ad599 [#25815] Patch gcc 4.6
with minor edits, made sure it works in CMake too.
2011-01-27 00:02:25 +00:00
340e411889 Silencing some annoying key-event prints in Win32 console:
The console was getting flooded with output like
g


i

i
...
all as a result of what looks like a debugging print. Whoever put this
in, you can get back your debugging prints by enabling BF_GHOST_DEBUG
in your local config :)
2011-01-26 23:58:20 +00:00
50e09b15a9 Bugfix [#25707] / Todo Item: "Local Space" for Object constraining
For Constraints, there's now a working "Local" Space for Objects
without parents. This is defined as relative to the object's rotated
set of axes which results from rotation that gets set via "rotation"
transform properties.

I'm not sure whether this different behaviour between parented and
unparented objects will be too confusing (and thus require separate
settings + a round of version patching), so I'll wait until we get
proper testing from experienced riggers first.
2011-01-26 23:33:08 +00:00
eb0ddb7684 Usability issue noted while self-testing some stuff...
Giving modifiers more descriptive tooltips for "Vertex Group" fields
than just the useless/meaningless "Vertex Group name" tooltip they
used to have.
2011-01-26 22:38:05 +00:00
5270280a65 Bullet-proofing mesh vertex group RNA wrapping, after double checking
on whether vertexgroup weight animation worked
2011-01-26 22:31:14 +00:00
Dalai Felinto
e46895811e bge fix: debug text didn't have GL_DEPTH disabled - text got clipped when we have objects too close to the camera
fix only in embed bge, blenderplayer seems to be doing differently.
-- reported live by Mike Pan
2011-01-26 22:16:58 +00:00
0fb785aaa7 Removing some old stuff from old animation system that isn't needed
anymore (shapekeys stuff)
2011-01-26 22:01:51 +00:00
91b1efc2c5 "Bugfix" (otherwise known as another ZanQdo Feature Request)
Shape Key point data can now be animated directly. That is, you can
animate the locations that each shape key defines.
2011-01-26 21:58:32 +00:00
4613d638a9 Fix #25818: Text Editor holizontal grab inverted
Stupid typo. Maybe it's a result of merging two patches related to this part of code.
2011-01-26 21:00:52 +00:00
c627e1cbaa Bug [#25696] Netrender feedback fails
Patch by Wintch Analyzer

Someone change an attribute name and this wasn't updated
2011-01-26 20:09:30 +00:00
8cf0d64623 option for blender --addons rigify,io_scene_fbx,add_mesh_gears
needed so ctest unit testing can be done on addons that are not enabled by default.
2011-01-26 16:30:12 +00:00
1efb22c2e6 fix from andguent on irc, wasn't checking for property type. 2011-01-26 16:21:54 +00:00
2df908df39 fix for error in add mesh script with no operator passed. 2011-01-26 14:52:00 +00:00
2761799c64 Possible fix for issue #2 in [#25664] Remove Pack does not work in Texture panel
- There were 2 pack menu's, merged into 1.
- Don't attempt to unpack into // if the blend file isn't saved, would use the CWD instead.
2011-01-26 14:18:16 +00:00
307c10486d Fix for [#25797] Hair partcle crash when vertexgroup length enabled
* Rounding errors could give vgroup weights of slightly over 1.0 to particles in some cases.
2011-01-26 13:02:47 +00:00
c7ea17bb92 After test, offset is better to be 0.001f (test in windows nvidia) 2011-01-26 12:48:22 +00:00
dc30caab61 fix for crash when assigning unsupported type to collection properties. 2011-01-26 12:44:09 +00:00
efa9d4f7e0 Bugfix #25756
Outliner was drawing icons sometimes blurred. Happens when subpixel
positions vary. UI code doesn't suffer this, it makes own ortho for
it.

This fix re-uses an un-used v2d flag (V2D_PIXELOFS_X) to force a 2d
view on pixel exact positions. It's set for outliner only, I need
testing feedback first.
2011-01-26 12:26:44 +00:00
Nathan Letwory
a70e697381 Apply part of patch [#25612] Windows 7 icon progress bar
Submitted by Alexander Kuznetsov.

This adds the progress bar to the taskbar item of Blender for Windows 7.
Small change in version retrieval, otherwise as is.
2011-01-26 12:23:02 +00:00
Nathan Letwory
75f155be33 Apply multimonitor fix part of patch [#25612]
Submitted by Alexander Kuznetsov
Fixes [#23630] Negative OS screen coords not stored/used
Reported by Mort (mnme)
2011-01-26 12:19:19 +00:00
2f45cdb420 ShapeKeys RNA Wrapping: Code cleanup
Replaced some manual/inlined operations with their equivalents from
the listbase library funcs.
2011-01-26 10:46:43 +00:00
ed5791bd0b - Clear rotation for objects now works on delta transforms too. The
only case that doesn't fully work yet is the one where quats/axis-
angle are converted to eulers first.
- Fixed incorrect comment
- Removed obsolete "armature_clear" var from clear origin operator.
This was some ancient stuff from 2.4x code that ended up getting
ported across...
2011-01-26 10:25:15 +00:00
fa84840c84 Refactoring object clear-transform operators to remove out the common
parts, like what was done for posechannel clear-transform operators
earlier. There shouldn't be any functional changes.
2011-01-26 09:27:43 +00:00
1f5cec709c update to background_job template to use --factory-startup option.
make all templates pep8 compliant.
2011-01-26 07:54:27 +00:00
7a23193811 cmake attempted fix before didnt work (I cant test on OSX), this should fix. 2011-01-26 07:34:17 +00:00
78fb0a42b7 Adding Calculate/Clear Motion Path operator buttons to toolbar. I'm
currently reviewing the UI for this, so more changes related to this
should be coming...
2011-01-26 06:41:44 +00:00
c47eb461ac After talking to Troy Sobotka, separated the time mapping UI a bit and added a label. It should be less obscure now 2011-01-26 06:08:26 +00:00
fb08dc11e3 missed this when updating cmake files 2011-01-26 04:48:37 +00:00
58352e12f5 Adding Framerate preset patch by Troy Sobotka (sobotka). Small change to
make Frame Old / Frame New remapping settings always visible as they
aren't really a part of framerate settings
2011-01-25 18:30:31 +00:00
0f375d8980 Fix for [#25781] Bake cache for particles fails at end , ALT + A not
* Missing check for info frame (frame 0).
2011-01-25 17:08:43 +00:00
d8539d8801 small internal cleanup, have matrix.scale_part() use same method to extract the scale as matrix.decompose() 2011-01-25 16:32:41 +00:00
1bd0db59f4 use cmake defined names for jpeg, png, zlib and python libs, building on *nix with non-standard libjpeg/png/zlib locations was broken.
in the case of python this makes it easier to move to find_package(PythonLibs) when 3.x is supported.
2011-01-25 14:43:13 +00:00
da2b490198 cmake maintenance, was missing 2 headers and made some minor improvements to cmake_consistency_check.py.
also converted GHOST_SystemWin32.cpp to utf8.
2011-01-25 08:35:10 +00:00
57289044ca improve unregister error check not to loop over parent classes properties (would check the same property multiple times) 2011-01-25 07:31:11 +00:00
c0e74f9dce fix [#25748] Addons register parameters/functions more than once
- values were added to both the classes __dict__ as well as the internal StructRNA.
- made properties available from the type since this is where the python api assigns them:
>>> bpy.types.Scene.frame_start
<bpy_struct, IntProperty("frame_start")>
- rename RNA_struct_type_properties() -> RNA_struct_type_properties(), added RNA_struct_type_find_property()
2011-01-25 06:54:57 +00:00
17509e7334 property lookups on structs was doing a listbase search even if the hash was defined.
since the property hash is maintained there is no reason for this, especially since the property could be in the StructRNA's parent class.
2011-01-25 05:45:21 +00:00
27cb6218a3 fix [#25778] Memoryblock Data from SCR: end corrupt
+ other minor changes.
2011-01-25 01:51:28 +00:00
8e83dd0933 Todo item: text editor does not honour continuous grab(see
Added OPTYPE_GRAB_POINTER flag to scrolling operator, changed a bit logic of
delta calculation and removed unused members from TextScroll structure.

Got issue with very-fast mouse moving (when mouse pointer could go out of window,
but it's general issue for all grab operator).

Was unable to check MOUSEPAN event (two-finger scroll). Please poke me if
there are any issues with this event.
2011-01-24 18:21:55 +00:00
076171c5fa fix [#25757] Torus script uses radians for rotation in panel 2011-01-24 15:25:03 +00:00
Nathan Letwory
f949c567b9 Fix [#25715] [!] key doesn't work on french keyboard with Windows XP/7.\nSubmitted by Eric Le Pape\n\nThe key sent VK_OEM_8, which wasn't handled at all. Added code to detect primary language and handle VK_OEM_8 specifically for certain layouts. 2011-01-24 14:37:10 +00:00
2adb55f2cd Todo item: text editor scroll bar does not respond to clicks
Text space's scroll bar now uses quite the same strategy of handling
drag and click events as view2d.

I tried to share some code between this two spaces. but there was no big
luck with it: text sace uses it's own constants (like scroll bas size and offsets),
so the simpliest way was to define zone stuff for text space without sharing it
with view2d.
2011-01-24 10:10:50 +00:00
c0f161f811 fix [#25776] Crash when operator's bl_idname has more than one dot 2011-01-24 05:15:14 +00:00
daa09a4a60 Raise an exception when registering classes with ID names which are too long. (related to bug ), found while looking into bug [#25776]. 2011-01-24 03:38:34 +00:00
0097997911 no functional changes.
- remove unneeded casts to (char*) in interface code.
- replace strcmp(.., "") with checks on the first char of the string.
2011-01-24 02:56:23 +00:00
490616d5bd Small fix for text input buttons:
Number buttons, in text input mode, now also align internally 
like text buttons.
2011-01-23 19:20:10 +00:00
Dalai Felinto
d58c31704b BGE: option in the UI to start with the mouse cursor visible. Patch by Vitor Balbio, changes by me.
----------------------------------
While we are more and more moving towards enabling features in the Python API, it's also important to have Logic Bricks working with no scripts.

This option allows you to start the game with the mouse cursor on (it's on Render Buttons). The defalt is still off (no do_version needed here).
2011-01-23 17:25:27 +00:00
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
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
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
7aebf814d2 update testing md5's for changes in exporters. 2011-01-23 13:34:36 +00:00
d2076e38f1 correct own bad spelling 2011-01-23 12:42:07 +00:00
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
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
f39c794c7c Own mistake in fluid particles ui cleanup commit.
* Emission tab was shown without particle settings.
2011-01-22 21:22:29 +00:00
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
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
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
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
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
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
3d635c0733 own fix r34446, was incorrect, fixed properly now. 2011-01-22 04:40:15 +00:00
98124e7f94 error in own recent commit, r34445 2011-01-22 04:13:13 +00:00
99ae4467d2 fix for makesdna error.
ERROR: still 1 structs unknown
*** Unknown structs : 
  PreviewImage
2011-01-22 04:02:54 +00:00
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
f6d54bd1ee correction to own cmake error checking script. 2011-01-21 11:52:56 +00:00
a5d4922639 PLY and STL importer tests. 2011-01-21 10:49:39 +00:00
6132f8c4b4 applied Linux SpaceNav patch from Rafael Ortis 2011-01-21 10:11:26 +00:00
162795cffe applied SpaceNav patch from Tom Acunzo 2011-01-21 09:59:58 +00:00
50186191d9 enabled multithread GL engine + minor cleanup 2011-01-21 09:56:41 +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
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
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
d7c6ddd7e9 correct spelling 2011-01-21 02:32:58 +00:00
022511d5ad [#25732] Incorrect shear matrix in XY plane
fix included by Lawrence D'Oliveiro (ldo)
2011-01-21 02:27:04 +00:00
a994f872c2 SVN maintenance. 2011-01-21 00:33:37 +00:00
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
df6bb34c2b correct fix for [#25737] Console error message 2011-01-20 23:05:25 +00:00
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
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
039bb7812f bugfix [#25742] blender-thumbnailer.py doesn't work with python 3.1 2011-01-20 21:02:42 +00:00
dc2431c491 Small code reshuffle... sequencer transform stuff was bisecting the
code for object transform stuff
2011-01-20 20:51:38 +00:00
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
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
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
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
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
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
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
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
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
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
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
e2f9006bd3 set variable as unused. 2011-01-19 19:58:44 +00:00
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
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
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
Lukas Toenne
450288999c Changed Brightness/Contrast node to use also buffer inputs for the B/C inputs. These were only working with single values. 2011-01-19 13:32:59 +00:00
cf39190268 Added missing updates for NLA RNA settings 2011-01-19 10:54:34 +00:00
fbe8f21826 NLA Editor: Added "Sync Action Length" operator to Edit menu
Although strictly-speaking, this only applies to a certain type of NLA
Strip (there are 3 types), but since only the classic "Action Clip"
gets much attention, it's probably worth exposing this here too to
make batch editing of strips a bit easier.
2011-01-19 10:45:35 +00:00
d177212f80 Fix for [#25705] Crashing doing Bake in Partile System in Particle Mode
* Missing null check.
2011-01-19 09:33:09 +00:00
161cbed9b5 new command line option '--factory-startup' to skip reading startup.blend. useful for testing with a predictable environment.
also commented python benchmark prints on exit, can enable when profiling later.
2011-01-19 09:13:24 +00:00
dddb9aa30f NLA Editor: Swap Strips (Alt-F) and Bugfixes
1) Added a new operator to swap the order of strips within a track
(Alt-F).
This makes it possible to select two strips (or more precisely, two
islands of consecutive + selected strips) in a single track and change
the order in which the appear without needing a extra tracks to
perform the move through.

As usual, the non-overlapping rules apply, so there may be some cases
where swapping in this way is not possible without adjusting the
intermediate strips first manually. Otherwise, everything just gets
too tricky to manage deciding what adjustments should be done to the
obstructing strips to make a fit.

2) Freeing meta-strips didn't free their local data properly (i.e.
modifiers they may have had).

3) Adding strips to tracks, where the endframes for the strips
overlapped would cause problems with incorrect ordering of strips. I
still need to double-check whether evaluation works ok in this case...
2011-01-18 23:38:36 +00:00
11f8b5fceb move release/test to source/test, there is nothing release about this dir. 2011-01-18 23:12:02 +00:00
Dalai Felinto
eff0e29cba BGE BugFix [#25711]render.setBackgroundColor() does not work:
Since rev.2 (hans ftw) we have a strange situation where horizon color was being used at Convert time for the WorldInfo background color (and for the fog). However through the Python API only the Rasterizer background color was being updated. On top of that the KX_KetsjiEngine.cpp::SetBackGround was using the WorldInfo bgcolor when render mode was the potato one (TEXTURED). Bottomline, when in potato mode the glClearColor used was the original one in worldinfo, not the API updated one in Rasterized.
2011-01-18 22:27:18 +00:00
3b0c2accc6 support building with python3.2 2011-01-18 21:39:50 +00:00
7d675b15fb Fix [#25678]: (Ghost Cocoa) Fix character encoding translation for filenames (open & window title display) 2011-01-18 20:53:20 +00:00
083be90232 Fix for "[#25700] 2.56: Rotation Mode: Quaternion shows wrong orientation of the object".
There was a small typing error that made object and armatures rotate twice the magnitude when in quaternion rotation mode.
2011-01-18 15:02:58 +00:00
Lukas Toenne
121f428097 Added group verification after autoconnect to avoid linked+external group sockets. 2011-01-18 14:49:06 +00:00
2167dc7f39 Bugfix, irc report: general view3d operator poll() was reading NULL
caused by commit for fix [#25691] 16 hours ago.
2011-01-18 14:34:59 +00:00
Lukas Toenne
bee3d78393 Added a check in nodeGroupVerify to detect if a tree is actually a group tree. This is necessary to avoid the group-in-group error if the function is called for a tree that already contains group nodes. 2011-01-18 13:28:18 +00:00
08dc18fda0 rename fcurve.keyframe_points.add() --> insert()
add new add function which allocates a number of points instead.
2011-01-18 11:27:52 +00:00
fb97780fdf Bug fix: particle dynamics were being calculated if point cache was only half baked (reported by Michael Fox in #blendercoders)
* When a simulation is baked no dynamics calculations should happen anymore (even outside of baked frame range) since these can be very time consuming and baked simulations are supposed to be fast!
2011-01-18 09:25:37 +00:00
e6027018fe recent commit broke Mesh.from_pydata() 2011-01-18 06:35:26 +00:00
a1de0fbf17 Small fix for my last fix: ignore the `preview' flag; if either size
has been marked for update then do it regardless. Otherwise changing
the texture type doesn't always update the brush texture preview.
2011-01-18 04:32:41 +00:00
c2a638a81e More fixes for bug [#25649], Image editor paint icon missing until
enter weight paint, hopefully fully fixed this time

* The texture selector for brushes wasn't updating. Seems that preview
  images have two sizes, small (icon) and big, but it was only
  updating if the icon size was set to update. Now both are checked.

* Also changed the previewimage arrays to use the already-existing
  PREVIEW_MIPMAPS define, makes it a little clearer what the arrays
  are for.
2011-01-18 04:08:01 +00:00
2431e8e045 bgl.Buffer()
- invalid dimension type could be passed without raising an error.
 - negative dimensions could crash blender, now they raise errors.
 - zero length dimension arg was not detected.
 - floating point lengths were accepted, now only allow ints.

 also comment unused vars.
2011-01-18 03:49:28 +00:00
8cf1184c04 bad spelling; 'indicies' --> 'indices' 2011-01-18 01:58:19 +00:00
28382c7983 document Mesh.from_pydata() [#25688] undocumted functions in pyapi 2011-01-18 01:38:14 +00:00
e49df9e09f Bugfix [#25684b] Surface and Stroke options are not working with Use
Sketching Sessions.

Fix for secondary issue noted in this bug report. Some of the code for
the fancy 3d view sketching options needed to be moved around so that
there is a clearer "paint/sketch session" and "stroke" separation
between various stages. There's still some more stuff that needs to be
done here before I think it's totally cleaned up.
2011-01-18 01:04:14 +00:00
86baf7c937 option for the path iterator to loop over packed files so their dir separator can be switched on file load. 2011-01-18 00:10:11 +00:00
3989351632 fix [#25694] Center View (Home Key) 2011-01-17 23:47:11 +00:00
44fdde5695 fix missing notifier [#25682] bpy.data.materials['XXX'].texture_slot.clear(0) dosen't delete texture from screen 2011-01-17 23:30:28 +00:00
1a0d88a108 fix [#25691] Lasso select on 3D Text editing segfaults
poll function was incorrect.
2011-01-17 22:37:24 +00:00
f6d73fdfee == file browser ==
bring back nice shortening of filenames in thumbnail view, shortening at front and end is confusing.
- adds ... at the end to indicate that the filename has been shortened
- also cuts off at the end and not at both front and end now

Note: maybe this can be moved into button code or so in the future, but for now should work.
2011-01-17 20:10:18 +00:00
0b1e517052 fix compile on MinGW, missing define in the mingw headers. 2011-01-17 19:39:25 +00:00
d591ab5355 Bugfix 25683
Compositor operators now have better poll check, so they won't
show up in operator search or hotkeys for other node views.

- backimage move, size
- read renderlayers
2011-01-17 18:38:44 +00:00
0828710204 Bugfix #25657
Three code fixes for 1 report. User experienced crashes while
painting on float buffer + having preview renders on.

- Texture Nodes: Image was re-allocated without using
  proper thread lock
- Paint code: old convention to free the byte rect from
  a float image as signal to re-create now is a proper
  flag. This keeps image memory unchanged. Nice for render.
- Imbuf: call to make a byte rect from float was freeing
  mipmaps unnecessary.
2011-01-17 18:16:10 +00:00
4b7930dbbd Bugfix #25681
Python API allowed to make links with input->output reversed.
Now node api checks for this case and flips order.
2011-01-17 15:16:08 +00:00
Nathan Letwory
9924ade102 test commit for svn link in commit mail, part two 2011-01-17 10:47:31 +00:00
Nathan Letwory
637f4273aa test commit for svn link in commit mail 2011-01-17 10:43:51 +00:00
d769ff0d26 Bugfix [#25667] "X-Axis Mirror" in the Pose Options panel toolbar is
misleading (?)

"X-Axis Mirror" option didn't work in Pose Mode, so hiding this option
for now. Perhaps one day we could properly support this for all
operators there, but that is more of a long term todo...
2011-01-17 10:35:04 +00:00
9d2292ef7e misc maintenance changes
- metaball tessellation functuion was calculating density when it didn't need to.
- image drawing was using a float as a loop counter, in extreme cases this could cause an infinite loop.
- remove/comment unused vars.
2011-01-17 08:31:57 +00:00
c42e382994 More consistency with order of action vs gp keyframes... 2011-01-17 08:27:16 +00:00
80c81605a1 Bugfix [#25674] No Box Select in Dopesheet
Border select was broken during Grease Pencil mode work
2011-01-17 08:21:13 +00:00
fd448bcfc7 remove/comment unused defines, also zero FileGlobal.filename to quiet valgrind. 2011-01-16 21:12:38 +00:00
26ee86b20d These files are needed for booleans (which I had disabled)
reverse merge:
svn merge . -r34357:34356
2011-01-16 20:52:15 +00:00
627d47c322 remove MSVC 6.0 workaround. 2011-01-16 20:25:47 +00:00
e3c69e6cfe remove unused memutil classes 2011-01-16 19:55:50 +00:00
Lukas Toenne
4f0b7650e9 Adding links to groups using the links.new function in RNA wasn't updating the group owntype. This lead to sockets being linked and external at the same time. 2011-01-16 18:38:54 +00:00
c94eefd52b Fixed bug [#25649] Image editor paint icon missing until enter weight
paint

A couple underlying issues:

* Paint icon was looking only at the object mode to determine what the
  "current" mode is, but that gave problems when the object mode was
  anything other than texpaint, but 2D image paint was turned on. Fix
  was to also look at what space is being drawn, and only if it's in
  the 3D view does it look at the ob mode.

* The brushes lists weren't getting filtered correctly in the same
  case where 2D image paint was on but a different object mode is
  enabled. Fixed by changing the brush rna poll to look at the paint
  source, rather than the object mode.
2011-01-16 18:33:08 +00:00
6ef1f23a33 Bugfix, IRC report
Texture nodes: including output node in group crashed when it got
connected. Note that this feature is not supported to do anything
else than temporarily giving an output when editing node groups.
2011-01-16 17:12:02 +00:00
Lukas Toenne
dbb5e5dec2 Fix for 25655: Crashes with texture node in compositor.
Texture node was using the preview buffer instead of socket output buffers, which is already free'd at that point.
2011-01-16 16:00:06 +00:00
e025bf3967 defining types via python gave confusing errors because DefRNA.laststruct was being used for errors when the new property wasn't on the last struct.
added CONTAINER_RNA_ID() define to get the ID from the ContainerRNA type.
2011-01-16 15:02:07 +00:00
5b3bf80dd8 detect mathutils types with mathutils_array_parse(), was using PySequence_Fast(), converting into a tuple every time then back to a float array.
gives approx 6x speedup with eg mathutils.Vector(some_vector).
2011-01-16 11:26:01 +00:00
ba96f02d4a use fast sequence functions for python's bpy.props.EnumProperty() arg parsing. 2011-01-16 10:36:27 +00:00
4dd92a988a Defining bpy.props.EnumProperty(... , options={'ENUM_FLAG'}) wasnt working right with default values. 2011-01-16 10:08:20 +00:00
a72f02c025 fix for using un-initialized stack memory with bullet triangle mesh collisions.
the 4th component of the vector is used later when copying the vector.
2011-01-16 06:16:28 +00:00
743182106f py api: bpy.path.abspath(), option to return relative to a path other then the current blend file. 2011-01-15 20:35:31 +00:00
fd7b6519fd move to bf-extensions 2011-01-15 19:36:01 +00:00
cae4e92ce8 bugfix [#25640] Cannot edit custom property values in it's popup window 2011-01-15 19:15:35 +00:00
ebfb96c125 Bugfix:
Texture nodes, the Image node didn't get initialized on load.
This caused the node to refuse accepting a new Image if a
file couldn't be found on saving.
2011-01-15 18:00:46 +00:00
86bbab7de5 remove/comment unused defines. 2011-01-15 16:14:57 +00:00
f66912a335 misc edits, no functional changes
- enabling/disabling no longer prints in the terminal unless in debug mode.
- remove 'header' struct from BLI_storage_types.h, from revision 2 and is not used.
- Add GCC property to guardedalloc to warn if the return value from allocation functions isn't used.
2011-01-15 15:48:46 +00:00
c6abe11512 IRC bugreport fix: thumb brush works incorrect when using tablet by Dan McGrath (troubled)
Quite silly fix, not sure if it could be smarter with current events/brushes design.
Use pressure_value from first brush step for brushes which don't support strokes -- thumb.
brush, brushes with anchored stroke method.

Should be fixed in nicer way after events redesigning.

P.S. Tried to place pressure saving into invaliants update fuunction, but it seens
     that this function wouldn't know about pressure yet.
2011-01-15 14:48:44 +00:00
384025f1a0 Bugfix #25636
On using loop-selects, the active vertex got cleared, it could still
simply indicate one of the vertices of indicated edge to become active.
That keeps the Ui for vertex-groups drawing correct, for example.

Also made loop-ring select store active edge for tools, like the loop-select.
2011-01-15 14:07:11 +00:00
4cb79661eb Fix for [#25633] Particles display switching causes crash when Velocity disp. ON
* Particle draw data wasn't freed properly in some cases.
* Velocity + circle draw type also crashed due to missing null pointer check.
2011-01-15 12:29:22 +00:00
7297169a74 Fix for [#25637] curveguide forcefield(Kink: Braid) + particlesystem cause crash by Null Pointer in some cases
* Missing null pointer check.
2011-01-15 12:00:15 +00:00
69c582a3d4 error in last commit, also skip getting vars for wm_operator_reports() when there are no reports. 2011-01-14 21:45:49 +00:00
eac31a2ece remove unused vars & avoid some clang warnings. 2011-01-14 21:06:28 +00:00
94b9d2da54 checking wrong null pointer in edit_modifier_poll_generic(). 2011-01-14 19:35:59 +00:00
255a1e0ed7 apply fix from r34275 to BLI_dynstr_appendf(), dont chop off last character for >256 length strings. 2011-01-14 19:15:06 +00:00
d340fb94a8 new startup.blend with official io addons enabled,
also include STL since this is an important format which we can support officially.
2011-01-14 17:41:33 +00:00
c69ecd3f90 moving io scripts to 'addons' dir in extensions svn, leaving MDD format since I dont maintain this. 2011-01-14 17:28:10 +00:00
439140d6ae Todo item #19816: Wave modifier does not affect Curve Paths
Added new option for applyong modifiers on splines' points. This moves
tesselation point and path would be affected by modifiers which are applied on
splines' points.
2011-01-14 16:57:53 +00:00
9d8d25cc34 add icons to show community vs official scripts as well as buttons to filter by support level (currently all scripts default to community)
note: we need better icons for this.

 also formatting edit for ply import.
2011-01-14 16:49:43 +00:00
dc1e1baabf rename bl_addon_info --> bl_info, because this isnt necessarily used for addons. 2011-01-14 15:21:13 +00:00
62eb77c119 Transform tweak:
2D Editors using the standard translation transform tool no longer
have their values converted. For instance, it simply didn't make much
sense in such editors to be showing frame numbers/timing in terms of
meters/inches.
2011-01-14 06:46:28 +00:00
af4bc28c44 Bugfix [#25617] HOME Key in fcurve editor doesn't center properly
* When euler-rotation F-Curves had a single keyframe only, the view
would be artifically extended to fill up to 57 (this comes from the
radians to degrees calculations) due to a combination of the bounds-
finding function enforcing a minimum separation of 1 unit between
min/max. This has now been moved to the operator-level where it gets
applied AFTER these conversions have taken effect

* F-Curves with samples only (i.e. baked F-Curves) would be ignored by
these operators. Was caused by using a poll calback that only
considered whether there were keyframes. Hopefully this is sufficient;
otherwise a hybrid poll method will be needed.
2011-01-14 05:19:04 +00:00
423fbcfa5c Driver creation hack:
Drivers created from the Properties Editor for Materials and Textures
will now be created on Object-level instead of on their owner
Material/Texture as for their keyframes.

The intention of this hack is to allow users to be able to easily set
up drivers for materials and textures. Without this hack, users would
have had to do this manually via the Datablocks editor (I've described
this method a few times in detail, though this still attracts
complaints), as the way the depsgraph works does not allow ID blocks
other than Objects and directly-linked Object data to be driven. As a
result, although this hack can be done for these two cases, there are
no workarounds possible for Scene and Scene-linked settings.

There are 2 issues that will be noticed with this approach:
1) There may be confusion over why the drivers are found under Object
level and not Material/Texture level.
2) Driver status will not be shown in the buttons, leading to attempts
to try to keyframe the properties directly later and subsequent
confusion when finding that that won't work.

However, these are the sacrifices we'll need to make to get easy-setup
working in the meantime until the proper fixes can be done.
2011-01-14 02:06:35 +00:00
3bf46c57c9 add ply import into the file menu. 2011-01-14 00:23:21 +00:00
ac5b048e99 initial 2.5x api port. basically working. 2011-01-14 00:06:43 +00:00
619c287851 Reverting r33930 and r34202, which were related to bugs #21825 and
#25554. As found by Daniel Lara (Pepeland) in #25554, the original
problems in #21825 all stemmed from the ChildOf constraint there
having an incorrect inverse set, which was altering the final results.

Now Auto-IK works nicely for old rigs again (i.e. FK arms on BBB rigs)
2011-01-13 23:53:14 +00:00
7c7b31cf84 python3 updates: 2011-01-13 23:38:25 +00:00
de5d321e71 pep8 cleanup. 2011-01-13 23:31:04 +00:00
a1850ed876 ply importer from 2.4x, no changes made.
svn cp https://svn.blender.org/svnroot/bf-blender/branches/blender2.4/release/scripts/ply_import.py release/scripts/op/io_mesh_ply/import_ply.py
2011-01-13 23:28:36 +00:00
932f3dab2a Bugfix [#25623] Intensity for Voxel data partially linked with
brightness

Committing fix on behalf of Matt. VoxelData/PointDensity RNA-structs
had malformed paths
2011-01-13 23:16:10 +00:00
9146ca06dd pep8 corrections. 2011-01-13 23:00:51 +00:00
6c3d7c7f12 Bugfix [#25620] Grease Pencil: crash when using Ctrl+Z while drawing
Crazy users! Who on earth would try undoing in the middle of an action
(here the crash occurred while a mouse button was still held)?!

(At least it wouldn't have been possible for those using the DKEY +
mousedrag method of invoking strokes though...)
2011-01-13 22:59:48 +00:00
29338aa2b3 fix for x3d importer
- files blender exports (blender uses unusual array formatting).
- scene needed to be rotated on import.
- lamp spot size was half as big as it needed to be.

x3d export typo broke image export.
2011-01-13 22:44:47 +00:00
c8df192de6 misc python api improvements
- rna array parsing was using PySequence_Size() in a loop, this can  be slow to run so only call once.
- assigning a single value to a multi-dimensional array was missing type check.
- improve exception messages for rna array type errors.
- simplify vector slice assignment by using mathutils_array_parse(...)
2011-01-13 21:44:18 +00:00
5bdb576d3d Fix #25609: Text Editor: Ctrl+Z error with Word Wrap
Not updated line number was passing to undo stack.
2011-01-13 20:16:36 +00:00
4cc4a73a9e feature request from colin levy, camera lens stamp. 2011-01-13 19:16:35 +00:00
1939ad3f94 Bugfix #25614
Reporter saw weird fgons and edge creases on spin-mesh.

Appeared that the edge-flag copying code happened after
freeing edges. Already since May 2007 or so... weird!

Also in this commit a couple of simple cleanups.
2011-01-13 19:01:27 +00:00
665648a40b bugfix [#25578] assigning to multi-dimensional arrays fails 2011-01-13 16:00:14 +00:00
e2054b291c bugfix [#25588] Not work fcurve.keyframe_points.add
The problem was flag-enums were being treated as regular enums, a default value of 0 was using the first enum item, whereas with flag enums we want to be able to use 0 as a default value to specify all flags are off.
2011-01-13 14:29:57 +00:00
d4fa68e448 speedup fluid file reading, seek past arrays rather then reading them & use fewer function calls to gzread().
also added missing MEM_freeN(), though it would only leak in exceptional cases.
2011-01-13 11:06:12 +00:00
d2e6ea65c3 revert r34284, this fix was incorrect. 2011-01-13 10:14:03 +00:00
9024b6789e Possible fix for [#24924] crash-Fluids
* In some rare cases gzread has problems with the fluid files. This could be minor file corruption or some strange thread issue, but checking the amount of read bytes always after read seems to give a graceful way out.
2011-01-13 10:10:13 +00:00
f373dd6a50 small feature for file manager, pasting a full file path into the directory field will split the dir/file.
nice when you have a list of file paths in a terminal/editor and want to open one.
2011-01-13 07:25:18 +00:00
4b922c0bf3 Bugfix [#25597] Grease Pencil crash when undoing during a Sketching
Session

As the key combination for undo was unhandled by Grease Pencil
operator and allowed to execute, some of the lingering Grease Pencil
data would get corrupted by undo as some flags may still have been
set.

This commit attempts to fix.workaround this problem by catching undo
events, using the internal "delete last stroke" functionality to
emulate undo-like behaviour as expected but without the associated
risks. The underlying functionality used was already part of the
original 2.4 implementation, but was exposed via the GUI instead there
where it was less useful.

---

Other tweaks related to Grease Pencil:
1) Spacebar can be used to end Sketching Sessions too now
2) Grease Pencil animation editor now displays GP datablocks in light
blue (i.e. "sub-id") colours as per dopesheet instead of them being
presented like groups. This better reflects their true nature.
2011-01-13 06:14:14 +00:00
6a9d93a339 fix for NULL missing pointer check, reported on IRC by admix.
also rename BVH class for consistency.
2011-01-13 05:05:10 +00:00
8227b3d463 remove/comment unused vars
also removed unnecessary NULL checks (where the pointer was used later without checking).
2011-01-13 04:53:55 +00:00
57ce3072d1 Sculpt:
Small cleanup, de-duplicated the code for combining proxies
2011-01-13 01:02:55 +00:00
604d029ddf Bugfix #25570
The tool-redo depends on a working undo system, so it can rewind
a step and then redo operator with new settings. When a user
disables undo, this won't work.

Now the properties for redo operator (toolbar, F6) will grey out
when a redo isn't possible.
2011-01-12 18:00:23 +00:00
505e2d882a fix [#25590] Export to X3D of Text object does not assign material to object in X3D file. 2011-01-12 17:57:00 +00:00
da69433ff9 simple add mesh operator template. 2011-01-12 17:29:54 +00:00
792f3b11f9 bugfix [#24774] Lattice modifier+Dupligroup+Texture solid=weird result
new 2.5x code was not passing group recalc flags onto objects within them.
2011-01-12 16:53:27 +00:00
0384be9644 bugfix [#25595] Adding Torus when in edit mode strange behavior.
also added Align View option and made local view cursor work.
2011-01-12 15:45:00 +00:00
70fefd81ea fix [#25600] Cannot add meta-object when in edit-mode 2011-01-12 14:08:11 +00:00
4e15c169c6 Fix for [#25572] crash when changing vertex group density in particle mode
* Hair was freed & redone on changes, but particle mode data wasn't updated.
2011-01-12 10:01:33 +00:00
Nathan Letwory
4043830cf8 fix compile error for MSVC; no va_copy here. Patch pasted to me by Keith Boshoff 2011-01-12 10:00:47 +00:00
792bf1535f add x3d/vrml importer into the menu. 2011-01-12 08:20:09 +00:00
ac64114d1b vrml/x3d import
now its basically usable, next step is to add menu item.

update for changes in mathutils api.
- fix radians/degrees usage
- correct matrix multiplication order
- primitives were being imported twice the size they should be.
- uv transformations were not working.
2011-01-12 08:02:27 +00:00
eba91f8e81 modification to Joshua's commit r34270,
replace NlaTrack.active() function with a property, since this is used everywhere else.
2011-01-12 07:16:24 +00:00
baaaceb3eb comment array/collection skip(), since there was some confusion in this area which caused bugs on index lookups. 2011-01-12 06:16:15 +00:00
9a70c609e0 BLI_dynstr_vappendf() was cutting off the last character when allocating strings. 2011-01-12 06:01:07 +00:00
e2e5361eb2 BLI_dynstr_vappendf() was crashing with strings above 256 chars, this happens with some long reports.
Problem was using va_list value more then once, fix by using va_copy().

Note, va_copy() is c99 spec but only alternative I can see is to turn BLI_dynstr_vappendf() into a macro which calls va_start/end inline.
2011-01-12 05:49:33 +00:00
63018144ba remove redundant assignments & unused vars.
also minor functional changes
- OBJECT_OT_make_links_data() type property is now assigned to the operator property (so popup menu can find it)
- removing BG image now returns cancelled if no image is removed.
2011-01-12 03:41:12 +00:00
21fc4cabaf Patch [#25409] Changes to panels header "open/close" and "drag" zones
Submitted by: Peter Tarasenko (pit)

This patch switches the screen real-estate given to the "open/close"
and "drag" zones for panels.
- Now, the entire header is used for resizing (open/close) panels
instead of just the triangle widget being used for this. This makes it
a larger target for clicking on, making it easier to do so (Fitt's Law
in action!)
- Dragging panels now is relegated to the "grabber" zone on the top-
right corner only now. This reflects the lesser importance of panel
reordering in the panel designs now over being able to open/close
them.
2011-01-12 02:15:38 +00:00
bbdf47aa0b Patch [#24808] B-Bone display size
Submitted by Dan Eicher (dna)

Adds the ability to resize b-bones (ctrl+alt+S) using the python api

Bone.bbone_x
Bone.bbone_z
2011-01-12 01:36:12 +00:00
610a759ecc Patch [#24763] NLA Track & Strip methods
Submitted by: Dan Eicher (dna)

<quote>
Adds:

AnimData.nla_tracks.new(prev)
* (optional) prev -- add new track after this track

AnimData.nla_tracks.remove(track)

AnimData.nla_tracks.active(track)
* (optional) track -- track to set active
* returns active track

NlaTrack.strips.new(name, start, action)
NOTE: fails if the strip can't fit in the track as opposed to the
operator which will create a new track and add the strip to that.
* name -- name for new strip
* start -- start frame of new strip
* action -- action to assign to strip

NlaTrack.strips.remove(strip)
</quote>

---

I've resolved the issue (noted in the original patch) regarding the
validation of the created strip by creating and using a "dummy
AnimData" block to solve the missing dependencies.
2011-01-12 01:17:13 +00:00
144fb8ed1f "Pointer" properties can now be reset to some kind of "default" value
when using the Numpad0 feature to reset properties to their default
values.

While this implementation here is not a full/proper implementation, as
you cannot truly specify a default value for some pointers that may
require something other than NULL (i.e. nothing), this should be good
enough for the vast majority of (editable) cases which are fine if set
to NULL.

This is most noticeable with the Active Keying Set field in the
TimeLine header, where it's now possible to simply use Numpad0 to
clear it instead of using a confusing click+backspace+enter dance to
do the same thing.
2011-01-11 22:32:18 +00:00
37b903e32c Fix #25594: Adding mesh while in edit mode with multires - crash.
That primitives, which used ri crash blender, flips normals just after creation
and this normals flipping calls layers interpolation, but MDISPS layer
contains no data still.

Just added checking to layerInterp_mdisps.
2011-01-11 22:06:44 +00:00
0a535feef6 More missing descriptions for operators 2011-01-11 21:46:11 +00:00
f5929ced95 Gave all armature operators descriptions (for tooltips and API
reference docs)
2011-01-11 21:37:23 +00:00
19c02ae981 Added operator to show all armature layers (similar to the 3D View
"Show All Layers"). This has been mapped to Ctrl-Accentkey

If necessary, you can alter your keymaps so that this operator is
invoked with its "all" property disabled. This will only toggle the
first row (first 16) layers, which is useful in most rigs for only
enabling all the layers with rig controls and not showing the layers
with rig mechanics.
2011-01-11 21:12:48 +00:00
f7611b0fd3 Bugfix #25580
Raytracing didn't show soft shadow in reflections, nor did it do any
derivative even. Added a basic version for it in raytracer now, still
needs improvement on heavily curved surfaces. But it's better!

Examples:

Glass sphere, mirror cube and sphere, look how it ignores bump and shadow
http://www.blender.org/bf/derivative256.png

in svn now:
http://www.blender.org/bf/derivative-svn.png
2011-01-11 18:40:44 +00:00
1d4f1d2e41 bugfix - collection index lookups was not working correctly when some items were skipped. 2011-01-11 17:01:12 +00:00
c603fa9f7d revert own recent fix for collection length, this is incorrect, the bug needs to be fixed elsewhere. 2011-01-11 14:39:14 +00:00
52a470041e Bugfix #25581
Pressure sensitivity for Sculpt 'strength' got lost in code cleanup.
Added warning in code, the function call is confusing.
2011-01-11 14:01:23 +00:00
8397e3e476 continued x3d/vrml import update from 2.4x version
- parsed over 1000 vrml test files
- animataion import works again
- importing curves works again
2011-01-11 13:42:22 +00:00
d1b14e7878 Bugfix, own testing
When pressure was zero, a sculpt brush was still being executed
with step amount divided by zero, and thus entering eternal loop.

Maybe tablet-specific this but I wonder how this never got reported...
2011-01-11 12:36:49 +00:00
4134e4f3ae Adding script template for adding Builtin Keying Sets 2011-01-11 11:25:24 +00:00
7225efeba0 - Added operator to clear all transforms from Pose Bones. This makes
it easier to reset a rig to its default pose again
- Refactored clear pose operators to separate out the common parts,
and made sure that they all had descriptions
2011-01-11 11:09:37 +00:00
8d385404ab bugfix [#25542] do not work? "Bind camera to Markers" 2011-01-11 10:00:21 +00:00
ca3d4052de py/mathutils fix for eternal loop with Matrix.Rotation().
rotation range clamping used a while loop which would run forever when the value was so big subtracting a full revolution didnt change the value.

Solve by using fmod() and double precision angle.
2011-01-11 09:41:26 +00:00
5bcee8cd0a remove misc unused vars and correct theme name for face angles. 2011-01-11 07:40:31 +00:00
fded5e5ce5 comment/remove unused vars from particle and multires code.
also remove calls to dm->getFaceDataArray() within a loop for particle grid distribution,
instead call this once at the start and reuse the result.
2011-01-11 07:38:16 +00:00
37420b2cf2 use size clamped string copying,
also some compilers complain of using sprintf(val, str) so replace with BLI_strncpy().
2011-01-11 05:58:47 +00:00
94f1e8df79 change rna function action.fcurves.add() so options an enum flag rather then booleans.
(rna flags were not available when this was originally written)
 action.fcurves.add(frame, val, 1,1,1) --> .add(frame, val, {'REPLACE', 'NEEDED', 'FAST'})
2011-01-11 04:52:17 +00:00
1b9c56c423 bugfix [#25577] Ctrl-Z after adding Color Ramp key resets ramp.
buttons would not add an undo event if the button had no tooltip/draw-string.

 add a fallback string 'Unknown Action' so undo's are predictable.
2011-01-11 03:22:37 +00:00
22577d98c9 initial x3d/vrml importer port from 2.4x.
some files import now.
- no animation support yet
- no rad/deg conversion changes from 2.4x
- matrix multiplication still needs switching.
2011-01-11 02:49:01 +00:00
35e68e9785 - bpy.data.lamps.new() now takes a type argument since lamp type also sets class type this avoids needing to use ugly lamp.type_recast() after changing type.
- default vertex color layer name was UTTex when added from python.
2011-01-11 02:30:01 +00:00
d72639323b "New Action" Operator:
When creating new actions using the "new" button the Action Editor
header databrowse, or the NLA editor's "Animation Data" databrowse,
the existing action will get copied (if it exists) instead of an empty
action getting added everytime.

Apparently this behaviour is very good for being able to "version"
actions within a single .blend file (Bassam?)
2011-01-11 00:39:59 +00:00
571ad40e48 tag unused vars. 2011-01-11 00:21:43 +00:00
Nathan Letwory
dbb67b4d4c Fix [#25575] Collada import problem with Maya2010 exported collada files
Reported by Morten Mikkelsen

It seems that the maya export may generate invalid joint UIDs. Skip these joints to prevent crash.
2011-01-10 23:31:14 +00:00
ac4eb52abf - Local Markers are now taken into account correctly for operators
that used markers. I might've missed a few still, but at least a few
more cases will work now
- Accidentally broke keyframe selection on group channels in gpencil
commit, after misreading a call name.
2011-01-10 22:31:34 +00:00
cf25b10eb5 Todo #22395: Restoring Grease Pencil Editing Mode in DopeSheet Editor
This commit restores some basic functionality for retiming Grease
Pencil sketches. Some of the functionality that existed before still
hasn't been restored (namely snap/mirror tools as well as copy+paste),
though it should be possible to use this for basic retiming and
sketch-frame management again.

- There's still a lot of work required to get this up to the standard
of the rest of the animation editor code, as some of this code was
originally just hacked in based on the old-style code.
- Work is already required to not have to directly access the main db
global to get the list of Grease Pencil datablocks to show, but that
can come along with pending cleanups of the filtering code.
2011-01-10 22:10:28 +00:00
d841a20631 SVN maintenance. 2011-01-10 21:30:14 +00:00
795ca28a82 action paste properties were assigned to copy operator instead. 2011-01-10 17:48:38 +00:00
dd69f1968e rna collection sizes for face data layers were invalid.
This meant python could do...
  mesh.uv_textures[0] 
...on a mesh with 1 vertex color layer instead.
2011-01-10 17:46:34 +00:00
bfcea85c6f x3d import now passes pep8 checker 2011-01-10 13:56:14 +00:00
ff204a1e4d x3d import tabs -> spaces 2011-01-10 13:16:04 +00:00
f5c203af73 copy x3d/vrml importer from blender 2.4x.
svn cp https://svn.blender.org/svnroot/bf-blender/branches/blender2.4/release/scripts/import_web3d.py release/scripts/op/io_scene_x3d/import_x3d.py
2011-01-10 13:11:56 +00:00
3b413b6fa8 [bugfix] Curve tilt button in 3d toolbar showing wrong shortcut
Added Ctrl-T to Curves Tilt button in the toolbar (edit mode), currently was reporting Alt-S for tilt
(reported by Rickyx here http://www.kino3d.com/forum/viewtopic.php?f=21&t=8485&start=0)

Also added the label "Tilt" to the tilt transform in the Curve > Control points header submenu, currently was just "Transform"
2011-01-10 12:50:46 +00:00
dab4ffa85b Bug fix: effectors in pre 2.5 files didn't work due to a forgotten flag in do_versions. 2011-01-10 11:53:07 +00:00
1b19ffb8c7 "Available" Keying Set bugfix:
This builtin Keying Set is supposed to insert keyframes for every
F-Curve that exists for the selected data (usually objects and/or
bones only). However, as coded, it was only useful for objects, since
it would just go through all the F-Curves for the object's action,
instead of just the F-Curves relevant to a selected bone.

Tweaked the code to make this case (and similar ones) hopefully work
better by default.
2011-01-10 10:22:08 +00:00
b0af2b5f3e bug [#25535] proportional editing bug
disable PET when rotating/scaling around face centers to make it more obvious its unsupported.
2011-01-10 06:00:56 +00:00
35d261fde0 edit to Ton's recent commit, r34177, only use the far clipping as PET max when not in Ortho view. 2011-01-10 05:40:41 +00:00
5feb46d814 callback function ptcache_particle_extra_read() was incorrect type, also fix some other compiler warnings with recent commits. 2011-01-10 05:17:53 +00:00
ede0d85522 comment/remove various unused vars,
also make rna function for new images require width and hight args.
2011-01-10 03:58:07 +00:00
a9faad8b37 comment unused vars from subsurf code. 2011-01-10 03:55:47 +00:00
293c1422de comment dead code from RNA_pointer_create(), was finding the id pointer type when 'id' was set, but not using it.
also comment a few unused vars.
2011-01-10 03:47:03 +00:00
91db8f6012 add constraint operator
- report an error if adding a pose constraint with no active pose channel.
- dont run update_pose_constraint_flags() when adding an object constrant to an armature object.
2011-01-10 03:30:27 +00:00
d9c6f51ee2 Compiler warning fixes for the same point cache things Joshua tried to fix earlier, don't know why I didn't notice these before. 2011-01-10 02:40:24 +00:00
83806d4042 Bug fix: particles dying in collisions could lead to crash in some cases
* Forgot to check for index range in own recent pointcache commit.
2011-01-10 02:20:30 +00:00
56db5f10aa Restoring "Pose Markers"
These were markers which belonged to an action instead of the scene,
and are used by PoseLib to keep track of where poses are.

To restore this, I've made this only available in Action/Shapekey
Editor modes, and only when an action is being shown and the "Show
Pose Markers" option in the Markers menu has been enabled. Other than
that, all the standard marker operators apply now (instead of using a
separate set of special operators).
2011-01-09 23:16:05 +00:00
3fba5cfe7a Bumping up margin for catching marker events in animation editors.
Old value of 30 px was perhaps a bit too strict, given that scrollbars
took up 16px and that standard icons are 16px, which in total would
have been 32px from the bottom of the region. Having said that, the
marker icons are only about half-size, though it seems that in general
people (can) only aim quite loosely...
2011-01-09 22:37:29 +00:00
9231ff4160 Viscoelastic springs for sph particle fluids, original patch by Stephen Whitehorn (chickencoop)
* Viscoelastic springs between the fluid particles can simulate all kinds
  of viscous and elastic substances, such as jelly and honey. This is
  achieved by creating springs dynamically between neighboring particles
  and adjusting their rest length based on stretching/compression.
* This nearly completes the currently intended functionality for particle
  fluids. The last missing thing is a surfacing extraction algorithm,
  which is needed for a proper representation of a sph fluid.
* I also cleaned up and renamed some of the fluid parameters to make the
  ui a bit easier to understand.
* One addition to the patch is an option to use "initial rest length" for
  the springs, which uses the lengths between the particles at the time of
  spring creation as the spring rest lengths instead of interaction radius/2.
  This makes the fluid keep it's original shape better (good for very
  viscoelastic materials), but can create large density differences inside
  the fluid (not really physically correct for a fluid).
* Viscoelastic springs are stored in point cache as extra data.
2011-01-09 19:09:41 +00:00
84a464ab62 several cosmetic changes to the node-editor
+ changed lines connecting nodes:
   they now use a linewidth of 1.5px for the light foreground and 4px for the dark background.
   this should fix node-lines not being visible on almost black or all white backdrops.
+ muted nodes now also show a red tinted header if they are hidden (collapsed)
+ both active and selected nodes show a (now properly antialiased) highlighting frame
+ fixed a small error in dropshadow code resulting in a gap at borders
+ fixed a tiny error for the collapsing indicators (triangles) - they were not symmetrical.

Ton will add proper theme colors for the node-editor in the coming days.
2011-01-09 18:59:35 +00:00
4a8dd84625 Bugfix #25557
Using texture brush in Sculpt, was calling to use "osa tex"
without giving it osa sample vectors. This crashed in using
texture nodes.
2011-01-09 18:43:47 +00:00
1786923afc Replace uint32_t in pointcache code with unsigned int as it's supported in dna
* Not strictly necessary right now, but better for future.
* Struct data (only boids at the moment) is now written as structs (with dna) so they work between 64 and 32 bit machines too.
2011-01-09 18:23:41 +00:00
856d9c9057 Bugfix #25554
Actually a minor tweak: 
Auto-IK fails on correcting for constrainted bones in chains.
For that reason it stops including constrainted bones for it.

Now it does include constraints with influence zero, or which
were disabled by user input.
2011-01-09 17:49:38 +00:00
7bc46973d2 script now passes pep8 checking tool. 2011-01-09 17:35:29 +00:00
d9c24f7e7c patch from Andrea Rugliancich, dont export locations for bones which are connected to their parents.
note, we could be smarter about not exporting animation channels which are not needed.
2011-01-09 16:46:01 +00:00
99a835d482 warning from clang, possible crash:
'cd' could be NULL, all other particle draw types checked 'cd' except for PART_DRAW_AXIS, seems logical to have the check here too.
2011-01-09 15:28:43 +00:00
00b8c9e7ea rename BKE_assert() --> BLI_assert(). 2011-01-09 15:12:08 +00:00
9cb71d1159 update for change to Matrix class. 2011-01-09 15:09:18 +00:00
c9f353956c use PySequence_Size() rather then PySequence_Length(), this is only kept in python for backwards compatibility. 2011-01-09 14:53:18 +00:00
0660078b8b mathutils matrix initialization now matches other mathutils types.
(should have made this change along with the others).
Matrix([1, 2],  [3, 4]) --> Matrix(([1, 2], [3, 4]))
This is so adding initialization args works right.

Also simplify initialization code (re-use slice assignment).
2011-01-09 14:30:16 +00:00
99e203dbd4 Bugfix #25547
Improved report print for 'remove doubles' to make it correct english.
Unsure if this kind of code can survive though, static strings do much
better for future translation efforts.

Instead of providing nice grammar sentences, we could make it more
declarative, like:

"Removed vertex amount: %d".
2011-01-09 12:38:54 +00:00
a825df946a use PySequence_Fast for matrix slice assignment to speed up assignment. 2011-01-09 12:38:22 +00:00
2f24124e97 py matrix api
- bugfix for printing matrices (row/col mixup)
- replace cumbersome loop sequence parsing with calls to mathutils_array_parse
2011-01-09 12:09:54 +00:00
abcdd0377c Bugfix #25551
Transform crash on autokey during animplay.
Transform event handling requires Context, for inserting keys. 

Marked it with XXX warning; we have to be more careful with which
API calls require context; like inserting keys shouldn't need it?

Originally Context was meant for operators; to define user level
or scripted context, not for underlying APIs to work.
2011-01-09 12:08:29 +00:00
02aab4977f quiet zombie python class warning. bug remains but its not useful to print out so many errors when this wont be fixed for a while. 2011-01-09 11:54:12 +00:00
d31ebbe666 cleanup for mathutils multiplication functions, a little faster in some cases, raise more informative exceptions. 2011-01-09 09:16:04 +00:00
ca89269c22 Remove py mathutils Euler.unique() method
- this just toggled between different rotations, I can't find any references to this as a common operation to have with eulers.
- wasn't working at all nobody noticed, not used by any blender scripts/addons either.
2011-01-09 07:46:26 +00:00
e32bbef017 Fix for [#25544] Blender crashes when changing the particles emission amount
* I've getting bad feelings about the point cache index_array for a while (cause for this bug too), so from now on memory cache uses a simple binary search directly on the index data to handle queries to specific data points.
* This is a bit slower than just checking from a dedicated array, but it's much less error prone, uses less memory and makes the code more readable too, so it's not a tough choice.
2011-01-09 07:41:51 +00:00
76a762aa51 Fix typo in particle rna 2011-01-09 07:07:15 +00:00
cac2c016b0 stubs.c updates provided by Kupoman. 2011-01-09 02:43:26 +00:00
70a828d5a5 remove unused vars, comment some which look like they could be useful still. have makesrna.c omit unused _data definitions for rna funcs with no args. 2011-01-09 01:17:56 +00:00
c0bae16dad netrender
Downloading results for jobs from blender now uses the current output settings, it doesn't just download the multilayer exr as it used to.

Render output panel now visible under the jobs panel in client mode.
2011-01-08 19:42:26 +00:00
17e733a4fc Bugfix #25525
Duplicating viewer node crashed in cases; bad ID was given to a function.
Fix provided by Alexander Kuznetsov. Thanks!
2011-01-08 19:12:42 +00:00
16e7a26185 Bugfix, IRC report
Texture space transform, SHIFT+R crashed
2011-01-08 18:46:21 +00:00
ac56fef228 Todo items:
- Outliner: new scroll operator, PageUp PageDown scroll entire page now.
- 2D views (like buttons) PageUp PageDown now also scroll entire page.
  (they used same step as scrollwheel before)
2011-01-08 18:37:11 +00:00
5e8b877268 Crash fix, IRC report.
Python console crashed on opening.

Too quick code cleaning for "unused variables" caused a complete line
of code to disappear that was needed anyway :)
2011-01-08 17:47:34 +00:00
6594b591de Proportional editing:
- Proportional circle size is printed in header
  Allows you to find out if you make it smaller when it's large
- Proportional size is clipped with view3d clip-end now
- Added the size to rna, so you can inspect values via UI and py.
2011-01-08 16:54:38 +00:00
17dd29cb85 Bugfix, own collection
New displist code for curves/text copied display lists without 
checking for freeing existing ones. Caused some memleaking.
2011-01-08 15:35:15 +00:00
3b74074aec remove unused code & variables. 2011-01-08 12:43:44 +00:00
988e5371fa fix for crash when converting sequencer profiles with non-float buffers. 2011-01-08 12:22:16 +00:00
39e7848ca1 fix for using freed memory with animation/group/ungroup code. 2011-01-08 11:08:51 +00:00
d3d5fe42bf fixed a case with occlusion where uninitialized variable could be used.
also removed unused vars.

can_pbvh_draw() had a NULL check which is never needed (callers check for this), a NULL ob would have crashed the function anyway.
2011-01-08 10:23:36 +00:00
c35db522da variable 'pool' could be accessed as NULL, globalPool was allocated but not assigned before use.
also remove unused vars.
2011-01-08 10:13:59 +00:00
c2d133a9fc fix for drawing addons when one of them had a syntax error or would not draw any.
now print the error and continue.
2011-01-08 04:49:33 +00:00
053776bf57 Sculpt/Paint:
More cleanups: moved a function declaration to the correct module,
removed old/incorrect comments, marked more things with TODO where
appropriate, refactored copy-pasted function, de-duplicated code.
2011-01-08 01:45:02 +00:00
2579347a9a Paint:
More cleanups to the cursor drawing code; factored out another
sculpt-related function, replaced float calculations with bitwise
flags, removed unnecessary GL changes, de-duplicated some lines,
removed unused parameters, and added more comments.
2011-01-08 01:16:35 +00:00
14d6d1cdf6 More Windows+mingw compiling fixes:
FILE_FILE_MAXDIR/FILE were undefined. Restoring BKE_utildefines.h
include to make this work again in the meantime.
2011-01-07 23:54:58 +00:00
e415798e13 Removed some overly agressive (and IMO pointless) "UNUSED(arg)"
wrappers which was breaking compiling on Windows (mingw)
2011-01-07 23:47:12 +00:00
46bf79fd02 Paint cleanup:
Pulled out the paint brush overlay drawing code into its own
function, brush drawing function was before ~250 lines.
2011-01-07 23:36:48 +00:00
2d9c11f3a3 Paint/Sculpt:
More minor cleanups: fixed names and factored out a function that was
copy-pasted into paint stroke.
2011-01-07 22:46:52 +00:00
ab41b9bbaf Paint/Sculpt:
Some minor cleanups: removed `#if 0' code and moved a function into paint_util to avoid `extern' declaration.
2011-01-07 22:03:16 +00:00
473838aec9 Fix for bug [#21534] Multires modifier strange deformations
This adds the "Apply Base" feature from my gsoc2010 branch.

Apply Base partially applies the modifier, in that the mesh is
reshaped to more closely match the deformed mesh. The upper-level
displacements are recalculated so that the highest multires level
appears unchanged.

Multires does not currently deal well with too large displacements.
An easy-to-reproduce example: create any mesh type, add multires,
subdivide a few times, then use the sculpt grab brush to drag the
entire mesh over a few units. At the highest level, and at level 0,
the mesh looks fine, but all of the intervening levels will have ugly
spikes on them.

This patch doesn't help with situations where you can't modify the
base mesh, but otherwise works around the problem fairly well (albeit
with a heuristic, not an exact solution.)
2011-01-07 21:12:47 +00:00
ab11863b2f SVN maintenance. 2011-01-07 20:02:56 +00:00
89c9aaaa25 remove references to BKE_utildefines where its not needed.
- move GS() define into DNA_ID.h
- add BLI_utildefines as an automatic include with makesrna generated files.
2011-01-07 19:18:31 +00:00
8f21a43535 split BKE_utildefines.h, now it only has blender specific defines like GS() MAKE_ID, FILE_MAXDIR, moved the generic defines to BLI_utildefines.h.
no functional changes.
2011-01-07 18:36:47 +00:00
a601fd8893 Bug fix: unbaked particle cache was cleared from current frame onwards on file load. 2011-01-07 17:27:27 +00:00
b9fe5399e8 Revert bump mapping patch for now, backwards compatibility is not good enough,
we may need to preserve the previous method.
2011-01-07 16:55:56 +00:00
f01cac08e7 Fix #25078: texture mapping options (e.g. size) not working correctly with bump.
This problem was in both new bump and new new bump. The derivatives used for
bump mapping did not include the mapping, which gave mismatched offset for the
taps, now just do the mapping beforehand.
2011-01-07 15:41:24 +00:00
c8e0ca44a3 Improved bump mapping patch by M.G. Kishalmi (lmg) and M.S. Mikkelsen (sparky).
Many thanks to them!

For comparison, see here:
http://kishalmi.servus.at/3D/bumpcode/

Based on algorithm in: Mikkelsen M. S.: Simulation of Wrinkled Surfaces Revisited.
http://jbit.net/~sparky/sfgrad_bump/mm_sfgrad_bump.pdf

This fixes bugs:
#24591: Artefacts/strange normal mapping when anti-aliasing is on
#24735: Error at the Normal function.
#24962: Normals are not calculated correctly if anti-aliasing is off
#25103: Weird artefacts in Normal

This will break render compatibility a bit, but fixing this bugs would have also
done that, so in this case it should be acceptable.

Patch committed with these modifications:
* Bump method Old/3-Tap/5-Tap option in UI, 3-Tap is default
* Only compute normal perturbation vectors when needed
* Fix some middle of block variable definitions for MSVC
2011-01-07 14:42:01 +00:00
03e0f28ea0 bugfix [#25528] lack of update and crash using hook modifier. 2011-01-07 11:48:35 +00:00
3c6077e8ec Bug fix: particle point cache was reset on start frame if particles had grid distribution even if there were no changes. 2011-01-07 11:38:28 +00:00
29efbf8a04 New hair child options:
* Renamed children to "simple" and "interpolated" as this is
  easier to explain and more descriptive than "from particles"
  and "from faces".
* Also shuffled the child ui around a bit to make it clearer.
* Child seed parameter allows to change the seed for children
  independent of the main seed value.
* Long hair mode for interpolated children:
  - Making even haircuts was impossible before as the child
    strand lengths were even, but their root coordinates were
    not similar in relation to the parent strands.
  - The "long hair" option uses the tips of the parent strands
    to calculate the child strand tips.
* Hair parting options:
  - Hair parting can now be calculated dynamically on the fly
    when in 2.49 there was a cumbersome way of using emitter mesh
    seams to define parting lines.
  - For long hair parting can be created by a tip distance/root
    distance threshold. For example setting the minimum threshold
    to 2.0 creates partings between children belonging to parents
    with tip distance of three times the root distance
    ((1+2)*root distance).
  - For short hair the parting thresholds are used as angles
    between the root directions.
* New kink parameters:
  - Kink flatness calculates kink into a shape that would have
    been achieved with an actual curling iron.
  - Kink amplitude clump determines how much the main clump value
    effects the kink amplitude.
  - The beginning of kink is now smoothed to make the hair look
    more natural close to the roots.
* Some bugs fixed along the way too:
  - Child parent's were not determined correctly in some cases.
  - Children didn't always look correct in particle mode.
  - Changing child parameters caused actual particles to be
    recalculated.
* Also cleaned up some deprecated code.

All in all there should be no real changes to how old files look
(except perhaps a bit better!), but the new options should make
hair/fur creation a bit more enjoyable. I'll try to make a video
demonstrating the new stuff shortly.
2011-01-07 11:24:34 +00:00
7ad97b04b7 cmake: share the DNA_*.h list definition between makesrna and makesdna 2011-01-07 11:08:47 +00:00
841c50b5e2 Fix for [#25526] Inmediate crash when changing amount of particles in a particle system
* Point cache index array doesn't necessarily have all particles if the particles were re-allocated recently.
2011-01-07 10:38:17 +00:00
96128ee69f Fix for [#25506] Hair showing up in places not assigned by a weightmap
* Two separate bugs, with very similar symptoms.
* The distribution binary search didn't work correctly in cases where there were a lot of faces with 0 weights.
* Maximum distribution sum should have been exactly 1, but due to the wonderful nature of floats this wasn't the case at all.
2011-01-07 10:13:30 +00:00
57a3cff3b8 patch [#25440] Object.vertex_group fixin'
from Dan Eicher (dna) 

 From the tracker (with minor edits)
========================

cube = bpy.data.objects['Cube']
foo = cube.vertex_groups.new('foo')
foo.add([1,3,5,7], 1.0, 'ADD')

for i in range(len(cube.data.vertices)):
    try:
        weight = foo.weight(i)
        print('vert: %i weight: %f' % (i, weight))
    except:
        pass

foo.remove([1,3])

cube.vertex_groups.remove(foo)
2011-01-07 09:50:23 +00:00
41c00063dd another error in commit r34143, was using the define's 'BLEN' & 'DER_' however the latter is incorrect since DER- is used for 64bit blend files.
removed the define.
2011-01-07 09:47:05 +00:00
7fe16a24a4 fix for error in own commit r34143 2011-01-07 08:59:00 +00:00
54ceccd0ee - cmake use execute_process, exec_program is deprecated.
- game engine builds without python again.
2011-01-07 08:43:29 +00:00
f3a00259e2 bugfix [#25457] Lack of update on undoing a lattice rig 2011-01-07 07:36:51 +00:00
a132674634 patch [#25490] Fix for [#22096] Blender tries to open non-blend file
from Alexander Kuznetsov (alexk) with edits.

From the report:
Blender assumed that all files are .blend as retval = 0;

Now retval is initialized as file cannot be open (-1) for gzopen fail and directory case
retval = -2; is defined for not supported formats
This must be assigned before #ifdef WITH_PYTHON because this part can be missing
Finally retval = 0; if it is a .blend file

---
also made other edits.

- exotic.c's blend header checking was sloppy, didn't check data was actually read, only checked first 4 bytes and had a check for "blend.gz" extension which is unnecessary.
- use defines to help readability for BKE_read_exotic & BKE_read_file return values.
- no need to check for a NULL pointer before calling BKE_reportf(). (will just print to the console)
- print better reports when the file fails to load.
2011-01-07 06:50:29 +00:00
0db684be3c incorrectly documented return type 2011-01-07 06:39:48 +00:00
82659944c6 Fix/add OSX style text editing shortcuts to default keymap 2011-01-07 05:50:17 +00:00
0f2089afa1 py/rna api speedup for collection slicing in all cases, rather then having an exception for [:].
- avoid looping over the entire collection unless a negative index is used.
- dont use the get index function for building the slice list, instead loop over the collection until the stop value.
2011-01-07 05:33:30 +00:00
5d74d65106 bugfix [#25519] particlesystem, type hair, hair dynamics enabled: crash with amount 0 2011-01-07 04:38:31 +00:00
109d3b8454 bugfix [#25519] particlesystem, type hair, hair dynamics enabled: crash with amount 0 2011-01-07 04:30:02 +00:00
adf961a46c fix [#25520] crash when closing the properties panel in uv/image editor
don't draw the image if the size is 0.

Crash was actually an assert() so debug builds only, replace assert() with BKE_assert() so crash is opt in build option.
2011-01-07 04:10:37 +00:00
e14247d079 bugfix [#25522] Export to X3D is missing ImageTexture and TextureTransform for plane with image texture
- tile option was broken.
- added basic export of texture/mtex transformation.
- recent mesh update broke material/image export with no UVs
2011-01-07 02:39:48 +00:00
af64765456 Todo items:
- Toobar views were reset on hide/unhide. Now they keep the view
  and zoom level.
- Added operator to delete all unused 'space data', this to make
  clean startup.blend files, remove unused editors, and to be
  able to test starting defaults for editors.
  No hotkey, use search for "Clean-up space-data"
2011-01-06 17:54:17 +00:00
b67d08c3c7 Todo item:
Compositor: Texture Node now behaves like an image.
- Image always in render output size
- Buffer outputs RGBA and Value both supported
- Works for filter and blur and scaling too.
- Mixing 2 textures works

Implementation note:
The texture node was meant to be 'procedural', not a buffer
but a color-sample method. Unfortunately the node editor 
didn't support this well, blur/filter/scale ignored it too.

For now, its better to drop this procedural concept, then
things work at least as expected. :)
2011-01-06 14:58:58 +00:00
7b302d5052 Bug fix:
On texture-space transform, pressing Rkey crashed.
Now it refuses to enter rotation mode. :)
2011-01-06 14:19:46 +00:00
149955b3e2 print_m3/m4 didnt use const char *, which gave an errror with passing strings & pedantic warnings.
also minor rename in bvh export
2011-01-06 13:49:09 +00:00
5cef085f77 Todo item:
Auto-texture space now is more responsive and correct.
- on transforming it, the buttons get redrawn to show option was reset
- on enabling option, texture space is recalculated/reset
2011-01-06 11:16:35 +00:00
a4c0d644c9 Bugfix #25505
Mesh properties: Auto Texture space option missing
2011-01-06 09:55:20 +00:00
28e689b9aa bugfix [#25498] Projection paint clone tool leaves seams 2011-01-06 09:32:25 +00:00
3ecacb5654 fix [#25507] Select Interior faces in edit mode gives python error 2011-01-06 05:45:41 +00:00
80e6d92639 Missed this file for markers commit... it already had a markers menu
defined, but it was outdated
2011-01-06 05:04:44 +00:00
a0b134cd88 bugfix [#25488] Game engine crash when try to run after blender app start
- also found other places where utf8 isnt ensured.
- remove duplicate NULL checks in object_edit.c
2011-01-06 05:04:07 +00:00
aafd32ab98 Added back "Marker" menu to all animation editors.
Issues:
- It looks a bit crowded though, so perhaps we could do without, and
just leave it for the TimeLine only?
- Due to the way the invoke() testing works, the rename operator
called from the menu currently fails. Will need to experiment more
with execution options to find a workaround.
2011-01-06 04:47:57 +00:00
bba20eb5ae use ED_markers_get_first_selected() where possible, simplify ed_marker_rename_exec 2011-01-06 04:35:57 +00:00
68b931b03f py/rna optimizations, will help for faster exporting.
Speedup for getting collection indices, avoid getting the collection length unless a negative index is given. This avoids a loop over the entire collection in many cases.

Speedup for getting collection slices by detecting collection[:] and internally calling collection.values(), this gives a big speedup with some collections because each slice item would loop over the list until that index was found.

Rough test with 336 objects.
- getting index of listbase collection ~ 5.0x faster
- getting index of array collection ~ 1.15x faster

- getting slices of listbase collections ~ 34.0x faster
- getting slices of array collections ~ 1.5x faster
2011-01-06 04:01:06 +00:00
1246f1c9b5 Markers Todo: Adding back "Rename Marker" operator (Ctrl M).
As we don't have any dedicated text-input boxes anymore, this is a bit
more clunky than it should optimally be.
2011-01-06 03:10:41 +00:00
f233f63d97 == Long-Standing 2.5 Todo - Markers fully working again in all
animation editors (DopeSheet, Graph Editor, NLA, Sequencer) ==

=== Usage Notes ===
In animation editors, marker operators will only be considered while
the mouse is hovering near/over the horizontal scrollbar (i.e. where
the markers usually appear). That means, in order to do something to
the markers, just position your cursor in line with the row of
markers, and then use the same hotkeys you'd use in the TimeLine (so,
unlike in 2.4x, no more need to hold down extra modifier keys for this
case). In the TimeLine, nothing changes, so you don't need to worry
about mouse placement there :)

=== Technical Details ===
Since early 2.5 versions, this functionality has been disabled, as the
markers were always getting evaluated first, and hence "swallowing"
all the events before the editor's own keymaps could access them.

In order to get this working again, I've had to give every marker
operator a "wrapper" invoke callback which performs some checking to
ensure that the mouse is close to the markers (vertically) before the
operator will try to be run. This wrapper also makes sure that once
the operator has finished running, that if it didn't manage to do
anything, then the editor's own keymaps get to have a go.

The vertical tolerance used is currently 30 pixels (as was used for
the borderselect operator).

=== Other Assorted Changes ===
* Gave marker operators dependent on having selected markers to
operate on suitable poll() callbacks. These new poll callbacks ensure
that there are selected markers for the operator to operate on,
further cutting down the number of places where markers may override
standard hotkeys (and avoiding calls to the wrappers too)
* Simplified some of the selection code
* Made some formatting tweaks for consistency, and in one case so that
my text editor's function-list display doesn't get confused
2011-01-06 02:35:12 +00:00
af5ed099e9 Improve reliability when setting property editor context via rna 2011-01-06 02:20:30 +00:00
6247a11076 fix for error in own recent commit, r34098. 2011-01-06 02:20:25 +00:00
9b8cbe47bd error in recent x3d commit using undefined autosmooth var. 2011-01-06 01:45:25 +00:00
a15189f845 fix for clang static check warnings.
- convertblender.c, remove assignments to unused vars.
- readfile.c, fix 2 possible crashes. null pointers were being checked for then used later without checking.
- space_graph.c, use switch statement for automatic color assignment rather then a float array.
2011-01-06 01:35:07 +00:00
5f64450726 remove assignments which are unused. 2011-01-06 01:29:13 +00:00
7196fb370e == blender icon ==
I've been asked by Giuseppe Ghibò (joeghi) for more icons for Mandriva Linux distro.
I've noticed that some folders had a blender.svg different from the one in scalable/, so made them all the same derived from 
scalable/blender.svg

Now each svg file has "document properties" of the right dimensions according to the folder it's in, and the svg is saved so that people
just have to press "export bitmap" in Inkscape in case they need it.
2011-01-05 20:18:16 +00:00
a46689b15d SVN maintenance. 2011-01-05 19:19:49 +00:00
979742241f Bugfix, irc report:
Outliner: using the object-data icons to enter editmode, didn't
reset the toolbar Operator redo. It was not using an operator
call here. Note to self: more outliner tools don't...

Error was that operator-redo then would repeat an action incorrect.
2011-01-05 18:12:54 +00:00
37931a6b1a Todo item: brought transform texture space back.
Code changes are minimal, re-using the code as already was there.

Options are in pulldown menu, or SHIFT+T and SHIFT+ALT+T

Might be that Martin likes to see it different... do we need
a special operatortype for it?
2011-01-05 17:27:26 +00:00
91d352024b Get rid of uninitialized variable and malicios derived mesh relising.
Pointer by llvn analyzer.
2011-01-05 15:58:44 +00:00
054deb4584 remove ED_retopo.h 2011-01-05 15:37:36 +00:00
b067a85aa3 Todo item:
Object color option now is incorporated in preview render, and
in display in 3D window.

Note that Object-color is "modulating" the render result, it just
multiplies... which is very limited for practical use. This was
added for Apricot game project. The original meaning however was
to replace diffuse only... so specular and light work still correct.

ALso made header for properties editor start on top, to reflect
default (report in tracker).
2011-01-05 15:10:35 +00:00
01b7299bdb bugfix [#25393] Export to X3D does not provide color field in indexedFaceSet for colored cube
mostly rewrote mesh export and added support for multiple materials/images, using texface or material images depending on the materials TexFace option.
2011-01-05 14:57:57 +00:00
a45183125a Patch: [#22524] Update Windows Recent Documents on Open/Save
Slightly modified to better fit in architecture (moved to related GHOST SystemPaths)
Thanks to Harley Acheson for the research and for providing the original patch.

Note: I added empty function for X11(Linux) and Mac (Carbon and Cocoa) to be implemented still.
2011-01-05 14:56:10 +00:00
978bc0d8ac fix for py/rna mesh.materials[:] where empty materials exist, would raise a runtime exception.
problem was there was no way to tell the difference between getting an empty item from a collection or the item not being found.
2011-01-05 14:49:08 +00:00
26024445ac Fix #23604: external shadows for volume materials don't work 2011-01-05 14:20:48 +00:00
195cc9c6a6 ToDo: long outstanding patch to allow access to system paths in background mode
Thanks Damien Plisson for contributing the Carbon and Cocoa implementation
2011-01-05 14:00:14 +00:00
8e29c7b76f Material slots: on adding a new one, the material datablock is now copied again
like in 2.4x. This can result in material datablocks you don't need, but not
doing it seems to cause too much confusion.
2011-01-05 13:15:29 +00:00
0daebd0ed6 Fix #25316: distorted subsurf UV in some cases. To counter distortion at seams,
we add extra creasing in the UV mesh, to keep it from shrinking, leading to
distorted UVs, but this wasn't always working right, so tweaked the conditions.
2011-01-05 12:04:06 +00:00
288c45db59 Marker Bugfixes ("Make Links to Scene" operator):
Some tweaks for this operator, found while scanning through the
current state of the markers code. These seem to be correct judging
from the overall direction the code is going in, though the intention
of this operator seems a bit unclear from the naming.

- Fixed potential issue where with only some markers selected (and the
last one selected not being the last marker in the source scene), you
could end up chaining the source and destination marker lists together
improperly.
- Clarified description/error messages...
2011-01-05 11:15:57 +00:00
7ec8761250 Fixing bugs in future:
DNA reconstruct now terminates strings, when the new string
in a file is longer than in current definition. This will
enable a safer ID and other name lengthening, keeping at
least some forward compitability.
2011-01-05 10:54:30 +00:00
64c3ea272e Todo item: linked curve objects behaves incorrect with modifiers
Use object's displists for storing deformed tesselated curve. Was unable to
totally get rid of curve's displist because of how texture space is calculating.
2011-01-05 10:40:38 +00:00
Nathan Letwory
730634ca51 Enable sndfile by default on win64 2011-01-05 09:00:28 +00:00
7a7760e938 Fix for [#25492] Cached particles are killed too early
* Own mistake from the sph particle fluids fix.
2011-01-05 08:52:13 +00:00
c8f0404f53 Bugfix #25494: Lattice keyframes can't be selected in dopesheet
(summary)

Oops.. missed one place
2011-01-05 08:31:05 +00:00
998b789138 use x3d Group's rather then IndexedFaceSets to re-use objects. 2011-01-05 07:14:26 +00:00
2028fb45ee X3D export
- last commit broke export
- more removal of not used functions.
- use twoside mesh setting rather then face flag.
- simplify transformations.
2011-01-05 06:58:52 +00:00
2225db0025 re-arrange x3d mesh export funcs in preparation for fixing [#25393] 2011-01-05 06:29:43 +00:00
14880d0713 X3D Export,
- mesh creaseAngle was being exported as degrees, should be radians.
- remove unused vars & code.
- indenting was using a for loop, can just multiply a string instead.
2011-01-05 05:53:41 +00:00
370adc51ff py api function to tag all ID blocks, was available in 2.4x as.
bpy.data.meshes.tag = True

But this was only useful for setting so make it a function for 2.5x.
 bpy.data.objects.tag(False)


X3D: use tagging rather then a name dictionary, this fixes a bug where library name overlaps could mix up names.
2011-01-05 05:33:27 +00:00
d387c19444 pep8 cleanup. 2011-01-05 03:22:46 +00:00
96b646c68d edits for BPY_extern.h functions, no functional changes
- remove unused code.
- BPY_run_python_script() split in 2, BPY_filepath_exec, BPY_text_exec
- renamed funcs.
2011-01-05 02:08:54 +00:00
8200e44c39 Removed a call to glPopMatrix that had no corresponding glPushMatrix. 2011-01-05 02:08:27 +00:00
a9f8083551 Adding overhead drawing (frame rate, profile, debug props) capabilities back to the Blenderplayer by replacing commented out BMF_* functions with BLF_* equivalents. 2011-01-05 01:34:33 +00:00
09852b9a58 Animation data for lattices is now shown in the Animaton Editors 2011-01-05 00:37:21 +00:00
Dalai Felinto
95dcf11a88 BGE: Font Object support to animated (object) colors
implemented the support for animated colors and a workaround for non animated colors. To be cleaned if/when this bug is fixed:
[#25487] BGE: Object Color only works when it has a keyed frame

* also increased the size of the text. Now it supports 280 (or 140 unicode) chars.
2011-01-04 21:27:44 +00:00
b9cda80cbb Note sure if this file is used still... named it 2.56a 2011-01-04 17:53:02 +00:00
8279d66cdc Fixed readme.html only went to the tag branch, now in trunk. 2011-01-04 17:49:43 +00:00
90a4e6a93d Don't commit with compiling first ;) 2011-01-04 16:39:05 +00:00
51a3d123e1 Todo item: notifiers sent from Material changes invoked Compositor
jobs. Now proper checks have been added, also for texture nodes.
2011-01-04 16:31:36 +00:00
231f3a4e2e fix [#25388] Export to X3D generates texture fields in X3D file for objects
use vertex color paint setting to export vertex colors when a material is assigned.
2011-01-04 15:25:12 +00:00
a952de66b0 todo item:
Files saved with image-window composite preview panel still
rendered cropped, but theres no way to disable it. Now it
ignores cropping.
2011-01-04 15:19:16 +00:00
5db20b512e Todo item:
New option to start threaded wmJobs, with flag WM_JOB_SUSPEND.
This makes the job wait 1 timer step before running. 

Used now for Material Icon render renders, which makes the
big preview to be always rendered first while using UI.
2011-01-04 14:59:55 +00:00
becca813d7 Crease tool brush missed brush color changing depends on brush appearance. 2011-01-04 14:55:29 +00:00
df29715498 Fix #25483: Brush appearance color
Set special brush flag when inversion stroke was started, not wery nice, but
we can't make better with current events system implementation.
2011-01-04 14:46:29 +00:00
8b1bfbcfea Todo items:
- File Window: when opened with operator (save, load, etc), you 
  couldn't start a new one, causing memleaks. Now it nicely 
  refreshes file window for new operator.
  Also means you can make CTRL+F3 screenies of filewindow now.
- CTRL+F3 screenshot had memleak on cancel.
2011-01-04 14:37:21 +00:00
c2bc82c9fc Bugfix #25486
MedtaBall editmode, 3D window, menu "Select" had an error, unknown
operator for select/deselect. Fix provided by Jonathan Smith
2011-01-04 13:10:46 +00:00
221187bcbd comment assert and ensure meshes are always calculated with CD_MASK_BAREMESH, scene->customdata_mask should be corrected in background mode but for now this is ok. 2011-01-04 12:31:42 +00:00
1704a5546d fix for makesrna error on windows where files cant be removed when open. 2011-01-04 10:37:22 +00:00
f4cebea207 print a message if the file cant be removed, may help narrow down why there are problems with MSVC at the moment. 2011-01-04 10:28:37 +00:00
9cafe19c70 - use BKE_keyingset_free_path where paths were being freed inline.
- rna_path was being freed when null, printing errors.
2011-01-04 08:56:25 +00:00
a735629fd1 no need to define betz in editcurve.c, replace ob_get_key with inline check for anim filter code. 2011-01-04 08:00:16 +00:00
f71ff8639c Fix to make two-side texface option work with modifiers in the BGE. However, there appear to be some issues when a mesh has mixed two-side and non two-side faces. I think it's a problem in the converter and possibly related to this bug: https://projects.blender.org/tracker/index.php?func=detail&aid=24948&group_id=9&atid=306 2011-01-04 07:43:32 +00:00
34fe2cd733 Fixed malicious selection checking in make segment operator.
Thanks to Campbell and CLang :)
2011-01-04 07:32:26 +00:00
72735b104d Fixing Grease Pencil typo noted while scanning through Mike Erwin's
GSoC10 work. Cheers Mike for catching this!

Also removing the use of sqrt() as noted in a "todo" comment there...
2011-01-04 06:28:44 +00:00
f3c8e4ddff No functional changes. Just formatting cleanups for now... 2011-01-04 06:18:58 +00:00
f228899e49 Grease Pencil: Redo for sketching sessions now works 2011-01-04 05:57:05 +00:00
a2d055af14 Fix bug #25471 2011-01-04 04:56:27 +00:00
cdc7d0b85f Grease Pencil Todos: "Sketching Sessions"
Due to popular request and usability considerations, this commit
reintroduces functionality similar to 2.4's "Draw Mode" for Grease
Pencil.

In the toolbar under the Draw/Line/Eraser buttons, you can find the
"Use Sketching Sessions" toggle, which enables this feature. This is a
per-scene setting, and defaults to off, so that the current 2.5
behaviour is still the default (i.e. the Grease Pencil operator will
only do a single stroke at a time).

With this option enabled, drawing with Grease Pencil will enter a
semi-modal state where you can draw multiple strokes without needing
to keep holding the DKEY throughout (though you'll still need to do so
to start the strokes, unless you use some toolbar buttons), while
still being able to manipulate the viewport. Header help-text prints
show the appropriate keybindings (i.e. press ESCKEY or ENTER to end
the sketching session).

Notes:
- To aid maintainability of the 3D-View toolbar code, I've taken the
liberty to factor out the groups of widgets which commonly occur in
most of the toolbars into separate functions (namely "Repeat" and
"Grease Pencil"). Perhaps it might make it slightly harder to newbies
to the toolbar code to grasp, though the physics panels are far worse
;)
- I've reshuffled some code in the Grease Pencil code to separate out
the various states of operation again more clearly, though some more
work is still needed there (TODO)
- There can now be only one Grease Pencil operator running at a time
- Redoing Grease Pencil operations where sketching sessions was
enabled still needs work. Namely, a way of delimiting the set of
points recorded into strokes is still needed (TODO)
- Ultimately, it should be possible to switch tools midway through a
session. Currently sessions are limited to only being able to be used
with a single drawing mode (TODO)
- After ending a drawing session, the titlebar contols may not work on
Windows without manually making the main window lose focus and then
regain (i.e. click on some other window in toolbar, then come back).
This may be related to (bug #25480)
2011-01-04 03:14:01 +00:00
5226155369 Memory for bevelSplitFlag wasn't duplicated in copy_displist.
Also corrected memory allocation comment for this array.
2011-01-03 19:45:08 +00:00
5eaad696e8 Bugfix, own collection
Graph editor: sliding Nkey Properties to left, closing curves view
entirely, was hanging in eternal loop. Caused by division by zero.
2011-01-03 18:57:13 +00:00
6b82aa8d01 fix for crash when some classes didnt register properly (this included loading sintel.blend). 2011-01-03 18:15:15 +00:00
9297cb01f6 Todo item:
2D view scrollers were drawing over background contents, making it
look somewhat messy (like for text, nodes, fcurves). Now it clears
first the back in the region edge.
2011-01-03 18:14:10 +00:00
3902eca8ca Image window Scopes (P key): the 4th "line histogram" was not
initialized on 100 pixels height on creation.
2011-01-03 17:37:37 +00:00
3f0210ca1d User pref button for 'drag threshold' 2011-01-03 17:01:08 +00:00
be5f30416b Todo item
Drag/drop now has a User preset for dragging threshold.
Noticed this was set to 3 pixels even, made it 5 as default.
Tablet owners can put it larger too :)

Note: the tweak-threshold (3d win) is 10 pixels now, I think
this needs another preset too, leave this for now.

Also: fixed crash in filewindow: drag .blend icon and drop it.
You can't test anything in Blender or you get a bug :)
2011-01-03 17:00:49 +00:00
e86a489327 Ported back import BVH as Empties, uses delta transformations.
& small pep8 changes.
2011-01-03 16:22:30 +00:00
2ad8175597 Todo: Material nodes
- On each re-render, the node image was cleared. Skipping this gives
  nicer pictures
- Node render was using AA, but unfortunately only 1 sample for Nodes
  is being stored. Disable AA render for now, nice speedup too.
2011-01-03 15:50:08 +00:00
9676902006 Todo items:
- New Node editor now opens with larger view, the default
  was like zoomed in factor 2.
- Add node via menu now shows new node more visible
- Click on (material) node now doesn't re-render the entire
  tree anymore, much nicer.
- Duplicate node creates preview image immediate
2011-01-03 14:36:44 +00:00
6ae84f96e0 fix for linking on msvc with own recent changes. 2011-01-03 14:30:59 +00:00
a41ec761fd rename layout.red_alert to alert, may be themeable some day. 2011-01-03 13:33:07 +00:00
72e8a0c552 check modifier keys are not pressed when using keys as accelerators, it meant you couldn't copy the operator from a menu with Ctrl+C because C would be used to activate an item. 2011-01-03 13:13:54 +00:00
8a2a7687f4 Bugfix #25457
After loading file, the Undo-push happened too early, causing an
undo for the first action to show animated setups wrong.

(material.c: removed old crap)
2011-01-03 12:48:16 +00:00
486c3cd937 DAG_id_tag_update was being called with non object ID's and OB_RECALC_* flags which only apply to objects. harmless but misleading. 2011-01-03 12:41:16 +00:00
16fdbd8552 Bugfix #25471
Scopes widgets in Image Editor (Pkey) could be dragged to zero size.
Now limit is 20. Thanks Mario Kishalmi for patch!
2011-01-03 12:13:48 +00:00
33a5a69d25 fix for own error with mathutils.geometry argument parsing.
also raise ValueError when the vector size is incorrect rather then type error.
2011-01-03 12:11:05 +00:00
f7857ec81b 2.4x <-> 2.5 Regression Fixes: Shapekey Problems
This commit partially fixes the problems with Shapekeys from older
files, as seen from the Regression suite (relative.blend and
dolphin.blend in particular).

In older files, keyblock->slidermax was never truly set to 1.0 even
though the UI may have shown such a value (which was bizzarely being
sourced from somewhere else). Hence, after loading the files in 2.5,
the shapekeys wouldn't animate, as the value would get clamped between
0 and 0.

To fix this, I've added a version patch which corrects these
situations in old files, and I've adjusted the slider-RNA code so that
it is not possible to set up such clamping anymore.

TODO:
The fixes detailed here only make it possible for these files to work
again in 2.5. However, I haven't been able to find a way to get the
files to actually work in 2.5 without manually changing the active
shapekey (per object) after loading the files with these patches
applied. Possibly it's just some depsgraph magic needed, unless
there's still some other evil voodoo in the shapekey code
2011-01-03 11:58:19 +00:00
e7ed8a3be0 fix for [#25470] single property driver vars don't update 2011-01-03 11:50:10 +00:00
7d1fce5533 Bugfix #25449
Adding surface objects via top menu crashed for option
"view aligned". Bad context checking.
2011-01-03 10:47:36 +00:00
35422ac536 rna/api
move Object.update(...) to ID.update(). since depsgraph update function can now be called on ID types.

also changed how update flags work.

  obj.update(scene, 1, 1, 1)
... is now
  obj.update({'OBJECT', 'DATA', 'TIME'})

Don't pass scene anymore. This was used for recalculating text but I think this is better dont in a different function.
2011-01-03 09:09:30 +00:00
dacdfbe6f3 recent change to keyframe menu broke BVH import, now don't use the operator at all, instead assign the action manually.
Also added bpy.path.display_name_from_filepath(), since filepaths are not ensured to be utf8.
same as calling:  os.path.splitext(os.path.basename(name))[0].encode("utf8", "replace").decode("utf8")
2011-01-03 08:28:22 +00:00
e6d1f25842 remove rna func scene.collada_export(), export functions dont exist for any other formats, calling operators should suffice. 2011-01-03 07:42:30 +00:00
1306a38133 fix for own error in recent commit. 2011-01-03 07:07:18 +00:00
f533630585 dont draw lamp volume when its being used as the view camera, would flicker annoyingly when flying the lamp about to position it. 2011-01-03 06:45:47 +00:00
22b97743ef avoid int/float comparisons within a number of for loops in deep shadow map compression.
gives minor overall speedup.
2011-01-03 06:13:50 +00:00
97e84765cd stubs.c updates for uiLayoutGetRedAlert and uiLayoutSetRedAlert 2011-01-03 06:08:17 +00:00
ca0b5434fa Keyframing Operator Code Cleanup:
Keyframing operators now use a dynamically-generated enum for their
"type" property, which determines the Keying Set to use for keyframing
instead of the obscure "index" values which were determined
internally. Internally though, these same indices are still being used
:)

Notes:
- I've kept the menu-building function and the special "menu" operator
for now, since it's better to not "pollute" the actual insert
keyframes operator with hardcoded menu-showing logic. Instead, the
menu operator does that, so that if you like, you could write another
such wrapper that works differently.
- The 'type' properties could have the PROP_HIDDEN flags removed,
though I think it's cleaner to leave these without this option for
now.
2011-01-03 05:36:52 +00:00
1ba9dde22d - add in asserts for unlikely cases of invalid ID types being assigned to key->from.
- mode duplicate pointer/offset code into a static function.
2011-01-03 04:59:57 +00:00
27b0bfef77 fix for possible comparison of un-initialized variable.
vol_get_bounds() only runs when shi->flippednor==0, but is.hit.ob was being checked afterwards irrespective.
2011-01-03 04:46:37 +00:00
17c3275c36 bugfix [#25459] Zooming out with view3d.zoom() crashes blender completely 2011-01-03 01:26:54 +00:00
6feddb8b61 Constraints UI Tweak:
Experimental tweak for the "Object Constraints" tab so that it now
shows a warning message instead of the "Add Constraints" button when
the active object is in Pose Mode. Hopefully this will further
alleviate any confusion over Object vs Bone level constraints.

Todo:
While coding this, I noticed that we currently don't have any way of
making help-text labels in UI panels which can span multiple lines
(word-wrapped or manually split). Probably not a critical issue, but
it would be nice for completeness...
2011-01-02 23:50:16 +00:00
c052a65b93 "Red-Alert" flags can now be set on UI layouts via the RNA API too 2011-01-02 23:47:48 +00:00
c7aa4f86a8 Bugfix:
Setting the group for F-Curves from the Py-API (i.e. to move F-Curves
from one group to another) was failing. After debugging this, this
functionality should now work correctly, while still prohibiting the
setting of groups on "F-Curves that aren't in actions" (i.e. driver-
fcurves)...
2011-01-02 23:47:03 +00:00
9b4adf76e3 Fix #25456: using Live Unwrap always unwraps with method Angle Based. 2011-01-02 21:13:28 +00:00
05cfe50436 Bugfix #25446 (and todo item)
The icons for materials were always lagging or not updating
at all. I also found it suspicious slow... 
It appeared that the icons now store a "mip level", where for
every change in Materials 2 render jobs for icons were started,
one for 32x32 pix, one for 96x96. The latter was cancelling out
the first job almost always.

Also made preview renders detect size, to set amount of tiles
to be rendered. Small icons use 1 part, larger previews 16 now.

All in all, behaves much smoother now! But, will also update
the thread Jobs manager to allow "delayed jobs" like for icons,
these are aggressively put as first in the jobs list.
2011-01-02 19:46:32 +00:00
5d6c76c6a3 Spelling fix: itterator->iterator 2011-01-02 19:00:32 +00:00
fe44c6596d Small changes to new pointcache code:
* Removed the unused fuctions spotted by Campbel.
* Removed the gotos to make Ton happy.
* Added better debug prints to disk cache operations.
* Fixed a memory unmap error that seemed to happen on a test file.
2011-01-02 18:10:33 +00:00
78162fa793 Splitting quad into triangles and merging triangles into quad should
work correct with sculpting data now.

Joining two triangles could give incorrect sculpting result for
special topologies, but it's that case that can't be nicely handled
with our layers architecture.
2011-01-02 17:38:22 +00:00
24e80665d8 New customdata layer callback: validate
Used to validate displacement allocation size after face copying
to match face vertex and displacement corners count.
2011-01-02 17:08:25 +00:00
76f0569a86 Multires math function used for layer interpolation moved from customdata.c to multires.c
No functional changes
2011-01-02 16:43:28 +00:00
7b865b5ce8 Crash fix for pointcache... bad goto's here. 2011-01-02 13:57:06 +00:00
118667c1bf Small feature for debugging pleasure:
The svn revision nr is saved in Blender file header now.
Can only be retrieved with running blender -d now.
2011-01-02 13:33:32 +00:00
939cf114bb Bugfix 25451
Tooltip for "default render output" was wrong.
2011-01-02 11:14:47 +00:00
a7ceeafd71 - correct typos in comments.
- move boxpack struct out of the public header.
2011-01-02 11:06:50 +00:00
4119132580 Fix #25435: remove code that enabled EWA filter on mipmap toggle, should not
have been there, mistake in removing SAT filter.
2011-01-02 10:52:21 +00:00
f6a034a481 CMake fix so MSVC works again. Fix suggested by Tamito Kajiyama. 2011-01-02 10:21:03 +00:00
8c86d2da3a Quiet warnings from last commit.
Janne: could you check if ptcache_file_pointers_seek() & ptcache_read_init() can be removed?
2011-01-02 10:13:17 +00:00
6127bcf854 CXX_Guardedalloc was complaining about freeing NULL pointers in VideoTexture. I've added guards around the deletes to prevent this. 2011-01-02 10:05:22 +00:00
f101e59e09 python api: rna array slices now return tuples rather then lists (fits with recent change made to mathutils).
minor improvements/cleanup to exporters.
2011-01-02 09:54:44 +00:00
a6a2512f47 Pointcache code cleanup and disk cache compression options:
* Massive reorganization of pointcache code, things are now cleaner than ever.
* For all but smoke the cache is first written to memory when using disk cache and after that written to disk in one operation. This allows less disk operations and the possibility to compress the data before writing it to disk.
* Previously only smoke cache could be compressed, now the same options exist for other physics types too (when using disk cache). For now the default compression option is still "no compression", but if there aren't any problems this can be set to "light compression" as it's actually faster than no compression in most cases since there's less data to write to the disk. Based on quick tests heavy compression can reduce the file size down to 1/3rd of the original size, but is really slow compared to other options, so it should be used only if file size is critical!
* The pointcache code wasn't really 64bit compatible (for disk cache) until now, so this update should fix some crashes on 64bit builds too. Now all integer data that's saved to disk uses 32 bit unsigned integers, so simulations done on 64bit should load fine on 32bit machines and vice versa. (Important disk cache simulations made on 64bit builds should be converted to memory cache in a revision before this commit).
* There are also the beginnings of extradata handling code in pointcache in anticipation of adding the dynamic springs for particle fluids (the springs need to be stored as extradata into point cache).
* Particles were being read from the cache with a slightly wrong framerate. In most cases this probably wasn't noticeable, but none the less the code is now correct in every way.
* Small other fixes here and there & some cosmetic changes to cache panel, but over all there should be no functional changes other than the new disk cache compression options.
* This whole re-organization also seems to fix bug #25436 and hopefully shouldn't introduce any new ones!
2011-01-02 06:52:47 +00:00
d5820f0dd0 bugreport & fix [#25441] Copy Transforms Constraint head/tail fixin'
from Dan Eicher (dna)
2011-01-02 04:16:19 +00:00
9f88e0faeb Fix for [#25427] cloth or soft body crash un Undo
* Argh my bad, sorry about this!
* Now only the actual data array is saved to avoid constant re-allocations, but no relations to active data are kept.
* Also reverted Ton's quick fix for the crash as it's not needed anymore.
2011-01-02 03:55:26 +00:00
03d046ad4f report & fix [#25447] SceneObjects null pointer dereference crash
from Dan Eicher (dna)

noticed sequence swap also wasn't checking for None.
2011-01-02 02:48:45 +00:00
129b6190ed geometry module
- rename functions from camel case.
- added docs for undocumented methods.
- minor functional changes with exceptions and accepting 3d/4d vectors where it makes no difference.

Renamed:
 - geometry.Intersect -> intersect_ray_tri
 - geometry.ClosestPointOnLine -> intersect_point_line
 - geometry.PointInTriangle2D -> intersect_point_tri_2d
 - geometry.PointInQuad2D -> intersect_point_quad_2d
 - geometry.LineIntersect -> intersect_line_line
 - geometry.LineIntersect2D -> intersect_line_line_2d
 - geometry.BezierInterp -> interpolate_bezier
 - geometry.TriangleArea -> area_tri
 - geometry.QuadNormal, TriangleNormal -> normal
 - geometry.PolyFill -> tesselate_polygon
 - geometry.BoxPack2D -> box_pack_2d
 - geometry.BarycentricTransform -> barycentric_transform
2011-01-02 02:11:38 +00:00
577e3b435e removing epydocs for mathutils and geometry mododules (now they are in sphinx) 2011-01-01 23:53:48 +00:00
559059ab3f Fix [#25442]: (Ghost Cocoa) Add missing initialization of associated object pointer when switching to/from fullscreen. 2011-01-01 19:48:14 +00:00
373524815a Bugfix #25445
CTRL+R loopcut now shows header print with instructions.
User report was that Blender was freezing :)
2011-01-01 17:52:06 +00:00
21eb65c450 For non-gnu compilers, the __func__ doesn't exist.
Fix for commit of 2 hours ago.
2011-01-01 15:49:25 +00:00
fd7152b839 Bugfix, IRC report
Floor constraint didn't work: the defines for the enums were using
the wrong ones, the right ones are not logical... but code and dna
and old files assume these. Now it works :)
2011-01-01 15:28:21 +00:00
d7c51aa3eb Bugfix #25437
Crash in Bezier animation (inserting keys on control points in
curve object). The animation rna paths were not fixed after an
editmode session, which got fixed 2 weeks ago, but for all older
binaries the issue can still pop up.

The crash happened because the RNA array-itterator was not doing
a boundary check, even whilst the array size was passed on to the
itterator callbacks. With rna then writing far outside of valid
memory, very bad and unpredictable corruptions happen.

I've added a range check now, and a decent print to denote the
issue. An assert quit is useless, since a tab-tab on curve objects
will fix the channels nicely.

Example of warning print:
Array itterator out of range: Spline_bezier_points_lookup_int (index 30 range 2)
2011-01-01 13:49:22 +00:00
7040c89af0 BVH Importing native order eulers was broken, simplify conversion between rotation orders. 2011-01-01 13:20:35 +00:00
e1f6dc5f73 bvh export
- write compatible eulers (no jumping as eulers change).
- write FPS.
- correct poll function incase bvh export is called without an armature.
2011-01-01 10:38:28 +00:00
f932371d1e added bvh export operator & menu item, now user accessible. 2011-01-01 09:44:13 +00:00
631745ab9b bvh export now works correctly with matrix multiplications and rad -> deg. 2011-01-01 08:57:09 +00:00
e98559fc12 pep8 cleanup 2011-01-01 08:44:17 +00:00
48921a4fa1 initial 2.5x port, still need to fix up matrix multiplication orders. 2011-01-01 08:35:38 +00:00
a1b1ac5781 committing 2.4x bvh exporter, updating to 2.5x. 2011-01-01 07:26:02 +00:00
7f3fe8a2df pep8 cleanup 2011-01-01 07:20:34 +00:00
2840e7b764 == Sequencer ==
Made anim_start / anim_endofs editable again within UI.
2010-12-31 22:44:17 +00:00
c169ccc711 Silence more compiler warnings. 2010-12-31 20:01:38 +00:00
91f0e13686 update UI introspect function & man page 2010-12-31 15:09:05 +00:00
803e9a2908 Bugfix #25427
Serious *bad* crash in undo introduced by commit Janne dec 21st.

Time window now stores some kind of cache for fluids/cloth, but
it's pointing (in SpaceTime) to data inside Objects. (Not ID).

That's really not allowed... this commit fixes crashes but the
cache code really needs to be redesigned. I'm also afraid this
crash is going to frustrate everyone using physics...
2010-12-31 12:37:30 +00:00
683694b520 Fix crash on load with a particular startup.blend, don't know how to redo
creating it, but this should be set to NULL on read.
2010-12-31 11:55:11 +00:00
c68e3913ed fix [#25429] Armature modifier and inverted vertex group
- the invert flag was only being used for multi-modifier, but there is no reason not to use this in normal cases as well.
- Armature modifier RNA name 'vertex_group' was incorrectly named 'vertex_group_multi_modifier' (own fault), confusion was caused by 'invert_vertex_group_multi_modifier' which was correct.
2010-12-31 11:51:00 +00:00
f0b0cce7bd Fixing a crash on exit when using the Blenderplayer on win32. When free_blender() was freeing main, main was garbage since the blend file data was already freed. So, I just replaced free_blender) with IMB_exit() and free_nodesystem(). Using free_blender() worked when I was in Linux running tests. That or I'm just gong crazy. ;) 2010-12-31 10:56:06 +00:00
23e5b79ced armature recalc roll now works properly with mirror enabled. 2010-12-31 10:42:31 +00:00
ce863a9fdc alternative fix [#25178] Switch Direction operator for bones doesn't update mirrored bones when X-Axis Mirror is enabled
- only temporarily adjust the selection, then de-select.
- fix applies to bone merge too.
2010-12-31 10:24:40 +00:00
e9ade5adae revert a small change from Ton's commit from r33637.
Having edit operations select the mirrored bones means you cant so easily continue editing on one side of the armature.
This is also inconsistent with other mirror editing operations in armature and mesh modes which don't adjust selection like this.
2010-12-31 06:24:52 +00:00
cdefce51f5 update python api with changes from Joshua's commit r33917. translate reports into python errors. 2010-12-31 05:40:30 +00:00
ae51e1c683 reverting part of Ton's commit r33911.
The bug was 'write_still' was incorrectly being initialized to 'view_context'.

'write_still' should always write an image, so failing silently here is bad behavior.
Also, opengl render and internal render engine operator should use this option the same way.
2010-12-31 04:48:56 +00:00
6fdfa97edb CMake: use blender_include_dirs("${OPENGL_INCLUDE_DIR}") rather then blender_include_dirs(${OPENGL_INCLUDE_DIR})
Apparently this is needed for MSVC in some cases, reported by Tamito Kajiyama r33895.
2010-12-31 04:29:11 +00:00
5593436652 Continue from my commit r33952, which disallowed floats to be wrapped as ints.
this missed some cases, now also disallow ints to be wrapped as floats.

This commit also exposed a number of cases where ints/floats were incorrectly wrapped.
Bugs like [#25416] wont slip through the cracks anymore.
2010-12-31 04:12:20 +00:00
a840643993 Bugfix [#25414] Entering a newline before a : still indents it
Fixed by patch attached by submitter. Cheers Jacob F (racoon)!
<quote>
If you write something like...

def do_something:

...and press return it makes the new line with a tab which is good,
but if you want to move the def line down to make room above it by
pressing return while your caret is at the start of the line it
indents the new line which has the def statement on it.

Attached patch just checks if it's checking for a colon after the
caret and returns if it is.
</quote>
2010-12-31 04:09:15 +00:00
dfffad69a9 Bugfix [#25420] Sequencer View Zoom operator hidden
"Numpad 1" shortcut to set preview view zoom to 1:1 (i.e. 100%) did
not exist in View menu. While investigating this, I found that the
operator was missing a description/tooltip, so added one too.
2010-12-31 03:54:28 +00:00
d4ea9eb9e7 Bugfix [#25415] Circle Selection does not work on bones in Pose mode
Clobbered together some new code to do this based on the code for Edit
Bone circle select as this case doesn't seem to have been implemented
yet.

NOTE: the code in view3d_select.c needs some urgent love and tidying
up (like a room full of flaking paint).
2010-12-31 03:35:34 +00:00
7703633762 Bugfix for [#25416] Precision in glare node doesn't match display. 2010-12-30 21:46:09 +00:00
f3e623f497 Bugfix #25407
Lamp shadows for offscreen render (opengl anim) had to be remade
to cope with animated objects. Fix proved by Alexander Kuznetsov
in the tracker log. Thanks!
2010-12-30 14:47:40 +00:00
f09d7912f8 Porting URL fixes for Release Logs from Tag to Trunk. 2010-12-30 13:02:48 +00:00
46feccfaea Fix for bug #25367 didn't ensure the problem wasn't happening elsewhere.
add a check in makesrna, found FollowPathConstraint.offset was a float wrapped as an int.
2010-12-30 12:50:44 +00:00
9733e5f76f revert part of Tons commit r33884.
- rather then use unlink="None", just don't pass unlink as a keyword. This is more pythonic.
- added an RNA flag for properties which cant be unlinked by setting to None.
2010-12-30 12:22:28 +00:00
e68a9ab95f Some small cosmetic fixes for readme.html. If it still gets into release, fine, otherwise no problem. 2010-12-30 11:35:56 +00:00
9fa2f9ffb6 Doh! 2010-12-30 05:47:34 +00:00
b67692a130 Various pedantic fixes to satisfy compilers. 2010-12-30 05:41:17 +00:00
02038dcf57 SVN maintenance. 2010-12-29 19:50:08 +00:00
4f7f820092 Part two of 2.56 beta, VERSION for make and splash itself.
(prvicon png was already commited as datatoc)
2010-12-29 19:05:58 +00:00
4819c9bdfa Part one of 2.56-beta release commit
(Splash picked by Durian team to honour team Argentina!)
2010-12-29 19:05:00 +00:00
a15f65776f netrender
Bugfix for job cancellation (reported by Carsten in email)
Ended up recoding part of the communication pipe (use json more consistently)
Fix bpy data modifications where it shouldn't happen (as a bonus, thumbnailing is now done out of process)
2010-12-29 18:34:43 +00:00
7f3c7eee67 Bugfix #25404
Frame Mapping (map old, map new) didn't set the the framelen
variable. Note that this feature is half-working, and on the
to. Might be removed/replaced with something better.
2010-12-29 18:21:57 +00:00
d36f15df03 DopeSheet Drawing Tweak:
Keyframes for locked channels are now shown faintly so that it is
possible to easily distinguish between keyframes for locked channels
and unlocked channels. Hopefully this solves the problem where you
have some keyframes selected, and try to move them but forget that
those channels are locked (without any feedback other than a single
icon).

Thanks for pointing out this problem Ronan Zeegers!
2010-12-29 12:52:06 +00:00
f22a3c16b1 Silencing some compiler warnings (gcc) 2010-12-29 12:27:03 +00:00
32b23b2b82 Bugfix [#24163] (PART 2) Unable to animate INSIDE a group node in the
compositor

Now ungrouping grouped-nodes copies the animation back to the main
nodetree. This means that it is now possible to successfully roundtrip
group/un-group nodes and their animation data.

---

This should also be done for the Separate Armature operator... hmm...
2010-12-29 12:18:59 +00:00
92172b779e Bugfix [#24163] Unable to animate INSIDE a group node in the
compositor

This commit fixes the original bug reported here by adding some
methods to move the relevant F-Curves (and drivers) over to the new
Node-Tree's (i.e. group-node) AnimData. Animated nodes which
subsequently get grouped will still be able to animate as a result of
this commit.

TODO's:
- Ungrouping now will not yet merge the animation back (or at least
copy it)
- Buttons for nodes freshly grouped do not correctly show animated
status indicators for some reason, yet normal animation does
2010-12-29 11:51:53 +00:00
c802e21dbb Bugfix #25397
Loading a vector font (.ttf) didn't have option for Relative Path
in the file window. Now it does, and it sets it to the default.

Todo note: the actual path is not visible in the UI yet, nor does
outliner RNA view allow to edit path.
2010-12-29 11:34:02 +00:00
7115a8d200 Consistency cleanups for AnimData stuff:
Some AnimData looping functions were not updated to take into account
the addition of AnimData for some additional datatypes (i.e. meshes
and lattices) as well as the changes to make nested nodetrees (i.e.
for Material and Texture nodes).
2010-12-29 05:20:19 +00:00
8c4a93110e Bugfix #21825
Auto-IK: applying back the IK transform on bones fails for constrainted 
bones themselves. This would require the post-transform of IK to be
converted to a pre-transform for the constraint. That's too much of
a headache for bugfixing days.

To keep the autoIK feature work it now stops IK chains at constrainted
bones. Added todo item for a matrix wizzard to fix this one day.

(What would be really cool is a matrix-api for armature to easily 
get all the required pre- and post transforms and apply. There's a lot
of duplicate exception handling for hinge bones for example.)
2010-12-28 17:03:09 +00:00
98ec317d2b Bugfix #25395
Mesh "Add grid" was quite broken:
- it added an edge to a previous (not selected) vertex
- it ignored cursor location
- and it didn't use 'align to view'

Now it does behave :)
2010-12-28 16:02:47 +00:00
Nathan Letwory
4eb806b0a4 Fix [#24630] alt+shift+LMB dragging does not work
Reported by Nils Austa

There was double handling of modifier keys. With my autumn work on the modifier keys I had moved state checks for
modifier keys into convertKey(), but left the call to handleModifierKeys. That caused problems with proper
modifier key handling in the entire key handling code of GHOST.
2010-12-28 13:03:38 +00:00
875a7288ca Bugfix, irc report.
UI name buttons with Search callback show red when item couldn't be
found. The check was too simple though, since the searches also find
partial matches. This caused KeyingSet browse to show red for "RotScale".

Now 10 matches are stored, and each match is being checked. Still a
bit weak for cases with more than 10 matches, but in that case it
won't show red-alert.
2010-12-28 11:56:18 +00:00
46891eec31 TimeLine UI:
Reshuffling order of "sync" and "Auto-Keying" buttons so that they are
grouped more appropriately. Hopefully this isn't too much of a muscle-
memory breaker...
2010-12-28 11:52:35 +00:00
7484d5b743 - Typo fixes
- Visual Location Keying Set was still using the old-style flag
defines
2010-12-28 11:50:10 +00:00
d0074169fb Bugfix: creating new 3d views in Blender now uses same defaults
as startup blend: showing solid + outline selection.

(It was wire, without outline select... confused people)
2010-12-28 11:01:26 +00:00
3c96b00500 Bugreport, IRC
Compositor: "Read & Compo Full Sample Buffers" option stopped after
1 pass; the break callback was returning '1' falsely.

Also made it show "wait cursor" again, since it doesn't run in 
thread nor updates UI while compositing buffers. Check console for
progress for now.
2010-12-28 10:39:27 +00:00
d44436ebf2 Assorted commenting, formatting, and compiler warning fixes for
keyframe pasting code
2010-12-28 06:24:01 +00:00
26104c7611 - Silencing some gcc warnings (yay! I can finally use this setup
again)
- Graph Editor "Active Keyframe" panel now displays more descriptive
error messages. In particular, hopefully this helps to alert users of
the default generator modifier for Driver F-Curves
- The first F-Modifier added to a list is now set to be active one for
that list.
2010-12-28 06:18:56 +00:00
71da1e96d1 Drivers Code Cleanups and UI Tweaks:
- Adding drivers from the UI (not from py-scripts though) will now
automatically add a "Transform Channel" driver variable to the newly
created drivers. This makes setting up drivers a bit more convenient
for the most commonly used case.

- Drivers now report their errors using the Reports system instead of
writing these directly to the console.

- Clarified some comments to be more insightful about the "why's" of
some design decisions, and related formatting/cleanup tweaks
- Reduced scope of "path" vars to just the scope they're required in

- Removed some unused defines from a failed experiment in the original
Keying Sets code ("templates" and "template flags") which was
superseeded by the more flexible + nicer "Builtin KeyingSets"
2010-12-28 05:45:15 +00:00
24ae6f8c91 stubs update for multitex_ext_safe 2010-12-27 21:58:07 +00:00
39919c7856 netrender
adjust dependency calculations for cache files of smoke simulations (no more separate paths for low and high). That was changed a while ago in the api, just didn't update yet.
2010-12-27 19:48:45 +00:00
b2be78c0cc Bugfix #25392
Compositor: Texture node didn't use texture-nodes itself.
Now composites initialize texture nodes correctly.

Also reviewed the fix for crashing texture nodes for displace.
It appears texture nodes also are used for sculpt/paint 
brushes, in these cases it can be allowed again. But, don't
do this during rendering for now!
2010-12-27 19:26:38 +00:00
1a8cc0a8f0 Small fixes:
- OpenGL still render failed when output format was set to Movie.
  Now it just doesn't save a file and renders anyway.
- Bone heat weight was missing 'wait cursor'.
- Waitcursor for Mac Cocoa is back! Made all OS's use the same
  nice hourglass cursor.

(Note: this violates Mac UI guidelines, we should rely on the 
spinning wheel of death instead. Highly disputable that.)
2010-12-27 18:54:43 +00:00
595525067e [#25210] Netrender failed and produce ghost slaves
Error when prefixing relative path (probably copy paste error)
2010-12-27 18:53:34 +00:00
b1b22e928d Usability fix:
OpenGL render now first opens render window.
It used to render first, save file, and then open window to show result.
2010-12-27 18:00:35 +00:00
Nathan Letwory
b9a6331781 By default install to the user profile instead of Program Files. This because right now the installer
runs in user mode, not elevated to admin. Otherwise users can't install to the default which used to
be Program Files, which causes more problems than necessary. Although unconventional location, probably
currently a better solution.

Network admins etc. can override install location on command-line. NSIS docs tell how.
2010-12-27 12:42:51 +00:00
Nathan Letwory
bf1eff43cf Run installer with user level permission by default. 2010-12-27 12:20:56 +00:00
56453a4361 Fix for own commit 24156:
Normal Map bool and the normal_space menu are only used for material based textures, not for textures used by lamp/world etc. Accidentally ported this over from 2.49, where these buttons are drawn even they don't work in that context.
2010-12-27 12:12:43 +00:00
9118614d8e Fix for blender crashing when starting playback with audio without being able to open the audio file. 2010-12-27 11:32:43 +00:00
2ff790d0bd Removing the not-working test "Submit description" from RMB
menu on buttons.
2010-12-27 11:05:01 +00:00
Nathan Letwory
de55b7897c Workaround for [#25279] Shift-Numpad combinations fail to align view to selected.
On Windows shift+numpad triggers extra ctrl event, making this fail. For now, use Alt as modifier on Windows (other platforms remain with Shift).
2010-12-27 09:56:05 +00:00
b72bffd70c Bug report #25384
Node editor
Some nodes - when muted - didn't draw a red line to indicate
a pass-on action. Stil, the node then is muted and either passes
on a buffer of same type, or just black.

To more clearly indicate muting, it now draws the header in a 
reddish blended color too.
2010-12-27 09:43:22 +00:00
Nathan Letwory
71eb4a2312 Work around cmake error on Windows. 2010-12-27 09:33:32 +00:00
Nathan Letwory
6278cda106 Compiling and linking blenderplayer statically now works too. This brings it in line with blender linking line.
Small patch by Sergey Sharybin
2010-12-27 09:01:57 +00:00
c4a56fda6d Bugfix #24966
Hair render: using strand "Blender Unit" size didn't correctly
clip for larger/wider strands. Now code clips strands based
on the maximum width.

Also found bad code for using clipping flags, which was mixed up,
and probably caused hair strands to be missing in cases.
2010-12-26 17:47:17 +00:00
31eadb358d Fix for IRC reported bug from lmg:
VBO enabled, GLSL shading and bevel modifier leads to crash when entering edit mode

Bevel modifier doe not support remapping still, so added check about original index
in cdDM_drawFacesTex_common. Now it works like VBO-less drawing for that special case.
2010-12-26 13:01:02 +00:00
b281f105c9 Bugfix [#25383] Drag&Drop .py file into text editor don't load it. 2010-12-26 10:40:50 +00:00
d0bdd8cd64 Bugfix [#25380] Recorded bone keyframes do not play back both in the
action editor and the NLA editor

This commit fixes the situation where if a NLA Track was on 'solo'
mode and then deleted, NLA evaluation (including Active Action) would
stop working as a flag wasn't getting cleared.
2010-12-26 10:36:02 +00:00
858ae19e4e Fix #25375: Vertical numbers in F-Curve Editor out-of-alignment with grid
Issue caused because previously sliders used a separate mask and now they're
drawing inside of region.

Thanks to AlexKu for point and Ton for checking :)
2010-12-26 10:34:09 +00:00
b89816d94f Bugfix #25366
Keyframe "Insert Visual" ignored new constraint type "Transform Like".
2010-12-24 16:45:04 +00:00
77d08370cf Bugfix #25371
Sculpt: brush type "Grab" with option "Frontface only" was flipping
back and forth when grabbing outside of original brush area.

Reason: it was calling a function that used deformed coordinates
for getting normal, clipped by brush area. Now it uses original
coordinates, so it always finds normal.

Nicholas can determine better if tag "cache->original" should be
set as default for this brush type, this far I don't dare to go :)
2010-12-24 15:30:13 +00:00
490c0758cb Bugfix #25357
Having 2 windows open, rendering to image editor, activate other
window and press F11 -> UI went haywire. Simple fix prevents
render output to be closed in this case.
2010-12-24 13:24:26 +00:00
8827079841 Bugfix: (Mario Kishalmi patch)
Edge slide bug: when multiple vertical subdivisions exist, the UVs for
a slide or loopcut-slide operation were wrong.
2010-12-24 12:50:07 +00:00
f1a545c4a5 Bugfix #25367
Several Softbody int variables were accidentally RNA-ified as
float values. Didn't cause harm, but UI worked weird then, 
cutting off the precision.
2010-12-24 11:27:34 +00:00
b61adec1fd Bugfix #25365
Property buttons: the "ID template" allowed to unlink data from object,
like Mesh or Curve etc, which is not supported. Button now is hidden.
Thanks Dan Eicher for patch.

Also: improved tooltip for 'data browse'. It was generic, now it gives
specific per-type information.
2010-12-24 10:15:57 +00:00
4d0c10d5ca presets for operators, re-using same preset system as render, cloth etc use.
- operators need to enable the option OPTYPE_PRESET or 'PRESET' in python.
- hidden properties are not written.
- currently this only works in the file selector (enabled for FBX/OBJ export)
- currently the menu label doesnt change when presets are selected, this is a TODO, not so simple since the UI is defined in C and the label in python.
- presets save in "scripts/presets/operators/*id*/*.py"
2010-12-24 07:46:40 +00:00
c0339029c7 is_hidden property for rna introspection 2010-12-24 07:30:15 +00:00
80e85c10be bugfix [#25364] Export to X3D generates objects with black color
was dividing color by 255 when it was already from 0-1.
also use slicing for getting tuples from vectors & colors.
2010-12-24 04:27:21 +00:00
577437488e use slicing for exporters for some speedup, no functional change.
3ds also uses non tuple __slots__ and had unused default values for some classes.
2010-12-24 04:24:33 +00:00
ce36f9a189 fix for exporting OBJ, materials when no world was set. also use slicing to get tuples. 2010-12-24 04:21:05 +00:00
2dcfa5acf9 return typle for mathutils slice's.
The main advantage with this is that its close to twice as fast to do 'vertex.co[:]' then 'tuple(vertex.co)', this is common for writing a vertex array.
the correct python behavior in this case is to return a copy of the original type, however euler and quats don't support different sizes so we cant do so easily.
2010-12-24 03:51:34 +00:00
47fc52f839 Customdata mask recode caused crashes, sloppy work here, but probably
caused by Campbell using too much Python. In C code you really need
{ and } for multiline if's. :)
2010-12-23 17:47:06 +00:00
f543fe1500 Bugfix #25341
Child-of constraint issue: on adding, it wasn't checking owner
correctly for Bones, resulting in a constraint working in wrong
space; it looked as if transform was applied double when moving
the object. Only adding via Py API went wrong btw.

Also found a silly check for drawing constraints, which caused
constraint initialization to happen for every object on every
redraw!

Implementation note: con->flag CONSTRAINT_SPACEONCE was only used
for child-of constraints in Bones, so I've patched it on file
reading to always set the flag. Marked with XXX, so it can be
removed one day. Now at least things get corrected well for
imported armatures.
2010-12-23 13:16:56 +00:00
1ea491d615 Bug #25354
In some cases, a LMB-drag was drawing a stippled line. Leftover of 
WIP code for support of gestures in Blender. 
Disabled drawing for now, until gestures is back in control.
2010-12-23 10:34:37 +00:00
b1d3854095 Make FBX export respect use_deform bone option 2010-12-23 09:42:00 +00:00
b4f61f0733 remove View3D.customdata_mask, since its stored in the scene now there is no need for each view to store every views combine data mask. 2010-12-23 04:26:53 +00:00
c046ae14be Fix for multiple modifier stack calculations per frame.
Since 2.5x blender has been using CD_MASK_BAREMESH for updating objects since object_handle_update() no longer has access to G.curscreen to calculate the mask from viewports.

The problem with this is after an initial calculation, CD_MASK_MTFACE may be required on draw, so it would recalculate the modifier stack multiple times per frame.
One case which caused this is armature animated mesh with texface in a dupligroup.

Fix this by having customdata_mask member in the scene, this isn't great design but at least fixes the bug and only changes a few files.
2010-12-23 04:16:31 +00:00
86b89af5dd use ICON_NULL define rather then 0, makes UI calls less confusing. (no functional change)
eg: uiItemR(row, &dvar_ptr, "type", 0, "", 0); -> uiItemR(row, &dvar_ptr, "type", 0, "", ICON_NULL);
2010-12-23 02:43:40 +00:00
f0951e86ee fix for PyC_LineSpit() finding the current line of the frame's code object. 2010-12-23 00:19:34 +00:00
194c23db0d fix [#25353] X3D Export generates AttributeError: 'NoneType' object has no attribute 'texture' 2010-12-22 23:16:45 +00:00
5e382eb8e5 rename blenderlib to blender_add_lib 2010-12-22 23:09:30 +00:00
af7b8883de remove bullet CMakeLists.txt files, blender uses its own. 2010-12-22 22:54:48 +00:00
29799bf09c Compact -I paths in makefiles for more readble files/output.
Also some white space cleaning and removal of redundant parameter.
2010-12-22 22:15:20 +00:00
54343b79e6 remove reload() from builtins since python3 no longer uses this.
use imp.reload now.

Should use import hooks but for now replace imp.reload with our own reload as the builtin reload was replaced before.
2010-12-22 21:39:48 +00:00
2811707b92 Fixed stupid typo with detecting corners of source mdisp.
Haven't noticed before because destination is a copy of source for now,
so there would be always the same count of corners.
2010-12-22 21:38:06 +00:00
dcd8c516dd Bugfix #25348
EdgeSlide: cancel didn't refresh UVs in mesh for cancelled 
state. Also loopcut suffered this.
2010-12-22 19:12:00 +00:00
3a81eca027 Report #25350
Loopcut check for deformed meshes was far too wide, it even disabled
loopcut on subsurfs.
Now added a check for armature/lattice only, and only give a warning,
not a return from the tool.
2010-12-22 18:46:54 +00:00
009eb42c0e == text editor templates ==
- adding template of a add_object addon from Florian Meyer (testscreenings)
- this template is using the new add_utils module in bf-extensions (also from Florian)
2010-12-22 18:43:21 +00:00
0db7bdf00a IRC fix: removing material slot from Object didn't refresh 3D correct.
Missing ID tag update.
2010-12-22 17:38:08 +00:00
ff7d106da4 Related to previous commit: Custom shapes for Bones now increase user
counter for linked objects.
2010-12-22 16:44:28 +00:00
f4e5addf93 Bug fix, IRC, patch provided by Dan Eicher
Custom bone shape link/unlink now respects ID user counting.
2010-12-22 16:33:13 +00:00
01bb474d4f Audio: Function to get channel count of a sound, for [#25062] Sound Actuator - Positional Audio. 2010-12-22 16:07:57 +00:00
Dalai Felinto
d729c0cff7 svn merge -r 33849:33848 [overcommitted due to the server problems we had early today] 2010-12-22 15:10:42 +00:00
51a7995269 Bugfix, IRC, textures or displacement on metaballs didnt work.
Commit 32361 from Campbell made quite a silly optimize mistake...

ver->orco= orco+=3;

Which is of course not:

ver->orco= orco; orco+=3;

Triple tsk!
2010-12-22 14:43:24 +00:00
Dalai Felinto
eeac25c9d0 Complement of commit 33789: Fix for [#25175] bge.logic.mouse.position[1] wrong when using autostart
Porting the fix when Fullscreen flag is on (~ scene.gm->fullscreen)
I still see some issues with that, a difference between width/height. To be addressed later.
2010-12-22 14:21:46 +00:00
Dalai Felinto
c67dac4274 Complement of commit 33789: Fix for [#25175] bge.logic.mouse.position[1] wrong when using autostart
Porting the fix when Fullscreen flag is on (~ scene.gm->fullscreen)
I still see some issues with that, a difference between width/height. To be addressed later.
2010-12-22 14:20:22 +00:00
3d58d17442 hide the play-reversed button if using JACK + A/V sync
(jack doesn't support reversed playback)

hey team, I'm the new guy.
proud to be on board! =)
2010-12-22 11:37:56 +00:00
f08fb046ce Audio:
* Improve Jack Transport responsiveness.
* Added minor error checking to OpenAL.
2010-12-22 10:51:34 +00:00
088f35787f bugfix [#25252] X3D Export does not specify ImageTexture to go with provided TextureCoordinate data
x3d material support is primitive but at least export first image texture found, similar to how texface is treated at the moment.
2010-12-22 10:44:31 +00:00
9d756fb761 Fix for [#25339] Rendering Fluid's Float Particals cause crash when utilizng raytracing
* Fluidsim particles hadn't really been working at all for who knows how long, even in viewport!
2010-12-22 09:30:13 +00:00
2dc2f50a6e bugfix [#25335] crash with file, console told me to report! svn 33836
view rotate precision was lost over time, make view3d rotate normalize rv3d->viewquat.

note, this no longer crashes blender, just prints.
also commented some RegionView3D struct members.
2010-12-22 02:28:06 +00:00
97d8e8bf42 bugfix [#25332] X3D export fails to export complete file 2010-12-22 00:30:22 +00:00
803bf8326d Better info text for particle edit
* Response to [#25314] Baked Particles point cache can not be editing in Particle Mode if Disk Cache option is enabled.
2010-12-21 20:25:37 +00:00
6a79de7698 Fix for [#25325] Timeline doesn't show status of baked psys until frame is advanced
* Timeline didn't listen to file read notifier, so the pointcache frames indicator didn't get updated.
* Also added listens to particle & modifier (cloth, sb & smoke) notifiers as changes that cleared a pointcache weren't shown directly in the timeline either.
* The timeline display was also always one frame behind the actual state, since the notifiers are handled before the actual dynamics are calculated.
** This is now fixed too, by creating the actual drawn data always at drawtime.
2010-12-21 20:18:43 +00:00
aeba7032e6 Bugfix #25330
3D Window: Snap to cursor or grid, didn't respect the 'restrict location'
options for objects or bones.
2010-12-21 18:55:49 +00:00
fae8dc5a73 Error/Warning report flipping.
An operator Error throws up a menu, a Warning only a flashy header print.
In mesh editmode the menus for simple failures got very annoying, like
"Already a face" for Fkey on a face.

Proposal is to use warning for contextual failures, like:
- wrong selection
- unsupported combination
- wrong modes

And use errors for cases you really need user attention, for example when
issues are invisble or potentially damaging work.
- Memory failures
- Files not found

List can grow in future :) let's test this for mesh now.
I'll tackle this for other ops later after review.

(Also changed: loopcut disabled when editmode shows deformed result)
2010-12-21 15:10:09 +00:00
b0f87a1746 rename addlisttolist() to BLI_movelisttolist()
name was misleading because the list items were removed from the source list.
(no functional changes)
2010-12-21 14:49:34 +00:00
3d1896bc6d Macro Operators now pass on reports to the Mother Op!
(errors for macros were not shown)
2010-12-21 14:08:58 +00:00
7006491451 bugfix [#24469] Cannot add keyframes on custom properties in IDPropertyGroups 2010-12-21 11:40:12 +00:00
Nathan Letwory
c5077e1ede Fix [#24359] Collada: end bone zero size, mysterious extra empty
Reported by Thomas Larsson
Fix by Jeroen Bakker

Fix max length of leaf bone and remove empty.
2010-12-21 10:43:47 +00:00
Nathan Letwory
044e31b89c Fix [#25319] COLLADA import segfaults on maya model
Reported by Michael Williamson
Fixed by Jeroen Bakker

Wrong UV index was being used.
2010-12-21 09:41:02 +00:00
48cda2e08e Plugging up some memory leaks in the Blenderplayer that I found with valgrind 2010-12-21 06:58:44 +00:00
9d289c602d better make_quiet.sh filter with threaded builds. 2010-12-21 04:55:46 +00:00
0d9ead00f8 fix for cmake flag detection, was not caching the resulting variable so the test ran each time.
also cache SSE, SSE2 checks.
2010-12-21 03:32:51 +00:00
Nathan Letwory
a8febab31b Workaround for blenderplayer not linking on linux with scons.
Maybe as a next big, uncool project would be: solve bad level calls.
2010-12-21 00:21:42 +00:00
a9ba96896a modified fix for commits r33811, 33812.
- SSS Presets were not working on pinned materials.
- added ability for save-presets to define variables to stop them becoming too verbose.
- remove object.active_node_material
2010-12-20 23:26:29 +00:00
4530b4984c use uppercase for axis chars, used in BLI_math and other parts of blender. 2010-12-20 23:21:33 +00:00
9cdf00897a Fix #25315: Curve points keyframe changes made in edit mode get lost
ED_curve_updateAnimPaths now updates fcurves from animation data rather than
from local copy of curves: nurb and point index from keyIndex data gets
updated in this function and for correct handling undo stuff copy of
fcurves is stored in UndoCurve.

Additional changes:
- Revert of rev33640 and more proper fix: do not copy remained
  spline-related rna fcurves after renaming pathes but all the rest
  fcurves woulddbe copied back to animation data
- Refresh graph and dopesheet editor after updating animation data
2010-12-20 19:47:16 +00:00
9f298c6e47 Bugfix #25308
Border or other selection tools didn't redraw action editor, when
option "only show selected" was set. Was missing area tagging.
2010-12-20 19:09:22 +00:00
7e624b81a4 Small UI fix
Image texture "repeat" options now greay out when not active.
Thanks Mario Kishalmi for the patch :)
2010-12-20 18:57:59 +00:00
d0193b938d Bugfix #25312
"Make Local" option "Objects and Data" made materials get
lost on save, the tagging was incorrect. Now it makes 
Materials local too.

Implementation note: the code is new (not 2.4) so it misses
some of the hairy goodies we had. It's something for another
time to really make this reliably work.
2010-12-20 18:54:32 +00:00
8017a9513b Bugfix, own collection:
File Window draw error:
On start Blender in smaller sized window, a scalled down screen
causes the File Window main area to draw too high, clipping off
half of the top line. This case (scroll horizontal only) is not
handled as view2d type.
2010-12-20 18:29:32 +00:00
28db3053fd Fix for last own commit: missed mode check in addvert_Nurb, so
blender was crashing when user tries to extrude (with e-button)
when nothing was selected.
2010-12-20 17:42:17 +00:00
fb586da690 Bugfix #25313
Outliner "show active" now also works for elements hidden in
closed items. (Coordinates were not set)
2010-12-20 15:39:00 +00:00
c0882efc8e Bugfix: new strict code for UI_make_axis_color() caused constraint
lines in Transform to not draw.
2010-12-20 13:57:52 +00:00
63b9d0bcaa 3D ortho view: the axes lines of grid had wrong color for X.
Thanks Mario Kishalmi for the report :)
2010-12-20 13:32:26 +00:00
291a66d212 Bugfix: material SSS presets now copy correctly to the displayed
material (in case it has nodes)
2010-12-20 13:03:03 +00:00
6b1258f5b8 Bugfix #25301
Material Node trees:
SSS wasn't displaying in Nodes.

Implementation notes:
- Currently copying local data for preview render, only copies
  the base material. Node materials are re-used.
- This causes data to be in 2 "main" databases... complex.
- To make it work for preview, I had to add another loop in the
  SSS code that checks the original Main dbase. That's marked
  as warning in code to be fixed up.

Another bug:
- Material properties "SSS presets" copied settings to the
  active material, not to the displayed one. Added RNA call 
  to retrieve this from Objects.

(Next commit will fix preset scripts)
2010-12-20 13:02:33 +00:00
88b2955564 Bugfix #25307
Node shaders + textures, showing in Texture properties, with option
"show both previews" had bad ID checking.
2010-12-20 11:33:52 +00:00
71202e26ff simple make wrapper to give quiet output. (more like nan-makefiles) 2010-12-20 11:21:29 +00:00
97197b54cf Bugfix #25309
Code cleanup to allow switching active output nodes in Compositor
made shader nodes output not set correctly.

Now you can have multiple output nodes in shaders too, and switch
on click-activate.
2010-12-20 11:08:29 +00:00
57cc3a5f6d Misleading defaults for smoke flow particle system:
* Show unborn was on by default, so smoke got emitted from all particles regardless of their birth time, not a good default in my opinion.
* What made things worse was that particles weren't shown in viewport, so you didn't even know the particles were considered alive from the very first frame! (Not rendering is a good default, but they should still be visible in viewport!)
2010-12-20 10:23:23 +00:00
a6f50e48aa fix [#25313] Outliner View Active only works once icon has been shown in view.
also disable UNDO and REGISTER flags for OUTLINER_OT_show_active() since its just scrolling the view.
2010-12-20 09:51:18 +00:00
2888016fb9 higher precision for wright & radius button. 2010-12-20 09:46:30 +00:00
09debd69ba change the resolution for new surfaces to 4x4, since 12x12 used to be the total number of subdivisions along the U/V of the nurbs surface but now its multiplied by the number of segments. 2010-12-20 07:45:24 +00:00
96974a9575 bugfix [#25310] Twice applied modifier with Convert to mesh with several multi-user objects 2010-12-20 07:21:08 +00:00
8e80ada09a bugfix [#25238] Render image window edits UV's 2010-12-20 05:26:25 +00:00
3bed4cbf2b fix [#25283] Edge length display difficult to read
- made theme colors for mesh edge len & face angle/area display.
- use %g rather then %f for float display, trims unneeded zeros.
- store cached 2d and 3d text color as bytes rather then floats, compare when drawing to avoid setting the context.
- use unsigned char for more color functions, avoids casting to glColorubv().
2010-12-20 03:59:22 +00:00
Nathan Letwory
17f37dcecc Apply [#25297] Fix for [#23765]
Bug reported by alarionfirn
Patch submitted by Jeroen Bakker

It took the read the N+N of the uv-layer, it should be the Nth uv layer.
2010-12-19 20:40:52 +00:00
Nathan Letwory
fad7121ca3 Apply [#25296] Fix for [#24636]
Bug reported by Dominique Lorre
Fix submitted by Jeroen Bakker

When importing COLLADA files, the name of a custom data layer can be longer than 32 bytes. Make sure only 32 bytes are copied.
2010-12-19 20:23:30 +00:00
b8e47fd160 Bugfix #25301
Preview render for node shaders broke, caused by localizing 
materials last week, to prevent thread crashes. Fixed now.
Also added a temp fix to draw color-management corrected
node previews default. Will follow scene setting tomorrow.

Also: SSS in nodes doesn't render yet. Was issue in 2.4 too...
2010-12-19 20:12:12 +00:00
7899765836 Made ctrl-point curve extruding more consistent with mesh edit mode:
when nothing is selected but active spline is set or when "middle"
control point is selected new spline would be created.

Nothing wull happen when there is no selection and no active spline
due to it's unclear which kind of spline should be added.
2010-12-19 19:22:17 +00:00
410c807338 Patch from Dan to use id user functions rather then accessing direct. also use warning fix using const for RNA_parameter_set() arg. 2010-12-19 16:34:58 +00:00
da153a509b CMake RelWithDebInfo uses python31.dll, not python31_d.dll 2010-12-19 16:09:24 +00:00
b5e30e58e1 Todo item:
Compositor: if you have multiple Composite-Out nodes, a click will
activate it for use. Just like viewer nodes.
2010-12-19 15:03:27 +00:00
6cdc631d98 Todo item: (Luca report in IRC)
Pulldown and other popup menus: this button type exits on release.
While holding mouse you then can move around, but the highlight of button
didn't disappear if you were outside item. The menu then doesn't close
when you release the mouse.
Now highlight goes on/off on mouse moves to show this better.

Implementation note: menu items are coded similar to regular activate
buttons (like for tools). There's no provision to make highlights go
to the next item while holding mouse in menus. That I rather not mess
with now.
2010-12-19 14:39:36 +00:00
d7c007c4d5 Another single-user case: the ID buttons (browse, name, users),
click on user-number 'make single user' now also makes animation
local.
2010-12-19 14:07:50 +00:00
9685589cf7 Fix for [#25175] bge.logic.mouse.position[1] wrong when using autostart 2010-12-19 13:56:02 +00:00
686420b15d Option "Make Single user" now also makes animations local.
Note that the menu option "Animation" only was working for
Object level animations, so I've changed the many name
accordingly.
2010-12-19 13:50:31 +00:00
f043caf1c1 Py UI fix: options for "Single user" had different names than the operator itself. 2010-12-19 13:48:45 +00:00
c2c71e59ed fix for own error [#25299] custom properties not showing in viedw3d panel
error made when fixing id pinning, for non-properties space.
2010-12-19 13:04:14 +00:00
8dcd210de0 bug [#25292] No undo scale with sculpt mode
applies to project paint too, added with comment.
2010-12-19 12:38:20 +00:00
79bb472720 user report renaming file fails, print the errno error message. 2010-12-19 12:32:33 +00:00
7507a5f959 Bugfix #25288
SSS preview render didn't happy.
Was caused by using a Material copy for preview renders (to prevent
crashing in other cases). There were actually 2 errors:
- material copy should be added to preview-main database
- the render was invoked using wrong main database even!
2010-12-19 11:39:55 +00:00
3bcde46dfa Bugfix [#25298] Nasty group cycle that creates crash blend files is
allowed

Infinite recursion (manisfesting as a crash) occurred when trying to
set the dupli-group setting on an object, when the object is a member
of the group being set. Added a check and warning for this in RNA to
prevent such setups from occurring in future.

Todo:
The warning report is currently only printed to console as I can't
quite remember how to grab reports pointer without context/operator
pointer available.
2010-12-19 10:38:02 +00:00
e53921cf40 Bugfix #25292
In sculpt mode, Object transform still worked, which was:
1) Not undo-able (sculpt undo stack)
2) Clearing the entire sculpt undo stack on operator redo
3) Had keymap conflict for R

Simply added check for this case and return trans operator.
2010-12-19 09:41:41 +00:00
de1bb51b0a another reason to run makesrna needlessly every build is that the makesrna binary is newer then the generated files. 2010-12-19 08:48:15 +00:00
4476e4c75c bugfix [#25289] X3D export generates incorrect direction for SpotLight 2010-12-19 07:40:08 +00:00
73ad13c879 fix for make-dupli-face operator & vector multiplication, tab/space error in last commit. 2010-12-19 07:14:42 +00:00
c26cc0afa1 bugfix [#25290] Align on text gives a traceback
[#25284] Traceback error on "System Info" script

- Align was only working on mesh objects, now operate on all objects, missing boundbox's are treated as single points.
- obj.bound_box was returning all nan's for object types with no boundbox.
- ENUM_FLAG type enums were showing no text when displayed in operator redo panel.
2010-12-19 07:05:29 +00:00
096369e89d [#25278] Ctrl-left click in beizer edit mode with no selection results
in crash.

This commit fixes the crash (missing null check for nu==NULL).

However, there is still a problem here with Curve Ctrl-Click not
behaving the same as Mesh EditMode Ctrl-Click, which adds a new vert
no matter what (i.e. no previous selection required). Then again,
that's a separate "todo" issue, so we can close this report now :)
2010-12-19 01:59:52 +00:00
831684fd8f Fix compilation, obvious typo. 2010-12-19 01:55:07 +00:00
e47ab723a0 Bugfix [#25221] Jump to Next/Prev keyframe doesn't work with
RotoBeizer

The jump to keyframes operator was being a bit too strict with its
checks for where it should check for keyframes.

In this particular case, RotoBezier keyframes were on Curve AnimData,
so the check for Object AnimData would return false, thus overlooking
this possibility. However, it should be safe enough to just open
things up a bit more.
2010-12-19 01:27:32 +00:00
43af26fa41 Bugfix [#25291] Objects that should not have subsurface modifier have
it (eg cameras)

When trying to add a modifier to non-geometry objects, warnings are
now shown instead of just adding some (useless) modifiers that cannot
be removed later.
2010-12-19 01:14:57 +00:00
555427765d Pointcache frame markers in timeline look a bit nicer if they are aligned exactly on frames. 2010-12-18 21:19:55 +00:00
d920bf5072 Mistake in previous own commit, checking the wrong cache frame. 2010-12-18 21:16:37 +00:00
e93a7aa849 FILTER="^\[[ 0123456789][ 0123456789][ 0123456789]\%] \|Linking \(C\|CXX\) static library\|Building \(C\|CXX\) object \|Built target "
Bugfix #25280

Image: sequence option was hardcoded to assume "first frame" was always
picture "001". Made it impossible to have a sequence of images starting
with picture like "000"

Note that by allowing to render a first frame as 000 in Blender, things
mess up a bit here. Things work now as follows:

- Start Frame = 1 : Image 001 on frame 1
- Start Frame = 0 : Image 001 on frame 0
- Start Frame =-1 : Image 000 on frame 0 ;)

This is of course the lack of proper control for image sequences.
Definite something to work on; best idea I have now is a new setting
that defines the Image Number to be "first frame". That way you can
map that number on any Blender frame. Or it makes it more confusing? :)

For the doc department: the proper meaning of "Start Frame" now is:

"The blender frame a sequence starts playing, assuming the sequence
starts with image #1"

Tooltop was fixed accordingly

(Also fixed 'remove doubles' to show more precision in toolbar)
2010-12-18 18:56:21 +00:00
a73e06775f Bug fix: some file browser buttons didn't return filename even though they were supposed to
* It working before was actually a bug that got fixed by ton in r33663.
* Now the property subtype is correct and things work like they should.
2010-12-18 16:52:17 +00:00
b58dbbd51b Extreme makeover of pointcache code:
* Pointcache code was quite ugly looking and complicated, so here are mostly just cosmetic adjustments, but some improved logic also.
* Slight cleanup of pointcache ui too.
* Shouldn't have any functional changes what so ever, so poke me right away if something seems off.
2010-12-18 15:03:31 +00:00
a934116298 Fix for [#25282] Crash when weting initial mesh pressets with a smoke simulation 2010-12-18 09:46:52 +00:00
ee762ce93f Fix for mistake in own commit
* Was a bit too eager to clean up, so all particles got reset when changing a particle value when animation was playing.
2010-12-18 09:32:27 +00:00
7bc0fa99ae workaround for build system dependency hell, fixed for cmake + makefiles (probably other buildsystems too).
makesrna was often generating source every build, but not updating the files because the contents wasn't changed.

this happened because makefiles would check makesrna.c and rna_*.c files were newer then rna_*_gen.c and force a re-generation.

Now ensure updating the files even if they dont change when makesrna.c or rna_*.c are newer then rna_*_gen.c files.

Another solution for this would be to run makesrna program for each C file for finer grained deps.
or remove file comparison checks but that would mean a change to any rna_*.c file would rebuild all.
2010-12-18 09:27:08 +00:00
b31b63bd72 - Rename operator "Set Curve Radius" to "Set Curve Weight" to "Set Goal Weight"
as it was in 2.49 (functionality of this operator hasn't changed, but it's
  quite confusing name)
- Documentation for some curve operators
2010-12-18 09:18:39 +00:00
77c17d332d fix [#25262] Keyboard shortcut presets can't be made because of wrong folder
New create option when getting a user resource for creating paths.
  bpy.utils.user_resource(type, path, create=False)
2010-12-18 07:22:52 +00:00
96dfaa215c Fix for moving caret to the line beginning/ending when word-wrapping is enabled 2010-12-17 20:24:13 +00:00
8b28c24d16 Fix #25272: shrinkwrap with dependency cycle could lead to eternal
loop and increasing memory usage.

Modifiers should never call mesh_get_derived_final or similar, only
use ob->derivedFinal if it exists, if the dependencies are set correct
and there are no cycles, it will be there.
2010-12-17 20:13:54 +00:00
4b0c455093 Fix #25263: Text cursor click point is random.
- Fixed some wierd cursor placements when clicking in special text position
  (mostly when line segments had null-terminator at the max allowed position)
- Also subtract top padding, so centering is looks a bit better
2010-12-17 19:58:02 +00:00
a0ce28d731 Drag & drop feature:
You now can drop a .blend inside blender window to open it.

Implementation notes:
- Added call to extract icon type for files. Code re-used from
  space_file
- External files that get dropped set icon types too.
  Drop box polls can check for this.
- Also enabled setting op-context for drop operators, this was
  needed to prevent filewindow to open.
2010-12-17 19:05:34 +00:00
fd90685a48 remove some paranoid NULL checks, since the pointers are used already. 2010-12-17 19:05:10 +00:00
b48f7901d2 [#25270] X3D Export generates incorrect location for Lamp
was actually incorrect location for everything!

- x3d's global scene rotation value wasnt converted from deg to radians.
- camera viewport was also incorrectly exported.

use mathutils rather then inline math for rotations.
2010-12-17 18:38:44 +00:00
f01672fde0 Render Buttons UI:
* Fixed a small alignment issue (Aspect Ratio/ Frame Rate Columns)
2010-12-17 18:25:08 +00:00
157082ecc9 fixes for pinning bones & pose ui, could easily get error messages and invalid situations.
when pinned there is no pose bone.
2010-12-17 17:51:43 +00:00
7bca6bcf1f Bugfix #25259
Compositor: using the icon "render only this layer" now shows
progress in header, allows it to stop, and signals composite in
end.
2010-12-17 17:06:36 +00:00
fb977b793e minor warnings removed. 2010-12-17 16:05:40 +00:00
264f37d6d8 Bugfix #25261
Adding weightgroup in weight-paint now sends notifier, so buttons
update
2010-12-17 16:04:05 +00:00
031d37f4d9 Bugfix #25261
Weightpaint tools now grey out when no active group exists.
2010-12-17 16:02:55 +00:00
f90a2123ee no functional change: only check against OB_RECALC_ALL but don't use for assignment.
Makes adding new flags give ambiguous results and also makes it less easy to tell whats intended.
In some places it looks like OB_RECALC_TIME should be left out too.
2010-12-17 15:51:42 +00:00
902b239aa8 no functional changes: SETLOOPER macro assumed a scene was defined called 'sce' used to loop over, now make this an argument, helps to make it clear what's going on. 2010-12-17 15:37:59 +00:00
f53e8b78b4 Bug fix:
When compositing without render (Enable composite, no renderlayer nodes)
the option Full Sample AA caused havoc. Added warning for this case
and gracefully stop render.
2010-12-17 15:24:03 +00:00
04590d86e7 fix for keymap error with renaming rna. 2010-12-17 14:49:38 +00:00
e5e039d626 Bugfix #25264
Bad user counting went on, ID users could be set zero whilst
having Fake user set. Also ensured the code using the BKE
calls for increment/decrement.
2010-12-17 14:20:20 +00:00
12a93c5b0f Fix for [#25256] Particles with trailcount > 1 does not render if particles system is baked to Disk Cache. 2010-12-17 13:29:40 +00:00
48abe2a27f Big fix: particle pointcache was cleared fully on any particle setting change
* Now only the cache after current frame is cleared.
* Probably own fault from my last commit.
2010-12-17 13:13:32 +00:00
676d795d7e bugfix [#25240] Custom properties panel on pinned data fail. 2010-12-17 10:33:28 +00:00
0ec7f95245 == Sequencer ==
Sequence effect rendering of color generator did some rather strange 
fall through, because of a missing break statement. (Noone got hurt, but 
better add that break, just in case)
2010-12-17 08:53:49 +00:00
9f3edfecfc This fixes
[#25011] Opacity IPO not refreshing with still images

(should be better named: animation of any prefiltering parameters using 
still images didn't work out as expected)

And this issue by private mail by Ton:

"I tried to debug a memory-free error; very simple case:

- add image strip
- click on strip at 2 places
- quit blender"
2010-12-17 08:08:35 +00:00
5b56bbfa0b script which dumps ui as xml in a fake blender envieonment.
useful for testing for bad api use (make sure UI uses limited functions).
2010-12-17 07:06:27 +00:00
4474782aa3 bugfix [#25260] Solidify function UV mapping problems 2010-12-17 06:02:52 +00:00
4558d45d46 WM_OT_path_open was failing with non utf8 paths. 2010-12-17 05:12:36 +00:00
5c621bd7f5 cmake was complaining when there was no libs skipped. 2010-12-17 04:41:48 +00:00
Dalai Felinto
61a7c8d4ae BGE Font: increasing the limit of the text object to 140 2010-12-17 02:45:17 +00:00
b51d86d977 Fixed bug reported by Reuben Martin:
Undoing in sculpt mode with drawing mode not set to solid didn't
redraw correctly.

Problem was that the non-PBVH VBOs need to be remade in that case.
2010-12-17 01:40:47 +00:00
66bdb9a12f late summer -- overhauled tablet-handling for Windows 2010-12-17 00:13:23 +00:00
a140fdcbdb SVN maintenance. 2010-12-16 23:24:25 +00:00
6afe713d57 script to generate qtcreator project files, advantage is they include all source which is nicer for refactoring. 2010-12-16 21:32:56 +00:00
eecfc0fbb2 bugfix [#25208] randomize transform doesn't work on objects with keyframes
Surprising this wasnt noticed in a much more obvious case:
 - Key Location, Move, Rotate, Undo-Rotate >> Resets to keyed location as well.

This was happening because DAG_on_load_update() was called on read_undosave(), flagging 'ob->adt->recalc |= ADT_RECALC_ANIM;'

Fix by adding an option to DAG_on_load_update(), not to recalculate time flags.
2010-12-16 19:26:54 +00:00
fef0549ea5 SVN maintenance.
Plus some typo fixes in comments.
2010-12-16 19:05:47 +00:00
fdcfca54e0 Annoyance fix:
Using scrollwheel on properties window halted when it was over
a list-button. Now it disables handling wheel events when you use
scrollwheel outside of lists first.

Implementation note: UI event handlers have priority over other
keymaps. That's OK. In this case it's simple conflict, for which
no design solution exists... wouldn't know how to do this nicer!
Code is nice local and can be improved when we look into other
conflicts...
2010-12-16 18:58:22 +00:00
b978bf39e3 fix for error in testing C/C++ flags 2010-12-16 17:54:00 +00:00
e836d2a169 Bugfix, irc report
After using loop-cut with multiple edges, transform widget
disappeared. Reason was a variable being set in function
not being called on cancelled operators. Now it's in Posttrans()
2010-12-16 17:19:24 +00:00
f7c60cab96 Fix for [#25202] Blender crashes when opening smoke simulations made with Blender 2.55.1 r33530
* Since r33398 smoke only uses one pointcache, but old versions want two caches so save new files with a fake second pointcache.
2010-12-16 16:09:23 +00:00
0a7853478f Workaround #22856: defocus node with OpenMP could crash on Mac, just disabled
OpenMP now in that case, since it's only an optimization.
2010-12-16 14:49:50 +00:00
919d341321 Bugfix #24976 revisited
Multi-layer images: clicking on the "Source" popup freed all memory
for multilayers, even when choosing the same "File" entry again.
Now it should work :)
2010-12-16 13:43:20 +00:00
4e26b4ec38 Bugfix #22794
Panorama render is now border-render safe.
2010-12-16 12:49:48 +00:00
566bda734a last commit to fix warnings didnt set them at all, not it works as it should.
also made cmakes output a lot quieter, messages can be uncommented for debugging or added back if other devs need this for some reason.
2010-12-16 12:48:30 +00:00
d3070ad9ac Bugfix #23658
Render: Alpha calculated for ray-traced transparency could overflow beyond 1.0.
Gets clamped now.
2010-12-16 11:31:04 +00:00
Dalai Felinto
0890b80ed9 Patch:[#25163] BGE support for Blender Font objects - unicode support
Problem/Bug:
------------
There were no way to have proper unicode characters (e.g. Japanese) in Blender Game Engine. Now we can :)
You can see a sample here: http://blog.mikepan.com/multi-language-support-in-blender/

Functionality Explanation:
--------------------------
This patch converts the Blender Font Objects to a new BGE type: KX_FontObject
This object inherits KX_GameObject.cpp and has the following properties:
- text (the text of the object)
- size (taken from the Blender object, usually is 1.0)
- resolution (1.0 by default, maybe not really needed, but at least for debugging/the time being it's nice to have) 

The way we deal with linked objects is different than Blender. In Blender the text and size are a property of the Text databock. Therefore linked objects necessarily share the same text (and size, although the size of the object datablock affects that too). In BGE they are stored and accessed per object. Without that it would be problematic to have addObject adding texts that don't share the same data.

Known problems/limitations/ToDo:
--------------------------------
1) support for packed font and the <builtin>
2) figure why some fonts are displayed in a different size in 3DView/BGE (BLF)
3) investigate some glitches I see some times
4) support for multiline
5) support for more Blender Font Object options (text aligment, text boxes, ...)

[1] Diego (bdiego) evantually will help on that. For the time being we are using the "default" (ui) font to replace the <builtin>.
[2] but not all of them. I need to cross check who is calculating the size/dpi in/correctly - Blender or BLF. (e.g. fonts that work well - MS Gothic)
[3] I think this may be related to the resolution we are drawing the font
[4] It can't/will not be handled inside BFL. So the way I see it is to implement a mini text library/api that works as a middlelayer between the drawing step and BLF. 
    So instead of:
      BLF_draw(fontid, (char *)text, strlen(text));
    We would do:
      MAGIC_ROUTINE_IM_NOT_BLF_draw(fontir, (char *)text, styleflag, width, height);
[5] don't hold your breath ... but if someone wants to have fun in the holidays the (4) and (5) are part of the same problem.

Code Explanation:
-----------------
The patch should be simple to read. They are three may parts:
1) BL_BlenderDataConversion.cpp:: converts the OB_FONT object into a KX_FontObject.cpp and store it in the KX_Scene->m_fonts
2) KetsjiEngine.cpp::RenderFonts:: loop through the texts and call their internal drawing routine.
3) KX_FontObject.cpp::
  a) constructor: load the font of the object, and store other values.
  b) DrawText: calculate the aspect for the given size (sounds hacky but this is how blf works) and call the render routine in RenderTools
4) KX_BlenderGL.cpp (called from rendertools) ::BL_print_game_line:: Draws the text. Using the BLF API

*) In order to handle visibility of the object added with AddObject I'm adding to the m_scene.m_fonts list only the Fonts in a visible layer - unlike Cameras and Lamps where all the objects are added.

Acknowledgements:
----------------
Thanks Benoit for the review and adjustment suggestions.
Thanks Diego for the BFL expertise, patches and support (Latin community ftw)
Thanks my boss for letting me do part of this patch during work time. Good thing we are starting a project in a partnership with a Japanese Foundation and eventual will need unicode in BGE :) for more details on that - www.nereusprogram.org - let's call it the main sponsor of this "bug feature" ;)
2010-12-16 10:25:41 +00:00
ed4e7271f1 CMake now tests warnings are supported, GCC 4.0 wasn't working because of unsupported warnings.
this can work for other compilers too, currently intel and gcc use this.
2010-12-16 09:55:35 +00:00
ee05792a7b missed this file before (de-duplicating enum). 2010-12-16 09:51:55 +00:00
6d2019074f - fix [#25246] export default scene to X3D crashes exporter, own fault but also made sure all colors are now clamped and noticed 3D text was not being exported.
- de-duplicated 'object_type_items' enum, text was known as TEXT in one, FONT in another.
2010-12-16 05:02:15 +00:00
e15f34b35f Fixed bug [#22634] sculpting/multires and wireframe display mode glitches
Added a call to flush sculpting face grid changes out to ccgsubsurf's
other data (in particular, to edge grids)

Hopefully correct fix this time :)
2010-12-16 03:39:51 +00:00
Dalai Felinto
3ae56ea1b3 small tweak, moving /* put compatibility code here until next subversion bump */ {} to a distinct (right) place
when doing a version bump, please remember to do that.
2010-12-15 22:46:43 +00:00
143573f507 Fix #25241: Wordwrap memory leak /w Undo
Looks like drawcache shouldn't be freed when restoring screen because spaces
aren't freeing and could still use caches.
2010-12-15 21:25:54 +00:00
a6855c9c21 Bugfix #25235
Image Editor: paint mode, use clone image, always showed.
Now it hides clone when paint is disabled.
2010-12-15 19:21:02 +00:00
97b0e17577 Bugfix #25243
Pressing Enter twice on enum-menus or pulldowns sent an 'OK execute'
with illegal values (no menu item active). Caused crashes too.
2010-12-15 19:10:42 +00:00
29d2e53463 Bugfix, own collection
Using RMB on menus to change hotkeys was broken.
- the input button was on a weird place outside menu, assign
  would close pulldown, so you had to reopen to check
- ESC didn't close the button, but assigned ESC as hotkey.
  This key is a protected key, and always should be escaping.
- Worst bug: if you used this on a 'user keymap' it removed
  all entries from the map...
2010-12-15 18:09:25 +00:00
7e10a9e6ce ensure pasted graph keys are always selected. 2010-12-15 17:36:08 +00:00
6b2b56c35e Fix for [#25218] No smoke is emitted when particle system starts and ends on same frame
* Depsgraph wasn't updated properly for smoke flow collision object dependencies.
* Smoke also wasn't properly using the actual emission frame of the flow particles.
* There was a lot of bloated logic in some parts of particle code so this fix turned into a small scale cleanup operation.
** As a result particle updating and cache usage should be a bit more stable too.
2010-12-15 17:05:34 +00:00
2c55dd96ad missing check for keyframe paste, was crashing when no keyframes to paste into. 2010-12-15 16:57:56 +00:00
0a3902bb55 change the cursor bounds to only use the Area if the mouse is outside the region or the region is not a WINDOW type. 2010-12-15 16:46:59 +00:00
bc64d8dcd8 Bugfix, irc report:
Stamp info was calling log10 on zero, when end-frame was zero.
Caused crash! Thanks Sergey for report.
2010-12-15 16:15:52 +00:00
ee09aeb498 dont transform hidden handles in the graph editor. 2010-12-15 16:07:49 +00:00
53adab9870 Minor annoyance with graph editor selection:
Selecting graph keys would toggle channel selection if shift was held.
this was annoying when selecting 2+ unselected keys to have the channel change color each click.
Now set the channel based on the selection state of the point, as long as points are being selected the channel will stay selected too.
2010-12-15 15:59:10 +00:00
9129750787 Bugfix #25231
File Window: text clipping was tiny bit too narrow. It was also
clipping text twice even ;)
2010-12-15 15:56:06 +00:00
95f205ed5c Bugfix 21333
"Continuous grab": the boundary is now set to Area (editor), making it work
for operators started in other regions (like toolbar, or in quad view case)
2010-12-15 15:28:03 +00:00
0efdb860f1 Bugfix #22982
Displace modifier: mapping "Global" didn't set a dependency entry.
Fix provided by the reporter himself, thanks Jacob F!
2010-12-15 13:08:34 +00:00
dbbd12d760 Randomize Transform op: Scale Even wasn't really working with objects
with an asymmetric starting scale. Handling of starting scale
values of 0 needs improvement, ie: default for delta transform
2010-12-15 10:59:45 +00:00
35fa581403 BKE_assert(), only prints the error unless cmake define WITH_ASSERT_ABORT is enabled and it will call abort().
made this option advanced so people don't enable along with other features.
2010-12-15 10:22:26 +00:00
eac46088e5 Randomize Transform operator:
Added support for working on delta transformations instead of plain
transform. this should help the fact that you cant randomize animated
objects (still need to check into that)

Removed minimun scale since it was not well done, need a stronger
version of this
2010-12-15 08:21:58 +00:00
dbd3081895 fix for annoyance found when looking into bug [#25226].
Changing the edge crease median value often wouldn't result in the median value entered because of clamping from 0-1.
Now the median crease is applied by scaling the values up/down.

also add some simple checks to speed up updates,
- don't move verts or recalculate normals if only crease changes.
- don't apply crease changes if location is being edited.
2010-12-15 07:15:51 +00:00
46ce8cdf58 replace debug popup function with call to generic function WM_operator_props_dialog_popup(). 2010-12-15 06:12:16 +00:00
97aa2287fa access bpy.app.debug_value, G.rt internally 2010-12-15 06:03:45 +00:00
eb8458b064 Centralized operator UI drawing into a new function uiLayoutOperatorButs(),
Operator drawing calls were duplicated in file selector panel, redo panels, redo & dialog popups.

note, uiDefAutoButsRNA's column's argument was misleading, renamed to label_align.
2010-12-15 05:42:23 +00:00
acd7b81c2d bugfix [#25230] Quick extrude Ctrl-LMB : wrong behaviour of 'RotateSource' option.
Problem is is with operator redo which click-extrude exposed.

Check if redo operator can run, otherwise lock the UI and add a label that the operator doesn't support redo.
This is clunky but IMHO better then failing silently and leaving the user confused.

- Merged redo functions into ED_undo_operator_repeat(), code was duplicated in a few places.
- added WM_operator_repeat_check to check if WM_operator_repeat() can run, avoids an undo call when redo work.

Unrelated changes
- GHOST_SystemWin32.cpp set to utf8 encoding.
- cmake_consistency_check.py now checks source files are utf8.
2010-12-15 04:06:19 +00:00
ff6e631c86 Fixed bug #23042, Sculpting + Multires + Noise texture tears mesh
Noise texture moved the edges of multires grids different, causing
tears in the mesh. Fixed with a call to re-stitch grids (but only done
if the brush texture is set to noise)
2010-12-15 03:53:56 +00:00
32e6f862e9 remove unused args. 2010-12-15 02:09:35 +00:00
f2d843ed2b Exposed mesh edit 'select similar' threshold as operator property, must have been missed before. 2010-12-15 00:56:15 +00:00
a7f2cbc88f As-yet uncommitted changes from end of summer. General code cleanup Mac-side, removed some unnecessary NSAutoreleasePool guards, etc. By no means complete -- just wanted to get this in and do a fresh checkout on another machine. 2010-12-14 22:43:52 +00:00
Nathan Letwory
100d611ce5 Apply patch [#25224] Refactor COLLADA DocumentImporter
Submitted by Martijn Berger.

Make DocumentImporter class the actual IWriter implementation and move prototype to the header.
Group together functions that we should move out of the class.

No functional changes.
2010-12-14 21:46:03 +00:00
7775a1a798 Bugfix #21724
Graph Editor: "make selected channels visible" VKEY didn't 
make unselected channels invisble.

What is left is that the active channel remains visible still.
Not sure if that's by design, for Joshua to answer.
2010-12-14 19:25:49 +00:00
9ac68ad4ab Bugfix #22040
Old bug report:

Image Editor, Painting: crash when texture was visible in 
Material or Texture preview. Was caused by paint code
freeing mipmaps. Now replaced with a mipmap tag (to be done
again), and a new mipmap function that doesn't re-allocate.
2010-12-14 18:02:41 +00:00
73ea636abb clamp colors from 0-1 which are used for display only. 2010-12-14 16:33:04 +00:00
2b53777745 Bugfix #25212
Sequencer: Properties -> Panel "Strip Input" -> file browse button
next to directory name assigned the full file name.

Added on todo: unported code still for "Change Sequence", allowing
to rebrowse strip contents.
2010-12-14 16:23:15 +00:00
4057626e55 - revert own recent change after discussion, default set hard minimum of colors to 0 but now don't set a hard min, each property needs to define.
- use_old_bump setting only applies to material texture slots.
2010-12-14 16:20:25 +00:00
2dc61df9ea Fix for [#25206] Particles system can't start at frame 0
* The basic problem is that frame 0 can't be cached, so the correct solution is to read frame 1 and interpolate backwards from that state.
2010-12-14 15:49:36 +00:00
78e7c6b329 graph editor & action keyframe paste options.
- Offset, so you can paste at the same time of the original frames, at the current frame or relative to the current frame at time of copying.
- Merge method, so the pasted keys can overwrite keys in their range or the entire curve.

Currently there is no redo panel for these space types so the only way to access these options is with F6 redo popup.
2010-12-14 15:14:16 +00:00
93cbc840e0 Fix for [#25198] Smoke gets shown before simulation starts
* Smoke is now only drawn/rendered after the simulation frame range starts.
* This does not apply to simulation end frame though, so that any remaining smoke can for example be faded away nicely through material settings.
2010-12-14 14:45:56 +00:00
295ce322e3 missed renaming this enum. 2010-12-14 13:56:10 +00:00
b412a072e7 script to convert datatoc files back to data. 2010-12-14 12:09:30 +00:00
ef0e29269b curve hide keys were still not right, now match mesh editmode. 2010-12-14 11:22:54 +00:00
b49ac2430c Fix for 'handle_type' submenu in Graph Editor no longer working.
Previous commit fixing rest of handle type keymaps renamed this
operator, but that brings it out of line with rest of animation editor
operators, so reverting that fix.

Also, made Action Editor/DopeSheet use same hotkey as Graph Editor for
setting handle types now (which is same as one used in 3D-View).
2010-12-14 10:52:38 +00:00
58f31f8a5d Change set handle types back to menu now menus have key access - V+A, V+V, V+L, V+F
for Graph & Edit Curve view.

Editcurve can be Hkey for hide again.
2010-12-14 10:17:13 +00:00
996bc87793 update for changes in cmake files. 2010-12-14 08:35:56 +00:00
c52ba88f79 [#25211] Impossible to select an armature with shapes
broke since 2.49b, highly confusing function.
Stick bones dont draw solid so cant run glLoadName() in this case.

Tested pose/object mode with all armature draw types and view draw modes.
2010-12-14 06:20:28 +00:00
96eeb9ad93 bugfix [#25209] X3D export results in invalid value for specular color 2010-12-14 04:45:29 +00:00
2fe540e0f2 disallow RNA color values to be set to negative values. Material colors could be set to -100.0 if typed in manually, this is sure to cause bad/unpredictable behavior. 2010-12-14 04:44:07 +00:00
98f642dd31 Fixed bug #23922, Sculpting - Textured display draws incorrectly
Root cause is that some drawing modes don't work with PBVH
drawing. Worked around by adding a call to update mesh normals from
the PBVH so that sculpted changes appear correctly in those
"unsupported" modes. (They'll still draw much more slowly than solid,
but should at least appear correct now.)
2010-12-14 03:30:30 +00:00
35f431b3d0 Menu UI feature common in other widget sets:
Automatically assign menu keys based on name, alternative to pressing number 0-9 on menus items.

 keys are assigned by first giving each menu item the first character of any word, if that fails any key in the name is used.

- active key is shown underlined.
- only ascii keys are assigned currently.
- can run operators, open menu items.
- currently this only works in cases where number buttons were used (UI_BLOCK_NUMSELECT), but could be enabled for file menu, splash etc by removing this check.
2010-12-14 02:38:29 +00:00
17bd906de3 Fixed bug #23826, Other kind of brushes appear in sculpt mode
Was another problem caused by each brush being allowed in more than
one paint mode.

Added a new field to the brush struct to indicate what mode the icon
was last set for; if it's changed then reset it. Not sure if it's
really worth it to cache this, could remove it for simplicity.
2010-12-14 01:19:51 +00:00
991eac85ff Initial implementation of mdisps layer interpolation
Sculpt data shouldn't be lost when making topology changes without
quads<->tris face converison.

General idea:
- Go through all grid points of each corner and convert per-corner
  coordiante to per-face cooredinate
- Apply weights and convert new point to per-corner coordinate
- Use bilinear interpolation to get needed displacement vector

Some additional work was necessery:
- Two neighbour corners could have different displacements along common
  boundary. multires_mdisp_smooth_bounds() makes displacement "symmetrical"
- Point could change it's corner, so displacement vector should be flipped
  in some way. In some cases it's not only flipping, because corner could
  be mapped with some rotation. It's not solved for triangular faces yet,
  so only z-axis displacement would be interpolated for tris.

More limitations:
- Interpolation will give incorrect result after quad<->triangle
  face conversion.
- When face normal was fillped displacement would change it's direction too.
2010-12-13 21:22:30 +00:00
bfe5ae9ff1 Compositor: Add an option to select the YCbCR conversion mode for the YCbCR combine/separate nodes. 2010-12-13 21:17:00 +00:00
33d98c4d3a Bugfix #25207
Driver fix: typing expression outside Graph Editor didn't tag the 
expression to be re-evaluated. Also missing was notifier for other
editors.
2010-12-13 19:10:35 +00:00
4d5afa04f8 Bugfix #23420
Compositor/Image viewer
In 2.4x viewer nodes had animation playback. Not restored yet.
However, when loading such older files the viewer never showed
any result.
2010-12-13 18:22:59 +00:00
d2f84e0f79 Bugfix #25191
F11 pushed a render window to back, but not popped it.
This also works for user prefs btw, not bad ;)
2010-12-13 17:40:06 +00:00
e3a2622cb5 Small fix in error text returned from baking. 2010-12-13 17:23:03 +00:00
573b8d0309 Bugfix #25197
Curve follow path: the fcurve modifier got lost after tabbing in out
editmode. Also other non-point related curves would get lost.
2010-12-13 17:10:44 +00:00
0ea96731d9 Bugfix #25199
Graph editor: submenu for handle type had drawing error.
Seems to be the collumns-separator feature for enum properties?
No time for debugging that, a 5-item menu doesn't need 2 collumns.
2010-12-13 15:21:44 +00:00
d241f2ed93 Fix for imageeditor's scopes not updating when changing the image. 2010-12-13 14:47:31 +00:00
6402aedc1a Bugfix #25178
Armature edit mode: x-mirror: "switch bone direction" now flips the
mirror bone too. It leaves the mirrored bones selected too, so
you get good visual feedback things happened there.
2010-12-13 13:50:20 +00:00
7a581f95d0 check if a path can be created to a property before showing keyframe items in menus since they only give an error when accessed. 2010-12-13 11:39:11 +00:00
7bf5d9449c "Fix" for [#25184] Forces for growing hair - update inconsistency - as discussed with Jahka on Saturday on IRC
* New option to "Regrow hair" for each frame.
* This was perhaps more a feature request, but there was a similar useful feature called "animated hair" in particles at some point.
* The previous behavior for hair growing was inconsistent to say the least, so this is a nice option to have.
2010-12-13 10:45:24 +00:00
c85adcc2e4 Use mdisps layer from edit_mesh when adding/removing multires modifier
when object is in edit mode.
2010-12-13 10:24:05 +00:00
4cd06a6526 Fix for [#25185] Toggling hair dynamics without deleting cache leaves hair disattached when mesh animation is controlled by deformers - discussed with Jahka on IRC on Sat 2010-12-13 09:39:14 +00:00
a4b410af3d Expose access to PROP_ENUM_FLAG from bpy.props.EnumProperty(), this is exposed as a python set(). The default value is also a python set() so multiple booleans can be used in the 1 property.
Also added PROP_ENUM_FLAG support to operator printouts.
2010-12-13 09:10:16 +00:00
25bf9e38f3 Bugfix #25188: Can't assign "add driver" to hide properties of bones
This was set to being not-animatable in r33397. However, I think there
are some valid use cases where controlling layer visibility may be a
"too heavy handed" approach.
2010-12-13 09:04:04 +00:00
02ec64ca46 fix for error in recent commit. 2010-12-13 08:44:07 +00:00
d09bc78e6b Reshuffled AnimData reading functions in writefile.c as per an old
comment I'd left in there before this code had been merged back from
NLA-SoC branch
2010-12-13 08:08:09 +00:00
6ef85af300 exceptions in registering properties were not properly handled, allowing a single error stop the main module registration loop.
worst case 1 script error could load blender without a UI.
2010-12-13 07:54:35 +00:00
39e3a75978 fix for transform operator giving '<UNKNOWN>' enum value when logged, now pass on the context for operator string representation. 2010-12-13 06:54:25 +00:00
1474b32456 Lattices now have AnimData
This allows manual (point by point) animation of their control verts,
although many other settings cannot really be animated with any
visible effects yet. Interestingly, lattices also had IPO block
pointers, though they were never really used (AFAIK).

Todo:
- Animation Editor support has yet to be added. I've got a few other
things to add to, so will group those changes together.
2010-12-13 06:31:49 +00:00
dec4789571 option to reverse cycle through render slots (Alt+J). 2010-12-13 05:02:23 +00:00
f2d4b7dfb8 fix [#24752] ctr-tab hotkey dont show "mesh select mode" menu for maya preset, but for default blender preset its ok 2010-12-13 04:33:58 +00:00
2ca6e5dd01 multi-dimensional array resolving for rna paths.
eg, "matrix[3][2]" could be used as a driver.

Test from python
  bpy.context.object.path_resolve("matrix_world[2][3]")

Before this was always treated as a 1 dimensional array.
2010-12-13 02:33:14 +00:00
19d0736862 bugfix [#23395] Mirror + Front Faces Only + Grab = Scaling oddity
sculpt normal was used un-initialized, this also affected snake/hook brush.
2010-12-12 23:02:19 +00:00
ddd2dff60e bugfix [#25186] FBX export rotations aren't applied to the exported model file. 2010-12-12 21:50:55 +00:00
433eeee41f clipboard setting background check correction. 2010-12-12 21:28:07 +00:00
450a09de2e Ui: User Preferences "Editing":
* "Sculpt Overlay Color" wasted some unnecessary space.
2010-12-12 20:36:07 +00:00
040112d6ae Fix for compile on windows:
*Variable declaration after return statement
2010-12-12 20:21:59 +00:00
32d82da9e4 Bugfix #25183
Copy constraints pose mode: didn't update constraint flag to denote
colored bone drawing. Also notifier was missing for redraw.
2010-12-12 19:22:24 +00:00
ba2edc007b Bugfix #25179
Armature properties: layer buttons now show which ones are in use,
like object layers.
2010-12-12 18:16:54 +00:00
826cf81d34 Unlinking material crashed, missing NULL check. 2010-12-12 17:59:48 +00:00
1185d70f8f Fix #25177: Skeleton Sketching - deleted sketches don't disappear immediately
Added notifier ND_SKETCH for handling such actions
2010-12-12 16:15:49 +00:00
d47ef94d1a Armature pose: removed the "Confirm" dialog for clearing
loc/rot/size properties.  (same as object mode)
2010-12-12 16:06:04 +00:00
ee73c96e90 - fix for rna show_brush variable shadowing its parent classes with a flag which is now unused.
- getting clipboard RNA variable would crash blender in background mode.
2010-12-12 14:28:23 +00:00
03305de86d OS X Cocoa: added QT "Animation" codec.
Thanks to Jens Verwiebe for providing diff and test
2010-12-12 13:45:35 +00:00
4f343642b1 isect_seg_seg_v2_point was modifying the value of line vectors passed.
this could be confusing later on, now swap the pointers rather then changing their values.
2010-12-12 01:36:10 +00:00
1ad15c37aa avoid possible errors, surround bit shifted defines with brackets. 2010-12-12 01:33:12 +00:00
448d24e7a0 New math util funcitons:
- equals_v2v2
- project_v2_v2v2
- isect_seg_seg_v2_point
which would be necessery for my further multires interpolation commit

M_Geometry_LineIntersect2D now uses isect_seg_seg_v2_point(). Behaviour of this
function was changed a bit -- it haven't returned intersection point in several
cases when two segments are making angle.
2010-12-11 21:27:39 +00:00
194449d038 Sequencer:
Dropping in image/movie/sound strips was broken; it dropped
things in wrong location (frame 0), and without giving images proper
length.

The file path setting code for the operators here is complex...
2010-12-11 20:01:34 +00:00
02be76be29 Drag/drop fix:
Outliner icons of ID blocks can be dragged, but it also caused an
activate of the item. This prevented using outliner for dragging
into name buttons. Now outliner activates on mouse-release, waiting
for potential drags to happen.
2010-12-11 17:55:54 +00:00
8a32c6468e 2.4 feature back:
For constraints that have 'disabled' flag (because it has invalid
input) the name was drawn in red. Easy to recognize constraints that
stopped working.
2010-12-11 17:47:36 +00:00
2b772739fb Moved extensions_framework into addons/modules 2010-12-11 16:35:11 +00:00
1d1c8bb21b Small fix:
Material Properties: adding new materials didn't create a new preview
icon for it.
2010-12-11 16:06:25 +00:00
63a508408d Added some explanation to pointcache->step value as suggested by troubled on irc. 2010-12-11 13:51:04 +00:00
f03735552b Fix for [#22967] UI stops updating
* Close event probably happens when drawable is set to other window and this messes up drawing.
* Also fixes #25071 and possibly #22477 (somebody with osx has to re-test)
2010-12-11 12:24:23 +00:00
3256d0fc6a allow addons/modules path so extension authors can develop their own shared modules. 2010-12-11 11:52:28 +00:00
552cecc89e ported back background_job template from 2.4x, useful for automating blender to generate scenes in background mode. 2010-12-11 11:14:30 +00:00
5f5814f45f - ignore calls to WM_cursor_wait() in background mode (crashes saving blend files)
- rename curve enum value align CENTRAL to CENTER
2010-12-11 11:11:32 +00:00
Dalai Felinto
b4b636386f BGE BugFix: [#25106] modelview matrix incorrect after using VideoTexture - affecting mouse.position. Patch by Benoit Bolsee (ben2610) 2010-12-11 00:04:01 +00:00
c0c4d9c14c fix [#25170] The 3d view properties panel median values use Blender units when set to use imperial.
unit settings were working for vertex location but not median selection.
2010-12-10 23:31:03 +00:00
e11601be37 Bugfix #25153
graph editor:
- option "extend mode" requires channel-selection. Moved pulldown menu
  from Key to Channel instead
- hotkey SHIFT+E for same operation now works both in channel list as in
  main view.
2010-12-10 18:48:20 +00:00
9aace59708 IRC report fix:
Text edit mode (3d): brought back the ALT+Backspace mode for
typing accented characters. Works with an operator property,
so the hotkey for it is free to define.

Example: type 'a', alt+backspace and then 'o'
works to combine characters with ' ` ~ o / and ^
2010-12-10 13:31:59 +00:00
5854cfa5b8 fix for error in recent commit, wasn't masking out the non unit subtype flags. 2010-12-10 13:15:11 +00:00
f610c9b8a2 Bug fix: child particles weren't always updated correctly
* Calling update_children(..) is very light if there's nothing to update, so it doesn't matter if it's called every time the particle system is updated.
2010-12-10 10:34:12 +00:00
fe19e5336b Fix for [#25095] Particle systems and object with collision modifier bug
* Collisions didn't take emitter object layer into account
2010-12-10 08:29:46 +00:00
b12ca6a400 bugfix [#25135] X3D export places scene objects incorrectly in x3d file
matrix rotation order issue.
2010-12-10 06:08:11 +00:00
ad3ce4abab fix [#25116] X3D export does generate image texture information in x3d file
- was exporting UVs only if an image texture was used too
- was also only exporting vertex colors if UV's existed which doesnt make much sense.
2010-12-10 05:35:06 +00:00
736ef55e74 fix [#25155] Glare node > Simple star > Rotate 45 is always applied
from acob F (raccoon)
2010-12-10 04:39:53 +00:00
b27f52ce24 bugfix [#25154] .MXF files should be included as a known video file type in the sequencer
[#25159] Vertex locations dont read correctly and are not labeled correctly in the properties bar.

- non rna buttons can now have units set.
- calls with invalid units system now raises an assert().
- include .mxf in filter.
2010-12-10 04:10:21 +00:00
b4081bfc7b patch [#25027] formatting mathutils.geometry module docs for sphinx
from Luka Bonavita

See:
http://www.blender.org/documentation/250PythonDoc/mathutils.geometry.html
2010-12-10 00:20:32 +00:00
2ed82275b5 transforming pose bones while the animation was playing would crash. 2010-12-10 00:10:43 +00:00
d9f131f2f0 tag unused variables. 2010-12-10 00:00:01 +00:00
545cc4803e Change the BLF_aspect function to handle 3d text.
This is need to properly handle 3d text (dalai work on GE), before
the BLF_aspect only take one argument, and the result was a call to:
	glScalef(aspect, aspect, 1.0)

Now the three value are store in the font (x, y and z) and also
need to be enable using BLF_enable(BLF_ASPECT).

By default all the code that don't have BLF_ASPECT enable work with
a scale of 1.0 (so nothing change to the current UI).

I also remove all the call of BLF_aspect(fontid, 1.0) found in
the editors, because is disable by default, so no need any more.

Campbell the only thing to check is the python api, right now
I modify the api to from:
	BLF_aspect(fontid, aspect)
to:
	BLF_aspect(fontid, aspect, aspect, 1.0)

This is to avoid break the api, but now you need add the BLF_ASPECT
option to the function py_blf_enable and in some point change
py_blf_aspect to take 3 arguments.
2010-12-09 22:27:55 +00:00
3ee53d7b5f Related to previous commit:
I still have to learn more of the recent changes in code :)

Didn't know the handle type options became a menu for Curve edit mode. 
Providing much-used tools non-modal (direct) really should have 
preference. Pull down is not very accessible here though, will
check on it later. :)

This restores H, Shift+H, V and alt+H for handle setting.
2010-12-09 19:06:45 +00:00
41acfb1907 Bugfix #25150
Graph editor: hotkeys for handles restored; they work immediate 
and non modal now (menu was ugly and slow). Uses similar options
as 3d curve editing, but not toggling 'aligned'
HKEY: sets aligned
SHIFT+H: sets auto
ALT+H: sets free handle
VKEY: vector handle
2010-12-09 18:31:40 +00:00
4640833747 Two nice usability fixes:
- On inserting keyframes in buttons, no redraw happened
- Keyframe in icon-only buttons now draw color in background.
2010-12-09 18:08:58 +00:00
996674704e Added more clear tooltip for Auto Save feature. 2010-12-09 17:36:44 +00:00
6a3efdc23a User prefs: label "Auto Save" was on wrong position. 2010-12-09 17:35:35 +00:00
Dalai Felinto
f1c4688e25 renaming blf_api.h to blf_py_api.h
In windows this was producing Linking dependence errors because we have BLF_api.h in the /blenfont/ and blf_api.h in /python/generic/. It doesn't produces crash out of the box but I was trying to link both "api" files to the same project (Ketjsi folder). For the linking order was determining what header to use. A workaround is to "include" the file using some ../../ relative folder. But renaming it is less error prone.

Probably Ketsji folder shouldn't link to BLF_api.h anyways, but this is something I will look better later before another commit. In the mean time it's not a good idea to have 2 api files with the same name (for non case-sensitive systems).
2010-12-09 17:31:42 +00:00
b6c68777ad A little more work on patch [#24814] Operators which have no decription
submitted by Murat Egretli

Not actually a patch but talks about descriptions that are missing
and some small fixes that are needed.

Kent
2010-12-09 16:50:32 +00:00
6cd849809d Bugfix 25147
Graph editor: operator poll for 'active curve' didn't check for
visibility flag, caused tool like ctrl+click to still work.
2010-12-09 16:15:51 +00:00
ad35b37f2d Bugfix #25120 and #25119 and numerous future bugs!
Two isses:
- Material assigning to MetaBalls used wrong pointer
  (copy paste error, casting badly).
- Checking for node-material used wrong RNA pointer
  (confusing void stuff going on here!)

The error leads to corruption in data and/or random
crashes. Better update svn now!
2010-12-09 15:49:05 +00:00
9f4b5d49fc Problem with FCurve pasting reported by Rob Garlington.
- Pasting from 1 fcurve to any other fcurve now works (skip index and rna path checking).
- Pasting multiple fcurves between bones now works.
- If path checking fails, pasting matches indices so Scale XYZ can be pasted into Location XYZ for eg.
2010-12-09 11:49:38 +00:00
Dalai Felinto
c6b3d4ff14 removing BLF_types.h from CMakeLists.txt 2010-12-09 07:05:09 +00:00
de159a67aa - internal py/rna ifdef's USE_MATHUTILS was mixed up,
- updated tooltip for vertex group mirror.
2010-12-09 06:08:19 +00:00
b25c32393d Add the possibility to set a 4x4 matrix to be used on blf.
This option allow the user to set a 4x4 matrix to be
multiplied before draw the text, for example:

	double *m;

	/* Get the matrix or build it! */

	BLF_matrix(m);
	BLF_enable(BLF_MATRIX);

	/* set color, size, etc and draw! */

	BLF_disable(BLF_MATRIX);

You don't need the last line (disable), but remember
that if you use the font to draw in any other place,
the matrix will be used!.

The GL code is:

	glPushMatrix();
	glMultMatrixd(m);
	glTranslatef();
	glScalef();
	glRotatef();

	glPopMatrix();

Let's Dalai test this!!! :D
2010-12-09 04:36:58 +00:00
36175f37c9 bugfix [#25104] Identical material settings render differently
- Use Old Bump option wasn't available.
- noise_intensity wasn't visible for MULTIFRACTAL musgrave textures.
2010-12-09 03:22:03 +00:00
3209077caf Testing commit! Remove an empty file. 2010-12-09 01:05:06 +00:00
e0ab0bc401 Added a few descriptions that were missing.
This is a little bit of todo item:
[#24814] Operators which have no decription

Kent
2010-12-08 21:56:50 +00:00
5d2966283b UI Cleanup: Halo materials and textures
* Textures applied to halo materials showed influence option for normal particles. This was really confusing, and with the cleanup I revealed a couple of hidden features too!
** Particles actually allow for textures to change halo size and hardness, but my guess is that nobody knew since the names were wrong in the ui!
** I also added the option to change the "add" value with a texture, since it was just silly not to have it.
* Halo material properties are also a bit cleaner now.
2010-12-08 20:10:59 +00:00
8f8aa3f863 Bugfix #20598
Armature editmode: Circle select didn't flush selections, causing
the center part of bones to remain unselected.
2010-12-08 18:12:59 +00:00
925077f744 Bugfix #25099
Outliner: group view: restrict buttons should be disabled in editmode.
2010-12-08 17:51:25 +00:00
071b61259b increase grease pencil user count when copying objects. 2010-12-08 14:40:14 +00:00
e5a9dd928a Bugfix #25086
The texture node is procedural; like RGB node it has no real buffers,
but allows per-pixel reading. The compositor uses nodes that directly
access buffers too, which conflicts with it... needs more design here.

Restored old functionality that just passes on preview size buffers
for nodes to prevent crashes. Giving it a render-size buffer is not
nice; the resolution-independence of texture nodes is interesting to
keep.

Solution could be:
- visually tag input/output sockets for this case (sockets with buffers, 
  vs sockets with values), so users know what to expect.
2010-12-08 13:19:27 +00:00
02f4003184 metaball rotations must be kept normalized, normalize values after setting from rna/python. 2010-12-08 13:02:16 +00:00
b8bde683fb remove contents from the svn cleanup file. not used now and could turn up results with source searches. 2010-12-08 11:44:38 +00:00
1622385445 pedantic word ordering change.
- wm.add_modal_handler -> modal_handler_add
- wm.add_fileselect -> fileselect_add
- ob.add_shape_key -> shape_key_add
- VIEW3D_OT_add_background_image -> VIEW3D_OT_background_image_add (same for remove)

Also made 2 internal cmake vars hidden.
2010-12-08 11:42:11 +00:00
40af167b09 Bug fix: normal (from particles) child particles didn't use the rough parameters properly
* Also child particles didn't do particle trail properly.
2010-12-08 11:02:56 +00:00
e29ac3fc76 use prints rather then asserts when normalized quats are expected. 2010-12-08 09:57:21 +00:00
cea760ac5a this change broke building. 2010-12-08 09:50:49 +00:00
eb26103822 cmake - mark vars as advanced so they dont show up by default when configuring. 2010-12-08 09:02:08 +00:00
afacd18498 use lowercase for cmake builtin names and macros, remove contents in else() and endif() which is no longer needed. 2010-12-08 08:43:06 +00:00
Dalai Felinto
70df57df0f BGE BugFix: [#24052] Can't change dynamic object's orientation using python (fix by Benoit)
from the tracker:
"""The required functionality is provided by the localOrientation property: setting this value will change the dynamic object orientation. This is because dynamic object have no parent and thus the local and world orientation are identical. However, setting worldOrientation will only change the scenegraph node, which has no effect as the physics controller will reset the orientation on next physics synchronization."""
2010-12-08 06:59:13 +00:00
2692dc5561 bugfix [#25082] minor bug. RGB to Intensity doesn't works for Lamps
- This is working correctly but confusing, made more confusing by UI problems, corrected these and updated tooltop for 'tex.use_rgb_to_intensity'
- bad RNA arguments used for lamps (left over from RNA renaming).
- use isinstance(...), rather then comparing type() directly, this failed with lamp type checks.
- removed redundant argument to internal texture UI function factor_but().
- the texture color was drawn inactive when it was used in some cases.

Note. AFAIK its not possible to do a general check to see if a texture is colored or not, eg: its possible a plugin texture returns color in some cases and greyscale in others.
so for now always have color button active.
2010-12-08 05:51:16 +00:00
1f16e68af9 bug [#25081] changes to pose bone selection state via python have no effect.
Remove pose channel select, this is for internal use on read/write only.

Its possible to have a convenience attribute but rather not fake bone data being in the pose channel. just access pose_bone.bone.select
2010-12-08 04:40:20 +00:00
23a49334ed fix for own change r33524, at the moment the context always has to be valid, noted with XXX.
reported by Doug Hammond.
2010-12-08 03:25:31 +00:00
2e667e45fc Changed armature active bone so it is separate from selection this is consistent with active object, mesh editmode, curves & metaballs.
- active is no longer assumed to be selected.
  this fixes a simple bug - eg: Adding a new armature, entering pose mode and toggling selection failed.
- outliner editbone selection now works like object and pose mode.
- mouse selection sets the bone active even when the tip is selected.
- active, unselected bones draw as wire color with a 15% tint of the selected color.
2010-12-08 03:05:46 +00:00
47d6166adb fix [#25088] Add spot lamp causing crash
this is actually an assert not a crash, when the lamp and view axis were aligned, the quat could not correctly be converted into a matrix.
Now fallback to the X axis in this case.
2010-12-08 00:58:15 +00:00
1a8665ac45 Fix for [#25079] Duplicating object with particles system on it make Blender crashs
* pointcache->cached_frames wasn't set to NULL when copying pointcaches
* also set pointcache->edit to null just in case
2010-12-07 22:17:58 +00:00
b5ab3980e8 Fix #25085: Enabling "Show Cone" on dupliverted buffer spots crashes Blender
Cone can't be drawn for duplicated lamps, because lamps with cone are drawn after
main draw function (from view3d_draw_transp) and list of duplicated object gets
freed to this moment.

Disable cone draw for lamps which are from dupli.
2010-12-07 20:22:35 +00:00
9c76ff3f2e "Particle" texture coordinates for halo materials:
* Particle age can now be used as the texture x-coordinate, and location in a particle trail as the y-coordinate.
* This finally enables particles in 2.5 to change their color (or any other texturable material property) by their age.
* In 2.4x this was accomplished with the "100 frames == particle age", but this was both non-intuitive and slow as the animation system had to be recalculated for every particle.
* Currently these are 2d coordinates (age/lifetime == x-coordinate, trail particle index/number of trail particles == y-coordinate), but other particle properties or possibly even a user definable property can be added as coordinates in the future.
* On the code side this uses the same coordinate definition number (for halo materials) as strand coordinates (for surface materials). This is also nice as they intuitively mean nearly the same thing, i.e. along strand or during particle life.
2010-12-07 12:58:25 +00:00
a98fc7500d - fix for crash with constraint UI when using with a pinner object, with None active.
- fix for material UI when the pinned data was not a material.
- fix an error axis-angle drot label.
2010-12-07 12:51:03 +00:00
b5c2f9df95 Bug fix: Halos didn't use texture alpha 2010-12-07 12:29:51 +00:00
3e7469cd01 Added WITH_CXX_GUARDEDALLOC support for GHOST, disabled by default. 2010-12-07 11:57:34 +00:00
6c32bffab0 Bugfix #24163a: Unable to animate INSIDE a group node in the compositor
(This commit doesn't fix the original bug reported in the report, but does fix one that was discovered while investigating that one) 

Trying to insert keyframes for nodes within group nodes was failing. 

This was caused by the ID-block for those UI widgets being set to the Node Editor's current ID-block (i.e. NodeTree) vs the NodeTree that those nodes lived in. The net result was that the paths couldn't be resolved, as the paths obtained for those widgets could only work up to the group's nodetree.
2010-12-07 11:03:53 +00:00
d3f9b0d05a Bugfix #25049: Compositing Nodes not Keyframable
An error seems to have been introduced to the node-tree building at some point, which means that the ID-type for data-attached node trees was incorrect (i.e. scene->nodetree->id.name = NTREE_COMPOSIT instead of ID_NT). 

This in turn meant that the ID AnimData availability poll would fail, as the ID-type could not be determined.
2010-12-07 10:15:09 +00:00
15d37747b3 bugfix [#25074] visible, selectable and render toggles in outliner not available
outliner added UI buttons which exceeded the range of a short, use ints for x/y button positioning.
2010-12-07 09:22:14 +00:00
46990b4904 fix for own mistake, reported [#25076] Creating new empty crashes Blender 2010-12-07 08:52:12 +00:00
Nathan Letwory
c5613de2d5 Remove redundant VC_REDIST code, since it's not used anymore. 2010-12-07 08:37:00 +00:00
8d284b7d02 error checking for setting operator string values for python operators, and get rid of annoying warnings (cmake/linux now builds without warnings again, except for extern libs). 2010-12-07 08:27:20 +00:00
d620ff8380 2D text drawing
- with the NLA on a small strip text was drawn under the scroll bar, now draw with same alignment as rectangle constrained text.
- single alloc per text item.
- was using opengl context rather then passing color value.
2010-12-07 07:02:47 +00:00
612936954a minor internal python api change - pass the context rather then getting from BPy_GetContext() again. 2010-12-07 06:47:40 +00:00
1e57d8c4e7 bugfix [#25073] Rendered image goes dim when saved from python batch script 2010-12-07 05:39:14 +00:00
d624d1cbdd pass along the context to extension functions, this was already being done in all cases except for the render engine.
this allows python to NULL its internal context while scripts are not running.
2010-12-07 04:12:15 +00:00
48614fbc2a Added an assert() check for normalized quats which exposed a number of bugs where normalized quat was incorrectly assumed.
This would have made bug #25003 very simple to find.

- Objects had their quats normalized when calculating their matrix, this is inconstant with pose bones and isn't useful for animation.
  Also it wasn't normalizing the delta rotation so these would give bad rotations.

- Converting between rotation modes BKE_rotMode_change_values() assumed normal length quat. changing quat to euler rotation for eg could change the bone.

- Clear rotation and transform were not normalizing the quat when 4d loc was disabled on quat rotation, corrected and also made it so the quat scale is restored after conversion so animations curves dont jump.

There is 1 case in mat3_to_quat_is_ok() where quat_to_mat3 on an unnormalized quat is needed, for this I had to add an ugly static function quat_to_mat3_no_assert(), but overall its worthwhile IMHO to be able to find incorrect use of rotation conversion.
2010-12-07 01:56:32 +00:00
Dalai Felinto
fe0f78a669 BGE BugFix: [#21246] Some values for ipoactuator.frameEnd and frameStart make ipo not play the first time
This is a bug as old as the ability to change the actuator values through Python.

For the records: although Blender supports floats as frame values BGE doesn't. It could but it doesn't. So only integers (longs) will be valid start/end frames.
2010-12-07 01:54:25 +00:00
7b39a7cdb9 mathutils quaternion axis/angle access was broken for non unit lenth quats, would return NAN's in simple cases.
now normalize upon conversion, when setting the quat axis/ange, maintain length by scaling back to the original size afterwards.
2010-12-07 01:38:42 +00:00
8bd5425a71 incorrect paranoid check for drawing texture face mode with no faces, it would crash in this case anyway.
instead check for faces from the caller.
2010-12-07 01:30:14 +00:00
4425331729 fix for crash on missing NULL check,
Brecht, changed this to update the duplicate objects data rather then the old ones incase they are not linked.
2010-12-07 00:48:36 +00:00
8e8b07cc07 Got rid of old-school searching CVs for index update.
No more infinity loops could happen -- only keyIndex data loose.
But it's smaller harm and actually could be easily fixed and it's more
correct way.
2010-12-06 21:18:08 +00:00
79ac49e290 Bugfix #25060
Edit mesh: CTRL+Click added vertices in edge/face select mode, but
doesn't draw them. Better disable it then.
Also removed dangling event print.
2010-12-06 18:58:04 +00:00
e779e3b08a Bugfix #25003
Pose mode: "Paste flipped" failed on not-normalized quaternions
(for example ones you edited with buttons)
2010-12-06 18:10:08 +00:00
59268ca715 Update curve animation data when loading UndoCurve -- fixes memory corruption
when starting playback after undo-ing topology changes

The simpliest way was to change data at which undoCurve_to_editCurve and
editCurve_to_undoCurve works from curve to object. Maybe it's not very
cool, but still better than moving curve animation handlers outside of
editcurve module.
2010-12-06 17:49:57 +00:00
2c7a2a6a41 Sync fix with render branch. Solves crash with ob->bb not found. 2010-12-06 17:41:12 +00:00
14ec2d9122 Curves CV animation
===================

Update fcurves RNA pathes after making changes to curve topology, so
animation will no longer lost after edit and wouldn't lead to crash.

Will be very useful for RotoBezier addon.

Also NodeKeyIndex renamed to CVNodeIndex due to node is an entity from
another module and better not used in others.
2010-12-06 17:20:22 +00:00
9d636334e9 Bugfix #25023 (additional remark, not report itself)
Adding Cone didn't set default 'fill end cap', as tooltip
promised it would be.
2010-12-06 15:44:06 +00:00
997338b5cb Curves shape keys:
fixed memory corruption after creating new CVs and switching direction
2010-12-06 13:44:36 +00:00
25bd57b0a1 include getset's for generating module docs.
used for bpy.debug/tempdir/driver_namespace which were previously undocumented.
2010-12-06 12:36:55 +00:00
d64f46e0bb CMake: use a global list to store libraries built rather then cmake_blender_libs.txt file. 2010-12-06 10:56:37 +00:00
357826aa6e bugfix [#24967] bge.KX_GameObject.worldAngularVelocity does not work, breaks mathutils somehow
- Exceptions from reading vector values in the game engine where not being caught.
- Also wrote specific KX_GameObject exceptions, without these the errors are quite confusing.
2010-12-06 08:29:41 +00:00
4dceafc928 bugfix [#24995] Object rotation seems to be applied incorrectly
- Object actuator rotation was being scaled by: (1/0.02)*2*PI/360 == 0.872, since revision 2. 
- Remove scaling and use do_versions to adjust existing files.
2010-12-06 07:45:07 +00:00
5c8dfc1d51 bugfix [#25057] Vertex paint - Cannot select or paint vertices of obscured vertices, even when obscuring faces are hiddden 2010-12-06 06:26:47 +00:00
0198b85ab9 [#25030] Grease Pencil active_frame_delete() deletes wrong layer
move buttons to the header since they only operate on the active layer.
2010-12-06 05:31:27 +00:00
7613d36b2a bugfix [#25046] Bold and Italics checkboxes for Text objects seem to do nothing
- Part of this report is a misunderstanding, but there was no access to bold/italic fonts. 
- Added rna access and changed the operators to use only rna properties.
2010-12-06 04:05:34 +00:00
a1fed1e268 [#25047] Deletion of any custom key map item remove always first one
keymap item id for user defined keymaps wasn't defined properly. This is really old, I'm surprised with didn't catch this before.
2010-12-06 02:42:59 +00:00
a724918cf3 bugfix [#22663] object material slots not updated for library data 2010-12-06 02:32:16 +00:00
60063d5383 - converted path cleaning on file load to use bPath Iterator functions - image & font and sequence paths were being cleaned but not multires, voxel & sound paths.
- skip fixing file paths on undo.
- simplify bpath alloc and free functions, also pass Main structure so as not to rely on G.main, (needed for file load).
2010-12-06 00:52:30 +00:00
2f366d1544 use BLI_strnlen rather then strlen when comparing against fixed lengths. 2010-12-05 23:50:55 +00:00
9668c29ba0 bpath iterator updates
- loop over sequencer plugin and texture voxel paths.
- fix leak in python bpy.utils.blend_path() and use PyUnicode_DecodeFSDefault() to ensure correct paths with different encodings.
- operators to make paths absolute & relative now redraw the view.
2010-12-05 23:14:48 +00:00
b110c7c8f2 Dependency graph: changed DAG_id_flush_update to DAG_id_tag_update. Now it
only tags the ID and does the actual flush/update delayed, before the next
redraw. For objects the update was already delayed, just flushing wasn't
yet.

This should help performance in python and animation editors, by making 
calls to RNA property update quicker. Still need to add calls in a few
places where this was previously avoided due to bad performance.
2010-12-05 18:59:23 +00:00
07692fc59b Partial bugfix for [#25037] , brought back Select menu in Sequencer
header...
2010-12-05 17:56:15 +00:00
ba8c185161 extensions_framework: prefer user config and scripts dirs, if set, to save addon config files to. 2010-12-05 16:39:48 +00:00
49320e697f Probably bugfix for [#25050] Outputing mpeg (audio in AC3 format) causes
audio to become buggy.

Added sensible audio preset settings for ffmpeg rendering
2010-12-05 16:14:34 +00:00
2011442931 Render UI: added the very important "free unused nodes" in the
Performance panel. This should actually be default on background
render...
2010-12-05 14:13:57 +00:00
2567a0ef52 Bugfix #25041
Sequencer crash when combining a scene strip with image strip and cross.
Code lacked proper check for byte buffer in scene...
2010-12-05 12:32:58 +00:00
c98f5b2e4b Bug fix #25042
Emulate numpad option: failed to use zero key to reset color picker.
2010-12-05 12:14:02 +00:00
57d1d4f78c Object transparency setting should only show on MESH type 2010-12-05 10:38:45 +00:00
0400745c0a Fix part of #25040: rendering multiple scenes from compositing nodes didn't
restore current scene properly afterwards.
2010-12-05 10:14:34 +00:00
260687d9b1 use PyUnicode_DecodeFSDefault rather then PyUnicode_DecodeUTF8(str, strlen(str), "surrogateescape"), for converting non utf8 names.
this is needed because some UTF8 names didnt resolve on windows when using surrogateescape'd strings.

This meant you couldn't export to models some directories on windows.
2010-12-05 09:20:18 +00:00
d30cd92014 - Fixed dead-lock when subviding curve
- Hard-limit for cuts number is set to INT_MAX, soft limit to 10 (same as for meshes)
2010-12-05 07:08:14 +00:00
5f8eb5c069 use constant strings for outliner menus rather then sprint'ing them together. 2010-12-05 06:40:47 +00:00
8a65538fe0 fix for camera border going outside the clipping range while in camera view. 2010-12-05 02:16:01 +00:00
8c467a9c8a Fix for [#25036] boids particle from 2.49 opened in 2.5 is crash !?
* Old boids didn't have all of the necessary data for the new system.
* Changed the particles code so that a check for all necessary data is always done before starting actual dynamics calculations.
2010-12-05 01:48:49 +00:00
55e3d499ae correction to r33469, operators return sets so string comparison isn't valid. 2010-12-05 00:08:25 +00:00
a3bac149a1 Fixed memory leak in thumbnail_joblist_free: last image in loadimages weren't
freed even if it's not copied to the filelist
2010-12-04 18:34:31 +00:00
b3eea07e84 IRC report:
Adding mesh primitive circle/cone/tube now has first vertex
on top. Looks much nicer on low vertex totals.
Fix provided by Mario G Kishalmi, thanks!
2010-12-04 16:02:04 +00:00
cadd08b16f Bug fix #21900
Issue with Library linking: if you already have libraries linked in,
and you attempt to link more data, using internally already linked
stuff (like a group with group links) the linkage would fail. It did
resolve on save-load though.

There's a long commented history in this code explaining it. I found
out it was because of manual step-by-step linking versus normal file
reads. In the first case, the "lib pointer map" was missing references.
2010-12-04 15:45:16 +00:00
5150884550 Cocoa : fix drag and drop was no more operational after having fullscreened the window 2010-12-04 14:26:45 +00:00
282910fdae Bugfix #21893
Python Operator "Delete Edge Loop" (which keeps mesh connected)
changed selection if sliding operator failed. Simply added a
check for return value. Gosh, that Python code is not bad ;)
2010-12-04 13:46:25 +00:00
fa4bbbb249 Maintenance,
- remove some redundant declarations
- changed VertexTangent and Path structs to avoid compiler alignment padding.
2010-12-04 13:00:28 +00:00
4dc59fff28 Bugfix #24699
Crash when deleting Shapekeys, while Graph or Dopesheet was visible.
Caused by RNA collection lookup, which is not checking against index 
out of range errors.

Brecht might have to give blessings for this though :)
2010-12-04 12:33:45 +00:00
0271ad6322 Give functions that use printf style formatting GCC format attributes so if incorrect formatting is used the compiler will warn of this.
found & fixed 2x incorrect formatting args.
2010-12-04 11:44:56 +00:00
471d304df1 Bugfix #25033
Texture face options like "two side" were invisible, unless the
top bar "render engine" was set to Game Engine.
This is confusing, since 3d window does draw these options well.

Added back panel to show default, but with a label warning that
the options are not supported for render.
2010-12-04 11:34:26 +00:00
47ca7a5f39 disallow setting RNA attributes while drawing, this is bad practice so enforcing here has the benifit of making sure people are not manipulating blender scene data in a drawing panel for eg.
This is ifdef'd and may be disabled later on, or only enabled in debug mode.

This applies to setting any RNA value that has an ID and is not a screen or window-manager datablock.

Some addons break this rule and need fixing but from my tests blender UI scripts are ok.
2010-12-04 06:25:36 +00:00
627e56b614 minor changes to bone UI script. 2010-12-04 06:21:08 +00:00
fe67fc6459 fix for strict prototype error. 2010-12-04 05:34:16 +00:00
60fad4c955 own mistake made r33442, was returning the pose channel, rather then its bone. 2010-12-04 01:11:50 +00:00
9dbb31383f remove shadowed definitions but keep them as zero this time. 2010-12-03 23:55:10 +00:00
0559f4f3e7 Const conflict in PIL_dynlib_find_symbol
Thanks wiseman!
2010-12-03 19:42:40 +00:00
1ebfb545ee Bugfix #2508
Campbell's cleanup commit  33442 today broke axes drawing.
Restored code.
2010-12-03 19:29:05 +00:00
c8f80fffba IRC fix:
Curve editmode was missing hotkey for operator "Select Inverse"
Is now added like Mesh, CTRL+I
Thanks lmg!
2010-12-03 18:49:38 +00:00
b036437a5b IRC bug report
Text editor, "Add new" caused zero-user block.
The claim in the code why it should be decreased is dubious.
Thanks wiseman!
2010-12-03 18:39:40 +00:00
5ae3c5d321 Irx report:
Missing void declarator in init ffmpg (appears to be error now).
Thanks lmg!
2010-12-03 18:35:10 +00:00
45922c9150 Bugfix #24568
The old blocking "time cursor" wasn't working anymore.
Commit 32798 overlooked that the initialization was
needed.

Now bakes show it again. Note to self: it seems to flash
slightly (like 2.49), need to check on it one day.
2010-12-03 18:26:42 +00:00
990b487c73 Bugfix #25026
Nurbs edit: 'switch order' crashed when order was higher than amount of 
points.
2010-12-03 17:31:34 +00:00
263830f000 Enabled GCC -Wwrite-strings warning for CMake and replaced many 'char's for 'const char's,.
Only one functional change where Transform orientations passed "" to BIF_createTransformOrientation() which could then have the value written into.
2010-12-03 17:05:21 +00:00
7c86a1a95c compile fixes for mingw32. 2010-12-03 16:45:04 +00:00
a21c639529 Fix for compilation error caused by strict prototype checking 2010-12-03 14:35:10 +00:00
8934b61739 Fix #25017: Bezier Curve Deform Twisting after adding Shape Keys
- Invalid step was used in curve_applyKeyVertexTilts
- Minor cleanup in editcurve stuff
2010-12-03 14:35:03 +00:00
52edaae9c5 Bugfix #20565
Material Node shaders: displaying GLSL + rendering previews crashed.
Reason was non-safe threaded access to material nodes. Now, on a preview
render, a full copy of Material is being made.
2010-12-03 14:26:03 +00:00
cd97253502 - added GCC warning -Wstrict-prototypes
- fixed bug in paste material, exposed by stricter warnings.
- removed/renamed various shadowed vars.
- removed BGE lamp.colour, only allow lamp.color attribute.
2010-12-03 12:30:59 +00:00
aca76ddb50 Fix for [#24899] Sequence Transform strips don't apply animation properly to scale.
* Rendering a scene strip updated all animation data to it's frame, so fcurves were left with the wrong value.
* Now the animation data is recalculated to original frame after rendering each scene strip.
2010-12-03 12:08:59 +00:00
9295a53022 Align Objects operator was broken due to incorrect order of vector by
matrix multiplication
2010-12-03 11:05:36 +00:00
cfc1b133f6 updates to patch from Dan Eicher, allow adding a NodeGroup through bpy.data.node_groups.new(name, type)
made some minor changes.
2010-12-03 03:44:39 +00:00
892b3fbe17 fix [#24938] Seed value on Particle settings gives Error when trying to insert key. 2010-12-03 02:24:21 +00:00
b45c3363fd fix for some pedantic warnings. 2010-12-03 01:52:28 +00:00
9e5577db47 fix [#25015] Ctrl+L linking to scene list does not scroll when the list is larger than screen resolution 2010-12-02 22:58:23 +00:00
cbab6a742f correction to error message from Dan Eicher 2010-12-02 21:55:55 +00:00
287325af35 fix [#24586] Report mode of console does not show proper cariage returns.
use the line iterator to split up newlines.
2010-12-02 21:48:46 +00:00
de0b41588a fix crash when report timer was set but no usable error reports were found. 2010-12-02 21:40:39 +00:00
3a88d96aa2 extensions_framework: fix bug that would create extra UI space when entire row is hidden. May not be the most efficient implementation, however it is working properly now. 2010-12-02 19:03:24 +00:00
f94dd65999 Bugfix #25010
When loading files without UI (quit.blend) you got memory-free errors
for fileselect. Pointers were NULLed where not needed.
2010-12-02 18:27:04 +00:00
1656366903 Update include paths for fonts in image stat display (rev33422). 2010-12-02 17:30:28 +00:00
30179f4dc6 IRC comment fix:
Option "free all texture-images" after render, was also
freeing unsaved painted images. Now it skips them.
2010-12-02 16:12:55 +00:00
5ca7c1b0f8 Fix for [#25006] Particle system crash (missing check for negative index) 2010-12-02 14:52:07 +00:00
38eb5fe75c bugfix [#24913] Text bevel normals wrong
error was introduced 33269, to fix [#24834].

this only reverts a small part of that commit, added note not to change this.
2010-12-02 05:39:43 +00:00
7b5696c866 Fix for [#25001] Enable Smoke High Resolution is greyout after baking
* Was a bit too eager to disable stuff
2010-12-02 04:47:40 +00:00
f305ed0c50 use fixed width fonts for image stat display. 2010-12-02 04:23:56 +00:00
1dbc93b540 Additional fix for #24958 Cloth pinning not working
* Don't assume that the original dm given to cloth modifier is a cddm
2010-12-02 04:06:02 +00:00
e75ef3551e Adding some descriptions for animation-related operators that were missing them. 2010-12-02 02:03:30 +00:00
b31594c4ab patch [#23212] Python api for Nodes
from Dan Eicher (dna)

This allows automated node tree creation and editing.

developer note, made some changes to the patch.
- removed incorrect use of container_of(), GCC only also, search for the scene instead.
- commented socket min/max access, these are internal use only as far as I can tell.
- commented group/ungroup functions, these use the selection context and are not really data level functions.
- use remove() rather then delete()
2010-12-02 01:18:59 +00:00
024b0f92d5 fixed crash with rigid body constraints not having their child pointer read correctly. 2010-12-01 23:40:21 +00:00
3e214bd72c Bugfix #24999
Array Modifier: edge indices could be equal to numVerts, causing 
bad crashes in derivedmesh. Similar fix to previous here with
face indices. Should poke the coder of this... for now it survives OK.
2010-12-01 17:47:38 +00:00
f4205498a9 Bugfix #24890
Particle cache reading: crash when loading .blend on a different
endian system, code was dumping arrays in .blend without DNA.

General warning for devs: avoid generic write_data and dynamic
arrays in DNA.
2010-12-01 15:58:45 +00:00
6090b1c5a7 Bugfix #24903
GRLESS key was missing in RNA key list, so it didn't show up in
keymap editor. Internally support for it worked already.

Thanks to Milos Zajic for showing the fix.
2010-12-01 13:18:24 +00:00
b36ab83778 Fix for [#24958] Cloth pinning not working
* Cloth now uses the original derived mesh for simulation and a new dm only for applying the simulation result.
* Reverted Campbell's temporary workaround r33406.
2010-12-01 12:23:10 +00:00
bfe2447f57 partial fix [#23265] matrix_world rna path is visible but returns 0 to drivers without error however accessed
this report raised a number of problems with rna paths, while we still dont have multi-dimensional array access, invalid paths were being accepted which confused things.

rna path resolving code was accepting all sorts of invalid input because atoi() just returns 0 for non numeric input.
now check if 0 number == '0' character.
2010-12-01 10:17:31 +00:00
2ada145fa4 fix for crashes trying to resolve paths "location[]" or "location.." 2010-12-01 09:12:54 +00:00
fd7728883a increase the reference counts when setting default scene compo nodes else removing them can set the user count < 0. 2010-12-01 08:49:08 +00:00
3e173f4d21 disable redcode support for cmake & scons-freebsd 2010-12-01 07:25:59 +00:00
8a761a374a quit blender if the first X11 window fails to open.
mainly just to avoid a segfault so the user knows its not a bug.
2010-12-01 07:15:05 +00:00
f5f332892c workaround [#24958] Cloth pinning not working
detailed explanation as to why this is needed in report.
2010-12-01 05:59:11 +00:00
f801b2bcba bugfix [#23406] DPX Images load darker then saved, UI broken.
- a linear float buffer was being created and saved into a non-linear DPX/Cineon file.
- removed the UI since the settings are not used at the moment.

added a utility function IMB_float_profile_ensure(), which returns a float buffer in the requested profile, using the existing if needed or returning an allocated buffer if the profile is different to that of the ImBuf. - Useful this case where the save function has its own linear setting.
2010-12-01 02:54:10 +00:00
ad0dd98f26 fix for some mistakes in recent commit. 2010-12-01 02:40:13 +00:00
b5ba824cf2 patch from JacobF on IRC, copy smoke settings. double checked none of these are used for runtime. 2010-12-01 02:28:08 +00:00
0184c62b63 fix [#24990] When extruding bones the outliner does not immediately update
also changed notify functions for new bone, hide/reveal, switch direction and parent.
these used ND_POSE or ND_DRAW, replaced with ND_BONE_SELECT since this changes editmode bone hierarchy/selection.
2010-11-30 23:50:21 +00:00
89abb9f2d2 bugfix [#22638] Alpha channel not saved when using texture paint
check for alpha channel while saving images that have been painted onto.
It would be nicer to do this while in paint mode except this isn't so simple with project paint using multiple images at once.
2010-11-30 23:38:31 +00:00
d9c23d8d5d minor console changes.
- remove report argument from console functions.
- don't update the scroll area while drawing, do this within operators instead.
- dont redraw while selecting text unless selection changes.
2010-11-30 22:39:41 +00:00
df6169dada bugfix [#23423] Multi-window : closing game windows cause blender crash
detect closing window while the BGE runs and exit without crashing, as if Esc was pressed.
2010-11-30 21:51:03 +00:00
17cd5811e7 Smoke now uses only one point cache where both normal and high resolution smoke are stored together:
* Separate caches were causing quite a lot of problems both in principle and practice.
* For example it doesn't really make sense to have different frame ranges for normal and high resolution smoke, but this was fully possible before.
* Also to fully bake the smoke you had to do a "Bake All Dynamics", which completely defeats the whole point of the feature!
* As a result of this change the smoke cache usage is much much simpler and less error prone.
* This is quite a big change, but hopefully there should be less rather than more problems as a result :)

Some other related changes:
* Changing the cache name now works for disk caches properly too, it now just renames the cache files so should be faster too!
* Smoke is now always forced to disk cache with step 1 on file load as there were some strange cases where smoke was trying to use memory cache.
* Disabled smoke debug prints from console.
* Disabled changing smoke parameters when smoke is baked.

Note to users: The unfortunate side effect of this is that old high resolution simulations have to be baked again, but in return you get much better and more logical functionality. Sorry none the less!
2010-11-30 21:31:18 +00:00
005feca62d minor rna changes
- set matrix values not to be animatable
- some matrix values were still accessed as 1d arrays.
2010-11-30 20:22:26 +00:00
435f0ee153 missing NULL check in own recent commit, 2010-11-30 19:12:17 +00:00
a1b8bc93e2 remove unmaintained windows and unix game engine plugin code. 2010-11-30 19:08:44 +00:00
7ca3ff1ff1 SVN maintenance. 2010-11-30 19:06:34 +00:00
42d6603cae Add option for CMake to build libredcode, also use CODEC prefix for ffmpeg, quicktime & sndfile options. 2010-11-30 18:52:39 +00:00
c22dcbdd64 Bugfix #24976
Compositor: MultiLayer image node: on using layer menu, the entire
multilayer file got freed, causing node to collapse and open full
again after a composite.
2010-11-30 18:46:34 +00:00
236a11ca63 misc small changes.
- commented unused View3D->flag's
- popup dialog now centers over the mouse
- only overwrite image alpha with render settings on save if saving the render result.
2010-11-30 18:07:44 +00:00
61c0de3f48 Bugfix #24986
When duplicating a mesh that has a mask modifier on it,
the invert option of that modifier dis not copy over.

Report + fix provided by Jacob F. Thanks!
2010-11-30 15:39:38 +00:00
79d9023f55 bugfix [#24974] "select all" in weight paint -> face selection mode selects all bones instead of all faces
face mask mode overrides pose mode keys. also removed function call from transform code.
2010-11-30 05:15:58 +00:00
050e863560 bugfix [#24798] Texture panels are shown in wrong order 2010-11-30 01:03:17 +00:00
51a66c27f3 replace overly verbose matrix creation for BGE camera, typo fix from MikeS. 2010-11-29 20:57:02 +00:00
a5cac5434a bugfix [#24969] Python Console bug: inserting a large text leads to strange caret behavior
Caret wasn't wrapping.
2010-11-29 20:42:03 +00:00
c8422f0de3 False should be with capital in Py
(IRC report by dsavi)
2010-11-29 18:58:49 +00:00
b195cdd14c Makefile fix, the getversion.py was using minor release numbers,
which conflicts how paths work in BLI bundle detection.
2010-11-29 17:23:06 +00:00
01169dd632 Bugfix #24971
Outliner: if bottom slider was hidden, you still could not click there
on items. Code was using region-mask to clip input, but the mask is not
adjusted for sliders now (keeps view same).
2010-11-29 17:10:46 +00:00
7286b7a7ca SVN maintenance. 2010-11-29 17:09:33 +00:00
1c0d7d6815 For all buttons with search-menu option, the button will show a
red-alert drawing when input doesn't exist. Will help debugging
when messing with uv-layer names, vertex groups, etc.

Also closes bugreport #24905
2010-11-29 15:25:06 +00:00
8272ec2302 Description of BLI_strncpy() and BLI_strdupcat() were mixed up.
IRC reported by OniNiubbo
2010-11-29 14:29:30 +00:00
ceebc3598f From the todo:
Save or load .blend file shows cursor 'wait' again. Is clear to indicate
a totally blocking operation.
2010-11-29 13:14:51 +00:00
1dd1cea06e fix for error when changing DISBALE_PYTHON -> WITH_PYTHON,
This define wasn't set in some parts of the BGE causing problems with the view matrix.
in CMake define for the entire BGE fixes this.
2010-11-29 07:56:45 +00:00
04d3741947 Fix [#24964] HISTOGRAM: Inconsistency in spaces 2010-11-29 07:37:20 +00:00
5fe2a16385 Fix [#20241] half-transparent objects in volume have no shadow. 2010-11-29 07:07:08 +00:00
e8397e6193 include headers in cmake source, added a script to check for consistency, reporting missing headers & C files.
this is important so IDE's using CMake integration always get blender headers. - QtCreator & MSVC for eg, probably others too.
2010-11-29 04:35:56 +00:00
4c82be95fd Fix:
[#24170] Camera inside volume error
[#24838] Light inside Volume material drops on it's walls - it may be double

Problem in a previous bugfix commit, reverted back, the original bug is still fixed too.
2010-11-29 01:05:20 +00:00
ab713ee1f4 fix [#24921] Crash after inserting keyframing UV coords and changing frame in edit mode
zero length arrays were still having their members accessible.
2010-11-29 00:18:26 +00:00
2dcec22627 bugfix [#24947] Animations data replaced by the first animation (fbx exporter)
this feature was ported from 2.5x but not tested, referring to the wrong object when assigning actions.
2010-11-28 23:07:49 +00:00
49102a84d1 Variable declaration in code, not allowed!
Also made it NULL, looks nicer than 0 ;)
2010-11-28 18:54:43 +00:00
d01054da0f Bugfix #24933
Compositor: Texture node only allowed 1 user, with more nodes using it
there was a thread conflict, using same memory for writing values.

Also: brought back the original intention for texture nodes, which is to
be using a "procedural image", not allocating memory for a buffer, but
only allowing to read per pixel. Commit in 2007 (!) allocated full buffers
for texture nodes, without using them even.
2010-11-28 18:34:16 +00:00
510920a299 == Sequencer ==
This fixes Orig Dimension display (mostly).
* orx, ory both didn't get calculated, if dimension already matched
* putting them into Strip instead of StripData ment, that using images
  of different dimensions in one strip could lead to incorrect results

Still TODO: on file open, timeline display happens before preview 
display which means: orig_width and height are calculated after the 
first draw of N-keys dialog. You have to hit refresh (or scrub one 
frame) to get the right values displayed.
2010-11-28 18:23:21 +00:00
3f6eb67b77 == addons ==
After discussing with campbell, I'm adding a menu in the addons panel to help people to find the addons development pages
This should give more visibility to the bf-extensions project so that people know where they can share their scripts "officially".
2010-11-28 18:22:23 +00:00
b7d0715284 Bugfix #24953
Compositor: If scene render size changed, a Texture node didn't get tagged
to re-render, using previous size instead.
2010-11-28 16:36:36 +00:00
6b4e7e8def bugfix "Export UV Layout" stalls when saving file in 2.55b
remove duplicate UVs on export to avoid long ztransp filling times - common on faces which have no assigned UV coords.
2010-11-28 13:39:39 +00:00
2840d524e0 fix for fix [#24955] Generating UV-Images within blender (Alt-N) not possible
We had 3 reports of not being able to add images in editmode which was a workaround for redo in editmode bug.
Rather then having it use operator redo, just give an OK button.
2010-11-28 12:38:29 +00:00
34ea1cf0b2 minor changes to the python api.
- pep8 script was giving an error on non utf8 scons source files.
- use PyList_SET_ITEM macro when list type is ensured.
- all mathutils types use subtypes to create new types when available.
- use defines MAT3_UNITY, MAT4_UNITY to initialize unit matrices.
2010-11-28 06:03:30 +00:00
9d3a17922c Detect Gallium driver. Extend NPoT workaround to opensource drivers. 2010-11-27 19:59:00 +00:00
f973be9fe4 Bugfix #21385
Blender MultiLayer openEXR files now save with correct scanline order.
Code also provides backward compatibility. Also thanks to Troy Sobotka!
2010-11-27 19:33:40 +00:00
1e579c780c [#24935] Proportional translation size stuck to none
Adjust hard and soft limits on proportional size operator property.

Prevent zero in old files with reset if under hard limit (in tools settings).
2010-11-27 19:18:13 +00:00
6c7403b8bd bugfix [#24944] Crash on attempting to keyframe HSV color
prevent eternal loop
2010-11-27 18:30:56 +00:00
02cc80691d python access to driver namespace, rather then have a textblock defined for drivers allow scripts to add functions directly.
- bpy.app.driver_namespace, read-only dictionary, edit in-place.
- reset on file load and new file.
- on errors the namespace used to be reset, this should not be needed.

simple example.

  def driverFunc(val):
    return val * val
  bpy.app.driver_namespace['driverFunc'] = driverFunc

... now all drivers can access this function.
2010-11-27 02:39:51 +00:00
4a804855b2 console text underscore would draw outside the view for larger font sizes. 2010-11-27 00:56:18 +00:00
5e6c0bcded fix for fix r33330, bug [#23118].
combing hair the view matrix wasn't updated so depth comparison was incorrect.
2010-11-27 00:23:06 +00:00
dbf01ba68c Particle draw was calling glColorMaterial(...) after glEnable(GL_COLOR_MATERIAL), this is documented to be incorrect.
On my system it set the ambient color value to 1.0.
2010-11-26 23:38:23 +00:00
d47a519cbb added option to turn off Text anti-aliasing in the UI
(userpref->system), with a great help from brecht (its been way too long
for me).

However as brecht pointed out that the non-AA text is slightly lareger
then AA'ed Text :S, i did not do anything about this as this commit was
just the option not the text drawing.

this commit also makes it possible to do all kinds of UI textrender options
2010-11-26 22:12:46 +00:00
8f4d8ad5bc Fix #24914: 3D text glitch and crash
Crash was caused by invalid utf8 sequence pasteing from the clipboard.
Prevent memory corruption by giving utf8slen() the same rules of bytes checking
as utf8towchar() does.
2010-11-26 18:13:27 +00:00
16feaf02af remove support for rna resolving paths with collection['name'], only support collection["name"],
added r31826.

This is valid python syntax but I rather be strict with data path format else it becomes harder to parse them if we try to support this.
it means checks like fcurve.data_path.startswith('pose.bones["SomeBone"]') isn't ensured to work, since blender uses "" quotes everywhere for keyframe paths I dont think its an advantage to allow users to do it differently.
2010-11-26 17:25:06 +00:00
d6a90a6bff Rigid Body Joint Constraint:
* RNA fix for my last commit, we want the last 3 items of the array, not the first 3, added get/set functions.
2010-11-26 17:11:16 +00:00
fb42188c18 Update nurb keyindex data when subdividing -- shape key data wouldn't be lost anyway 2010-11-26 17:08:22 +00:00
cfd3b11630 fix building blenderplayer and a divide by zero bug with the console view. 2010-11-26 17:07:31 +00:00
cf0820d628 change monospace font to be an extern, not good final design but better then loading the same font 3 times.
need to load twice still because render may use the font in a thread.
2010-11-26 16:33:42 +00:00
782d7b312f "Fix" for [#24934] Particle single user crash
* Changing anything related to particle settings shouldn't be allowed when in particle mode, so disabled the buttons in ui.
2010-11-26 15:37:08 +00:00
4efffc90f9 Bug fix: voxeldata texture extension didn't work.
* Code was using tex->extend instead of vd->extend.
2010-11-26 14:33:44 +00:00
f2c9eff803 lasso select wasn't comparing the depth with particle selection, where border and circle select do. 2010-11-26 13:40:47 +00:00
a44acdf348 bugfix [#23118] Blender freezes when combing hair - OS X path changes related?
- glReadPixels() was running to get the depth on each pixel, this works fine one some cards but was locking up on OSX.
- Replace glReadPixels() call with a single call to view3d_update_depths() right after view3d_validate_backbuf(), so the depths are only read once.
- Unrelated to the changes above, but should improve performance: view3d_validate_backbuf() was being called on every redraw while combing, now only call once when combing starts.
2010-11-26 12:57:35 +00:00
c2cd9ab039 remove calls to update the depth buffer while in particle editmode, this calls glReadPixels() for the viewport which is slow on some systems and the depths are currently not used. 2010-11-26 12:38:42 +00:00
d3ec9753c4 freeing all free GPU buffers every frame could be a performance issue and is not necessary 2010-11-26 11:20:03 +00:00
Dalai Felinto
b8572527df follow up of "Bugfix #23576" (Logic UI) - replacing hardcoded values by RNA_struct_is_a + making rna_sensor future proof 2010-11-26 03:58:31 +00:00
ca6cc30368 Fix #24855: disabling shadows didn't disable AO/env with ray transparency
and AO multiply mode.
2010-11-26 03:50:14 +00:00
Dalai Felinto
9d9a88348e BGE Bugfix: [#24926] Sensor 'Radar' les axes X+ et Y+ ont été inversé. (oui, a french bug report :)
we were using SENSOR_RAY for the radar sensor axis. However the Ray axis is inverted (God knows why) so I created a set of defines only for radar sensor.

Also I thought it was a good idea to replace some hardcoded values in Radar and Ray codes by their defines in DNA_sensor_types.h (similar to what Benoit did for Armature Sensor, so I see no problem on that).
2010-11-26 03:37:08 +00:00
886e7a7f45 Fix #24923: tweak falloff strength tooltip to apply both to AO and indirect. 2010-11-26 03:31:12 +00:00
9a6fee750a Fix #24775: boolean modifier crash in rendering on Mac. Problem was that this
ran out of stack memory, now it passes some arguments by reference instead of
by value to use less stack space.
2010-11-26 03:26:57 +00:00
a7cce73fd0 fix [#24900] Texture paint mode broken
own commit r33070 broke this.
2010-11-26 00:52:37 +00:00
b0df3a29f2 ATI X1xxx gfx cards (R500 chipset) lack full support for npot textures although they report the GLEW_ARB_texture_non_power_of_two extension. 2010-11-25 22:15:04 +00:00
5d0b3a5230 Smoke domain resolutions were calculated wrong for non-cube domains in some cases. 2010-11-25 22:13:40 +00:00
2b4cf2ac8d bugfix while looking into [#24900], color wasn't being set for face-mask mode. 2010-11-25 21:59:12 +00:00
6f1077ed2c bone roll recalculate, option to use active bones Z axis. 2010-11-25 20:50:50 +00:00
95d8cfc25d bugfix [#24907] bone roll z up broken and python script showing correct method to roll bones
from Josh Wedlake (joshwedlake), who provided a reference script used to apply changes in ED_rollBoneToVector().

- Obvious bug fixed where Z-Up didnt work right.
- More align axis options to Recalculate Roll operator: X/Y/Z/View Axis & Negate.
- Axis Only option, ignore the axis direction, use shortest rotation to align bones.


ED_rollBoneToVector() changes:
- would give bad roll when the axis wasn't normalized or perpendicular to the bone.
  some callers accounted for this but not all.
- option to align to the axis but not the direction.
2010-11-25 19:49:07 +00:00
d2a2cab975 Fixed bug with Text menu in font edit mode 2010-11-25 18:22:59 +00:00
b9b9ac75bc fix for https://projects.blender.org/tracker/index.php?func=detail&aid=24442&group_id=9&atid=498
[#24442] GLSL + VBOs
2010-11-25 17:36:03 +00:00
dd8a55b23f new vectors that were the result of functions or operators were not using the same subclass as the vectors they were derived from. 2010-11-25 16:00:06 +00:00
c8fb984ee6 bugfix [#24916] Blender Crash after inappropriate Merge-Command 2010-11-25 15:03:36 +00:00
2d0a1f4de2 Redraw 3d view when new object was added (NC_OBJECT|NA_ADDED notifier)
This fixes one issue from #24914: 3D text glitch and crash ("delayed" 3d view refresh)
2010-11-25 14:56:02 +00:00
56f8ced34f == console ==
- banner formatting

== sphinx doc ==

- bpy.data: put the example below the documentation itself
2010-11-25 14:55:03 +00:00
e3fa2d8be8 found some errors while looking into bug #24909, in exceptional cases where the PNG could not be saved it could leak memory and not close the file. 2010-11-25 14:00:11 +00:00
22b3f2228f Possible fix for the issue that came up in [#24890] Vector Blur node is Buggy
* Apparently some compilers don't respect proper operator precedence, so added some parentheses around to make inline conditionals unambiguous.
2010-11-25 11:38:55 +00:00
728ad84c66 Fix polling order for ui panels in netrender.
Was broken by r33071 but order wasn't optimal even before. Should be snappier now (at least only check if correct render engine is selected).
2010-11-25 01:25:47 +00:00
9f18e066fc Spline IK Bugfix:
Binding code had off-by-1 error, which meant that when "Even Divisions" was disabled the length of the wrong bone would get used. 

This error was most noticeable when the lengths of the bones were quite different - for example, a chain with 3 bones of increasing length. Thanks to "Julius" on BlenderArtists for catching this. Cheers!

---

Also, simplified the binding code loop a bit to prevent this sort of error in future.
2010-11-24 23:36:36 +00:00
49f63589ab OSX: Patch associated with Python update to 3.1.2.
Thanks to Jens Verwiebe for making the build and the patch to make the Game Engine build again with it.
2010-11-24 21:39:07 +00:00
9371a800b7 drivers could reference invalid index values outside the bounds of the array. 2010-11-24 21:33:07 +00:00
77e3d5dfb4 define UNUSED() locally for mmap_win 2010-11-24 20:56:25 +00:00
c5f7207948 fix for crash introduced r33257, also tag some vars as unused. 2010-11-24 20:13:37 +00:00
6f71d575bf fix [#24893] Minor error message glitch 2010-11-24 19:06:56 +00:00
315879db11 bugfix [#24884] Loading any preset leads to crash
caused by own recent commit. update uv operator template too.
2010-11-24 18:37:54 +00:00
2c70b1785c bugfix [#24887] Crash on snapping verts on other object
now the derived mesh and the editmesh will always have matching faces.
2010-11-24 18:02:35 +00:00
82f019e954 close addon files, Py3.2 now complains when files are left open. 2010-11-24 17:29:22 +00:00
337f95dfab Bugfix #24887
Crash in snapping, bvh tree. Wrong check for numFaces here.
Fixed the crash by adding test for face pointer, but not sure
what the coder intended here. Needs investigation, left XXX remark.
2010-11-24 17:13:02 +00:00
bc9f1642bd fix for crash canceling fly mode. 2010-11-24 16:54:18 +00:00
117d11021e Bugfix #24847
When report error was drawn in info header, using border select
or paint brushes flickered. Was caused by Triple Buffer method
not checking for correct redraw case.

Also made report redraws less aggressive, it was drawing the info
header all over with 50 FPS for 10 seconds. Made it 20 FPS, and 
added code to only send notifiers for actual changes.

As todo note for future: animated UI options could get better
caching to cope with slower refreshes.
2010-11-24 16:34:38 +00:00
0daee3b8ed bugfix [#24882] fbx exporter Krash, screw objects and animations
fixed remaining issue with win32 paths.
2010-11-24 15:57:59 +00:00
6470078bca Typo in commit... for some reason rna_xx.c files compile without warning? 2010-11-24 15:05:54 +00:00
7c7307edbf add a window manager to files loaded from 2.4x in background mode. (partial fix for [#24882]). 2010-11-24 14:40:03 +00:00
c19dd6a7b2 Bugfix #23576
Logic Window: Actuator type options in menu didn't show special options
for Armature or Mesh when 'show selected' was used.

Dalai proposed a nice new RNA feature for inherited types, but with
only two exceptions handled, it was easy to code this check.
2010-11-24 14:34:16 +00:00
c7c034fedb Fix #24782: proxy armature Layer state not saved with file. Was in 2.4x but
not ported to 2.5x, implemented a bit different now to fit RNA better.
2010-11-24 14:05:53 +00:00
40d7da495e correction while looking into another bug, setup_app_data() will always free window manages if mode==0, but had left the contexts manager variable which could be used later. 2010-11-24 14:05:09 +00:00
16537d8dbc fix [#24879] "Feather" symmetry option in sculpt mode crashes.
rotate_m4() was being called with axis=0
2010-11-24 12:38:18 +00:00
4235a9ff02 when fail to read a blend, report the filepath too, less confusing when chaining together multiple blends. 2010-11-24 12:17:26 +00:00
8df8b42144 Fix for [#24877] Cloth + hair bug
* Particles needed the original index layer, but didn't ask for it.
2010-11-24 11:37:09 +00:00
2512c6ce88 Fixes for [#24862] Fluid Simulator issues
* Fluid baking (using the job system) didn't update the "lastgoodframe" anymore, so reversing the frames didn't work. Now the last valid frame is checked by going through all fluid bake files when "reverse frames" is selected.
* There was all kinds of fancy checks done in the fluid modifier for reading a different frame in different cases, but as the "lastgoodframe" was really not working I don't see the point of this whole code, so removed it for now. The new functionality is: if the fluid data for current frame exists use it, otherwise just return unmodified domain mesh without any fancy backup plans.
* There were also some errors on reading uncompleted files (scrubbing timeline while bake was running), so I made the fluid file reader just return null if the number of faces didn't correspond to to actually read data. Previously this just printed an error to the console.
2010-11-24 10:56:15 +00:00
05f2e47ff0 bugfix [#23871] OSX panel button bug (Python Namespace issue)
This is an annoying but which isn't a problem for Python because they don't execute multiple scripts, one after another (there is one __main__ and everything else is a module).

So when the __main__ module in sys.modules is overwritten, it decref's the module and clears the dictionary with _PyModule_Clear(), even though the modules dictionary is still in use.

Strangely this problem only happens with Python3.1.1 and Python3.2x svn but not 3.1.2

This commit restores the namespace after _PyModule_Clear() sets all its values to None.
2010-11-24 10:23:23 +00:00
Nathan Letwory
a5cecd8284 Remove library specification. 2010-11-24 09:13:59 +00:00
32eba0898b Reverting revision 33120, which added vram monitoring. The method used had some problems (especially in the freeing function). I will research an alternative solution and submit it to the tracker. 2010-11-24 06:27:07 +00:00
Nathan Letwory
c790b2c238 When exporting images also add the string name (attribute). This is optional, but it helps other viewers importing from Blender .dae exports.
Small request by factor in IRC.
2010-11-23 23:58:12 +00:00
250c2fe3e5 Fix #24834: curves extrude + bevel gave bad normals on rendering.
This happened when removing vertex normal flipping in the render engine. But
actually the normal of the first face in the curve was flipped on rendering,
because it used a different vertex order than other places. Also removed the
hack that computes a face normal only from a triangle instead of a quad.
2010-11-23 20:32:15 +00:00
c88991adee Small feature fix: zero-user blocks get indicated with "0" again in
browsing.
2010-11-23 19:06:54 +00:00
6c19670d7c Bugfix #24860
On entering editmode Curve/Nurbs, the undo buffer was not
correct; storing old Curve/Nurbs object name. This caused
for example the Operator tool redo options to fail; it added
another curve on first use (with user pref "enter editmode).

Solved with adding good undo push + nicer code for curve and
nurbs naming.
2010-11-23 17:28:41 +00:00
68b49aa981 use unit system for the grid floor (was only ortho before). 2010-11-23 17:14:03 +00:00
96dafef228 minor edits to exception formatting (remove ... or \n from suffix) 2010-11-23 16:45:17 +00:00
97488b0934 bugfix [#24871] Unwrapping with Smart Project give a bad result. 2010-11-23 16:10:20 +00:00
8686f46abc fix for typo in mathutils vec.to_track_quat() argument parsing. 2010-11-23 16:07:51 +00:00
c51d075b0e Changed some ui names for smoke parameters to make things less ambiguous. 2010-11-23 15:16:19 +00:00
513f0142fb Fix for [#19706] Smoke 'sticks' to Collision objects initial position
* Smoke got emitted inside collision cells, so it got stuck there.
2010-11-23 14:40:27 +00:00
620ba31e63 changes in own recent commit broke MSVC building. 2010-11-23 14:38:02 +00:00
0e9b664fce Changes to the ortho grid drawing based on discussion with Ton.
- ortho grid now draws scaled by the view3d 'Scale' setting, venomgfx noticed this was missing.
- so as not to confuse add scale next to unit display text, so rather then "Metres" it shows "Metres x 1.5" otherwise its confusing that grid lines are not in exact units.
- changed grid spacing to grid scale (needed for more logical behavior with units)
- when units are enabled grey out subdivisions.
2010-11-23 14:14:06 +00:00
4aeeee8819 Cached smoke wasn't being drawn on file load before going to simulation start frame. 2010-11-23 14:04:05 +00:00
8f37be3c0b transform snapping to a unit scaled grid was broken. 2010-11-23 13:28:13 +00:00
60d13818cf fix [#24870] ObjectActuator.offset_rotation in radians 2010-11-23 12:23:19 +00:00
ee1d2adc16 partial fix for [#23532]
- Python calling operators didn't run WM_operator_properties_sanitize() so enum functions called from python were given a NULL context.
- PROP_ENUM_NO_CONTEXT and PROP_NEVER_NULL used the same value in the enum (possible conflict).
2010-11-23 12:05:35 +00:00
855b83caec Particle fluid and boid settings didn't have a valid rna path, so they couldn't be animated. 2010-11-23 11:15:38 +00:00
ce2295999e use zero initializers instead of memset(), also change PointerRNA_NULL from an extern into a define. 2010-11-23 08:44:21 +00:00
225be0cf30 extensions_framework: fix UI drawing logic 2010-11-23 00:23:57 +00:00
8a4b42bee7 extensions_framework: fix UI drawing bug and some redundant code 2010-11-23 00:06:09 +00:00
e1506d1f12 Partial fix for #24773: Material Nodes - there isn't able to set keys on Mapping coordinates
Playback now works. The problem was that material/texture nodetrees were getting ignored completely, as I was assuming that all of these existed in the main->nodetree collection when in fact only the "group" nodetrees lived there. I don't really agree with this, but that's the way it is...

TODO: animation editor support still to come
2010-11-22 23:59:00 +00:00
4816f8fd00 fix for player with recent update. 2010-11-22 23:47:00 +00:00
6f90a38a54 error in own recent commit 2010-11-22 23:41:00 +00:00
837fedf372 fix for building with mingw/cmake 2010-11-22 23:25:21 +00:00
94e17ff01e fix for cmake if build flags are not defined. 2010-11-22 23:06:57 +00:00
3892bef1f1 Fix #24596: specular toggle on material didn't work correct. 2010-11-22 22:23:50 +00:00
166980b6fe fix [#24866] object/transform/align objects error 2010-11-22 20:54:26 +00:00
5e4f03ea08 bugfix [#23609] Lamp PointerProperty 2010-11-22 20:44:59 +00:00
01117ca27b Bugfix #24823
Color picker: RMB "insert single value" was inserting all three values.
Same case as yesterday, made code recurse into open menu to check for
active button there.
2010-11-22 18:51:40 +00:00
ce9ce42e38 More button alignment stuff: campbell had a script that was
drawing various cases. Fixed another one. :)
2010-11-22 18:41:08 +00:00
739b8f6a5c Bugfix #24856
Button aligning revisited. Now layer buttons draw OK too, and even 
better than before (missed a rounded corner!)
2010-11-22 18:11:40 +00:00
1d468c75e7 bugfix [#24805] bpy operator runs in wrong order or is ignored at all 2010-11-22 17:21:18 +00:00
d43b55a200 fix for triangulate OBJ export option.
reworked fix from Radu Danciu
2010-11-22 16:20:59 +00:00
4a20c386fd bugfix [#20768] Project Snap Broken 2010-11-22 14:16:11 +00:00
69246d9080 rna invoke function wm.invoke_confirm() for python access. 2010-11-22 13:43:51 +00:00
71079a47d3 find filepaths operator had blend file and search path swapped. 2010-11-22 13:32:43 +00:00
0191c2f776 Reverting fix for yesterday's commit that broke Undo. 2010-11-22 11:21:33 +00:00
f781780cc0 - blend_m3_m3m3 and blend_m4_m4m4 now support matrices with negative scales.
- python/mathutils api matrix.lerp(other, factor)
- new function mat3_to_rot_size(), like mat4_to_loc_rot_size but with no location.
2010-11-22 10:39:28 +00:00
77dff3f986 fix for fix r33219, reports. Set a valid WM after running UNDO.
[#24849] changing objects to another layer causes segmentation fault
[#24848] Using an operator outside of edit mode crashes blender
[#24844] Crash related to the subdivision (aka subsurf) modifier
[#24843] ctrl+z crashes blender
2010-11-22 06:18:49 +00:00
bb36378a3a rename hide_tooltips_python to show_ ..., tag unused variable with recent sequencer commits. 2010-11-22 05:36:49 +00:00
19e091ec5e User preference to hide Python references in Tooltips. 2010-11-22 00:10:32 +00:00
8f657c174d Fix: 8bit raw and 'blender voxel' voxel data texture formats didn't support relative paths 2010-11-21 23:36:29 +00:00
a0517e6338 == Sequencer ==
* documented and rewrote the render interface of the sequencer.
  (now, the geometry / render_type / etc. settings are stored within a
  seperate structure called SeqRenderData that is passed within the code.)

* that fixes
  * cache problems, since the caching system didn't keep track of
    proxy files vs. final renders.
  * is a necessary step, to bring back frame blending in speed effect
    (the SeqRenderData structure elements are already there)
  * will make motion blur render options available within the sequencer!

* this patch also fixes:
  * "easy retiming" using speed effects. (in Blender 2.49, you could 
    add a speed effect and resize the source track to retime it to that
    length)
  * adds labels for the Original dimensions for Image + Movie tracks
    (worked in 2.49, too)
2010-11-21 20:00:31 +00:00
a2dc1fe4b0 Toggle cyclic on when creating segment between first and last points of non-cyclic bezier 2010-11-21 19:29:08 +00:00
18d9f7cbbf Recalc handles after toggling bezier's cyclic flag when deleting segment 2010-11-21 19:01:18 +00:00
e006d187f4 Applying patch #24822: Select linked for curves as for meshes, CTRL + L version
With some own changes:
- Select pick moved to invoke()
- Used editsurfcurve_region_view3d as poll function for this operator
  due to ogl dependency

Thanks to Elia Sarti (vekoon)!
2010-11-21 18:50:53 +00:00
d016f52c21 Bugfix #22611
(Well, while testing this report I found this fix!)
Blender could crash after rendering a 2.4 or 2.5 file

The context before/during/after file reads is still fishy.
Need a more clear & clean mind to really check it from
scratch again.
2010-11-21 18:46:50 +00:00
01c6b6f1e9 [#22854] Objects lag behind mouse pointer when transformed (translated)
[#24652] Project vertices button showing in object mode and leads to wrong behavior.

Removing soft redraw (code is still there in case we need it eventually) on mouse move, now that events are compressed.
2010-11-21 18:31:00 +00:00
8a92513032 Bugfix #24837
Small typo, EXR option PIZ was typed as PIX
2010-11-21 17:32:57 +00:00
ca354a6a6f Bugfix #24825
Error in alignment code caused some buttons to draw not nicely
aligned, like the Frame rate buttons in Render properties.
2010-11-21 17:23:55 +00:00
5a37554b1e disallow disabling WITH_SAMPLERATE if any audio outputs are enabled. 2010-11-21 16:32:11 +00:00
c85c2746df WITH_SAMPLERATE option for cmake, without this playback wont behave right so this is mainly intended for developers who build without audio enabled. 2010-11-21 14:32:55 +00:00
5fff1a98a1 Fixed missed selection oulines for curves/surfaces/fonts/armature when texture shading is active 2010-11-21 14:05:18 +00:00
39b7bfe6bd - check IF WIN32 AND NOT UNIX (for cygwin)
- patch from Mike S to enable OpenMP and xcode
2010-11-21 13:41:43 +00:00
722376ed7b Bugfix #24824
Color Picker: when inserting keys (right mouse menu), the colors didn't
change for buttons to indicate such. The function that sets the flags
returned too early.
2010-11-21 13:01:22 +00:00
cd2ab75b73 - include pthreads for win32 globally (as with opengl).
- MSVC CFLAGS were being set by only checking WIN32, (breaking non-msvc win32 builds)
2010-11-21 09:10:50 +00:00
f580d9c33b - some more rna range corrections
- correct exception messages for mathutils constructors.
2010-11-21 09:06:27 +00:00
cb031ec092 incorrect argument parsing for python opengl module bgl.
unsigned byte/short/int were being passes as signed values which would raise an overflow error if a range greater then the signed value was used.
2010-11-21 05:35:29 +00:00
72279e1c92 fix for RNA ranges exceeding the range of the type (INT_MAX used on short's for eg). 2010-11-21 03:45:35 +00:00
8abb58b7ce Changing KX_Camera.perspective didn't actually change the camera's perspective because the camera's matrix was cached. The setter for KX_Camera.perspective now invalidates the camera's matrix so it's recomputed with the change. 2010-11-21 01:55:08 +00:00
ac2e77cac5 [#24827] Crash when auto-keyframing while playing animation
Reported by André Oliveira

Need to pass valid context to autokeying callback function.
2010-11-20 21:43:16 +00:00
06fdd5b95d Bugfix #24792
On file save, the 3d view thumbnail creation caused changes in lighting
enables. Solved with a glPushAttrib() and pop.
2010-11-20 19:20:27 +00:00
bf14b21481 == Multires ==
Fixed bug #20620, "VertColors and Flat/Soft imported from 2.49 are wrong
(MultiRes)" reported by Manuel R.

* Added function to load level-0 vertex colors
* Added function to load level-0 face flags
* Warning: the 2.5 multires modifier doesn't support multires vertex colors
  or multires face flags; that data will be lost if you import it into 2.5.
2010-11-20 18:54:58 +00:00
6eaf0ac8be Cancel edge slide on invalid selection.
Patch by Shane Ambler
2010-11-20 18:46:36 +00:00
4f3d80e706 Bugfix #21028
- Image Editor, "New", gave for each tweak in redo menu a new Image
  when Object is in Editmode. This is a limitation of our current
  undo system. Marked this issue in the wiki todo.
  Solved by adding a poll in operator that prevents this to be called.
  (a bit annoying, but the error is worse!)

- On assigning a new image texture to faces in Editmode, no redraw
  happened in 3D window. Added notifier for it.
2010-11-20 17:31:59 +00:00
03e943be52 Allow keyframing editmode curve values, also fix a bug where adding a new curve would always use object mode spline list but removing would use editmode when set. 2010-11-20 17:28:05 +00:00
7b16d7496d - report python script errors to blender report system, or through operators reports (when using operator callbacks).
- when python operators fail to execute they were returning RUNNING_MODAL, now return CANCELLED

now when an operator fails it gives an error popup as well as a message in the terminal.
2010-11-20 16:39:15 +00:00
6e5ccba6da Bugfix #24801
- Reading 2.4x files could cause print "missing region type".
  Appeared the 2.50 do_versions patch differed from default region
  definitions
- Sometimes editors showed wrong button for type browsing.
  Was because variable wasn't correctly reset on saves.
2010-11-20 16:00:36 +00:00
dcd5d7b99d region.tag_redraw() broke building with the player. 2010-11-20 14:39:03 +00:00
8c6c6d01f4 WITH_OPENJPEG wasn't defined for CMake or SCons, which meant blender couldn't save jpeg2000 images from the file selector.
also fixed typo in jp2.c
2010-11-20 14:19:21 +00:00
6aea182b1e Bugfix for [#24768] 6DoF Constraint options missing.
* Added the options in UI and RNA 

Funny Note: This was on my own to-do list (see commit 20577 in the py file from 2009-06-02 when I ported the UI from C to Python) :P
2010-11-20 09:48:51 +00:00
78cd971bac - smoke wasn't closing the file of loading a tile had the wrong length.
- missing break in operator context switch meant RGN_TYPE_CHANNELS was always being overwritten with RGN_TYPE_PREVIEW when calling operators (from r26692)
2010-11-20 07:51:39 +00:00
de9bb343cf fix smoke memory leak with OpenMP disabled. 2010-11-20 07:40:50 +00:00
35014aa741 - add python/rna function region.tag_redraw()
- removed print which was before NULL check, (possible crash)
- add execute hooks for the python console (not used by any scripts yet)
2010-11-20 05:11:10 +00:00
593815b23f reloading addons wasn't working. 2010-11-20 04:18:06 +00:00
03d8fd4616 - use relative imports for packages
- reload() has been removed from pythons builtins. use imp.reload() instead (still need to apply globally).
- fixed own mistake, not ignoring 'filter_glob' as a keyword argument (broke fbx, obj, 3ds export)
2010-11-20 02:56:58 +00:00
96952b83fa patch from Shane Ambler, free memory when failing to create slide verts. 2010-11-19 17:29:51 +00:00
e8647ff5c7 bugfix [#24812] Cannot change top/left/front views in quad view after camera change 2010-11-19 17:16:25 +00:00
b2a227b442 Tsk! Circle, cross and axis draw types for particles weren't using the particle draw size. 2010-11-19 16:19:15 +00:00
64e8035d0b Tsk! Minimum value for particle draw size is 0 (default size). 2010-11-19 16:19:07 +00:00
257a2553c0 Fix for [#23696] Receive Transparent produces shadows in diffuse pass
* Even Ton couldn't remember why that code was there, so problem solved by removing the code :)
2010-11-19 15:17:33 +00:00
7689ac75ad fix for error in recent commit. 2010-11-19 11:57:10 +00:00
a04bbb2374 use CMake's OpenMP built in detection rather then defining flags ourselves. 2010-11-19 11:33:12 +00:00
47541fe47e fix [#24810] Mist Settings Are Not Visually Updated When Camera Displays Mist 2010-11-19 11:10:56 +00:00
506e692263 fix [#24804] filetring of files doesnt work for import/export 2010-11-19 10:33:44 +00:00
7358a95c8a bugfix [#24807] nan pixel on Word BG with Angular Map coord texture
also avoid divide by zero with an empty raytree
2010-11-19 10:24:14 +00:00
ba36dd3cc5 "Fix" for [#24743] Strand Shading: Distance slider gives different results even when greyed out
* The actual flag was set at render time, was not supposed to be editable manually.
2010-11-19 08:37:19 +00:00
53d0bdd6b3 Possible fix for [#23982] Display update with animated nested custom ID properties
* Any property area can have animated properties, so redraw the area on frame changes regardless of the specific property area type.
2010-11-19 08:17:57 +00:00
3066d82662 patch [#24800] Make scene type buttons from material preview optional
from Wenzel Jakob (wenzel)
2010-11-19 07:46:23 +00:00
ab72823917 edit on last commit, for calculating drivers on obdata just check for animdata rather then the object type.
also use switch rather then if checks.
2010-11-19 07:40:17 +00:00
39de1914ab bugfix [#24796] Drivers are ineffective on Text & Curve obj. geometry parameters
also added note that adjusting bone radius changes the parent bone for connected child bones, and fix typo on failing to read startup.blend (both pointed out by MikeS on IRC)
2010-11-19 07:31:24 +00:00
18200f5f87 bugfix for pivot constraint.
- no rotation resulted in NAN location.
- subtraction of pivot done in wrong order made the constraint give odd results when rotating on more then 1 axis.
2010-11-19 06:21:39 +00:00
844e63f3b6 Fixing a crash when dynamically loading a scene that contains a bone parent. 2010-11-19 04:06:06 +00:00
d4a2972a21 bugfix [#24803] Export UV Layout in PNG (default) corrupts Blendfile
Removing a scene would set the active scene, assuming the scene removed was the current scene. This broke UV Export which used a temp background scene.
2010-11-19 03:45:45 +00:00
c1664dd78e [#24802] Invert vertex group not inverting armature modifier influence
the armature vertex group options only apply to Multi-Modifier, rename and edit the UI to make this clear.
2010-11-19 03:09:51 +00:00
5a09368957 use 'const char *' for imbuf and file ops. 2010-11-19 02:14:18 +00:00
0b74aab939 remove unused argument. 2010-11-19 01:06:46 +00:00
b83cc77b14 Bugfix #24795: Typo fix in particle_system.c
Also, fixed indention in armature.c (stupid space-based indention)
2010-11-18 23:48:55 +00:00
71721f02fc Algorithm fix for fluid particles:
* The SPH fluid particle algorithm was implemented a bit wrong. This problem could for example result in the fluid moving sideways after being dropped straight to a horizontal collision surface, a very big no-no as far as real world physics are concerned!
* After some extensive code shuffling the algorithm is now much more true to the paper it was implemented from, and more importantly now the physics should be correct too!
* The main thing was that fluids calculations can effect many particles simultaneously, so just a single loop through all particles can't work properly. As a side note this also means that the actual fluid algorithm can't be made threaded :(
* To make things work I also had to reshuffle some general particle physics code, but there should be no functional changes what so ever to other physics types, so poke me immediately if something strange happens.

Note to users: these changes will most probably effect the way previously done sph fluid simulations look, so some parameter tweaking will be needed to get things back looking the way they were.
2010-11-18 19:12:36 +00:00
aef3e99eab Bugfix #22052
OpenGL viewport render gave squeezed results in cases.
Reason: some graphics cards only give offscreen buffers in multiples
of 256 or 512 (my case). 

Current fix uses the actual size returned by graphics card, which
is also safe for too large renders.
More elaborate cropping or matching is for another time.

(Added printf for feedback on this, might disappear)
2010-11-18 19:11:05 +00:00
e76074da0b Feature fix
When using Material Nodes, there was no indication in Material
Property window which node was active. The context/channel widget
now shows this.

Better would be to be able to browse nodes in this list, and
to have option to preview only this material (not node tree
result). Enough todo for future :)
2010-11-18 16:38:32 +00:00
23fbce5a5f bugfix [#22615] Opening a blend file in python (bpy.ops.wm.open_mainfile() (r29489)
[#22557] bpy.ops.wm.read_homefile() causes segfault (r29372)
2010-11-18 16:33:13 +00:00
3ae670fc02 fix [#24786] Setting Rotation Units to Radians doesn't affect the UI [33146] 2010-11-18 14:10:09 +00:00
4045e838df missed removing the file for scons. 2010-11-18 13:52:09 +00:00
95e7417e0a remove unused classes. 2010-11-18 12:54:05 +00:00
da1f288f50 rename libs internal libs for CMake + SCons (used in MSVC project files)
for game engine use "ge_" prefix & make names generally more descriptive.
2010-11-18 11:42:05 +00:00
8d77002ae7 patch [#24736] 3ds import hierarchy
from Dominique Lorre (dlorre)
- fixes [#24626] 3ds import assigns wrong positions to objects
- spec info http://www.the-labs.com/Blender/3dsspec.html, http://www.martinreddy.net/gfx/3d/3DS.spec

This patch adds parent/child support to the 3ds importer.
2010-11-18 10:36:14 +00:00
fd3c8214d0 Bug fix:
When 2nd window open, the code that tried to find an Image editor in the
the active window failed.
2010-11-18 08:44:50 +00:00
26cd3fd293 Bugfix #24781: Can't use rest position / pose position on linked-group proxy armatures 2010-11-18 05:45:21 +00:00
a3773b6ec5 bugfix [#24783] Strange shadows on beveled curve; goes away with modifier
this bug wasnt in 2.4x, suspect this happened when normal flipping was removed.
2010-11-18 05:35:04 +00:00
223e70467e bugfix [#24777] Scale both markers and keyframes at the same time?
sync marker option worked for translate and extend but not for scale in the dope sheet.
2010-11-18 05:05:06 +00:00
48524d6e91 fix [#24780] Metaballs are not drawn correctly in new scenes
this is a can of worms, at the moment blender depends on broken behavior for metaballs:
 find_basis_mball() can return a metaball object that fails a is_basis_mball() check which makes this logic very confusing (added note about this in mball.c).

Metaballs needs a refactor however at least make drawing fail consistently,
For wire draw is_basis_mball() wasn't being checked, for solid drawing it was (hence the strange wire frame).

For now the motherball needs to exist in the main scene else it wont work.
2010-11-18 04:26:50 +00:00
7045ef617f - many settings in a new scene didn't match the startup.blend defaults, copied into scene.c.
- view3d metaball panel wasn't updated for rna name change 'location' -> 'co'
2010-11-18 03:03:17 +00:00
50778a3ea5 store the view align setting even if its disabled & don't edit the view quat when getting a euler from it. 2010-11-18 00:26:00 +00:00
9183f20fb4 extensions_framework: lots of docs and code formatting to be more pep8-like 2010-11-17 21:28:22 +00:00
b99a11bc3c Bugfix, irc report by lmg
Toolbar:
Operator 'add object' didn't show checkbox for "align to view" if such was
set in user preferences.
2010-11-17 18:05:33 +00:00
ab968fd6eb bugfix [#24690] Scene.frame_set() breaks pose restore
scene.frame_set() was sending out a frame change notifier which would update the scene loosing any un-keyed changes after a script ran.
for now use a window redraw notifier.
2010-11-17 17:38:56 +00:00
5f4f4e607b Bugfix #24767
Operator redo in 3D window now moves context to the main region,
makes knife cut work (and probably others)

Todo: this callback should be shared with other redo panels. On the
todo list.
2010-11-17 16:25:30 +00:00
c8bcabaf40 bugfix [#24685] Changing mode bypasses undo suppression
Editmode undo operator was using the operator OPTYPE_UNDO flag as well as its own EM_DO_UNDO option.

This gave 2 problems.
- python suppressed undos would fail (as in the report).
- Undo push was called twice on exiting editmode for no reason.

Use the operator undo in this case.
2010-11-17 15:16:49 +00:00
5a37333053 fixes from r33127 2010-11-17 14:36:19 +00:00
7bd944795f fix [#24762] Bezier Point Radius Cannot be Set When Curve is Created
this could be set in 2.4x, no reason to be readonly.
2010-11-17 12:59:59 +00:00
17aa5ae796 bugfix [#24766] Crasher on inserting keyframe on Bezier points [33126] 2010-11-17 12:52:56 +00:00
376d129dc6 bugfix [#24671] Operators called from Python Leak Memory
This problem is caused by returning Modal from a non-modal operator.
2010-11-17 12:32:39 +00:00
673ed8b50d Bugfix for previous commit.
Tweaked keymap for Graph Editor Ctrl-LMB so that the popup menu for displaying reports won't get dismissed immediately. Changing keymap here from KM_PRESS to KM_CLICK
2010-11-17 12:16:34 +00:00
f713761039 Keyframing Operators: Improved Error Messages
* Keyframing operators now use the reports system for displaying all its error messages. 
- The benefit of this is that users no longer need to check the console for error messages if keyframing fails.
- Unfortunately, reports are not currently viewable in any space/view in Blender, so...

* Added a temporary operator (UI_OT_reports_to_textblock), which can be accessed in the UI from the button which appears in place of the icon when more than one report exists. This dumps the current list of reports to a textblock "Recent Reports", from which they can be viewed. 

This isn't really nice, but at least we now have a way to view these again, which makes debugging some things a pain.

* Bugfix #24606 - when trying to add keyframes to F-Curves with F-Modifiers already which alter the curve significantly enough that the keyframes will have no effect, there are now warnings which aim to alleviate any confusion.
2010-11-17 12:02:36 +00:00
91217f117f should fix building with collada. 2010-11-17 11:09:07 +00:00
51dcbdde03 use 'const char *' by default with RNA functions except when the value is flagged as PROP_THICK_WRAP.
Also use const char in many other parts of blenders code.

Currently this gives warnings for setting operator id, label and description since these are an exception and allocated beforehand.
2010-11-17 09:45:45 +00:00
acc883da83 - move cmake file for python.
- move bpy_array.c to bpy_rna_array.c
- minor syntax changes
2010-11-17 07:22:20 +00:00
fbcf01f9f7 cleanup the operator template and rename to operator_export 2010-11-17 07:00:14 +00:00
d0d16ecaee Fix #22645: Texture paint: soften tool does draw brushes
Disable projection painting for soften tools.

Also it looks like smear tools support projection in the code, so
enabled project paint menu for such tools
2010-11-17 06:30:06 +00:00
1bb98b4194 Adding monitoring for (approximate) VRAM used by textures. The information is currently only used in the profiling data of the BGE.
Here is a image of it in action:
http://www.pasteall.org/pic/show.php?id=6351

What it monitors:
  * VRAM used by textures created via bf_gpu and BL_Textures

What it does not monitor:
  * VRAM used by the Blender ui
  * VRAM used by 2d filters
  * VRAM allocated by the user via KX_Scene.pre_draw and KX_Scene.pre_draw
2010-11-17 05:28:25 +00:00
f791d74f10 writing single images from a render (own commit r33104), wasn't checking if the render was cancelled which would crash when writing the image.
also remove paranoid checks for writing TAGA, Other formats - BMP, JPEG, Iris don't do this.
2010-11-17 04:02:19 +00:00
02bbce8b6d bugfix [#24672] Bone.evaluate_envelope() is misleading
fix from Dan Eicher
2010-11-17 03:26:50 +00:00
d0f7184ab9 bugfix [#24761] minor bug - Modifiers don't "catches" Vertex Group renaming automatically 2010-11-17 03:21:50 +00:00
62f3bb8526 patch [#24760] Bezier handles update
from Dan Eicher (dna)

Made some edits to the patch because only the first spline was getting the updates.
also added path functions for splines and spline points (request from ZanQdo so splines can be keyframed).
2010-11-17 03:15:08 +00:00
2d6cf9ee6b the 'Multi' option was not being copied with the armature modifier. 2010-11-17 01:50:25 +00:00
98896d55d0 Fixing bad ui range in camera draw size 2010-11-17 01:15:31 +00:00
Nathan Letwory
12afa64de9 Fix [#24592] COLLADA imports only one special node per type per node
Reported and patched by Martijn Berger
2010-11-16 23:18:17 +00:00
Nathan Letwory
e2b3ff5024 Apply patch [#24722] COLLADA exporter: handle instancing
Submitted by Wenzel Jakob

Patch adds handling of linked meshes: instead of generating separate geometry objects, use instances.
2010-11-16 22:27:31 +00:00
b1b02b7a5e bugfix [#24509] UV/Image Editor: selected elements move not as specified 2010-11-16 17:37:26 +00:00
fe2df7849e Bugfix #23677
Very old bug: Material/Render: the "filter" option for transparent
absorption also works for alpha==0, but in that case another part
of render code just didn't add the faces in render list.
2010-11-16 17:10:39 +00:00
c658141fad Fix for [#24750] Particles draw percentage setting is not working in No Physics mode 2010-11-16 16:56:21 +00:00
303646fbd4 Fix for [#24706] 2.55 beta Hair now only rendering small fuzzy blob 2010-11-16 16:39:35 +00:00
e60393b8a8 option to immediately write single render to a file added for OpenGL render. 2010-11-16 15:15:20 +00:00
cf3d6d63ee bugfix [#24462] UV Layouts saved as PNG results in two files (rename bug)
renaming failed in some cases, now we can just render to a file.
2010-11-16 14:45:27 +00:00
1e245cc589 option to write images to a files on single frame renders, this isn't accessed by the UI at the moment, but could eventually be used for saving test-renders.
The main reason to have this is so renders can be scripted to write to a specific file without having to do annoying tricks like set a dummy start/end frame range, render an animation and work out the current frame image will be written to, then rename after rendering.

Also made some 'char *' args into 'const char *'
2010-11-16 14:40:46 +00:00
2153c663be Bug #22585
Using texture nodes for displacement crashes, a conflict between using
nodes in render and for displacement at same time. Code simply disables
texture nodes for displacement for now, until we have better handling for it.
(on our long todo)
2010-11-16 13:41:39 +00:00
3ad21a8b4c Curve's UI minor fix:
- "Use Deformed" replaced back with "Fill Deformed"
- Use a bit more informative tooltip for this option
2010-11-16 13:25:21 +00:00
ca95a1d1ad edits to image save operator, no functional changes.
- don't rename the image when saving (problematic if the image is used with linked libraries)
- file writing and path updating was duplicated for multilayer images.
2010-11-16 13:08:24 +00:00
92ee3658d3 UV Layout Export was missing UV Layer check. 2010-11-16 12:54:44 +00:00
a58dcca5de Removing unnecesary print "draw swap exchange" 2010-11-16 12:29:30 +00:00
2de1c1fe1b Fixed wrong rna name for the old "UV Orco" option.
It was called "map on length", but it actually makes the UV
values of curves/nurbs to become used as "Generated" texture 
map input.

Sorry; this might break own local UI py script saves... :)
2010-11-16 12:10:57 +00:00
34c67bae0c bugfix [#24747] Blender crash entering in Sculpt Mode
rotate_m4 was being called with a zero axis.
2010-11-16 09:47:01 +00:00
5a1fdcdc2a bugfix [#24746] Align Camera to View locks 3D Editor in Camera Perspective View 2010-11-16 09:35:58 +00:00
7f96852176 fix for creating movie paths with non utf8 names.
button test if non utf8 chars are allowed was inverted.
2010-11-16 08:53:55 +00:00
f48f8d3bbc FBX Export, small changes made while looking into reported bug. (no functional changes)
- Warn for armature deformed meshes which are scaled, these don't work quite the same as in blender, reported as [#24663].
- Use matrix.decompose() to convert a matrix to loc/rot/scale.
- get vert/edge/face lists for each mesh only once.
- faster euler rad -> deg conversion function.
2010-11-16 04:32:35 +00:00
efcf1ac357 fix for matrix * vector rotation order. 2010-11-16 03:11:22 +00:00
f59b675641 patch [#24742] materials.pop() doesn't decrement user count
from Dan Eicher (dna)
2010-11-16 02:23:20 +00:00
1f1c0b8027 patch #24737] PyCObject depreciated in py3k [patch]
from Dan Eicher (dna), use PyCapsule rather then PyCObject
2010-11-16 02:18:50 +00:00
7e0f9229d6 fix for fix, r33086.
- incorrect range check broke ZYX euler rotations, use MIN/MAX constants so this doesn't happen again.
- BGE Armature PyAPI also wasn't using correct min/max with rotation modes.
- clamp on file read rather then when calling the rotation functions, so developers don't use invalid args without realizing it.
- added assert() checks for debug builds so invalid axis constants don't slip through.
2010-11-16 01:19:37 +00:00
7a7b4aff40 Bugfix #24726
Doing F1-load a lot of times on same .blend could crash. 
Janne karhu provided a potential fix, which is good to add
anyway. Will ask him to verify too.

Added XXX warning for these lines, after filesel exec no
context variables should be re-used. Is for later investigation.
2010-11-15 16:26:30 +00:00
e3ace7ee62 Bugfix, reported in IRC
The enum "rotmode" was read using an array, without checking for boundary
cases, causing crashes on bad input. (Wahooney report 2, thanks!)
2010-11-15 13:33:38 +00:00
070f38a6d0 bugfix [#24696] Export OBJ - Selection Only toggle button has the wrong default state.
Added convenience function to operators, 'as_keywords()', so operator settings can be passed directly to a function as keyword arguments.

The problem in this case was that dictionary access to operator properties was not returning rna-property defaults, so as_keywords() ensures all defaults are set.
2010-11-15 13:11:40 +00:00
Nathan Letwory
b9b95be374 Fix [#24310] With high poly numbers when sculpting, modifier keys hang
reported by Eclectiel L

When working with very heavy scenes Blender can seem to 'hang' (not responding). Key events that happen
during this period may get lost, especially for modifier keys.

Adding extra handling to account for these situations.
2010-11-15 12:05:11 +00:00
ccf1f08f37 Bugfix (IRC report)
Bone drawing code failed to check the correnct parent pointer, causing
NULL pointer to be read. Thanks Wahooney!
2010-11-15 11:45:54 +00:00
fd30c383dc Bugfix #24719: Layer ipocurves from Blender 2.49 wrongly ported to Blender 2.5x
Found and fixed a few problems here, but strangely I don't recall seeing any of these a few months ago when this conversion (probably last) worked well ...
2010-11-15 10:48:48 +00:00
Nathan Letwory
9453d40d93 Fix [#24552] Exception when starting Blender on Windows XP SP3
Reported by Ruud van Eeghem

Instead of running vcredist, which can fail when installing as normal user, have the DLLs
like our zip distribution bundled already inside install dir.
2010-11-15 10:29:42 +00:00
5182fa2e05 Fix for [#24724] Emission settings of Particles with no physics are stuck to Previous newtonian settings. 2010-11-15 09:15:23 +00:00
91d544f322 fix for very old crash when setting an empty object as the camera and using stars. 2010-11-15 09:00:09 +00:00
df9bedddcf bugfix [#24708] World Notifier Problems
also draw stars when 'Only Render' option is enabled.
2010-11-15 08:53:35 +00:00
4661fb03a9 bugfix [#24704] UV editor: [x] modified does not update on change of modifiers
- VBO UV Edge display wasn't allocating a large enough array for drawing.
- VBO UV Edge drawing was using an edge flag with faces.
- notifier for modifiers updating the UV window.
2010-11-15 08:03:20 +00:00
6401058c22 bugfix [#24704] UV editor: [x] modified does not update on change of modifiers 2010-11-15 07:07:14 +00:00
db16310386 - 'matrix_basis' for objects and pose bones, this is an alternative access to directly adjusting the loc/scale/rot.
- pose bone 'matrix_local' wasn't well named since it didn't work like object or regular bones.
- pose bone matrix values for rna had array access rather then 4x4 matrix access.

 note: for pose bones update scripts by renaming 'matrix_local' --> 'matrix_basis'
2010-11-15 06:38:07 +00:00
8fee983619 patch from Dan Eicher to support intel C++ compiler for CMake on *nix. 2010-11-15 05:32:49 +00:00
1a12d6d1d8 revert change from r32955.
This added a poll function to the Panel base class but this means that all panels register as having a poll() function which is called a lot and does nothing, raising an exception and removing it because of how python implements hasattr().

Found when checking why exceptions were continuously raised on redraw.

Martin, can you check on netrender?
2010-11-15 03:13:28 +00:00
7be25eba13 fix [#24712] 3ds_import fix
Rather then applying the proposed fix, enabling 'Apply Transform' works in almost all cases including the reported one.

There are some files that don't work with 'Apply Transform', which is why the option is worth keeping.

also remove unneeded calls to paint_facesel_test()
2010-11-15 00:07:38 +00:00
cdf7a1eaca creating the editmesh structure was running paint_facesel_test() for every vert and selected face.
not so efficient, check once.
2010-11-14 23:37:03 +00:00
e0209b593b unreported fixes for 3ds import
- non ASCII names would break loading.
- meshes with no faces would break loading too.
2010-11-14 22:30:51 +00:00
2d2a96a334 netrender
Adding retries on initial slave connection.
2010-11-14 22:11:56 +00:00
Nathan Letwory
1994fc80ed r33039 added dependency to COLLADA for blenderplayer, but it's really not needed there.
Stubbing for now.
2010-11-14 20:40:55 +00:00
Dalai Felinto
f4912b933e Logic UI bugfix: [#24628] two specific tooltips of keyboard sensor reversed
I also changed the order of them (target and log toggle) in the UI to match 2.49
2010-11-14 19:46:14 +00:00
43e6ccd57b Move rotOrder to proper transform data structure 2010-11-14 19:19:58 +00:00
ba965b0f7a Seamless texture used for beveled curve is now really seamless (thanks to Mario G. Kishalmi aka lmg) 2010-11-14 19:06:39 +00:00
f4f3bdb834 Correct description for Projection property (it doesn't just work on vertice) 2010-11-14 18:31:32 +00:00
7f0877f0dc bugfix [#24697]
Proper fix: change the poll function to reflect actual operator requirements.
2010-11-14 18:27:25 +00:00
bc7903c858 [#24639] Snap to Face (retopo) doesn't work when clipping is enabled in mirror modifier.
Apply project snap at the very end.
2010-11-14 16:31:06 +00:00
25bd3feeb5 == filebrowser ==
* compile fix on non-Windows platforms.
2010-11-14 11:59:42 +00:00
63f131803c == filebrowser ==
* removed now unused function file_string_width_shortened.
2010-11-14 10:53:49 +00:00
2e84732228 == filebrowser ==
* drawing code cleanup.
* list drawing code now uses uiStyleFontDraw like buttons etc.
2010-11-14 10:48:36 +00:00
27f607f86d bugfix [#24668] Deleting armature objects removes a user from its action, eventually leading to data loss 2010-11-14 09:20:31 +00:00
c66731b634 bugfix [#24697] Trying to run bpy.ops.transform.create_orientation crashes Blender 2010-11-14 08:26:44 +00:00
5bbe32be41 Forgot to Add NodeLink to the Access Struct file. 2010-11-14 08:11:58 +00:00
30ac7799c8 bugfix [#24702] 3Dmanipulator does not display if view's layers are not synchronize to scene's layers. 2010-11-14 07:49:07 +00:00
4a3e00488d fix for own recent error, [#24695] column_vector_multiplication call writes past end of array
was setting the vector array out of bounds with vec*=matrix, where the vector wasnt size 4.
2010-11-14 07:42:14 +00:00
6a49aca153 fix for own error in recent commit. add a back NULL terminator to the string in text_font_draw_character. 2010-11-14 07:28:53 +00:00
e4e79f4aa3 update for mathutils vector/matrix order change. 2010-11-14 07:02:55 +00:00
e574b3cdcc Patch [#21942] Node links access by Andrey Izrantsev (bdancer) Thanks!
This adds Node Link Acces in RNA.
2010-11-13 22:38:33 +00:00
2fbfd11f8d Fix for [#24654] Sound Actuator doesn't find the file when Blender is reopened. 2010-11-13 13:44:45 +00:00
c1dec420b0 Bugfix #20382
Fixed old annoyance in Search menu, with a load of object-mode 
operators showing up in editmode. 
It's much cleaner now, but it will take further work and 
investigation to have context & polls work satisfying for all cases.
2010-11-12 17:35:51 +00:00
17ab7466a7 Makefile fix for compiling with quicktime. 2010-11-12 16:14:31 +00:00
b1c9e599d4 bugfix [#24661] Object.find_armature() only works on meshes 2010-11-12 15:05:57 +00:00
0b23f03503 Bugfix #24335
ZCombine node in compositor ignored alpha values. Enabling it
would break compatibility though, so it's a tickbox option now.

Patch provided by reporter, Martin Lubich. Thanks!
2010-11-12 14:59:01 +00:00
3c4b1c0d60 Hide "active" checkbox in ui for "fluid" type fluid objects as it's not used by fluidsim.
* Response to report [#24670] Keyframe fluid on/off does not work
2010-11-12 14:54:40 +00:00
e83ef4efc5 Related to #24653: added scene.collada_export() function, to use instead of an
operator for external render engines, since operators should not be called in
the render() callback.
2010-11-12 14:36:58 +00:00
0a467d5183 bugfix [#24682] Render artifacts with mat node 2010-11-12 12:45:55 +00:00
a102c07f7d add back red tint for zero user datablocks. 2010-11-12 11:49:33 +00:00
ee7bf4dab5 take delta's into account when applying the objects matrix (dloc, drot, dsize).
Now object_apply_mat4() can be used as the reverse of object_to_mat4().

Noticeable result is fly mode and 'Apply Visual Transform' dont jump when deltas are used, also means setting matrix from python works as expected.
2010-11-12 11:16:04 +00:00
73a91bc548 fix for vec * matrix always returning a 3D vector. 2010-11-12 09:06:50 +00:00
d43d5d7690 Getting BLF to work with the Blenderplayer. 2010-11-12 07:16:33 +00:00
4f4bd27512 bugfix [#24665] mathutils.Matrix initialization is counter-intuitive and generates bugs
was printing transposed, also nicer printing.

>>> from mathutils import Matrix
>>> Matrix()
Matrix((1.0, 0.0, 0.0, 0.0),
       (0.0, 1.0, 0.0, 0.0),
       (0.0, 0.0, 1.0, 0.0),
       (0.0, 0.0, 0.0, 1.0))

was...
Matrix((1.000000, 0.000000, 0.000000, 0.000000), (0.000000, 1.000000, 0.000000, 0.000000), (0.000000, 0.000000, 1.000000, 0.000000), (0.000000, 0.000000, 0.000000, 1.000000))
2010-11-12 02:50:57 +00:00
a34f525a21 bugfix [#24660] (vector * matrix) fails, (matrix * vector) succeeds
- Reverse vector * matrix multiplication order. now this matches how numpy works.
- Disallow 'matrix * vec' and 'quat * vec', now it raises an error.
- Add missing in-place multiply 'vec *= quat'

Many scripts will need to be updated for this but at least it will error rather then failing silently.
2010-11-12 01:38:18 +00:00
Nathan Letwory
44e36b5156 Revert the reversal :) 2010-11-11 22:12:49 +00:00
Nathan Letwory
9860832820 Fix compile problems for msvc. 2010-11-11 22:09:09 +00:00
bc3ea2cb66 Revert r33023
Was causing compile troubles with MSVC:
wm_operators.c
C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\io.h(322) : error C3163: '_write': attribute
s inconsistent with previous declaration
        C:\Program Files\Microsoft Visual Studio 9.0\VC\INCLUDE\io.h(224) : see declaration of '_wri
te'
scons: *** [C:\blenderdev\b250\buildvc\source\blender\windowmanager\intern\wm_operators.obj] Error 2
2010-11-11 22:05:17 +00:00
fd9afa7431 rename anim.channels_revive_fcurves --> anim.channels_fcurves_enable
better matches existing VIEW3D_OT_enable_manipulator & ANIM_OT_channels_setting_enable
also fixed warning.
2010-11-11 21:49:40 +00:00
0d488e00c8 System console toggling for MinGW
Define WINVER=0x0501 for MinGW due to some stuff requres this winver, but
MinGW's default is 0x0400 (thanks AlexKu for point)

Better to replace all #include <windows.h> with #include "BLI_winstuff.h" to
avoid possibility of different functions prototypes in different modules.
2010-11-11 20:32:28 +00:00
b96bd0a732 Fix for definitions checking. Now it should work with MinGW. 2010-11-11 19:28:10 +00:00
Nathan Letwory
3e01338094 Also !defined(FREE_WINDOWS) on appending operator. 2010-11-11 19:04:57 +00:00
5aa9d804c9 SVN maintenance. 2010-11-11 19:00:52 +00:00
c0da754d8d == filebrowser ==
When loading .blend file (F1) open the filebrowser with the most recently used .blend file. Another lost feature from 2.49 back ;)
2010-11-11 18:53:10 +00:00
Nathan Letwory
df487be82f wrong language :° 2010-11-11 18:24:03 +00:00
Nathan Letwory
fc667fdb8e For now have console toggling only when compiled with MSVC.
Need to find out how to enable for MingW too.
2010-11-11 18:21:57 +00:00
c69bc46c98 Smoke now uses the start and end of cached data properly when outside the cached frame range.
* Patch by MiikaH.
2010-11-11 17:59:52 +00:00
1659e3fca7 Bug fix: memoryleak when using smoke heat/velocity data as texture
* In addition to fixing the memleak it's much better to always copy the voxeldata to the texture. Smoke data can change at any time due to some changes, so we can't depend on that data.
* Thanks to MiikaH for finding this!
2010-11-11 17:03:09 +00:00
4d9684ebdf Bugfix #20027
Texture Nodes didn't work for normal output anymore anymore.
It was caused by new handling of bump code using derivatives,
but that's not how texture nodes work now. In case a texture
has nodes, it uses the old (2.4) method.
2010-11-11 16:50:04 +00:00
d9e7e71675 Bugfix #19534
Crash in Array Modifier. The merging-vertices option 
(mysteriously named "First Last") caused invalid indices in
faces to exist. This commit solves the crash, but not the
cause. For that Ben Batt's assistance is needed.
2010-11-11 15:33:28 +00:00
Nathan Letwory
a583ea5096 Apply patch [#24579] Fix for Win; Show/hide console
Submitted by Alexander Kuznetsov
2010-11-11 13:44:51 +00:00
43f396218f move report/operator view out of the 'Console' into the 'Info' space (file menu).
Ton will work on moving the File menu out of the Info space before release.

notes.
- reply Operator isn't working anymore.
- UI for reports is commented out so its not mixed with the file menu.
2010-11-11 13:36:57 +00:00
c1a74d9bd6 Animation Editors: Experimental indicators + "fixup" operator for "Disabled FCurves"
F-Curves tagged as "disabled" now have their channels drawn with a red line underlining their names. 

"Disabled" F-Curves are skipped for evaluation, and typically result (for example) from assigning an action from one armature to another, but the new armature does not have some of the bones the action's F-Curves need in order for the datapaths (referring to the property the F-Curves affect) to be resolved. This is to prevent heaps of invalid channels slowing down animation playback.

I've also added a new operator, found by:
Channels -> Revive Disabled F-Curves
in the Graph Editor and DopeSheet/Action Editors, which will clear all the disabled tags for all the F-Curves in the animation editor at the time (based on the filtering criteria). 

Use this operator to clear the disabled tags, allowing such channels to be able to be evaluated again (perhaps after adding the offending bones for example, or when using the action on the original armature again).
2010-11-11 11:56:50 +00:00
5aea6c2181 Bugfix #24659
Material buttons: Wardiso slope button was not of type 'factor' (slider), 
making it very hard to use.
2010-11-11 11:53:30 +00:00
36901ff5bb use BLI_snprintf, fixed building on msvc. 2010-11-11 11:46:45 +00:00
4d0a5451c5 Makefile fix: new compile flag moved to correct Makefile 2010-11-11 11:06:15 +00:00
dfb27a3494 fix mistake in makefile 2010-11-11 11:01:15 +00:00
98e98bf5d2 Bugfix #24621: NLA strips move insensitively across tracks
This was a 2-part bug:
1) "Track index" (i.e. "index of NLA track within NLA Stack") was calculated incorrectly when the transform data is created. A typo meant that this was actually "index of strip within original track" 

2) Strips were flying around madly vertically (especially for downward movements, and with extreme difficulty for upwards) as the track index was being updated incorrectly. I suspect at the time I was misreading it as trackIndex = ... vs trackIndex += ..., though it obviously looked wrong looking at it now!
2010-11-11 10:27:24 +00:00
e3db157074 NLA Transform Bugfix:
Transforming strips into locked tracks meant that they were not unlocked properly (i.e. they stayed as temporary "meta" strips). This is now taken into account as part of the step which checks if there's any space for them in those tracks.
2010-11-11 10:07:33 +00:00
7d80a4a067 Get rid of G.rendering in curve_to_displist 2010-11-11 10:01:10 +00:00
cf673cf80a Fix #24643: Nurbs Surface Preview resolution overrides render resolution
NURBS surfaces always used resol{u,v} from spline and never used curve's render resolutions.
Now, if curve's render resolution is non-zero then it'll override resolution for all
splines when rendering (in needed direction only, ofcource).
2010-11-11 09:56:39 +00:00
030253cdf6 fix for building, also use const char in more places. 2010-11-11 07:51:12 +00:00
80a650dfb1 BLF_draw functions take an extra length argument, so the console drawing doenst need to swap in NULL chars to draw word wrapping. 2010-11-11 06:35:45 +00:00
59cfe81085 Reorder library linking. 2010-11-11 06:22:55 +00:00
85ac881d31 SVN maintenance. 2010-11-11 06:03:41 +00:00
e47d84026d make console wrapped text drawing into its own function in preparation to move report view out of the console space type. (no functional changes)
also remove incorrect messages about the original copyright in the GPL headers.
2010-11-11 05:45:55 +00:00
662b35a2c0 Preview Range operators were broken in Graph Editor 2010-11-11 05:11:37 +00:00
e6f6a0a6e2 Nurbs Curve UI:
* Fixed an alignment issue in resolution buttons.
2010-11-10 19:37:58 +00:00
3b5ad51719 Bugfix #24524
Mesh loop tools allowed to be invoked outside 3d region (properties).
That caused crash, it needs 3d view code to work.
2010-11-10 18:00:51 +00:00
8df02539ba Bugfix #24570
When using a startup.blend without user prefs (themes etc) saved, Blender
crashed. Added a provision to then fall back to the compiled in startup, 
including a print in console.
2010-11-10 16:49:42 +00:00
278124669b bugfix #24573
View2d custom keymap to put zoom in RMB didn't work, the modal handler
still has a hardcoded check for mouse/keys. Fixed it for this case quickly,
added wiki todo and warning in code.
2010-11-10 16:22:19 +00:00
b8a3daea31 Bugfix #24603
Using ALT+B clipping and CTRL+R loopcut in wireframe mode, made 3d drawing
disappear. Was caused by faulty setting of zbuffering on in loopcut code.
2010-11-10 15:10:54 +00:00
97984e6562 Fix #24615
Light Cache resolution for volumetric material could be set to zero,
causing crashes.
2010-11-10 14:09:32 +00:00
7b36b5d1a3 bugfix [#24638] Crash when parenting ni local view through the outliner 2010-11-10 11:37:55 +00:00
fe18f517a1 bugfix [#24635] "Add Shortcut" 2010-11-10 11:19:52 +00:00
bb3cd04887 "Fix" for [#24629] 2D-cursor coordinates in 254B UV and 3D views
* This null check just prevents the crash, but the real bug is that 3d view toolbar redo even shows the image view operator..
* ..and since the redo is in the wrong view it doesn't work. Both of these are known issues.
2010-11-10 10:21:14 +00:00
1a0198ee12 Reverting part of #32971
By just removing these vars (commenting them out), we were getting alignment errors which were causing crashes when loading old files with armatures (crash in armature drawing code). 

Fortunately I happen to be working on a little project right now, and caught this :)
2010-11-10 09:51:30 +00:00
4b45a42b48 Removed unused code from multires module 2010-11-10 08:24:15 +00:00
f529e10951 Fix #24632: Sculpt Mode Context Set hotkeys (1..0, Shift+1..0) don't work
- Totally get rid of old active_brush_index stuff
- Use operator to set n-th brush as active in specified paint mode
  thans to Cambo for it's optimization :)
2010-11-10 08:11:58 +00:00
8023da964c fix [#24631] array modifier, relative offset, units 2010-11-10 08:10:42 +00:00
99396da62c [#24627] [minor] Object type is TEXT, but icon names are FONT
change object.type enum name TEXT for FONT to match icon and ID type names.
2010-11-10 07:44:48 +00:00
91c1b80a5f bugfix [#23710] 'repeat last' button doesnt' work with extrude along axes other than Z 2010-11-10 07:10:23 +00:00
854b6cd327 fix for the crash reported in [#24625] Duplifaces not generated using spacebar to activate 2010-11-10 05:46:17 +00:00
9471855be5 correct some comments and fix for allocating more memory then needed for animation paths. 2010-11-10 04:58:37 +00:00
df028b90a3 partial fix for [#24634] Passing custom context to join operator doesn't work
- report errors when join fails.
- toggle editmode with internal functions rather then ED_object_enter_editmode / ED_object_exit_editmode, which rely on context too much and didnt work properly when calling join from python.
2010-11-10 01:40:24 +00:00
5f69c0ec09 string lookup for scene.object_bases, also removed some unused DNA vars. 2010-11-10 00:51:34 +00:00
4c12298832 Bugfix #20812 (and probably others)
Issue: in user preferences window, using file selecting caused the
the userpref window to be saved, and not closing.

Reason: design error (by me) in using screen->full tag for denoting
a temporarily screen (like file window). Fixed by using a new 
screen->temp variable for it.

System remained unstable though, noticed another issue with freeing
temp screens in wrong places. Seems nice stable now! Will check on
the wiki for relarted issues now.
2010-11-09 14:54:59 +00:00
2b96175608 Bug fix: cutting a sequencer movie strip with sound could crash in some cases. 2010-11-09 11:26:00 +00:00
b874bdc227 Fix for [#24580] and [#24600]
* Particles didn't want to stay cached, even if there were no actual chages.
* Particle states weren't set properly for times before actual simulation start.
2010-11-09 11:17:00 +00:00
db4c2b8016 remove unused scene members 'jumpframe' and 'ima' 2010-11-09 10:40:03 +00:00
7a62c05204 bugfix [#24403] Object.copy() duplicates armature action
now duplicating ID data wont duplicate actions by default and the user preference is used with duplicate operators.
2010-11-09 09:53:17 +00:00
989aea3ed0 copying a camera would copy its animation data (and action datablocks) twice. 2010-11-09 09:34:03 +00:00
1b513838a8 Add a "Save user settings" operator entry in the File menu, avoids having to open User Preferences to save layout changes. 2010-11-09 07:49:15 +00:00
5cf7699abf RNA_property_as_string support for pointer properties, without this macro arguments were just called '<POINTER>' 2010-11-09 05:58:30 +00:00
7684901bb8 bugfix [#24623] VSE strip animation data out of sync after moving using shift-s
also fixes snap on metastrips which was snapping nested strips.
2010-11-09 04:56:52 +00:00
a85ffa6ffd bugfix [#24578] crash on browse directory w/ broken image file
Was trying to decode an image when quicktime wasn't initialized.

There are a few other reports on windows about thumbnails crashing which this probably fixes.

This also fixes a bug where DisposeHandle wasn't called if decode was called with a NULL pointer.
2010-11-09 03:52:27 +00:00
cd71a6d12b [#24602] Netrender master node IP information is reset to [Default] no matter what
[#24601] Net rendering master node fails to send/retrieve files to/from slaves

Both Reported by Dan McGrath

The second might not actually be fixed with this, but now there is better error checking and reporting.

Misc: add poll method in Panel base class, to better support mixins with different inheritance order.
2010-11-09 03:37:51 +00:00
718df71864 bugfix [#22794] Inconsistent behaviour with Panorama, border rendering 2010-11-09 01:37:58 +00:00
c4967b5dde bugfix [#24616] Apply Visual Transform doesn't always apply location
- object updates were not being flushed, so children weren't updating.
- apply the matrix relative to the parent, added this as an option to object_apply_mat4() which allows assigning the worldspace matrix in python without worrying about the parent.
2010-11-08 22:32:28 +00:00
0c27782b8e update the man page from blenders --help message 2010-11-08 21:13:44 +00:00
7fd87de47b Small bug, reported by Andy in irc:
Image editor & texture properties, add new Image, inits 'start' now 
to frame 1 for sequences.

Added triple-X warning in Image Open operator, it uses SpaceImage whilst
it can be called from other editors. Code is safe but not correct.
2010-11-08 19:03:42 +00:00
f9487fba39 Fixed own mistake from previous commit -- get_levels_from_disps can't be used
when handling topology changes.
Added grid size detection based on totdisp and corners count.
2010-11-08 14:39:36 +00:00
fe53cf2cb4 Patch [#24608] Fix for typo and better indentation in command line help by Susanne H. (sanne). Thanks! 2010-11-08 14:08:22 +00:00
8647dbc0a6 Fix crash when creating new faces in edit mode
- Do not check corners count if totdisp is set to 0
- Allocate memory for such mdisps to prevent the whole disp layer erasing
2010-11-08 14:00:23 +00:00
f15187cfcd Fix for [#24597] Option External in Smoke cache affects settings of start and end frame of simulation
* Don't change anything in the pointcache unless a valid external cache is found.
2010-11-08 11:19:53 +00:00
d5a913378f Better name for smoke "gravity" parameter and more descriptive tooltips. 2010-11-08 11:13:46 +00:00
cc395e4d2f fix for not being able to select the camera while in the camera view, also draw the camera unscaled in the 3D view. 2010-11-08 09:38:48 +00:00
3ca44b5d16 Second fix for [#24476] The driver is not displayed in GraphEditor.
* Texture data still wasn't shown if material didn't have animation data.
* Also unified the material/texture filtering logic a bit.
2010-11-08 09:05:27 +00:00
4d743796fd bugfix [#24583] Mesh.from_pydata does not properly construct faces 2010-11-08 07:59:34 +00:00
741d5a6c06 fix for CMake file grouping with MSVC project files. 2010-11-08 06:31:45 +00:00
a652544909 change from recent commit. when orbiting out of the camera view switch to the last used perspective. 2010-11-08 03:55:03 +00:00
85b9652258 fix for glitches with quad-split view.
- Home or Numpad Period with smoothview disabled were not syncing up the other views.
- Disabling clip only disabled clip syncing but left clip enabled for all views.
- Clip was being calculated for every update even when not enabled.
- The perspective view was being used to copy settings from when changing box & clip settings, resetting the distance each time. Now use one of the aligned views instead.
2010-11-08 03:44:52 +00:00
c300d58497 - when orbiting the view out of camera mode use the ortho/persp setting of the camera.
- display the physical size of a ortho camera since, unlike a perspective camera the ortho scale can be converted into a plane with real size.
2010-11-08 02:30:46 +00:00
615a2060c9 Bugfix: NLA Channel Borderselect works again 2010-11-08 00:09:31 +00:00
55923d1044 compiler warning fixes 2010-11-07 23:22:40 +00:00
1e4f0a92f6 [#24594] Edge weighting while making subsurf
use shift+e for crease as in 2.4x
2010-11-07 23:02:08 +00:00
8b27e83e5c [#24593] Cloud Depth setting above 30 cause texture corruption
disallow cloud depth over 30, it causes a lot of floating point exceptions (and nan value pixels), because of hitting the int limit with 1<<(oct+1) in BLI_gTurbulence
2010-11-07 22:48:51 +00:00
6de12ac853 UI Scripts World:
* Remove poll, not needed anymore.
2010-11-07 20:48:09 +00:00
6900d71ac6 Remove code duplication.
Will look into nicely using uiStyleFontDraw later.
2010-11-07 18:16:27 +00:00
4741dd26d3 Enabled kerning for the default UI font for the places that are using UI_DrawString still and for filebrowser.
Makes text more readable :)
2010-11-07 18:01:32 +00:00
a9f96d1adc fix ford last commit - also remove file from CMakeLists.txt 2010-11-07 17:14:10 +00:00
f5ffb18932 removed unused code for image loading, was copied from 2.49 and never used. 2010-11-07 16:22:25 +00:00
5bf1a6d13b Raised soft limit for cloud texture noise to 24 for easier access. 2010-11-07 16:20:44 +00:00
c3878175f0 Removal of more ancient stuff. (Help url and some cygwin build file, which is not in use anymore) 2010-11-07 16:19:13 +00:00
c40725fe5e remove BLI_bfile, has been in blenders source for quite some time but remains unused.
can add back in if its ready to be used ofcourse.
2010-11-07 16:02:17 +00:00
034c956260 fix [#24554] Blender does not remember name of last saved picture
* image name is now set when the file is actually saved if it is empty. Otherwise it is only changed if we're not saving a copy.
* If previous image name is empty, filename will be 'untitled.png' for png saving.

NOTE: if we saved a copy of 'render.png' as render1.png, the save image dialog will be re-opened with the image name that Blender has (render.png) rather than render1.png.
2010-11-07 15:07:14 +00:00
c7fab53ccb Bugfix #24585
Quad view split 3D window: didn't work for "box lock" option when
using "view all" or "view selected".
Made it work nicely for animated 'smooth' view too.
2010-11-07 14:57:24 +00:00
fb20c1b184 Partial fix for NLA Channel-List Border Select. This part of the fix gets the selection ranges right. The next part of the fix (for tomorrow) will involve setting up access for NLA-Track properties... 2010-11-07 12:15:21 +00:00
db4609eb08 Animation Editors: Channel Reordering
This commit restores the ability to reorder channels in the animation editors (DopeSheet/Action/etc., Graph/Drivers, NLA). The hotkeys for this are:
- Shift-PageUp = Move Up
- Shift-PageDown = Move Down

- Ctrl-Shift-PageUp = Move to Top of List
- Ctrl-Shift-PageDown = Move to Bottom of List

Do note that only animation data can get reordered using this. 
So, do not expect to be able to change the object order (that is actually taken from the order that Blender actually evaluates them per update/frame).

---

In the process, I've fixed a couple of other bugs:
* Removed 'optimisation step' check in anim_filter.c for dopesheet with no filtering options modified, since this meant that the ANIMFILTER_ANIMDATA data filter was not getting processed (and potentially there were other maintenance problems with that).

* Made NLA Editor's channel list not totally duplicate the basic Animation Channels keymap. Instead, the "NLA Channels" keymap now only defines the parts that are different, and this then gets specified before the standard one so that these different parts will override the standard ones.

* Attempted to fix BorderSelect on NLA Channels list. Still not totally working correctly yet though.

* Moved "Euler Discontinuity" menu entry from "Channels" to "Keys". It really belongs in the latter, since it affects the keyframe values, rather than some aspect of the channel (i.e. ordering of channels or how they're displayed)
2010-11-07 12:09:15 +00:00
12770dba0e use RV3D_CAMOB define, theres no reason to use >= comparison either.
also fixed opengl render ortho test.
2010-11-07 10:36:06 +00:00
89baa67a40 Inverted the opacity setting for Background Images through RNA.
I was testing with a patched blender where this wasn't a problem else I'd have noticed.
2010-11-07 09:53:39 +00:00
ed61900e5e - avoid loop within loop for unique naming function (even though it wasnt likely to run often).
- off by 1 error with outliner naming length. was 1 too short.
2010-11-07 09:33:10 +00:00
20b16e4074 de-duplicate unique naming logic, was used in 7 different places, convert into a function call. 2010-11-07 08:49:07 +00:00
fbcaa502ca bugfix [#24574] setting location gained from a matrix_world.copy().translation_part() (visual loc) after constraints causes NAN in object location after python script ends
shrinkwrap constraint was dividing by zero. also the shrinkwrap UI was incorrectly trying to draw a subtarget.
2010-11-07 05:59:35 +00:00
05e598959e bugfix [#24575] On file save plus and minus don't re-evaluate whether a file exists
actually it was re-evaluated. just the flag was overwritten by the old button.
2010-11-07 05:35:41 +00:00
c34275bcab better exception check for calling operators. non dict/None values were being treated as None. 2010-11-07 04:46:50 +00:00
46f90690e0 patch [#24576] aud.Handle.status return bool
from Dan Eicher (dna), no functional changes, just return bool rather then int types.
2010-11-07 04:34:27 +00:00
231cceaa46 patch [#24577] MESH_OT_noise. Adds missing 2.4x noise vertex displace functionality.
from Dan Eicher (dna) 

Also added a factor option so you can adjust the amount of noise applied.
2010-11-07 03:56:58 +00:00
e764868741 committed by mistake 2010-11-07 03:45:55 +00:00
8d38358f4b Fix for [#24569] F11 no longer functional after image save
* Same fix was already in ED_area_prevspace().
2010-11-06 22:37:29 +00:00
f793b75dcc Fix for [#24476] The driver is not displayed in GraphEditor.
* TSK! give_current_material(..) is used with index+1
* Also very bad practice to use same loop variable name in a loop inside a loop.
2010-11-06 22:23:37 +00:00
b0e62b0351 Fix for [#24560] Cloth pinning breaks (when parenting?)
* Changing the pin group needs to redo the whole cloth object.
* Also, parent updates weren't flushed properly to pointcache in depsgraph.
2010-11-06 22:03:42 +00:00
801c79e938 remove line which wasnt supposed to be committed. 2010-11-06 21:42:27 +00:00
e9fa964315 Rename BG image Transparency to Opacity, Since 100% transparency is actually 100% opaque and this matches grease pencil. 2010-11-06 21:40:09 +00:00
09980065b7 Do not hide the Indirect Lighting tab, caused some confusion.
Now print an info that Indirect Light only works with Approximate in Trunk atm. 

If someone knows a better solution, feel free to change.
2010-11-06 21:37:11 +00:00
9e7c968113 Bug fix: Rendering with anti-aliasing disabled and full samples enabled crashed
* Disabling anti-aliasing disables full samples in ui, so do that in render code too.
2010-11-06 21:32:58 +00:00
d475448bdd == filebrowser ==
Added two user preferences for filebrowser:

1. Hide Recent Locations
Requested by Kernon Dillon. Reason: People doing video tutorials might not want to expose the name of other projects they are working on.

2. Open Filebrowser in thumbnail view for images and movies
Requested by Sebastian König at the Blender Conference. Reason: In the past (and most likely still) some corrupt images or movies could crash the filebrowser when generating thumbnails. (crashes in ffmpeg, libtiff, libjpg). While many of those were solved, artists in a production environment might want to use this setting to prevent any crashes.

NOTE: the second setting should probably be set next time we create a new default startup.blend. Until then users need to switch this on manually in the User Preferences.
2010-11-06 18:54:15 +00:00
066a1d30bb Fix #24556: N Panel in Compositor doesn't work with Vector Normal node. 2010-11-06 17:55:43 +00:00
e686cdae93 [#24565] editors/armature: overwritten return value
Reported by Nicolas Kaiser

(error was turning off some optimization in etch-a-ton)
2010-11-06 17:25:33 +00:00
5d1ea9e340 Fix crash in several cases when adding bevel on array modifier with merging switched on
Check if edge would be collapsed to single point after mapping in array modifier
2010-11-06 17:19:40 +00:00
5b0e1520cf == filebrowser ==
Center Text underneath the icons in thumbnail view. (Small request from Sergey)
2010-11-06 17:03:11 +00:00
06a53cde7d Minor adjustments in the readme file. 2010-11-06 16:17:49 +00:00
dcda17b3b3 == filebrowser ==
Bringing back missing feature: Create new directory by typing a not existing name into the directory button.

Note: Small issue still with autocomplete -> if typing the new directory directly after autocomplete, it doesn't execute the operator yet.

Also fixed some minor compile/cleanup issues with warning about signed/unsigned comparison and missing header.
2010-11-06 16:09:12 +00:00
a1c7cccae4 Fix bug with unneeded outline for filled 2d curves when converted to mesh
- Revert of my old change in curve->mesh conversion
- Do not ignore DL_POLYs for surfaces -- they will never be filled,
  but ignore them for 2d curves -- they'll be filled with INDEX3 parts.
2010-11-06 06:22:25 +00:00
e8501edae2 Read external mdisp when hamdling topology changes 2010-11-05 14:00:31 +00:00
66b274766a minor c90 compat edits. (no functional changes). 2010-11-05 13:37:18 +00:00
e202aa6e66 dont change the file paths of sequence images, this is weak design because you can easily have 2 image users with different frame numbers so this ends up being which ever was last loaded.
Modified to image user template to show the current filename of the image.
2010-11-05 09:01:00 +00:00
e179c92a27 tedious string copying changes
- use sizeof() in more places.
- fixed some off by 1 bugs copying strings. setting curve font family for instance was 1 char too short.
- replace strncpy and strcpy with BLI_strncpy
2010-11-05 07:35:21 +00:00
0ebdbdac00 workaround/fix for [#24540] Adding the path to an image Editor in the file preferences window messes up the path
when selecting paths from the user preferences always default relative option to off.
otherwise you get paths like '//..\..\..\..\Program Files\GIMP-2.0\bin\gimp-2.6.exe'
2010-11-05 06:33:33 +00:00
7569a25a4f centralize function for calculating pixel size. (no functional changes) 2010-11-05 05:26:34 +00:00
36b8ebceb5 added back include file globbing for cmake, thought this was needed for MSVC only but turns out QtCreator also needs this else it wont index headers. 2010-11-05 04:18:53 +00:00
f0b01220e5 'Continue' zoom method for 2d views wasn't continuously updating. added a timer so it works like the 3D view. 2010-11-05 03:54:54 +00:00
96a980ea1c incorrect poll function for clearing/applying loc/rot/scale.
Without an active object it wasn't possible to clear location on the selected objects for eg.
2010-11-05 02:49:01 +00:00
c7ed7fcbe1 fix for missing NULL check with brush poll, reported by Mike S. 2010-11-05 02:42:33 +00:00
da402c937e fix for linking the player, also fixes building without python and bullet. 2010-11-05 01:47:55 +00:00
52865a5140 Bugfix #24535: File saved with NLA Strip in Tweakmode crashes on reload
Now the active strip doesn't just get cleared on fileload, but is relinked properly. 

I had originally intended that files shouldn't be able to be saved with NLA data still in Tweakmode, but this turns out to be a bit more troublesome to get working as that would make undo keep popping out of this mode too.

Also reverting 32743 (bugfix for 24418), which was a hack around this.
2010-11-05 00:09:45 +00:00
8bbf27dfbd Temporary fix for "freezing when pointcache is baked":
* WM_timecursor is broken somehow, so pointcache baking makes the cursor disappear.
* For user this seems like blender has frozen although it's just a matter of no progress indication.
* This fix just sets the default "busy" cursor for the whole duration of baking and reports progress in the console.
* If there's and easy fix for this then it should probably be done straight away, but I want to re-implement baking using the job system soon anyways, so a proper fix for this is not strictly necessary.
2010-11-04 20:17:38 +00:00
951882e289 Fix for [#24510] VSE SceneStrip problem when rendering animation 2010-11-04 18:16:34 +00:00
27de85af37 Fix for [#24513] VSE curves displaced from effect when source is moved numerically 2010-11-04 17:02:32 +00:00
228ed6f086 Global definition of _LARGEFILE_SOURCE, _FILE_OFFSET_BITS and _LARGEFILE64_SOURCE at linux and win32/mingw platforms
Needed to work properly with large files at 32bit system (display correct size in file browser, i.e.)

This will also fix compilation with zlib 1.2.5
2010-11-04 17:02:25 +00:00
b2d3843992 for some reason even though this resizes areas more evenly on my system (and works ok on Brecht's) theres a report that resizing views fail.
[#24529] Views Resizing Problems

now this is exactly like what it was before, hope its fixed.
2010-11-04 16:17:37 +00:00
f478cef43b Fix #24388: multires base mesh
- MDisp should be re-allocated if face changed amount of vertices
- Allocate disps array in layerSwap_mdisps to prevent loosing all highres data
2010-11-04 16:00:28 +00:00
6753882e42 bugfix [#24009] Crash when switching area types and performing ops 2010-11-04 15:59:09 +00:00
5fafa570d0 warn if blender is compiled without python 2010-11-04 13:13:31 +00:00
64ff9d6de4 fix to allow [#24009] to be fixed.
WM_operator_poll() could fail in cases WM_operator_name_call() would succeed because calling the operator would setup the context before calling poll.
this would result in python raising an invalid error or menu items being greyed out.

now python can also check with an operator context:
  bpy.ops.object.editmode_toggle.poll('INVOKE_SCREEN')
2010-11-04 12:59:03 +00:00
0e81723683 Fix #24531: UV editor: setting rotating/scaling pivot with [ , ] [ . ] not working.
Patch by M.G. Kishalmi, thanks!
2010-11-04 11:45:30 +00:00
e8f08c612b Fix #24523: deep shadows are rendered although object's shadow casting is disabled. 2010-11-04 11:41:05 +00:00
e32a81cba2 workaround/fix [#24451] Motion path not automatic recalculating + locking obj moving
Comment from source...
			/* re-calculating the frame positions means we loose our original transform if its not auto-keyed [#24451]
			 * this hack re-applies it, which is annoying, only alternatives are...
			 * - dont recalc paths.
			 * - have an object_handle_update() which gives is the new transform without touching the objects.
			 * - only recalc paths on auto-keying.
			 * - ED_objects_recalculate_paths could backup/restore transforms.
			 * - re-apply the transform which is simplest in this case. (2 lines below)
			 */

Martin, if you think this workaround is unacceptable, then automatic recalculating of paths after transform should probably be disabled since it looses data on non transform un-keyed values.
2010-11-03 23:49:56 +00:00
dba1904f65 bugfix [#24518] Blender wont compile with -Wall -Werror and COLLADA support
fix included in report from Martijn Berger (mberger)
made some small changes.

- use ints rather then unsigned long for printing, values are not likely to be very large.
- CMake remove strict flags from collada build dir since I had warnings in the collada headers.
- added xml2 to collada libraries else I couldnt get collada building.
2010-11-03 22:44:39 +00:00
ce3b49742d fix for #24428, commit r32757 broke menu bar display for some users [#24454] (but not me for some reason).
For now revert most of r32757.
2010-11-03 22:11:17 +00:00
81fe9d2d04 workaround [#24392] 2d Image paint editor: no clone/smear/soften tools etc
the brush system matches the brush mode with the object mode, but this doesn't work for 2D image view paint.
since the poll() function doesnt have access to the context, for now just check if no paint modes are active, default to texture paint.
2010-11-03 21:23:02 +00:00
ee4b32c41a Fix for [#21958] Dupli group doesn't show up if linked on a layer that is different from the group layer
* Object layer flag was set too soon for group duplication.
2010-11-03 16:51:25 +00:00
57fd35ae26 A few texture node properties still had old rna names in draw code. 2010-11-03 15:30:24 +00:00
b350954501 [#23095] If no camera is present, a render starts but does nothing, and we have no "No camera" warning
Improve camera checking and move it before starting render jobs
2010-11-03 13:10:09 +00:00
1f2469d992 bugfix [#24508] Render and changing scenes crashes.
The scenes 'Render' is kept by blender while blender runs but the callbacks were not cleared when the render was done.
In this case the callback would reference a freed render job.

This isn't normally a problem because on re-rendering new callbacks are set, however the sequencer can render a previously rendered scene without setting up callbacks.
Simple fix is to to dummy callbacks applied onto the scenes 'Render' struct once its finished.
2010-11-03 11:14:02 +00:00
c31536fc53 bugfix [#24445] NLA reverse option flickers
UnMapping the reversed NLA strips timing was incorrect.
2010-11-03 08:46:14 +00:00
fe8d5b81b0 use c90 compatible static initializers. 2010-11-03 06:31:53 +00:00
de8e066a1c bugfix [#24505] Python command bpy.ops.transform.rotate(...) does not follow axis=(...) attribute
the axis was being constantly re-initialized from the view.
2010-11-03 04:38:07 +00:00
3db9233ae5 bugfix [#24483] Link/Append File Browser Typo 2010-11-03 03:45:09 +00:00
44f3f03f02 paint/face mask lasso select was checking for uv coords, which isnt needed, also make a mistake on this check last commit. 2010-11-03 02:50:05 +00:00
bcd2d60557 added metaball lasso select. 2010-11-03 02:28:11 +00:00
6b767b8018 fix [#24499] Consistency Issue with LassoSelect/ExtendOption
Added extend option to lasso. 

also...
- selecting bones wasn't checking their layer of if they were hidden in a number of places.
- fixed memory leak.

small unrealed changes
- added PBONE_VISIBLE macro
- renamed functions used for paint selectoin from *_tface to paintface_*. sine they no longer have anything todo with tface's.
- removed scanfill include from BLI_blenlib.h, this is only used in very few places and quite specific.


Noticed lasso select is broken for metaballs and face mask mode but this has been the case for a while, will look into it next.
2010-11-03 01:56:02 +00:00
b9c3bfa053 bugfix [#24392] 2d Image paint editor: no clone/smear/soften tools etc 2010-11-02 22:04:41 +00:00
1c5f72f273 - remove BLANK* from rna icon enum, would string search this list for every python icon button call, enum from 818 down to 444.
- remove unused space image members
2010-11-02 21:43:47 +00:00
09435ec149 Oops, particle collisions didn't take simulation subframes into account at all.
* This caused nearly all particles to leak through the collision surface if simulation subframes were used and the collision object was moving.
* In addition to fixing this I also did some more cleanup of the collision code and refined some of the comments.
2010-11-02 21:16:41 +00:00
130088300b Fix for [#24501] Apeend object with cloth sim from another file crash. 2010-11-02 15:21:43 +00:00
369a5cc29e fix for compiling with the c90 standard, support for non-static variable initializers is a c99 feature. 2010-11-02 13:12:30 +00:00
5d7ed88f17 Fix #24436: GLSL + Node material gives wrong color. 2010-11-02 12:18:49 +00:00
f3e3d59f04 Fix #24435: GLSL 3D view lacks refresh on node setups, patch by Lukas Toenne. 2010-11-02 11:41:25 +00:00
342e79461b bugfix [#24398] Select Nth
- use first selected if non active (clears confusion since this isn't at all clear)
- dont take unselected into account when calculating connectivity, would mess up in many cases.
2010-11-02 11:14:04 +00:00
55ad862386 UI:
* Sampled Motion Blur Panel missed check for compatible engines, causing the panel to appear in Game Engine and Netrender as well.
2010-11-02 11:10:21 +00:00
5fb6c942b7 Fix #24485: Applying scale to multires object end up in a blender crash
Fixed multires_apply_smat to work properly with different current and
total subdivision levels.
2010-11-02 10:55:49 +00:00
f130d4c0a7 bugfix [#24455] Scene is left at last rendered frame from rendering an animation 2010-11-02 09:34:32 +00:00
ca3ade6ac4 Patch [#24497] Fix for [#24484] Right Ctrl for snapping by Alexander Kuznetsov. Thank you!
This fixes [#24484] Right Hand Ctrl key none functional for snapping?
2010-11-02 09:04:57 +00:00
8221ed36d0 patch [#24496] Fix for exporting animations to OBJ format.
from Keith Astoria (kastoria)
2010-11-02 04:12:00 +00:00
8503bcde23 bugfix for exporting an FBX animation for an object that was the child of an armature deformed mesh. 2010-11-02 01:12:00 +00:00
0e588cbf10 use __slots__ for fbx exporter classes, no functional change. 2010-11-02 00:39:07 +00:00
562731fc12 Recommit sharp font optional code as all Freetype should be above 2.1.10 now.
If still fails, check & update Freetype (OS one or Blender's lib/).
2010-11-01 23:26:04 +00:00
2cef9203ba Add PREFIX support to makefiles. 2010-11-01 23:17:58 +00:00
aef7d52ea7 Fix #24464: missing icons. It looks like there were some icons still named
from the 2.4 them but they were never in the 2.5 theme, so marked as BLANK
now.
2010-11-01 22:28:58 +00:00
7e913f25c2 throw an error is PREFIX isnt defined on X11 systems. defaults to /usr/local 2010-11-01 22:26:56 +00:00
6ee21ceefb Fix #24489: decimate modifier: undecimated is "ratio 1.00%".
Patch by Emil Brink, thanks!
2010-11-01 21:53:35 +00:00
5ef1cf4b19 Fix for some enum property identifiers, that were not using upper case
with underscore, or were simply not set correctly after code copy/paste.
2010-11-01 21:45:38 +00:00
010106a1f6 [#24491] not possible to create a new Rendering preset than "add render preset.py"
- Setting operator properties was broken because of bpy_types.py meta-classing (surprising this wasn't noticed before!)
- Presets now use a dialog with an OK button.
- Presets use a check function on the filename so invalid chars are replaced editing.
- Submit docs operator was broken.
2010-11-01 21:07:25 +00:00
f890b00851 Sequencer: fix for the fix of: #23318
also known as: broken multicam strip caused by other fix.

Calculated render_size where it belongs (within the glow effect) and 
restored old functionality.

also: renamed render_size to preview_render_size at all relevant places, 
where the naming wasn't used correctly.

Hopefully it's now a little bit more clear. 

render_size := render size from scene (just rescales width/height)
preview_render_size := preview render size from sequencer preview, 
  controls the resolution and the use of sequencer proxy sources
2010-11-01 18:55:12 +00:00
1b18ea5823 == FFMPEG ==
This fixes a rather subtle seeking issue with ffmpeg and Sony 
XDCAM-footage.

Problem is: MPEG2 streams within an MP4 container can contain a start 
time - at several places. There is a starttime within the video 
and audio streams and one within the container.

FFMpeg commandline tool only uses the container starttime and we used 
the stream starttime. 

The world would be a better place, if those two timestamps always match 
up, since in XDCAM-footage those two starttimes differ in 4 
frames - and the container has the right one.

We now always use the container start time as ffmpeg commandline tool 
does (in the hope, that there is a good explaination for this and this 
is the right thing(tm) to do).

I tested this also with HDV footage, which seems to work with the new 
code, too.

Additional fix: disabled seek_by_bytes again, since it will only work 
correctly, if ffmpeg guessed the HDV bitrate right (which it doesn't). 
If you have seeking issues with HDV and have an older version of ffmpeg 
installed, please upgrade, newer versions have some fixes in them.
2010-11-01 18:13:10 +00:00
3a8c37bb24 "Fix" for [#22537] motion blur render result incorrect when full sample anti-aliasing is selected
* FSA and motion blur can't work nicely together the way they're currently implemented, so I disabled this in the ui and code.
* FSA is used if both are selected.
* Also changed the name "Full Sample Motion Blur" to "Sampled Motion Blur" to avoid confusion with full sample anti-aliasing.
2010-11-01 13:51:11 +00:00
726e6d8530 == blender file format ==
- added a readme so that it's easy to understand how to use the py files.
- fixed typos in the usage message.
2010-11-01 13:27:33 +00:00
e40b4d80c6 improvement to axis/angle gimble conversion added last commit. fixed flipping problems and enabled for pose bones. 2010-11-01 11:50:15 +00:00
a55627339c Temporary revert recent changes in blf_glyph.c until its fixed.
>> Compile failure on windows platform (see ML for Errors).

SVN Revert of Revisions: 32805, 32804 and 32802
2010-11-01 10:48:48 +00:00
08fbe28464 bugfix [#24480] Axis Angle + manipulators: bad behaviour 2010-11-01 10:29:05 +00:00
84a3282933 Patch: [#24479] fix for bug 24474, by Anthony Edlin. Thanks!
This fixes [#24474] Pressing <Shift Alt A> or clicking "Play Animation ... reverse = True" does not play animation backwards
2010-11-01 10:22:46 +00:00
daa4feaaea bugfix [#24477] Can easily create bones with duplicate names
- fixed this error 7 different functions (deform groups, uv layers & similar).
- support for numbers over 999.
- renamed splitIDname() to BLI_split_name_num(), moved to BLI_path_utils
2010-11-01 07:19:41 +00:00
8bbcef4c7a bugfix [#24449] User Preferences - Interface - Manipulator 2010-11-01 02:22:20 +00:00
f1e10b0935 Fix silly column paste. 2010-11-01 01:48:43 +00:00
d9a7358b4c bugfix [#24462] UV Layouts saved as PNG results in two files (one is 0 KB, other has corrupted filename) 2010-11-01 01:46:26 +00:00
29bcda37fd Provide a way to get non-AA font rendering, which some see as "sharper".
"Configuration" by recompilation for now (feel free to code that).
2010-11-01 01:45:40 +00:00
a6007d1a5c A couple of changes to 2D filters to make adding new built-in ones nicer:
* Built-in filters were not being analyzed, which means no depth or luminance textures for them
  * Removed an unnecessary if that becomes really hairy when new built-in filters are added (ie, when filters are defined beyond the value used for custom filters)
2010-11-01 00:15:12 +00:00
604f0ae301 Fix name, update others to match style. 2010-11-01 00:09:33 +00:00
24cd951f42 bugfix [#24470] Ctrl+Tweak cutting connections fail 2010-10-31 22:19:52 +00:00
3367ef8b65 initialize structs to zero rather then using memset(). 2010-10-31 15:39:37 +00:00
4c80d13e54 Audaspace: Disabling High- and Lowpass for Bake Sound to F-Curve Operator in case they're unused. 2010-10-31 14:44:45 +00:00
184b5fd6db bugfix [#24466] Selecting of object with pattern leads to strange behavior
The undo problem was caused by python operators returning 'RUNNING_MODAL' rather then the return value from wm.invoke_props_popup(self, event) - 'FINISHED'.

This was done because returning FINISHED would free the operator causing the buttons redo handler to try and run a freed operator and crash.

So the real fix is to disallow any operators to use wm.invoke_props_popup(self, event) if they dont have the REGISTER option enabled, fixing the crash and redo problem.
2010-10-31 14:43:30 +00:00
391c547208 Fix for #24453: Missing delete statement. 2010-10-31 14:21:06 +00:00
6b677a2616 own recent commit broke this python import:
from mathutils.geometry import PolyFill

I couldn't find a way for python's inittab to do this so just inserting mathutils.geometry into sys.modules manually.
2010-10-31 13:17:39 +00:00
3a3ac0de8f Fix #23283: crash exiting blender player, IMB_exit got called twice. 2010-10-31 12:43:42 +00:00
12812e494f Fix cmake building of blender player. 2010-10-31 12:31:15 +00:00
Dalai Felinto
89ceb3b87a bugfix: "glsl lamp not (directly) updated when there is no material in the object" reported by Olivier Amrein
lamps require a depsgraph update.
There is no more need to ED_render_id_flush_update because this is called by the DAG_id_flush_update.
help (and the right fix) from Brecht.
2010-10-31 12:12:57 +00:00
06abc862b0 Fix crashing running read full sample layers operator. 2010-10-31 11:51:10 +00:00
Nathan Letwory
beb5f84991 stdint include needed on non-msvc platforms 2010-10-31 08:42:42 +00:00
0876fce009 rename and negate DISABLE_PYTHON --> WITH_PYTHON 2010-10-31 04:11:39 +00:00
50dab4fc37 rename definition for enabling the game engine GAMEBLENDER==1 --> WITH_GAMEENGINE 2010-10-31 03:20:33 +00:00
Nathan Letwory
73f21f20b7 Lock to Cursor
Patch by Dan Eicher. In 3dview properties you can enable this. Rotating view then uses cursor as pivot point. Note that with this option enabled just relocating the 3d cursor also changes the 3dview.

Sebastian König: "Now the 3d cursor is actually useful" (sitting next to me while applying patch at bconf hostel)
2010-10-31 01:18:26 +00:00
bae43df4ec building the BGE without bullet works again. 2010-10-31 01:04:31 +00:00
7f5abb7fe2 dont build blender/kernel if the game engines disabled. 2010-10-31 00:56:46 +00:00
b349f7c99d Minor speedups for 3D view text drawing ~10-15% improved frame-rate with particle display.
- ascii text drawing functions, slightly faster since they dont have to do hash lookups & utf8 conversions for each char.
- used ascii drawing functions for the view3d's number display.
- each text item was using fixed 128 chars, now only allocate the string length needed.
2010-10-30 23:02:38 +00:00
97d2ca8a33 Sequence editor code cleanup
* The logic in some parts of the sequencer code was rather cryptic, so I cleaned it up a bit.
* There should be no functional changes what so ever from these changes.
2010-10-30 21:55:17 +00:00
c2b9dfaff2 fix for own mistake with mat4_to_loc_rot_size(), flipping the scale on negative matrix isn't correct. 2010-10-30 19:52:40 +00:00
90e9970094 change mat4_to_eulO, mat3_to_eulO to calculate 2 rotations and return the smallest one.
mat4_to_eul & mat3_to_eul are already working this way.

Without this we get problems with constraints, eg:
 rotation on the Y axis over 90d can be represented by setting the X and Z to -PI, Y would decrease to 0 (infact 180d).
2010-10-30 19:29:11 +00:00
44e6026626 the pivot constraint was translating when the pivot was offset along the rotation axis.
fixed by projecting the pivot along the axis of rotation and subtracting this from the pivot.
2010-10-30 18:42:11 +00:00
082e9b329d Fix for [#24458] Problem with Axis Angle rotation
* Added checks to handle zero axis vector.
2010-10-30 17:42:08 +00:00
001259ccb6 warning/portability fixes. 2010-10-30 17:16:37 +00:00
c69f2eaca9 Fix for [#24448] User Preferences - Interface - Mini Axis - Brightness, none working?
* The axis draw function was changed by Campbell recently, but the brightness value was forgotten?
* Solved currently by mapping the brightness value to axis alpha.
2010-10-30 17:13:03 +00:00
d29d972e33 Fix for [#23318] SEQUENCER EFFECT: Glow blur amount should be relative 2010-10-30 15:20:48 +00:00
e548e3e1d8 == blender file format ==
Hello, from the bconf 2010 from Jeroen and Luca. Our first combined commit :)

Automatically create sdna documentations from Trunk.

Usage: 
        blender2.5 -b -P BlendFileDnaExporter_25.py [-- [options]]
Options:
        --dna-keep-blend:      doesn't delete the produced blend file DNA export to html
        --dna-debug:           sets the logging level to DEBUG (lots of additional info)
        --dna-versioned'       saves version informations in the html and blend filenames
        --dna-overwrite-css'   overwrite dna.css, useful when modifying css in the script
Examples:
        default:       % blender2.5 -b -P BlendFileDnaExporter_25.py
        with options:  % blender2.5 -b -P BlendFileDnaExporter_25.py -- --dna-keep-blend --dna-debug
2010-10-30 13:25:24 +00:00
ae9c4b1649 Info text for scene strips showing the frame range that's set in the scene
* Related to bug report [#24329] scene length not updated in VSE
* This data is nice to have in the sequencer without having to go the actual scene that's added as a strip.
2010-10-30 13:09:31 +00:00
ef3e5a3d71 Fix for [#24374] VSE: Reassign Inputs ignores selection order.
* No way currently to know the order of effect inputs, so I added a swap operator for the inputs.
* Also added the effect inputs to the strip property panel (weren't even in rna before). These are not yet editable, but can be very helpful in determining what the inputs are if the strip is too short to see the name in the timeline.
2010-10-30 12:04:00 +00:00
a12d0fc836 Fix for [#24409] Particle corruption after rendering with multires
* Also removed some unused flags from the particle modifier.
2010-10-30 10:19:30 +00:00
210915e3c7 Fix for items 3 and 8 of [#24443] Trying to bake a smoke simulation crashes blender, and other smoke bugs. 2010-10-30 08:51:50 +00:00
bd8758561f Build fix by Mike S 2010-10-30 02:59:42 +00:00
ced06081b8 use PyImport_ExtendInittab for py module initialization rather then adding to sys.modules directly, no functional change. 2010-10-29 22:59:39 +00:00
719c941c58 bugfix [#23155] Metastrip contents area allowed to move vertically, occasionally swapping order or overlapping
overlapping tests cant be done recursively
2010-10-29 19:40:45 +00:00
f921f91454 Fix for[#24422] Crash when switching to Point Select Mode - particle hair 2010-10-29 12:49:36 +00:00
ce74b14850 Fix for [#24430] Hair Dynamics Problem
* Hair added in particle mode didn't have any weights assigned.
2010-10-29 10:31:45 +00:00
6a9a49f8af bugfix for grease pencil freeing order.
it was freed before objects which would then decrease its usercount - accessing freed memory.

Also fixed error in own last commit.
2010-10-29 07:11:45 +00:00
b4a6418518 extensions_framework: minor string change 2010-10-28 21:20:57 +00:00
b5b48bd53a bugfix [#24439] Smear 2D paint fails
small unrelated change: when setting the image type of an image, loop over all its Imbufs and set them.
2010-10-28 19:40:05 +00:00
651efb3763 bugfix [#24428] Interface Regions will not keep relative proportions
screen verts were being rounded so resizing a window would end up moving the border in one direction.
for this to work properly we should store floats internally but for now compensate for this.
2010-10-28 17:46:31 +00:00
4bfd915f9c pencils down! additional Windows Wacom wackiness. 2010-08-16 18:59:36 +00:00
2c468d9e5a Further hacking on Windows tablet code. More accurate detection of certain tablet tools (mice, etc.). Made tablet mouse/pen buttons play nice with GHOST. Removed old code from WindowWin32. 2010-08-15 11:02:03 +00:00
0473790bbe removed gpencil Manhattan distance from user prefs. updated ghost build script. 2010-08-14 23:33:22 +00:00
91e2a55171 continued Win32 tablet hackery 2010-08-14 21:01:09 +00:00
7428380cc3 still working on tablet for Windows... 2010-08-13 00:34:57 +00:00
fc5c4d98f4 Minor cleanup of Windows tablet code. 2010-08-12 14:02:38 +00:00
1232bb6923 Better Intuos4 support on Windows. 2010-08-12 13:04:00 +00:00
485d1ef06e Updated Win32 tablet code. 2010-08-12 04:03:40 +00:00
1c2d36344c Linux compiles again, no SpaceNav yet. 2010-08-10 09:56:39 +00:00
4bf887d4d3 SpaceNav works in 3D view on Windows. Cleaned up related WIP code. 2010-08-10 09:51:22 +00:00
ced1bd9e7d Windows shell/IE #define. 2010-08-08 05:08:35 +00:00
757f75b768 merged 30707:31141 from trunk 2010-08-07 12:51:51 +00:00
f399481251 SpaceNav turntable and fit in 3D view. Tablet data rides with cursor/button events (incomplete! Mac-only for now). Grease pencil works better with pen. 2010-08-07 10:57:15 +00:00
ad623ddd82 merged 29285:30707 from trunk 2010-07-25 10:09:17 +00:00
b0193772da removing Mac C++ file (contents same as Obj-C++ file), since TortoiseSVN's 'rename' forgot to do it 2010-07-25 08:38:13 +00:00
a7ba245fe3 Activated NDOF capture for Windows. Robust++ for generic NDOF manager. Removed experimental Win32 mouse and NDOF code now that good solutions are in place. Cleaned up formatting. 2010-07-24 11:06:08 +00:00
a51ebf247f Renamed Mac file to exclude it from Windows build. Revoke this cowardly commit once I figure out how to properly fix the build script! 2010-07-24 06:49:24 +00:00
c4c46e4403 mostly formatting: put SystemCocoa on a diet of a thousand tabs, also spotted and fixed a leaky switch-case (trackpad gesture for 'rotate') 2010-07-23 10:03:22 +00:00
6216199af8 SpaceNav event capture for MacOS, dispatch for all platforms. To compile this, you need their Mac driver installed and to send '-weak_framework 3DconnexionClient' to the linker. I'm also exploring a HID Manager version, bypassing their driver (and any licensing issues). 2010-07-23 06:45:59 +00:00
47ea957c9d provided a way for NDOF manager to poke SystemCocoa about out-of-loop events 2010-07-23 06:36:08 +00:00
195ad03901 more preliminary NDOF handling stuff (untested) 2010-07-22 09:30:01 +00:00
6c2dee0198 revamped NDOF event system for ghost, added (untested) Mac support 2010-07-22 07:23:41 +00:00
f0167c6a41 get more mouse events only when in hi-fi mode 2010-07-22 07:18:12 +00:00
b86a25efba removed some NDOF plugin-related code 2010-07-22 07:15:00 +00:00
8a4d43427d removed more unused Macintosh Carbon code 2010-07-22 07:10:57 +00:00
1a27b5a74d removed unused Macintosh Carbon code 2010-07-22 07:07:28 +00:00
14736cab16 Added rudimentary SpaceNav event capture code for Windows.
Disabled RawInput mouse code.
2010-07-17 05:52:46 +00:00
8a138f4ab2 fixed misspelled variable in Wacom utility 2010-07-17 05:49:41 +00:00
f6730216e0 Tweak Windows #includes to require WinXP or newer and speed up build times. 2010-07-15 12:30:16 +00:00
7aa8ae3781 Hi-fi mouse input on Windows!
The remains of a RawInput mouse attempt are included, but disabled. RawInput will still be used for multi-axis devices. 

Eliminated the need for several #defines by requiring WinXP or newer.
2010-07-15 12:24:14 +00:00
5b1925afba Improved tablet support on Windows. Nice deep queue for input points. Much more is being captured now. WT_PACKET events are disabled until I can revisit in a day or two.
Also added Wacom's driver wrappers, with their permission. These won't live here very long, but the WindowWin32 tablet code uses it for now.
2010-07-15 12:12:52 +00:00
56b287bfe6 disabled lo-fi dispatch log to reduce event debugging noise 2010-07-15 11:54:24 +00:00
12d7b10c10 added filtered event dispatch for lo-fi mouse/pen input 2010-07-08 01:53:36 +00:00
6365cb3fa8 much-improved tablet handling; hi-fi input for mouse/pen 2010-07-03 07:03:21 +00:00
09f6604241 preparing for NDOF overhaul 2010-07-03 06:58:29 +00:00
905fcc7b74 guarding printf calls as MinGW (gcc 4.5) insists 2010-07-03 03:53:06 +00:00
d5cdfb18f6 removed unused #include 2010-06-26 01:34:49 +00:00
185c77989e hint for mouse/pen input fidelity 2010-06-25 00:09:50 +00:00
da314f51bf fixed tablet mouse spasm bug and refactored event handling 2010-06-19 10:35:01 +00:00
707220b150 gpencil simplified filtering, unbiased smoothing, and pen eraser that works 2010-06-14 02:03:01 +00:00
6154ea9f28 merged 28477:29285 from trunk 2010-06-07 00:08:01 +00:00
7a853f6d19 branching for GSOC 2010 2010-04-27 22:29:11 +00:00
3489 changed files with 305202 additions and 196452 deletions

File diff suppressed because it is too large Load Diff

182
GNUmakefile Normal file
View File

@@ -0,0 +1,182 @@
# -*- mode: gnumakefile; tab-width: 8; indent-tabs-mode: t; -*-
# vim: tabstop=8
# $Id$
#
# ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# ##### END GPL LICENSE BLOCK #####
# This Makefile does an out-of-source CMake build in ../build/`OS`_`CPU`
# eg:
# ../build/Linux_i386
# This is for users who like to configure & build blender with a single command.
# System Vars
OS:=$(shell uname -s)
OS_NCASE:=$(shell uname -s | tr '[A-Z]' '[a-z]')
# CPU:=$(shell uname -m) # UNUSED
# Source and Build DIR's
BLENDER_DIR:=$(shell pwd -P)
BUILD_DIR:=$(shell dirname $(BLENDER_DIR))/build/$(OS_NCASE)
BUILD_TYPE:=Release
BUILD_CMAKE_ARGS:=""
# -----------------------------------------------------------------------------
# additional targets for the build configuration
# support 'make debug'
ifneq "$(findstring debug, $(MAKECMDGOALS))" ""
BUILD_DIR:=$(BUILD_DIR)_debug
BUILD_TYPE:=Debug
endif
ifneq "$(findstring lite, $(MAKECMDGOALS))" ""
BUILD_DIR:=$(BUILD_DIR)_lite
BUILD_CMAKE_ARGS:=$(BUILD_CMAKE_ARGS) -C$(BLENDER_DIR)/build_files/cmake/config/blender_lite.cmake
endif
ifneq "$(findstring headless, $(MAKECMDGOALS))" ""
BUILD_DIR:=$(BUILD_DIR)_bpy
BUILD_CMAKE_ARGS:=$(BUILD_CMAKE_ARGS) -C$(BLENDER_DIR)/build_files/cmake/config/blender_headless.cmake
endif
ifneq "$(findstring bpy, $(MAKECMDGOALS))" ""
BUILD_DIR:=$(BUILD_DIR)_bpy
BUILD_CMAKE_ARGS:=$(BUILD_CMAKE_ARGS) -C$(BLENDER_DIR)/build_files/cmake/config/bpy_module.cmake
endif
# -----------------------------------------------------------------------------
# Get the number of cores for threaded build
NPROCS:=1
ifeq ($(OS), Linux)
NPROCS:=$(shell grep -c ^processor /proc/cpuinfo)
endif
ifeq ($(OS), Darwin)
NPROCS:=$(shell sysctl -a | grep "hw.ncpu " | cut -d" " -f3)
endif
ifeq ($(OS), FreeBSD)
NPROCS:=$(shell sysctl -a | grep "hw.ncpu " | cut -d" " -f3 )
endif
ifeq ($(OS), NetBSD)
NPROCS:=$(shell sysctl -a | grep "hw.ncpu " | cut -d" " -f3 )
endif
# -----------------------------------------------------------------------------
# Build Blender
all:
@echo
@echo Configuring Blender ...
if test ! -f $(BUILD_DIR)/CMakeCache.txt ; then \
cmake $(BUILD_CMAKE_ARGS) -H$(BLENDER_DIR) -B$(BUILD_DIR) -DCMAKE_BUILD_TYPE:STRING=$(BUILD_TYPE); \
fi
@echo
@echo Building Blender ...
$(MAKE) -C $(BUILD_DIR) -s -j $(NPROCS) install
@echo
@echo edit build configuration with: "$(BUILD_DIR)/CMakeCache.txt" run make again to rebuild.
@echo blender installed, run from: "$(BUILD_DIR)/bin/blender"
@echo
debug: all
lite: all
headless: all
bpy: all
# -----------------------------------------------------------------------------
# Helo for build targets
help:
@echo ""
@echo "Convenience targets provided for building blender, (multiple at once can be used)"
@echo " * debug - build a debug binary"
@echo " * lite - disable non essential features for a smaller binary and faster build"
@echo " * headless - build without an interface (renderfarm or server automation)"
@echo " * bpy - build as a python module which can be loaded from python directly"
@echo ""
@echo "Project Files for IDE's"
@echo " * project_qtcreator - QtCreator Project Files"
@echo " * project_netbeans - NetBeans Project Files"
@echo " * project_eclipse - Eclipse CDT4 Project Files"
@echo ""
@echo "Package Targets"
@echo " * package_debian - build a debian package"
@echo " * package_pacman - build an arch linux pacmanpackage"
@echo " * package_archive - build an archive package"
@echo ""
@echo "Testing Targets (not assosiated with building blender)"
@echo " * test - run ctest, currently tests import/export, operator execution and that python modules load"
@echo " * test_cmake - runs our own cmake file checker which detects errors in the cmake file list definitions"
@echo " * test_pep8 - checks all python script are pep8 which are tagged to use the stricter formatting"
@echo " * test_deprecated - checks for deprecation tags in our code which may need to be removed"
@echo ""
# -----------------------------------------------------------------------------
# Packages
#
package_debian:
cd build_files/package_spec ; DEB_BUILD_OPTIONS="parallel=$(NPROCS)" sh ./build_debian.sh
package_pacman:
cd build_files/package_spec/pacman ; MAKEFLAGS="-j$(NPROCS)" makepkg --asroot
package_archive:
make -C $(BUILD_DIR) -s package_archive
@echo archive in "$(BUILD_DIR)/release"
# -----------------------------------------------------------------------------
# Tests
#
test:
cd $(BUILD_DIR) ; ctest . --output-on-failure
# run pep8 check check on scripts we distribute.
test_pep8:
python3 source/tests/pep8.py > test_pep8.log 2>&1
@echo "written: test_pep8.log"
# run some checks on our cmakefiles.
test_cmake:
python3 build_files/cmake/cmake_consistency_check.py > test_cmake_consistency.log 2>&1
@echo "written: test_cmake_consistency.log"
# run deprecation tests, see if we have anything to remove.
test_deprecated:
python3 source/tests/check_deprecated.py
# -----------------------------------------------------------------------------
# Project Files
#
project_qtcreator:
python3 build_files/cmake/cmake_qtcreator_project.py $(BUILD_DIR)
project_netbeans:
python3 build_files/cmake/cmake_netbeans_project.py $(BUILD_DIR)
project_eclipse:
cmake -G"Eclipse CDT4 - Unix Makefiles" -H$(BLENDER_DIR) -B$(BUILD_DIR)
clean:
$(MAKE) -C $(BUILD_DIR) clean
.PHONY: all

View File

@@ -1,60 +0,0 @@
# -*- mode: gnumakefile; tab-width: 8; indent-tabs-mode: t; -*-
# vim: tabstop=8
# $Id$
#
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
# The Original Code is Copyright (C) 2002 by Wouter van Heyst
# All rights reserved.
#
# The Original Code is: revision 1.1
#
# Contributor(s): Hans Lambermont, GSR
#
# ***** END GPL LICENSE BLOCK *****
#
# Toplevel Makefile for blender. Bounces make to subdirectories.
# Available targets: 'all' 'debug' 'release'
# If the user wants to override some of the build
# vars they can put it in the file user-def.mk which
# will get included if it exists (please do not commit
# user-def.mk to the revision control server).
sinclude user-def.mk
# To build without openAL, set it as an environment variable,
# or put it uncommented in user-def.mk:
# export NAN_NO_OPENAL=true
export NANBLENDERHOME=$(shell pwd)
MAKEFLAGS=-I$(NANBLENDERHOME)/build_files/make --no-print-directory
SOURCEDIR =
ifeq ($(FREE_WINDOWS),true)
DIRS ?= $(NANBLENDERHOME)/build_files/make/dlltool extern intern source po
else
DIRS ?= extern intern source po
endif
include build_files/make/nan_subdirs.mk
.PHONY: release
release:
@echo "====> $(MAKE) $@ in $(SOURCEDIR)/$@" ;\
$(MAKE) -C $@ $@ || exit 1;

View File

@@ -28,6 +28,8 @@
# Main entry-point for the SCons building system
# Set up some custom actions and target/argument handling
# Then read all SConscripts and build
#
# TODO: fix /FORCE:MULTIPLE on windows to get proper debug builds.
import platform as pltfrm
@@ -58,6 +60,10 @@ import bcolors
EnsureSConsVersion(1,0,0)
# Before we do anything, let's check if we have a sane os.environ
if not btools.check_environ():
Exit()
BlenderEnvironment = Blender.BlenderEnvironment
B = Blender
@@ -70,7 +76,7 @@ quickdebug = None
##### BEGIN SETUP #####
B.possible_types = ['core', 'player', 'intern', 'extern']
B.possible_types = ['core', 'player', 'player2', 'intern', 'extern']
B.binarykind = ['blender' , 'blenderplayer']
##################################
@@ -105,6 +111,11 @@ btools.print_targets(B.targets, B.bc)
# handling cmd line arguments & config file
# bitness stuff
tempbitness = int(B.arguments.get('BF_BITNESS', bitness)) # default to bitness found as per starting python
if tempbitness in (32, 64): # only set if 32 or 64 has been given
bitness = int(tempbitness)
# first check cmdline for toolset and we create env to work on
quickie = B.arguments.get('BF_QUICK', None)
quickdebug = B.arguments.get('BF_QUICKDEBUG', None)
@@ -140,7 +151,6 @@ if not env:
print "Could not create a build environment"
Exit()
cc = B.arguments.get('CC', None)
cxx = B.arguments.get('CXX', None)
if cc:
@@ -148,16 +158,21 @@ if cc:
if cxx:
env['CXX'] = cxx
if env['CC'] in ['cl', 'cl.exe'] and sys.platform=='win32':
if bitness == 64:
platform = 'win64-vc'
else:
platform = 'win32-vc'
elif env['CC'] in ['gcc'] and sys.platform=='win32':
platform = 'win32-mingw'
if sys.platform=='win32':
if env['CC'] in ['cl', 'cl.exe']:
platform = 'win64-vc' if bitness == 64 else 'win32-vc'
elif env['CC'] in ['gcc']:
platform = 'win32-mingw'
env.SConscriptChdir(0)
# Remove major kernel version from linux platform.
# After Linus switched kernel to new version model this major version
# shouldn't take much sense for building rules.
if re.match('linux[0-9]+', platform):
platform = 'linux'
crossbuild = B.arguments.get('BF_CROSS', None)
if crossbuild and platform not in ('win32-vc', 'win64-vc'):
platform = 'linuxcross'
@@ -192,6 +207,10 @@ else:
opts = btools.read_opts(env, optfiles, B.arguments)
opts.Update(env)
if sys.platform=='win32':
if bitness==64:
env.Append(CFLAGS=['-DWIN64']) # -DWIN32 needed too, as it's used all over to target Windows generally
if not env['BF_FANCY']:
B.bc.disable()
@@ -234,12 +253,31 @@ if 'blenderlite' in B.targets:
target_env_defs['BF_BUILDINFO'] = False
target_env_defs['BF_NO_ELBEEM'] = True
target_env_defs['WITH_BF_PYTHON'] = False
target_env_defs['WITH_BF_3DMOUSE'] = False
# Merge blenderlite, let command line to override
for k,v in target_env_defs.iteritems():
if k not in B.arguments:
env[k] = v
# Extended OSX_SDK and 3D_CONNEXION_CLIENT_LIBRARY detection for OSX
if env['OURPLATFORM']=='darwin':
print B.bc.OKGREEN + "Detected Xcode version: -- " + B.bc.ENDC + env['XCODE_CUR_VER'][:9] + " --"
print "Available " + env['MACOSX_SDK_CHECK']
if not 'Mac OS X 10.5' in env['MACOSX_SDK_CHECK']:
print B.bc.OKGREEN + "MacOSX10.5.sdk not available:" + B.bc.ENDC + " using MacOSX10.6.sdk"
else:
print B.bc.OKGREEN + "Found recommended sdk :" + B.bc.ENDC + " using MacOSX10.5.sdk"
# for now, Mac builders must download and install the 3DxWare 10 Beta 4 driver framework from 3Dconnexion
# necessary header file lives here when installed:
# /Library/Frameworks/3DconnexionClient.framework/Versions/Current/Headers/ConnexionClientAPI.h
if env['WITH_BF_3DMOUSE'] == 1:
if not os.path.exists('/Library/Frameworks/3DconnexionClient.framework'):
print "3D_CONNEXION_CLIENT_LIBRARY not found, disabling WITH_BF_3DMOUSE" # avoid build errors !
env['WITH_BF_3DMOUSE'] = 0
else:
env.Append(LINKFLAGS=['-weak_framework','3DconnexionClient'])
if env['WITH_BF_OPENMP'] == 1:
if env['OURPLATFORM'] in ('win32-vc', 'win64-vc'):
@@ -299,9 +337,10 @@ if env['BF_NO_ELBEEM'] == 1:
env['CXXFLAGS'].append('-DDISABLE_ELBEEM')
env['CCFLAGS'].append('-DDISABLE_ELBEEM')
if env['WITH_BF_SDL'] == False and env['OURPLATFORM'] in ('win32-vc', 'win32-ming', 'win64-vc'):
env['PLATFORM_LINKFLAGS'].remove('/ENTRY:mainCRTStartup')
env['PLATFORM_LINKFLAGS'].append('/ENTRY:main')
# TODO, make optional
env['CPPFLAGS'].append('-DWITH_AUDASPACE')
env['CXXFLAGS'].append('-DWITH_AUDASPACE')
env['CCFLAGS'].append('-DWITH_AUDASPACE')
# lastly we check for root_build_dir ( we should not do before, otherwise we might do wrong builddir
B.root_build_dir = env['BF_BUILDDIR']
@@ -353,6 +392,23 @@ if not quickie and do_clean:
print B.bc.HEADER+'Already Clean, nothing to do.'+B.bc.ENDC
Exit()
# ensure python header is found since detection can fail, this could happen
# with _any_ library but since we used a fixed python version this tends to
# be most problematic.
if env['WITH_BF_PYTHON']:
py_h = os.path.join(Dir(env.subst('${BF_PYTHON_INC}')).abspath, "Python.h")
if not os.path.exists(py_h):
print("\nMissing: \"" + env.subst('${BF_PYTHON_INC}') + os.sep + "Python.h\",\n"
" Set 'BF_PYTHON_INC' to point "
"to a valid python include path.\n Containing "
"Python.h for python version \"" + env.subst('${BF_PYTHON_VERSION}') + "\"")
Exit()
del py_h
if not os.path.isdir ( B.root_build_dir):
os.makedirs ( B.root_build_dir )
os.makedirs ( B.root_build_dir + 'source' )
@@ -395,23 +451,25 @@ SConscript(B.root_build_dir+'/source/SConscript')
# libraries to give as objects to linking phase
mainlist = []
for tp in B.possible_types:
if not tp == 'player':
if (not tp == 'player') and (not tp == 'player2'):
mainlist += B.create_blender_liblist(env, tp)
if B.arguments.get('BF_PRIORITYLIST', '0')=='1':
B.propose_priorities()
dobj = B.buildinfo(env, "dynamic") + B.resources
creob = B.creator(env)
thestatlibs, thelibincs = B.setup_staticlibs(env)
thesyslibs = B.setup_syslibs(env)
if 'blender' in B.targets or not env['WITH_BF_NOBLENDER']:
env.BlenderProg(B.root_build_dir, "blender", mainlist + thestatlibs + dobj, thesyslibs, [B.root_build_dir+'/lib'] + thelibincs, 'blender')
env.BlenderProg(B.root_build_dir, "blender", creob + mainlist + thestatlibs + dobj, thesyslibs, [B.root_build_dir+'/lib'] + thelibincs, 'blender')
if env['WITH_BF_PLAYER']:
playerlist = B.create_blender_liblist(env, 'player')
playerlist += B.create_blender_liblist(env, 'player2')
playerlist += B.create_blender_liblist(env, 'intern')
playerlist += B.create_blender_liblist(env, 'extern')
env.BlenderProg(B.root_build_dir, "blenderplayer", playerlist, thestatlibs + dobj + thesyslibs, [B.root_build_dir+'/lib'] + thelibincs, 'blenderplayer')
env.BlenderProg(B.root_build_dir, "blenderplayer", dobj + playerlist + thestatlibs, thesyslibs, [B.root_build_dir+'/lib'] + thelibincs, 'blenderplayer')
##### Now define some targets
@@ -487,18 +545,20 @@ if env['OURPLATFORM']!='darwin':
dn.remove('.svn')
if '_svn' in dn:
dn.remove('_svn')
if '__pycache__' in dn: # py3.2 cache dir
dn.remove('__pycache__')
dir = os.path.join(env['BF_INSTALLDIR'], VERSION)
dir += os.sep + os.path.basename(scriptpath) + dp[len(scriptpath):]
source=[os.path.join(dp, f) for f in df if f[-3:]!='pyc']
source=[os.path.join(dp, f) for f in df if not f.endswith(".pyc")]
# To ensure empty dirs are created too
if len(source)==0:
env.Execute(Mkdir(dir))
scriptinstall.append(env.Install(dir=dir,source=source))
#-- icons
if env['OURPLATFORM']=='linux2':
if env['OURPLATFORM']=='linux':
iconlist = []
icontargetlist = []
@@ -558,9 +618,10 @@ pluglist.append('source/blender/blenpluginapi/plugin.DEF')
plugtargetlist.append(os.path.join(env['BF_INSTALLDIR'], VERSION, 'plugins', 'include', 'plugin.def'))
plugininstall = []
for targetdir,srcfile in zip(plugtargetlist, pluglist):
td, tf = os.path.split(targetdir)
plugininstall.append(env.Install(dir=td, source=srcfile))
# plugins in blender 2.5 don't work at the moment.
#for targetdir,srcfile in zip(plugtargetlist, pluglist):
# td, tf = os.path.split(targetdir)
# plugininstall.append(env.Install(dir=td, source=srcfile))
textlist = []
texttargetlist = []
@@ -576,7 +637,7 @@ textinstall = env.Install(dir=env['BF_INSTALLDIR'], source=textlist)
if env['OURPLATFORM']=='darwin':
allinstall = [blenderinstall, plugininstall, textinstall]
elif env['OURPLATFORM']=='linux2':
elif env['OURPLATFORM']=='linux':
allinstall = [blenderinstall, dotblenderinstall, scriptinstall, plugininstall, textinstall, iconinstall]
else:
allinstall = [blenderinstall, dotblenderinstall, scriptinstall, plugininstall, textinstall]
@@ -628,11 +689,17 @@ if env['OURPLATFORM'] in ('win32-vc', 'win32-mingw', 'win64-vc', 'linuxcross'):
dllsources.append('${LCGDIR}/sndfile/lib/libsndfile-1.dll')
if env['WITH_BF_FFMPEG']:
dllsources += ['${BF_FFMPEG_LIBPATH}/avcodec-52.dll',
'${BF_FFMPEG_LIBPATH}/avformat-52.dll',
'${BF_FFMPEG_LIBPATH}/avdevice-52.dll',
'${BF_FFMPEG_LIBPATH}/avutil-50.dll',
'${BF_FFMPEG_LIBPATH}/swscale-0.dll']
dllsources += env['BF_FFMPEG_DLL'].split()
# Since the thumb handler is loaded by Explorer, architecture is
# strict: the x86 build fails on x64 Windows. We need to ship
# both builds in x86 packages.
if bitness == 32:
dllsources.append('${LCGDIR}/thumbhandler/lib/BlendThumb.dll')
dllsources.append('${LCGDIR}/thumbhandler/lib/BlendThumb64.dll')
dllsources.append('#source/icons/blender.exe.manifest')
windlls = env.Install(dir=env['BF_INSTALLDIR'], source = dllsources)
allinstall += windlls
@@ -661,7 +728,14 @@ if 'blenderlite' in B.targets:
Depends(nsiscmd, allinstall)
buildslave_action = env.Action(btools.buildslave, btools.buildslave_print)
buildslave_cmd = env.Command('buildslave_exec', None, buildslave_action)
buildslave_alias = env.Alias('buildslave', buildslave_cmd)
Depends(buildslave_cmd, allinstall)
Default(B.program_list)
if not env['WITHOUT_BF_INSTALL']:
Default(installtarget)

View File

@@ -0,0 +1,94 @@
BF_BUILDDIR = '../blender-build/linux-glibc27-i686'
BF_INSTALLDIR = '../blender-install/linux-glibc27-i686'
BF_NUMJOBS = 2
# Python configuration
BF_PYTHON_VERSION = '3.2'
BF_PYTHON_ABI_FLAGS = 'mu'
BF_PYTHON = '/opt/python3.2'
WITH_BF_STATICPYTHON = True
# OpenCollada configuration
WITH_BF_COLLADA = True
BF_OPENCOLLADA = '/opt/opencollada'
BF_OPENCOLLADA_INC = '${BF_OPENCOLLADA}/include'
BF_OPENCOLLADA_LIB = 'OpenCOLLADAStreamWriter OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils GeneratedSaxParser UTF MathMLSolver buffer ftoa libxml2-static libexpat-static libpcre-static'
BF_OPENCOLLADA_LIBPATH = '${BF_OPENCOLLADA}/lib /home/sources/staticlibs/lib32'
BF_PCRE_LIB = ''
BF_EXPAT_LIB = ''
# FFMPEG configuration
WITH_BF_FFMPEG = True
WITH_BF_STATICFFMPEG = True
BF_FFMPEG = '/home/sources/staticlibs/ffmpeg'
BF_FFMPEG_LIBPATH = '${BF_FFMPEG}/lib32'
BF_FFMPEG_LIB_STATIC = '${BF_FFMPEG_LIBPATH}/libavformat.a ${BF_FFMPEG_LIBPATH}/libswscale.a ' + \
'${BF_FFMPEG_LIBPATH}/libavcodec.a ${BF_FFMPEG_LIBPATH}/libavdevice.a ${BF_FFMPEG_LIBPATH}/libavutil.a ' + \
'${BF_FFMPEG_LIBPATH}/libxvidcore.a ${BF_FFMPEG_LIBPATH}/libx264.a ${BF_FFMPEG_LIBPATH}/libmp3lame.a ' + \
'${BF_FFMPEG_LIBPATH}/libvpx.a ${BF_FFMPEG_LIBPATH}/libvorbis.a ${BF_FFMPEG_LIBPATH}/libogg.a ' + \
'${BF_FFMPEG_LIBPATH}/libvorbisenc.a ${BF_FFMPEG_LIBPATH}/libtheora.a ' + \
'${BF_FFMPEG_LIBPATH}/libschroedinger-1.0.a ${BF_FFMPEG_LIBPATH}/liborc-0.4.a ${BF_FFMPEG_LIBPATH}/libdirac_encoder.a ' + \
'${BF_FFMPEG_LIBPATH}/libfaad.a'
# Don't depend on system's libstdc++
WITH_BF_STATICCXX = True
BF_CXX_LIB_STATIC = '/usr/lib/gcc/i486-linux-gnu/4.3.2/libstdc++.a'
WITH_BF_OPENAL = True
WITH_BF_STATICOPENAL = True
BF_OPENAL_LIB_STATIC = '/opt/openal/lib/libopenal.a'
WITH_BF_GETTEXT_STATIC = True
BF_FREETYPE_LIB_STATIC = True
WITH_BF_OPENEXR = True
WITH_BF_STATICOPENEXR = True
WITH_BF_TIFF = True
WITH_BF_STATICTIFF = True
BF_TIFF_LIB_STATIC = '${BF_TIFF}/lib/libtiff.a'
WITH_BF_JPEG = True
BF_JPEG_LIB = 'libjpeg'
BF_JPEG_LIBPATH = '/home/sources/staticlibs/lib32'
WITH_BF_PNG = True
BF_PNG_LIB = 'libpng'
BF_PNG_LIBPATH = '/home/sources/staticlibs/lib32'
WITH_BF_STATICLIBSAMPLERATE = True
WITH_BF_ZLIB = True
WITH_BF_STATICZLIB = True
BF_ZLIB_LIB_STATIC = '${BF_ZLIB}/lib/libz.a'
WITH_BF_SDL = True
WITH_BF_OGG = True
WITH_BF_OPENMP = True
WITH_BF_GAMEENGINE = True
WITH_BF_BULLET = True
# Blender player (would be enabled in it's own config)
WITH_BF_PLAYER = False
# Use jemalloc memory manager
WITH_BF_JEMALLOC = True
WITH_BF_STATICJEMALLOC = True
BF_JEMALLOC = '/home/sources/staticlibs/jemalloc'
BF_JEMALLOC_LIBPATH = '${BF_JEMALLOC}/lib32'
# Use 3d mouse library
WITH_BF_3DMOUSE = True
WITH_BF_STATIC3DMOUSE = True
BF_3DMOUSE = '/home/sources/staticlibs/spnav'
BF_3DMOUSE_LIBPATH = '${BF_3DMOUSE}/lib32'
# Compilation and optimization
BF_DEBUG = False
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
PLATFORM_LINKFLAGS = ['-L/home/sources/staticlibs/lib32']

View File

@@ -0,0 +1,89 @@
BF_BUILDDIR = '../blender-build/linux-glibc27-i686'
BF_INSTALLDIR = '../blender-install/linux-glibc27-i686'
BF_NUMJOBS = 2
# Python configuration
BF_PYTHON_VERSION = '3.2'
BF_PYTHON_ABI_FLAGS = 'mu'
BF_PYTHON = '/opt/python3.2'
WITH_BF_STATICPYTHON = True
# OpenCollada configuration
WITH_BF_COLLADA = False
# FFMPEG configuration
WITH_BF_FFMPEG = True
WITH_BF_STATICFFMPEG = True
BF_FFMPEG = '/home/sources/staticlibs/ffmpeg'
BF_FFMPEG_LIBPATH = '${BF_FFMPEG}/lib32'
BF_FFMPEG_LIB_STATIC = '${BF_FFMPEG_LIBPATH}/libavformat.a ${BF_FFMPEG_LIBPATH}/libswscale.a ' + \
'${BF_FFMPEG_LIBPATH}/libavcodec.a ${BF_FFMPEG_LIBPATH}/libavdevice.a ${BF_FFMPEG_LIBPATH}/libavutil.a ' + \
'${BF_FFMPEG_LIBPATH}/libxvidcore.a ${BF_FFMPEG_LIBPATH}/libx264.a ${BF_FFMPEG_LIBPATH}/libmp3lame.a ' + \
'${BF_FFMPEG_LIBPATH}/libvpx.a ${BF_FFMPEG_LIBPATH}/libvorbis.a ${BF_FFMPEG_LIBPATH}/libogg.a ' + \
'${BF_FFMPEG_LIBPATH}/libvorbisenc.a ${BF_FFMPEG_LIBPATH}/libtheora.a ' + \
'${BF_FFMPEG_LIBPATH}/libschroedinger-1.0.a ${BF_FFMPEG_LIBPATH}/liborc-0.4.a ${BF_FFMPEG_LIBPATH}/libdirac_encoder.a ' + \
'${BF_FFMPEG_LIBPATH}/libfaad.a'
# Don't depend on system's libstdc++
WITH_BF_STATICCXX = True
BF_CXX_LIB_STATIC = '/usr/lib/gcc/i486-linux-gnu/4.3.2/libstdc++.a'
WITH_BF_OPENAL = True
WITH_BF_STATICOPENAL = True
BF_OPENAL_LIB_STATIC = '/opt/openal/lib/libopenal.a'
WITH_BF_GETTEXT_STATIC = True
BF_FREETYPE_LIB_STATIC = True
WITH_BF_OPENEXR = False
WITH_BF_STATICOPENEXR = True
WITH_BF_TIFF = False
WITH_BF_STATICTIFF = True
BF_TIFF_LIB_STATIC = '${BF_TIFF}/lib/libtiff.a'
WITH_BF_JPEG = True
BF_JPEG_LIB = 'libjpeg'
BF_JPEG_LIBPATH = '/home/sources/staticlibs/lib32'
WITH_BF_PNG = True
BF_PNG_LIB = 'libpng'
BF_PNG_LIBPATH = '/home/sources/staticlibs/lib32'
WITH_BF_STATICLIBSAMPLERATE = True
WITH_BF_ZLIB = True
WITH_BF_STATICZLIB = True
BF_ZLIB_LIB_STATIC = '${BF_ZLIB}/lib/libz.a'
WITH_BF_SDL = True
WITH_BF_OGG = False
WITH_BF_OPENMP = True
WITH_BF_GAMEENGINE = True
WITH_BF_BULLET = True
# Do not build blender when building blenderplayer
WITH_BF_NOBLENDER = True
WITH_BF_PLAYER = True
# Use jemalloc memory manager
WITH_BF_JEMALLOC = True
WITH_BF_STATICJEMALLOC = True
BF_JEMALLOC = '/home/sources/staticlibs/jemalloc'
BF_JEMALLOC_LIBPATH = '${BF_JEMALLOC}/lib32'
# Use 3d mouse library
WITH_BF_3DMOUSE = True
WITH_BF_STATIC3DMOUSE = True
BF_3DMOUSE = '/home/sources/staticlibs/spnav'
BF_3DMOUSE_LIBPATH = '${BF_3DMOUSE}/lib32'
# Compilation and optimization
BF_DEBUG = False
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
PLATFORM_LINKFLAGS = ['-L/home/sources/staticlibs/lib32']

View File

@@ -0,0 +1,89 @@
BF_BUILDDIR = '../blender-build/linux-glibc27-x86_64'
BF_INSTALLDIR = '../blender-install/linux-glibc27-x86_64'
BF_NUMJOBS = 2
# Python configuration
BF_PYTHON_VERSION = '3.2'
BF_PYTHON_ABI_FLAGS = 'mu'
BF_PYTHON = '/opt/python3.2'
WITH_BF_STATICPYTHON = True
# OpenCollada configuration
WITH_BF_COLLADA = False
# FFMPEG configuration
WITH_BF_FFMPEG = True
WITH_BF_STATICFFMPEG = True
BF_FFMPEG = '/home/sources/staticlibs/ffmpeg'
BF_FFMPEG_LIBPATH = '${BF_FFMPEG}/lib64'
BF_FFMPEG_LIB_STATIC = '${BF_FFMPEG_LIBPATH}/libavformat.a ${BF_FFMPEG_LIBPATH}/libswscale.a ' + \
'${BF_FFMPEG_LIBPATH}/libavcodec.a ${BF_FFMPEG_LIBPATH}/libavdevice.a ${BF_FFMPEG_LIBPATH}/libavutil.a ' + \
'${BF_FFMPEG_LIBPATH}/libxvidcore.a ${BF_FFMPEG_LIBPATH}/libx264.a ${BF_FFMPEG_LIBPATH}/libmp3lame.a ' + \
'${BF_FFMPEG_LIBPATH}/libvpx.a ${BF_FFMPEG_LIBPATH}/libvorbis.a ${BF_FFMPEG_LIBPATH}/libogg.a ' + \
'${BF_FFMPEG_LIBPATH}/libvorbisenc.a ${BF_FFMPEG_LIBPATH}/libtheora.a ' + \
'${BF_FFMPEG_LIBPATH}/libschroedinger-1.0.a ${BF_FFMPEG_LIBPATH}/liborc-0.4.a ${BF_FFMPEG_LIBPATH}/libdirac_encoder.a ' + \
'${BF_FFMPEG_LIBPATH}/libfaad.a'
# Don't depend on system's libstdc++
WITH_BF_STATICCXX = True
BF_CXX_LIB_STATIC = '/usr/lib/gcc/x86_64-linux-gnu/4.3.2/libstdc++.a'
WITH_BF_OPENAL = True
WITH_BF_STATICOPENAL = True
BF_OPENAL_LIB_STATIC = '/opt/openal/lib/libopenal.a'
WITH_BF_GETTEXT_STATIC = True
BF_FREETYPE_LIB_STATIC = True
WITH_BF_OPENEXR = False
WITH_BF_STATICOPENEXR = True
WITH_BF_TIFF = False
WITH_BF_STATICTIFF = True
BF_TIFF_LIB_STATIC = '${BF_TIFF}/lib/libtiff.a'
WITH_BF_JPEG = True
BF_JPEG_LIB = 'libjpeg'
BF_JPEG_LIBPATH = '/home/sources/staticlibs/lib64'
WITH_BF_PNG = True
BF_PNG_LIB = 'libpng'
BF_PNG_LIBPATH = '/home/sources/staticlibs/lib64'
WITH_BF_STATICLIBSAMPLERATE = True
WITH_BF_ZLIB = True
WITH_BF_STATICZLIB = True
BF_ZLIB_LIB_STATIC = '${BF_ZLIB}/lib/libz.a'
WITH_BF_SDL = True
WITH_BF_OGG = False
WITH_BF_OPENMP = True
WITH_BF_GAMEENGINE = True
WITH_BF_BULLET = True
# Do not build blender when building blenderplayer
WITH_BF_NOBLENDER = True
WITH_BF_PLAYER = True
# Use jemalloc memory manager
WITH_BF_JEMALLOC = True
WITH_BF_STATICJEMALLOC = True
BF_JEMALLOC = '/home/sources/staticlibs/jemalloc'
BF_JEMALLOC_LIBPATH = '${BF_JEMALLOC}/lib64'
# Use 3d mouse library
WITH_BF_3DMOUSE = True
WITH_BF_STATIC3DMOUSE = True
BF_3DMOUSE = '/home/sources/staticlibs/spnav'
BF_3DMOUSE_LIBPATH = '${BF_3DMOUSE}/lib64'
# Compilation and optimization
BF_DEBUG = False
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
PLATFORM_LINKFLAGS = ['-L/home/sources/staticlibs/lib64']

View File

@@ -0,0 +1,94 @@
BF_BUILDDIR = '../blender-build/linux-glibc27-x86_64'
BF_INSTALLDIR = '../blender-install/linux-glibc27-x86_64'
BF_NUMJOBS = 2
# Python configuration
BF_PYTHON_VERSION = '3.2'
BF_PYTHON_ABI_FLAGS = 'mu'
BF_PYTHON = '/opt/python3.2'
WITH_BF_STATICPYTHON = True
# OpenCollada configuration
WITH_BF_COLLADA = True
BF_OPENCOLLADA = '/opt/opencollada'
BF_OPENCOLLADA_INC = '${BF_OPENCOLLADA}/include'
BF_OPENCOLLADA_LIB = 'OpenCOLLADAStreamWriter OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils GeneratedSaxParser UTF MathMLSolver buffer ftoa libxml2-static libexpat-static libpcre-static'
BF_OPENCOLLADA_LIBPATH = '${BF_OPENCOLLADA}/lib /home/sources/staticlibs/lib64'
BF_PCRE_LIB = ''
BF_EXPAT_LIB = ''
# FFMPEG configuration
WITH_BF_FFMPEG = True
WITH_BF_STATICFFMPEG = True
BF_FFMPEG = '/home/sources/staticlibs/ffmpeg'
BF_FFMPEG_LIBPATH = '${BF_FFMPEG}/lib64'
BF_FFMPEG_LIB_STATIC = '${BF_FFMPEG_LIBPATH}/libavformat.a ${BF_FFMPEG_LIBPATH}/libswscale.a ' + \
'${BF_FFMPEG_LIBPATH}/libavcodec.a ${BF_FFMPEG_LIBPATH}/libavdevice.a ${BF_FFMPEG_LIBPATH}/libavutil.a ' + \
'${BF_FFMPEG_LIBPATH}/libxvidcore.a ${BF_FFMPEG_LIBPATH}/libx264.a ${BF_FFMPEG_LIBPATH}/libmp3lame.a ' + \
'${BF_FFMPEG_LIBPATH}/libvpx.a ${BF_FFMPEG_LIBPATH}/libvorbis.a ${BF_FFMPEG_LIBPATH}/libogg.a ' + \
'${BF_FFMPEG_LIBPATH}/libvorbisenc.a ${BF_FFMPEG_LIBPATH}/libtheora.a ' + \
'${BF_FFMPEG_LIBPATH}/libschroedinger-1.0.a ${BF_FFMPEG_LIBPATH}/liborc-0.4.a ${BF_FFMPEG_LIBPATH}/libdirac_encoder.a ' + \
'${BF_FFMPEG_LIBPATH}/libfaad.a'
# Don't depend on system's libstdc++
WITH_BF_STATICCXX = True
BF_CXX_LIB_STATIC = '/usr/lib/gcc/x86_64-linux-gnu/4.3.2/libstdc++.a'
WITH_BF_OPENAL = True
WITH_BF_STATICOPENAL = True
BF_OPENAL_LIB_STATIC = '/opt/openal/lib/libopenal.a'
WITH_BF_GETTEXT_STATIC = True
BF_FREETYPE_LIB_STATIC = True
WITH_BF_OPENEXR = True
WITH_BF_STATICOPENEXR = True
WITH_BF_TIFF = True
WITH_BF_STATICTIFF = True
BF_TIFF_LIB_STATIC = '${BF_TIFF}/lib/libtiff.a'
WITH_BF_JPEG = True
BF_JPEG_LIB = 'libjpeg'
BF_JPEG_LIBPATH = '/home/sources/staticlibs/lib64'
WITH_BF_PNG = True
BF_PNG_LIB = 'libpng'
BF_PNG_LIBPATH = '/home/sources/staticlibs/lib64'
WITH_BF_STATICLIBSAMPLERATE = True
WITH_BF_ZLIB = True
WITH_BF_STATICZLIB = True
BF_ZLIB_LIB_STATIC = '${BF_ZLIB}/lib/libz.a'
WITH_BF_SDL = True
WITH_BF_OGG = True
WITH_BF_OPENMP = True
WITH_BF_GAMEENGINE = True
WITH_BF_BULLET = True
# Blender player (would be enabled in it's own config)
WITH_BF_PLAYER = False
# Use jemalloc memory manager
WITH_BF_JEMALLOC = True
WITH_BF_STATICJEMALLOC = True
BF_JEMALLOC = '/home/sources/staticlibs/jemalloc'
BF_JEMALLOC_LIBPATH = '${BF_JEMALLOC}/lib64'
# Use 3d mouse library
WITH_BF_3DMOUSE = True
WITH_BF_STATIC3DMOUSE = True
BF_3DMOUSE = '/home/sources/staticlibs/spnav'
BF_3DMOUSE_LIBPATH = '${BF_3DMOUSE}/lib64'
# Compilation and optimization
BF_DEBUG = False
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
PLATFORM_LINKFLAGS = ['-L/home/sources/staticlibs/lib64']

View File

@@ -0,0 +1,187 @@
# -*- python -*-
# ex: set syntax=python:
# <pep8 compliant>
# Dictionary that the buildmaster pays attention to.
c = BuildmasterConfig = {}
# BUILD SLAVES
#
# We load the slaves and their passwords from a separator file, so we can have
# this one in SVN.
from buildbot.buildslave import BuildSlave
import master_private
c['slaves'] = []
for slave in master_private.slaves:
c['slaves'].append(BuildSlave(slave['name'], slave['password']))
# TCP port through which slaves connect
c['slavePortnum'] = 9989
# CHANGE SOURCES
from buildbot.changes.svnpoller import SVNPoller
c['change_source'] = SVNPoller(
'https://svn.blender.org/svnroot/bf-blender/trunk/',
pollinterval=1200)
# BUILDERS
#
# The 'builders' list defines the Builders, which tell Buildbot how to perform a build:
# what steps, and which slaves can execute them. Note that any particular build will
# only take place on one slave.
from buildbot.process.factory import BuildFactory
from buildbot.steps.source import SVN
from buildbot.steps.shell import ShellCommand
from buildbot.steps.shell import Compile
from buildbot.steps.shell import Test
from buildbot.steps.transfer import FileUpload
# from buildbot.steps.transfer import FileDownload
from buildbot.steps.master import MasterShellCommand
from buildbot.config import BuilderConfig
# add builder utility
c['builders'] = []
buildernames = []
def add_builder(c, name, libdir, factory, branch=''):
slavenames = []
for slave in master_private.slaves:
if name in slave['builders']:
slavenames.append(slave['name'])
if len(slavenames) > 0:
f = factory(name, libdir, branch)
c['builders'].append(BuilderConfig(name=name, slavenames=slavenames, factory=f, category='blender'))
buildernames.append(name)
# common steps
def svn_step(branch=''):
if branch:
return SVN(baseURL='https://svn.blender.org/svnroot/bf-blender/branches/%%BRANCH%%', mode='update', defaultBranch=branch, workdir='blender')
else:
return SVN(baseURL='https://svn.blender.org/svnroot/bf-blender/%%BRANCH%%/blender', mode='update', defaultBranch='trunk', workdir='blender')
def lib_svn_step(dir):
return SVN(name='lib svn', baseURL='https://svn.blender.org/svnroot/bf-blender/%%BRANCH%%/lib/' + dir, mode='update', defaultBranch='trunk', workdir='lib/' + dir)
# generic builder
def generic_builder(id, libdir='', branch=''):
filename = 'buildbot_upload_' + id + '.zip'
compile_script = '../blender/build_files/buildbot/slave_compile.py'
test_script = '../blender/build_files/buildbot/slave_test.py'
pack_script = '../blender/build_files/buildbot/slave_pack.py'
unpack_script = 'master_unpack.py'
f = BuildFactory()
f.addStep(svn_step(branch))
if libdir != '':
f.addStep(lib_svn_step(libdir))
f.addStep(Compile(command=['python', compile_script, id]))
f.addStep(Test(command=['python', test_script, id]))
f.addStep(ShellCommand(name='package', command=['python', pack_script, id, branch], description='packaging', descriptionDone='packaged'))
if id.find('cmake') != -1:
f.addStep(FileUpload(name='upload', slavesrc='buildbot_upload.zip', masterdest=filename, maxsize=100 * 1024 * 1024))
else:
f.addStep(FileUpload(name='upload', slavesrc='buildbot_upload.zip', masterdest=filename, maxsize=100 * 1024 * 1024, workdir='install'))
f.addStep(MasterShellCommand(name='unpack', command=['python', unpack_script, filename], description='unpacking', descriptionDone='unpacked'))
return f
# builders
add_builder(c, 'mac_x86_64_scons', 'darwin-9.x.universal', generic_builder)
add_builder(c, 'salad_mac_x86_64_scons', 'darwin-9.x.universal', generic_builder, 'soc-2011-salad')
add_builder(c, 'mac_i386_scons', 'darwin-9.x.universal', generic_builder)
add_builder(c, 'mac_ppc_scons', 'darwin-9.x.universal', generic_builder)
#add_builder(c, 'linux_x86_64_cmake', '', generic_builder)
add_builder(c, 'linux_i386_scons', '', generic_builder)
add_builder(c, 'salad_linux_i386_scons', '', generic_builder, 'soc-2011-salad')
add_builder(c, 'linux_x86_64_scons', '', generic_builder)
add_builder(c, 'salad_linux_x86_64_scons', '', generic_builder, 'soc-2011-salad')
add_builder(c, 'win32_scons', 'windows', generic_builder)
add_builder(c, 'salad_win32_scons', 'windows', generic_builder, 'soc-2011-salad')
add_builder(c, 'win64_scons', 'win64', generic_builder)
#add_builder(c, 'freebsd_i386_cmake', '', generic_builder)
#add_builder(c, 'freebsd_x86_64_cmake', '', generic_builder)
# SCHEDULERS
#
# Decide how to react to incoming changes.
# from buildbot.scheduler import Scheduler
from buildbot.schedulers import timed
c['schedulers'] = []
#c['schedulers'].append(Scheduler(name="all", branch=None,
# treeStableTimer=None,
# builderNames=[]))
#c['schedulers'].append(timed.Periodic(name="nightly",
# builderNames=buildernames,
# periodicBuildTimer=24*60*60))
c['schedulers'].append(timed.Nightly(name='nightly',
builderNames=buildernames,
hour=3,
minute=0))
# STATUS TARGETS
#
# 'status' is a list of Status Targets. The results of each build will be
# pushed to these targets. buildbot/status/*.py has a variety to choose from,
# including web pages, email senders, and IRC bots.
c['status'] = []
from buildbot.status import html
from buildbot.status.web import authz
authz_cfg = authz.Authz(
# change any of these to True to enable; see the manual for more
# options
gracefulShutdown=False,
forceBuild=True, # use this to test your slave once it is set up
forceAllBuilds=False,
pingBuilder=False,
stopBuild=False,
stopAllBuilds=False,
cancelPendingBuild=True,
)
c['status'].append(html.WebStatus(http_port=8010, authz=authz_cfg))
# PROJECT IDENTITY
c['projectName'] = "Blender"
c['projectURL'] = "http://www.blender.org"
# the 'buildbotURL' string should point to the location where the buildbot's
# internal web server (usually the html.WebStatus page) is visible. This
# typically uses the port number set in the Waterfall 'status' entry, but
# with an externally-visible host name which the buildbot cannot figure out
# without some help.
c['buildbotURL'] = "http://builder.blender.org/"
# DB URL
#
# This specifies what database buildbot uses to store change and scheduler
# state. You can leave this at its default for all but the largest
# installations.
c['db_url'] = "sqlite:///state.sqlite"

View File

@@ -0,0 +1,142 @@
# ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# ##### END GPL LICENSE BLOCK #####
# Runs on Buildbot master, to unpack incoming unload.zip into latest
# builds directory and remove older builds.
# <pep8 compliant>
import os
import shutil
import sys
import zipfile
# extension stripping
def strip_extension(filename):
extensions = '.zip', '.tar', '.bz2', '.gz', '.tgz', '.tbz', '.exe'
filename_noext, ext = os.path.splitext(filename)
if ext in extensions:
return strip_extension(filename_noext) # may have .tar.bz2
else:
return filename
# extract platform from package name
def get_platform(filename):
# name is blender-version-platform.extension. we want to get the
# platform out, but there may be some variations, so we fiddle a
# bit to handle current and hopefully future names
filename = strip_extension(filename)
filename = strip_extension(filename)
tokens = filename.split("-")
platforms = ('osx', 'mac', 'bsd',
'win', 'linux', 'source',
'irix', 'solaris')
platform_tokens = []
found = False
for i, token in enumerate(tokens):
if not found:
for platform in platforms:
if platform in token.lower():
found = True
break
if found:
platform_tokens += [token]
return '-'.join(platform_tokens)
def get_branch(filename):
tokens = filename.split("-")
branch = ""
for token in tokens:
if branch == "":
branch = token
else:
branch = branch + "-" + token
if token == "blender":
return branch
return ""
# get filename
if len(sys.argv) < 2:
sys.stderr.write("Not enough arguments, expecting file to unpack\n")
sys.exit(1)
filename = sys.argv[1]
# open zip file
if not os.path.exists(filename):
sys.stderr.write("File %r not found.\n" % filename)
sys.exit(1)
try:
z = zipfile.ZipFile(filename, "r")
except Exception, ex:
sys.stderr.write('Failed to open zip file: %s\n' % str(ex))
sys.exit(1)
if len(z.namelist()) != 1:
sys.stderr.write("Expected one file in %r." % filename)
sys.exit(1)
package = z.namelist()[0]
packagename = os.path.basename(package)
# detect platform and branch
platform = get_platform(packagename)
branch = get_branch(packagename)
if platform == '':
sys.stderr.write('Failed to detect platform ' +
'from package: %r\n' % packagename)
sys.exit(1)
# extract
directory = 'public_html/download'
try:
zf = z.open(package)
f = file(os.path.join(directory, packagename), "wb")
shutil.copyfileobj(zf, f)
zf.close()
z.close()
os.remove(filename)
except Exception, ex:
sys.stderr.write('Failed to unzip package: %s\n' % str(ex))
sys.exit(1)
# remove other files from the same platform and branch
try:
for f in os.listdir(directory):
if get_platform(f) == platform and get_branch(f) == branch:
if f != packagename:
os.remove(os.path.join(directory, f))
except Exception, ex:
sys.stderr.write('Failed to remove old packages: %s\n' % str(ex))
sys.exit(1)

View File

@@ -0,0 +1,120 @@
# ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# ##### END GPL LICENSE BLOCK #####
# <pep8 compliant>
import os
import subprocess
import sys
# get builder name
if len(sys.argv) < 2:
sys.stderr.write("Not enough arguments, expecting builder name\n")
sys.exit(1)
builder = sys.argv[1]
# we run from build/ directory
blender_dir = '../blender'
if builder.find('cmake') != -1:
# cmake
# set build options
cmake_options = ['-DCMAKE_BUILD_TYPE:STRING=Release']
if builder.endswith('mac_x86_64_cmake'):
cmake_options.append('-DCMAKE_OSX_ARCHITECTURES:STRING=x86_64')
elif builder.endswith('mac_i386_cmake'):
cmake_options.append('-DCMAKE_OSX_ARCHITECTURES:STRING=i386')
elif builder.endswith('mac_ppc_cmake'):
cmake_options.append('-DCMAKE_OSX_ARCHITECTURES:STRING=ppc')
# configure and make
retcode = subprocess.call(['cmake', blender_dir] + cmake_options)
if retcode != 0:
sys.exit(retcode)
retcode = subprocess.call(['make', '-s', '-j4', 'install'])
sys.exit(retcode)
else:
# scons
os.chdir(blender_dir)
scons_cmd = ['python', 'scons/scons.py']
scons_options = []
if builder.find('linux') != -1:
import shutil
# We're using the same rules as release builder, so tweak
# build and install dirs
build_dir = os.path.join('..', 'build', builder)
install_dir = os.path.join('..', 'install', builder)
common_options = ['BF_INSTALLDIR=' + install_dir]
# Clean install directory so we'll be sure there's no
if os.path.isdir(install_dir):
shutil.rmtree(install_dir)
buildbot_dir = os.path.dirname(os.path.realpath(__file__))
config_dir = os.path.join(buildbot_dir, 'config')
configs = []
if builder.endswith('linux_x86_64_scons'):
configs = ['user-config-player-x86_64.py',
'user-config-x86_64.py']
elif builder.endswith('linux_i386_scons'):
configs = ['user-config-player-i686.py',
'user-config-i686.py']
for config in configs:
config_fpath = os.path.join(config_dir, config)
scons_options = []
if config.find('player') != -1:
scons_options.append('BF_BUILDDIR=%s_player' % (build_dir))
else:
scons_options.append('BF_BUILDDIR=%s' % (build_dir))
scons_options += common_options
if config.find('player') == -1:
scons_options.append('blender')
else:
scons_options.append('blenderplayer')
scons_options.append('BF_CONFIG=' + config_fpath)
retcode = subprocess.call(scons_cmd + scons_options)
if retcode != 0:
print('Error building rules wuth config ' + config)
sys.exit(retcode)
sys.exit(0)
else:
if builder.find('win') != -1:
bitness = '32'
if builder.find('win64') != -1:
bitness = '64'
scons_options.append('BF_BITNESS=' + bitness)
retcode = subprocess.call(['python', 'scons/scons.py'] + scons_options)
sys.exit(retcode)

View File

@@ -0,0 +1,130 @@
# ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# ##### END GPL LICENSE BLOCK #####
# <pep8 compliant>
# Runs on buildbot slave, creating a release package using the build
# system and zipping it into buildbot_upload.zip. This is then uploaded
# to the master in the next buildbot step.
import os
import subprocess
import sys
import zipfile
# get builder name
if len(sys.argv) < 2:
sys.stderr.write("Not enough arguments, expecting builder name\n")
sys.exit(1)
builder = sys.argv[1]
branch = ''
if len(sys.argv) >= 3:
branch = sys.argv[2]
# scons does own packaging
if builder.find('scons') != -1:
os.chdir('../blender')
scons_options = ['BF_QUICK=slnt', 'BUILDBOT_BRANCH=' + branch, 'buildslave']
if builder.find('linux') != -1:
buildbot_dir = os.path.dirname(os.path.realpath(__file__))
config_dir = os.path.join(buildbot_dir, 'config')
build_dir = os.path.join('..', 'build', builder)
install_dir = os.path.join('..', 'install', builder)
scons_options += ['WITH_BF_NOBLENDER=True', 'WITH_BF_PLAYER=False',
'BF_BUILDDIR=' + build_dir,
'BF_INSTALLDIR=' + install_dir,
'WITHOUT_BF_INSTALL=True']
config = None
if builder.endswith('linux_x86_64_scons'):
config = 'user-config-x86_64.py'
elif builder.endswith('linux_i386_scons'):
config = 'user-config-x86_64.py'
if config is not None:
config_fpath = os.path.join(config_dir, config)
scons_options.append('BF_CONFIG=' + config_fpath)
blender = os.path.join(install_dir, 'blender')
blenderplayer = os.path.join(install_dir, 'blenderplayer')
subprocess.call(['strip', '--strip-all', blender, blenderplayer])
retcode = subprocess.call(['python', 'scons/scons.py'] + scons_options)
sys.exit(retcode)
else:
if builder.find('win') != -1:
bitness = '32'
if builder.find('win64') != -1:
bitness = '64'
scons_options.append('BF_BITNESS=' + bitness)
retcode = subprocess.call(['python', 'scons/scons.py'] + scons_options)
sys.exit(retcode)
# clean release directory if it already exists
dir = 'release'
if os.path.exists(dir):
for f in os.listdir(dir):
if os.path.isfile(os.path.join(dir, f)):
os.remove(os.path.join(dir, f))
# create release package
try:
subprocess.call(['make', 'package_archive'])
except Exception, ex:
sys.stderr.write('Make package release failed' + str(ex) + '\n')
sys.exit(1)
# find release directory, must exist this time
if not os.path.exists(dir):
sys.stderr.write("Failed to find release directory.\n")
sys.exit(1)
# find release package
file = None
filepath = None
for f in os.listdir(dir):
rf = os.path.join(dir, f)
if os.path.isfile(rf) and f.startswith('blender'):
file = f
filepath = rf
if not file:
sys.stderr.write("Failed to find release package.\n")
sys.exit(1)
# create zip file
try:
upload_zip = "buildbot_upload.zip"
if os.path.exists(upload_zip):
os.remove(upload_zip)
z = zipfile.ZipFile(upload_zip, "w", compression=zipfile.ZIP_STORED)
z.write(filepath, arcname=file)
z.close()
except Exception, ex:
sys.stderr.write('Create buildbot_upload.zip failed' + str(ex) + '\n')
sys.exit(1)

View File

@@ -0,0 +1,40 @@
# ##### BEGIN GPL LICENSE BLOCK #####
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# ##### END GPL LICENSE BLOCK #####
# <pep8 compliant>
import subprocess
import sys
# get builder name
if len(sys.argv) < 2:
sys.stderr.write("Not enough arguments, expecting builder name\n")
sys.exit(1)
builder = sys.argv[1]
# we run from build/ directory
blender_dir = '../blender'
if builder.find('cmake') != -1:
# cmake
retcode = subprocess.call(['ctest', '.' '--output-on-failure'])
sys.exit(retcode)
else:
# scons
pass

View File

@@ -0,0 +1,70 @@
# - Find Fftw3 library
# Find the native Fftw3 includes and library
# This module defines
# FFTW3_INCLUDE_DIRS, where to find fftw3.h, Set when
# FFTW3_INCLUDE_DIR is found.
# FFTW3_LIBRARIES, libraries to link against to use Fftw3.
# FFTW3_ROOT_DIR, The base directory to search for Fftw3.
# This can also be an environment variable.
# FFTW3_FOUND, If false, do not try to use Fftw3.
#
# also defined, but not for general use are
# FFTW3_LIBRARY, where to find the Fftw3 library.
#=============================================================================
# Copyright 2011 Blender Foundation.
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# If FFTW3_ROOT_DIR was defined in the environment, use it.
IF(NOT FFTW3_ROOT_DIR AND NOT $ENV{FFTW3_ROOT_DIR} STREQUAL "")
SET(FFTW3_ROOT_DIR $ENV{FFTW3_ROOT_DIR})
ENDIF()
SET(_fftw3_SEARCH_DIRS
${FFTW3_ROOT_DIR}
/usr/local
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
)
FIND_PATH(FFTW3_INCLUDE_DIR
NAMES
fftw3.h
HINTS
${_fftw3_SEARCH_DIRS}
PATH_SUFFIXES
include
)
FIND_LIBRARY(FFTW3_LIBRARY
NAMES
fftw3
HINTS
${_fftw3_SEARCH_DIRS}
PATH_SUFFIXES
lib64 lib
)
# handle the QUIETLY and REQUIRED arguments and set FFTW3_FOUND to TRUE if
# all listed variables are TRUE
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Fftw3 DEFAULT_MSG
FFTW3_LIBRARY FFTW3_INCLUDE_DIR)
IF(FFTW3_FOUND)
SET(FFTW3_LIBRARIES ${FFTW3_LIBRARY})
SET(FFTW3_INCLUDE_DIRS ${FFTW3_INCLUDE_DIR})
ENDIF(FFTW3_FOUND)
MARK_AS_ADVANCED(
FFTW3_INCLUDE_DIR
FFTW3_LIBRARY
)

View File

@@ -0,0 +1,59 @@
#
# Try to find GLEW library and include path.
# Once done this will define
#
# GLEW_FOUND
# GLEW_INCLUDE_PATH
# GLEW_LIBRARY
#
IF (WIN32)
FIND_PATH( GLEW_INCLUDE_PATH GL/glew.h
$ENV{PROGRAMFILES}/GLEW/include
${PROJECT_SOURCE_DIR}/src/nvgl/glew/include
DOC "The directory where GL/glew.h resides")
IF (NV_SYSTEM_PROCESSOR STREQUAL "AMD64")
FIND_LIBRARY( GLEW_LIBRARY
NAMES glew64 glew64s
PATHS
$ENV{PROGRAMFILES}/GLEW/lib
${PROJECT_SOURCE_DIR}/src/nvgl/glew/bin
${PROJECT_SOURCE_DIR}/src/nvgl/glew/lib
DOC "The GLEW library (64-bit)"
)
ELSE(NV_SYSTEM_PROCESSOR STREQUAL "AMD64")
FIND_LIBRARY( GLEW_LIBRARY
NAMES glew GLEW glew32 glew32s
PATHS
$ENV{PROGRAMFILES}/GLEW/lib
${PROJECT_SOURCE_DIR}/src/nvgl/glew/bin
${PROJECT_SOURCE_DIR}/src/nvgl/glew/lib
DOC "The GLEW library"
)
ENDIF(NV_SYSTEM_PROCESSOR STREQUAL "AMD64")
ELSE (WIN32)
FIND_PATH( GLEW_INCLUDE_PATH GL/glew.h
/usr/include
/usr/local/include
/sw/include
/opt/local/include
DOC "The directory where GL/glew.h resides")
FIND_LIBRARY( GLEW_LIBRARY
NAMES GLEW glew
PATHS
/usr/lib64
/usr/lib
/usr/local/lib64
/usr/local/lib
/sw/lib
/opt/local/lib
DOC "The GLEW library")
ENDIF (WIN32)
IF (GLEW_INCLUDE_PATH)
SET( GLEW_FOUND 1 CACHE STRING "Set to 1 if GLEW is found, 0 otherwise")
ELSE (GLEW_INCLUDE_PATH)
SET( GLEW_FOUND 0 CACHE STRING "Set to 1 if GLEW is found, 0 otherwise")
ENDIF (GLEW_INCLUDE_PATH)
MARK_AS_ADVANCED( GLEW_FOUND )

View File

@@ -0,0 +1,70 @@
# - Find Jack library
# Find the native Jack includes and library
# This module defines
# JACK_INCLUDE_DIRS, where to find jack.h, Set when
# JACK_INCLUDE_DIR is found.
# JACK_LIBRARIES, libraries to link against to use Jack.
# JACK_ROOT_DIR, The base directory to search for Jack.
# This can also be an environment variable.
# JACK_FOUND, If false, do not try to use Jack.
#
# also defined, but not for general use are
# JACK_LIBRARY, where to find the Jack library.
#=============================================================================
# Copyright 2011 Blender Foundation.
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# If JACK_ROOT_DIR was defined in the environment, use it.
IF(NOT JACK_ROOT_DIR AND NOT $ENV{JACK_ROOT_DIR} STREQUAL "")
SET(JACK_ROOT_DIR $ENV{JACK_ROOT_DIR})
ENDIF()
SET(_jack_SEARCH_DIRS
${JACK_ROOT_DIR}
/usr/local
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
)
FIND_PATH(JACK_INCLUDE_DIR
NAMES
jack.h
HINTS
${_jack_SEARCH_DIRS}
PATH_SUFFIXES
include/jack
)
FIND_LIBRARY(JACK_LIBRARY
NAMES
jack
HINTS
${_jack_SEARCH_DIRS}
PATH_SUFFIXES
lib64 lib
)
# handle the QUIETLY and REQUIRED arguments and set JACK_FOUND to TRUE if
# all listed variables are TRUE
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Jack DEFAULT_MSG
JACK_LIBRARY JACK_INCLUDE_DIR)
IF(JACK_FOUND)
SET(JACK_LIBRARIES ${JACK_LIBRARY})
SET(JACK_INCLUDE_DIRS ${JACK_INCLUDE_DIR})
ENDIF(JACK_FOUND)
MARK_AS_ADVANCED(
JACK_INCLUDE_DIR
JACK_LIBRARY
)

View File

@@ -0,0 +1,70 @@
# - Find JeMalloc library
# Find the native JeMalloc includes and library
# This module defines
# JEMALLOC_INCLUDE_DIRS, where to find jemalloc.h, Set when
# JEMALLOC_INCLUDE_DIR is found.
# JEMALLOC_LIBRARIES, libraries to link against to use JeMalloc.
# JEMALLOC_ROOT_DIR, The base directory to search for JeMalloc.
# This can also be an environment variable.
# JEMALLOC_FOUND, If false, do not try to use JeMalloc.
#
# also defined, but not for general use are
# JEMALLOC_LIBRARY, where to find the JeMalloc library.
#=============================================================================
# Copyright 2011 Blender Foundation.
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# If JEMALLOC_ROOT_DIR was defined in the environment, use it.
IF(NOT JEMALLOC_ROOT_DIR AND NOT $ENV{JEMALLOC_ROOT_DIR} STREQUAL "")
SET(JEMALLOC_ROOT_DIR $ENV{JEMALLOC_ROOT_DIR})
ENDIF()
SET(_jemalloc_SEARCH_DIRS
${JEMALLOC_ROOT_DIR}
/usr/local
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
)
FIND_PATH(JEMALLOC_INCLUDE_DIR
NAMES
jemalloc.h
HINTS
${_jemalloc_SEARCH_DIRS}
PATH_SUFFIXES
include/jemalloc
)
FIND_LIBRARY(JEMALLOC_LIBRARY
NAMES
jemalloc
HINTS
${_jemalloc_SEARCH_DIRS}
PATH_SUFFIXES
lib64 lib
)
# handle the QUIETLY and REQUIRED arguments and set JEMALLOC_FOUND to TRUE if
# all listed variables are TRUE
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(JeMalloc DEFAULT_MSG
JEMALLOC_LIBRARY JEMALLOC_INCLUDE_DIR)
IF(JEMALLOC_FOUND)
SET(JEMALLOC_LIBRARIES ${JEMALLOC_LIBRARY})
SET(JEMALLOC_INCLUDE_DIRS ${JEMALLOC_INCLUDE_DIR})
ENDIF(JEMALLOC_FOUND)
MARK_AS_ADVANCED(
JEMALLOC_INCLUDE_DIR
JEMALLOC_LIBRARY
)

View File

@@ -0,0 +1,118 @@
# - Find OpenCOLLADA library
# Find the native OpenCOLLADA includes and library
# This module defines
# OPENCOLLADA_INCLUDE_DIRS, where to find COLLADABaseUtils/ and
# COLLADAFramework/, Set when OPENCOLLADA_INCLUDE_DIR is found.
# OPENCOLLADA_LIBRARIES, libraries to link against to use OpenCOLLADA.
# OPENCOLLADA_ROOT_DIR, The base directory to search for OpenCOLLADA.
# This can also be an environment variable.
# OPENCOLLADA_FOUND, If false, do not try to use OpenCOLLADA.
#
# also defined, but not for general use are
# OPENCOLLADA_LIBRARY, where to find the OpenCOLLADA library.
#=============================================================================
# Copyright 2011 Blender Foundation.
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# note about include paths, there are 2 ways includes are set
#
# Where '/usr/include/opencollada' is the root dir:
# /usr/include/opencollada/COLLADABaseUtils/COLLADABUPlatform.h
#
# Where '/opt/opencollada' is the base dir:
# /opt/opencollada/COLLADABaseUtils/include/COLLADABUPlatform.h
# If OPENCOLLADA_ROOT_DIR was defined in the environment, use it.
IF(NOT OPENCOLLADA_ROOT_DIR AND NOT $ENV{OPENCOLLADA_ROOT_DIR} STREQUAL "")
SET(OPENCOLLADA_ROOT_DIR $ENV{OPENCOLLADA_ROOT_DIR})
ENDIF()
SET(_opencollada_FIND_INCLUDES
COLLADAStreamWriter
COLLADABaseUtils
COLLADAFramework
COLLADASaxFrameworkLoader
GeneratedSaxParser
)
SET(_opencollada_FIND_COMPONENTS
OpenCOLLADAStreamWriter
OpenCOLLADASaxFrameworkLoader
OpenCOLLADAFramework
OpenCOLLADABaseUtils
GeneratedSaxParser
UTF
MathMLSolver
pcre
ftoa
buffer
xml2
)
SET(_opencollada_SEARCH_DIRS
${OPENCOLLADA_ROOT_DIR}
/usr/local
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
)
SET(_opencollada_INCLUDES)
FOREACH(COMPONENT ${_opencollada_FIND_INCLUDES})
STRING(TOUPPER ${COMPONENT} UPPERCOMPONENT)
# need to use this even thouh we are looking for a dir
FIND_FILE(OPENCOLLADA_${UPPERCOMPONENT}_INCLUDE_DIR
NAMES
${COMPONENT}/include
${COMPONENT}
# Ubuntu ppa needs this.
# Alternative would be to suffix all members of search path
# but this is less trouble, just looks strange.
include/opencollada/${COMPONENT}
HINTS
${_opencollada_SEARCH_DIRS}
)
MARK_AS_ADVANCED(OPENCOLLADA_${UPPERCOMPONENT}_INCLUDE_DIR)
LIST(APPEND _opencollada_INCLUDES "${OPENCOLLADA_${UPPERCOMPONENT}_INCLUDE_DIR}")
ENDFOREACH()
SET(_opencollada_LIBRARIES)
FOREACH(COMPONENT ${_opencollada_FIND_COMPONENTS})
STRING(TOUPPER ${COMPONENT} UPPERCOMPONENT)
FIND_LIBRARY(OPENCOLLADA_${UPPERCOMPONENT}_LIBRARY
NAMES
${COMPONENT}
HINTS
${_opencollada_SEARCH_DIRS}
PATH_SUFFIXES
lib64 lib
# Ubuntu ppa needs this.
lib64/opencollada lib/opencollada
)
MARK_AS_ADVANCED(OPENCOLLADA_${UPPERCOMPONENT}_LIBRARY)
LIST(APPEND _opencollada_LIBRARIES "${OPENCOLLADA_${UPPERCOMPONENT}_LIBRARY}")
ENDFOREACH()
# handle the QUIETLY and REQUIRED arguments and set OPENCOLLADA_FOUND to TRUE if
# all listed variables are TRUE
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OpenCOLLADA DEFAULT_MSG
_opencollada_LIBRARIES _opencollada_INCLUDES)
IF(OPENCOLLADA_FOUND)
SET(OPENCOLLADA_LIBRARIES ${_opencollada_LIBRARIES})
SET(OPENCOLLADA_INCLUDE_DIRS ${_opencollada_INCLUDES})
ENDIF(OPENCOLLADA_FOUND)

View File

@@ -0,0 +1,92 @@
# - Find OpenEXR library
# Find the native OpenEXR includes and library
# This module defines
# OPENEXR_INCLUDE_DIRS, where to find ImfXdr.h, etc. Set when
# OPENEXR_INCLUDE_DIR is found.
# OPENEXR_LIBRARIES, libraries to link against to use OpenEXR.
# OPENEXR_ROOT_DIR, The base directory to search for OpenEXR.
# This can also be an environment variable.
# OPENEXR_FOUND, If false, do not try to use OpenEXR.
#
# For indervidual library access these advanced settings are available
# OPENEXR_HALF_LIBRARY, Path to Half library
# OPENEXR_IEX_LIBRARY, Path to Half library
# OPENEXR_ILMIMF_LIBRARY, Path to Ilmimf library
# OPENEXR_ILMTHREAD_LIBRARY, Path to IlmThread library
# OPENEXR_IMATH_LIBRARY, Path to Imath library
#
# also defined, but not for general use are
# OPENEXR_LIBRARY, where to find the OpenEXR library.
#=============================================================================
# Copyright 2011 Blender Foundation.
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# If OPENEXR_ROOT_DIR was defined in the environment, use it.
IF(NOT OPENEXR_ROOT_DIR AND NOT $ENV{OPENEXR_ROOT_DIR} STREQUAL "")
SET(OPENEXR_ROOT_DIR $ENV{OPENEXR_ROOT_DIR})
ENDIF()
SET(_openexr_FIND_COMPONENTS
Half
Iex
IlmImf
IlmThread
Imath
)
SET(_openexr_SEARCH_DIRS
${OPENEXR_ROOT_DIR}
/usr/local
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
)
FIND_PATH(OPENEXR_INCLUDE_DIR
NAMES
ImfXdr.h
HINTS
${_openexr_SEARCH_DIRS}
PATH_SUFFIXES
include/OpenEXR
)
SET(_openexr_LIBRARIES)
FOREACH(COMPONENT ${_openexr_FIND_COMPONENTS})
STRING(TOUPPER ${COMPONENT} UPPERCOMPONENT)
FIND_LIBRARY(OPENEXR_${UPPERCOMPONENT}_LIBRARY
NAMES
${COMPONENT}
HINTS
${_openexr_SEARCH_DIRS}
PATH_SUFFIXES
lib64 lib
)
LIST(APPEND _openexr_LIBRARIES "${OPENEXR_${UPPERCOMPONENT}_LIBRARY}")
ENDFOREACH()
# handle the QUIETLY and REQUIRED arguments and set OPENEXR_FOUND to TRUE if
# all listed variables are TRUE
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OpenEXR DEFAULT_MSG
_openexr_LIBRARIES OPENEXR_INCLUDE_DIR)
IF(OPENEXR_FOUND)
SET(OPENEXR_LIBRARIES ${_openexr_LIBRARIES})
SET(OPENEXR_INCLUDE_DIRS ${OPENEXR_INCLUDE_DIR})
ENDIF()
MARK_AS_ADVANCED(OPENEXR_INCLUDE_DIR)
FOREACH(COMPONENT ${_openexr_FIND_COMPONENTS})
STRING(TOUPPER ${COMPONENT} UPPERCOMPONENT)
MARK_AS_ADVANCED(OPENEXR_${UPPERCOMPONENT}_LIBRARY)
ENDFOREACH()

View File

@@ -0,0 +1,70 @@
# - Find OpenJPEG library
# Find the native OpenJPEG includes and library
# This module defines
# OPENJPEG_INCLUDE_DIRS, where to find openjpeg.h, Set when
# OPENJPEG_INCLUDE_DIR is found.
# OPENJPEG_LIBRARIES, libraries to link against to use OpenJPEG.
# OPENJPEG_ROOT_DIR, The base directory to search for OpenJPEG.
# This can also be an environment variable.
# OPENJPEG_FOUND, If false, do not try to use OpenJPEG.
#
# also defined, but not for general use are
# OPENJPEG_LIBRARY, where to find the OpenJPEG library.
#=============================================================================
# Copyright 2011 Blender Foundation.
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# If OPENJPEG_ROOT_DIR was defined in the environment, use it.
IF(NOT OPENJPEG_ROOT_DIR AND NOT $ENV{OPENJPEG_ROOT_DIR} STREQUAL "")
SET(OPENJPEG_ROOT_DIR $ENV{OPENJPEG_ROOT_DIR})
ENDIF()
SET(_openjpeg_SEARCH_DIRS
${OPENJPEG_ROOT_DIR}
/usr/local
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
)
FIND_PATH(OPENJPEG_INCLUDE_DIR
NAMES
openjpeg.h
HINTS
${_openjpeg_SEARCH_DIRS}
PATH_SUFFIXES
include
)
FIND_LIBRARY(OPENJPEG_LIBRARY
NAMES
openjpeg
HINTS
${_openjpeg_SEARCH_DIRS}
PATH_SUFFIXES
lib64 lib
)
# handle the QUIETLY and REQUIRED arguments and set OPENJPEG_FOUND to TRUE if
# all listed variables are TRUE
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OpenJPEG DEFAULT_MSG
OPENJPEG_LIBRARY OPENJPEG_INCLUDE_DIR)
IF(OPENJPEG_FOUND)
SET(OPENJPEG_LIBRARIES ${OPENJPEG_LIBRARY})
SET(OPENJPEG_INCLUDE_DIRS ${OPENJPEG_INCLUDE_DIR})
ENDIF(OPENJPEG_FOUND)
MARK_AS_ADVANCED(
OPENJPEG_INCLUDE_DIR
OPENJPEG_LIBRARY
)

View File

@@ -0,0 +1,121 @@
# - Find Python libraries
# Find the native Python includes and library
#
# Note:, This is not _yet_ intended to be a general python module for other
# projects to use since its hard coded to python 3.2 as blender only supports
# a single python version.
# This is for blender/unix python only.
#
# This module defines
# PYTHON_VERSION
# PYTHON_INCLUDE_DIRS
# PYTHON_LIBRARIES
# PYTHON_LIBPATH, Used for installation
# PYTHON_LINKFLAGS
# PYTHON_ROOT_DIR, The base directory to search for Python.
# This can also be an environment variable.
#
# also defined, but not for general use are
# PYTHON_LIBRARY, where to find the python library.
#=============================================================================
# Copyright 2011 Blender Foundation.
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# If PYTHON_ROOT_DIR was defined in the environment, use it.
IF(NOT PYTHON_ROOT_DIR AND NOT $ENV{PYTHON_ROOT_DIR} STREQUAL "")
SET(PYTHON_ROOT_DIR $ENV{PYTHON_ROOT_DIR})
ENDIF()
IF(DEFINED PYTHON_VERSION)
SET(PYTHON_VERSION "${PYTHON_VERSION}" CACHE STRING "")
ELSE()
SET(PYTHON_VERSION 3.2 CACHE STRING "")
ENDIF()
MARK_AS_ADVANCED(PYTHON_VERSION)
SET(PYTHON_LINKFLAGS "-Xlinker -export-dynamic")
MARK_AS_ADVANCED(PYTHON_LINKFLAGS)
SET(_python_ABI_FLAGS
"m;mu;u; " # release
"md;mud;ud;d" # debug
)
STRING(REPLACE "." "" _PYTHON_VERSION_NO_DOTS ${PYTHON_VERSION})
SET(_python_SEARCH_DIRS
${PYTHON_ROOT_DIR}
"$ENV{HOME}/py${_PYTHON_VERSION_NO_DOTS}"
"/opt/py${_PYTHON_VERSION_NO_DOTS}"
)
FOREACH(_CURRENT_ABI_FLAGS ${_python_ABI_FLAGS})
#IF(CMAKE_BUILD_TYPE STREQUAL Debug)
# SET(_CURRENT_ABI_FLAGS "d${_CURRENT_ABI_FLAGS}")
#ENDIF()
STRING(REPLACE " " "" _CURRENT_ABI_FLAGS ${_CURRENT_ABI_FLAGS})
FIND_PATH(PYTHON_INCLUDE_DIR
NAMES
Python.h
HINTS
${_python_SEARCH_DIRS}
PATH_SUFFIXES
include/python${PYTHON_VERSION}${_CURRENT_ABI_FLAGS}
)
FIND_LIBRARY(PYTHON_LIBRARY
NAMES
"python${PYTHON_VERSION}${_CURRENT_ABI_FLAGS}"
HINTS
${_python_SEARCH_DIRS}
PATH_SUFFIXES
lib64 lib
)
IF(PYTHON_LIBRARY AND PYTHON_INCLUDE_DIR)
break()
ELSE()
# ensure we dont find values from 2 different ABI versions
UNSET(PYTHON_INCLUDE_DIR CACHE)
UNSET(PYTHON_LIBRARY CACHE)
ENDIF()
ENDFOREACH()
UNSET(_CURRENT_ABI_FLAGS)
UNSET(_CURRENT_PATH)
UNSET(_python_ABI_FLAGS)
UNSET(_python_SEARCH_DIRS)
# handle the QUIETLY and REQUIRED arguments and SET PYTHONLIBSUNIX_FOUND to TRUE IF
# all listed variables are TRUE
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(PythonLibsUnix DEFAULT_MSG
PYTHON_LIBRARY PYTHON_INCLUDE_DIR)
IF(PYTHONLIBSUNIX_FOUND)
# Assign cache items
SET(PYTHON_INCLUDE_DIRS ${PYTHON_INCLUDE_DIR})
SET(PYTHON_LIBRARIES ${PYTHON_LIBRARY})
# we need this for installation
GET_FILENAME_COMPONENT(PYTHON_LIBPATH ${PYTHON_LIBRARY} PATH)
# not used
# SET(PYTHON_BINARY ${PYTHON_EXECUTABLE} CACHE STRING "")
MARK_AS_ADVANCED(
PYTHON_INCLUDE_DIR
PYTHON_LIBRARY
)
ENDIF()

View File

@@ -0,0 +1,70 @@
# - Find Samplerate library
# Find the native Samplerate includes and library
# This module defines
# SAMPLERATE_INCLUDE_DIRS, where to find samplerate.h, Set when
# SAMPLERATE_INCLUDE_DIR is found.
# SAMPLERATE_LIBRARIES, libraries to link against to use Samplerate.
# SAMPLERATE_ROOT_DIR, The base directory to search for Samplerate.
# This can also be an environment variable.
# SAMPLERATE_FOUND, If false, do not try to use Samplerate.
#
# also defined, but not for general use are
# SAMPLERATE_LIBRARY, where to find the Samplerate library.
#=============================================================================
# Copyright 2011 Blender Foundation.
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# If SAMPLERATE_ROOT_DIR was defined in the environment, use it.
IF(NOT SAMPLERATE_ROOT_DIR AND NOT $ENV{SAMPLERATE_ROOT_DIR} STREQUAL "")
SET(SAMPLERATE_ROOT_DIR $ENV{SAMPLERATE_ROOT_DIR})
ENDIF()
SET(_samplerate_SEARCH_DIRS
${SAMPLERATE_ROOT_DIR}
/usr/local
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
)
FIND_PATH(SAMPLERATE_INCLUDE_DIR
NAMES
samplerate.h
HINTS
${_samplerate_SEARCH_DIRS}
PATH_SUFFIXES
include
)
FIND_LIBRARY(SAMPLERATE_LIBRARY
NAMES
samplerate
HINTS
${_samplerate_SEARCH_DIRS}
PATH_SUFFIXES
lib64 lib
)
# handle the QUIETLY and REQUIRED arguments and set SAMPLERATE_FOUND to TRUE if
# all listed variables are TRUE
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Samplerate DEFAULT_MSG
SAMPLERATE_LIBRARY SAMPLERATE_INCLUDE_DIR)
IF(SAMPLERATE_FOUND)
SET(SAMPLERATE_LIBRARIES ${SAMPLERATE_LIBRARY})
SET(SAMPLERATE_INCLUDE_DIRS ${SAMPLERATE_INCLUDE_DIR})
ENDIF(SAMPLERATE_FOUND)
MARK_AS_ADVANCED(
SAMPLERATE_INCLUDE_DIR
SAMPLERATE_LIBRARY
)

View File

@@ -0,0 +1,68 @@
# - Find SndFile library
# Find the native SndFile includes and library
# This module defines
# SNDFILE_INCLUDE_DIRS, where to find sndfile.h, Set when
# SNDFILE_INCLUDE_DIR is found.
# SNDFILE_LIBRARIES, libraries to link against to use SndFile.
# SNDFILE_ROOT_DIR, The base directory to search for SndFile.
# This can also be an environment variable.
# SNDFILE_FOUND, If false, do not try to use SndFile.
#
# also defined, but not for general use are
# SNDFILE_LIBRARY, where to find the SndFile library.
#=============================================================================
# Copyright 2011 Blender Foundation.
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# If SNDFILE_ROOT_DIR was defined in the environment, use it.
IF(NOT SNDFILE_ROOT_DIR AND NOT $ENV{SNDFILE_ROOT_DIR} STREQUAL "")
SET(SNDFILE_ROOT_DIR $ENV{SNDFILE_ROOT_DIR})
ENDIF()
SET(_sndfile_SEARCH_DIRS
${SNDFILE_ROOT_DIR}
/usr/local
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
)
FIND_PATH(SNDFILE_INCLUDE_DIR sndfile.h
HINTS
${_sndfile_SEARCH_DIRS}
PATH_SUFFIXES
include
)
FIND_LIBRARY(SNDFILE_LIBRARY
NAMES
sndfile
HINTS
${_sndfile_SEARCH_DIRS}
PATH_SUFFIXES
lib64 lib
)
# handle the QUIETLY and REQUIRED arguments and set SNDFILE_FOUND to TRUE if
# all listed variables are TRUE
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(SndFile DEFAULT_MSG
SNDFILE_LIBRARY SNDFILE_INCLUDE_DIR)
IF(SNDFILE_FOUND)
SET(SNDFILE_LIBRARIES ${SNDFILE_LIBRARY})
SET(SNDFILE_INCLUDE_DIRS ${SNDFILE_INCLUDE_DIR})
ENDIF(SNDFILE_FOUND)
MARK_AS_ADVANCED(
SNDFILE_INCLUDE_DIR
SNDFILE_LIBRARY
)

View File

@@ -0,0 +1,70 @@
# - Find Spacenav library
# Find the native Spacenav includes and library
# This module defines
# SPACENAV_INCLUDE_DIRS, where to find spnav.h, Set when
# SPACENAV_INCLUDE_DIR is found.
# SPACENAV_LIBRARIES, libraries to link against to use Spacenav.
# SPACENAV_ROOT_DIR, The base directory to search for Spacenav.
# This can also be an environment variable.
# SPACENAV_FOUND, If false, do not try to use Spacenav.
#
# also defined, but not for general use are
# SPACENAV_LIBRARY, where to find the Spacenav library.
#=============================================================================
# Copyright 2011 Blender Foundation.
#
# Distributed under the OSI-approved BSD License (the "License");
# see accompanying file Copyright.txt for details.
#
# This software is distributed WITHOUT ANY WARRANTY; without even the
# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
# See the License for more information.
#=============================================================================
# If SPACENAV_ROOT_DIR was defined in the environment, use it.
IF(NOT SPACENAV_ROOT_DIR AND NOT $ENV{SPACENAV_ROOT_DIR} STREQUAL "")
SET(SPACENAV_ROOT_DIR $ENV{SPACENAV_ROOT_DIR})
ENDIF()
SET(_spacenav_SEARCH_DIRS
${SPACENAV_ROOT_DIR}
/usr/local
/sw # Fink
/opt/local # DarwinPorts
/opt/csw # Blastwave
)
FIND_PATH(SPACENAV_INCLUDE_DIR
NAMES
spnav.h
HINTS
${_spacenav_SEARCH_DIRS}
PATH_SUFFIXES
include
)
FIND_LIBRARY(SPACENAV_LIBRARY
NAMES
spnav
HINTS
${_spacenav_SEARCH_DIRS}
PATH_SUFFIXES
lib64 lib
)
# handle the QUIETLY and REQUIRED arguments and set SPACENAV_FOUND to TRUE if
# all listed variables are TRUE
INCLUDE(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Spacenav DEFAULT_MSG
SPACENAV_LIBRARY SPACENAV_INCLUDE_DIR)
IF(SPACENAV_FOUND)
SET(SPACENAV_LIBRARIES ${SPACENAV_LIBRARY})
SET(SPACENAV_INCLUDE_DIRS ${SPACENAV_INCLUDE_DIR})
ENDIF(SPACENAV_FOUND)
MARK_AS_ADVANCED(
SPACENAV_INCLUDE_DIR
SPACENAV_LIBRARY
)

View File

@@ -0,0 +1,19 @@
#
# VLMC RPM Finder
# Authors: Rohit Yadav <rohityadav89@gmail.com>
#
find_program(RPMBUILD
NAMES rpmbuild
PATHS "/usr/bin")
mark_as_advanced(RPMBUILD)
if(RPMBUILD)
get_filename_component(RPMBUILD_PATH ${RPMBUILD} ABSOLUTE)
message(STATUS "Found rpmbuild : ${RPMBUILD_PATH}")
set(RPMBUILD_FOUND "YES")
else(RPMBUILD)
message(STATUS "rpmbuild NOT found. RPM generation will not be available")
set(RPMBUILD_FOUND "NO")
endif()

View File

@@ -0,0 +1,39 @@
# This is called by cmake as an extermal process from
# ./source/creator/CMakeLists.txt to write ./source/creator/buildinfo.h
# The FindSubversion.cmake module is part of the standard distribution
include(FindSubversion)
# Extract working copy information for SOURCE_DIR into MY_XXX variables
# with a default in case anything fails, for examble when using git-svn
set(MY_WC_REVISION "unknown")
# Guess if this is a SVN working copy and then look up the revision
if(EXISTS ${SOURCE_DIR}/.svn/)
if(Subversion_FOUND)
Subversion_WC_INFO(${SOURCE_DIR} MY)
endif()
endif()
# BUILD_PLATFORM and BUILD_PLATFORM are taken from CMake
# but BUILD_DATE and BUILD_TIME are plataform dependant
if(UNIX)
execute_process(COMMAND date "+%Y-%m-%d" OUTPUT_VARIABLE BUILD_DATE OUTPUT_STRIP_TRAILING_WHITESPACE)
execute_process(COMMAND date "+%H:%M:%S" OUTPUT_VARIABLE BUILD_TIME OUTPUT_STRIP_TRAILING_WHITESPACE)
endif()
if(WIN32)
execute_process(COMMAND cmd /c date /t OUTPUT_VARIABLE BUILD_DATE OUTPUT_STRIP_TRAILING_WHITESPACE)
execute_process(COMMAND cmd /c time /t OUTPUT_VARIABLE BUILD_TIME OUTPUT_STRIP_TRAILING_WHITESPACE)
endif()
# Write a file with the SVNVERSION define
file(WRITE buildinfo.h.txt
"#define BUILD_REV \"${MY_WC_REVISION}\"\n"
"#define BUILD_DATE \"${BUILD_DATE}\"\n"
"#define BUILD_TIME \"${BUILD_TIME}\"\n"
)
# Copy the file to the final header only if the version changes
# and avoid needless rebuilds
# TODO: verify this comment is true, as BUILD_TIME probably changes
execute_process(COMMAND ${CMAKE_COMMAND} -E copy_if_different
buildinfo.h.txt buildinfo.h)

View File

@@ -0,0 +1,297 @@
#!/usr/bin/env python
# $Id$
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# Contributor(s): Campbell Barton
#
# ***** END GPL LICENSE BLOCK *****
# <pep8 compliant>
from cmake_consistency_check_config import IGNORE, UTF8_CHECK, SOURCE_DIR
import os
from os.path import join, dirname, normpath, splitext
print("Scanning:", SOURCE_DIR)
global_h = set()
global_c = set()
global_refs = {}
def replace_line(f, i, text, keep_indent=True):
file_handle = open(f, 'r')
data = file_handle.readlines()
file_handle.close()
l = data[i]
ws = l[:len(l) - len(l.lstrip())]
data[i] = "%s%s\n" % (ws, text)
file_handle = open(f, 'w')
file_handle.writelines(data)
file_handle.close()
def source_list(path, filename_check=None):
for dirpath, dirnames, filenames in os.walk(path):
# skip '.svn'
if dirpath.startswith("."):
continue
for filename in filenames:
if filename_check is None or filename_check(filename):
yield os.path.join(dirpath, filename)
# extension checking
def is_cmake(filename):
ext = splitext(filename)[1]
return (ext == ".cmake") or (filename == "CMakeLists.txt")
def is_c_header(filename):
ext = splitext(filename)[1]
return (ext in (".h", ".hpp", ".hxx"))
def is_c(filename):
ext = splitext(filename)[1]
return (ext in (".c", ".cpp", ".cxx", ".m", ".mm", ".rc"))
def is_c_any(filename):
return is_c(filename) or is_c_header(filename)
def cmake_get_src(f):
sources_h = []
sources_c = []
filen = open(f, "r", encoding="utf8")
it = iter(filen)
found = False
i = 0
# print(f)
def is_definition(l, f, i, name):
if ('set(%s' % name) in l or ('set(' in l and l.endswith(name)):
if len(l.split()) > 1:
raise Exception("strict formatting not kept 'set(%s*' %s:%d" % (name, f, i))
return True
if ("list(APPEND %s" % name) in l or ('list(APPEND ' in l and l.endswith(name)):
if l.endswith(")"):
raise Exception("strict formatting not kept 'list(APPEND %s...)' on 1 line %s:%d" % (name, f, i))
return True
while it is not None:
context_name = ""
while it is not None:
i += 1
try:
l = next(it)
except StopIteration:
it = None
break
l = l.strip()
if not l.startswith("#"):
found = is_definition(l, f, i, "SRC")
if found:
context_name = "SRC"
break
found = is_definition(l, f, i, "INC")
if found:
context_name = "INC"
break
if found:
cmake_base = dirname(f)
while it is not None:
i += 1
try:
l = next(it)
except StopIteration:
it = None
break
l = l.strip()
if not l.startswith("#"):
if ")" in l:
if l.strip() != ")":
raise Exception("strict formatting not kept '*)' %s:%d" % (f, i))
break
# replace dirs
l = l.replace("${CMAKE_CURRENT_SOURCE_DIR}", cmake_base)
if not l:
pass
elif l.startswith("$"):
if context_name == "SRC":
# assume if it ends with context_name we know about it
if not l.split("}")[0].endswith(context_name):
print("Can't use var '%s' %s:%d" % (l, f, i))
elif len(l.split()) > 1:
raise Exception("Multi-line define '%s' %s:%d" % (l, f, i))
else:
new_file = normpath(join(cmake_base, l))
if context_name == "SRC":
if is_c_header(new_file):
sources_h.append(new_file)
global_refs.setdefault(new_file, []).append((f, i))
elif is_c(new_file):
sources_c.append(new_file)
global_refs.setdefault(new_file, []).append((f, i))
elif l in ("PARENT_SCOPE", ):
# cmake var, ignore
pass
elif new_file.endswith(".list"):
pass
elif new_file.endswith(".def"):
pass
else:
raise Exception("unknown file type - not c or h %s -> %s" % (f, new_file))
elif context_name == "INC":
if os.path.isdir(new_file):
new_path_rel = os.path.relpath(new_file, cmake_base)
if new_path_rel != l:
print("overly relative path:\n %s:%d\n %s\n %s" % (f, i, l, new_path_rel))
## Save time. just replace the line
# replace_line(f, i - 1, new_path_rel)
else:
raise Exception("non existant include %s:%d -> %s" % (f, i, new_file))
# print(new_file)
global_h.update(set(sources_h))
global_c.update(set(sources_c))
'''
if not sources_h and not sources_c:
raise Exception("No sources %s" % f)
sources_h_fs = list(source_list(cmake_base, is_c_header))
sources_c_fs = list(source_list(cmake_base, is_c))
'''
# find missing C files:
'''
for ff in sources_c_fs:
if ff not in sources_c:
print(" missing: " + ff)
'''
# reset
sources_h[:] = []
sources_c[:] = []
filen.close()
for cmake in source_list(SOURCE_DIR, is_cmake):
cmake_get_src(cmake)
def is_ignore(f):
for ig in IGNORE:
if ig in f:
return True
return False
# First do stupid check, do these files exist?
print("\nChecking for missing references:")
is_err = False
errs = []
for f in (global_h | global_c):
if f.endswith("dna.c"):
continue
if not os.path.exists(f):
refs = global_refs[f]
if refs:
for cf, i in refs:
errs.append((cf, i))
else:
raise Exception("CMake referenecs missing, internal error, aborting!")
is_err = True
errs.sort()
errs.reverse()
for cf, i in errs:
print("%s:%d" % (cf, i))
# Write a 'sed' script, useful if we get a lot of these
# print("sed '%dd' '%s' > '%s.tmp' ; mv '%s.tmp' '%s'" % (i, cf, cf, cf, cf))
if is_err:
raise Exception("CMake referenecs missing files, aborting!")
del is_err
del errs
# now check on files not accounted for.
print("\nC/C++ Files CMake doesnt know about...")
for cf in sorted(source_list(SOURCE_DIR, is_c)):
if not is_ignore(cf):
if cf not in global_c:
print("missing_c: ", cf)
# check if automake builds a corrasponding .o file.
'''
if cf in global_c:
out1 = os.path.splitext(cf)[0] + ".o"
out2 = os.path.splitext(cf)[0] + ".Po"
out2_dir, out2_file = out2 = os.path.split(out2)
out2 = os.path.join(out2_dir, ".deps", out2_file)
if not os.path.exists(out1) and not os.path.exists(out2):
print("bad_c: ", cf)
'''
print("\nC/C++ Headers CMake doesnt know about...")
for hf in sorted(source_list(SOURCE_DIR, is_c_header)):
if not is_ignore(hf):
if hf not in global_h:
print("missing_h: ", hf)
if UTF8_CHECK:
# test encoding
import traceback
for files in (global_c, global_h):
for f in sorted(files):
if os.path.exists(f):
# ignore outside of our source tree
if "extern" not in f:
i = 1
try:
for l in open(f, "r", encoding="utf8"):
i += 1
except:
print("Non utf8: %s:%d" % (f, i))
if i > 1:
traceback.print_exc()

View File

@@ -0,0 +1,48 @@
import os
IGNORE = (
"/test/",
"/decimate_glut_test/",
"/BSP_GhostTest/",
"/release/",
"/xembed/",
"/decimation/intern/future/",
"/TerraplayNetwork/",
"/ik_glut_test/",
# specific source files
"extern/Eigen2/Eigen/src/Cholesky/CholeskyInstantiations.cpp",
"extern/Eigen2/Eigen/src/Core/CoreInstantiations.cpp",
"extern/Eigen2/Eigen/src/QR/QrInstantiations.cpp",
"extern/bullet2/src/BulletCollision/CollisionDispatch/btBox2dBox2dCollisionAlgorithm.cpp",
"extern/bullet2/src/BulletCollision/CollisionDispatch/btConvex2dConvex2dAlgorithm.cpp",
"extern/bullet2/src/BulletCollision/CollisionDispatch/btInternalEdgeUtility.cpp",
"extern/bullet2/src/BulletCollision/CollisionShapes/btBox2dShape.cpp",
"extern/bullet2/src/BulletCollision/CollisionShapes/btConvex2dShape.cpp",
"extern/bullet2/src/BulletDynamics/Character/btKinematicCharacterController.cpp",
"extern/bullet2/src/BulletDynamics/ConstraintSolver/btHinge2Constraint.cpp",
"extern/bullet2/src/BulletDynamics/ConstraintSolver/btUniversalConstraint.cpp",
"extern/eltopo/common/meshes/ObjLoader.cpp",
"extern/eltopo/common/meshes/meshloader.cpp",
"extern/eltopo/common/openglutils.cpp",
"extern/eltopo/eltopo3d/broadphase_blenderbvh.cpp",
"source/blender/imbuf/intern/imbuf_cocoa.m",
"extern/bullet2/src/BulletCollision/CollisionDispatch/btBox2dBox2dCollisionAlgorithm.h",
"extern/bullet2/src/BulletCollision/CollisionDispatch/btConvex2dConvex2dAlgorithm.h",
"extern/bullet2/src/BulletCollision/CollisionDispatch/btInternalEdgeUtility.h",
"extern/bullet2/src/BulletCollision/CollisionShapes/btBox2dShape.h",
"extern/bullet2/src/BulletCollision/CollisionShapes/btConvex2dShape.h",
"extern/bullet2/src/BulletDynamics/Character/btKinematicCharacterController.h",
"extern/bullet2/src/BulletDynamics/ConstraintSolver/btHinge2Constraint.h",
"extern/bullet2/src/BulletDynamics/ConstraintSolver/btUniversalConstraint.h",
"extern/eltopo/common/meshes/Edge.hpp",
"extern/eltopo/common/meshes/ObjLoader.hpp",
"extern/eltopo/common/meshes/TriangleIndex.hpp",
"extern/eltopo/common/meshes/meshloader.h",
"extern/eltopo/eltopo3d/broadphase_blenderbvh.h"
)
UTF8_CHECK = True
SOURCE_DIR = os.path.normpath(os.path.abspath(os.path.normpath(os.path.join(os.path.dirname(__file__), "..", ".."))))

View File

@@ -0,0 +1,240 @@
#!/usr/bin/env python
# $Id$
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# Contributor(s): Campbell Barton, M.G. Kishalmi
#
# ***** END GPL LICENSE BLOCK *****
# <pep8 compliant>
"""
Example linux usage
python .~/blenderSVN/blender/build_files/cmake/cmake_netbeans_project.py ~/blenderSVN/cmake
Windows not supported so far
"""
from project_info import (SIMPLE_PROJECTFILE,
SOURCE_DIR,
CMAKE_DIR,
PROJECT_DIR,
source_list,
is_project_file,
is_c_header,
# is_py,
cmake_advanced_info,
cmake_compiler_defines,
)
import os
from os.path import join, dirname, normpath, relpath, exists
def create_nb_project_main():
files = list(source_list(SOURCE_DIR, filename_check=is_project_file))
files_rel = [relpath(f, start=PROJECT_DIR) for f in files]
files_rel.sort()
if SIMPLE_PROJECTFILE:
pass
else:
includes, defines = cmake_advanced_info()
# for some reason it doesnt give all internal includes
includes = list(set(includes) | set(dirname(f) for f in files if is_c_header(f)))
includes.sort()
PROJECT_NAME = "Blender"
# --------------- NB spesific
defines = [("%s=%s" % cdef) if cdef[1] else cdef[0] for cdef in defines]
defines += [cdef.replace("#define", "").strip() for cdef in cmake_compiler_defines()]
def file_list_to_nested(files):
# convert paths to hierarchy
paths_nested = {}
def ensure_path(filepath):
filepath_split = filepath.split(os.sep)
pn = paths_nested
for subdir in filepath_split[:-1]:
pn = pn.setdefault(subdir, {})
pn[filepath_split[-1]] = None
for path in files:
ensure_path(path)
return paths_nested
PROJECT_DIR_NB = join(PROJECT_DIR, "nbproject")
if not exists(PROJECT_DIR_NB):
os.mkdir(PROJECT_DIR_NB)
# SOURCE_DIR_REL = relpath(SOURCE_DIR, PROJECT_DIR)
f = open(join(PROJECT_DIR_NB, "project.xml"), 'w')
f.write('<?xml version="1.0" encoding="UTF-8"?>\n')
f.write('<project xmlns="http://www.netbeans.org/ns/project/1">\n')
f.write(' <type>org.netbeans.modules.cnd.makeproject</type>\n')
f.write(' <configuration>\n')
f.write(' <data xmlns="http://www.netbeans.org/ns/make-project/1">\n')
f.write(' <name>%s</name>\n' % PROJECT_NAME)
f.write(' <c-extensions>c,m</c-extensions>\n')
f.write(' <cpp-extensions>cpp,mm</cpp-extensions>\n')
f.write(' <header-extensions>h,hpp,inl</header-extensions>\n')
f.write(' <sourceEncoding>UTF-8</sourceEncoding>\n')
f.write(' <make-dep-projects/>\n')
f.write(' <sourceRootList>\n')
f.write(' <sourceRootElem>%s</sourceRootElem>\n' % SOURCE_DIR) # base_root_rel
f.write(' </sourceRootList>\n')
f.write(' <confList>\n')
f.write(' <confElem>\n')
f.write(' <name>Default</name>\n')
f.write(' <type>0</type>\n')
f.write(' </confElem>\n')
f.write(' </confList>\n')
f.write(' </data>\n')
f.write(' </configuration>\n')
f.write('</project>\n')
f = open(join(PROJECT_DIR_NB, "configurations.xml"), 'w')
f.write('<?xml version="1.0" encoding="UTF-8"?>\n')
f.write('<configurationDescriptor version="79">\n')
f.write(' <logicalFolder name="root" displayName="root" projectFiles="true" kind="ROOT">\n')
f.write(' <df name="blender" root="%s">\n' % SOURCE_DIR) # base_root_rel
# write files!
files_rel_local = [normpath(relpath(join(CMAKE_DIR, path), SOURCE_DIR)) for path in files_rel]
files_rel_hierarchy = file_list_to_nested(files_rel_local)
# print(files_rel_hierarchy)
def write_df(hdir, ident):
dirs = []
files = []
for key, item in sorted(hdir.items()):
if item is None:
files.append(key)
else:
dirs.append((key, item))
for key, item in dirs:
f.write('%s <df name="%s">\n' % (ident, key))
write_df(item, ident + " ")
f.write('%s </df>\n' % ident)
for key in files:
f.write('%s<in>%s</in>\n' % (ident, key))
write_df(files_rel_hierarchy, ident=" ")
f.write(' </df>\n')
f.write(' <logicalFolder name="ExternalFiles"\n')
f.write(' displayName="Important Files"\n')
f.write(' projectFiles="false"\n')
f.write(' kind="IMPORTANT_FILES_FOLDER">\n')
# f.write(' <itemPath>../GNUmakefile</itemPath>\n')
f.write(' </logicalFolder>\n')
f.write(' </logicalFolder>\n')
# default, but this dir is infact not in blender dir so we can ignore it
# f.write(' <sourceFolderFilter>^(nbproject)$</sourceFolderFilter>\n')
f.write(' <sourceFolderFilter>^(nbproject|__pycache__|.*\.py|.*\.html|.*\.blend)$</sourceFolderFilter>\n')
f.write(' <sourceRootList>\n')
f.write(' <Elem>%s</Elem>\n' % SOURCE_DIR) # base_root_rel
f.write(' </sourceRootList>\n')
f.write(' <projectmakefile>Makefile</projectmakefile>\n')
# paths again
f.write(' <confs>\n')
f.write(' <conf name="Default" type="0">\n')
f.write(' <toolsSet>\n')
f.write(' <remote-sources-mode>LOCAL_SOURCES</remote-sources-mode>\n')
f.write(' <compilerSet>default</compilerSet>\n')
f.write(' </toolsSet>\n')
f.write(' <makefileType>\n')
f.write(' <makeTool>\n')
f.write(' <buildCommandWorkingDir>.</buildCommandWorkingDir>\n')
f.write(' <buildCommand>${MAKE} -f Makefile</buildCommand>\n')
f.write(' <cleanCommand>${MAKE} -f Makefile clean</cleanCommand>\n')
f.write(' <executablePath>./bin/blender</executablePath>\n')
def write_toolinfo():
f.write(' <incDir>\n')
for inc in includes:
f.write(' <pElem>%s</pElem>\n' % inc)
f.write(' </incDir>\n')
f.write(' <preprocessorList>\n')
for cdef in defines:
f.write(' <Elem>%s</Elem>\n' % cdef)
f.write(' </preprocessorList>\n')
f.write(' <cTool>\n')
write_toolinfo()
f.write(' </cTool>\n')
f.write(' <ccTool>\n')
write_toolinfo()
f.write(' </ccTool>\n')
f.write(' </makeTool>\n')
f.write(' </makefileType>\n')
# finishe makefle info
f.write(' \n')
for path in files_rel_local:
f.write(' <item path="%s"\n' % path)
f.write(' ex="false"\n')
f.write(' tool="1"\n')
f.write(' flavor="0">\n')
f.write(' </item>\n')
f.write(' <runprofile version="9">\n')
f.write(' <runcommandpicklist>\n')
f.write(' </runcommandpicklist>\n')
f.write(' <runcommand>%s</runcommand>\n' % os.path.join(CMAKE_DIR, "bin/blender"))
f.write(' <rundir>%s</rundir>\n' % SOURCE_DIR)
f.write(' <buildfirst>false</buildfirst>\n')
f.write(' <terminal-type>0</terminal-type>\n')
f.write(' <remove-instrumentation>0</remove-instrumentation>\n')
f.write(' <environment>\n')
f.write(' </environment>\n')
f.write(' </runprofile>\n')
f.write(' </conf>\n')
f.write(' </confs>\n')
# todo
f.write('</configurationDescriptor>\n')
def main():
create_nb_project_main()
if __name__ == "__main__":
main()

View File

@@ -0,0 +1,133 @@
#!/usr/bin/env python
# $Id$
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# Contributor(s): Campbell Barton, M.G. Kishalmi
#
# ***** END GPL LICENSE BLOCK *****
# <pep8 compliant>
"""
Example Win32 usage:
c:\Python32\python.exe c:\blender_dev\blender\build_files\cmake\cmake_qtcreator_project.py c:\blender_dev\cmake_build
example linux usage
python .~/blenderSVN/blender/build_files/cmake/cmake_qtcreator_project.py ~/blenderSVN/cmake
"""
from project_info import (SIMPLE_PROJECTFILE,
SOURCE_DIR,
# CMAKE_DIR,
PROJECT_DIR,
source_list,
is_project_file,
is_c_header,
is_py,
cmake_advanced_info,
cmake_compiler_defines,
)
import os
import sys
def create_qtc_project_main():
files = list(source_list(SOURCE_DIR, filename_check=is_project_file))
files_rel = [os.path.relpath(f, start=PROJECT_DIR) for f in files]
files_rel.sort()
# --- qtcreator specific, simple format
if SIMPLE_PROJECTFILE:
# --- qtcreator specific, simple format
PROJECT_NAME = "Blender"
f = open(os.path.join(PROJECT_DIR, "%s.files" % PROJECT_NAME), 'w')
f.write("\n".join(files_rel))
f = open(os.path.join(PROJECT_DIR, "%s.includes" % PROJECT_NAME), 'w')
f.write("\n".join(sorted(list(set(os.path.dirname(f) for f in files_rel if is_c_header(f))))))
qtc_prj = os.path.join(PROJECT_DIR, "%s.creator" % PROJECT_NAME)
f = open(qtc_prj, 'w')
f.write("[General]\n")
qtc_cfg = os.path.join(PROJECT_DIR, "%s.config" % PROJECT_NAME)
if not os.path.exists(qtc_cfg):
f = open(qtc_cfg, 'w')
f.write("// ADD PREDEFINED MACROS HERE!\n")
else:
includes, defines = cmake_advanced_info()
# for some reason it doesnt give all internal includes
includes = list(set(includes) | set(os.path.dirname(f) for f in files_rel if is_c_header(f)))
includes.sort()
PROJECT_NAME = "Blender"
FILE_NAME = PROJECT_NAME.lower()
f = open(os.path.join(PROJECT_DIR, "%s.files" % FILE_NAME), 'w')
f.write("\n".join(files_rel))
f = open(os.path.join(PROJECT_DIR, "%s.includes" % FILE_NAME), 'w')
f.write("\n".join(sorted(includes)))
qtc_prj = os.path.join(PROJECT_DIR, "%s.creator" % FILE_NAME)
f = open(qtc_prj, 'w')
f.write("[General]\n")
qtc_cfg = os.path.join(PROJECT_DIR, "%s.config" % FILE_NAME)
f = open(qtc_cfg, 'w')
f.write("// ADD PREDEFINED MACROS HERE!\n")
defines_final = [("#define %s %s" % item) for item in defines]
if sys.platform != "win32":
defines_final += cmake_compiler_defines() # defines from the compiler
f.write("\n".join(defines_final))
print("Blender project file written to: %s" % qtc_prj)
# --- end
def create_qtc_project_python():
files = list(source_list(SOURCE_DIR, filename_check=is_py))
files_rel = [os.path.relpath(f, start=PROJECT_DIR) for f in files]
files_rel.sort()
# --- qtcreator specific, simple format
PROJECT_NAME = "Blender_Python"
FILE_NAME = PROJECT_NAME.lower()
f = open(os.path.join(PROJECT_DIR, "%s.files" % FILE_NAME), 'w')
f.write("\n".join(files_rel))
qtc_prj = os.path.join(PROJECT_DIR, "%s.creator" % FILE_NAME)
f = open(qtc_prj, 'w')
f.write("[General]\n")
qtc_cfg = os.path.join(PROJECT_DIR, "%s.config" % FILE_NAME)
if not os.path.exists(qtc_cfg):
f = open(qtc_cfg, 'w')
f.write("// ADD PREDEFINED MACROS HERE!\n")
print("Python project file written to: %s" % qtc_prj)
def main():
create_qtc_project_main()
create_qtc_project_python()
if __name__ == "__main__":
main()

View File

@@ -0,0 +1,24 @@
# headless configuration, useful in for servers or renderfarms
# builds without a windowing system (X11/Windows/Cocoa).
#
# Example usage:
# cmake -C../blender/build_files/cmake/config/blender_headless.cmake ../blender
#
set(WITH_HEADLESS ON CACHE FORCE BOOL)
set(WITH_GAMEENGINE OFF CACHE FORCE BOOL)
# disable audio, its possible some devs may want this but for now disable
# so the python module doesnt hold the audio device and loads quickly.
set(WITH_AUDASPACE OFF CACHE FORCE BOOL)
set(WITH_SAMPLERATE OFF CACHE FORCE BOOL)
set(WITH_FFTW3 OFF CACHE FORCE BOOL)
set(WITH_JACK OFF CACHE FORCE BOOL)
set(WITH_SDL OFF CACHE FORCE BOOL)
set(WITH_OPENAL OFF CACHE FORCE BOOL)
set(WITH_CODEC_FFMPEG OFF CACHE FORCE BOOL)
set(WITH_CODEC_SNDFILE OFF CACHE FORCE BOOL)
# other features which are not especially useful as a python module
set(WITH_X11_XINPUT OFF CACHE FORCE BOOL)
set(WITH_INPUT_NDOF OFF CACHE FORCE BOOL)

View File

@@ -0,0 +1,43 @@
# turn everything OFF except for python which defaults to ON
# and is needed for the UI
#
# Example usage:
# cmake -C../blender/build_files/cmake/config/blender_lite.cmake ../blender
#
set(WITH_INSTALL_PORTABLE ON CACHE FORCE BOOL)
set(WITH_BUILDINFO OFF CACHE FORCE BOOL)
set(WITH_BUILTIN_GLEW OFF CACHE FORCE BOOL)
set(WITH_BULLET OFF CACHE FORCE BOOL)
set(WITH_CODEC_FFMPEG OFF CACHE FORCE BOOL)
set(WITH_CODEC_SNDFILE OFF CACHE FORCE BOOL)
set(WITH_FFTW3 OFF CACHE FORCE BOOL)
set(WITH_GAMEENGINE OFF CACHE FORCE BOOL)
set(WITH_IK_ITASC OFF CACHE FORCE BOOL)
set(WITH_IMAGE_CINEON OFF CACHE FORCE BOOL)
set(WITH_IMAGE_DDS OFF CACHE FORCE BOOL)
set(WITH_IMAGE_FRAMESERVER OFF CACHE FORCE BOOL)
set(WITH_IMAGE_HDR OFF CACHE FORCE BOOL)
set(WITH_IMAGE_OPENEXR OFF CACHE FORCE BOOL)
set(WITH_IMAGE_OPENJPEG OFF CACHE FORCE BOOL)
set(WITH_IMAGE_REDCODE OFF CACHE FORCE BOOL)
set(WITH_IMAGE_TIFF OFF CACHE FORCE BOOL)
set(WITH_INPUT_NDOF OFF CACHE FORCE BOOL)
set(WITH_INTERNATIONAL OFF CACHE FORCE BOOL)
set(WITH_JACK OFF CACHE FORCE BOOL)
set(WITH_LZMA OFF CACHE FORCE BOOL)
set(WITH_LZO OFF CACHE FORCE BOOL)
set(WITH_MOD_BOOLEAN OFF CACHE FORCE BOOL)
set(WITH_MOD_DECIMATE OFF CACHE FORCE BOOL)
set(WITH_MOD_FLUID OFF CACHE FORCE BOOL)
set(WITH_MOD_SMOKE OFF CACHE FORCE BOOL)
set(WITH_AUDASPACE OFF CACHE FORCE BOOL)
set(WITH_OPENAL OFF CACHE FORCE BOOL)
set(WITH_OPENCOLLADA OFF CACHE FORCE BOOL)
set(WITH_OPENMP OFF CACHE FORCE BOOL)
set(WITH_PYTHON_INSTALL OFF CACHE FORCE BOOL)
set(WITH_RAYOPTIMIZATION OFF CACHE FORCE BOOL)
set(WITH_SAMPLERATE OFF CACHE FORCE BOOL)
set(WITH_SDL OFF CACHE FORCE BOOL)
set(WITH_X11_XINPUT OFF CACHE FORCE BOOL)

View File

@@ -0,0 +1,34 @@
# defaults for building blender as a python module 'bpy'
#
# Example usage:
# cmake -C../blender/build_files/cmake/config/bpy_module.cmake ../blender
#
set(WITH_PYTHON_MODULE ON CACHE FORCE BOOL)
# install into the systems python dir
set(WITH_INSTALL_PORTABLE OFF CACHE FORCE BOOL)
# no point int copying python into python
set(WITH_PYTHON_INSTALL OFF CACHE FORCE BOOL)
# dont build the game engine
set(WITH_GAMEENGINE OFF CACHE FORCE BOOL)
# disable audio, its possible some devs may want this but for now disable
# so the python module doesnt hold the audio device and loads quickly.
set(WITH_AUDASPACE OFF CACHE FORCE BOOL)
set(WITH_SAMPLERATE OFF CACHE FORCE BOOL)
set(WITH_FFTW3 OFF CACHE FORCE BOOL)
set(WITH_JACK OFF CACHE FORCE BOOL)
set(WITH_SDL OFF CACHE FORCE BOOL)
set(WITH_OPENAL OFF CACHE FORCE BOOL)
set(WITH_CODEC_FFMPEG OFF CACHE FORCE BOOL)
set(WITH_CODEC_SNDFILE OFF CACHE FORCE BOOL)
# other features which are not especially useful as a python module
set(WITH_X11_XINPUT OFF CACHE FORCE BOOL)
set(WITH_INPUT_NDOF OFF CACHE FORCE BOOL)
set(WITH_OPENCOLLADA OFF CACHE FORCE BOOL)
set(WITH_INTERNATIONAL OFF CACHE FORCE BOOL)
set(WITH_BULLET OFF CACHE FORCE BOOL)

View File

@@ -17,7 +17,7 @@ cd ~/blender-svn/build-cmake
# cmake without copying files for fast rebuilds
# the files from svn will be used in place
cmake ../blender -DWITH_INSTALL:BOOL=FALSE
cmake ../blender
# make blender, will take some time
make

View File

@@ -43,8 +43,8 @@ def main():
targets = set()
# collect targets
file = open("Makefile", "r")
for line in file:
makefile = open("Makefile", "r")
for line in makefile:
line = line.rstrip()
if not line or line[0] in ". \t@$#":
continue
@@ -59,7 +59,7 @@ def main():
continue
targets.add(line)
file.close()
makefile.close()
# remove cmake targets
bad = set([

View File

@@ -0,0 +1,10 @@
#!/bin/bash
# filters CMake output to be more like nan-makefiles
FILTER="^\[ *[0-9]*%] \|^Built target \|^Scanning "
make $@ | \
sed -u -e 's/^Linking .*\//Linking /' | \
sed -u -e 's/^.*\// /' | \
grep --line-buffered -v "$FILTER"
echo "Build Done"

View File

@@ -1,309 +1,574 @@
# -*- mode: cmake; indent-tabs-mode: t; -*-
# $Id$
IF(MSVC)
# only MSVC uses SOURCE_GROUP
MACRO(BLENDERLIB_NOLIST
name
sources
includes)
MESSAGE(STATUS "Configuring library ${name}")
# foo_bar.spam --> foo_barMySuffix.spam
macro(file_suffix
file_name_new file_name file_suffix
)
# Gather all headers
FILE(GLOB_RECURSE INC_ALL *.h)
INCLUDE_DIRECTORIES(${includes})
ADD_LIBRARY(${name} ${INC_ALL} ${sources})
get_filename_component(_file_name_PATH ${file_name} PATH)
get_filename_component(_file_name_NAME_WE ${file_name} NAME_WE)
get_filename_component(_file_name_EXT ${file_name} EXT)
set(${file_name_new} "${_file_name_PATH}/${_file_name_NAME_WE}${file_suffix}${_file_name_EXT}")
# Group by location on disk
SOURCE_GROUP(Files FILES CMakeLists.txt)
SET(ALL_FILES ${sources} ${INC_ALL})
FOREACH(SRC ${ALL_FILES})
STRING(REGEX REPLACE ${CMAKE_CURRENT_SOURCE_DIR} "Files" REL_DIR "${SRC}")
STRING(REGEX REPLACE "[\\\\/][^\\\\/]*$" "" REL_DIR "${REL_DIR}")
STRING(REGEX REPLACE "^[\\\\/]" "" REL_DIR "${REL_DIR}")
IF(REL_DIR)
SOURCE_GROUP(${REL_DIR} FILES ${SRC})
ELSE(REL_DIR)
SOURCE_GROUP(Files FILES ${SRC})
ENDIF(REL_DIR)
ENDFOREACH(SRC)
ENDMACRO(BLENDERLIB_NOLIST)
ELSE(MSVC)
unset(_file_name_PATH)
unset(_file_name_NAME_WE)
unset(_file_name_EXT)
endmacro()
MACRO(BLENDERLIB_NOLIST
name
sources
includes)
# usefil for adding debug suffix to library lists:
# /somepath/foo.lib --> /somepath/foo_d.lib
macro(file_list_suffix
fp_list_new fp_list fn_suffix
)
MESSAGE(STATUS "Configuring library ${name}")
INCLUDE_DIRECTORIES(${includes})
ADD_LIBRARY(${name} ${sources})
ENDMACRO(BLENDERLIB_NOLIST)
ENDIF(MSVC)
# incase of empty list
set(_fp)
set(_fp_suffixed)
MACRO(BLENDERLIB
set(fp_list_new)
foreach(_fp ${fp_list})
file_suffix(_fp_suffixed "${_fp}" "${fn_suffix}")
list(APPEND "${fp_list_new}" "${_fp_suffixed}")
endforeach()
unset(_fp)
unset(_fp_suffixed)
endmacro()
macro(target_link_libraries_optimized TARGET LIBS)
foreach(_LIB ${LIBS})
target_link_libraries(${TARGET} optimized "${_LIB}")
endforeach()
unset(_LIB)
endmacro()
macro(target_link_libraries_debug TARGET LIBS)
foreach(_LIB ${LIBS})
target_link_libraries(${TARGET} debug "${_LIB}")
endforeach()
unset(_LIB)
endmacro()
# Nicer makefiles with -I/1/foo/ instead of -I/1/2/3/../../foo/
# use it instead of include_directories()
macro(blender_include_dirs
includes)
set(_ALL_INCS "")
foreach(_INC ${ARGV})
get_filename_component(_ABS_INC ${_INC} ABSOLUTE)
list(APPEND _ALL_INCS ${_ABS_INC})
# for checking for invalid includes, disable for regular use
##if(NOT EXISTS "${_ABS_INC}/")
## message(FATAL_ERROR "Include not found: ${_ABS_INC}/")
##endif()
endforeach()
include_directories(${_ALL_INCS})
unset(_INC)
unset(_ABS_INC)
unset(_ALL_INCS)
endmacro()
macro(blender_include_dirs_sys
includes)
set(_ALL_INCS "")
foreach(_INC ${ARGV})
get_filename_component(_ABS_INC ${_INC} ABSOLUTE)
list(APPEND _ALL_INCS ${_ABS_INC})
##if(NOT EXISTS "${_ABS_INC}/")
## message(FATAL_ERROR "Include not found: ${_ABS_INC}/")
##endif()
endforeach()
include_directories(SYSTEM ${_ALL_INCS})
unset(_INC)
unset(_ABS_INC)
unset(_ALL_INCS)
endmacro()
macro(blender_source_group
sources)
# Group by location on disk
source_group("Source Files" FILES CMakeLists.txt)
foreach(_SRC ${sources})
get_filename_component(_SRC_EXT ${_SRC} EXT)
if((${_SRC_EXT} MATCHES ".h") OR (${_SRC_EXT} MATCHES ".hpp"))
source_group("Header Files" FILES ${_SRC})
else()
source_group("Source Files" FILES ${_SRC})
endif()
endforeach()
unset(_SRC)
unset(_SRC_EXT)
endmacro()
# only MSVC uses SOURCE_GROUP
macro(blender_add_lib_nolist
name
sources
includes)
includes
includes_sys)
BLENDERLIB_NOLIST(${name} "${sources}" "${includes}")
# message(STATUS "Configuring library ${name}")
# Add to blender's list of libraries
FILE(APPEND ${CMAKE_BINARY_DIR}/cmake_blender_libs.txt "${name};")
ENDMACRO(BLENDERLIB)
# include_directories(${includes})
# include_directories(SYSTEM ${includes_sys})
blender_include_dirs("${includes}")
blender_include_dirs_sys("${includes_sys}")
MACRO(SETUP_LIBDIRS)
# see "cmake --help-policy CMP0003"
if(COMMAND cmake_policy)
CMAKE_POLICY(SET CMP0003 NEW)
endif(COMMAND cmake_policy)
LINK_DIRECTORIES(${JPEG_LIBPATH} ${PNG_LIBPATH} ${ZLIB_LIBPATH} ${FREETYPE_LIBPATH} ${LIBSAMPLERATE_LIBPATH})
IF(WITH_PYTHON)
LINK_DIRECTORIES(${PYTHON_LIBPATH})
ENDIF(WITH_PYTHON)
IF(WITH_INTERNATIONAL)
LINK_DIRECTORIES(${ICONV_LIBPATH})
LINK_DIRECTORIES(${GETTEXT_LIBPATH})
ENDIF(WITH_INTERNATIONAL)
IF(WITH_SDL)
LINK_DIRECTORIES(${SDL_LIBPATH})
ENDIF(WITH_SDL)
IF(WITH_FFMPEG)
LINK_DIRECTORIES(${FFMPEG_LIBPATH})
ENDIF(WITH_FFMPEG)
IF(WITH_IMAGE_OPENEXR)
LINK_DIRECTORIES(${OPENEXR_LIBPATH})
ENDIF(WITH_IMAGE_OPENEXR)
IF(WITH_IMAGE_TIFF)
LINK_DIRECTORIES(${TIFF_LIBPATH})
ENDIF(WITH_IMAGE_TIFF)
IF(WITH_LCMS)
LINK_DIRECTORIES(${LCMS_LIBPATH})
ENDIF(WITH_LCMS)
IF(WITH_QUICKTIME)
LINK_DIRECTORIES(${QUICKTIME_LIBPATH})
ENDIF(WITH_QUICKTIME)
IF(WITH_OPENAL)
LINK_DIRECTORIES(${OPENAL_LIBPATH})
ENDIF(WITH_OPENAL)
IF(WITH_JACK)
LINK_DIRECTORIES(${JACK_LIBPATH})
ENDIF(WITH_JACK)
IF(WITH_SNDFILE)
LINK_DIRECTORIES(${SNDFILE_LIBPATH})
ENDIF(WITH_SNDFILE)
IF(WITH_FFTW3)
LINK_DIRECTORIES(${FFTW3_LIBPATH})
ENDIF(WITH_FFTW3)
IF(WITH_OPENCOLLADA)
LINK_DIRECTORIES(${OPENCOLLADA_LIBPATH})
LINK_DIRECTORIES(${PCRE_LIBPATH})
LINK_DIRECTORIES(${EXPAT_LIBPATH})
ENDIF(WITH_OPENCOLLADA)
add_library(${name} ${sources})
IF(WIN32)
LINK_DIRECTORIES(${PTHREADS_LIBPATH})
ENDIF(WIN32)
ENDMACRO(SETUP_LIBDIRS)
# works fine without having the includes
# listed is helpful for IDE's (QtCreator/MSVC)
blender_source_group("${sources}")
MACRO(SETUP_LIBLINKS
endmacro()
macro(blender_add_lib
name
sources
includes
includes_sys)
blender_add_lib_nolist(${name} "${sources}" "${includes}" "${includes_sys}")
set_property(GLOBAL APPEND PROPERTY BLENDER_LINK_LIBS ${name})
endmacro()
macro(SETUP_LIBDIRS)
link_directories(${JPEG_LIBPATH} ${PNG_LIBPATH} ${ZLIB_LIBPATH} ${FREETYPE_LIBPATH})
if(WITH_PYTHON) # AND NOT WITH_PYTHON_MODULE # WIN32 needs
link_directories(${PYTHON_LIBPATH})
endif()
if(WITH_INTERNATIONAL)
link_directories(${ICONV_LIBPATH})
link_directories(${GETTEXT_LIBPATH})
endif()
if(WITH_SDL)
link_directories(${SDL_LIBPATH})
endif()
if(WITH_CODEC_FFMPEG)
link_directories(${FFMPEG_LIBPATH})
endif()
if(WITH_IMAGE_OPENEXR)
link_directories(${OPENEXR_LIBPATH})
endif()
if(WITH_IMAGE_TIFF)
link_directories(${TIFF_LIBPATH})
endif()
if(WITH_IMAGE_OPENJPEG AND UNIX AND NOT APPLE)
link_directories(${OPENJPEG_LIBPATH})
endif()
if(WITH_CODEC_QUICKTIME)
link_directories(${QUICKTIME_LIBPATH})
endif()
if(WITH_OPENAL)
link_directories(${OPENAL_LIBPATH})
endif()
if(WITH_JACK)
link_directories(${JACK_LIBPATH})
endif()
if(WITH_CODEC_SNDFILE)
link_directories(${SNDFILE_LIBPATH})
endif()
if(WITH_SAMPLERATE)
link_directories(${SAMPLERATE_LIBPATH})
endif()
if(WITH_FFTW3)
link_directories(${FFTW3_LIBPATH})
endif()
if(WITH_OPENCOLLADA)
link_directories(${OPENCOLLADA_LIBPATH})
link_directories(${PCRE_LIBPATH})
link_directories(${EXPAT_LIBPATH})
endif()
if(WITH_MEM_JEMALLOC)
link_directories(${JEMALLOC_LIBPATH})
endif()
if(WIN32 AND NOT UNIX)
link_directories(${PTHREADS_LIBPATH})
endif()
endmacro()
macro(setup_liblinks
target)
SET(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${PLATFORM_LINKFLAGS} ")
TARGET_LINK_LIBRARIES(${target} ${OPENGL_gl_LIBRARY} ${OPENGL_glu_LIBRARY} ${JPEG_LIBRARY} ${PNG_LIBRARIES} ${ZLIB_LIBRARIES} ${LLIBS})
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${PLATFORM_LINKFLAGS}")
set(CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} ${PLATFORM_LINKFLAGS_DEBUG}")
target_link_libraries(${target}
${OPENGL_gl_LIBRARY}
${OPENGL_glu_LIBRARY}
${JPEG_LIBRARIES}
${PNG_LIBRARIES}
${ZLIB_LIBRARIES}
${PLATFORM_LINKLIBS})
# since we are using the local libs for python when compiling msvc projects, we need to add _d when compiling debug versions
IF(WITH_PYTHON)
TARGET_LINK_LIBRARIES(${target} ${PYTHON_LINKFLAGS})
if(WITH_PYTHON) # AND NOT WITH_PYTHON_MODULE # WIN32 needs
target_link_libraries(${target} ${PYTHON_LINKFLAGS})
IF(WIN32)
TARGET_LINK_LIBRARIES(${target} debug ${PYTHON_LIB}_d)
TARGET_LINK_LIBRARIES(${target} optimized ${PYTHON_LIB})
ELSE(WIN32)
TARGET_LINK_LIBRARIES(${target} ${PYTHON_LIB})
ENDIF(WIN32)
ENDIF(WITH_PYTHON)
if(WIN32 AND NOT UNIX)
file_list_suffix(PYTHON_LIBRARIES_DEBUG "${PYTHON_LIBRARIES}" "_d")
target_link_libraries_debug(${target} "${PYTHON_LIBRARIES_DEBUG}")
target_link_libraries_optimized(${target} "${PYTHON_LIBRARIES}")
unset(PYTHON_LIBRARIES_DEBUG)
else()
target_link_libraries(${target} ${PYTHON_LIBRARIES})
endif()
endif()
TARGET_LINK_LIBRARIES(${target} ${OPENGL_glu_LIBRARY} ${JPEG_LIB} ${PNG_LIB} ${ZLIB_LIB})
TARGET_LINK_LIBRARIES(${target} ${FREETYPE_LIBRARY} ${LIBSAMPLERATE_LIB})
if(NOT WITH_BUILTIN_GLEW)
target_link_libraries(${target} ${GLEW_LIBRARY})
endif()
IF(WITH_INTERNATIONAL)
TARGET_LINK_LIBRARIES(${target} ${GETTEXT_LIB})
target_link_libraries(${target}
${OPENGL_glu_LIBRARY}
${JPEG_LIBRARIES}
${PNG_LIBRARIES}
${ZLIB_LIBRARIES}
${FREETYPE_LIBRARY})
IF(WIN32)
TARGET_LINK_LIBRARIES(${target} ${ICONV_LIB})
ENDIF(WIN32)
ENDIF(WITH_INTERNATIONAL)
if(WITH_INTERNATIONAL)
target_link_libraries(${target} ${GETTEXT_LIB})
IF(WITH_OPENAL)
TARGET_LINK_LIBRARIES(${target} ${OPENAL_LIBRARY})
ENDIF(WITH_OPENAL)
IF(WITH_FFTW3)
TARGET_LINK_LIBRARIES(${target} ${FFTW3_LIB})
ENDIF(WITH_FFTW3)
IF(WITH_JACK)
TARGET_LINK_LIBRARIES(${target} ${JACK_LIB})
ENDIF(WITH_JACK)
IF(WITH_SNDFILE)
TARGET_LINK_LIBRARIES(${target} ${SNDFILE_LIB})
ENDIF(WITH_SNDFILE)
IF(WITH_SDL)
TARGET_LINK_LIBRARIES(${target} ${SDL_LIBRARY})
ENDIF(WITH_SDL)
IF(WITH_QUICKTIME)
TARGET_LINK_LIBRARIES(${target} ${QUICKTIME_LIB})
ENDIF(WITH_QUICKTIME)
IF(WITH_IMAGE_TIFF)
TARGET_LINK_LIBRARIES(${target} ${TIFF_LIBRARY})
ENDIF(WITH_IMAGE_TIFF)
IF(WITH_IMAGE_OPENEXR)
IF(WIN32)
FOREACH(loop_var ${OPENEXR_LIB})
TARGET_LINK_LIBRARIES(${target} debug ${loop_var}_d)
TARGET_LINK_LIBRARIES(${target} optimized ${loop_var})
ENDFOREACH(loop_var)
ELSE(WIN32)
TARGET_LINK_LIBRARIES(${target} ${OPENEXR_LIB})
ENDIF(WIN32)
ENDIF(WITH_IMAGE_OPENEXR)
IF(WITH_LCMS)
TARGET_LINK_LIBRARIES(${target} ${LCMS_LIBRARY})
ENDIF(WITH_LCMS)
IF(WITH_FFMPEG)
TARGET_LINK_LIBRARIES(${target} ${FFMPEG_LIB})
ENDIF(WITH_FFMPEG)
IF(WITH_OPENCOLLADA)
IF(WIN32)
FOREACH(loop_var ${OPENCOLLADA_LIB})
TARGET_LINK_LIBRARIES(${target} debug ${loop_var}_d)
TARGET_LINK_LIBRARIES(${target} optimized ${loop_var})
ENDFOREACH(loop_var)
TARGET_LINK_LIBRARIES(${target} debug ${PCRE_LIB}_d)
TARGET_LINK_LIBRARIES(${target} optimized ${PCRE_LIB})
IF(EXPAT_LIB)
TARGET_LINK_LIBRARIES(${target} debug ${EXPAT_LIB}_d)
TARGET_LINK_LIBRARIES(${target} optimized ${EXPAT_LIB})
ENDIF(EXPAT_LIB)
ELSE(WIN32)
TARGET_LINK_LIBRARIES(${target} ${OPENCOLLADA_LIB})
TARGET_LINK_LIBRARIES(${target} ${PCRE_LIB})
TARGET_LINK_LIBRARIES(${target} ${EXPAT_LIB})
ENDIF(WIN32)
ENDIF(WITH_OPENCOLLADA)
IF(WITH_LCMS)
IF(WIN32)
TARGET_LINK_LIBRARIES(${target} debug ${LCMS_LIB}_d)
TARGET_LINK_LIBRARIES(${target} optimized ${LCMS_LIB})
ENDIF(WIN32)
ENDIF(WITH_LCMS)
IF(WIN32)
TARGET_LINK_LIBRARIES(${target} ${PTHREADS_LIB})
ENDIF(WIN32)
ENDMACRO(SETUP_LIBLINKS)
if(WIN32 AND NOT UNIX)
target_link_libraries(${target} ${ICONV_LIBRARIES})
endif()
endif()
MACRO(TEST_SSE_SUPPORT)
INCLUDE(CheckCSourceRuns)
if(WITH_OPENAL)
target_link_libraries(${target} ${OPENAL_LIBRARY})
endif()
if(WITH_FFTW3)
target_link_libraries(${target} ${FFTW3_LIBRARIES})
endif()
if(WITH_JACK)
target_link_libraries(${target} ${JACK_LIBRARIES})
endif()
if(WITH_CODEC_SNDFILE)
target_link_libraries(${target} ${SNDFILE_LIBRARIES})
endif()
if(WITH_SAMPLERATE)
target_link_libraries(${target} ${SAMPLERATE_LIBRARIES})
endif()
if(WITH_SDL)
target_link_libraries(${target} ${SDL_LIBRARY})
endif()
if(WITH_CODEC_QUICKTIME)
target_link_libraries(${target} ${QUICKTIME_LIBRARIES})
endif()
if(WITH_IMAGE_TIFF)
target_link_libraries(${target} ${TIFF_LIBRARY})
endif()
if(WITH_IMAGE_OPENEXR)
if(WIN32 AND NOT UNIX)
file_list_suffix(OPENEXR_LIBRARIES_DEBUG "${OPENEXR_LIBRARIES}" "_d")
target_link_libraries_debug(${target} "${OPENEXR_LIBRARIES_DEBUG}")
target_link_libraries_optimized(${target} "${OPENEXR_LIBRARIES}")
unset(OPENEXR_LIBRARIES_DEBUG)
else()
target_link_libraries(${target} ${OPENEXR_LIBRARIES})
endif()
endif()
if(WITH_IMAGE_OPENJPEG AND UNIX AND NOT APPLE)
target_link_libraries(${target} ${OPENJPEG_LIBRARIES})
endif()
if(WITH_CODEC_FFMPEG)
target_link_libraries(${target} ${FFMPEG_LIBRARIES})
endif()
if(WITH_OPENCOLLADA)
if(WIN32 AND NOT UNIX)
file_list_suffix(OPENCOLLADA_LIBRARIES_DEBUG "${OPENCOLLADA_LIBRARIES}" "_d")
target_link_libraries_debug(${target} "${OPENCOLLADA_LIBRARIES_DEBUG}")
target_link_libraries_optimized(${target} "${OPENCOLLADA_LIBRARIES}")
unset(OPENCOLLADA_LIBRARIES_DEBUG)
MESSAGE(STATUS "Detecting SSE support")
IF(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX)
SET(CMAKE_REQUIRED_FLAGS "-msse -msse2")
ELSEIF(MSVC)
SET(CMAKE_REQUIRED_FLAGS "/arch:SSE2") # TODO, SSE 1 ?
ENDIF()
file_list_suffix(PCRE_LIB_DEBUG "${PCRE_LIB}" "_d")
target_link_libraries_debug(${target} "${PCRE_LIB_DEBUG}")
target_link_libraries_optimized(${target} "${PCRE_LIB}")
unset(PCRE_LIB_DEBUG)
CHECK_C_SOURCE_RUNS("
#include <xmmintrin.h>
int main() { __m128 v = _mm_setzero_ps(); return 0; }"
SUPPORT_SSE_BUILD)
if(EXPAT_LIB)
file_list_suffix(EXPAT_LIB_DEBUG "${EXPAT_LIB}" "_d")
target_link_libraries_debug(${target} "${EXPAT_LIB_DEBUG}")
target_link_libraries_optimized(${target} "${EXPAT_LIB}")
unset(EXPAT_LIB_DEBUG)
endif()
else()
target_link_libraries(${target}
${OPENCOLLADA_LIBRARIES}
${PCRE_LIB}
${EXPAT_LIB})
endif()
endif()
if(WITH_MEM_JEMALLOC)
target_link_libraries(${target} ${JEMALLOC_LIBRARIES})
endif()
if(WITH_INPUT_NDOF)
target_link_libraries(${target} ${NDOF_LIBRARIES})
endif()
CHECK_C_SOURCE_RUNS("
#include <emmintrin.h>
int main() { __m128d v = _mm_setzero_pd(); return 0; }"
SUPPORT_SSE2_BUILD)
MESSAGE(STATUS "Detecting SSE support")
if(WIN32 AND NOT UNIX)
target_link_libraries(${target} ${PTHREADS_LIBRARIES})
endif()
endmacro()
IF(SUPPORT_SSE_BUILD)
MESSAGE(STATUS " ...SSE support found.")
ELSE(SUPPORT_SSE_BUILD)
MESSAGE(STATUS " ...SSE support missing.")
ENDIF(SUPPORT_SSE_BUILD)
macro(TEST_SSE_SUPPORT)
include(CheckCSourceRuns)
IF(SUPPORT_SSE2_BUILD)
MESSAGE(STATUS " ...SSE2 support found.")
ELSE(SUPPORT_SSE2_BUILD)
MESSAGE(STATUS " ...SSE2 support missing.")
ENDIF(SUPPORT_SSE2_BUILD)
# message(STATUS "Detecting SSE support")
if(CMAKE_COMPILER_IS_GNUCC OR CMAKE_COMPILER_IS_GNUCXX)
set(CMAKE_REQUIRED_FLAGS "-msse -msse2")
elseif(MSVC)
set(CMAKE_REQUIRED_FLAGS "/arch:SSE2") # TODO, SSE 1 ?
endif()
ENDMACRO(TEST_SSE_SUPPORT)
if(NOT DEFINED ${SUPPORT_SSE_BUILD})
check_c_source_runs("
#include <xmmintrin.h>
int main() { __m128 v = _mm_setzero_ps(); return 0; }"
SUPPORT_SSE_BUILD)
if(SUPPORT_SSE_BUILD)
message(STATUS "SSE Support: detected.")
else()
message(STATUS "SSE Support: missing.")
endif()
set(${SUPPORT_SSE_BUILD} ${SUPPORT_SSE_BUILD} CACHE INTERNAL "SSE Test")
endif()
if(NOT DEFINED ${SUPPORT_SSE2_BUILD})
check_c_source_runs("
#include <emmintrin.h>
int main() { __m128d v = _mm_setzero_pd(); return 0; }"
SUPPORT_SSE2_BUILD)
if(SUPPORT_SSE2_BUILD)
message(STATUS "SSE2 Support: detected.")
else()
message(STATUS "SSE2 Support: missing.")
endif()
set(${SUPPORT_SSE2_BUILD} ${SUPPORT_SSE2_BUILD} CACHE INTERNAL "SSE2 Test")
endif()
endmacro()
# when we have warnings as errors applied globally this
# needs to be removed for some external libs which we dont maintain.
# utility macro
MACRO(_REMOVE_STRICT_FLAGS
macro(remove_flag
flag)
STRING(REGEX REPLACE ${flag} "" CMAKE_C_FLAGS ${CMAKE_C_FLAGS})
STRING(REGEX REPLACE ${flag} "" CMAKE_C_FLAGS_DEBUG ${CMAKE_C_FLAGS_DEBUG})
STRING(REGEX REPLACE ${flag} "" CMAKE_C_FLAGS_RELEASE ${CMAKE_C_FLAGS_RELEASE})
STRING(REGEX REPLACE ${flag} "" CMAKE_C_FLAGS_MINSIZEREL ${CMAKE_C_FLAGS_MINSIZEREL})
STRING(REGEX REPLACE ${flag} "" CMAKE_C_FLAGS_RELWITHDEBINFO ${CMAKE_C_FLAGS_RELWITHDEBINFO})
STRING(REGEX REPLACE ${flag} "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
STRING(REGEX REPLACE ${flag} "" CMAKE_CXX_FLAGS_DEBUG ${CMAKE_CXX_FLAGS_DEBUG})
STRING(REGEX REPLACE ${flag} "" CMAKE_CXX_FLAGS_RELEASE ${CMAKE_CXX_FLAGS_RELEASE})
STRING(REGEX REPLACE ${flag} "" CMAKE_CXX_FLAGS_MINSIZEREL ${CMAKE_CXX_FLAGS_MINSIZEREL})
STRING(REGEX REPLACE ${flag} "" CMAKE_CXX_FLAGS_RELWITHDEBINFO ${CMAKE_CXX_FLAGS_RELWITHDEBINFO})
string(REGEX REPLACE ${flag} "" CMAKE_C_FLAGS "${CMAKE_C_FLAGS}")
string(REGEX REPLACE ${flag} "" CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG}")
string(REGEX REPLACE ${flag} "" CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE}")
string(REGEX REPLACE ${flag} "" CMAKE_C_FLAGS_MINSIZEREL "${CMAKE_C_FLAGS_MINSIZEREL}")
string(REGEX REPLACE ${flag} "" CMAKE_C_FLAGS_RELWITHDEBINFO "${CMAKE_C_FLAGS_RELWITHDEBINFO}")
ENDMACRO(_REMOVE_STRICT_FLAGS)
string(REGEX REPLACE ${flag} "" CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
string(REGEX REPLACE ${flag} "" CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG}")
string(REGEX REPLACE ${flag} "" CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE}")
string(REGEX REPLACE ${flag} "" CMAKE_CXX_FLAGS_MINSIZEREL "${CMAKE_CXX_FLAGS_MINSIZEREL}")
string(REGEX REPLACE ${flag} "" CMAKE_CXX_FLAGS_RELWITHDEBINFO "${CMAKE_CXX_FLAGS_RELWITHDEBINFO}")
MACRO(REMOVE_STRICT_FLAGS)
endmacro()
IF(CMAKE_COMPILER_IS_GNUCC)
_REMOVE_STRICT_FLAGS("-Wunused-parameter")
_REMOVE_STRICT_FLAGS("-Werror=[^ ]+")
_REMOVE_STRICT_FLAGS("-Werror")
ENDIF(CMAKE_COMPILER_IS_GNUCC)
macro(remove_strict_flags)
IF(MSVC)
if(CMAKE_COMPILER_IS_GNUCC)
remove_flag("-Wstrict-prototypes")
remove_flag("-Wunused-parameter")
remove_flag("-Wwrite-strings")
remove_flag("-Wundef")
remove_flag("-Wshadow")
remove_flag("-Werror=[^ ]+")
remove_flag("-Werror")
endif()
if(MSVC)
# TODO
ENDIF(MSVC)
endif()
ENDMACRO(REMOVE_STRICT_FLAGS)
endmacro()
macro(ADD_CHECK_C_COMPILER_FLAG
_CFLAGS
_CACHE_VAR
_FLAG)
include(CheckCCompilerFlag)
CHECK_C_COMPILER_FLAG("${_FLAG}" "${_CACHE_VAR}")
if(${_CACHE_VAR})
# message(STATUS "Using CFLAG: ${_FLAG}")
set(${_CFLAGS} "${${_CFLAGS}} ${_FLAG}")
else()
message(STATUS "Unsupported CFLAG: ${_FLAG}")
endif()
endmacro()
macro(ADD_CHECK_CXX_COMPILER_FLAG
_CXXFLAGS
_CACHE_VAR
_FLAG)
include(CheckCXXCompilerFlag)
CHECK_CXX_COMPILER_FLAG("${_FLAG}" "${_CACHE_VAR}")
if(${_CACHE_VAR})
# message(STATUS "Using CXXFLAG: ${_FLAG}")
set(${_CXXFLAGS} "${${_CXXFLAGS}} ${_FLAG}")
else()
message(STATUS "Unsupported CXXFLAG: ${_FLAG}")
endif()
endmacro()
macro(get_blender_version)
# So cmake depends on BKE_blender.h, beware of inf-loops!
CONFIGURE_FILE(${CMAKE_SOURCE_DIR}/source/blender/blenkernel/BKE_blender.h ${CMAKE_BINARY_DIR}/source/blender/blenkernel/BKE_blender.h.done)
file(STRINGS ${CMAKE_SOURCE_DIR}/source/blender/blenkernel/BKE_blender.h _contents REGEX "^#define[ \t]+BLENDER_.*$")
string(REGEX REPLACE ".*#define[ \t]+BLENDER_VERSION[ \t]+([0-9]+).*" "\\1" _out_version "${_contents}")
string(REGEX REPLACE ".*#define[ \t]+BLENDER_SUBVERSION[ \t]+([0-9]+).*" "\\1" _out_subversion "${_contents}")
string(REGEX REPLACE ".*#define[ \t]+BLENDER_VERSION_CHAR[ \t]+([a-z]+).*" "\\1" _out_version_char "${_contents}")
string(REGEX REPLACE ".*#define[ \t]+BLENDER_VERSION_CYCLE[ \t]+([a-z]+).*" "\\1" _out_version_cycle "${_contents}")
if(NOT ${_out_version} MATCHES "[0-9]+")
message(FATAL_ERROR "Version parsing failed for BLENDER_VERSION")
endif()
if(NOT ${_out_subversion} MATCHES "[0-9]+")
message(FATAL_ERROR "Version parsing failed for BLENDER_SUBVERSION")
endif()
# clumsy regex, only single char are ok but it could be unset
string(LENGTH "${_out_version_char}" _out_version_char_len)
if(NOT _out_version_char_len EQUAL 1)
set(_out_version_char "")
elseif(NOT ${_out_version_char} MATCHES "[a-z]+")
message(FATAL_ERROR "Version parsing failed for BLENDER_VERSION_CHAR")
endif()
if(NOT ${_out_version_cycle} MATCHES "[a-z]+")
message(FATAL_ERROR "Version parsing failed for BLENDER_VERSION_CYCLE")
endif()
math(EXPR BLENDER_VERSION_MAJOR "${_out_version} / 100")
math(EXPR BLENDER_VERSION_MINOR "${_out_version} % 100")
set(BLENDER_VERSION "${BLENDER_VERSION_MAJOR}.${BLENDER_VERSION_MINOR}")
set(BLENDER_SUBVERSION ${_out_subversion})
set(BLENDER_VERSION_CHAR ${_out_version_char})
set(BLENDER_VERSION_CYCLE ${_out_version_cycle})
# for packaging, alpha to numbers
string(COMPARE EQUAL "${BLENDER_VERSION_CHAR}" "" _out_version_char_empty)
if(${_out_version_char_empty})
set(BLENDER_VERSION_CHAR_INDEX "0")
else()
set(_char_ls a b c d e f g h i j k l m n o p q r s t u v w q y z)
list(FIND _char_ls ${BLENDER_VERSION_CHAR} _out_version_char_index)
math(EXPR BLENDER_VERSION_CHAR_INDEX "${_out_version_char_index} + 1")
unset(_char_ls)
unset(_out_version_char_index)
endif()
unset(_out_subversion)
unset(_out_version_char)
unset(_out_version_char_empty)
unset(_out_version_cycle)
# message(STATUS "Version (Internal): ${BLENDER_VERSION}.${BLENDER_SUBVERSION}, Version (external): ${BLENDER_VERSION}${BLENDER_VERSION_CHAR}-${BLENDER_VERSION_CYCLE}")
endmacro()
MACRO(GET_BLENDER_VERSION)
FILE(READ ${CMAKE_SOURCE_DIR}/source/blender/blenkernel/BKE_blender.h CONTENT)
STRING(REGEX REPLACE "\n" ";" CONTENT "${CONTENT}")
STRING(REGEX REPLACE "\t" ";" CONTENT "${CONTENT}")
STRING(REGEX REPLACE " " ";" CONTENT "${CONTENT}")
# hacks to override initial project settings
# these macros must be called directly before/after project(Blender)
macro(blender_project_hack_pre)
# ----------------
# MINGW HACK START
# ignore system set flag, use our own
# must be before project(...)
# if the user wants to add their own its ok after first run.
if(DEFINED CMAKE_C_STANDARD_LIBRARIES)
set(_reset_standard_libraries OFF)
else()
set(_reset_standard_libraries ON)
endif()
FOREACH(ITEM ${CONTENT})
IF(LASTITEM MATCHES "BLENDER_VERSION")
MATH(EXPR BLENDER_VERSION_MAJOR "${ITEM} / 100")
MATH(EXPR BLENDER_VERSION_MINOR "${ITEM} % 100")
SET(BLENDER_VERSION "${BLENDER_VERSION_MAJOR}.${BLENDER_VERSION_MINOR}")
ENDIF(LASTITEM MATCHES "BLENDER_VERSION")
IF(LASTITEM MATCHES "BLENDER_SUBVERSION")
SET(BLENDER_SUBVERSION ${ITEM})
ENDIF(LASTITEM MATCHES "BLENDER_SUBVERSION")
IF(LASTITEM MATCHES "BLENDER_MINVERSION")
MATH(EXPR BLENDER_MINVERSION_MAJOR "${ITEM} / 100")
MATH(EXPR BLENDER_MINVERSION_MINOR "${ITEM} % 100")
SET(BLENDER_MINVERSION "${BLENDER_MINVERSION_MAJOR}.${BLENDER_MINVERSION_MINOR}")
ENDIF(LASTITEM MATCHES "BLENDER_MINVERSION")
IF(LASTITEM MATCHES "BLENDER_MINSUBVERSION")
SET(BLENDER_MINSUBVERSION ${ITEM})
ENDIF(LASTITEM MATCHES "BLENDER_MINSUBVERSION")
# ------------------
# GCC -O3 HACK START
# needed because O3 can cause problems but
# allow the builder to set O3 manually after.
if(DEFINED CMAKE_C_FLAGS_RELEASE)
set(_reset_standard_cflags_rel OFF)
else()
set(_reset_standard_cflags_rel ON)
endif()
if(DEFINED CMAKE_CXX_FLAGS_RELEASE)
set(_reset_standard_cxxflags_rel OFF)
else()
set(_reset_standard_cxxflags_rel ON)
endif()
endmacro()
SET(LASTITEM ${ITEM})
ENDFOREACH(ITEM ${CONTENT})
MESSAGE(STATUS "Version major: ${BLENDER_VERSION_MAJOR}, Version minor: ${BLENDER_VERSION_MINOR}, Subversion: ${BLENDER_SUBVERSION}, Version: ${BLENDER_VERSION}")
MESSAGE(STATUS "Minversion major: ${BLENDER_MINVERSION_MAJOR}, Minversion minor: ${BLENDER_MINVERSION_MINOR}, MinSubversion: ${BLENDER_MINSUBVERSION}, Minversion: ${BLENDER_MINVERSION}")
ENDMACRO(GET_BLENDER_VERSION)
macro(blender_project_hack_post)
# --------------
# MINGW HACK END
if (_reset_standard_libraries)
# Must come after project(...)
#
# MINGW workaround for -ladvapi32 being included which surprisingly causes
# string formatting of floats, eg: printf("%.*f", 3, value). to crash blender
# with a meaningless stack trace. by overriding this flag we ensure we only
# have libs we define and that cmake & scons builds match.
set(CMAKE_C_STANDARD_LIBRARIES "" CACHE STRING "" FORCE)
set(CMAKE_CXX_STANDARD_LIBRARIES "" CACHE STRING "" FORCE)
mark_as_advanced(CMAKE_C_STANDARD_LIBRARIES)
mark_as_advanced(CMAKE_CXX_STANDARD_LIBRARIES)
endif()
unset(_reset_standard_libraries)
# ----------------
# GCC -O3 HACK END
if(_reset_standard_cflags_rel)
string(REGEX REPLACE "-O3" "-O2" CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE}")
set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE}" CACHE STRING "" FORCE)
mark_as_advanced(CMAKE_C_FLAGS_RELEASE)
endif()
if(_reset_standard_cxxflags_rel)
string(REGEX REPLACE "-O3" "-O2" CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE}")
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE}" CACHE STRING "" FORCE)
mark_as_advanced(CMAKE_CXX_FLAGS_RELEASE)
endif()
unset(_reset_standard_cflags_rel)
unset(_reset_standard_cxxflags_rel)
# ------------------------------------------------------------------
# workaround for omission in cmake 2.8.4's GNU.cmake, fixed in 2.8.5
if(CMAKE_COMPILER_IS_GNUCC)
if(NOT DARWIN)
set(CMAKE_INCLUDE_SYSTEM_FLAG_C "-isystem ")
endif()
endif()
endmacro()

View File

@@ -0,0 +1,88 @@
set(PROJECT_DESCRIPTION "Blender is a very fast and versatile 3D modeller/renderer.")
set(PROJECT_COPYRIGHT "Copyright (C) 2001-2011 Blender Foundation")
set(PROJECT_CONTACT "foundation@blender.org")
set(PROJECT_VENDOR "Blender Foundation")
set(ORG_WEBSITE "www.blender.org")
set(MAJOR_VERSION ${BLENDER_VERSION_MAJOR})
set(MINOR_VERSION ${BLENDER_VERSION_MINOR})
set(PATCH_VERSION ${BLENDER_VERSION_CHAR_INDEX})
set(CPACK_SYSTEM_NAME ${CMAKE_SYSTEM_NAME})
set(CPACK_PACKAGE_DESCRIPTION ${PROJECT_DESCRIPTION})
set(CPACK_PACKAGE_VENDOR ${PROJECT_VENDOR})
set(CPACK_PACKAGE_CONTACT ${PROJECT_CONTACT})
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/COPYING")
set(CPACK_PACKAGE_INSTALL_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}")
SET(CPACK_PACKAGE_VERSION_MAJOR "${MAJOR_VERSION}")
SET(CPACK_PACKAGE_VERSION_MINOR "${MINOR_VERSION}")
SET(CPACK_PACKAGE_VERSION_PATCH "${PATCH_VERSION}")
# Get the build revision, note that this can get out-of-sync, so for packaging run cmake first.
include(FindSubversion)
set(MY_WC_REVISION "unknown")
if(EXISTS ${CMAKE_SOURCE_DIR}/.svn/)
if(Subversion_FOUND)
Subversion_WC_INFO(${CMAKE_SOURCE_DIR} MY)
endif()
endif()
set(BUILD_REV ${MY_WC_REVISION})
# Force Package Name
set(CPACK_PACKAGE_FILE_NAME ${PROJECT_NAME}-${BLENDER_VERSION}-r${BUILD_REV}-${CMAKE_SYSTEM_PROCESSOR})
if(CMAKE_SYSTEM_NAME MATCHES "Linux")
# RPM packages
include(build_files/cmake/RpmBuild.cmake)
if(RPMBUILD_FOUND AND NOT WIN32)
set(CPACK_GENERATOR "RPM")
set(CPACK_RPM_PACKAGE_RELEASE "1.r${BUILD_REV}")
set(CPACK_SET_DESTDIR "true")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "${PROJECT_DESCRIPTION}")
set(CPACK_PACKAGE_RELOCATABLE "false")
set(CPACK_RPM_PACKAGE_LICENSE "GPLv2")
set(CPACK_RPM_PACKAGE_GROUP "Amusements/Multimedia")
set(CPACK_RPM_USER_BINARY_SPECFILE "${CMAKE_SOURCE_DIR}/build_files/package_spec/rpm/blender.spec.in")
endif()
endif()
# Mac Bundle
if(APPLE)
set(CPACK_GENERATOR "DragNDrop")
# Libraries are bundled directly
set(CPACK_COMPONENT_LIBRARIES_HIDDEN TRUE)
endif()
set(CPACK_PACKAGE_EXECUTABLES "blender")
include(CPack)
# Target for build_archive.py script, to automatically pass along
# version, revision, platform, build directory
macro(add_package_archive packagename extension)
set(build_archive python ${CMAKE_SOURCE_DIR}/build_files/package_spec/build_archive.py)
set(package_output ${CMAKE_BINARY_DIR}/release/${packagename}.${extension})
add_custom_target(package_archive DEPENDS ${package_output})
add_custom_command(
OUTPUT ${package_output}
COMMAND ${build_archive} ${packagename} ${extension} bin release
WORKING_DIRECTORY ${CMAKE_BINARY_DIR})
endmacro()
if(APPLE)
add_package_archive(
"${PROJECT_NAME}-${BLENDER_VERSION}-r${BUILD_REV}-OSX-${CMAKE_OSX_ARCHITECTURES}"
"zip")
elseif(UNIX)
# platform name could be tweaked, to include glibc, and ensure processor is correct (i386 vs i686)
string(TOLOWER ${CMAKE_SYSTEM_NAME} PACKAGE_SYSTEM_NAME)
add_package_archive(
"${PROJECT_NAME}-${BLENDER_VERSION}-r${BUILD_REV}-${PACKAGE_SYSTEM_NAME}-${CMAKE_SYSTEM_PROCESSOR}"
"tar.bz2")
endif()

218
build_files/cmake/project_info.py Executable file
View File

@@ -0,0 +1,218 @@
#!/usr/bin/env python
# $Id$
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# Contributor(s): Campbell Barton, M.G. Kishalmi
#
# ***** END GPL LICENSE BLOCK *****
# <pep8 compliant>
"""
Example Win32 usage:
c:\Python32\python.exe c:\blender_dev\blender\build_files\cmake\cmake_qtcreator_project.py c:\blender_dev\cmake_build
example linux usage
python .~/blenderSVN/blender/build_files/cmake/cmake_qtcreator_project.py ~/blenderSVN/cmake
"""
__all__ = (
"SIMPLE_PROJECTFILE",
"SOURCE_DIR",
"CMAKE_DIR",
"PROJECT_DIR",
"source_list",
"is_project_file",
"is_c_header",
"is_py",
"cmake_advanced_info",
"cmake_compiler_defines",
)
import sys
import os
from os.path import join, dirname, normpath, abspath, splitext, exists
SOURCE_DIR = join(dirname(__file__), "..", "..")
SOURCE_DIR = normpath(SOURCE_DIR)
SOURCE_DIR = abspath(SOURCE_DIR)
SIMPLE_PROJECTFILE = False
# get cmake path
CMAKE_DIR = sys.argv[-1]
if not exists(join(CMAKE_DIR, "CMakeCache.txt")):
CMAKE_DIR = os.getcwd()
if not exists(join(CMAKE_DIR, "CMakeCache.txt")):
print("CMakeCache.txt not found in %r or %r\n Pass CMake build dir as an argument, or run from that dir, aborting" % (CMAKE_DIR, os.getcwd()))
sys.exit(1)
# could be either.
# PROJECT_DIR = SOURCE_DIR
PROJECT_DIR = CMAKE_DIR
def source_list(path, filename_check=None):
for dirpath, dirnames, filenames in os.walk(path):
# skip '.svn'
if dirpath.startswith("."):
continue
for filename in filenames:
filepath = join(dirpath, filename)
if filename_check is None or filename_check(filepath):
yield filepath
# extension checking
def is_cmake(filename):
ext = splitext(filename)[1]
return (ext == ".cmake") or (filename.endswith("CMakeLists.txt"))
def is_c_header(filename):
ext = splitext(filename)[1]
return (ext in (".h", ".hpp", ".hxx"))
def is_py(filename):
ext = splitext(filename)[1]
return (ext == ".py")
def is_glsl(filename):
ext = splitext(filename)[1]
return (ext == ".glsl")
def is_c(filename):
ext = splitext(filename)[1]
return (ext in (".c", ".cpp", ".cxx", ".m", ".mm", ".rc"))
def is_c_any(filename):
return is_c(filename) or is_c_header(filename)
def is_svn_file(filename):
dn, fn = os.path.split(filename)
filename_svn = join(dn, ".svn", "text-base", "%s.svn-base" % fn)
return exists(filename_svn)
def is_project_file(filename):
return (is_c_any(filename) or is_cmake(filename) or is_glsl(filename)) # and is_svn_file(filename)
def cmake_advanced_info():
""" Extracr includes and defines from cmake.
"""
def create_eclipse_project(CMAKE_DIR):
print("CMAKE_DIR %r" % CMAKE_DIR)
if sys.platform == "win32":
cmd = 'cmake "%s" -G"Eclipse CDT4 - MinGW Makefiles"' % CMAKE_DIR
else:
cmd = 'cmake "%s" -G"Eclipse CDT4 - Unix Makefiles"' % CMAKE_DIR
os.system(cmd)
includes = []
defines = []
create_eclipse_project(CMAKE_DIR)
from xml.dom.minidom import parse
tree = parse(join(CMAKE_DIR, ".cproject"))
'''
f = open(".cproject_pretty", 'w')
f.write(tree.toprettyxml(indent=" ", newl=""))
'''
ELEMENT_NODE = tree.ELEMENT_NODE
cproject, = tree.getElementsByTagName("cproject")
for storage in cproject.childNodes:
if storage.nodeType != ELEMENT_NODE:
continue
if storage.attributes["moduleId"].value == "org.eclipse.cdt.core.settings":
cconfig = storage.getElementsByTagName("cconfiguration")[0]
for substorage in cconfig.childNodes:
if substorage.nodeType != ELEMENT_NODE:
continue
moduleId = substorage.attributes["moduleId"].value
# org.eclipse.cdt.core.settings
# org.eclipse.cdt.core.language.mapping
# org.eclipse.cdt.core.externalSettings
# org.eclipse.cdt.core.pathentry
# org.eclipse.cdt.make.core.buildtargets
if moduleId == "org.eclipse.cdt.core.pathentry":
for path in substorage.childNodes:
if path.nodeType != ELEMENT_NODE:
continue
kind = path.attributes["kind"].value
if kind == "mac":
# <pathentry kind="mac" name="PREFIX" path="" value="&quot;/opt/blender25&quot;"/>
defines.append((path.attributes["name"].value, path.attributes["value"].value))
elif kind == "inc":
# <pathentry include="/data/src/blender/blender/source/blender/editors/include" kind="inc" path="" system="true"/>
includes.append(path.attributes["include"].value)
else:
pass
return includes, defines
def cmake_cache_var(var):
cache_file = open(join(CMAKE_DIR, "CMakeCache.txt"))
lines = [l_strip for l in cache_file for l_strip in (l.strip(),) if l_strip if not l_strip.startswith("//") if not l_strip.startswith("#")]
cache_file.close()
for l in lines:
if l.split(":")[0] == var:
return l.split("=", 1)[-1]
return None
def cmake_compiler_defines():
compiler = cmake_cache_var("CMAKE_C_COMPILER") # could do CXX too
if compiler is None:
print("Couldn't find the compiler, os defines will be omitted...")
return
import tempfile
temp_c = tempfile.mkstemp(suffix=".c")[1]
temp_def = tempfile.mkstemp(suffix=".def")[1]
os.system("%s -dM -E %s > %s" % (compiler, temp_c, temp_def))
temp_def_file = open(temp_def)
lines = [l.strip() for l in temp_def_file if l.strip()]
temp_def_file.close()
os.remove(temp_c)
os.remove(temp_def)
return lines

View File

@@ -1,38 +0,0 @@
#!/bin/sh
#
# This is an example script to build things with the Nan Makefiles
#
#
rm -f /tmp/.nanguess
export MAKE=make
export NANBLENDERHOME=`pwd`
export MAKEFLAGS="-w -I $NANBLENDERHOME/source --no-print-directory"
export HMAKE="$NANBLENDERHOME/source/tools/hmake/hmake"
export NAN_PYTHON=/soft/python-2.2.2b1/progeny1
export NAN_PYTHON_VERSION=2.2
export NAN_OPENAL=/usr/local
export NAN_JPEG=/usr/local
export NAN_PNG=/usr/local
export NAN_SDL=/usr/local
export NAN_ODE=/usr/local
export NAN_ZLIB=/usr/local
export NAN_FREETYPE=/usr/local
export NAN_MOZILLA_INC=/usr/local/include/mozilla-1.0.1/
export NAN_MOZILLA_LIB=/usr/local/lib/mozilla-1.0.1/
#export NAN_NSPR=/scratch/irulan/mein/nspr-4.2.2/mozilla/nsprpub/dist/
export CPPFLAGS="$CPPFLAGS"
export CFLAGS="$CFLAGS"
export INTERNATIONAL=true
$HMAKE -C intern/
if [ $? -eq 0 ]; then
$HMAKE -C source/
fi
$HMAKE -C release
#cd release
#make

View File

@@ -1,18 +0,0 @@
#!/bin/bash
rm -f /tmp/.nanguess
export MAKE=make
export NANBLENDERHOME=`pwd`
export MAKEFLAGS="-w -I $NANBLENDERHOME/source --no-print-directory"
export HMAKE="$NANBLENDERHOME/source/tools/hmake/hmake"
echo
echo NANBLENDERHOME : ${NANBLENDERHOME}
export NAN_PYTHON=/sw
$HMAKE -C intern/
if [ $? -eq 0 ]; then
$HMAKE -C source/
fi
cd release
make

View File

@@ -1,35 +0,0 @@
#!/bin/sh
# This is an example build script for SunOS5.8
rm -f /tmp/.nanguess
export MAKE=make
export NANBLENDERHOME=`pwd`
export MAKEFLAGS="-w -I $NANBLENDERHOME/source --no-print-directory"
export HMAKE="$NANBLENDERHOME/source/tools/hmake/hmake"
export NAN_PYTHON=/soft/python-2.2.2b1/SunOS5.8
export NAN_PYTHON_VERSION=2.2
export NAN_OPENAL=/usr/local
export NAN_JPEG=/usr/local
export NAN_PNG=/usr/local
export NAN_SDL=/usr/local
export NAN_ODE=/usr/local
export NAN_OPENSSL=/soft/ssl/openssl-0.9.6e
export NAN_ZLIB=/usr/local
export NAN_FREETYPE=/usr/local
export NAN_MOZILLA_INC=/usr/local/include/mozilla-1.0.1/
export NAN_MOZILLA_LIB=/usr/local/lib/mozilla-1.0.1/
export NAN_NSPR=/scratch/irulan/mein/nspr-4.2.2/mozilla/nsprpub/dist/
export CPPFLAGS="$CPPFLAGS"
export CFLAGS="$CFLAGS"
export INTERNATIONAL=true
$HMAKE -C intern/
if [ $? -eq 0 ]; then
$HMAKE -C source/
fi
$HMAKE -C release
#cd release
#make

View File

@@ -1,474 +0,0 @@
# -*- mode: gnumakefile; tab-width: 8; indent-tabs-mode: t; -*-
# vim: tabstop=8
#
# $Id$
#
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
# All rights reserved.
#
# The Original Code is: all of this file.
#
# Contributor(s): GSR, Stefan Gartner
#
# ***** END GPL LICENSE BLOCK *****
#
# Compile and archive
include nan_definitions.mk
CPPFLAGS ?= $(NAN_CPPFLAGS)
# common parts ---------------------------------------------------
# Uncomment next lines to enable integrated game engine
ifneq ($(NAN_NO_KETSJI), true)
CFLAGS += -DGAMEBLENDER=1
ifeq ($(NAN_USE_BULLET), true)
CFLAGS += -DUSE_BULLET
CCFLAGS += -DUSE_BULLET
endif
else
CPPFLAGS += -DNO_KETSJI
endif
ifeq ($(BF_PROFILE), true)
CFLAGS += -pg
CCFLAGS += -pg
endif
ifeq ($(WITH_BF_OPENMP), true)
CFLAGS += -fopenmp
CCFLAGS += -fopenmp
endif
ifdef NAN_DEBUG
CFLAGS += $(NAN_DEBUG)
CCFLAGS += $(NAN_DEBUG)
endif
REL_CFLAGS += -DNDEBUG
REL_CCFLAGS += -DNDEBUG
DBG_CFLAGS += -g
DBG_CCFLAGS += -g
# OS dependent parts ---------------------------------------------------
ifeq ($(OS),darwin)
CC ?= gcc
CCC ?= g++
ifeq ($(MACOSX_DEPLOYMENT_TARGET), 10.4)
CC = gcc-4.0
CCC = g++-4.0
else
ifeq ($(MACOSX_DEPLOYMENT_TARGET), 10.5)
CC = gcc-4.2
CCC = g++-4.2
endif
endif
ifeq ($(CPU),powerpc)
CFLAGS += -pipe -fPIC -mcpu=7450 -mtune=G5 -funsigned-char -fno-strict-aliasing
CCFLAGS += -pipe -fPIC -funsigned-char -fno-strict-aliasing
else
CFLAGS += -pipe -fPIC -funsigned-char
CCFLAGS += -pipe -fPIC -funsigned-char
endif
CFLAGS += -arch $(MACOSX_ARCHITECTURE) #-isysroot $(MACOSX_SDK) -mmacosx-version-min=$(MACOSX_MIN_VERS)
CCFLAGS += -arch $(MACOSX_ARCHITECTURE) #-isysroot $(MACOSX_SDK) -mmacosx-version-min=$(MACOSX_MIN_VERS)
ifeq ($(MACOSX_ARCHITECTURE), $(findstring $(MACOSX_ARCHITECTURE), "i386 x86_64"))
REL_CFLAGS += -O2 -ftree-vectorize -msse -msse2 -msse3
REL_CCFLAGS += -O2 -ftree-vectorize -msse -msse2 -msse3
else
REL_CFLAGS += -O2
REL_CCFLAGS += -O2
endif
CPPFLAGS += -D_THREAD_SAFE
ifeq ($(WITH_COCOA), true)
CPPFLAGS += -DGHOST_COCOA
endif
ifeq ($(USE_QTKIT), true)
CPPFLAGS += -DUSE_QTKIT
endif
NAN_DEPEND = true
OPENGL_HEADERS = /System/Library/Frameworks/OpenGL.framework
AR = ar
ARFLAGS = ruv
RANLIB = ranlib
ARFLAGSQUIET = ru
endif
ifeq ($(OS),freebsd)
CC ?= gcc
CCC ?= g++
JAVAC = javac
JAVAH = javah
CFLAGS += -pipe -fPIC -funsigned-char -fno-strict-aliasing
CCFLAGS += -pipe -fPIC -funsigned-char -fno-strict-aliasing
REL_CFLAGS += -O2
REL_CCFLAGS += -O2
CPPFLAGS += -D_THREAD_SAFE
NAN_DEPEND = true
OPENGL_HEADERS = /usr/X11R6/include
JAVA_HEADERS = /usr/local/jdk1.3.1/include
JAVA_SYSTEM_HEADERS = /usr/local/jdk1.3.1/include/freebsd
AR = ar
ARFLAGS = ruv
ARFLAGSQUIET = ru
endif
ifeq ($(OS),irix)
ifeq ($(IRIX_USE_GCC),true)
CC ?= gcc
CCC ?= g++
CFLAGS += -fPIC -funsigned-char -fno-strict-aliasing -mabi=n32 -mips4
CCFLAGS += -fPIC -fpermissive -funsigned-char -fno-strict-aliasing -mabi=n32 -mips4
REL_CFLAGS += -O2
REL_CCFLAGS += -O2
DBG_CFLAGS += -g3 -gdwarf-2 -ggdb
DBG_CCFLAGS += -g3 -gdwarf-2 -ggdb
else
CC ?= cc
CCC ?= CC
CFLAGS += -n32 -mips3 -Xcpluscomm
CCFLAGS += -n32 -mips3 -Xcpluscomm -LANG:std
ifdef MIPS73_ISOHEADERS
CCFLAGS += -LANG:libc_in_namespace_std=off -I$(MIPS73_ISOHEADERS)
else
CCFLAGS += -LANG:libc_in_namespace_std=off
endif
REL_CFLAGS += -n32 -mips3 -O2 -OPT:Olimit=0
REL_CCFLAGS += -n32 -mips3 -O2 -OPT:Olimit=0
endif
OPENGL_HEADERS = /usr/include
NAN_DEPEND = true
AR = CC
ARFLAGS = -ar -o
ARFLAGSQUIET = -ar -o
endif
ifeq ($(OS),linux)
CC ?= gcc
CCC ?= g++
# CFLAGS += -pipe
# CCFLAGS += -pipe
CFLAGS += -pipe -fPIC -funsigned-char -fno-strict-aliasing -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
CCFLAGS += -pipe -fPIC -funsigned-char -fno-strict-aliasing -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64
REL_CFLAGS += -O2
REL_CCFLAGS += -O2
NAN_DEPEND = true
ifeq ($(WITH_BF_RAYOPTIMIZATION), true)
CCFLAGS += -msse
endif
ifeq ($(CPU),alpha)
CFLAGS += -mieee
endif
OPENGL_HEADERS = /usr/X11R6/include
AR = ar
ARFLAGS = ruv
ARFLAGSQUIET = ru
endif
ifeq ($(OS),openbsd)
CC ?= gcc
CCC ?= g++
CFLAGS += -pipe -fPIC -funsigned-char -fno-strict-aliasing
CCFLAGS += -pipe -fPIC -funsigned-char -fno-strict-aliasing
REL_CFLAGS += -O2
REL_CCFLAGS += -O2
NAN_DEPEND = true
CPPFLAGS += -D__FreeBSD__
OPENGL_HEADERS = /usr/X11R6/include
AR = ar
ARFLAGS = ruv
ARFLAGSQUIET = ru
endif
ifeq ($(OS),solaris)
# Adding gcc flag to $CC is not good, however if its not there makesdna wont build - Campbell
ifeq (x86_64, $(findstring x86_64, $(CPU)))
CC ?= gcc -m64
CCC ?= g++ -m64
else
CC ?= gcc
CCC ?= g++
#CC ?= cc
#CCC ?= CC
endif
JAVAC = javac
JAVAH = javah
CFLAGS += -pipe -fPIC -funsigned-char -fno-strict-aliasing
CCFLAGS += -pipe -fPIC -funsigned-char -fno-strict-aliasing
# CFLAGS += "-fast -xdepend -xarch=v8plus -xO3 -xlibmil -KPIC -DPIC -xchar=unsigned"
# CCFLAGS += "-fast -xdepend -xarch=v8plus -xO3 -xlibmil -xlibmopt -features=tmplife -norunpath -KPIC -DPIC -xchar=unsigned"
# Note, you might still want to compile a 32 bit binary if you have a 64bit system. if so remove the following lines
# ifeq ($(findstring 64,$(CPU)), 64)
# CFLAGS += -m64
# CCFLAGS += -m64
# endif
REL_CFLAGS += -O2
REL_CCFLAGS += -O2
NAN_DEPEND = true
# ifeq ($(CPU),sparc)
ifeq ($(findstring sparc,$(CPU)), sparc)
OPENGL_HEADERS = /usr/openwin/share/include
CPPFLAGS += -DSUN_OGL_NO_VERTEX_MACROS
JAVA_HEADERS = /usr/java/include
JAVA_SYSTEM_HEADERS = /usr/java/include/solaris
else
# OPENGL_HEADERS = /usr/X11/include/mesa
OPENGL_HEADERS = /usr/X11/include/
endif
AR = ar
ARFLAGS = ruv
ARFLAGSQUIET = ru
endif
ifeq ($(OS),windows)
ifeq ($(FREE_WINDOWS),true)
CC ?= gcc
CCC ?= g++
CFLAGS += -pipe -mno-cygwin -mwindows -funsigned-char -fno-strict-aliasing
CCFLAGS += -pipe -mno-cygwin -mwindows -funsigned-char -fno-strict-aliasing
CPPFLAGS += -DFREE_WINDOWS
REL_CFLAGS += -O2
REL_CCFLAGS += -O2
NAN_DEPEND = true
#OPENGL_HEADERS = /usr/include/w32api
OPENGL_HEADERS = ./
AR = ar
ARFLAGS = ruv
ARFLAGSQUIET = ru
WINRC = $(wildcard *.rc)
RANLIB = ranlib
else
CC ?= $(SRCHOME)/tools/cygwin/cl_wrapper.pl
CCC ?= $(SRCHOME)/tools/cygwin/cl_wrapper.pl
JAVAC = $(SRCHOME)/tools/cygwin/java_wrapper.pl -c
JAVAH = $(SRCHOME)/tools/cygwin/java_wrapper.pl -h
REL_CFLAGS += /O2
REL_CCFLAGS += /O2 -GX
DBG_CFLAGS += /Fd$(DIR)/debug/
DBG_CCFLAGS += /Fd$(DIR)/debug/
CFLAGS += /MT
CCFLAGS += /MT
NAN_DEPEND = true
OPENGL_HEADERS = .
CPPFLAGS += -DWIN32 -D_WIN32 -D__WIN32
CPPFLAGS += -D_M_IX86
CPPFLAGS += -I"/cygdrive/c/Program Files/Microsoft Visual Studio/VC98/include"
JAVA_HEADERS = /cygdrive/c/j2sdk1.4.0-beta3/include
JAVA_SYSTEM_HEADERS = /cygdrive/c/j2sdk1.4.0-beta3/include/win32
CPP = $(SRCHOME)/tools/cygwin/cl_wrapper.pl
AR = ar
ARFLAGS = ruv
ARFLAGSQUIET = ru
WINRC = $(wildcard *.rc)
endif
endif
ifeq (debug, $(findstring debug, $(MAKECMDGOALS)))
export DEBUG_DIR=debug/
endif
ifneq (x$(DEBUG_DIR), x)
CFLAGS +=$(DBG_CFLAGS)
CCFLAGS+=$(DBG_CCFLAGS)
else
CFLAGS +=$(REL_CFLAGS)
CCFLAGS+=$(REL_CCFLAGS)
endif
# Note: include nan_warn's LEVEL_*_WARNINGS after CC/OS have been set.
include nan_warn.mk
# compile rules
default: all
$(DIR)/$(DEBUG_DIR)%.o: %.c
ifdef NAN_DEPEND
@set -e; $(CC) -M $(CPPFLAGS) $< 2>/dev/null \
| sed 's@\($*\)\.o[ :]*@$(DIR)/$(DEBUG_DIR)\1.o : @g' \
> $(DIR)/$(DEBUG_DIR)$*.d; \
[ -s $(DIR)/$(DEBUG_DIR)$*.d ] || $(RM) $(DIR)/$(DEBUG_DIR)$*.d
endif
ifdef NAN_QUIET
@echo " -- $< -- "
@$(CC) -c $(CFLAGS) $(CPPFLAGS) $< -o $@
else
$(CC) -c $(CFLAGS) $(CPPFLAGS) $< -o $@
endif
$(DIR)/$(DEBUG_DIR)%.o: %.cpp
ifdef NAN_DEPEND
@set -e; $(CCC) -M $(CPPFLAGS) $< 2>/dev/null \
| sed 's@\($*\)\.o[ :]*@$(DIR)/$(DEBUG_DIR)\1.o : @g' \
> $(DIR)/$(DEBUG_DIR)$*.d; \
[ -s $(DIR)/$(DEBUG_DIR)$*.d ] || $(RM) $(DIR)/$(DEBUG_DIR)$*.d
endif
ifdef NAN_QUIET
@echo " -- $< -- "
@$(CCC) -c $(CCFLAGS) $(CPPFLAGS) $< -o $@
else
$(CCC) -c $(CCFLAGS) $(CPPFLAGS) $< -o $@
endif
$(DIR)/$(DEBUG_DIR)%.o: %.mm
ifdef NAN_DEPEND
@set -e; $(CC) -M $(CPPFLAGS) $< 2>/dev/null \
| sed 's@\($*\)\.o[ :]*@$(DIR)/$(DEBUG_DIR)\1.o : @g' \
> $(DIR)/$(DEBUG_DIR)$*.d; \
[ -s $(DIR)/$(DEBUG_DIR)$*.d ] || $(RM) $(DIR)/$(DEBUG_DIR)$*.d
endif
ifdef NAN_QUIET
@echo " -- $< -- "
@$(CC) -c $(CFLAGS) $(CPPFLAGS) $< -o $@
else
$(CC) -c $(CFLAGS) $(CPPFLAGS) $< -o $@
endif
$(DIR)/$(DEBUG_DIR)%.o: %.m
ifdef NAN_DEPEND
@set -e; $(CC) -M $(CPPFLAGS) $< 2>/dev/null \
| sed 's@\($*\)\.o[ :]*@$(DIR)/$(DEBUG_DIR)\1.o : @g' \
> $(DIR)/$(DEBUG_DIR)$*.d; \
[ -s $(DIR)/$(DEBUG_DIR)$*.d ] || $(RM) $(DIR)/$(DEBUG_DIR)$*.d
endif
ifdef NAN_QUIET
@echo " -- $< -- "
@$(CC) -c $(CFLAGS) $(CPPFLAGS) $< -o $@
else
$(CC) -c $(CFLAGS) $(CPPFLAGS) $< -o $@
endif
$(DIR)/$(DEBUG_DIR)%.res: %.rc
ifeq ($(FREE_WINDOWS),true)
windres $< -O coff -o $@
else
$(SRCHOME)/tools/cygwin/cl_wrapper.pl - rc /fo$@ $<
endif
$(DIR)/$(DEBUG_DIR)%.class: %.java
ifdef JARS
$(JAVAC) -verbose -g -deprecation -sourcepath . -classpath "$(JARS)" -d $(DIR)/$(DEBUG_DIR) $<
else
$(JAVAC) -verbose -g -deprecation -d $(DIR)/$(DEBUG_DIR) $<
endif
$(DIR)/$(DEBUG_DIR)%.h: $(DIR)/$(DEBUG_DIR)%.class
$(JAVAH) -classpath $(DIR)/$(DEBUG_DIR) -d $(DIR)/$(DEBUG_DIR) -jni $*
%.h:
@echo "WARNING: Fake header creation rule used, dependencies will be remade"
CSRCS ?= $(wildcard *.c)
CCSRCS ?= $(wildcard *.cpp)
JSRCS ?= $(wildcard *.java)
ifdef NAN_DEPEND
-include $(CSRCS:%.c=$(DIR)/$(DEBUG_DIR)%.d) $(CCSRCS:%.cpp=$(DIR)/$(DEBUG_DIR)%.d) $(OCCSRCS:$.mm=$(DIR)/$(DEBUG_DIR)%.d) $(OCSRCS:$.m=$(DIR)/$(DEBUG_DIR)%.d)
endif
OBJS_AR := $(OBJS)
OBJS_AR += $(CSRCS:%.c=%.o)
OBJS_AR += $(CCSRCS:%.cpp=%.o)
OBJS_AR += $(OCCSRCS:%.mm=%.o)
OBJS_AR += $(OCSRCS:%.m=%.o)
OBJS_AR += $(WINRC:%.rc=%.res)
OBJS += $(CSRCS:%.c=$(DIR)/$(DEBUG_DIR)%.o)
OBJS += $(CCSRCS:%.cpp=$(DIR)/$(DEBUG_DIR)%.o)
OBJS += $(OCCSRCS:%.mm=$(DIR)/$(DEBUG_DIR)%.o)
OBJS += $(OCSRCS:%.m=$(DIR)/$(DEBUG_DIR)%.o)
OBJS += $(WINRC:%.rc=$(DIR)/$(DEBUG_DIR)%.res)
JCLASS += $(JSRCS:%.java=$(DIR)/$(DEBUG_DIR)%.class)
LIB_a = $(DIR)/$(DEBUG_DIR)lib$(LIBNAME).a
$(LIB_a): $(OBJS)
# $OBJS can be empty except for some spaces
ifneq (x, x$(strip $(OBJS)))
ifdef NAN_PARANOID
@$(RM) $(LIB_a)
ifdef NAN_QUIET
@echo " -- lib: lib$(LIBNAME).a -- "
@cd $(DIR)/$(DEBUG_DIR); $(AR) $(ARFLAGSQUIET) $@ $(OBJS_AR)
else
cd $(DIR)/$(DEBUG_DIR); $(AR) $(ARFLAGS) $@ $(OBJS_AR)
endif
else
ifdef NAN_QUIET
@echo " -- lib: lib$(LIBNAME).a -- "
@$(AR) $(ARFLAGSQUIET) $@ $?
else
$(AR) $(ARFLAGS) $@ $?
endif
endif
ifdef RANLIB
$(RANLIB) $@
endif
endif
ALLTARGETS ?= $(LIB_a)
all debug :: makedir $(ALLTARGETS)
lib: $(LIB_a)
creator: $(OBJS)
@echo "====> make creator subtarget in `pwd | sed 's/^.*develop\///'`"
@$(MAKE) makedir DIR=$(DIR)/$(DEBUG_DIR)cre
@$(MAKE) lib CSRCS="$(CRE_CSRCS)" LIBNAME=$(LIBNAME)$@
publisher: $(OBJS)
@echo "====> make publisher subtarget in `pwd | sed 's/^.*develop\///'`"
@$(MAKE) makedir DIR=$(DIR)/$(DEBUG_DIR)pub
@$(MAKE) lib CSRCS="$(PUB_CSRCS)" LIBNAME=$(LIBNAME)$@
player: $(OBJS)
@echo "====> make player subtarget in `pwd | sed 's/^.*develop\///'`"
@$(MAKE) makedir DIR=$(DIR)/player/$(DEBUG_DIR)
@$(MAKE) lib CSRCS="$(SAP_CSRCS)" LIBNAME=$(LIBNAME)$@
clean:: optclean debugclean
optclean::
@-[ ! -d $(DIR) ] || ( cd $(DIR) && \
$(RM) *.o *.a *.d *.res ii_files/*.ii *.class *.h )
debugclean::
@-[ ! -d $(DIR)/debug ] || ( cd $(DIR)/debug && \
$(RM) *.o *.a *.d *.res ii_files/*.ii *.class *.h )
.PHONY: makedir
makedir::
@# don't use mkdir -p. Cygwin will try to make network paths and fail
@[ -d $(DIR) ] || mkdir $(DIR)
@[ -d $(DIR)/debug ] || mkdir $(DIR)/debug

View File

@@ -1,646 +0,0 @@
# -*- mode: gnumakefile; tab-width: 8; indent-tabs-mode: t; -*-
# vim: tabstop=8
#
# $Id$
#
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
# All rights reserved.
#
# The Original Code is: all of this file.
#
# Contributor(s): GSR, Stefan Gartner
#
# ***** END GPL LICENSE BLOCK *****
#
# set some defaults when these are not overruled (?=) by environment variables
#
sinclude ../../user-def.mk
# This warning only takes place once in source/
ifeq (debug, $(findstring debug, $(MAKECMDGOALS)))
ifeq (all, $(findstring all, $(MAKECMDGOALS)))
export ERRTXT = "ERROR: all and debug targets cannot be used together anymore"
export ERRTXT += "Use something like ..make all && make debug.. instead"
endif
endif
ifdef ERRTXT
$(error $(ERRTXT))
endif
ifndef CONFIG_GUESS
ifeq (debug, $(findstring debug, $(MAKECMDGOALS)))
export DEBUG_DIR = debug/
export ALL_OR_DEBUG = debug
endif
ifeq (all, $(findstring all, $(MAKECMDGOALS)))
export ALL_OR_DEBUG ?= all
endif
# First generic defaults for all platforms which should be constant.
# Note: ?= lets these defaults be overruled by environment variables,
export SRCHOME ?= $(NANBLENDERHOME)/source
export CONFIG_GUESS := $(shell ${SRCHOME}/tools/guess/guessconfig)
export OS := $(shell echo ${CONFIG_GUESS} | sed -e 's/-.*//')
export OS_VERSION := $(shell echo ${CONFIG_GUESS} | sed -e 's/^[^-]*-//' -e 's/-[^-]*//')
export CPU := $(shell echo ${CONFIG_GUESS} | sed -e 's/^[^-]*-[^-]*-//')
export MAKE_START := $(shell date "+%H:%M:%S %d-%b-%Y")
export NAN_LIBDIR ?= $(NANBLENDERHOME)/../lib
export NAN_OBJDIR ?= $(NANBLENDERHOME)/obj
# Library Config_Guess DIRectory
export LCGDIR = $(NAN_LIBDIR)/$(CONFIG_GUESS)
# Object Config_Guess DIRectory
export OCGDIR = $(NAN_OBJDIR)/$(CONFIG_GUESS)
# Determines what targets are built
export WITH_BF_DYNAMICOPENGL ?= true
export WITH_BF_STATICOPENGL ?= false
export WITH_BF_BLENDERGAMEENGINE ?= true
export WITH_BF_BLENDERPLAYER ?= true
ifeq ($(NAN_NO_PLUGIN), true)
export WITH_BF_WEBPLUGIN = false
else
export WITH_BF_WEBPLUGIN ?= false
endif
export NAN_MOTO ?= $(LCGDIR)/moto
export NAN_ITASC ?= $(LCGDIR)/itasc
export BF_PROFILE ?= false
export NAN_USE_BULLET ?= true
export NAN_BULLET2 ?= $(LCGDIR)/bullet2
export NAN_DECIMATION ?= $(LCGDIR)/decimation
export NAN_GUARDEDALLOC ?= $(LCGDIR)/guardedalloc
export NAN_IKSOLVER ?= $(LCGDIR)/iksolver
export NAN_BSP ?= $(LCGDIR)/bsp
export NAN_BOOLOP ?= $(LCGDIR)/boolop
export NAN_AUDASPACE ?= $(LCGDIR)/audaspace
export NAN_STRING ?= $(LCGDIR)/string
export NAN_MEMUTIL ?= $(LCGDIR)/memutil
export NAN_CONTAINER ?= $(LCGDIR)/container
export NAN_ACTION ?= $(LCGDIR)/action
export NAN_GHOST ?= $(LCGDIR)/ghost
export NAN_TEST_VERBOSITY ?= 1
export NAN_OPENNL ?= $(LCGDIR)/opennl
export NAN_ELBEEM ?= $(LCGDIR)/elbeem
export NAN_SMOKE ?= $(LCGDIR)/smoke
export NAN_SUPERLU ?= $(LCGDIR)/superlu
export NAN_GLEW ?= $(LCGDIR)/glew
ifeq ($(FREE_WINDOWS), true)
export NAN_FFMPEG ?= $(LCGDIR)/gcc/ffmpeg
export NAN_FFMPEGLIBS ?= $(NAN_FFMPEG)/lib/libavformat.a $(NAN_FFMPEG)/lib/libavutil.a $(NAN_FFMPEG)/lib/libavcodec.a $(NAN_FFMPEG)/lib/libavdevice.a
else
export NAN_FFMPEG ?= $(LCGDIR)/ffmpeg
ifeq ($(OS), darwin)
export NAN_FFMPEGLIBS ?= $(NAN_FFMPEG)/lib/libavformat.a $(NAN_FFMPEG)/lib/libavcodec.a $(NAN_FFMPEG)/lib/libswscale.a $(NAN_FFMPEG)/lib/libavutil.a $(NAN_FFMPEG)/lib/libavdevice.a $(NAN_FFMPEG)/lib/libmp3lame.a $(NAN_FFMPEG)/lib/libx264.a $(NAN_FFMPEG)/lib/libxvidcore.a $(NAN_FFMPEG)/lib/libtheora.a $(NAN_FFMPEG)/lib/libtheoradec.a $(NAN_FFMPEG)/lib/libtheoraenc.a $(NAN_FFMPEG)/lib/libvorbis.a $(NAN_FFMPEG)/lib/libvorbisenc.a $(NAN_FFMPEG)/lib/libvorbisfile.a $(NAN_FFMPEG)/lib/libogg.a -lbz2
else
export NAN_FFMPEGLIBS ?= $(NAN_FFMPEG)/lib/libavformat.a $(NAN_FFMPEG)/lib/libavcodec.a $(NAN_FFMPEG)/lib/libswscale.a $(NAN_FFMPEG)/lib/libavutil.a $(NAN_FFMPEG)/lib/libavdevice.a
endif
endif
export NAN_FFMPEGCFLAGS ?= -I$(NAN_FFMPEG)/include -I$(NANBLENDERHOME)/extern/ffmpeg
export WITH_OPENEXR ?= true
export WITH_DDS ?= true
export WITH_OPENJPEG ?= true
export WITH_LZO ?= true
export WITH_LZMA ?= true
export NAN_LZO ?= $(LCGDIR)/lzo
export NAN_LZMA ?= $(LCGDIR)/lzma
export WITH_OPENAL ?= false
export WITH_JACK ?= false
export WITH_SNDFILE ?= false
export WITH_FFTW3 ?= false
ifeq ($(WITH_OPENAL), true)
export NAN_OPENAL ?= /usr
endif
ifeq ($(WITH_JACK), true)
export NAN_JACK ?= $(LCGDIR)/jack
export NAN_JACKCFLAGS ?= -I$(NAN_JACK)/include/jack
export NAN_JACKLIBS ?= $(NAN_JACK)/lib/libjack.a
endif
ifeq ($(WITH_SNDFILE),true)
export NAN_SNDFILE ?= $(LCGDIR)/sndfile
export NAN_SNDFILECFLAGS ?= -I$(NAN_SNDFILE)/include
export NAN_SNDFILELIBS ?= $(NAN_SNDFILE)/lib/libsndfile.a $(NAN_SNDFILE)/lib/libFLAC.a $(NAN_SNDFILE)/lib/libogg.a
endif
ifeq ($(NAN_USE_FFMPEG_CONFIG), true)
export NAN_FFMPEG = $(shell pkg-config --variable=prefix libavcodec) # Assume they are all in the same prefix
export NAN_FFMPEGLIBS = $(shell pkg-config --libs libavcodec libavdevice libavformat libswscale libavutil)
export NAN_FFMPEGCFLAGS = $(shell pkg-config --cflags libavcodec libavdevice libavformat libswscale libavutil)
endif
ifeq ($(WITH_OPENCOLLADA), true)
export BF_OPENCOLLADA ?= $(LCGDIR)/opencollada
export BF_OPENCOLLADA_INC ?= $(BF_OPENCOLLADA)/include
export BF_OPENCOLLADA_LIBS ?= $(BF_OPENCOLLADA)/lib/libOpenCOLLADASaxFrameworkLoader.a $(BF_OPENCOLLADA)/lib/libOpenCOLLADAFramework.a $(BF_OPENCOLLADA)/lib/libOpenCOLLADABaseUtils.a $(BF_OPENCOLLADA)/lib/libOpenCOLLADAStreamWriter.a $(BF_OPENCOLLADA)/lib/libMathMLSolver.a $(BF_OPENCOLLADA)/lib/libGeneratedSaxParser.a $(BF_OPENCOLLADA)/lib/libUTF.a -lxml2
export BF_PCRE ?= $(LCGDIR)/pcre
export BF_PCRE_LIBS ?= $(BF_PCRE)/lib/libpcre.a
endif
export WITH_TIFF ?= true
#enable raytracing optimization (currently only for i386 and x86_64)
ifeq ($(CPU),powerpc)
export WITH_BF_RAYOPTIMIZATION ?= false
else
export WITH_BF_RAYOPTIMIZATION ?= true
endif
export WITH_LCMS ?= false
export WITH_CINEON ?= true
export WITH_HDR ?= true
# Compare recreated .mo files with committed ones
export BF_VERIFY_MO_FILES ?= true
# Platform Dependent settings go below:
ifeq ($(OS),darwin)
export ID = $(shell whoami)
export HOST = $(shell hostname -s)
# set target arch & os version
# architecture defaults to host arch, can be ppc, ppc64, i386, x86_64
ifeq ($(CPU),powerpc)
export MACOSX_ARCHITECTURE ?= ppc
else
export MACOSX_ARCHITECTURE ?= i386
endif
# target os version defaults to 10.4 for ppc & i386 (32 bit), 10.5 for ppc64, x86_64
ifeq (64,$(findstring 64, $(MACOSX_ARCHITECTURE)))
export MACOSX_MIN_VERS ?= 10.5
export MACOSX_DEPLOYMENT_TARGET ?= 10.5
export MACOSX_SDK ?= /Developer/SDKs/MacOSX10.5.sdk
else
export MACOSX_MIN_VERS ?= 10.4
export MACOSX_DEPLOYMENT_TARGET ?= 10.4
export MACOSX_SDK ?= /Developer/SDKs/MacOSX10.4u.sdk
endif
# useful for crosscompiling
ifeq ($(MACOSX_ARCHITECTURE),$(findstring $(MACOSX_ARCHITECTURE), "ppc ppc64"))
export CPU = powerpc
export LCGDIR = $(NAN_LIBDIR)/$(OS)-$(OS_VERSION)-$(CPU)
export OCGDIR = $(NAN_OBJDIR)/$(OS)-$(OS_VERSION)-$(CPU)
endif
ifeq ($(MACOSX_ARCHITECTURE),$(findstring $(MACOSX_ARCHITECTURE),"i386 x86_64"))
export CPU = i386
export LCGDIR = $(NAN_LIBDIR)/$(OS)-$(OS_VERSION)-$(CPU)
export OCGDIR = $(NAN_OBJDIR)/$(OS)-$(OS_VERSION)-$(CPU)
endif
export NAN_PYTHON_VERSION = 3.1
ifeq ($(NAN_PYTHON_VERSION),3.1)
export PY_FRAMEWORK ?= 0
export NAN_PYTHON ?= $(LCGDIR)/python
export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python$(NAN_PYTHON_VERSION)/libpython$(NAN_PYTHON_VERSION).a
else
export PY_FRAMEWORK ?= 1
ifdef PY_FRAMEWORK
export NAN_PYTHON_VERSION ?= 3.1
export NAN_PYTHON ?= /System/Library/Frameworks/Python.framework/Versions/$(NAN_PYTHON_VERSION)
export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
export NAN_PYTHON_LIB ?= -framework Python
else
export NAN_PYTHON ?= /sw
export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python$(NAN_PYTHON_VERSION)/config/libpython$(NAN_PYTHON_VERSION).a
endif
endif
export NAN_OPENAL ?= $(LCGDIR)/openal
export NAN_JPEG ?= $(LCGDIR)/jpeg
export NAN_PNG ?= $(LCGDIR)/png
export NAN_TIFF ?= $(LCGDIR)/tiff
export NAN_TERRAPLAY ?= $(LCGDIR)/terraplay
export NAN_MESA ?= /usr/src/Mesa-3.1
export NAN_ZLIB ?= $(LCGDIR)/zlib
export NAN_NSPR ?= $(LCGDIR)/nspr
export NAN_FREETYPE ?= $(LCGDIR)/freetype
export NAN_GETTEXT ?= $(LCGDIR)/gettext
export NAN_GETTEXT_LIB ?= $(NAN_GETTEXT)/lib/libintl.a
ifeq (($CPU), i386)
export NAN_GETTEXT_LIB += $(NAN_GETTEXT)/lib/libintl.a
endif
export NAN_SDL ?= $(LCGDIR)/sdl
export NAN_SDLCFLAGS ?= -I$(NAN_SDL)/include
export NAN_SDLLIBS ?= $(NAN_SDL)/lib/libSDL.a -framework Cocoa -framework IOKit
export NAN_OPENEXR ?= $(LCGDIR)/openexr
export NAN_OPENEXR_INC ?= -I$(NAN_OPENEXR)/include -I$(NAN_OPENEXR)/include/OpenEXR
export NAN_OPENEXR_LIBS ?= $(NAN_OPENEXR)/lib/libIlmImf.a $(NAN_OPENEXR)/lib/libHalf.a $(NAN_OPENEXR)/lib/libIex.a $(NAN_OPENEXR)/lib/libIlmThread.a
export NAN_NO_KETSJI=false
#ifeq ($(CPU), i386)
# export WITH_OPENAL=false
#endif
# Location of MOZILLA/Netscape header files...
export NAN_MOZILLA_INC ?= $(LCGDIR)/mozilla/include
export NAN_MOZILLA_LIB ?= $(LCGDIR)/mozilla/lib/
# Will fall back to look in NAN_MOZILLA_INC/nspr and NAN_MOZILLA_LIB
# if this is not set.
export NAN_BUILDINFO ?= true
# Be paranoid regarding library creation (do not update archives)
export NAN_PARANOID ?= true
# enable quicktime by default on OS X
export WITH_QUICKTIME ?= true
# enable l10n
export INTERNATIONAL ?= true
export NAN_SAMPLERATE ?= $(LCGDIR)/samplerate
export NAN_SAMPLERATE_LIBS ?= $(NAN_SAMPLERATE)/lib/libsamplerate.a
# enable building with Cocoa
export WITH_COCOA ?= false
export USE_QTKIT ?= false
# use cocoa and qtkit for 64bit builds
ifeq (64, $(findstring 64, $(MACOSX_ARCHITECTURE)))
export WITH_COCOA = true
export USE_QTKIT = true
endif
export BF_PCRE = $(LCGDIR)/opencollada
export BF_OPENCOLLADA_LIBS = $(BF_OPENCOLLADA)/lib/libOpenCOLLADASaxFrameworkLoader.a $(BF_OPENCOLLADA)/lib/libOpenCOLLADAFramework.a $(BF_OPENCOLLADA)/lib/libOpenCOLLADABaseUtils.a $(BF_OPENCOLLADA)/lib/libOpenCOLLADAStreamWriter.a $(BF_OPENCOLLADA)/lib/libMathMLSolver.a $(BF_OPENCOLLADA)/lib/libGeneratedSaxParser.a $(BF_OPENCOLLADA)/lib/libUTF.a $(BF_OPENCOLLADA)/lib/libftoa.a $(BF_OPENCOLLADA)/lib/libbuffer.a -lxml2
else
ifeq ($(OS),freebsd)
export ID = $(shell whoami)
export HOST = $(shell hostname -s)
export FREEDESKTOP ?= true
export NAN_PYTHON ?= /usr/local
export NAN_PYTHON_VERSION ?= 3.1
export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python$(NAN_PYTHON_VERSION)/config/libpython$(NAN_PYTHON_VERSION).a
export NAN_OPENAL ?= /usr/local
export NAN_JPEG ?= /usr/local
export NAN_PNG ?= /usr/local
export NAN_TIFF ?= /usr/local
export NAN_TERRAPLAY ?= $(LCGDIR)/terraplay
export NAN_MESA ?= /usr/src/Mesa-3.1
export NAN_ZLIB ?= /usr
export NAN_NSPR ?= /usr/local
export NAN_FREETYPE ?= $(LCGDIR)/freetype
export NAN_GETTEXT ?= $(LCGDIR)/gettext
export NAN_SDL ?= $(shell sdl-config --prefix)
export NAN_SDLLIBS ?= $(shell sdl-config --libs)
export NAN_SDLCFLAGS ?= $(shell sdl-config --cflags)
# Location of MOZILLA/Netscape header files...
export NAN_MOZILLA_INC ?= $(LCGDIR)/mozilla/include
export NAN_MOZILLA_LIB ?= $(LCGDIR)/mozilla/lib/
# Will fall back to look in NAN_MOZILLA_INC/nspr and NAN_MOZILLA_LIB
# if this is not set.
export NAN_BUILDINFO ?= true
# Be paranoid regarding library creation (do not update archives)
export NAN_PARANOID ?= true
# enable l10n
# export INTERNATIONAL ?= true
else
ifeq ($(OS),irix)
export ID = $(shell whoami)
export HOST = $(shell /usr/bsd/hostname -s)
#export NAN_NO_KETSJI=true
export NAN_JUST_BLENDERDYNAMIC=true
export NAN_PYTHON_VERSION ?= 3.1
ifeq ($(IRIX_USE_GCC), true)
export NAN_PYTHON ?= $(LCGDIR)/python_gcc
else
export NAN_PYTHON ?= $(LCGDIR)/python
endif
export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python$(NAN_PYTHON_VERSION)/config/libpython$(NAN_PYTHON_VERSION).a -lpthread
export NAN_OPENAL ?= $(LCGDIR)/openal
export NAN_JPEG ?= $(LCGDIR)/jpeg
export NAN_PNG ?= $(LCGDIR)/png
export NAN_TIFF ?= $(LCGDIR)/tiff
export NAN_TERRAPLAY ?= $(LCGDIR)/terraplay
export NAN_MESA ?= /usr/src/Mesa-3.1
export NAN_ZLIB ?= $(LCGDIR)/zlib
export NAN_NSPR ?= $(LCGDIR)/nspr
export NAN_FREETYPE ?= $(LCGDIR)/freetype
export NAN_ICONV ?= $(LCGDIR)/iconv
export NAN_GETTEXT ?= $(LCGDIR)/gettext
export NAN_GETTEXT_LIB ?= $(NAN_GETTEXT)/lib/libintl.a $(NAN_ICONV)/lib/libiconv.a
export NAN_SDL ?= $(LCGDIR)/sdl
export NAN_SDLLIBS ?= $(NAN_SDL)/lib/libSDL.a
export NAN_SDLCFLAGS ?= -I$(NAN_SDL)/include/SDL
export NAN_FFMPEG ?= $(LCGDIR)/ffmpeg
export NAN_FFMPEGLIBS = $(NAN_FFMPEG)/lib/libavformat.a $(NAN_FFMPEG)/lib/libavcodec.a $(NAN_FFMPEG)/lib/libswscale.a $(NAN_FFMPEG)/lib/libavutil.a $(NAN_FFMPEG)/lib/libavdevice.a $(NAN_FFMPEG)/lib/libogg.a $(NAN_FFMPEG)/lib/libfaad.a $(NAN_FFMPEG)/lib/libmp3lame.a $(NAN_FFMPEG)/lib/libvorbis.a $(NAN_FFMPEG)/lib/libx264.a $(NAN_FFMPEG)/lib/libfaac.a $(NAN_ZLIB)/lib/libz.a
export NAN_FFMPEGCFLAGS ?= -I$(NAN_FFMPEG)/include -I$(NANBLENDERHOME)/extern/ffmpeg
ifeq ($(IRIX_USE_GCC), true)
export NAN_OPENEXR ?= $(LCGDIR)/openexr/gcc
else
export NAN_OPENEXR ?= $(LCGDIR)/openexr
endif
export NAN_OPENEXR_INC ?= -I$(NAN_OPENEXR)/include -I$(NAN_OPENEXR)/include/OpenEXR
export NAN_OPENEXR_LIBS ?= $(NAN_OPENEXR)/lib/libIlmImf.a $(NAN_OPENEXR)/lib/libHalf.a $(NAN_OPENEXR)/lib/libIex.a $(NAN_OPENEXR)/lib/libIlmThread.a
# Location of MOZILLA/Netscape header files...
export NAN_MOZILLA_INC ?= $(LCGDIR)/mozilla/include
export NAN_MOZILLA_LIB ?= $(LCGDIR)/mozilla/lib/
# Will fall back to look in NAN_MOZILLA_INC/nspr and NAN_MOZILLA_LIB
# if this is not set.
export NAN_BUILDINFO ?= true
# Be paranoid regarding library creation (do not update archives)
export NAN_PARANOID ?= true
# enable l10n
export INTERNATIONAL ?= true
# Different endianess will make it fail, rely on other platforms for checks
export BF_VERIFY_MO_FILES = false
else
ifeq ($(OS),linux)
export ID = $(shell whoami)
export HOST = $(shell hostname -s)
export FREEDESKTOP ?= true
export NAN_PYTHON ?= /usr
export NAN_PYTHON_VERSION ?= 3.1
export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
# Next line if for static python, nan_link.mk uses -lpython$(NAN_PYTHON_VERSION)
#export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python$(NAN_PYTHON_VERSION)/config/libpython$(NAN_PYTHON_VERSION).a
export NAN_OPENAL ?= /usr
export NAN_JPEG ?= /usr
export NAN_PNG ?= /usr
export NAN_TIFF ?= /usr
export NAN_TERRAPLAY ?= $(LCGDIR)/terraplay
export NAN_MESA ?= /usr
export NAN_ZLIB ?= /usr
export NAN_NSPR ?= $(LCGDIR)/nspr
export NAN_FREETYPE ?= /usr
export NAN_GETTEXT ?= /usr
export NAN_SDL ?= $(shell sdl-config --prefix)
export NAN_SDLLIBS ?= $(shell sdl-config --libs)
export NAN_SDLCFLAGS ?= $(shell sdl-config --cflags)
export NAN_SAMPLERATE ?= /usr
ifeq ($(WITH_OPENEXR), true)
export NAN_OPENEXR ?= $(shell pkg-config --variable=prefix OpenEXR )
export NAN_OPENEXR_INC ?= $(shell pkg-config --cflags OpenEXR )
export NAN_OPENEXR_LIBS ?= $(addprefix ${NAN_OPENEXR}/lib/lib,$(addsuffix .a,$(shell pkg-config --libs-only-l OpenEXR | sed -s "s/-l//g" )))
endif
ifeq ($(WITH_FFTW3), true)
export BF_FFTW3 ?= $(shell pkg-config --variable=prefix fftw3 )
export BF_FFTW3_INC ?= $(shell pkg-config --variable=includedir fftw3 )
export BF_FFTW3_LIBS ?= $(shell pkg-config --libs fftw3 )
endif
# Uncomment the following line to use Mozilla inplace of netscape
# Location of MOZILLA/Netscape header files...
export NAN_MOZILLA_INC ?= /usr/include/mozilla
export NAN_MOZILLA_LIB ?= $(LCGDIR)/mozilla/lib/
# Will fall back to look in NAN_MOZILLA_INC/nspr and NAN_MOZILLA_LIB
# if this is not set.
export NAN_BUILDINFO ?= true
# Be paranoid regarding library creation (do not update archives)
export NAN_PARANOID ?= true
# l10n
export INTERNATIONAL ?= true
export WITH_BINRELOC ?= true
# enable ffmpeg support
ifndef NAN_NO_FFMPEG
export WITH_FFMPEG ?= true
endif
ifeq ($(CPU), powerpc)
# Different endianess will make it fail, rely on other platforms for checks
export BF_VERIFY_MO_FILES = false
endif
else
ifeq ($(OS),openbsd)
export ID = $(shell whoami)
export HOST = $(shell hostname -s)
export FREEDESKTOP ?= true
export NAN_PYTHON ?= $(LCGDIR)/python
export NAN_PYTHON_VERSION ?= 3.1
export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python$(NAN_PYTHON_VERSION)/config/libpython$(NAN_PYTHON_VERSION).a
export NAN_OPENAL ?= $(LCGDIR)/openal
export NAN_JPEG ?= $(LCGDIR)/jpeg
export NAN_PNG ?= $(LCGDIR)/png
export NAN_TIFF ?= $(LCGDIR)/tiff
export NAN_TERRAPLAY ?= $(LCGDIR)/terraplay
export NAN_MESA ?= /usr/src/Mesa-3.1
export NAN_ZLIB ?= $(LCGDIR)/zlib
export NAN_NSPR ?= $(LCGDIR)/nspr
export NAN_FREETYPE ?= $(LCGDIR)/freetype
export NAN_GETTEXT ?= $(LCGDIR)/gettext
export NAN_SDL ?= $(shell sdl-config --prefix)
export NAN_SDLLIBS ?= $(shell sdl-config --libs)
export NAN_SDLCFLAGS ?= $(shell sdl-config --cflags)
# Location of MOZILLA/Netscape header files...
export NAN_MOZILLA_INC ?= $(LCGDIR)/mozilla/include
export NAN_MOZILLA_LIB ?= $(LCGDIR)/mozilla/lib/
# Will fall back to look in NAN_MOZILLA_INC/nspr and NAN_MOZILLA_LIB
# if this is not set.
export NAN_BUILDINFO ?= true
# Be paranoid regarding library creation (do not update archives)
export NAN_PARANOID ?= true
# l10n
#export INTERNATIONAL ?= true
else
ifeq ($(OS),solaris)
export ID = $(shell /usr/ucb/whoami)
export HOST = $(shell hostname)
export NAN_PYTHON ?= $(LCGDIR)/python
export NAN_PYTHON_VERSION ?= 3.1
export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python$(NAN_PYTHON_VERSION)/config/libpython$(NAN_PYTHON_VERSION).a
export NAN_OPENAL ?= $(LCGDIR)/openal
export NAN_JPEG ?= $(LCGDIR)/jpeg
export NAN_PNG ?= $(LCGDIR)/png
export NAN_TIFF ?= /usr
export NAN_TERRAPLAY ?=
export NAN_MESA ?= /usr/X11
export NAN_ZLIB ?= $(LCGDIR)/zlib
export NAN_NSPR ?= $(LCGDIR)/nspr
export NAN_FREETYPE ?= $(LCGDIR)/freetype
export NAN_GETTEXT ?= $(LCGDIR)/gettext
export NAN_GETTEXT_LIB ?= $(NAN_GETTEXT)/lib/libintl.a $(NAN_GETTEXT)/lib/libiconv.a
export NAN_SDL ?= $(LCGDIR)/sdl
export NAN_SDLCFLAGS ?= -I$(NAN_SDL)/include/SDL
export NAN_SDLLIBS ?= $(NAN_SDL)/lib/libSDL.a
# this only exists at the moment for i386-64 CPU Types at the moment
export NAN_OPENEXR ?= $(LCGDIR)/openexr
export NAN_OPENEXR_INC ?= -I$(NAN_OPENEXR)/include -I$(NAN_OPENEXR)/include/OpenEXR
export NAN_OPENEXR_LIBS ?= $(NAN_OPENEXR)/lib/libIlmImf.a $(NAN_OPENEXR)/lib/libHalf.a $(NAN_OPENEXR)/lib/libIex.a $(NAN_OPENEXR)/lib/libIlmThread.a -lrt
# Location of MOZILLA/Netscape header files...
export NAN_MOZILLA_INC ?= $(LCGDIR)/mozilla/include
export NAN_MOZILLA_LIB ?= $(LCGDIR)/mozilla/lib/
# Will fall back to look in NAN_MOZILLA_INC/nspr and NAN_MOZILLA_LIB
# if this is not set.
export NAN_BUILDINFO ?= true
# Be paranoid regarding library creation (do not update archives)
export NAN_PARANOID ?= true
# l10n
#export INTERNATIONAL ?= true
else
ifeq ($(OS),windows)
export ID = $(LOGNAME)
export NAN_PYTHON ?= $(LCGDIR)/python
export NAN_ICONV ?= $(LCGDIR)/iconv
export NAN_PYTHON_VERSION ?= 3.1
export NAN_OPENAL ?= $(LCGDIR)/openal
export NAN_JPEG ?= $(LCGDIR)/jpeg
export NAN_PNG ?= $(LCGDIR)/png
export NAN_TIFF ?= $(LCGDIR)/tiff
export NAN_TERRAPLAY ?= $(LCGDIR)/terraplay
export NAN_MESA ?= /usr/src/Mesa-3.1
export NAN_ZLIB ?= $(LCGDIR)/zlib
export NAN_NSPR ?= $(LCGDIR)/nspr
export NAN_GETTEXT ?= $(LCGDIR)/gettext
ifeq ($(FREE_WINDOWS), true)
export NAN_GETTEXT_LIB ?= $(NAN_GETTEXT)/lib/freegettext.a $(NAN_ICONV)/lib/freeiconv.a
export NAN_PYTHON_BINARY ?= $(NAN_PYTHON)/bin/python$(NAN_PYTHON_VERSION)
export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/lib25_vs2005/libpython31.a # NOT TESTED, PROBABLY BROKEN
export NAN_FREETYPE ?= $(LCGDIR)/gcc/freetype
export NAN_SDL ?= $(LCGDIR)/gcc/sdl
export NAN_OPENEXR ?= $(LCGDIR)/gcc/openexr
export NAN_OPENEXR_INC ?= -I$(NAN_OPENEXR)/include -I$(NAN_OPENEXR)/include/OpenEXR
export NAN_OPENEXR_LIBS ?= $(NAN_OPENEXR)/lib/libIlmImf.a $(NAN_OPENEXR)/lib/libHalf.a $(NAN_OPENEXR)/lib/libIex.a
export NAN_PTHREADS ?= $(LCGDIR)/pthreads
else
export NAN_GETTEXT_LIB ?= $(NAN_GETTEXT)/lib/gnu_gettext.lib $(NAN_ICONV)/lib/iconv.lib
export NAN_PYTHON_BINARY ?= python
export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python31.lib # NOT TESTED, PROBABLY BROKEN
export NAN_FREETYPE ?= $(LCGDIR)/freetype
export NAN_SDL ?= $(LCGDIR)/sdl
export NAN_OPENEXR ?= $(LCGDIR)/openexr
export NAN_OPENEXR_INC ?= -I$(NAN_OPENEXR)/include -I$(NAN_OPENEXR)/include/IlmImf -I$(NAN_OPENEXR)/include/Imath -I$(NAN_OPENEXR)/include/Iex
export NAN_OPENEXR_LIBS ?= $(NAN_OPENEXR)/lib/IlmImf.lib $(NAN_OPENEXR)/lib/Half.lib $(NAN_OPENEXR)/lib/Iex.lib
endif
export NAN_SDLCFLAGS ?= -I$(NAN_SDL)/include
export NAN_WINTAB ?= $(LCGDIR)/wintab
# Location of MOZILLA/Netscape header files...
export NAN_MOZILLA_INC ?= $(LCGDIR)/mozilla/include
export NAN_MOZILLA_LIB ?= $(LCGDIR)/mozilla/lib/
# Will fall back to look in NAN_MOZILLA_INC/nspr and NAN_MOZILLA_LIB
# if this is not set.
export NAN_PYTHON_BINARY ?= python
export NAN_BUILDINFO ?= true
# Be paranoid regarding library creation (do not update archives)
export NAN_PARANOID ?= true
# l10n
export INTERNATIONAL ?= true
# enable quicktime support
# export WITH_QUICKTIME ?= true
else # Platform not listed above
export NAN_PYTHON ?= $(LCGDIR)/python
export NAN_PYTHON_VERSION ?= 3.1
export NAN_PYTHON_BINARY ?= python
export NAN_PYTHON_LIB ?= $(NAN_PYTHON)/lib/python$(NAN_PYTHON_VERSION)/config/libpython$(NAN_PYTHON_VERSION).a
export NAN_OPENAL ?= $(LCGDIR)/openal
export NAN_JPEG ?= $(LCGDIR)/jpeg
export NAN_PNG ?= $(LCGDIR)/png
export NAN_TIFF ?= $(LCGDIR)/tiff
export NAN_SDL ?= $(LCGDIR)/sdl
export NAN_TERRAPLAY ?= $(LCGDIR)/terraplay
export NAN_MESA ?= /usr/src/Mesa-3.1
export NAN_ZLIB ?= $(LCGDIR)/zlib
export NAN_NSPR ?= $(LCGDIR)/nspr
export NAN_FREETYPE ?= $(LCGDIR)/freetype
export NAN_GETTEXT ?= $(LCGDIR)/gettext
export NAN_SDL ?= $(shell sdl-config --prefix)
export NAN_SDLLIBS ?= $(shell sdl-config --libs)
export NAN_SDLCFLAGS ?= $(shell sdl-config --cflags)
# Location of MOZILLA/Netscape header files...
export NAN_MOZILLA_INC ?= $(LCGDIR)/mozilla/include
export NAN_MOZILLA_LIB ?= $(LCGDIR)/mozilla/lib/
# Will fall back to look in NAN_MOZILLA_INC/nspr and NAN_MOZILLA_LIB
# if this is not set.
export NAN_BUILDINFO ?= true
# Be paranoid regarding library creation (do not update archives)
export NAN_PARANOID ?= true
# l10n
#export INTERNATIONAL ?= true
endif # windows + fallback
endif # solaris
endif # openbsd
endif # linux
endif # irix
endif # freebsd
endif # darwin
# default tiff libs
export NAN_TIFF_LIBS ?= $(NAN_TIFF)/lib/libtiff.a
# default path to lcms, may be overidden in platform sections above or in user-def.mk
export BF_LCMS ?= $(LCGDIR)/lcms
export BF_LCMS_INC ?= $(BF_LCMS)/include
export BF_LCMS_LIBS ?= $(BF_LCMS)/lib/liblcms.a
endif # CONFIG_GUESS
# Don't want to build the gameengine?
ifeq ($(NAN_NO_KETSJI), true)
export NAN_JUST_BLENDERDYNAMIC=true
endif

View File

@@ -1,202 +0,0 @@
# -*- mode: gnumakefile; tab-width: 8; indent-tabs-mode: t; -*-
# vim: tabstop=8
#
# $Id$
#
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
# All rights reserved.
#
# The Original Code is: all of this file.
#
# Contributor(s): GSR
#
# ***** END GPL LICENSE BLOCK *****
#
# linking only
include nan_definitions.mk
ifdef NAN_DEBUG
LDFLAGS += $(NAN_DEBUG)
endif
DBG_LDFLAGS += -g
ifneq (x$(DEBUG_DIR), x)
LDFLAGS+=$(DBG_LDFLAGS)
else
LDFLAGS+=$(REL_LDFLAGS)
endif
######################## OS dependencies (alphabetic!) ################
# default (overriden by windows)
SOEXT = .so
ifeq ($(OS),darwin)
LLIBS += -lGLU -lGL
LLIBS += -lz -lstdc++
ifdef USE_OSX10.4STUBS
LLIBS +=-lSystemStubs
endif
ifeq ($(WITH_COCOA), true)
LLIBS += -framework Cocoa
endif
LLIBS += -framework Carbon -framework AGL -framework OpenGL
ifeq ($(WITH_QUICKTIME), true)
ifeq ($(USE_QTKIT), true)
LLIBS += -framework QTKit
else
LLIBS += -framework QuickTime
endif
endif
LLIBS += -framework CoreAudio
LLIBS += -framework AudioUnit -framework AudioToolbox
LDFLAGS += -L/System/Library/Frameworks/OpenGL.framework/Libraries
# useful for crosscompiling
LDFLAGS += -arch $(MACOSX_ARCHITECTURE) #-isysroot $(MACOSX_SDK) -mmacosx-version-min=$(MACOSX_MIN_VERS)
DBG_LDFLAGS += -L/System/Library/Frameworks/OpenGL.framework/Libraries
endif
ifeq ($(OS),freebsd)
LLIBS = -L/usr/X11R6/lib -lX11 -lXmu -lXi -lm -lutil -lz -pthread -lc_r
DADD = -lGL -lGLU
DYNLDFLAGS = -shared $(LDFLAGS)
LOPTS = -Wl,--export-dynamic
endif
ifeq ($(OS),irix)
ifeq ($(IRIX_USE_GCC), true)
LDFLAGS += -mabi=n32 -mips4
DBG_LDFLAGS += -LD_LAYOUT:lgot_buffer=40
else
LDFLAGS += -n32 -mips3
LDFLAGS += -woff 84,171
endif
LLIBS = -lmovieGL -lGLU -lGL -lXmu -lXext -lXi -lX11 -lc -lm -ldmedia
LLIBS += -lcl -laudio
ifneq ($(IRIX_USE_GCC), true)
LLIBS += -lCio -ldb
endif
LLIBS += -lz -lpthread
DYNLDFLAGS = -shared $(LDFLAGS)
endif
ifeq ($(OS),linux)
ifeq ($(CPU),alpha)
COMMENT = "MESA 3.1"
LLIBS = -lGL -lGLU -L/usr/X11R6/lib/ -lXmu -lXext -lX11
LLIBS += -lc -lm -ldl -lutil
LOPTS = -export-dynamic
endif
ifeq ($(CPU),$(findstring $(CPU), "i386 x86_64 ia64 parisc64 powerpc sparc64"))
COMMENT = "MESA 3.1"
LLIBS = -L$(NAN_MESA)/lib -L/usr/X11R6/lib -lXext -lX11 -lXi
LLIBS += -lutil -lc -lm -ldl -lpthread
LLIBS += -L$(NAN_PYTHON)/lib -Wl,-rpath -Wl,$(NAN_PYTHON)/lib -lpython$(NAN_PYTHON_VERSION)
LOPTS = -export-dynamic
DADD = -lGL -lGLU
SADD = $(NAN_MESA)/lib/libGL.a $(NAN_MESA)/lib/libGLU.a
DYNLDFLAGS = -shared $(LDFLAGS)
endif
LLIBS += -lz
endif
ifeq ($(OS),openbsd)
SADD = /usr/local/lib/libGL.a /usr/local/lib/libGLU.a
SADD += /usr/X11R6/lib/libXmu.a /usr/X11R6/lib/libXext.a
SADD += /usr/X11R6/lib/libX11.a /usr/lib/libm.a -pthread
endif
ifeq ($(OS),solaris)
ifeq (x86_64, $(findstring x86_64, $(CPU)))
LLIBS = -lrt
LLIBS += -L$(NAN_MESA)/lib/amd64
else
LLIBS += -L$(NAN_MESA)/lib
endif
LLIBS += $(NAN_ZLIB)/lib/libz.a -lGLU -lGL -lXmu -lXext -lXi -lX11 -lc -lm -ldl -lsocket -lnsl
DYNLDFLAGS = -shared $(LDFLAGS)
endif
ifeq ($(OS),windows)
EXT = .exe
SOEXT = .dll
ifeq ($(FREE_WINDOWS),true)
MINGWLIB = /usr/lib/w32api
LDFLAGS += -mwindows -mno-cygwin -mconsole
DADD += -L/usr/lib/w32api -lnetapi32 -lopengl32 -lglu32 -lshfolder
DADD += -L/usr/lib/w32api -lwinmm -lwsock32
else
DADD = kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib
DADD += advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib
DADD += vfw32.lib winmm.lib opengl32.lib glu32.lib largeint.lib dxguid.lib
DADD += libcmt.lib
LOPTS = /link
LOPTS += /NODEFAULTLIB:"libc"
LOPTS += /NODEFAULTLIB:"libcd"
LOPTS += /NODEFAULTLIB:"libcp"
LOPTS += /NODEFAULTLIB:"libcpd"
LOPTS += /NODEFAULTLIB:"python31"
LOPTS += /NODEFAULTLIB:"msvcrt"
LOPTS += /SUBSYSTEM:CONSOLE
LDFLAGS += /MT
DYNLDFLAGS = /LD
endif
endif
ifneq ($(OS), irix)
LLIBS += $(NAN_SDLLIBS)
endif
ifeq ($(WITH_ICONV),true)
LLIBS += $(NAN_ICONV_LIBS)
endif
ifeq ($(WITH_FFMPEG),true)
LLIBS += $(NAN_FFMPEGLIBS)
endif
ifeq ($(INTERNATIONAL),true)
LLIBS += $(NAN_GETTEXT_LIB)
endif
ifeq ($(WITH_BF_OPENMP),true)
LLIBS += -lgomp
endif
ifeq ($(WITH_FFTW3),true)
LLIBS += $(BF_FFTW3_LIBS)
endif
ifeq ($(WITH_OPENCOLLADA),true)
LLIBS += $(BF_OPENCOLLADA_LIBS)
endif
ifeq ($(WITH_TIFF),true)
LLIBS += $(NAN_TIFF_LIBS)
endif
ifeq ($(WITH_LCMS),true)
LLIBS += $(BF_LCMS_LIBS)
endif
LLIBS += $(NAN_PYTHON_LIB)

View File

@@ -1,78 +0,0 @@
# -*- mode: gnumakefile; tab-width: 8; indent-tabs-mode: t; -*-
# vim: tabstop=8
#
# $Id$
#
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
# All rights reserved.
#
# The Original Code is: all of this file.
#
# Contributor(s): GSR
#
# ***** END GPL LICENSE BLOCK *****
#
# Bounce make to subdirectories.
# Set DIRS, SOURCEDIR. Optionally also reacts on DIR, TESTDIRS.
#
default: all
# do not add install here. install target can only be used in intern/
# top level Makefiles
all debug clean::
ifdef quicky
@for i in $(quicky); do \
echo "====> $(MAKE) $@ in $$i";\
$(MAKE) -C $$i $@ quicky= || exit 1;\
done
$(MAKE) -C source link || exit 1
@echo "${quicky}"
else
ifdef DIR
@# Make sure object toplevels are there
@[ -d $(NAN_OBJDIR) ] || mkdir -p $(NAN_OBJDIR)
@[ -d $(LCGDIR) ] || mkdir -p $(LCGDIR)
@[ -d $(OCGDIR) ] || mkdir -p $(OCGDIR)
@[ -d $(OCGDIR)/intern ] || mkdir -p $(OCGDIR)/intern
@[ -d $(OCGDIR)/extern ] || mkdir -p $(OCGDIR)/extern
@# Create object directory
@[ -d $(DIR) ] || mkdir -p $(DIR)
endif
ifdef SOURCEDIR
@for i in $(DIRS); do \
echo "====> $(MAKE) $@ in $(SOURCEDIR)/$$i" ;\
$(MAKE) -C $$i $@ || exit 1; \
done
else
@for i in $(DIRS); do \
echo "====> $(MAKE) $@ in $$i" ;\
$(MAKE) -C $$i $@ || exit 1; \
done
endif
endif
test::
ifdef TESTDIRS
@for i in $(TESTDIRS); do \
echo "====> $(MAKE) $@ in $(SOURCEDIR)/$$i" ;\
$(MAKE) -C $$i $@ || exit 1; \
done
endif

View File

@@ -1,167 +0,0 @@
# -*- mode: gnumakefile; tab-width: 8; indent-tabs-mode: t; -*-
# vim: tabstop=8
#
# $Id$
#
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
# All rights reserved.
#
# The Original Code is: all of this file.
#
# Contributor(s): GSR
#
# ***** END GPL LICENSE BLOCK *****
#
# NaN compiler and linker warning levels
# On some platforms, you will be flooded with system include file warnings.
# Use hmake to filter those away.
#
# Force the correct redefinition
LEVEL_1_C_WARNINGS = -FIX_NAN_WARN1A
LEVEL_1_CPP_WARNINGS = -FIX_NAN_WARN1B
LEVEL_2_C_WARNINGS = -FIX_NAN_WARN2A
LEVEL_2_CPP_WARNINGS = -FIX_NAN_WARN2B
FIX_STUBS_WARNINGS = -FIX_NAN_WARN3
########################################################################
# Level 1: basic C warnings.
ifeq (gcc, $(findstring gcc,$(CC)))
LEVEL_1_C_WARNINGS = -Wall
LEVEL_1_C_WARNINGS += -Wno-char-subscripts
else
ifeq (cc, $(findstring cc,$(CC)))
ifeq ($(OS),irix)
# MIPSpro Compilers
#
# Irix warning info
#
# 1001 # the source file does not end w/ a newline
# 1110 # unreachable statement
# 1201 # trailing comma in enums is nonstandard
# 1209 # constant controlling expressions
# 1355 # extra semicolon is ignored
# 1424 # unreferenced template paramaters
# 1681 # virtual function override
# 3201 # unreferenced formal paramaters
#
LEVEL_1_C_WARNINGS = -fullwarn -woff 1001,1110,1201,1209,1355,1424,1681,3201
endif
endif
ifeq ($(OS),windows)
# Microsoft Compilers and cl_wrapper.pl
LEVEL_1_C_WARNINGS = -Wall
endif
endif
# Level 1: basic CPP warnings.
ifeq (g++, $(findstring g++,$(CCC)))
LEVEL_1_CPP_WARNINGS = -Wall
LEVEL_1_CPP_WARNINGS += -Wno-reorder
else
ifeq (CC, $(findstring CC,$(CCC)))
ifeq ($(OS),irix)
# MIPSpro Compilers
# see warning descriptions above
LEVEL_1_CPP_WARNINGS = -woff 1001,1110,1201,1209,1355,1424,1681,3201
endif
endif
ifeq ($(OS),windows)
# Microsoft Compilers and cl_wrapper.pl
LEVEL_1_CPP_WARNINGS = -Wall
endif
endif
########################################################################
# Level 2: paranoia level C warnings.
# DO NOT REUSE LEVEL_1_ DEFINES.
ifeq (gcc, $(findstring gcc,$(CC)))
LEVEL_2_C_WARNINGS = -Wall
LEVEL_2_C_WARNINGS += -W
# deliberately enable char-subscript warnings
LEVEL_2_C_WARNINGS += -Wshadow
LEVEL_2_C_WARNINGS += -Wpointer-arith
LEVEL_2_C_WARNINGS += -Wbad-function-cast
LEVEL_2_C_WARNINGS += -Wcast-qual
LEVEL_2_C_WARNINGS += -Wcast-align
LEVEL_2_C_WARNINGS += -Waggregate-return
LEVEL_2_C_WARNINGS += -Wstrict-prototypes
LEVEL_2_C_WARNINGS += -Wmissing-prototypes
LEVEL_2_C_WARNINGS += -Wmissing-declarations
LEVEL_2_C_WARNINGS += -Wnested-externs
LEVEL_2_C_WARNINGS += -Wredundant-decls
else
ifeq (cc, $(findstring cc,$(CC)))
ifeq ($(OS),irix)
# MIPSpro Compilers
# see warning descriptions above
LEVEL_2_C_WARNINGS = -fullwarn -woff 1001,1209,1424,3201
endif
ifeq ($(OS),solaris)
# Forte / Sun WorkShop Compilers
LEVEL_2_C_WARNINGS = -v
endif
endif
ifeq ($(OS),windows)
# Microsoft Compilers and cl_wrapper.pl
LEVEL_2_C_WARNINGS = -Wall
endif
endif
# Level 2: paranoia level CPP warnings.
# DO NOT REUSE LEVEL_1_ DEFINES.
ifeq (g++, $(findstring g++,$(CCC)))
LEVEL_2_CPP_WARNINGS = -Wall
LEVEL_2_CPP_WARNINGS += -W
# deliberately enable char-subscript warnings
LEVEL_2_CPP_WARNINGS += -Wshadow
LEVEL_2_CPP_WARNINGS += -Wpointer-arith
LEVEL_2_CPP_WARNINGS += -Wcast-qual
LEVEL_2_CPP_WARNINGS += -Wcast-align
# deliberately disable aggregate-return warnings
LEVEL_2_CPP_WARNINGS += -Wredundant-decls
LEVEL_2_CPP_WARNINGS += -Wreorder
LEVEL_2_CPP_WARNINGS += -Wctor-dtor-privacy
LEVEL_2_CPP_WARNINGS += -Wnon-virtual-dtor
#LEVEL_2_CPP_WARNINGS += -Wold-style-cast
LEVEL_2_CPP_WARNINGS += -Woverloaded-virtual
LEVEL_2_CPP_WARNINGS += -Wsign-promo
LEVEL_2_CPP_WARNINGS += -Wsynth
else
ifeq (CC, $(findstring CC,$(CCC)))
ifeq ($(OS),irix)
# MIPSpro Compilers
# see warning descriptions above
LEVEL_2_CPP_WARNINGS = -fullwarn -woff 1209,1424,3201
endif
endif
ifeq ($(OS),windows)
# Microsoft Compilers and cl_wrapper.pl
LEVEL_2_CPP_WARNINGS = -Wall
endif
endif
########################################################################
# stubs warning fix
ifeq (gcc, $(findstring gcc,$(CC)))
FIX_STUBS_WARNINGS = -Wno-unused
else
FIX_STUBS_WARNINGS =
endif

View File

@@ -0,0 +1,70 @@
#!/usr/bin/python
# <pep8 compliant>
import os
import shutil
import subprocess
import sys
# todo:
# strip executables
# get parameters
if len(sys.argv) < 5:
sys.stderr.write('Excepted arguments: ./build_archive.py name extension install_dir output_dir')
sys.exit(1)
package_name = sys.argv[1]
extension = sys.argv[2]
install_dir = sys.argv[3]
output_dir = sys.argv[4]
package_archive = os.path.join(output_dir, package_name + '.' + extension)
package_dir = package_name
# remove existing package with the same name
try:
if os.path.exists(package_archive):
os.remove(package_archive)
if os.path.exists(package_dir):
shutil.rmtree(package_dir)
except Exception, ex:
sys.stderr.write('Failed to clean up old package files: ' + str(ex) + '\n')
sys.exit(1)
# create temporary package dir
try:
shutil.copytree(install_dir, package_dir)
for f in os.listdir(package_dir):
if f.startswith('makes'):
os.remove(os.path.join(package_dir, f))
except Exception, ex:
sys.stderr.write('Failed to copy install directory: ' + str(ex) + '\n')
sys.exit(1)
# create archive
try:
if not os.path.exists(output_dir):
os.mkdir(output_dir)
if extension == 'zip':
archive_cmd = ['zip', '-9', '-r', package_archive, package_dir]
elif extension == 'tar.bz2':
archive_cmd = ['tar', 'cjf', package_archive, package_dir]
else:
sys.stderr.write('Unknown archive extension: ' + extension)
sys.exit(-1)
subprocess.call(archive_cmd)
except Exception, ex:
sys.stderr.write('Failed to create package archive: ' + str(ex) + '\n')
sys.exit(1)
# empty temporary package dir
try:
shutil.rmtree(package_dir)
except Exception, ex:
sys.stderr.write('Failed to clean up package directory: ' + str(ex) + '\n')
sys.exit(1)

View File

@@ -0,0 +1,43 @@
#!/bin/sh
# Builds a debian package from SVN source.
#
# For paralelle builds use:
# DEB_BUILD_OPTIONS="parallel=5" sh build_files/package_spec/build_debian.sh
# this needs to run in the root dir.
cd $(dirname $0)/../../
rm -rf debian
cp -a build_files/package_spec/debian .
# Get values from blender to use in debian/changelog.
# value may be formatted: 35042:35051M
BLENDER_REVISION=$(svnversion | cut -d: -f2 | tr -dc 0-9)
blender_version=$(grep BLENDER_VERSION source/blender/blenkernel/BKE_blender.h | tr -dc 0-9)
blender_version_char=$(sed -ne 's/.*BLENDER_VERSION_CHAR.*\([a-z]\)$/\1/p' source/blender/blenkernel/BKE_blender.h)
BLENDER_VERSION=$(expr $blender_version / 100).$(expr $blender_version % 100)
# map the version a -> 1, to conform to debian naming convention
# not to be confused with blender's internal subversions
if [ "$blender_version_char" ]; then
BLENDER_VERSION=${BLENDER_VERSION}.$(expr index abcdefghijklmnopqrstuvwxyz $blender_version_char)
fi
DEB_VERSION=${BLENDER_VERSION}+svn${BLENDER_REVISION}-bf
# update debian/changelog
dch -b -v $DEB_VERSION "New upstream SVN snapshot."
# run the rules makefile
rm -rf get-orig-source
debian/rules get-orig-source SVN_URL=.
mv *.gz ../
# build the package
debuild -i -us -uc -b
# remove temp dir
rm -rf debian

View File

@@ -0,0 +1,5 @@
blender (2.56+svn34749-bf) unstable; urgency=low
* New upstream SVN snapshot.
-- Dan Eicher <dan@trollwerks.org> Wed, 09 Feb 2011 18:55:24 -0700

View File

@@ -0,0 +1 @@
7

View File

@@ -0,0 +1,24 @@
Source: blender
Section: graphics
Priority: extra
Maintainer: Dan Eicher <dan@trollwerks.org>
Build-Depends: debhelper (>= 7.0.50~), cmake, python3, python, libfreetype6-dev, libglu1-mesa-dev, libilmbase-dev, libopenexr-dev, libjpeg62-dev, libopenal-dev, libpng12-dev, libsamplerate0-dev, libsdl-dev, libtiff4-dev, libx11-dev, libxi-dev, zlib1g-dev, python3.2-dev, libopenjpeg-dev
Standards-Version: 3.9.1
Homepage: http://blender.org/
X-Python3-Version: >= 3.2, << 3.3
Package: blender-snapshot
Architecture: any
Depends: ${shlibs:Depends}, ${python3:Depends}, ${misc:Depends}
Provides: blender
Conflicts: blender
Replaces: blender
Description: Very fast and versatile 3D modeller/renderer
Blender is an integrated 3d suite for modelling, animation, rendering,
post-production, interactive creation and playback (games). Blender has its
own particular user interface, which is implemented entirely in OpenGL and
designed with speed in mind. Python bindings are available for scripting;
import/export features for popular file formats like 3D Studio and Wavefront
Obj are implemented as scripts by the community. Stills, animations, models
for games or other third party engines and interactive content in the form of
a standalone binary and/or a web plug-in are common products of Blender use.

View File

@@ -0,0 +1,41 @@
This work was packaged for Debian by:
Dan Eicher <dan@trollwerks.org> on Tue, 08 Feb 2011 21:59:32 -0700
It was downloaded from:
http://blender.org
Copyright:
Copyright (C) 2002-2011 Blender Foundation
License:
This package is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This package is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>
On Debian systems, the complete text of the GNU General
Public License version 2 can be found in "/usr/share/common-licenses/GPL-2".
The Debian packaging is:
Copyright (C) 2011 Dan Eicher <dan@trollwerks.org>
you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.

View File

@@ -0,0 +1,2 @@
release/text/copyright.txt
release/text/readme.html

View File

@@ -0,0 +1,4 @@
?package(blender-snapshot):needs="X11" section="Applications/Graphics"\
longtitle="Blender 3D modeler / renderer"\
icon="/usr/share/icons/hicolor/scalable/apps/blender.svg"\
title="blender" command="/usr/bin/blender"

View File

@@ -0,0 +1,44 @@
#!/usr/bin/make -f
# -*- makefile -*-
SVN_URL := https://svn.blender.org/svnroot/bf-blender/trunk/blender
REV := $(shell dpkg-parsechangelog | sed -rne 's,^Version: .*[+~]svn([0-9]+).*,\1,p')
VER := $(shell dpkg-parsechangelog | sed -rne 's,^Version: ([^-]+).*,\1,p')
REL := $(shell dpkg-parsechangelog | sed -rne 's,^Version: ([0-9]+\.[0-9]+).*,\1,p')
TARBALL = blender_$(VER).orig.tar.gz
BLDDIR = debian/cmake
%:
dh $@ -Scmake -B$(BLDDIR) --parallel --with python3 --without python-support
override_dh_auto_configure:
# blender spesific CMake options
dh_auto_configure -- \
-DCMAKE_BUILD_TYPE:STRING=Release \
-DWITH_INSTALL_PORTABLE:BOOL=OFF \
-DWITH_PYTHON_INSTALL:BOOL=OFF \
-DWITH_OPENCOLLADA:BOOL=OFF
override_dh_auto_test:
# don't run CTest
override_dh_install:
dh_install
# remove duplicated docs
rm -rf debian/blender-snapshot/usr/share/doc/blender
override_dh_python3:
dh_python3 -V 3.2-3.3 /usr/share/blender/$(REL)/scripts
get-orig-source:
rm -rf get-orig-source $(TARBALL)
mkdir get-orig-source
if [ "$(SVN_URL)" = . ] && [ `svnversion` = "$(REV)" ]; then \
svn -q export . get-orig-source/blender-$(VER); \
else \
svn -q export -r $(REV) $(SVN_URL) get-orig-source/blender-$(VER); \
fi
GZIP='--best --no-name' tar czf $(TARBALL) -C get-orig-source blender-$(VER)
rm -rf get-orig-source
@echo "$(TARBALL) created; move it to the right destination to build the package"

View File

@@ -0,0 +1 @@
3.0 (quilt)

View File

@@ -0,0 +1,3 @@
version=3
opts=uversionmangle=s/[a-z]$/.$&/;s/[j-s]$/1$&/;s/[t-z]$/2$&/;tr/a-z/1-90-90-6/ \
http://download.blender.org/source/blender-([0-9.]+[a-z]?)\.tar\.gz

View File

@@ -1,12 +1,23 @@
# Maintainer: Campbell Barton <ideasman42 at gmail dot com>
# custom blender vars
blender_srcdir=$srcdir/../../../..
blender_version=$(grep BLENDER_VERSION $blender_srcdir/source/blender/blenkernel/BKE_blender.h | tr -dc 0-9)
blender_subversion=$(grep BLENDER_SUBVERSION $blender_srcdir/source/blender/blenkernel/BKE_blender.h | tr -dc 0-9)
blender_ver_string=$(expr $blender_version / 100).$(expr $blender_version % 100).$blender_subversion
blender_srcdir=$(dirname $startdir)"/../.."
# value may be formatted: 35042:35051M
blender_revision=$(svnversion $blender_srcdir | cut -d: -f2 | awk '{print $3}')
blender_version=$(grep BLENDER_VERSION $blender_srcdir/source/blender/blenkernel/BKE_blender.h | awk '{print $3}')
blender_version=$(expr $blender_version / 100).$(expr $blender_version % 100) # 256 -> 2.56
blender_version_char=$(sed -ne 's/.*BLENDER_VERSION_CHAR.*\([a-z]\)$/\1/p' $blender_srcdir/source/blender/blenkernel/BKE_blender.h)
# blender_subversion=$(grep BLENDER_SUBVERSION $blender_srcdir/source/blender/blenkernel/BKE_blender.h | awk '{print $3}')
pkgname=blender-beta
# map the version a -> 1
# not to be confused with blender's internal subversions
if [ "$blender_version_char" ]; then
blender_version=${blender_version}.$(expr index abcdefghijklmnopqrstuvwxyz $blender_version_char)
fi
blender_ver_string=$blender_version+svn$blender_revision
pkgname=blender-snapshot
pkgver=$blender_ver_string
pkgrel=1
pkgdesc="A fully integrated 3D graphics creation suite"
@@ -14,12 +25,12 @@ arch=('i686' 'x86_64')
url="www.blender.org"
license=('GPL')
groups=()
depends=('libjpeg' 'libpng' 'openexr' 'python3>=3.1' 'gettext' 'libxi' 'libxmu' 'mesa' 'freetype2' 'openal' 'sdl' 'libsndfile' 'libsamplerate' 'ffmpeg')
depends=('libjpeg' 'libpng' 'openjpeg' 'libtiff' 'openexr' 'python>=3.2' 'gettext' 'libxi' 'libxmu' 'mesa' 'freetype2' 'openal' 'sdl' 'libsndfile' 'libsamplerate' 'ffmpeg')
makedepends=('cmake' 'svn')
optdepends=()
provides=('blender')
provides=()
conflicts=('blender')
replaces=()
replaces=('blender')
backup=()
options=()
install=blender.install
@@ -36,13 +47,19 @@ build() {
cmake $blender_srcdir \
-DCMAKE_INSTALL_PREFIX:PATH=/usr \
-DCMAKE_BUILD_TYPE:STRING=Release \
-DWITH_INSTALL_PORTABLE:BOOL=OFF \
-DWITH_PYTHON_INSTALL:BOOL=OFF \
-DWITH_OPENCOLLADA:BOOL=OFF
-DWITH_OPENCOLLADA:BOOL=OFF \
-DPYTHON_VERSION:STRING=3.2 \
-DPYTHON_LIBPATH:STRING=/usr/lib \
-DPYTHON_LIBRARY:STRING=python3.2mu \
-DPYTHON_INCLUDE_DIRS:STRING=/usr/include/python3.2mu
make
make $MAKEFLAGS
}
package() {
cd $srcdir/build
make DESTDIR="$pkgdir" install
python -m compileall $pkgdir/usr/share/blender
}

View File

@@ -0,0 +1,70 @@
# -*- rpm-spec -*-
%global __python %{__python3}
BuildRoot: @CPACK_RPM_DIRECTORY@/@CPACK_PACKAGE_FILE_NAME@@CPACK_RPM_PACKAGE_COMPONENT_PART_PATH@
Summary: @CPACK_RPM_PACKAGE_SUMMARY@
Name: @CPACK_RPM_PACKAGE_NAME@
Version: @CPACK_RPM_PACKAGE_VERSION@
Release: @CPACK_RPM_PACKAGE_RELEASE@%{?dist}
License: @CPACK_RPM_PACKAGE_LICENSE@
Group: @CPACK_RPM_PACKAGE_GROUP@
Vendor: @CPACK_RPM_PACKAGE_VENDOR@
Epoch: 1
%define _rpmdir @CPACK_RPM_DIRECTORY@
%define _rpmfilename @CPACK_RPM_FILE_NAME@
%define _unpackaged_files_terminate_build 0
%define _topdir @CPACK_RPM_DIRECTORY@
%description
Blender is an integrated 3d suite for modelling, animation, rendering,
post-production, interactive creation and playback (games). Blender has its
own particular user interface, which is implemented entirely in OpenGL and
designed with speed in mind. Python bindings are available for scripting;
import/export features for popular file formats like 3D Studio and Wavefront
Obj are implemented as scripts by the community. Stills, animations, models
for games or other third party engines and interactive content in the form of
a standalone binary and/or a web plug-in are common products of Blender use.
# This is a shortcutted spec file generated by CMake RPM generator
# we skip _install step because CPack does that for us.
# We do only save CPack installed tree in _prepr
# and then restore it in build.
%prep
mv ${RPM_BUILD_ROOT} "@CPACK_TOPLEVEL_DIRECTORY@/tmpBBroot"
%install
if [ -e ${RPM_BUILD_ROOT} ];
then
rm -rf ${RPM_BUILD_ROOT}
fi
mv "@CPACK_TOPLEVEL_DIRECTORY@/tmpBBroot" ${RPM_BUILD_ROOT}
%clean
rm -rf ${RPM_BUILD_ROOT}
%post
touch --no-create %{_datadir}/icons/hicolor
if [ -x %{_bindir}/gtk-update-icon-cache ]; then
%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor
fi
%{_bindir}/update-desktop-database %{_datadir}/applications || :
%postun
%{_bindir}/update-desktop-database %{_datadir}/applications
touch --no-create %{_datadir}/icons/hicolor
if [ -x %{_bindir}/gtk-update-icon-cache ]; then
%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor
fi || :
%files
%defattr(-,root,root,-)
%{_bindir}/%{name}
%{_datadir}/%{name}/@CPACK_PACKAGE_VERSION_MAJOR@.@CPACK_PACKAGE_VERSION_MINOR@
%{_datadir}/icons/hicolor/*/apps/%{name}.*
%{_datadir}/applications/%{name}.desktop
%{_datadir}/doc/blender
%{_mandir}/man1/blender.*
%changelog
@CPACK_RPM_SPEC_CHANGELOG@

View File

@@ -8,7 +8,7 @@ WITH_BF_VERSE = 'false'
BF_VERSE_INCLUDE = "#extern/verse/dist"
BF_PYTHON = LCGDIR+'/python'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
WITH_BF_STATICPYTHON = 'true'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'
@@ -76,11 +76,6 @@ BF_GETTEXT_INC = '${BF_GETTEXT}/include'
BF_GETTEXT_LIB = 'gettextpo intl'
BF_GETTEXT_LIBPATH = '${BF_GETTEXT}/lib'
WITH_BF_FTGL = 'false'
BF_FTGL = '#extern/bFTGL'
BF_FTGL_INC = '${BF_FTGL}/include'
BF_FTGL_LIB = 'extern_ftgl'
WITH_BF_GAMEENGINE='false'
WITH_BF_BULLET = 'true'
@@ -165,8 +160,8 @@ CCFLAGS = [ '-pipe', '-funsigned-char', '-fno-strict-aliasing' ]
CPPFLAGS = [ '-DXP_UNIX', '-DWIN32', '-DFREE_WINDOWS' ]
CXXFLAGS = ['-pipe', '-funsigned-char', '-fno-strict-aliasing' ]
REL_CFLAGS = [ '-O2' ]
REL_CCFLAGS = [ '-O2' ]
REL_CFLAGS = ['-DNDEBUG', '-O2' ]
REL_CCFLAGS = ['-DNDEBUG', '-O2' ]
C_WARN = [ '-Wall' , '-Wno-char-subscripts', '-Wdeclaration-after-statement' ]
CC_WARN = [ '-Wall' ]

View File

@@ -14,21 +14,30 @@ USE_SDK=True
################### Cocoa & architecture settings ##################
#############################################################################
WITH_GHOST_COCOA=True
MACOSX_ARCHITECTURE = 'i386' # valid archs: ppc, i386, ppc64, x86_64
MACOSX_ARCHITECTURE = 'x86_64' # valid archs: ppc, i386, ppc64, x86_64
cmd = 'uname -p'
MAC_PROC=commands.getoutput(cmd)
cmd = 'uname -r'
cmd_res=commands.getoutput(cmd)
if cmd_res[0]=='7':
if cmd_res[:1]=='7':
MAC_CUR_VER='10.3'
elif cmd_res[0]=='8':
elif cmd_res[:1]=='8':
MAC_CUR_VER='10.4'
elif cmd_res[0]=='9':
elif cmd_res[:1]=='9':
MAC_CUR_VER='10.5'
elif cmd_res[0]=='10':
elif cmd_res[:2]=='10':
MAC_CUR_VER='10.6'
elif cmd_res[:2]=='11':
MAC_CUR_VER='10.7'
cmd = 'xcodebuild -version'
cmd_xcode=commands.getoutput(cmd)
XCODE_CUR_VER=cmd_xcode
cmd = 'xcodebuild -showsdks'
cmd_sdk=commands.getoutput(cmd)
MACOSX_SDK_CHECK=cmd_sdk
if MACOSX_ARCHITECTURE == 'x86_64' or MACOSX_ARCHITECTURE == 'ppc64':
USE_QTKIT=True # Carbon quicktime is not available for 64bit
@@ -37,8 +46,8 @@ if MACOSX_ARCHITECTURE == 'x86_64' or MACOSX_ARCHITECTURE == 'ppc64':
# Default target OSX settings per architecture
# Can be customized
if MACOSX_ARCHITECTURE == 'ppc':
# ppc release are now made for 10.4
if MACOSX_ARCHITECTURE == 'ppc' and MAC_CUR_VER == '10.4':
# all releases are now made for 10.5 !
# MAC_MIN_VERS = '10.3'
# MACOSX_SDK='/Developer/SDKs/MacOSX10.3.9.sdk'
# LCGDIR = '#../lib/darwin-6.1-powerpc'
@@ -50,7 +59,7 @@ if MACOSX_ARCHITECTURE == 'ppc':
LCGDIR = '#../lib/darwin-8.0.0-powerpc'
CC = 'gcc-4.0'
CXX = 'g++-4.0'
elif MACOSX_ARCHITECTURE == 'i386':
elif MACOSX_ARCHITECTURE == 'i386' and MAC_CUR_VER == '10.4':
MAC_MIN_VERS = '10.4'
MACOSX_DEPLOYMENT_TARGET = '10.4'
MACOSX_SDK='/Developer/SDKs/MacOSX10.4u.sdk'
@@ -58,12 +67,22 @@ elif MACOSX_ARCHITECTURE == 'i386':
CC = 'gcc-4.0'
CXX = 'g++-4.0'
else :
MAC_MIN_VERS = '10.5'
MACOSX_DEPLOYMENT_TARGET = '10.5'
MACOSX_SDK='/Developer/SDKs/MacOSX10.5.sdk'
LCGDIR = '#../lib/darwin-9.x.universal'
CC = 'gcc-4.2'
CXX = 'g++-4.2'
if 'Mac OS X 10.5' in MACOSX_SDK_CHECK:
# OSX 10.5/6 with Xcode 3.x
MAC_MIN_VERS = '10.5'
MACOSX_DEPLOYMENT_TARGET = '10.5'
MACOSX_SDK='/Developer/SDKs/MacOSX10.5.sdk'
LCGDIR = '#../lib/darwin-9.x.universal'
CC = 'gcc-4.2'
CXX = 'g++-4.2'
else:
# OSX 10.6/7 with Xcode 4.x
MAC_MIN_VERS = '10.6'
MACOSX_DEPLOYMENT_TARGET = '10.6'
MACOSX_SDK='/Developer/SDKs/MacOSX10.6.sdk'
LCGDIR = '#../lib/darwin-9.x.universal'
CC = 'gcc-4.2'
CXX = 'g++-4.2'
LIBDIR = '${LCGDIR}'
@@ -71,8 +90,8 @@ LIBDIR = '${LCGDIR}'
################### Dependency settings ##################
#############################################################################
#Defaults openMP to true if compiler (currently only gcc 4.2) handles it
if CC == 'gcc-4.2':
#Defaults openMP to true if compiler handles it
if CC == 'gcc-4.2' or CC == 'llvm-gcc-4.2':
WITH_BF_OPENMP = True # multithreading for fluids, cloth and smoke
else:
WITH_BF_OPENMP = False
@@ -85,14 +104,26 @@ BF_FFMPEG_LIBPATH='${BF_FFMPEG}/lib'
BF_FFMPEG_LIB = 'avcodec avdevice avformat avutil mp3lame swscale x264 xvidcore theora theoradec theoraenc vorbis vorbisenc vorbisfile ogg bz2'
#bz2 is a standard osx dynlib
# python 3.1 uses precompiled libraries in bf svn /lib by default
BF_PYTHON_VERSION = '3.1'
BF_PYTHON = LIBDIR + '/python'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
# BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}'
BF_PYTHON_LIBPATH = '${BF_PYTHON}/lib/python${BF_PYTHON_VERSION}'
# BF_PYTHON_LINKFLAGS = ['-u', '_PyMac_Error', '-framework', 'System']
BF_PYTHON_VERSION = '3.2'
WITH_OSX_STATICPYTHON = True
if WITH_OSX_STATICPYTHON:
# python 3.2 uses precompiled libraries in bf svn /lib by default
BF_PYTHON = LIBDIR + '/python'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
# BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}'
BF_PYTHON_LIBPATH = '${BF_PYTHON}/lib/python${BF_PYTHON_VERSION}'
# BF_PYTHON_LINKFLAGS = ['-u', '_PyMac_Error', '-framework', 'System']
else:
# python 3.2 uses Python-framework additionally installed in /Library/Frameworks
BF_PYTHON = '/Library/Frameworks/Python.framework/Versions/'
BF_PYTHON_INC = '${BF_PYTHON}${BF_PYTHON_VERSION}/include/python${BF_PYTHON_VERSION}m'
BF_PYTHON_BINARY = '${BF_PYTHON}${BF_PYTHON_VERSION}/bin/python${BF_PYTHON_VERSION}'
#BF_PYTHON_LIB = ''
BF_PYTHON_LIBPATH = '${BF_PYTHON}${BF_PYTHON_VERSION}/lib/python${BF_PYTHON_VERSION}/config-3.2m'
WITH_BF_OPENAL = True
#different lib must be used following version of gcc
@@ -188,8 +219,8 @@ BF_GETTEXT_INC = '${BF_GETTEXT}/include'
BF_GETTEXT_LIB = 'intl'
BF_GETTEXT_LIBPATH = '${BF_GETTEXT}/lib'
WITH_BF_GAMEENGINE=True
WITH_BF_PLAYER = False
WITH_BF_GAMEENGINE = True
WITH_BF_PLAYER = True
WITH_BF_BULLET = True
BF_BULLET = '#extern/bullet2/src'
@@ -240,7 +271,7 @@ BF_OPENGL_LIBPATH = '/System/Library/Frameworks/OpenGL.framework/Libraries'
BF_OPENGL_LINKFLAGS = ['-framework', 'OpenGL']
#OpenCollada flags
WITH_BF_COLLADA = False
WITH_BF_COLLADA = True
BF_COLLADA = '#source/blender/collada'
BF_COLLADA_INC = '${BF_COLLADA}'
BF_COLLADA_LIB = 'bf_collada'
@@ -264,7 +295,9 @@ if MACOSX_ARCHITECTURE == 'i386':
BF_RAYOPTIMIZATION_SSE_FLAGS = ['-msse']
elif MACOSX_ARCHITECTURE == 'x86_64':
BF_RAYOPTIMIZATION_SSE_FLAGS = ['-msse','-msse2']
# SpaceNavigator and related 3D mice, driver must be 3DxWare 10 Beta 4 (Mac OS X) or later !
WITH_BF_3DMOUSE = True
#############################################################################
################### various compile settings and flags ##################
@@ -283,28 +316,36 @@ CPPFLAGS = []+ARCH_FLAGS
CCFLAGS = ['-pipe','-funsigned-char']+ARCH_FLAGS
CXXFLAGS = ['-pipe','-funsigned-char']+ARCH_FLAGS
if WITH_GHOST_COCOA==True:
if WITH_GHOST_COCOA:
PLATFORM_LINKFLAGS = ['-fexceptions','-framework','CoreServices','-framework','Foundation','-framework','IOKit','-framework','AppKit','-framework','Cocoa','-framework','Carbon','-framework','AudioUnit','-framework','AudioToolbox','-framework','CoreAudio','-framework','OpenAL']+ARCH_FLAGS
else:
PLATFORM_LINKFLAGS = ['-fexceptions','-framework','CoreServices','-framework','Foundation','-framework','IOKit','-framework','AppKit','-framework','Carbon','-framework','AGL','-framework','AudioUnit','-framework','AudioToolbox','-framework','CoreAudio','-framework','OpenAL']+ARCH_FLAGS
if WITH_BF_QUICKTIME == True:
if USE_QTKIT == True:
if WITH_BF_QUICKTIME:
if USE_QTKIT:
PLATFORM_LINKFLAGS = PLATFORM_LINKFLAGS+['-framework','QTKit']
else:
PLATFORM_LINKFLAGS = PLATFORM_LINKFLAGS+['-framework','QuickTime']
#note to build succesfully on 10.3.9 SDK you need to patch 10.3.9 by adding the SystemStubs.a lib from 10.4
LLIBS = ['stdc++', 'SystemStubs']
if not WITH_OSX_STATICPYTHON:
PLATFORM_LINKFLAGS = PLATFORM_LINKFLAGS+['-framework','Python']
# some flags shuffling for different Os versions
#note to build succesfully on 10.3.9 SDK you need to patch 10.3.9 by adding the SystemStubs.a lib from 10.4
#for 10.7.sdk, SystemStubs needs to be excluded (lib doesn't exist anymore)
if MACOSX_DEPLOYMENT_TARGET == '10.7':
LLIBS = ['stdc++']
else:
LLIBS = ['stdc++', 'SystemStubs']
# some flags shuffling for different OS versions
if MAC_MIN_VERS == '10.3':
CFLAGS = ['-fuse-cxa-atexit']+CFLAGS
CXXFLAGS = ['-fuse-cxa-atexit']+CXXFLAGS
PLATFORM_LINKFLAGS = ['-fuse-cxa-atexit']+PLATFORM_LINKFLAGS
LLIBS.append('crt3.o')
if USE_SDK==True:
if USE_SDK:
SDK_FLAGS=['-isysroot', MACOSX_SDK,'-mmacosx-version-min='+MAC_MIN_VERS,'-arch',MACOSX_ARCHITECTURE]
PLATFORM_LINKFLAGS = ['-mmacosx-version-min='+MAC_MIN_VERS,'-Wl','-isysroot',MACOSX_SDK,'-arch',MACOSX_ARCHITECTURE]+PLATFORM_LINKFLAGS
CCFLAGS=SDK_FLAGS+CCFLAGS
@@ -312,14 +353,14 @@ if USE_SDK==True:
#Intel Macs are CoreDuo and Up
if MACOSX_ARCHITECTURE == 'i386' or MACOSX_ARCHITECTURE == 'x86_64':
REL_CFLAGS = ['-O2','-ftree-vectorize','-msse','-msse2','-msse3','-mfpmath=sse']
REL_CCFLAGS = ['-O2','-ftree-vectorize','-msse','-msse2','-msse3','-mfpmath=sse']
REL_CFLAGS = ['-DNDEBUG', '-O2','-ftree-vectorize','-msse','-msse2','-msse3','-mfpmath=sse']
REL_CCFLAGS = ['-DNDEBUG', '-O2','-ftree-vectorize','-msse','-msse2','-msse3','-mfpmath=sse']
else:
CFLAGS = CFLAGS+['-fno-strict-aliasing']
CCFLAGS = CCFLAGS+['-fno-strict-aliasing']
CXXFLAGS = CXXFLAGS+['-fno-strict-aliasing']
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
REL_CFLAGS = ['-DNDEBUG', '-O2']
REL_CCFLAGS = ['-DNDEBUG', '-O2']
# Intel 64bit Macs are Core2Duo and up
if MACOSX_ARCHITECTURE == 'x86_64':
@@ -327,7 +368,7 @@ if MACOSX_ARCHITECTURE == 'x86_64':
REL_CCFLAGS = REL_CCFLAGS+['-march=core2','-mssse3','-with-tune=core2','-enable-threads']
CC_WARN = ['-Wall']
C_WARN = ['-Wno-char-subscripts', '-Wpointer-arith', '-Wcast-align', '-Wdeclaration-after-statement', '-Wno-unknown-pragmas']
C_WARN = ['-Wno-char-subscripts', '-Wpointer-arith', '-Wcast-align', '-Wdeclaration-after-statement', '-Wno-unknown-pragmas', '-Wstrict-prototypes']
CXX_WARN = ['-Wno-invalid-offsetof', '-Wno-sign-compare']
##FIX_STUBS_WARNINGS = -Wno-unused
@@ -340,7 +381,7 @@ BF_PROFILE_LINKFLAGS = ['-pg']
BF_PROFILE = False
BF_DEBUG = False
BF_DEBUG_CCFLAGS = ['-g', '-DDEBUG']
BF_DEBUG_CCFLAGS = ['-g', '-D_DEBUG']
#############################################################################
################### Output directories ##################

View File

@@ -4,14 +4,15 @@ CXX = 'g++44'
LCGDIR = '../lib/freebsd7'
LIBDIR = "${LCGDIR}"
BF_PYTHON_ABI_FLAGS = ''
BF_PYTHON = '/usr/local'
BF_PYTHON_LIBPATH = '${BF_PYTHON}/lib'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
WITH_BF_STATICPYTHON = False
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}'
BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB_STATIC = '${BF_PYTHON}/lib/libpython${BF_PYTHON_VERSION}.a'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}'
BF_PYTHON_LIB_STATIC = '${BF_PYTHON}/lib/libpython${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}.a'
WITH_BF_OPENAL = True
WITH_BF_STATICOPENAL = False
@@ -137,7 +138,7 @@ BF_FFTW3_INC = '${BF_FFTW3}/include'
BF_FFTW3_LIB = 'fftw3'
BF_FFTW3_LIBPATH = '${BF_FFTW3}/lib'
WITH_BF_REDCODE = True
WITH_BF_REDCODE = False
BF_REDCODE = '#extern/libredcode'
BF_REDCODE_LIB = ''
# BF_REDCODE_INC = '${BF_REDCODE}/include'
@@ -173,22 +174,22 @@ WITH_BF_OPENMP = True
WITH_BF_RAYOPTIMIZATION = True
BF_RAYOPTIMIZATION_SSE_FLAGS = ['-msse','-pthread']
CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64']
CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE','-D_FILE_OFFSET_BITS=64','-D_LARGEFILE64_SOURCE']
CPPFLAGS = []
CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64']
CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE','-D_FILE_OFFSET_BITS=64','-D_LARGEFILE64_SOURCE']
if WITH_BF_FFMPEG:
# libavutil needs UINT64_C()
CXXFLAGS += ['-D__STDC_CONSTANT_MACROS', ]
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
REL_CFLAGS = ['-DNDEBUG', '-O2']
REL_CCFLAGS = ['-DNDEBUG', '-O2']
##BF_DEPEND = True
##
##AR = ar
##ARFLAGS = ruv
##ARFLAGSQUIET = ru
##
C_WARN = ['-Wno-char-subscripts', '-Wdeclaration-after-statement']
C_WARN = ['-Wno-char-subscripts', '-Wdeclaration-after-statement', '-Wstrict-prototypes']
CC_WARN = ['-Wall']
CXX_WARN = ['-Wno-invalid-offsetof', '-Wno-sign-compare']
@@ -204,7 +205,7 @@ BF_PROFILE_CCFLAGS = ['-pg','-g']
BF_PROFILE_LINKFLAGS = ['-pg']
BF_DEBUG = False
BF_DEBUG_CCFLAGS = ['-g', '-DDEBUG']
BF_DEBUG_CCFLAGS = ['-g', '-D_DEBUG']
BF_BUILDDIR = '../build/freebsd7'
BF_INSTALLDIR='../install/freebsd7'

View File

@@ -4,14 +4,15 @@ CXX = 'g++44'
LCGDIR = '../lib/freebsd8'
LIBDIR = "${LCGDIR}"
BF_PYTHON_ABI_FLAGS = ''
BF_PYTHON = '/usr/local'
BF_PYTHON_LIBPATH = '${BF_PYTHON}/lib'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
WITH_BF_STATICPYTHON = False
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}'
BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB_STATIC = '${BF_PYTHON}/lib/libpython${BF_PYTHON_VERSION}.a'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}'
BF_PYTHON_LIB_STATIC = '${BF_PYTHON}/lib/libpython${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}.a'
WITH_BF_OPENAL = True
WITH_BF_STATICOPENAL = False
@@ -137,7 +138,7 @@ BF_FFTW3_INC = '${BF_FFTW3}/include'
BF_FFTW3_LIB = 'fftw3'
BF_FFTW3_LIBPATH = '${BF_FFTW3}/lib'
WITH_BF_REDCODE = True
WITH_BF_REDCODE = False
BF_REDCODE = '#extern/libredcode'
BF_REDCODE_LIB = ''
# BF_REDCODE_INC = '${BF_REDCODE}/include'
@@ -173,22 +174,22 @@ WITH_BF_OPENMP = True
WITH_BF_RAYOPTIMIZATION = True
BF_RAYOPTIMIZATION_SSE_FLAGS = ['-msse','-pthread']
CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64']
CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE','-D_FILE_OFFSET_BITS=64','-D_LARGEFILE64_SOURCE']
CPPFLAGS = []
CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64']
CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE','-D_FILE_OFFSET_BITS=64','-D_LARGEFILE64_SOURCE']
if WITH_BF_FFMPEG:
# libavutil needs UINT64_C()
CXXFLAGS += ['-D__STDC_CONSTANT_MACROS', ]
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
REL_CFLAGS = ['-DNDEBUG', '-O2']
REL_CCFLAGS = ['-DNDEBUG', '-O2']
##BF_DEPEND = True
##
##AR = ar
##ARFLAGS = ruv
##ARFLAGSQUIET = ru
##
C_WARN = ['-Wno-char-subscripts', '-Wdeclaration-after-statement']
C_WARN = ['-Wno-char-subscripts', '-Wdeclaration-after-statement', '-Wstrict-prototypes']
CC_WARN = ['-Wall']
CXX_WARN = ['-Wno-invalid-offsetof', '-Wno-sign-compare']
@@ -204,7 +205,7 @@ BF_PROFILE_CCFLAGS = ['-pg','-g']
BF_PROFILE_LINKFLAGS = ['-pg']
BF_DEBUG = False
BF_DEBUG_CCFLAGS = ['-g', '-DDEBUG']
BF_DEBUG_CCFLAGS = ['-g', '-D_DEBUG']
BF_BUILDDIR = '../build/freebsd8'
BF_INSTALLDIR='../install/freebsd8'

View File

@@ -4,14 +4,15 @@ CXX = 'g++44'
LCGDIR = '../lib/freebsd9'
LIBDIR = "${LCGDIR}"
BF_PYTHON_ABI_FLAGS = ''
BF_PYTHON = '/usr/local'
BF_PYTHON_LIBPATH = '${BF_PYTHON}/lib'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
WITH_BF_STATICPYTHON = False
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}'
BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB_STATIC = '${BF_PYTHON}/lib/libpython${BF_PYTHON_VERSION}.a'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}'
BF_PYTHON_LIB_STATIC = '${BF_PYTHON}/lib/libpython${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}.a'
WITH_BF_OPENAL = True
WITH_BF_STATICOPENAL = False
@@ -137,7 +138,7 @@ BF_FFTW3_INC = '${BF_FFTW3}/include'
BF_FFTW3_LIB = 'fftw3'
BF_FFTW3_LIBPATH = '${BF_FFTW3}/lib'
WITH_BF_REDCODE = True
WITH_BF_REDCODE = False
BF_REDCODE = '#extern/libredcode'
BF_REDCODE_LIB = ''
# BF_REDCODE_INC = '${BF_REDCODE}/include'
@@ -173,22 +174,22 @@ WITH_BF_OPENMP = True
WITH_BF_RAYOPTIMIZATION = True
BF_RAYOPTIMIZATION_SSE_FLAGS = ['-msse','-pthread']
CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64']
CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE','-D_FILE_OFFSET_BITS=64','-D_LARGEFILE64_SOURCE']
CPPFLAGS = []
CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64']
CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE','-D_FILE_OFFSET_BITS=64','-D_LARGEFILE64_SOURCE']
if WITH_BF_FFMPEG:
# libavutil needs UINT64_C()
CXXFLAGS += ['-D__STDC_CONSTANT_MACROS', ]
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
REL_CFLAGS = ['-DNDEBUG', '-O2']
REL_CCFLAGS = ['-DNDEBUG', '-O2']
##BF_DEPEND = True
##
##AR = ar
##ARFLAGS = ruv
##ARFLAGSQUIET = ru
##
C_WARN = ['-Wno-char-subscripts', '-Wdeclaration-after-statement']
C_WARN = ['-Wno-char-subscripts', '-Wdeclaration-after-statement', '-Wstrict-prototypes']
CC_WARN = ['-Wall']
CXX_WARN = ['-Wno-invalid-offsetof', '-Wno-sign-compare']
@@ -204,7 +205,7 @@ BF_PROFILE_CCFLAGS = ['-pg','-g']
BF_PROFILE_LINKFLAGS = ['-pg']
BF_DEBUG = False
BF_DEBUG_CCFLAGS = ['-g', '-DDEBUG']
BF_DEBUG_CCFLAGS = ['-g', '-D_DEBUG']
BF_BUILDDIR = '../build/freebsd9'
BF_INSTALLDIR='../install/freebsd9'

View File

@@ -4,7 +4,7 @@ LCGDIR = os.getcwd()+"/../lib/irix-6.5-mips"
LIBDIR = LCGDIR
BF_PYTHON = LCGDIR+'/python'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
WITH_BF_STATICPYTHON = 'true'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'
@@ -163,8 +163,8 @@ CCFLAGS = ['-pipe','-fPIC', '-n32']
CPPFLAGS = []
CXXFLAGS = ['-pipe','-fPIC', '-n32']
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
REL_CFLAGS = ['-DNDEBUG', '-O2']
REL_CCFLAGS = ['-DNDEBUG', '-O2']
##BF_DEPEND = 'true'
##
##AR = ar

View File

@@ -1,15 +1,16 @@
LCGDIR = '../lib/linux2'
LCGDIR = '../lib/linux'
LIBDIR = "${LCGDIR}"
BF_PYTHON_ABI_FLAGS = 'm' # Most common for linux distros
BF_PYTHON = '/usr'
BF_PYTHON_LIBPATH = '${BF_PYTHON}/lib'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
WITH_BF_STATICPYTHON = False
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}'
BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}' #BF_PYTHON+'/lib/python'+BF_PYTHON_VERSION+'/config/libpython'+BF_PYTHON_VERSION+'.a'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}' # BF_PYTHON+'/lib/python'+BF_PYTHON_VERSION+'/config/libpython'+BF_PYTHON_VERSION+'.a'
BF_PYTHON_LINKFLAGS = ['-Xlinker', '-export-dynamic']
BF_PYTHON_LIB_STATIC = '${BF_PYTHON}/lib/libpython${BF_PYTHON_VERSION}.a'
BF_PYTHON_LIB_STATIC = '${BF_PYTHON}/lib/libpython${BF_PYTHON_VERSION}${BF_PYTHON_ABI_FLAGS}.a'
WITH_BF_OPENAL = True
WITH_BF_STATICOPENAL = False
@@ -92,7 +93,7 @@ BF_GETTEXT_LIBPATH = '${BF_GETTEXT}/lib'
#BF_GETTEXT_LIB_STATIC = '${BF_GETTEXT}/lib/libgettextlib.a'
WITH_BF_GAMEENGINE = True
WITH_BF_PLAYER = False
WITH_BF_PLAYER = True
WITH_BF_BULLET = True
BF_BULLET = '#extern/bullet2/src'
@@ -177,34 +178,52 @@ BF_EXPAT = '/usr'
BF_EXPAT_LIB = 'expat'
BF_EXPAT_LIBPATH = '/usr/lib'
WITH_BF_JEMALLOC = False
WITH_BF_STATICJEMALLOC = False
BF_JEMALLOC = '/usr'
BF_JEMALLOC_INC = '${BF_JEMALLOC}/include'
BF_JEMALLOC_LIBPATH = '${BF_JEMALLOC}/lib'
BF_JEMALLOC_LIB = 'jemalloc'
BF_JEMALLOC_LIB_STATIC = '${BF_JEMALLOC_LIBPATH}/libjemalloc.a'
WITH_BF_OPENMP = True
#Ray trace optimization
WITH_BF_RAYOPTIMIZATION = True
BF_RAYOPTIMIZATION_SSE_FLAGS = ['-msse','-pthread']
#SpaceNavigator and friends
WITH_BF_3DMOUSE = True
BF_3DMOUSE = '/usr'
BF_3DMOUSE_INC = '${BF_3DMOUSE}/include'
BF_3DMOUSE_LIBPATH = '${BF_3DMOUSE}/lib'
BF_3DMOUSE_LIB = 'spnav'
BF_3DMOUSE_LIB_STATIC = '${BF_3DMOUSE_LIBPATH}/libspnav.a'
##
CC = 'gcc'
CXX = 'g++'
##ifeq ($CPU),alpha)
## CFLAGS += -pipe -fPIC -funsigned-char -fno-strict-aliasing -mieee
CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64']
CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64','-D_LARGEFILE64_SOURCE']
CPPFLAGS = []
CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64']
CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing','-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64','-D_LARGEFILE64_SOURCE']
# g++ 4.6, only needed for bullet
CXXFLAGS += ['-fpermissive']
if WITH_BF_FFMPEG:
# libavutil needs UINT64_C()
CXXFLAGS += ['-D__STDC_CONSTANT_MACROS', ]
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
REL_CFLAGS = ['-DNDEBUG', '-O2']
REL_CCFLAGS = ['-DNDEBUG', '-O2']
##BF_DEPEND = True
##
##AR = ar
##ARFLAGS = ruv
##ARFLAGSQUIET = ru
##
C_WARN = ['-Wno-char-subscripts', '-Wdeclaration-after-statement', '-Wunused-parameter', '-Werror=declaration-after-statement', '-Werror=implicit-function-declaration', '-Werror=return-type']
C_WARN = ['-Wno-char-subscripts', '-Wdeclaration-after-statement', '-Wunused-parameter', '-Wstrict-prototypes', '-Werror=declaration-after-statement', '-Werror=implicit-function-declaration', '-Werror=return-type']
CC_WARN = ['-Wall']
CXX_WARN = ['-Wno-invalid-offsetof', '-Wno-sign-compare']
@@ -220,10 +239,10 @@ BF_PROFILE_CCFLAGS = ['-pg','-g']
BF_PROFILE_LINKFLAGS = ['-pg']
BF_DEBUG = False
BF_DEBUG_CCFLAGS = ['-g', '-DDEBUG']
BF_DEBUG_CCFLAGS = ['-g', '-D_DEBUG']
BF_BUILDDIR = '../build/linux2'
BF_INSTALLDIR='../install/linux2'
BF_BUILDDIR = '../build/linux'
BF_INSTALLDIR='../install/linux'
#Link against pthread
PLATFORM_LINKFLAGS = ['-pthread']

View File

@@ -2,7 +2,7 @@ LCGDIR = '#../lib/windows'
LIBDIR = '${LCGDIR}'
BF_PYTHON = LIBDIR + '/python'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_BINARY = 'python'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION[0]}${BF_PYTHON_VERSION[2]}mw'
@@ -126,9 +126,10 @@ WITH_BF_BINRELOC = False
# enable ffmpeg support
WITH_BF_FFMPEG = True # -DWITH_FFMPEG
BF_FFMPEG = LIBDIR + '/ffmpeg'
BF_FFMPEG_LIB = 'avformat-52 avcodec-52 avdevice-52 avutil-50 swscale-0'
BF_FFMPEG_LIB = 'avformat-53 avcodec-53 avdevice-53 avutil-51 swscale-2'
BF_FFMPEG_INC = '${BF_FFMPEG}/include'
BF_FFMPEG_LIBPATH = '${BF_FFMPEG}/lib'
BF_FFMPEG_DLL = '${BF_FFMPEG_LIBPATH}/avformat-53.dll ${BF_FFMPEG_LIBPATH}/avcodec-53.dll ${BF_FFMPEG_LIBPATH}/avdevice-53.dll ${BF_FFMPEG_LIBPATH}/avutil-51.dll ${BF_FFMPEG_LIBPATH}/swscale-2.dll'
WITH_BF_OPENJPEG = True
BF_OPENJPEG = '#extern/libopenjpeg'
@@ -174,18 +175,20 @@ BF_RAYOPTIMIZATION_SSE_FLAGS = ['-msse']
CCFLAGS = [ '-pipe', '-funsigned-char', '-fno-strict-aliasing' ]
CPPFLAGS = ['-DWIN32', '-DFREE_WINDOWS']
CPPFLAGS = ['-DWIN32', '-DFREE_WINDOWS', '-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64', '-D_LARGEFILE64_SOURCE']
CXXFLAGS = ['-pipe', '-funsigned-char', '-fno-strict-aliasing' ]
REL_CFLAGS = [ '-O2' ]
REL_CCFLAGS = [ '-O2' ]
C_WARN = [ '-Wall' , '-Wno-char-subscripts', '-Wdeclaration-after-statement' ]
REL_CFLAGS = ['-DNDEBUG', '-O2']
REL_CCFLAGS = ['-DNDEBUG', '-O2']
C_WARN = ['-Wall', '-Wstrict-prototypes', '-Wno-char-subscripts', '-Wdeclaration-after-statement']
CC_WARN = [ '-Wall' ]
LLIBS = [ '-ldxguid', '-lgdi32', '-lmsvcrt', '-lwinmm', '-lmingw32', '-lm', '-lws2_32', '-lz', '-lstdc++', '-luuid', '-lole32'] #'-lutil', '-lc', '-lm', '-ldl', '-lpthread' ]
PLATFORM_LINKFLAGS = ['--stack,2097152']
BF_DEBUG = False
BF_DEBUG_CCFLAGS = ['-g', '-DDEBUG']
BF_DEBUG_CCFLAGS = ['-g', '-D_DEBUG']
BF_PROFILE = False
BF_PROFILE_CCFLAGS = ['-pg','-g']

View File

@@ -2,7 +2,7 @@ LCGDIR = '../lib/openbsd3'
LIBDIR = '${LCGDIR}'
BF_PYTHON = '/usr/local'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}'
@@ -122,8 +122,8 @@ CFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing']
CPPFLAGS = []
CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing']
CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing']
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
REL_CFLAGS = ['-DNDEBUG', '-O2']
REL_CCFLAGS = ['-DNDEBUG', '-O2']
##BF_DEPEND = True
##
##AR = ar
@@ -132,7 +132,7 @@ REL_CCFLAGS = ['-O2']
##
CC = 'gcc'
CXX = 'g++'
C_WARN = ['-Wdeclaration-after-statement']
C_WARN = ['-Wdeclaration-after-statement', '-Wstrict-prototypes']
CC_WARN = ['-Wall']
@@ -147,7 +147,7 @@ BF_PROFILE_CCFLAGS = ['-pg','-g']
BF_PROFILE_LINKFLAGS = ['-pg']
BF_DEBUG = False
BF_DEBUG_CCFLAGS = ['-g', '-DDEBUG']
BF_DEBUG_CCFLAGS = ['-g', '-D_DEBUG']
BF_BUILDDIR='../build/openbsd3'
BF_INSTALLDIR='../install/openbsd3'

View File

@@ -2,7 +2,7 @@ LCGDIR = '../lib/sunos5'
LIBDIR = '${LCGDIR}'
BF_PYTHON = '/usr/local'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_BINARY = '${BF_PYTHON}/bin/python${BF_PYTHON_VERSION}'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION}' #BF_PYTHON+'/lib/python'+BF_PYTHON_VERSION+'/config/libpython'+BF_PYTHON_VERSION+'.a'
@@ -138,8 +138,8 @@ CCFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing']
CPPFLAGS = ['-DSUN_OGL_NO_VERTEX_MACROS']
CXXFLAGS = ['-pipe','-fPIC','-funsigned-char','-fno-strict-aliasing']
REL_CFLAGS = ['-O2']
REL_CCFLAGS = ['-O2']
REL_CFLAGS = ['-DNDEBUG', '-O2']
REL_CCFLAGS = ['-DNDEBUG', '-O2']
##BF_DEPEND = True
##
##AR = ar
@@ -161,7 +161,7 @@ BF_PROFILE_LINKFLAGS = ['-pg']
BF_PROFILE = False
BF_DEBUG = False
BF_DEBUG_CCFLAGS = ['-DDEBUG']
BF_DEBUG_CCFLAGS = ['-D_DEBUG']
BF_BUILDDIR = '../build/sunos5'
BF_INSTALLDIR='../install/sunos5'

View File

@@ -2,12 +2,12 @@ LCGDIR = '#../lib/windows'
LIBDIR = "${LCGDIR}"
BF_PYTHON = LIBDIR + '/python'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
WITH_BF_STATICPYTHON = False
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_BINARY = 'python'
BF_PYTHON_LIB = 'python${BF_PYTHON_VERSION[0]}${BF_PYTHON_VERSION[2]}mw'
BF_PYTHON_DLL = 'python31'
BF_PYTHON_DLL = 'python32'
BF_PYTHON_LIBPATH = '${BF_PYTHON}/lib'
BF_PYTHON_LIB_STATIC = '${BF_PYTHON}/lib/libpython${BF_PYTHON_VERSION[0]}${BF_PYTHON_VERSION[2]}.a'
@@ -18,9 +18,10 @@ BF_OPENAL_LIB = 'wrap_oal'
BF_OPENAL_LIBPATH = '${BF_OPENAL}/lib'
WITH_BF_FFMPEG = False
BF_FFMPEG_LIB = 'avformat-52 avcodec-52 avdevice-52 avutil-50 swscale-0'
BF_FFMPEG_LIB = 'avformat-53 avcodec-53 avdevice-53 avutil-51 swscale-2'
BF_FFMPEG_LIBPATH = LIBDIR + '/ffmpeg/lib'
BF_FFMPEG_INC = LIBDIR + '/ffmpeg/include'
BF_FFMPEG_DLL = '${BF_FFMPEG_LIBPATH}/avformat-53.dll ${BF_FFMPEG_LIBPATH}/avcodec-53.dll ${BF_FFMPEG_LIBPATH}/avdevice-53.dll ${BF_FFMPEG_LIBPATH}/avutil-51.dll ${BF_FFMPEG_LIBPATH}/swscale-2.dll'
BF_LIBSAMPLERATE = LIBDIR + '/samplerate'
BF_LIBSAMPLERATE_INC = '${BF_LIBSAMPLERATE}/include'
@@ -50,7 +51,7 @@ BF_PTHREADS_INC = '${BF_PTHREADS}/include'
BF_PTHREADS_LIB = 'pthreadGC2'
BF_PTHREADS_LIBPATH = '${BF_PTHREADS}/lib'
WITH_BF_OPENEXR = True
WITH_BF_OPENEXR = False # TODO, gives linking problems for the moment.
WITH_BF_STATICOPENEXR = False
BF_OPENEXR = LIBDIR + '/gcc/openexr'
BF_OPENEXR_INC = '${BF_OPENEXR}/include ${BF_OPENEXR}/include/OpenEXR'
@@ -144,7 +145,7 @@ BF_OPENGL_LIB_STATIC = [ '${BF_OPENGL}/lib/libGL.a', '${BF_OPENGL}/lib/libGLU.a'
'${BF_OPENGL}/lib/libXmu.a', '${BF_OPENGL}/lib/libXext.a',
'${BF_OPENGL}/lib/libX11.a', '${BF_OPENGL}/lib/libXi.a' ]
WITH_BF_COLLADA = True
WITH_BF_COLLADA = False # TODO, gives linking problems at the moment.
BF_COLLADA = '#source/blender/collada'
BF_COLLADA_INC = '${BF_COLLADA}'
BF_COLLADA_LIB = 'bf_collada'
@@ -164,19 +165,21 @@ CXX = 'g++'
CCFLAGS = [ '-pipe', '-funsigned-char', '-fno-strict-aliasing' ]
CPPFLAGS = ['-DWIN32', '-DFREE_WINDOWS']
CXXFLAGS = ['-pipe', '-mwindows', '-funsigned-char', '-fno-strict-aliasing' ]
REL_CFLAGS = [ '-O2' ]
REL_CCFLAGS = [ '-O2' ]
CPPFLAGS = ['-DWIN32', '-DFREE_WINDOWS', '-D_LARGEFILE_SOURCE', '-D_FILE_OFFSET_BITS=64', '-D_LARGEFILE64_SOURCE']
CXXFLAGS = ['-pipe', '-funsigned-char', '-fno-strict-aliasing' ]
REL_CFLAGS = ['-DNDEBUG', '-O2']
REL_CCFLAGS = ['-DNDEBUG', '-O2']
C_WARN = [ '-Wno-char-subscripts', '-Wdeclaration-after-statement' ]
C_WARN = ['-Wno-char-subscripts', '-Wdeclaration-after-statement', '-Wstrict-prototypes']
CC_WARN = [ '-Wall' ]
LLIBS = ['-lshell32', '-lshfolder', '-lgdi32', '-lmsvcrt', '-lwinmm', '-lmingw32', '-lm', '-lws2_32', '-lz', '-lstdc++','-lole32','-luuid']
LLIBS = ['-lshell32', '-lshfolder', '-lgdi32', '-lmsvcrt', '-lwinmm', '-lmingw32', '-lm', '-lws2_32', '-lz', '-lstdc++','-lole32','-luuid', '-lwsock32']
PLATFORM_LINKFLAGS = ['--stack,2097152']
BF_DEBUG = False
BF_DEBUG_CCFLAGS= ['-g', '-DDEBUG']
BF_DEBUG_CCFLAGS= ['-g', '-D_DEBUG']
BF_PROFILE_CCFLAGS = ['-pg', '-g']
BF_PROFILE_LINKFLAGS = ['-pg']

View File

@@ -6,13 +6,14 @@ WITH_BF_FFMPEG = True # -DWITH_FFMPEG
BF_FFMPEG = LIBDIR +'/ffmpeg'
BF_FFMPEG_INC = '${BF_FFMPEG}/include ${BF_FFMPEG}/include/msvc'
BF_FFMPEG_LIBPATH='${BF_FFMPEG}/lib'
BF_FFMPEG_LIB = 'avformat-52.lib avcodec-52.lib avdevice-52.lib avutil-50.lib swscale-0.lib'
BF_FFMPEG_LIB = 'avformat-53.lib avcodec-53.lib avdevice-53.lib avutil-51.lib swscale-2.lib'
BF_FFMPEG_DLL = '${BF_FFMPEG_LIBPATH}/avformat-53.dll ${BF_FFMPEG_LIBPATH}/avcodec-53.dll ${BF_FFMPEG_LIBPATH}/avdevice-53.dll ${BF_FFMPEG_LIBPATH}/avutil-51.dll ${BF_FFMPEG_LIBPATH}/swscale-2.dll'
BF_PYTHON = LIBDIR + '/python'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_BINARY = 'python'
BF_PYTHON_LIB = 'python31'
BF_PYTHON_LIB = 'python32'
BF_PYTHON_DLL = '${BF_PYTHON_LIB}'
BF_PYTHON_LIBPATH = '${BF_PYTHON}/lib'
@@ -35,11 +36,11 @@ BF_LIBSAMPLERATE_LIBPATH = '${BF_LIBSAMPLERATE}/lib'
WITH_BF_JACK = False
BF_JACK = LIBDIR + '/jack'
BF_JACK_INC = '${BF_JACK}/include'
BF_JACK_INC = '${BF_JACK}/include ${BF_FFMPEG}/include/msvc'
BF_JACK_LIB = 'libjack'
BF_JACK_LIBPATH = '${BF_JACK}/lib'
WITH_BF_SNDFILE = False
WITH_BF_SNDFILE = True
BF_SNDFILE = LIBDIR + '/sndfile'
BF_SNDFILE_INC = '${BF_SNDFILE}/include'
BF_SNDFILE_LIB = 'libsndfile-1'
@@ -99,7 +100,7 @@ BF_GETTEXT_LIB = 'gnu_gettext'
BF_GETTEXT_LIBPATH = '${BF_GETTEXT}/lib'
WITH_BF_GAMEENGINE = True
WITH_BF_PLAYER = False
WITH_BF_PLAYER = True
WITH_BF_BULLET = True
BF_BULLET = '#extern/bullet2/src'
@@ -118,7 +119,7 @@ BF_FREETYPE_INC = '${BF_FREETYPE}/include ${BF_FREETYPE}/include/freetype2'
BF_FREETYPE_LIB = 'freetype2ST'
BF_FREETYPE_LIBPATH = '${BF_FREETYPE}/lib'
WITH_BF_QUICKTIME = True # -DWITH_QUICKTIME
WITH_BF_QUICKTIME = False # -DWITH_QUICKTIME
BF_QUICKTIME = LIBDIR + '/QTDevWin'
BF_QUICKTIME_INC = '${BF_QUICKTIME}/CIncludes'
BF_QUICKTIME_LIB = 'qtmlClient'
@@ -146,14 +147,10 @@ BF_COLLADA_LIB = 'bf_collada'
BF_OPENCOLLADA = LIBDIR + '/opencollada'
BF_OPENCOLLADA_INC = '${BF_OPENCOLLADA}/include'
BF_OPENCOLLADA_LIB = 'OpenCOLLADAStreamWriter OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils GeneratedSaxParser MathMLSolver xml2 pcre buffer ftoa'
BF_OPENCOLLADA_LIB = 'OpenCOLLADAStreamWriter OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils GeneratedSaxParser MathMLSolver xml2 pcre buffer ftoa UTF'
BF_OPENCOLLADA_LIBPATH = '${BF_OPENCOLLADA}/lib'
WITH_BF_LCMS = False
BF_LCMS = LIBDIR + '/lcms'
BF_LCMS_INC = '${BF_LCMS}/include'
BF_LCMS_LIB = 'lcms'
BF_LCMS_LIBPATH = '${BF_LCMS}/lib'
WITH_BF_3DMOUSE = True
#Ray trace optimization
WITH_BF_RAYOPTIMIZATION = True
@@ -176,7 +173,7 @@ BGE_CXXFLAGS = ['/O2', '/EHsc', '/GR', '/fp:fast', '/arch:SSE']
BF_DEBUG_CCFLAGS = ['/Zi', '/FR${TARGET}.sbr']
CPPFLAGS = ['-DWIN32','-D_CONSOLE', '-D_LIB', '-DFTGL_LIBRARY_STATIC', '-D_CRT_SECURE_NO_DEPRECATE']
CPPFLAGS = ['-DWIN32','-D_CONSOLE', '-D_LIB', '-D_CRT_SECURE_NO_DEPRECATE']
REL_CFLAGS = ['-O2', '-DNDEBUG']
REL_CCFLAGS = ['-O2', '-DNDEBUG']
REL_CXXFLAGS = ['-O2', '-DNDEBUG']
@@ -187,7 +184,7 @@ CXX_WARN = []
LLIBS = ['ws2_32', 'vfw32', 'winmm', 'kernel32', 'user32', 'gdi32', 'comdlg32', 'advapi32', 'shfolder', 'shell32', 'ole32', 'oleaut32', 'uuid']
PLATFORM_LINKFLAGS = ['/SUBSYSTEM:CONSOLE','/MACHINE:IX86','/INCREMENTAL:NO','/NODEFAULTLIB:"msvcprt.lib"','/NODEFAULTLIB:"msvcprtd.lib"','/NODEFAULTLIB:"glut32.lib"','/NODEFAULTLIB:"libc.lib"','/NODEFAULTLIB:"libcd.lib"','/NODEFAULTLIB:"libcpd.lib"','/NODEFAULTLIB:"libcp.lib"','/NODEFAULTLIB:"msvcrt.lib"', '/NODEFAULTLIB:"msvcrtd.lib"', '/NODEFAULTLIB:"msvcmrt.lib"', '/NODEFAULTLIB:"msvcurt.lib"', '/LARGEADDRESSAWARE']
PLATFORM_LINKFLAGS = ['/SUBSYSTEM:CONSOLE','/MACHINE:IX86','/STACK:2097152','/INCREMENTAL:NO', '/LARGEADDRESSAWARE', '/NODEFAULTLIB:msvcrt.lib', '/NODEFAULTLIB:msvcmrt.lib', '/NODEFAULTLIB:msvcurt.lib', '/NODEFAULTLIB:msvcrtd.lib']
# # Todo
# BF_PROFILE_CCFLAGS = ['-pg', '-g ']

View File

@@ -6,13 +6,14 @@ WITH_BF_FFMPEG = True # -DWITH_FFMPEG
BF_FFMPEG = LIBDIR +'/ffmpeg'
BF_FFMPEG_INC = '${BF_FFMPEG}/include ${BF_FFMPEG}/include/msvc '
BF_FFMPEG_LIBPATH='${BF_FFMPEG}/lib'
BF_FFMPEG_LIB = 'avformat-52.lib avcodec-52.lib avdevice-52.lib avutil-50.lib swscale-0.lib'
BF_FFMPEG_LIB = 'avformat-53.lib avcodec-53.lib avdevice-53.lib avutil-51.lib swscale-2.lib'
BF_FFMPEG_DLL = '${BF_FFMPEG_LIBPATH}/avformat-53.dll ${BF_FFMPEG_LIBPATH}/avcodec-53.dll ${BF_FFMPEG_LIBPATH}/avdevice-53.dll ${BF_FFMPEG_LIBPATH}/avutil-51.dll ${BF_FFMPEG_LIBPATH}/swscale-2.dll'
BF_PYTHON = LIBDIR + '/python'
BF_PYTHON_VERSION = '3.1'
BF_PYTHON_VERSION = '3.2'
BF_PYTHON_INC = '${BF_PYTHON}/include/python${BF_PYTHON_VERSION}'
BF_PYTHON_BINARY = 'python'
BF_PYTHON_LIB = 'python31'
BF_PYTHON_LIB = 'python32'
BF_PYTHON_DLL = '${BF_PYTHON_LIB}'
BF_PYTHON_LIBPATH = '${BF_PYTHON}/lib'
@@ -22,6 +23,12 @@ BF_OPENAL_INC = '${BF_OPENAL}/include '
BF_OPENAL_LIB = 'wrap_oal'
BF_OPENAL_LIBPATH = '${BF_OPENAL}/lib'
WITH_BF_SNDFILE = True
BF_SNDFILE = LIBDIR + '/sndfile'
BF_SNDFILE_INC = '${BF_SNDFILE}/include'
BF_SNDFILE_LIB = 'libsndfile-1'
BF_SNDFILE_LIBPATH = '${BF_SNDFILE}/lib'
# TODO - are these useful on win32?
# BF_CXX = '/usr'
# WITH_BF_STATICCXX = False
@@ -44,6 +51,8 @@ BF_SDL_INC = '${BF_SDL}/include'
BF_SDL_LIB = 'SDL.lib'
BF_SDL_LIBPATH = '${BF_SDL}/lib'
WITH_BF_JACK = False
BF_PTHREADS = LIBDIR + '/pthreads'
BF_PTHREADS_INC = '${BF_PTHREADS}/include'
BF_PTHREADS_LIB = 'pthreadVC2'
@@ -95,7 +104,7 @@ BF_GETTEXT_LIB = 'gettext'
BF_GETTEXT_LIBPATH = '${BF_GETTEXT}/lib'
WITH_BF_GAMEENGINE = True
WITH_BF_PLAYER = False
WITH_BF_PLAYER = True
WITH_BF_BULLET = True
BF_BULLET = '#extern/bullet2/src'
@@ -142,14 +151,10 @@ BF_COLLADA_LIB = 'bf_collada'
BF_OPENCOLLADA = LIBDIR + '/opencollada'
BF_OPENCOLLADA_INC = '${BF_OPENCOLLADA}/include'
BF_OPENCOLLADA_LIB = 'OpenCOLLADAStreamWriter OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils GeneratedSaxParser MathMLSolver xml2 pcre buffer ftoa'
BF_OPENCOLLADA_LIB = 'OpenCOLLADAStreamWriter OpenCOLLADASaxFrameworkLoader OpenCOLLADAFramework OpenCOLLADABaseUtils GeneratedSaxParser MathMLSolver xml2 pcre buffer ftoa UTF'
BF_OPENCOLLADA_LIBPATH = '${BF_OPENCOLLADA}/lib'
WITH_BF_LCMS = False
BF_LCMS = LIBDIR + '/lcms'
BF_LCMS_INC = '${BF_LCMS}/include'
BF_LCMS_LIB = 'lcms'
BF_LCMS_LIBPATH = '${BF_LCMS}/lib'
WITH_BF_3DMOUSE = True
#Ray trace optimization
WITH_BF_RAYOPTIMIZATION = True
@@ -170,9 +175,9 @@ CCFLAGS = ['/nologo', '/Ob1', '/J', '/W0', '/Gd', '/we4013', '/wd4018', '/wd4244
CXXFLAGS = ['/EHsc']
BGE_CXXFLAGS = ['/O2', '/EHsc', '/GR', '/fp:fast']
BF_DEBUG_CCFLAGS = ['/Zi', '/FR${TARGET}.sbr']
BF_DEBUG_CCFLAGS = ['/Zi', '/FR${TARGET}.sbr', '/Od']
CPPFLAGS = ['-DWIN32', '-D_CONSOLE', '-D_LIB', '-DFTGL_LIBRARY_STATIC', '-D_CRT_SECURE_NO_DEPRECATE']
CPPFLAGS = ['-DWIN32', '-D_CONSOLE', '-D_LIB', '-D_CRT_SECURE_NO_DEPRECATE']
REL_CFLAGS = ['-O2', '-DNDEBUG']
REL_CCFLAGS = ['-O2', '-DNDEBUG']
REL_CXXFLAGS = ['-O2', '-DNDEBUG']
@@ -188,7 +193,7 @@ if BF_DEBUG:
else:
BF_NUMJOBS=6
PLATFORM_LINKFLAGS = ['/SUBSYSTEM:CONSOLE','/MACHINE:X64','/INCREMENTAL:NO','/NODEFAULTLIB:"msvcprt.lib"','/NODEFAULTLIB:"msvcprtd.lib"','/NODEFAULTLIB:"glut32.lib"','/NODEFAULTLIB:"libc.lib"','/NODEFAULTLIB:"libcd.lib"','/NODEFAULTLIB:"libcpd.lib"','/NODEFAULTLIB:"libcp.lib"','/NODEFAULTLIB:"msvcrt.lib"', '/NODEFAULTLIB:"msvcrtd.lib"', '/NODEFAULTLIB:"msvcmrt.lib"', '/NODEFAULTLIB:"msvcurt.lib"']
PLATFORM_LINKFLAGS = ['/SUBSYSTEM:CONSOLE','/MACHINE:X64','/STACK:2097152','/OPT:NOREF','/INCREMENTAL:NO', '/NODEFAULTLIB:msvcrt.lib', '/NODEFAULTLIB:msvcmrt.lib', '/NODEFAULTLIB:msvcurt.lib', '/NODEFAULTLIB:msvcrtd.lib']
BF_BUILDDIR = '..\\build\\blender25-win64-vc'
BF_INSTALLDIR='..\\install\\blender25-win64-vc'

View File

@@ -20,7 +20,7 @@ import string
import glob
import time
import sys
import zipfile
import tarfile
import shutil
import cStringIO
import platform
@@ -148,8 +148,6 @@ def setup_staticlibs(lenv):
libincs += Split(lenv['BF_OPENEXR_LIBPATH'])
if lenv['WITH_BF_STATICOPENEXR']:
statlibs += Split(lenv['BF_OPENEXR_LIB_STATIC'])
if lenv['WITH_BF_LCMS']:
libincs += Split(lenv['BF_LCMS_LIBPATH'])
if lenv['WITH_BF_TIFF']:
libincs += Split(lenv['BF_TIFF_LIBPATH'])
if lenv['WITH_BF_STATICTIFF']:
@@ -203,6 +201,17 @@ def setup_staticlibs(lenv):
if lenv['OURPLATFORM'] not in ('win32-vc', 'win32-mingw', 'win64-vc', 'linuxcross'):
libincs.append('/usr/lib')
if lenv['WITH_BF_JEMALLOC']:
libincs += Split(lenv['BF_JEMALLOC_LIBPATH'])
if lenv['WITH_BF_STATICJEMALLOC']:
statlibs += Split(lenv['BF_JEMALLOC_LIB_STATIC'])
if lenv['OURPLATFORM']=='linux':
if lenv['WITH_BF_3DMOUSE']:
libincs += Split(lenv['BF_3DMOUSE_LIBPATH'])
if lenv['WITH_BF_STATIC3DMOUSE']:
statlibs += Split(lenv['BF_3DMOUSE_LIB_STATIC'])
return statlibs, libincs
def setup_syslibs(lenv):
@@ -253,16 +262,25 @@ def setup_syslibs(lenv):
syslibs += Split(lenv['BF_OPENGL_LIB'])
if lenv['OURPLATFORM'] in ('win32-vc', 'win32-mingw','linuxcross', 'win64-vc'):
syslibs += Split(lenv['BF_PTHREADS_LIB'])
if lenv['WITH_BF_LCMS']:
syslibs.append(lenv['BF_LCMS_LIB'])
if lenv['WITH_BF_COLLADA']:
syslibs.append(lenv['BF_PCRE_LIB'])
syslibs += Split(lenv['BF_OPENCOLLADA_LIB'])
if lenv['BF_DEBUG']:
syslibs += [colladalib+'_d' for colladalib in Split(lenv['BF_OPENCOLLADA_LIB'])]
else:
syslibs += Split(lenv['BF_OPENCOLLADA_LIB'])
syslibs.append(lenv['BF_EXPAT_LIB'])
if not lenv['WITH_BF_STATICLIBSAMPLERATE']:
syslibs += Split(lenv['BF_LIBSAMPLERATE_LIB'])
if lenv['WITH_BF_JEMALLOC']:
if not lenv['WITH_BF_STATICJEMALLOC']:
syslibs += Split(lenv['BF_JEMALLOC_LIB'])
if lenv['OURPLATFORM']=='linux':
if lenv['WITH_BF_3DMOUSE']:
if not lenv['WITH_BF_STATIC3DMOUSE']:
syslibs += Split(lenv['BF_3DMOUSE_LIB'])
syslibs += lenv['LLIBS']
@@ -283,6 +301,46 @@ def propose_priorities():
print "\t\t",new_priority, v
new_priority += 5
# emits the necessary file objects for creator.c, to be used in creating
# the final blender executable
def creator(env):
sources = ['creator.c']# + Blender.buildinfo(env, "dynamic") + Blender.resources
incs = ['#/intern/guardedalloc', '#/source/blender/blenlib', '#/source/blender/blenkernel', '#/source/blender/editors/include', '#/source/blender/blenloader', '#/source/blender/imbuf', '#/source/blender/renderconverter', '#/source/blender/render/extern/include', '#/source/blender/windowmanager', '#/source/blender/makesdna', '#/source/blender/makesrna', '#/source/gameengine/BlenderRoutines', '#/extern/glew/include', '#/source/blender/gpu', env['BF_OPENGL_INC']]
defs = []
if env['WITH_BF_QUICKTIME']:
incs.append(env['BF_QUICKTIME_INC'])
defs.append('WITH_QUICKTIME')
if env['WITH_BF_BINRELOC']:
incs.append('#/extern/binreloc/include')
defs.append('WITH_BINRELOC')
if env['WITH_BF_OPENEXR']:
defs.append('WITH_OPENEXR')
if env['WITH_BF_TIFF']:
defs.append('WITH_TIFF')
if not env['WITH_BF_SDL']:
defs.append('DISABLE_SDL')
if env['WITH_BF_PYTHON']:
incs.append('#/source/blender/python')
defs.append('WITH_PYTHON')
if env['BF_DEBUG']:
defs.append('_DEBUG')
if env['OURPLATFORM'] in ('win32-vc', 'win32-mingw', 'linuxcross', 'win64-vc'):
incs.append(env['BF_PTHREADS_INC'])
env.Append(CPPDEFINES=defs)
env.Append(CPPPATH=incs)
obj = [env.Object(root_build_dir+'source/creator/creator/creator', ['#source/creator/creator.c'])]
return obj
## TODO: see if this can be made in an emitter
def buildinfo(lenv, build_type):
"""
@@ -306,21 +364,21 @@ def buildinfo(lenv, build_type):
obj = []
if lenv['BF_BUILDINFO']:
lenv.Append (CPPDEFINES = ['BUILD_TIME="%s"'%(build_time),
'BUILD_DATE="%s"'%(build_date),
'BUILD_TYPE="%s"'%(build_type),
'BUILD_REV="%s"'%(build_rev),
'NAN_BUILDINFO',
'BUILD_PLATFORM="%s:%s"'%(platform.system(), platform.architecture()[0]),
lenv.Append (CPPDEFINES = ['BUILD_TIME=\\"%s\\"'%(build_time),
'BUILD_DATE=\\"%s\\"'%(build_date),
'BUILD_TYPE=\\"%s\\"'%(build_type),
'BUILD_REV=\\"%s\\"'%(build_rev),
'WITH_BUILDINFO',
'BUILD_PLATFORM=\\"%s:%s\\"'%(platform.system(), platform.architecture()[0]),
'BUILD_CFLAGS=\\"%s\\"'%(build_cflags),
'BUILD_CXXFLAGS=\\"%s\\"'%(build_cxxflags),
'BUILD_LINKFLAGS=\\"%s\\"'%(build_linkflags),
'BUILD_SYSTEM="SCons"'
'BUILD_SYSTEM=\\"SCons\\"'
])
lenv.Append (CPPPATH = [root_build_dir+'source/blender/blenkernel'])
obj = [lenv.Object (root_build_dir+'source/creator/%s_buildinfo'%build_type, [root_build_dir+'source/creator/buildinfo.c'])]
obj = [lenv.Object (root_build_dir+'source/creator/%s_buildinfo'%build_type, ['#source/creator/buildinfo.c'])]
return obj
@@ -399,89 +457,13 @@ def set_quiet_output(env):
if env['BF_LINE_OVERWRITE']:
SCons.Action._ActionAction.print_cmd_line = my_print_cmd_line
class CompZipFile(zipfile.ZipFile):
"""Partial copy of python2.6's zipfile.ZipFile (see http://www.python.org)
to get a extractall() that works on py2.5 and probably earlier distributions."""
def __init__(self, file, mode="r", compression=zipfile.ZIP_STORED, allowZip64=False):
if sys.version_info < (2, 6):
zipfile.ZipFile.__init__(self, file, mode, compression)
else:
zipfile.ZipFile.__init__(self, file, mode, compression, allowZip64)
if not hasattr(self,"extractall"): # use our method
print "Debug: Using comp_extractall!"
self.extractall= self.comp_extractall
def comp_extractall(self, path=None, members=None, pwd=None): #renamed method
"""Extract all members from the archive to the current working
directory. `path' specifies a different directory to extract to.
`members' is optional and must be a subset of the list returned
by namelist().
"""
if members is None:
members = self.namelist()
for zipinfo in members:
self.comp_extract(zipinfo, path, pwd) # use our method
def comp_extract(self, member, path=None, pwd=None): #renamed method
"""Extract a member from the archive to the current working directory,
using its full name. Its file information is extracted as accurately
as possible. `member' may be a filename or a ZipInfo object. You can
specify a different directory using `path'.
"""
if not isinstance(member, zipfile.ZipInfo):
member = self.getinfo(member)
if path is None:
path = os.getcwd()
return self.comp_extract_member(member, path, pwd) # use our method
def comp_extract_member(self, member, targetpath, pwd): #renamed method
"""Extract the ZipInfo object 'member' to a physical
file on the path targetpath.
"""
# build the destination pathname, replacing
# forward slashes to platform specific separators.
if targetpath[-1:] in (os.path.sep, os.path.altsep):
targetpath = targetpath[:-1]
# don't include leading "/" from file name if present
if member.filename[0] == '/':
targetpath = os.path.join(targetpath, member.filename[1:])
else:
targetpath = os.path.join(targetpath, member.filename)
targetpath = os.path.normpath(targetpath)
# Create all upper directories if necessary.
upperdirs = os.path.dirname(targetpath)
if upperdirs and not os.path.exists(upperdirs):
os.makedirs(upperdirs)
if member.filename[-1] == '/':
os.mkdir(targetpath)
return targetpath
#use StrinIO instead so we don't have to reproduce more functionality.
source = cStringIO.StringIO(self.read(member.filename))
target = file(targetpath, "wb")
shutil.copyfileobj(source, target)
source.close()
target.close()
return targetpath
def unzip_pybundle(from_zip,to_dir,exclude_re):
zip= CompZipFile(from_zip, mode='r')
def untar_pybundle(from_tar,to_dir,exclude_re):
tar= tarfile.open(from_tar, mode='r')
exclude_re= list(exclude_re) #single re object or list of re objects
debug= 0 #list files instead of unpacking
good= []
if debug: print '\nFiles not being unpacked:\n'
for name in zip.namelist():
for name in tar.getnames():
is_bad= 0
for r in exclude_re:
if r.match(name):
@@ -489,26 +471,26 @@ def unzip_pybundle(from_zip,to_dir,exclude_re):
if debug: print name
break
if not is_bad:
good.append(name)
good.append(tar.getmember(name))
if debug:
print '\nFiles being unpacked:\n'
for g in good:
print g
else:
zip.extractall(to_dir, good)
tar.extractall(to_dir, good)
def my_winpybundle_print(target, source, env):
pass
def WinPyBundle(target=None, source=None, env=None):
import re
py_zip= env.subst( env['LCGDIR'] )
if py_zip[0]=='#':
py_zip= py_zip[1:]
py_tar= env.subst( env['LCGDIR'] )
if py_tar[0]=='#':
py_tar= py_tar[1:]
if env['BF_DEBUG']:
py_zip+= '/release/python' + env['BF_PYTHON_VERSION'].replace('.','') + '_d.zip'
py_tar+= '/release/python' + env['BF_PYTHON_VERSION'].replace('.','') + '_d.tar.gz'
else:
py_zip+= '/release/python' + env['BF_PYTHON_VERSION'].replace('.','') + '.zip'
py_tar+= '/release/python' + env['BF_PYTHON_VERSION'].replace('.','') + '.tar.gz'
py_target = env.subst( env['BF_INSTALLDIR'] )
if py_target[0]=='#':
@@ -521,12 +503,18 @@ def WinPyBundle(target=None, source=None, env=None):
shutil.rmtree(py_target, False, printexception)
exclude_re=[re.compile('.*/test/.*'),
re.compile('^config/.*'),
re.compile('^config-*/.*'),
re.compile('^distutils/.*'),
re.compile('^idlelib/.*'),
re.compile('^lib2to3/.*'),
re.compile('^tkinter/.*')]
print "Unpacking '" + py_zip + "' to '" + py_target + "'"
unzip_pybundle(py_zip,py_target,exclude_re)
re.compile('^tkinter/.*'),
re.compile('^_tkinter_d.pyd'),
re.compile('^turtledemo'),
re.compile('^turtle.py'),
]
print "Unpacking '" + py_tar + "' to '" + py_target + "'"
untar_pybundle(py_tar,py_target,exclude_re)
def my_appit_print(target, source, env):
a = '%s' % (target[0])
@@ -546,8 +534,12 @@ def AppIt(target=None, source=None, env=None):
installdir = env['BF_INSTALLDIR']
print("compiled architecture: %s"%(osxarch))
print("Installing to %s"%(installdir))
# TODO, use tar.
python_zip = 'python_' + osxarch + '.zip' # set specific python_arch.zip
print("unzipping to app-bundle: %s"%(python_zip))
if env['WITH_OSX_STATICPYTHON']:
print("unzipping to app-bundle: %s"%(python_zip))
else:
print("dynamic build - make sure to have python3.x-framework installed")
bldroot = env.Dir('.').abspath
binary = env['BINARYKIND']
@@ -563,7 +555,8 @@ def AppIt(target=None, source=None, env=None):
if os.path.isdir(cmd):
shutil.rmtree(cmd)
shutil.copytree(sourcedir, cmd)
cmd = "cat %s | sed s/VERSION/`cat release/VERSION`/ | sed s/DATE/`date +'%%Y-%%b-%%d'`/ > %s"%(sourceinfo,targetinfo)
cmd = "cat %s | sed s/\$\{MACOSX_BUNDLE_SHORT_VERSION_STRING\}/%s/ | "%(sourceinfo,VERSION)
cmd += "sed s/\$\{MACOSX_BUNDLE_LONG_VERSION_STRING\}/%s,\ %s/g > %s"%(VERSION,time.strftime("%Y-%b-%d"),targetinfo)
commands.getoutput(cmd)
cmd = 'cp %s/%s %s/%s.app/Contents/MacOS/%s'%(builddir, binary,installdir, binary, binary)
commands.getoutput(cmd)
@@ -579,16 +572,20 @@ def AppIt(target=None, source=None, env=None):
commands.getoutput(cmd)
cmd = 'cp %s/release/bin/%s/.Blanguages %s/%s.app/Contents/Resources/'%(bldroot,VERSION,installdir,binary)
commands.getoutput(cmd)
cmd = 'mkdir %s/%s.app/Contents/MacOS/%s/python/'%(installdir,binary, VERSION)
commands.getoutput(cmd)
cmd = 'unzip -q %s/release/%s -d %s/%s.app/Contents/MacOS/%s/python/'%(libdir,python_zip,installdir,binary,VERSION)
commands.getoutput(cmd)
cmd = 'cp -R %s/release/scripts %s/%s.app/Contents/MacOS/%s/'%(bldroot,installdir,binary,VERSION)
commands.getoutput(cmd)
cmd = 'cp -R %s/release/ui %s/%s.app/Contents/MacOS/%s/'%(bldroot,installdir,binary,VERSION)
commands.getoutput(cmd)
cmd = 'cp -R %s/release/io %s/%s.app/Contents/MacOS/%s/'%(bldroot,installdir,binary,VERSION)
commands.getoutput(cmd)
if env['WITH_OSX_STATICPYTHON']:
cmd = 'mkdir %s/%s.app/Contents/MacOS/%s/python/'%(installdir,binary, VERSION)
commands.getoutput(cmd)
cmd = 'unzip -q %s/release/%s -d %s/%s.app/Contents/MacOS/%s/python/'%(libdir,python_zip,installdir,binary,VERSION)
commands.getoutput(cmd)
if binary == 'blender':#not copy everything for blenderplayer
cmd = 'cp -R %s/release/scripts %s/%s.app/Contents/MacOS/%s/'%(bldroot,installdir,binary,VERSION)
commands.getoutput(cmd)
cmd = 'cp -R %s/release/ui %s/%s.app/Contents/MacOS/%s/'%(bldroot,installdir,binary,VERSION)
commands.getoutput(cmd)
cmd = 'cp -R %s/release/io %s/%s.app/Contents/MacOS/%s/'%(bldroot,installdir,binary,VERSION)
commands.getoutput(cmd)
cmd = 'chmod +x %s/%s.app/Contents/MacOS/%s'%(installdir,binary, binary)
commands.getoutput(cmd)
cmd = 'find %s/%s.app -name .svn -prune -exec rm -rf {} \;'%(installdir, binary)
@@ -624,31 +621,36 @@ def UnixPyBundle(target=None, source=None, env=None):
print '\t"%s"' % py_target
print '\t(skipping copy)\n'
return
# Copied from source/creator/CMakeLists.txt, keep in sync.
print 'Install python from:'
print '\t"%s" into...' % py_src
print '\t"%s"\n' % py_target
run('rm -rf "%s"' % py_target)
try: os.makedirs(os.path.dirname(py_target)) # the final part is copied
except:pass
run('cp -R "%s" "%s"' % (py_src, os.path.dirname(py_target)))
run('rm -rf "%s/distutils"' % py_target)
run('rm -rf "%s/lib2to3"' % py_target)
run('rm -rf "%s/idlelib"' % py_target)
run('rm -rf "%s/tkinter"' % py_target)
run('rm -rf "%s/config"' % py_target)
print '\t"%s" into...' % py_src
print '\t"%s"\n' % py_target
run('rm -rf "%s/site-packages"' % py_target)
run('mkdir "%s/site-packages"' % py_target) # python needs it.'
run("rm -rf '%s'" % py_target)
try:
os.makedirs(os.path.dirname(py_target)) # the final part is copied
except:
pass
run('rm -f "%s/lib-dynload/_tkinter.so"' % py_target)
run('find "%s" -name "test" -prune -exec rm -rf {} \;' % py_target)
run('find "%s" -name "*.py?" -exec rm -rf {} \;' % py_target)
run('find "%s" -name "*.so"-exec strip -s {} \;' % py_target)
run("cp -R '%s' '%s'" % (py_src, os.path.dirname(py_target)))
run("rm -rf '%s/distutils'" % py_target)
run("rm -rf '%s/lib2to3'" % py_target)
run("rm -rf '%s/config'" % py_target)
run("rm -rf '%s/config-*'" % py_target)
run("rm -rf '%s/site-packages'" % py_target)
run("mkdir '%s/site-packages'" % py_target) # python needs it.'
run("rm -rf '%s/idlelib'" % py_target)
run("rm -rf '%s/tkinter'" % py_target)
run("rm -rf '%s/turtledemo'" % py_target)
run("rm -r '%s/turtle.py'" % py_target)
run("rm -f '%s/lib-dynload/_tkinter.so'" % py_target)
run("find '%s' -type d -name 'test' -prune -exec rm -rf {} ';'" % py_target)
run("find '%s' -type d -name '__pycache__' -exec rm -rf {} ';'" % py_target)
run("find '%s' -name '*.py[co]' -exec rm -rf {} ';'" % py_target)
run("find '%s' -name '*.so' -exec strip -s {} ';'" % py_target)
#### END ACTION STUFF #########
@@ -675,6 +677,8 @@ def bsc(env, target, source):
class BlenderEnvironment(SConsEnvironment):
PyBundleActionAdded = False
def BlenderRes(self=None, libname=None, source=None, libtype=['core'], priority=[100]):
global libs
if not self or not libname or not source:
@@ -771,23 +775,19 @@ class BlenderEnvironment(SConsEnvironment):
global vcp
print bc.HEADER+'Configuring program '+bc.ENDC+bc.OKGREEN+progname+bc.ENDC
lenv = self.Clone()
lenv.Append(LINKFLAGS = lenv['PLATFORM_LINKFLAGS'])
if lenv['OURPLATFORM'] in ('win32-vc', 'cygwin', 'win64-vc'):
lenv.Append(LINKFLAGS = lenv['PLATFORM_LINKFLAGS'])
lenv.Append(LINKFLAGS = ['/FORCE:MULTIPLE'])
if lenv['BF_DEBUG']:
lenv.Prepend(LINKFLAGS = ['/DEBUG','/PDB:'+progname+'.pdb'])
if lenv['OURPLATFORM']=='linux2':
lenv.Append(LINKFLAGS = lenv['PLATFORM_LINKFLAGS'])
lenv.Prepend(LINKFLAGS = ['/DEBUG','/PDB:'+progname+'.pdb','/NODEFAULTLIB:libcmt'])
if lenv['OURPLATFORM']=='linux':
if lenv['WITH_BF_PYTHON']:
lenv.Append(LINKFLAGS = lenv['BF_PYTHON_LINKFLAGS'])
if lenv['OURPLATFORM']=='sunos5':
lenv.Append(LINKFLAGS = lenv['PLATFORM_LINKFLAGS'])
if lenv['WITH_BF_PYTHON']:
lenv.Append(LINKFLAGS = lenv['BF_PYTHON_LINKFLAGS'])
if lenv['CXX'].endswith('CC'):
lenv.Replace(LINK = '$CXX')
if lenv['OURPLATFORM']=='darwin':
lenv.Append(LINKFLAGS = lenv['PLATFORM_LINKFLAGS'])
if lenv['WITH_BF_PYTHON']:
lenv.Append(LINKFLAGS = lenv['BF_PYTHON_LINKFLAGS'])
lenv.Append(LINKFLAGS = lenv['BF_OPENGL_LINKFLAGS'])
@@ -818,12 +818,14 @@ class BlenderEnvironment(SConsEnvironment):
lenv.AddPostAction(prog,Action(AppIt,strfunction=my_appit_print))
elif os.sep == '/' and lenv['OURPLATFORM'] != 'linuxcross': # any unix (except cross-compilation)
if lenv['WITH_BF_PYTHON']:
if not lenv['WITHOUT_BF_INSTALL'] and not lenv['WITHOUT_BF_PYTHON_INSTALL']:
if not lenv['WITHOUT_BF_INSTALL'] and not lenv['WITHOUT_BF_PYTHON_INSTALL'] and not BlenderEnvironment.PyBundleActionAdded:
lenv.AddPostAction(prog,Action(UnixPyBundle,strfunction=my_unixpybundle_print))
BlenderEnvironment.PyBundleActionAdded = True
elif lenv['OURPLATFORM'].startswith('win') or lenv['OURPLATFORM'] == 'linuxcross': # windows or cross-compilation
if lenv['WITH_BF_PYTHON']:
if not lenv['WITHOUT_BF_PYTHON_INSTALL']:
if not lenv['WITHOUT_BF_PYTHON_INSTALL'] and not BlenderEnvironment.PyBundleActionAdded:
lenv.AddPostAction(prog,Action(WinPyBundle,strfunction=my_winpybundle_print))
BlenderEnvironment.PyBundleActionAdded = True
return prog
def Glob(lenv, pattern):

View File

@@ -16,14 +16,56 @@ Variables = SCons.Variables
BoolVariable = SCons.Variables.BoolVariable
def get_version():
import re
fname = os.path.join(os.path.dirname(__file__), "..", "..", "..", "source", "blender", "blenkernel", "BKE_blender.h")
ver_base = None
ver_char = None
ver_cycle = None
re_ver = re.compile("^#\s*define\s+BLENDER_VERSION\s+([0-9]+)")
re_ver_char = re.compile("^#\s*define\s+BLENDER_VERSION_CHAR\s*(\S*)") # optional arg
re_ver_cycle = re.compile("^#\s*define\s+BLENDER_VERSION_CYCLE\s*(\S*)") # optional arg
for l in open(fname, "r"):
if "BLENDER_VERSION" in l:
ver = int(l.split()[-1])
return "%d.%d" % (ver / 100, ver % 100)
match = re_ver.match(l)
if match:
ver = int(match.group(1))
ver_base = "%d.%d" % (ver / 100, ver % 100)
match = re_ver_char.match(l)
if match:
ver_char = match.group(1)
if ver_char == "BLENDER_CHAR_VERSION":
ver_char = ""
match = re_ver_cycle.match(l)
if match:
ver_cycle = match.group(1)
if ver_cycle == "BLENDER_CYCLE_VERSION":
ver_cycle = ""
if (ver_base is not None) and (ver_char is not None) and (ver_cycle is not None):
# eg '2.56a-beta'
if ver_cycle:
ver_display = "%s%s-%s" % (ver_base, ver_char, ver_cycle)
else:
ver_display = "%s%s" % (ver_base, ver_char) # assume release
return ver_base, ver_display
raise Exception("%s: missing version string" % fname)
VERSION = get_version() # This is used in creating the local config directories
def get_revision():
build_rev = os.popen('svnversion').read()[:-1] # remove \n
if build_rev == '' or build_rev==None:
build_rev = 'UNKNOWN'
return 'r' + build_rev
# This is used in creating the local config directories
VERSION, VERSION_DISPLAY = get_version()
REVISION = get_revision()
def print_arguments(args, bc):
if len(args):
@@ -36,7 +78,7 @@ def print_arguments(args, bc):
def validate_arguments(args, bc):
opts_list = [
'WITH_BF_PYTHON', 'BF_PYTHON', 'BF_PYTHON_VERSION', 'BF_PYTHON_INC', 'BF_PYTHON_BINARY', 'BF_PYTHON_LIB', 'BF_PYTHON_LIBPATH', 'WITH_BF_STATICPYTHON', 'BF_PYTHON_LIB_STATIC', 'BF_PYTHON_DLL',
'WITH_BF_PYTHON', 'WITH_BF_PYTHON_SAFETY', 'BF_PYTHON', 'BF_PYTHON_VERSION', 'BF_PYTHON_INC', 'BF_PYTHON_BINARY', 'BF_PYTHON_LIB', 'BF_PYTHON_LIBPATH', 'WITH_BF_STATICPYTHON', 'WITH_OSX_STATICPYTHON', 'BF_PYTHON_LIB_STATIC', 'BF_PYTHON_DLL', 'BF_PYTHON_ABI_FLAGS',
'WITH_BF_OPENAL', 'BF_OPENAL', 'BF_OPENAL_INC', 'BF_OPENAL_LIB', 'BF_OPENAL_LIBPATH', 'WITH_BF_STATICOPENAL', 'BF_OPENAL_LIB_STATIC',
'WITH_BF_SDL', 'BF_SDL', 'BF_SDL_INC', 'BF_SDL_LIB', 'BF_SDL_LIBPATH',
'BF_LIBSAMPLERATE', 'BF_LIBSAMPLERATE_INC', 'BF_LIBSAMPLERATE_LIB', 'BF_LIBSAMPLERATE_LIBPATH', 'WITH_BF_STATICLIBSAMPLERATE', 'BF_LIBSAMPLERATE_LIB_STATIC',
@@ -45,7 +87,7 @@ def validate_arguments(args, bc):
'BF_PTHREADS', 'BF_PTHREADS_INC', 'BF_PTHREADS_LIB', 'BF_PTHREADS_LIBPATH',
'WITH_BF_OPENEXR', 'BF_OPENEXR', 'BF_OPENEXR_INC', 'BF_OPENEXR_LIB', 'BF_OPENEXR_LIBPATH', 'WITH_BF_STATICOPENEXR', 'BF_OPENEXR_LIB_STATIC',
'WITH_BF_DDS', 'WITH_BF_CINEON', 'WITH_BF_HDR',
'WITH_BF_FFMPEG', 'BF_FFMPEG_LIB','BF_FFMPEG_EXTRA', 'BF_FFMPEG', 'BF_FFMPEG_INC',
'WITH_BF_FFMPEG', 'BF_FFMPEG_LIB','BF_FFMPEG_EXTRA', 'BF_FFMPEG', 'BF_FFMPEG_INC', 'BF_FFMPEG_DLL',
'WITH_BF_STATICFFMPEG', 'BF_FFMPEG_LIB_STATIC',
'WITH_BF_OGG', 'BF_OGG', 'BF_OGG_LIB',
'WITH_BF_JPEG', 'BF_JPEG', 'BF_JPEG_INC', 'BF_JPEG_LIB', 'BF_JPEG_LIBPATH',
@@ -57,7 +99,7 @@ def validate_arguments(args, bc):
'WITH_BF_INTERNATIONAL',
'BF_GETTEXT', 'BF_GETTEXT_INC', 'BF_GETTEXT_LIB', 'WITH_BF_GETTEXT_STATIC', 'BF_GETTEXT_LIB_STATIC', 'BF_GETTEXT_LIBPATH',
'WITH_BF_ICONV', 'BF_ICONV', 'BF_ICONV_INC', 'BF_ICONV_LIB', 'BF_ICONV_LIBPATH',
'WITH_BF_GAMEENGINE', 'WITH_BF_BULLET', 'BF_BULLET', 'BF_BULLET_INC', 'BF_BULLET_LIB',
'WITH_BF_GAMEENGINE', 'WITH_BF_BULLET', 'WITH_BF_ELTOPO', 'BF_BULLET', 'BF_BULLET_INC', 'BF_BULLET_LIB',
'BF_WINTAB', 'BF_WINTAB_INC',
'WITH_BF_FREETYPE', 'BF_FREETYPE', 'BF_FREETYPE_INC', 'BF_FREETYPE_LIB', 'BF_FREETYPE_LIBPATH', 'BF_FREETYPE_LIB_STATIC', 'WITH_BF_FREETYPE_STATIC',
'WITH_BF_QUICKTIME', 'BF_QUICKTIME', 'BF_QUICKTIME_INC', 'BF_QUICKTIME_LIB', 'BF_QUICKTIME_LIBPATH',
@@ -79,11 +121,11 @@ def validate_arguments(args, bc):
'BF_OPENMP_INC',
'BF_OPENMP_LIBPATH',
'WITH_GHOST_COCOA',
'WITH_GHOST_SDL',
'USE_QTKIT',
'BF_FANCY', 'BF_QUIET', 'BF_LINE_OVERWRITE',
'BF_X264_CONFIG',
'BF_XVIDCORE_CONFIG',
'WITH_BF_LCMS', 'BF_LCMS', 'BF_LCMS_INC', 'BF_LCMS_LIB', 'BF_LCMS_LIBPATH',
'WITH_BF_DOCS',
'BF_NUMJOBS',
'BF_MSVS',
@@ -92,8 +134,9 @@ def validate_arguments(args, bc):
'WITH_BF_RAYOPTIMIZATION',
'BF_RAYOPTIMIZATION_SSE_FLAGS',
'BF_NO_ELBEEM',
'WITH_BF_CXX_GUARDEDALLOC',
'BF_VCREDIST' # Windows-only, and useful only when creating installer
'WITH_BF_CXX_GUARDEDALLOC',
'WITH_BF_JEMALLOC', 'WITH_BF_STATICJEMALLOC', 'BF_JEMALLOC', 'BF_JEMALLOC_INC', 'BF_JEMALLOC_LIBPATH', 'BF_JEMALLOC_LIB', 'BF_JEMALLOC_LIB_STATIC',
'BUILDBOT_BRANCH', 'WITH_BF_3DMOUSE', 'WITH_BF_STATIC3DMOUSE', 'BF_3DMOUSE', 'BF_3DMOUSE_INC', 'BF_3DMOUSE_LIB', 'BF_3DMOUSE_LIBPATH', 'BF_3DMOUSE_LIB_STATIC'
]
# Have options here that scons expects to be lists
@@ -106,7 +149,7 @@ def validate_arguments(args, bc):
'BF_PROFILE_CFLAGS', 'BF_PROFILE_CCFLAGS', 'BF_PROFILE_CXXFLAGS', 'BF_PROFILE_LINKFLAGS',
'BF_DEBUG_CFLAGS', 'BF_DEBUG_CCFLAGS', 'BF_DEBUG_CXXFLAGS',
'C_WARN', 'CC_WARN', 'CXX_WARN',
'LLIBS', 'PLATFORM_LINKFLAGS','MACOSX_ARCHITECTURE',
'LLIBS', 'PLATFORM_LINKFLAGS','MACOSX_ARCHITECTURE', 'MACOSX_SDK_CHECK', 'XCODE_CUR_VER',
]
@@ -116,7 +159,7 @@ def validate_arguments(args, bc):
'BF_BSC', 'BF_CONFIG',
'BF_PRIORITYLIST', 'BF_BUILDINFO','CC', 'CXX', 'BF_QUICKDEBUG',
'BF_LISTDEBUG', 'LCGDIR', 'BF_X264_CONFIG', 'BF_XVIDCORE_CONFIG',
'BF_UNIT_TEST']
'BF_UNIT_TEST', 'BF_BITNESS']
okdict = {}
@@ -140,7 +183,7 @@ def print_targets(targs, bc):
def validate_targets(targs, bc):
valid_list = ['.', 'blender', 'blenderstatic', 'blenderplayer', 'webplugin',
'blendernogame', 'blenderstaticnogame', 'blenderlite', 'release',
'everything', 'clean', 'install-bin', 'install', 'nsis']
'everything', 'clean', 'install-bin', 'install', 'nsis','buildslave']
oklist = []
for t in targs:
if t in valid_list:
@@ -176,6 +219,7 @@ def read_opts(env, cfg, args):
localopts.AddVariables(
('LCGDIR', 'location of cvs lib dir'),
(BoolVariable('WITH_BF_PYTHON', 'Compile with python', True)),
(BoolVariable('WITH_BF_PYTHON_SAFETY', 'Internal API error checking to track invalid data to prevent crash on access (at the expense of some effeciency)', False)),
('BF_PYTHON', 'base path for python', ''),
('BF_PYTHON_VERSION', 'Python version to use', ''),
('BF_PYTHON_INC', 'include path for Python headers', ''),
@@ -186,6 +230,8 @@ def read_opts(env, cfg, args):
('BF_PYTHON_LIBPATH', 'Library path', ''),
('BF_PYTHON_LINKFLAGS', 'Python link flags', ''),
(BoolVariable('WITH_BF_STATICPYTHON', 'Staticly link to python', False)),
(BoolVariable('WITH_OSX_STATICPYTHON', 'Staticly link to python', True)),
('BF_PYTHON_ABI_FLAGS', 'Python ABI flags (suffix in library version: m, mu, etc)', ''),
(BoolVariable('BF_NO_ELBEEM', 'Disable Fluid Sim', False)),
('BF_PROFILE_FLAGS', 'Profiling compiler flags', ''),
@@ -246,6 +292,7 @@ def read_opts(env, cfg, args):
(BoolVariable('WITH_BF_FFMPEG', 'Use FFMPEG if true', False)),
('BF_FFMPEG', 'FFMPEG base path', ''),
('BF_FFMPEG_LIB', 'FFMPEG library', ''),
('BF_FFMPEG_DLL', 'FFMPEG dll libraries to be installed', ''),
('BF_FFMPEG_EXTRA', 'FFMPEG flags that must be preserved', ''),
('BF_FFMPEG_INC', 'FFMPEG includes', ''),
@@ -290,12 +337,6 @@ def read_opts(env, cfg, args):
('BF_TIFF_LIBPATH', 'TIFF library path', ''),
('BF_TIFF_LIB_STATIC', 'TIFF static library', ''),
(BoolVariable('WITH_BF_LCMS', 'Enable color correction with lcms', False)),
('BF_LCMS', 'LCMS base path', ''),
('BF_LCMS_INC', 'LCMS include path', ''),
('BF_LCMS_LIB', 'LCMS library', ''),
('BF_LCMS_LIBPATH', 'LCMS library path', ''),
(BoolVariable('WITH_BF_ZLIB', 'Use ZLib if true', True)),
(BoolVariable('WITH_BF_STATICZLIB', 'Staticly link to ZLib', False)),
('BF_ZLIB', 'ZLib base path', ''),
@@ -322,6 +363,8 @@ def read_opts(env, cfg, args):
(BoolVariable('WITH_BF_GAMEENGINE', 'Build with gameengine' , False)),
(BoolVariable('WITH_BF_BULLET', 'Use Bullet if true', True)),
(BoolVariable('WITH_BF_ELTOPO', 'Use Eltopo collision library if true', False)),
('BF_BULLET', 'Bullet base dir', ''),
('BF_BULLET_INC', 'Bullet include path', ''),
('BF_BULLET_LIB', 'Bullet library', ''),
@@ -345,6 +388,7 @@ def read_opts(env, cfg, args):
('BF_OPENMP_INC', 'Path to OpenMP includes (used when cross-compiling with older versions of WinGW)', ''),
('BF_OPENMP_LIBPATH', 'Path to OpenMP libraries (used when cross-compiling with older versions of WinGW)', ''),
(BoolVariable('WITH_GHOST_COCOA', 'Use Cocoa-framework if true', False)),
(BoolVariable('WITH_GHOST_SDL', 'Enable building blender against SDL for windowing rather then the native APIs', False)),
(BoolVariable('USE_QTKIT', 'Use QTKIT if true', False)),
(BoolVariable('WITH_BF_QUICKTIME', 'Use QuickTime if true', False)),
@@ -384,9 +428,25 @@ def read_opts(env, cfg, args):
('BF_EXPAT_LIB', 'Expat library', ''),
('BF_EXPAT_LIBPATH', 'Expat library path', ''),
(BoolVariable('WITH_BF_JEMALLOC', 'Use jemalloc if true', False)),
(BoolVariable('WITH_BF_STATICJEMALLOC', 'Staticly link to jemalloc', False)),
('BF_JEMALLOC', 'jemalloc base path', ''),
('BF_JEMALLOC_INC', 'jemalloc include path', ''),
('BF_JEMALLOC_LIB', 'jemalloc library', ''),
('BF_JEMALLOC_LIBPATH', 'jemalloc library path', ''),
('BF_JEMALLOC_LIB_STATIC', 'jemalloc static library', ''),
(BoolVariable('WITH_BF_PLAYER', 'Build blenderplayer if true', False)),
(BoolVariable('WITH_BF_NOBLENDER', 'Do not build blender if true', False)),
(BoolVariable('WITH_BF_3DMOUSE', 'Build blender with support of 3D mouses', False)),
(BoolVariable('WITH_BF_STATIC3DMOUSE', 'Staticly link to 3d mouse library', False)),
('BF_3DMOUSE', '3d mouse library base path', ''),
('BF_3DMOUSE_INC', '3d mouse library include path', ''),
('BF_3DMOUSE_LIB', '3d mouse library', ''),
('BF_3DMOUSE_LIBPATH', '3d mouse library path', ''),
('BF_3DMOUSE_LIB_STATIC', '3d mouse static library', ''),
('CFLAGS', 'C only flags', []),
('CCFLAGS', 'Generic C and C++ flags', []),
('CXXFLAGS', 'C++ only flags', []),
@@ -403,6 +463,8 @@ def read_opts(env, cfg, args):
('LLIBS', 'Platform libs', []),
('PLATFORM_LINKFLAGS', 'Platform linkflags', []),
('MACOSX_ARCHITECTURE', 'python_arch.zip select', ''),
('MACOSX_SDK_CHECK', 'detect available OSX sdk`s', ''),
('XCODE_CUR_VER', 'detect XCode version', ''),
(BoolVariable('BF_PROFILE', 'Add profiling information if true', False)),
('BF_PROFILE_CFLAGS', 'C only profiling flags', []),
@@ -455,11 +517,91 @@ def read_opts(env, cfg, args):
(BoolVariable('WITH_BF_RAYOPTIMIZATION', 'Enable raytracer SSE/SIMD optimization.', False)),
('BF_RAYOPTIMIZATION_SSE_FLAGS', 'SSE flags', ''),
(BoolVariable('WITH_BF_CXX_GUARDEDALLOC', 'Enable GuardedAlloc for C++ memory allocation tracking.', False)),
('BF_VCREDIST', 'Full path to vcredist', '')
('BUILDBOT_BRANCH', 'Buildbot branch name', ''),
) # end of opts.AddOptions()
return localopts
def buildbot_zip(src, dest, package_name, extension):
import zipfile
ln = len(src)+1 # one extra to remove leading os.sep when cleaning root for package_root
flist = list()
# create list of tuples containing file and archive name
for root, dirs, files in os.walk(src):
package_root = os.path.join(package_name, root[ln:])
flist.extend([(os.path.join(root, file), os.path.join(package_root, file)) for file in files])
if extension == '.zip':
package = zipfile.ZipFile(dest, 'w', zipfile.ZIP_DEFLATED)
package.comment = package_name + ' is a zip-file containing the Blender software. Visit http://www.blender.org for more information.'
for entry in flist:
package.write(entry[0], entry[1])
package.close()
else:
import tarfile
package = tarfile.open(dest, 'w:bz2')
for entry in flist:
package.add(entry[0], entry[1], recursive=False)
package.close()
bb_zip_name = os.path.normpath(src + os.sep + '..' + os.sep + 'buildbot_upload.zip')
print("creating %s" % (bb_zip_name))
bb_zip = zipfile.ZipFile(bb_zip_name, 'w', zipfile.ZIP_DEFLATED)
print("writing %s to %s" % (dest, bb_zip_name))
bb_zip.write(dest, os.path.split(dest)[1])
bb_zip.close()
print("removing unneeded packed file %s (to keep install directory clean)" % (dest))
os.remove(dest)
print("done.")
def buildslave_print(target, source, env):
return "Running buildslave target"
def buildslave(target=None, source=None, env=None):
"""
Builder for buildbot integration. Used by buildslaves of http://builder.blender.org only.
"""
if env['OURPLATFORM'] in ('win32-vc', 'win64-vc', 'win32-mingw', 'darwin'):
extension = '.zip'
else:
extension = '.tar.bz2'
platform = env['OURPLATFORM'].split('-')[0]
if platform == 'linux':
import platform
bitness = platform.architecture()[0]
if bitness == '64bit':
platform = 'linux-glibc27-x86_64'
elif bitness == '32bit':
platform = 'linux-glibc27-i686'
if platform == 'darwin':
platform = 'OSX-' + env['MACOSX_ARCHITECTURE']
branch = env['BUILDBOT_BRANCH']
outdir = os.path.abspath(env['BF_INSTALLDIR'])
package_name = 'blender-' + VERSION+'-'+REVISION + '-' + platform
if branch != '':
package_name = branch + '-' + package_name
package_dir = os.path.normpath(outdir + os.sep + '..' + os.sep + package_name)
package_archive = os.path.normpath(outdir + os.sep + '..' + os.sep + package_name + extension)
try:
if os.path.exists(package_archive):
os.remove(package_archive)
if os.path.exists(package_dir):
shutil.rmtree(package_dir)
except Exception, ex:
sys.stderr.write('Failed to clean up old package files: ' + str(ex) + '\n')
return 1
buildbot_zip(outdir, package_archive, package_name, extension)
return 0
def NSIS_print(target, source, env):
return "Creating NSIS installer for Blender"
@@ -486,9 +628,12 @@ def NSIS_Installer(target=None, source=None, env=None):
doneroot = False
rootdirconts = []
datafiles = ''
deldatafiles = ''
deldatadirs = ''
l = len(bf_installdir)
for dp,dn,df in os.walk(bf_installdir):
# install
if not doneroot:
for f in df:
rootdirconts.append(os.path.join(dp,f))
@@ -496,24 +641,26 @@ def NSIS_Installer(target=None, source=None, env=None):
else:
if len(df)>0:
dp_tmp = dp[l:]
if dp_tmp.find('python\\lib') > -1:
datafiles += "\n" +r'SetOutPath $INSTDIR'+dp[l:]+"\n\n"
else:
datafiles += "\n"+r'SetOutPath $BLENDERHOME'+dp[l:]+"\n\n"
datafiles += "\n" +r'SetOutPath $INSTDIR'+dp[l:]+"\n\n"
for f in df:
outfile = os.path.join(dp,f)
datafiles += ' File '+outfile + "\n"
os.chdir("release")
v = open("VERSION")
version = v.read()[:-1]
v.close()
# uninstall
deldir = dp[l+1:]
if len(deldir)>0:
deldatadirs = "RMDir $INSTDIR\\" + deldir + "\n" + deldatadirs
deldatadirs = "RMDir /r $INSTDIR\\" + deldir + "\\__pycache__\n" + deldatadirs
for f in df:
deldatafiles += 'Delete \"$INSTDIR\\' + os.path.join(deldir, f) + "\"\n"
#### change to suit install dir ####
inst_dir = install_base_dir + env['BF_INSTALLDIR']
os.chdir("windows/installer")
os.chdir(rel_dir)
ns = open("00.sconsblender.nsi","r")
@@ -522,7 +669,7 @@ def NSIS_Installer(target=None, source=None, env=None):
# var replacements
ns_cnt = string.replace(ns_cnt, "[DISTDIR]", os.path.normpath(inst_dir+os.sep))
ns_cnt = string.replace(ns_cnt, "[VERSION]", version)
ns_cnt = string.replace(ns_cnt, "[VERSION]", VERSION_DISPLAY)
ns_cnt = string.replace(ns_cnt, "[SHORTVERSION]", VERSION)
ns_cnt = string.replace(ns_cnt, "[RELDIR]", os.path.normpath(rel_dir))
ns_cnt = string.replace(ns_cnt, "[BITNESS]", bitness)
@@ -546,12 +693,8 @@ def NSIS_Installer(target=None, source=None, env=None):
ns_cnt = string.replace(ns_cnt, "[DELROOTDIRCONTS]", delrootstring)
ns_cnt = string.replace(ns_cnt, "[DODATAFILES]", datafiles)
# Setup vcredist part
vcredist = "File \""+env['BF_VCREDIST'] + "\"\n"
vcredist += " ExecWait '\"$TEMP\\" + os.path.basename(env['BF_VCREDIST']) + "\" /q'\n"
vcredist += " Delete \"$TEMP\\" + os.path.basename(env['BF_VCREDIST'])+"\""
ns_cnt = string.replace(ns_cnt, "[VCREDIST]", vcredist)
ns_cnt = string.replace(ns_cnt, "[DELDATAFILES]", deldatafiles)
ns_cnt = string.replace(ns_cnt, "[DELDATADIRS]", deldatadirs)
tmpnsi = os.path.normpath(install_base_dir+os.sep+env['BF_BUILDDIR']+os.sep+"00.blender_tmp.nsi")
new_nsis = open(tmpnsi, 'w')
@@ -576,3 +719,24 @@ def NSIS_Installer(target=None, source=None, env=None):
print data.strip().split("\n")[-1]
return rv
def check_environ():
problematic_envvars = ""
for i in os.environ:
try:
os.environ[i].decode('ascii')
except UnicodeDecodeError:
problematic_envvars = problematic_envvars + "%s = %s\n" % (i, os.environ[i])
if len(problematic_envvars)>0:
print("================\n\n")
print("@@ ABORTING BUILD @@\n")
print("PROBLEM DETECTED WITH ENVIRONMENT")
print("---------------------------------\n\n")
print("A problem with one or more environment variable was found")
print("Their value contain non-ascii characters. Check the below")
print("list and override them locally to be ASCII-clean by doing")
print("'set VARNAME=cleanvalue' on the command-line prior to")
print("starting the build process:\n")
print(problematic_envvars)
return False
else:
return True

View File

@@ -1,943 +0,0 @@
# Doxyfile 1.2.15
# This file describes the settings to be used by the documentation system
# doxygen (www.doxygen.org) for a project
#
# All text after a hash (#) is considered a comment and will be ignored
# The format is:
# TAG = value [value, ...]
# For lists items can also be appended using:
# TAG += value [value, ...]
# Values that contain spaces should be placed between quotes (" ")
#---------------------------------------------------------------------------
# General configuration options
#---------------------------------------------------------------------------
# The PROJECT_NAME tag is a single word (or a sequence of words surrounded
# by quotes) that should identify the project.
PROJECT_NAME = Blender
# The PROJECT_NUMBER tag can be used to enter a project or revision number.
# This could be handy for archiving the generated documentation or
# if some version control system is used.
PROJECT_NUMBER = V2.27
# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute)
# base path where the generated documentation will be put.
# If a relative path is entered, it will be relative to the location
# where doxygen was started. If left blank the current directory will be used.
OUTPUT_DIRECTORY =
# The OUTPUT_LANGUAGE tag is used to specify the language in which all
# documentation generated by doxygen is written. Doxygen will use this
# information to generate all constant output in the proper language.
# The default language is English, other supported languages are:
# Brazilian, Chinese, Croatian, Czech, Danish, Dutch, Finnish, French,
# German, Greek, Hungarian, Italian, Japanese, Korean, Norwegian, Polish,
# Portuguese, Romanian, Russian, Slovak, Slovene, Spanish and Swedish.
OUTPUT_LANGUAGE = English
# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in
# documentation are documented, even if no documentation was available.
# Private class members and static file members will be hidden unless
# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES
EXTRACT_ALL = NO
# If the EXTRACT_PRIVATE tag is set to YES all private members of a class
# will be included in the documentation.
EXTRACT_PRIVATE = NO
# If the EXTRACT_STATIC tag is set to YES all static members of a file
# will be included in the documentation.
EXTRACT_STATIC = YES
# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs)
# defined locally in source files will be included in the documentation.
# If set to NO only classes defined in header files are included.
EXTRACT_LOCAL_CLASSES = YES
# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all
# undocumented members of documented classes, files or namespaces.
# If set to NO (the default) these members will be included in the
# various overviews, but no documentation section is generated.
# This option has no effect if EXTRACT_ALL is enabled.
HIDE_UNDOC_MEMBERS = NO
# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all
# undocumented classes that are normally visible in the class hierarchy.
# If set to NO (the default) these class will be included in the various
# overviews. This option has no effect if EXTRACT_ALL is enabled.
HIDE_UNDOC_CLASSES = NO
# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will
# include brief member descriptions after the members that are listed in
# the file and class documentation (similar to JavaDoc).
# Set to NO to disable this.
BRIEF_MEMBER_DESC = YES
# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend
# the brief description of a member or function before the detailed description.
# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the
# brief descriptions will be completely suppressed.
REPEAT_BRIEF = YES
# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then
# Doxygen will generate a detailed section even if there is only a brief
# description.
ALWAYS_DETAILED_SEC = NO
# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all inherited
# members of a class in the documentation of that class as if those members were
# ordinary class members. Constructors, destructors and assignment operators of
# the base classes will not be shown.
INLINE_INHERITED_MEMB = NO
# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full
# path before files name in the file list and in the header files. If set
# to NO the shortest path that makes the file name unique will be used.
FULL_PATH_NAMES = NO
# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag
# can be used to strip a user defined part of the path. Stripping is
# only done if one of the specified strings matches the left-hand part of
# the path. It is allowed to use relative paths in the argument list.
STRIP_FROM_PATH =
# The INTERNAL_DOCS tag determines if documentation
# that is typed after a \internal command is included. If the tag is set
# to NO (the default) then the documentation will be excluded.
# Set it to YES to include the internal documentation.
INTERNAL_DOCS = YES
# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct
# doxygen to hide any special comment blocks from generated source code
# fragments. Normal C and C++ comments will always remain visible.
STRIP_CODE_COMMENTS = YES
# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate
# file names in lower case letters. If set to YES upper case letters are also
# allowed. This is useful if you have classes or files whose names only differ
# in case and if your file system supports case sensitive file names. Windows
# users are adviced to set this option to NO.
CASE_SENSE_NAMES = YES
# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter
# (but less readable) file names. This can be useful is your file systems
# doesn't support long names like on DOS, Mac, or CD-ROM.
SHORT_NAMES = NO
# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen
# will show members with their full class and namespace scopes in the
# documentation. If set to YES the scope will be hidden.
HIDE_SCOPE_NAMES = NO
# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen
# will generate a verbatim copy of the header file for each class for
# which an include is specified. Set to NO to disable this.
VERBATIM_HEADERS = YES
# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen
# will put list of the files that are included by a file in the documentation
# of that file.
SHOW_INCLUDE_FILES = YES
# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen
# will interpret the first line (until the first dot) of a JavaDoc-style
# comment as the brief description. If set to NO, the JavaDoc
# comments will behave just like the Qt-style comments (thus requiring an
# explict @brief command for a brief description.
JAVADOC_AUTOBRIEF = NO
# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented
# member inherits the documentation from any documented member that it
# reimplements.
INHERIT_DOCS = YES
# If the INLINE_INFO tag is set to YES (the default) then a tag [inline]
# is inserted in the documentation for inline members.
INLINE_INFO = YES
# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen
# will sort the (detailed) documentation of file and class members
# alphabetically by member name. If set to NO the members will appear in
# declaration order.
SORT_MEMBER_DOCS = YES
# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC
# tag is set to YES, then doxygen will reuse the documentation of the first
# member in the group (if any) for the other members of the group. By default
# all members of a group must be documented explicitly.
DISTRIBUTE_GROUP_DOC = YES
# The TAB_SIZE tag can be used to set the number of spaces in a tab.
# Doxygen uses this value to replace tabs by spaces in code fragments.
TAB_SIZE = 8
# The GENERATE_TODOLIST tag can be used to enable (YES) or
# disable (NO) the todo list. This list is created by putting \todo
# commands in the documentation.
GENERATE_TODOLIST = YES
# The GENERATE_TESTLIST tag can be used to enable (YES) or
# disable (NO) the test list. This list is created by putting \test
# commands in the documentation.
GENERATE_TESTLIST = YES
# The GENERATE_BUGLIST tag can be used to enable (YES) or
# disable (NO) the bug list. This list is created by putting \bug
# commands in the documentation.
GENERATE_BUGLIST = YES
# This tag can be used to specify a number of aliases that acts
# as commands in the documentation. An alias has the form "name=value".
# For example adding "sideeffect=\par Side Effects:\n" will allow you to
# put the command \sideeffect (or @sideeffect) in the documentation, which
# will result in a user defined paragraph with heading "Side Effects:".
# You can put \n's in the value part of an alias to insert newlines.
ALIASES =
# The ENABLED_SECTIONS tag can be used to enable conditional
# documentation sections, marked by \if sectionname ... \endif.
ENABLED_SECTIONS =
# The MAX_INITIALIZER_LINES tag determines the maximum number of lines
# the initial value of a variable or define consist of for it to appear in
# the documentation. If the initializer consists of more lines than specified
# here it will be hidden. Use a value of 0 to hide initializers completely.
# The appearance of the initializer of individual variables and defines in the
# documentation can be controlled using \showinitializer or \hideinitializer
# command in the documentation regardless of this setting.
MAX_INITIALIZER_LINES = 30
# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C sources
# only. Doxygen will then generate output that is more tailored for C.
# For instance some of the names that are used will be different. The list
# of all members will be omitted, etc.
OPTIMIZE_OUTPUT_FOR_C = NO
# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java sources
# only. Doxygen will then generate output that is more tailored for Java.
# For instance namespaces will be presented as packages, qualified scopes
# will look different, etc.
OPTIMIZE_OUTPUT_JAVA = NO
# Set the SHOW_USED_FILES tag to NO to disable the list of files generated
# at the bottom of the documentation of classes and structs. If set to YES the
# list will mention the files that were used to generate the documentation.
SHOW_USED_FILES = YES
#---------------------------------------------------------------------------
# configuration options related to warning and progress messages
#---------------------------------------------------------------------------
# The QUIET tag can be used to turn on/off the messages that are generated
# by doxygen. Possible values are YES and NO. If left blank NO is used.
QUIET = NO
# The WARNINGS tag can be used to turn on/off the warning messages that are
# generated by doxygen. Possible values are YES and NO. If left blank
# NO is used.
WARNINGS = YES
# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings
# for undocumented members. If EXTRACT_ALL is set to YES then this flag will
# automatically be disabled.
WARN_IF_UNDOCUMENTED = YES
# The WARN_FORMAT tag determines the format of the warning messages that
# doxygen can produce. The string should contain the $file, $line, and $text
# tags, which will be replaced by the file and line number from which the
# warning originated and the warning text.
WARN_FORMAT = "$file:$line: $text"
# The WARN_LOGFILE tag can be used to specify a file to which warning
# and error messages should be written. If left blank the output is written
# to stderr.
WARN_LOGFILE =
#---------------------------------------------------------------------------
# configuration options related to the input files
#---------------------------------------------------------------------------
# The INPUT tag can be used to specify the files and/or directories that contain
# documented source files. You may enter file names like "myfile.cpp" or
# directories like "/usr/src/myproject". Separate the files or directories
# with spaces.
INPUT = doxygen.main ../source/creator/ ../source/blender/src/B.blend.c ../source/blender/src/blenderbuttons.c ../source/blender/readblenfile/intern/BLO_readblenfile.c ../intern/ghost/GHOST_C-api.h ../source/blender/imbuf/ ../source/blender/src/mainqueue.c
# cmccad - The following lines are directories which will eventually be included:
#
# ../source/blender/blenkernel/ ../source/blender/imbuf/ ../source/blender/render/
# ../source/blender/blenlib/ ../source/blender/include
# If the value of the INPUT tag contains directories, you can use the
# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp
# and *.h) to filter out the source-files in the directories. If left
# blank the following patterns are tested:
# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx *.hpp
# *.h++ *.idl *.odl
FILE_PATTERNS =
# The RECURSIVE tag can be used to turn specify whether or not subdirectories
# should be searched for input files as well. Possible values are YES and NO.
# If left blank NO is used.
RECURSIVE = YES
# The EXCLUDE tag can be used to specify files and/or directories that should
# excluded from the INPUT source files. This way you can easily exclude a
# subdirectory from a directory tree whose root is specified with the INPUT tag.
EXCLUDE =
# The EXCLUDE_SYMLINKS tag can be used select whether or not files or directories
# that are symbolic links (a Unix filesystem feature) are excluded from the input.
EXCLUDE_SYMLINKS = NO
# If the value of the INPUT tag contains directories, you can use the
# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude
# certain files from those directories.
EXCLUDE_PATTERNS =
# The EXAMPLE_PATH tag can be used to specify one or more files or
# directories that contain example code fragments that are included (see
# the \include command).
EXAMPLE_PATH =
# If the value of the EXAMPLE_PATH tag contains directories, you can use the
# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp
# and *.h) to filter out the source-files in the directories. If left
# blank all files are included.
EXAMPLE_PATTERNS =
# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be
# searched for input files to be used with the \include or \dontinclude
# commands irrespective of the value of the RECURSIVE tag.
# Possible values are YES and NO. If left blank NO is used.
EXAMPLE_RECURSIVE = NO
# The IMAGE_PATH tag can be used to specify one or more files or
# directories that contain image that are included in the documentation (see
# the \image command).
IMAGE_PATH =
# The INPUT_FILTER tag can be used to specify a program that doxygen should
# invoke to filter for each input file. Doxygen will invoke the filter program
# by executing (via popen()) the command <filter> <input-file>, where <filter>
# is the value of the INPUT_FILTER tag, and <input-file> is the name of an
# input file. Doxygen will then use the output that the filter program writes
# to standard output.
INPUT_FILTER =
# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using
# INPUT_FILTER) will be used to filter the input files when producing source
# files to browse.
FILTER_SOURCE_FILES = NO
#---------------------------------------------------------------------------
# configuration options related to source browsing
#---------------------------------------------------------------------------
# If the SOURCE_BROWSER tag is set to YES then a list of source files will
# be generated. Documented entities will be cross-referenced with these sources.
SOURCE_BROWSER = YES
# Setting the INLINE_SOURCES tag to YES will include the body
# of functions and classes directly in the documentation.
INLINE_SOURCES = NO
# If the REFERENCED_BY_RELATION tag is set to YES (the default)
# then for each documented function all documented
# functions referencing it will be listed.
REFERENCED_BY_RELATION = YES
# If the REFERENCES_RELATION tag is set to YES (the default)
# then for each documented function all documented entities
# called/used by that function will be listed.
REFERENCES_RELATION = YES
#---------------------------------------------------------------------------
# configuration options related to the alphabetical class index
#---------------------------------------------------------------------------
# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index
# of all compounds will be generated. Enable this if the project
# contains a lot of classes, structs, unions or interfaces.
ALPHABETICAL_INDEX = NO
# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then
# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns
# in which this list will be split (can be a number in the range [1..20])
COLS_IN_ALPHA_INDEX = 5
# In case all classes in a project start with a common prefix, all
# classes will be put under the same header in the alphabetical index.
# The IGNORE_PREFIX tag can be used to specify one or more prefixes that
# should be ignored while generating the index headers.
IGNORE_PREFIX =
#---------------------------------------------------------------------------
# configuration options related to the HTML output
#---------------------------------------------------------------------------
# If the GENERATE_HTML tag is set to YES (the default) Doxygen will
# generate HTML output.
GENERATE_HTML = YES
# The HTML_OUTPUT tag is used to specify where the HTML docs will be put.
# If a relative path is entered the value of OUTPUT_DIRECTORY will be
# put in front of it. If left blank `html' will be used as the default path.
HTML_OUTPUT = html
# The HTML_FILE_EXTENSION tag can be used to specify the file extension for
# each generated HTML page (for example: .htm,.php,.asp). If it is left blank
# doxygen will generate files with .html extension.
HTML_FILE_EXTENSION = .html
# The HTML_HEADER tag can be used to specify a personal HTML header for
# each generated HTML page. If it is left blank doxygen will generate a
# standard header.
HTML_HEADER =
# The HTML_FOOTER tag can be used to specify a personal HTML footer for
# each generated HTML page. If it is left blank doxygen will generate a
# standard footer.
HTML_FOOTER =
# The HTML_STYLESHEET tag can be used to specify a user defined cascading
# style sheet that is used by each HTML page. It can be used to
# fine-tune the look of the HTML output. If the tag is left blank doxygen
# will generate a default style sheet
HTML_STYLESHEET =
# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes,
# files or namespaces will be aligned in HTML using tables. If set to
# NO a bullet list will be used.
HTML_ALIGN_MEMBERS = YES
# If the GENERATE_HTMLHELP tag is set to YES, additional index files
# will be generated that can be used as input for tools like the
# Microsoft HTML help workshop to generate a compressed HTML help file (.chm)
# of the generated HTML documentation.
GENERATE_HTMLHELP = NO
# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag
# controls if a separate .chi index file is generated (YES) or that
# it should be included in the master .chm file (NO).
GENERATE_CHI = NO
# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag
# controls whether a binary table of contents is generated (YES) or a
# normal table of contents (NO) in the .chm file.
BINARY_TOC = NO
# The TOC_EXPAND flag can be set to YES to add extra items for group members
# to the contents of the Html help documentation and to the tree view.
TOC_EXPAND = NO
# The DISABLE_INDEX tag can be used to turn on/off the condensed index at
# top of each HTML page. The value NO (the default) enables the index and
# the value YES disables it.
DISABLE_INDEX = NO
# This tag can be used to set the number of enum values (range [1..20])
# that doxygen will group on one line in the generated HTML documentation.
ENUM_VALUES_PER_LINE = 4
# If the GENERATE_TREEVIEW tag is set to YES, a side panel will be
# generated containing a tree-like index structure (just like the one that
# is generated for HTML Help). For this to work a browser that supports
# JavaScript and frames is required (for instance Mozilla, Netscape 4.0+,
# or Internet explorer 4.0+). Note that for large projects the tree generation
# can take a very long time. In such cases it is better to disable this feature.
# Windows users are probably better off using the HTML help feature.
GENERATE_TREEVIEW = NO
# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be
# used to set the initial width (in pixels) of the frame in which the tree
# is shown.
TREEVIEW_WIDTH = 250
#---------------------------------------------------------------------------
# configuration options related to the LaTeX output
#---------------------------------------------------------------------------
# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will
# generate Latex output.
GENERATE_LATEX = NO
# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put.
# If a relative path is entered the value of OUTPUT_DIRECTORY will be
# put in front of it. If left blank `latex' will be used as the default path.
LATEX_OUTPUT = latex
# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be invoked. If left blank `latex' will be used as the default command name.
LATEX_CMD_NAME = latex
# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to
# generate index for LaTeX. If left blank `makeindex' will be used as the
# default command name.
MAKEINDEX_CMD_NAME = makeindex
# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact
# LaTeX documents. This may be useful for small projects and may help to
# save some trees in general.
COMPACT_LATEX = NO
# The PAPER_TYPE tag can be used to set the paper type that is used
# by the printer. Possible values are: a4, a4wide, letter, legal and
# executive. If left blank a4wide will be used.
PAPER_TYPE = a4wide
# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX
# packages that should be included in the LaTeX output.
EXTRA_PACKAGES =
# The LATEX_HEADER tag can be used to specify a personal LaTeX header for
# the generated latex document. The header should contain everything until
# the first chapter. If it is left blank doxygen will generate a
# standard header. Notice: only use this tag if you know what you are doing!
LATEX_HEADER =
# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated
# is prepared for conversion to pdf (using ps2pdf). The pdf file will
# contain links (just like the HTML output) instead of page references
# This makes the output suitable for online browsing using a pdf viewer.
PDF_HYPERLINKS = NO
# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of
# plain latex in the generated Makefile. Set this option to YES to get a
# higher quality PDF documentation.
USE_PDFLATEX = NO
# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode.
# command to the generated LaTeX files. This will instruct LaTeX to keep
# running if errors occur, instead of asking the user for help.
# This option is also used when generating formulas in HTML.
LATEX_BATCHMODE = NO
#---------------------------------------------------------------------------
# configuration options related to the RTF output
#---------------------------------------------------------------------------
# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output
# The RTF output is optimised for Word 97 and may not look very pretty with
# other RTF readers or editors.
GENERATE_RTF = NO
# The RTF_OUTPUT tag is used to specify where the RTF docs will be put.
# If a relative path is entered the value of OUTPUT_DIRECTORY will be
# put in front of it. If left blank `rtf' will be used as the default path.
RTF_OUTPUT = rtf
# If the COMPACT_RTF tag is set to YES Doxygen generates more compact
# RTF documents. This may be useful for small projects and may help to
# save some trees in general.
COMPACT_RTF = NO
# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated
# will contain hyperlink fields. The RTF file will
# contain links (just like the HTML output) instead of page references.
# This makes the output suitable for online browsing using WORD or other
# programs which support those fields.
# Note: wordpad (write) and others do not support links.
RTF_HYPERLINKS = NO
# Load stylesheet definitions from file. Syntax is similar to doxygen's
# config file, i.e. a series of assigments. You only have to provide
# replacements, missing definitions are set to their default value.
RTF_STYLESHEET_FILE =
# Set optional variables used in the generation of an rtf document.
# Syntax is similar to doxygen's config file.
RTF_EXTENSIONS_FILE =
#---------------------------------------------------------------------------
# configuration options related to the man page output
#---------------------------------------------------------------------------
# If the GENERATE_MAN tag is set to YES (the default) Doxygen will
# generate man pages
GENERATE_MAN = NO
# The MAN_OUTPUT tag is used to specify where the man pages will be put.
# If a relative path is entered the value of OUTPUT_DIRECTORY will be
# put in front of it. If left blank `man' will be used as the default path.
MAN_OUTPUT = man
# The MAN_EXTENSION tag determines the extension that is added to
# the generated man pages (default is the subroutine's section .3)
MAN_EXTENSION = .3
# If the MAN_LINKS tag is set to YES and Doxygen generates man output,
# then it will generate one additional man file for each entity
# documented in the real man page(s). These additional files
# only source the real man page, but without them the man command
# would be unable to find the correct page. The default is NO.
MAN_LINKS = NO
#---------------------------------------------------------------------------
# configuration options related to the XML output
#---------------------------------------------------------------------------
# If the GENERATE_XML tag is set to YES Doxygen will
# generate an XML file that captures the structure of
# the code including all documentation. Note that this
# feature is still experimental and incomplete at the
# moment.
GENERATE_XML = NO
#---------------------------------------------------------------------------
# configuration options for the AutoGen Definitions output
#---------------------------------------------------------------------------
# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will
# generate an AutoGen Definitions (see autogen.sf.net) file
# that captures the structure of the code including all
# documentation. Note that this feature is still experimental
# and incomplete at the moment.
GENERATE_AUTOGEN_DEF = NO
#---------------------------------------------------------------------------
# Configuration options related to the preprocessor
#---------------------------------------------------------------------------
# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will
# evaluate all C-preprocessor directives found in the sources and include
# files.
ENABLE_PREPROCESSING = YES
# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro
# names in the source code. If set to NO (the default) only conditional
# compilation will be performed. Macro expansion can be done in a controlled
# way by setting EXPAND_ONLY_PREDEF to YES.
MACRO_EXPANSION = NO
# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES
# then the macro expansion is limited to the macros specified with the
# PREDEFINED and EXPAND_AS_PREDEFINED tags.
EXPAND_ONLY_PREDEF = NO
# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files
# in the INCLUDE_PATH (see below) will be search if a #include is found.
SEARCH_INCLUDES = YES
# The INCLUDE_PATH tag can be used to specify one or more directories that
# contain include files that are not input files but should be processed by
# the preprocessor.
INCLUDE_PATH =
# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard
# patterns (like *.h and *.hpp) to filter out the header-files in the
# directories. If left blank, the patterns specified with FILE_PATTERNS will
# be used.
INCLUDE_FILE_PATTERNS =
# The PREDEFINED tag can be used to specify one or more macro names that
# are defined before the preprocessor is started (similar to the -D option of
# gcc). The argument of the tag is a list of macros of the form: name
# or name=definition (no spaces). If the definition and the = are
# omitted =1 is assumed.
PREDEFINED = BUILD_DATE
# If the MACRO_EXPANSION and EXPAND_PREDEF_ONLY tags are set to YES then
# this tag can be used to specify a list of macro names that should be expanded.
# The macro definition that is found in the sources will be used.
# Use the PREDEFINED tag if you want to use a different macro definition.
EXPAND_AS_DEFINED =
# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then
# doxygen's preprocessor will remove all function-like macros that are alone
# on a line and do not end with a semicolon. Such function macros are typically
# used for boiler-plate code, and will confuse the parser if not removed.
SKIP_FUNCTION_MACROS = YES
#---------------------------------------------------------------------------
# Configuration::addtions related to external references
#---------------------------------------------------------------------------
# The TAGFILES tag can be used to specify one or more tagfiles.
TAGFILES =
# When a file name is specified after GENERATE_TAGFILE, doxygen will create
# a tag file that is based on the input files it reads.
GENERATE_TAGFILE =
# If the ALLEXTERNALS tag is set to YES all external classes will be listed
# in the class index. If set to NO only the inherited external classes
# will be listed.
ALLEXTERNALS = NO
# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed
# in the modules index. If set to NO, only the current project's groups will
# be listed.
EXTERNAL_GROUPS = YES
# The PERL_PATH should be the absolute path and name of the perl script
# interpreter (i.e. the result of `which perl').
PERL_PATH = /usr/bin/perl
#---------------------------------------------------------------------------
# Configuration options related to the dot tool
#---------------------------------------------------------------------------
# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will
# generate a inheritance diagram (in Html, RTF and LaTeX) for classes with base or
# super classes. Setting the tag to NO turns the diagrams off. Note that this
# option is superceded by the HAVE_DOT option below. This is only a fallback. It is
# recommended to install and use dot, since it yield more powerful graphs.
CLASS_DIAGRAMS = YES
# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is
# available from the path. This tool is part of Graphviz, a graph visualization
# toolkit from AT&T and Lucent Bell Labs. The other options in this section
# have no effect if this option is set to NO (the default)
HAVE_DOT = NO
# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen
# will generate a graph for each documented class showing the direct and
# indirect inheritance relations. Setting this tag to YES will force the
# the CLASS_DIAGRAMS tag to NO.
CLASS_GRAPH = YES
# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen
# will generate a graph for each documented class showing the direct and
# indirect implementation dependencies (inheritance, containment, and
# class references variables) of the class with other documented classes.
COLLABORATION_GRAPH = YES
# If set to YES, the inheritance and collaboration graphs will show the
# relations between templates and their instances.
TEMPLATE_RELATIONS = YES
# If set to YES, the inheritance and collaboration graphs will hide
# inheritance and usage relations if the target is undocumented
# or is not a class.
HIDE_UNDOC_RELATIONS = YES
# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT
# tags are set to YES then doxygen will generate a graph for each documented
# file showing the direct and indirect include dependencies of the file with
# other documented files.
INCLUDE_GRAPH = YES
# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and
# HAVE_DOT tags are set to YES then doxygen will generate a graph for each
# documented header file showing the documented files that directly or
# indirectly include this file.
INCLUDED_BY_GRAPH = YES
# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen
# will graphical hierarchy of all classes instead of a textual one.
GRAPHICAL_HIERARCHY = YES
# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images
# generated by dot. Possible values are png, jpg, or gif
# If left blank png will be used.
DOT_IMAGE_FORMAT = png
# The tag DOT_PATH can be used to specify the path where the dot tool can be
# found. If left blank, it is assumed the dot tool can be found on the path.
DOT_PATH =
# The DOTFILE_DIRS tag can be used to specify one or more directories that
# contain dot files that are included in the documentation (see the
# \dotfile command).
DOTFILE_DIRS =
# The MAX_DOT_GRAPH_WIDTH tag can be used to set the maximum allowed width
# (in pixels) of the graphs generated by dot. If a graph becomes larger than
# this value, doxygen will try to truncate the graph, so that it fits within
# the specified constraint. Beware that most browsers cannot cope with very
# large images.
MAX_DOT_GRAPH_WIDTH = 1024
# The MAX_DOT_GRAPH_HEIGHT tag can be used to set the maximum allows height
# (in pixels) of the graphs generated by dot. If a graph becomes larger than
# this value, doxygen will try to truncate the graph, so that it fits within
# the specified constraint. Beware that most browsers cannot cope with very
# large images.
MAX_DOT_GRAPH_HEIGHT = 1024
# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will
# generate a legend page explaining the meaning of the various boxes and
# arrows in the dot generated graphs.
GENERATE_LEGEND = YES
# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will
# remove the intermedate dot files that are used to generate
# the various graphs.
DOT_CLEANUP = YES
#---------------------------------------------------------------------------
# Configuration::addtions related to the search engine
#---------------------------------------------------------------------------
# The SEARCHENGINE tag specifies whether or not a search engine should be
# used. If set to NO the values of all tags below this one will be ignored.
SEARCHENGINE = NO
# The CGI_NAME tag should be the name of the CGI script that
# starts the search engine (doxysearch) with the correct parameters.
# A script with this name will be generated by doxygen.
CGI_NAME = search.cgi
# The CGI_URL tag should be the absolute URL to the directory where the
# cgi binaries are located. See the documentation of your http daemon for
# details.
CGI_URL =
# The DOC_URL tag should be the absolute URL to the directory where the
# documentation is located. If left blank the absolute path to the
# documentation, with file:// prepended to it, will be used.
DOC_URL =
# The DOC_ABSPATH tag should be the absolute path to the directory where the
# documentation is located. If left blank the directory on the local machine
# will be used.
DOC_ABSPATH =
# The BIN_ABSPATH tag must point to the directory where the doxysearch binary
# is installed.
BIN_ABSPATH = /usr/local/bin/
# The EXT_DOC_PATHS tag can be used to specify one or more paths to
# documentation generated for other projects. This allows doxysearch to search
# the documentation for these projects as well.
EXT_DOC_PATHS =

View File

@@ -0,0 +1,477 @@
#! /usr/bin/env python3
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# ***** END GPL LICENCE BLOCK *****
######################################################
#
# Name:
# dna.py
#
# Description:
# Creates a browsable DNA output to HTML.
#
# Author:
# Jeroen Bakker
#
# Version:
# v0.1 (12-05-2009) - migration of original source code to python.
# Added code to support blender 2.5 branch
# v0.2 (25-05-2009) - integrated with BlendFileReader.py
#
# Input:
# blender build executable
#
# Output:
# dna.html
# dna.css (will only be created when not existing)
#
# Startup:
# ./blender -P BlendFileDnaExporter.py
#
# Process:
# 1: write blend file with SDNA info
# 2: read blend header from blend file
# 3: seek DNA1 file-block
# 4: read dna record from blend file
# 5: close and eventually delete temp blend file
# 6: export dna to html and css
# 7: quit blender
#
######################################################
import struct
import sys
import getopt # command line arguments handling
from string import Template # strings completion
# logs
import logging
log = logging.getLogger("BlendFileDnaExporter")
if '--dna-debug' in sys.argv:
logging.basicConfig(level=logging.DEBUG)
else:
logging.basicConfig(level=logging.INFO)
class DNACatalogHTML:
'''
DNACatalog is a catalog of all information in the DNA1 file-block
'''
def __init__(self, catalog, bpy_module = None):
self.Catalog = catalog
self.bpy = bpy_module
def WriteToHTML(self, handle):
dna_html_template = """
<!DOCTYPE html PUBLIC -//W3C//DTD HTML 4.01 Transitional//EN http://www.w3.org/TR/html4/loose.dtd>
<html>
<head>
<link rel="stylesheet" type="text/css" href="dna.css" media="screen, print" />
<meta http-equiv="Content-Type" content="text/html"; charset="ISO-8859-1" />
<title>The mystery of the blend</title>
</head>
<body>
<div class=title>
Blender ${version}<br/>
Internal SDNA structures
</div>
Architecture: ${bitness} ${endianness}<br/>
Build revision: <a href="https://svn.blender.org/svnroot/bf-blender/!svn/bc/${revision}/trunk/">${revision}</a><br/>
File format reference: <a href="mystery_of_the_blend.html">The mystery of the blend</a> by Jeroen Bakker<br/>
<h1>Index of blender structures</h1>
<ul class=multicolumn>
${structs_list}
</ul>
${structs_content}
</body>
</html>"""
header = self.Catalog.Header
bpy = self.bpy
# ${version} and ${revision}
if bpy:
version = '.'.join(map(str, bpy.app.version))
revision = bpy.app.build_revision[:-1]
else:
version = str(header.Version)
revision = 'Unknown'
# ${bitness}
if header.PointerSize == 8:
bitness = '64 bit'
else:
bitness = '32 bit'
# ${endianness}
if header.LittleEndianness:
endianess= 'Little endianness'
else:
endianess= 'Big endianness'
# ${structs_list}
log.debug("Creating structs index")
structs_list = ''
list_item = '<li class="multicolumn">({0}) <a href="#{1}">{1}</a></li>\n'
structureIndex = 0
for structure in self.Catalog.Structs:
structs_list += list_item.format(structureIndex, structure.Type.Name)
structureIndex+=1
# ${structs_content}
log.debug("Creating structs content")
structs_content = ''
for structure in self.Catalog.Structs:
log.debug(structure.Type.Name)
structs_content += self.Structure(structure)
d = dict(
version = version,
revision = revision,
bitness = bitness,
endianness = endianess,
structs_list = structs_list,
structs_content = structs_content
)
dna_html = Template(dna_html_template).substitute(d)
dna_html = self.format(dna_html)
handle.write(dna_html)
def Structure(self, structure):
struct_table_template = """
<table><a name="${struct_name}"></a>
<caption><a href="#${struct_name}">${struct_name}</a></caption>
<thead>
<tr>
<th>reference</th>
<th>structure</th>
<th>type</th>
<th>name</th>
<th>offset</th>
<th>size</th>
</tr>
</thead>
<tbody>
${fields}
</tbody>
</table>
<label>Total size: ${size} bytes</label><br/>
<label>(<a href="#top">top</a>)</label><br/>"""
d = dict(
struct_name = structure.Type.Name,
fields = self.StructureFields(structure, None, 0),
size = str(structure.Type.Size)
)
struct_table = Template(struct_table_template).substitute(d)
return struct_table
def StructureFields(self, structure, parentReference, offset):
fields = ''
for field in structure.Fields:
fields += self.StructureField(field, structure, parentReference, offset)
offset += field.Size(self.Catalog.Header)
return fields
def StructureField(self, field, structure, parentReference, offset):
structure_field_template = """
<tr>
<td>${reference}</td>
<td>${struct}</td>
<td>${type}</td>
<td>${name}</td>
<td>${offset}</td>
<td>${size}</td>
</tr>"""
if field.Type.Structure == None or field.Name.IsPointer():
# ${reference}
reference = field.Name.AsReference(parentReference)
# ${struct}
if parentReference != None:
struct = '<a href="#{0}">{0}</a>'.format(structure.Type.Name)
else:
struct = structure.Type.Name
# ${type}
type = field.Type.Name
# ${name}
name = field.Name.Name
# ${offset}
# offset already set
# ${size}
size = field.Size(self.Catalog.Header)
d = dict(
reference = reference,
struct = struct,
type = type,
name = name,
offset = offset,
size = size
)
structure_field = Template(structure_field_template).substitute(d)
elif field.Type.Structure != None:
reference = field.Name.AsReference(parentReference)
structure_field = self.StructureFields(field.Type.Structure, reference, offset)
return structure_field
def indent(self, input, dent, startswith = ''):
output = ''
if dent < 0:
for line in input.split('\n'):
dent = abs(dent)
output += line[dent:] + '\n' # unindent of a desired amount
elif dent == 0:
for line in input.split('\n'):
output += line.lstrip() + '\n' # remove indentation completely
elif dent > 0:
for line in input.split('\n'):
output += ' '* dent + line + '\n'
return output
def format(self, input):
diff = {
'\n<!DOCTYPE':'<!DOCTYPE',
'\n</ul>' :'</ul>',
'<a name' :'\n<a name',
'<tr>\n' :'<tr>',
'<tr>' :' <tr>',
'</th>\n' :'</th>',
'</td>\n' :'</td>',
'<tbody>\n' :'<tbody>'
}
output = self.indent(input, 0)
for key, value in diff.items():
output = output.replace(key, value)
return output
def WriteToCSS(self, handle):
'''
Write the Cascading stylesheet template to the handle
It is expected that the handle is a Filehandle
'''
css = """
@CHARSET "ISO-8859-1";
body {
font-family: verdana;
font-size: small;
}
div.title {
font-size: large;
text-align: center;
}
h1 {
page-break-before: always;
}
h1, h2 {
background-color: #D3D3D3;
color:#404040;
margin-right: 3%;
padding-left: 40px;
}
h1:hover{
background-color: #EBEBEB;
}
h3 {
padding-left: 40px;
}
table {
border-width: 1px;
border-style: solid;
border-color: #000000;
border-collapse: collapse;
width: 94%;
margin: 20px 3% 10px;
}
caption {
margin-bottom: 5px;
}
th {
background-color: #000000;
color:#ffffff;
padding-left:5px;
padding-right:5px;
}
tr {
}
td {
border-width: 1px;
border-style: solid;
border-color: #a0a0a0;
padding-left:5px;
padding-right:5px;
}
label {
float:right;
margin-right: 3%;
}
ul.multicolumn {
list-style:none;
float:left;
padding-right:0px;
margin-right:0px;
}
li.multicolumn {
float:left;
width:200px;
margin-right:0px;
}
a {
color:#a000a0;
text-decoration:none;
}
a:hover {
color:#a000a0;
text-decoration:underline;
}
"""
css = self.indent(css, 0)
handle.write(css)
def usage():
print("\nUsage: \n\tblender2.5 -b -P BlendFileDnaExporter_25.py [-- [options]]")
print("Options:")
print("\t--dna-keep-blend: doesn't delete the produced blend file DNA export to html")
print("\t--dna-debug: sets the logging level to DEBUG (lots of additional info)")
print("\t--dna-versioned saves version informations in the html and blend filenames")
print("\t--dna-overwrite-css overwrite dna.css, useful when modifying css in the script")
print("Examples:")
print("\tdefault: % blender2.5 -b -P BlendFileDnaExporter_25.py")
print("\twith options: % blender2.5 -b -P BlendFileDnaExporter_25.py -- --dna-keep-blend --dna-debug\n")
######################################################
# Main
######################################################
def main():
import os, os.path
try:
bpy = __import__('bpy')
# Files
if '--dna-versioned' in sys.argv:
blender_version = '_'.join(map(str, bpy.app.version))
filename = 'dna-{0}-{1}_endian-{2}-r{3}'.format(sys.arch, sys.byteorder, blender_version, bpy.app.build_revision[2:-1])
else:
filename = 'dna'
dir = os.path.dirname(__file__)
Path_Blend = os.path.join(dir, filename + '.blend') # temporary blend file
Path_HTML = os.path.join(dir, filename + '.html') # output html file
Path_CSS = os.path.join(dir, 'dna.css') # output css file
# create a blend file for dna parsing
if not os.path.exists(Path_Blend):
log.info("1: write temp blend file with SDNA info")
log.info(" saving to: " + Path_Blend)
try:
bpy.ops.wm.save_as_mainfile(filepath = Path_Blend, copy = True, compress = False)
except:
log.error("Filename {0} does not exist and can't be created... quitting".format(Path_Blend))
return
else:
log.info("1: found blend file with SDNA info")
log.info(" " + Path_Blend)
# read blend header from blend file
log.info("2: read file:")
if not dir in sys.path:
sys.path.append(dir)
import BlendFileReader
handle = BlendFileReader.openBlendFile(Path_Blend)
blendfile = BlendFileReader.BlendFile(handle)
catalog = DNACatalogHTML(blendfile.Catalog, bpy)
# close temp file
handle.close()
# deleting or not?
if '--dna-keep-blend' in sys.argv:
# keep the blend, useful for studying hexdumps
log.info("5: closing blend file:")
log.info(" {0}".format(Path_Blend))
else:
# delete the blend
log.info("5: close and delete temp blend:")
log.info(" {0}".format(Path_Blend))
os.remove(Path_Blend)
# export dna to xhtml
log.info("6: export sdna to xhtml file")
handleHTML = open(Path_HTML, "w")
catalog.WriteToHTML(handleHTML)
handleHTML.close()
# only write the css when doesn't exist or at explicit request
if not os.path.exists(Path_CSS) or '--dna-overwrite-css' in sys.argv:
handleCSS = open(Path_CSS, "w")
catalog.WriteToCSS(handleCSS)
handleCSS.close()
# quit blender
if not bpy.app.background:
log.info("7: quit blender")
bpy.ops.wm.exit_blender()
except ImportError:
log.warning(" skipping, not running in Blender")
usage()
sys.exit(2)
if __name__ == '__main__':
main()

View File

@@ -0,0 +1,446 @@
#! /usr/bin/env python3
# ***** BEGIN GPL LICENSE BLOCK *****
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software Foundation,
# Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# ***** END GPL LICENCE BLOCK *****
######################################################
# Importing modules
######################################################
import os
import struct
import gzip
import tempfile
import logging
log = logging.getLogger("BlendFileReader")
######################################################
# module global routines
######################################################
def ReadString(handle, length):
'''
ReadString reads a String of given length or a zero terminating String
from a file handle
'''
if length != 0:
return handle.read(length).decode()
else:
# length == 0 means we want a zero terminating string
result = ""
s = ReadString(handle, 1)
while s!="\0":
result += s
s = ReadString(handle, 1)
return result
def Read(type, handle, fileheader):
'''
Reads the chosen type from a file handle
'''
def unpacked_bytes(type_char, size):
return struct.unpack(fileheader.StructPre + type_char, handle.read(size))[0]
if type == 'ushort':
return unpacked_bytes("H", 2) # unsigned short
elif type == 'short':
return unpacked_bytes("h", 2) # short
elif type == 'uint':
return unpacked_bytes("I", 4) # unsigned int
elif type == 'int':
return unpacked_bytes("i", 4) # int
elif type == 'float':
return unpacked_bytes("f", 4) # float
elif type == 'ulong':
return unpacked_bytes("Q", 8) # unsigned long
elif type == 'pointer':
# The pointersize is given by the header (BlendFileHeader).
if fileheader.PointerSize == 4:
return Read('uint', handle, fileheader)
if fileheader.PointerSize == 8:
return Read('ulong', handle, fileheader)
def openBlendFile(filename):
'''
Open a filename, determine if the file is compressed and returns a handle
'''
handle = open(filename, 'rb')
magic = ReadString(handle, 7)
if magic in ("BLENDER", "BULLETf"):
log.debug("normal blendfile detected")
handle.seek(0, os.SEEK_SET)
return handle
else:
log.debug("gzip blendfile detected?")
handle.close()
log.debug("decompressing started")
fs = gzip.open(filename, "rb")
handle = tempfile.TemporaryFile()
data = fs.read(1024*1024)
while data:
handle.write(data)
data = fs.read(1024*1024)
log.debug("decompressing finished")
fs.close()
log.debug("resetting decompressed file")
handle.seek(0, os.SEEK_SET)
return handle
def Align(handle):
'''
Aligns the filehandle on 4 bytes
'''
offset = handle.tell()
trim = offset % 4
if trim != 0:
handle.seek(4-trim, os.SEEK_CUR)
######################################################
# module classes
######################################################
class BlendFile:
'''
Reads a blendfile and store the header, all the fileblocks, and catalogue
structs foound in the DNA fileblock
- BlendFile.Header (BlendFileHeader instance)
- BlendFile.Blocks (list of BlendFileBlock instances)
- BlendFile.Catalog (DNACatalog instance)
'''
def __init__(self, handle):
log.debug("initializing reading blend-file")
self.Header = BlendFileHeader(handle)
self.Blocks = []
fileblock = BlendFileBlock(handle, self)
found_dna_block = False
while not found_dna_block:
if fileblock.Header.Code in ("DNA1", "SDNA"):
self.Catalog = DNACatalog(self.Header, handle)
found_dna_block = True
else:
fileblock.Header.skip(handle)
self.Blocks.append(fileblock)
fileblock = BlendFileBlock(handle, self)
# appending last fileblock, "ENDB"
self.Blocks.append(fileblock)
# seems unused?
"""
def FindBlendFileBlocksWithCode(self, code):
#result = []
#for block in self.Blocks:
#if block.Header.Code.startswith(code) or block.Header.Code.endswith(code):
#result.append(block)
#return result
"""
class BlendFileHeader:
'''
BlendFileHeader allocates the first 12 bytes of a blend file.
It contains information about the hardware architecture.
Header example: BLENDER_v254
BlendFileHeader.Magic (str)
BlendFileHeader.PointerSize (int)
BlendFileHeader.LittleEndianness (bool)
BlendFileHeader.StructPre (str) see http://docs.python.org/py3k/library/struct.html#byte-order-size-and-alignment
BlendFileHeader.Version (int)
'''
def __init__(self, handle):
log.debug("reading blend-file-header")
self.Magic = ReadString(handle, 7)
log.debug(self.Magic)
pointersize = ReadString(handle, 1)
log.debug(pointersize)
if pointersize == "-":
self.PointerSize = 8
if pointersize == "_":
self.PointerSize = 4
endianness = ReadString(handle, 1)
log.debug(endianness)
if endianness == "v":
self.LittleEndianness = True
self.StructPre = "<"
if endianness == "V":
self.LittleEndianness = False
self.StructPre = ">"
version = ReadString(handle, 3)
log.debug(version)
self.Version = int(version)
log.debug("{0} {1} {2} {3}".format(self.Magic, self.PointerSize, self.LittleEndianness, version))
class BlendFileBlock:
'''
BlendFileBlock.File (BlendFile)
BlendFileBlock.Header (FileBlockHeader)
'''
def __init__(self, handle, blendfile):
self.File = blendfile
self.Header = FileBlockHeader(handle, blendfile.Header)
def Get(self, handle, path):
log.debug("find dna structure")
dnaIndex = self.Header.SDNAIndex
dnaStruct = self.File.Catalog.Structs[dnaIndex]
log.debug("found " + dnaStruct.Type.Name)
handle.seek(self.Header.FileOffset, os.SEEK_SET)
return dnaStruct.GetField(self.File.Header, handle, path)
class FileBlockHeader:
'''
FileBlockHeader contains the information in a file-block-header.
The class is needed for searching to the correct file-block (containing Code: DNA1)
Code (str)
Size (int)
OldAddress (pointer)
SDNAIndex (int)
Count (int)
FileOffset (= file pointer of datablock)
'''
def __init__(self, handle, fileheader):
self.Code = ReadString(handle, 4).strip()
if self.Code != "ENDB":
self.Size = Read('uint', handle, fileheader)
self.OldAddress = Read('pointer', handle, fileheader)
self.SDNAIndex = Read('uint', handle, fileheader)
self.Count = Read('uint', handle, fileheader)
self.FileOffset = handle.tell()
else:
self.Size = Read('uint', handle, fileheader)
self.OldAddress = 0
self.SDNAIndex = 0
self.Count = 0
self.FileOffset = handle.tell()
#self.Code += ' ' * (4 - len(self.Code))
log.debug("found blend-file-block-fileheader {0} {1}".format(self.Code, self.FileOffset))
def skip(self, handle):
handle.read(self.Size)
class DNACatalog:
'''
DNACatalog is a catalog of all information in the DNA1 file-block
Header = None
Names = None
Types = None
Structs = None
'''
def __init__(self, fileheader, handle):
log.debug("building DNA catalog")
self.Names=[]
self.Types=[]
self.Structs=[]
self.Header = fileheader
SDNA = ReadString(handle, 4)
# names
NAME = ReadString(handle, 4)
numberOfNames = Read('uint', handle, fileheader)
log.debug("building #{0} names".format(numberOfNames))
for i in range(numberOfNames):
name = ReadString(handle,0)
self.Names.append(DNAName(name))
Align(handle)
# types
TYPE = ReadString(handle, 4)
numberOfTypes = Read('uint', handle, fileheader)
log.debug("building #{0} types".format(numberOfTypes))
for i in range(numberOfTypes):
type = ReadString(handle,0)
self.Types.append(DNAType(type))
Align(handle)
# type lengths
TLEN = ReadString(handle, 4)
log.debug("building #{0} type-lengths".format(numberOfTypes))
for i in range(numberOfTypes):
length = Read('ushort', handle, fileheader)
self.Types[i].Size = length
Align(handle)
# structs
STRC = ReadString(handle, 4)
numberOfStructures = Read('uint', handle, fileheader)
log.debug("building #{0} structures".format(numberOfStructures))
for structureIndex in range(numberOfStructures):
type = Read('ushort', handle, fileheader)
Type = self.Types[type]
structure = DNAStructure(Type)
self.Structs.append(structure)
numberOfFields = Read('ushort', handle, fileheader)
for fieldIndex in range(numberOfFields):
fTypeIndex = Read('ushort', handle, fileheader)
fNameIndex = Read('ushort', handle, fileheader)
fType = self.Types[fTypeIndex]
fName = self.Names[fNameIndex]
structure.Fields.append(DNAField(fType, fName))
class DNAName:
'''
DNAName is a C-type name stored in the DNA.
Name = str
'''
def __init__(self, name):
self.Name = name
def AsReference(self, parent):
if parent == None:
result = ""
else:
result = parent+"."
result = result + self.ShortName()
return result
def ShortName(self):
result = self.Name;
result = result.replace("*", "")
result = result.replace("(", "")
result = result.replace(")", "")
Index = result.find("[")
if Index != -1:
result = result[0:Index]
return result
def IsPointer(self):
return self.Name.find("*")>-1
def IsMethodPointer(self):
return self.Name.find("(*")>-1
def ArraySize(self):
result = 1
Temp = self.Name
Index = Temp.find("[")
while Index != -1:
Index2 = Temp.find("]")
result*=int(Temp[Index+1:Index2])
Temp = Temp[Index2+1:]
Index = Temp.find("[")
return result
class DNAType:
'''
DNAType is a C-type stored in the DNA
Name = str
Size = int
Structure = DNAStructure
'''
def __init__(self, aName):
self.Name = aName
self.Structure=None
class DNAStructure:
'''
DNAType is a C-type structure stored in the DNA
Type = DNAType
Fields = [DNAField]
'''
def __init__(self, aType):
self.Type = aType
self.Type.Structure = self
self.Fields=[]
def GetField(self, header, handle, path):
splitted = path.partition(".")
name = splitted[0]
rest = splitted[2]
offset = 0;
for field in self.Fields:
if field.Name.ShortName() == name:
log.debug("found "+name+"@"+str(offset))
handle.seek(offset, os.SEEK_CUR)
return field.DecodeField(header, handle, rest)
else:
offset += field.Size(header)
log.debug("error did not find "+path)
return None
class DNAField:
'''
DNAField is a coupled DNAType and DNAName.
Type = DNAType
Name = DNAName
'''
def __init__(self, aType, aName):
self.Type = aType
self.Name = aName
def Size(self, header):
if self.Name.IsPointer() or self.Name.IsMethodPointer():
return header.PointerSize*self.Name.ArraySize()
else:
return self.Type.Size*self.Name.ArraySize()
def DecodeField(self, header, handle, path):
if path == "":
if self.Name.IsPointer():
return Read('pointer', handle, header)
if self.Type.Name=="int":
return Read('int', handle, header)
if self.Type.Name=="short":
return Read('short', handle, header)
if self.Type.Name=="float":
return Read('float', handle, header)
if self.Type.Name=="char":
return ReadString(handle, self.Name.ArraySize())
else:
return self.Type.Structure.GetField(header, handle, path)

View File

@@ -0,0 +1,29 @@
To inspect the blend-file-format used by a certain version of blender 2.5x,
navigate to this folder and run this command:
blender2.5 -b -P BlendFileDnaExporter_25.py
where "blender2.5" is your blender executable or a symlink to it.
This creates a temporary dna.blend to be inspected and it produces two new files:
* dna.html: the list of all the structures saved in a blend file with the blender2.5
executable you have used. If you enable build informations when you build blender,
the dna.html file will also show which svn revision the html refers to.
* dna.css: the css for the html above
Below you have the help message with a list of options you can use.
Usage:
blender2.5 -b -P BlendFileDnaExporter_25.py [-- [options]]
Options:
--dna-keep-blend: doesn't delete the produced blend file DNA export to html
--dna-debug: sets the logging level to DEBUG (lots of additional info)
--dna-versioned saves version informations in the html and blend filenames
--dna-overwrite-css overwrite dna.css, useful when modifying css in the script
Examples:
default: % blender2.5 -b -P BlendFileDnaExporter_25.py
with options: % blender2.5 -b -P BlendFileDnaExporter_25.py -- --dna-keep-blend --dna-debug

View File

@@ -0,0 +1,204 @@
@CHARSET "ISO-8859-1";
table {
border-width: 1px;
border-style: solid;
border-color: #000000;
border-collapse: collapse;
width: 94%;
margin: 10px 3%;
}
DIV.title {
font-size: 30px;
font-weight: bold;
text-align: center
}
DIV.subtitle {
font-size: large;
text-align: center
}
DIV.contact {
margin:30px 3%;
}
@media print {
DIV.contact {
margin-top: 300px;
}
DIV.title {
margin-top: 400px;
}
}
label {
font-weight: bold;
width: 100px;
float: left;
}
label:after {
content: ":";
}
TH {
background-color: #000000;
color: #ffffff;
padding-left: 5px;
padding-right: 5px;
}
TR {
}
TD {
border-width: 1px;
border-style: solid;
border-color: #a0a0a0;
padding-left: 5px;
padding-right: 5px;
}
BODY {
font-family: verdana;
font-size: small;
}
H1 {
page-break-before: always;
}
H1, H2, H3, H4 {
margin-top: 30px;
margin-right: 3%;
padding: 3px 3%;
color: #404040;
cursor: pointer;
}
H1, H2 {
background-color: #D3D3D3;
}
H3, H4 {
padding-top: 5px;
padding-bottom: 5px;
}
H1:hover, H2:hover, H3:hover, H4:hover {
background-color: #EBEBEB;
}
CODE.evidence {
font-size:larger
}
CODE.block {
color: #000000;
background-color: #DDDC75;
margin: 10px 0;
padding: 5px;
border-width: 1px;
border-style: dotted;
border-color: #000000;
white-space: pre;
display: block;
font-size: 2 em;
}
ul {
margin: 10px 3%;
}
li {
margin: 0 -15px;
}
ul.multicolumn {
list-style: none;
float: left;
padding-right: 0px;
margin-right: 0px;
}
li.multicolumn {
float: left;
width: 200px;
margin-right: 0px;
}
@media screen {
p {
margin: 10px 3%;
line-height: 130%;
}
}
span.fade {
color: gray;
}
span.header {
color: green;
}
span.header-greyed {
color: #4CBE4B;
}
span.data {
color: blue;
}
span.data-greyed {
color: #5D99C4;
}
span.descr {
color: red;
}
div.box {
margin: 15px 3%;
border-style: dotted;
border-width: 1px;
}
div.box-solid {
margin: 15px 3%;
border-style: solid;
border-width: 1px;
}
p.box-title {
font-style: italic;
font-size: 110%;
cursor: pointer;
}
p.box-title:hover {
background-color: #EBEBEB;
}
p.code {
font-family: "Courier New", Courier, monospace;
}
a {
color: #a000a0;
text-decoration: none;
}
a:hover {
color: #a000a0;
text-decoration: underline;
}
td.skip {
color: #808080;
padding-top: 10px;
padding-bottom: 10px;
text-align: center;
}

View File

@@ -0,0 +1,835 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<link rel="stylesheet" type="text/css" href="mystery_of_the_blend.css" media="screen, print">
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>The mystery of the blend</title>
</head>
<body>
<div class="title">The mystery of the blend</div>
<div class="subtitle">The blender file-format explained</div>
<div class="contact">
<label>Author</label> Jeroen Bakker<br>
<label>Email</label> <a href="mailto:j.bakker@atmind.nl">j.bakker@atmind.nl</a><br>
<label>Website</label> <a href="http://www.atmind.nl/blender/">http://www.atmind.nl/blender</a><br>
<label>Version</label> 06-10-2010<br>
</div>
<a name="introduction" href="#introduction" ><h2>Introduction</h2></a>
</a>
<p>In this article I will describe the
blend-file-format with a request to tool-makers to support blend-file.
</p>
<p>First I'll describe how Blender works with blend-files. You'll notice
why the blend-file-format is not that well documented, as from
Blender's perspective this is not needed.
We look at the global file-structure of a blend-file (the file-header
and file-blocks).
After this is explained, we go deeper to the core of the blend-file, the
DNA-structures. They hold the blue-prints of the blend-file and the key
asset of understanding blend-files.
When that's done we can use these DNA-structures to read information
from elsewhere in the blend-file.
</p>
<p>
In this article we'll be using the default blend-file from Blender 2.54,
with the goal to read the output resolution from the Scene.
The article is written to be programming language independent and I've
setup a web-site for support.
</p>
<a name="loading-and-saving-in-blender" href="#loading-and-saving-in-blender">
<h2>Loading and saving in Blender</h2>
</a>
<p>
Loading and saving in Blender is very fast and Blender is known to
have excellent downward and upward compatibility. Ton Roosendaal
demonstrated that in December 2008 by loading a 1.0 blend-file using
Blender 2.48a [ref: <a href="http://www.blendernation.com/2008/12/01/blender-dna-rna-and-backward-compatibility/">http://www.blendernation.com/2008/12/01/blender-dna-rna-and-backward-compatibility/</a>].
</p>
<p>
Saving complex scenes in Blender is done within seconds. Blender
achieves this by saving data in memory to disk without any
transformations or translations. Blender only adds file-block-headers to
this data. A file-block-header contains clues on how to interpret the
data. After the data, all internally Blender structures are stored.
These structures will act as blue-prints when Blender loads the file.
Blend-files can be different when stored on different hardware platforms
or Blender releases. There is no effort taken to make blend-files
binary the same. Blender creates the blend-files in this manner since
release 1.0. Backward and upwards compatibility is not implemented when
saving the file, this is done during loading.
</p>
<p>
When Blender loads a blend-file, the DNA-structures are read first.
Blender creates a catalog of these DNA-structures. Blender uses this
catalog together with the data in the file, the internal Blender
structures of the Blender release you're using and a lot of
transformation and translation logic to implement the backward and
upward compatibility. In the source code of blender there is actually
logic which can transform and translate every structure used by a
Blender release to the one of the release you're using [ref: <a href="http://download.blender.org/source/blender-2.48a.tar.gz">http://download.blender.org/source/blender-2.48a.tar.gz</a>
<a href="https://svn.blender.org/svnroot/bf-blender/tags/blender-2.48-release/source/blender/blenloader/intern/readfile.c">blender/blenloader/intern/readfile.c</a> lines
4946-7960]. The more difference between releases the more logic is
executed.
</p>
<p>
The blend-file-format is not well documented, as it does not differ from
internally used structures and the file can really explain itself.
</p>
<a name="global-file-structure" href="#global-file-structure">
<h2>Global file-structure</h2>
</a>
<p>
This section explains how the global file-structure can be read.
</p>
<ul>
<li>A blend-file always start with the <b>file-header</b></li>
<li>After the file-header, follows a list of <b>file-blocks</b> (the default blend file of Blender 2.48 contains more than 400 of these file-blocks).</li>
<li>Each file-block has a <b>file-block header</b> and <b>file-block data</b></li>
<li>At the end of the blend-file there is a section called "<a href="#structure-DNA" style="font-weight:bold">Structure DNA</a>", which lists all the internal structures of the Blender release the file was created in</li>
<li>The blend-file ends with a file-block called 'ENDB'</li>
</ul>
<!-- file scheme -->
<div class="box-solid" style="width:20%; margin-left:35%; font-size:0.8em;">
<p class="code"><b>File.blend</b></p>
<div class="box"><p class="code">File-header</p></div>
<div class="box-solid"><p class="code">File-block</p>
<div class="box"><p class="code">Header</p></div>
<div class="box"><p class="code">Data</p></div>
</div>
<div class="box" style="border-style:dashed"><p class="code">File-block</p></div>
<div class="box" style="border-style:dashed"><p class="code">File-block</p></div>
<div class="box-solid"><p class="code">File-block 'Structure DNA'</p>
<div class="box"><p class="code">Header ('DNA1')</p></div>
<div class="box-solid">
<p class="code">Data ('SDNA')</p>
<div class="box">
<p class="code">Names ('NAME')</p>
</div>
<div class="box">
<p class="code">Types ('TYPE')</p>
</div>
<div class="box">
<p class="code">Lengths ('TLEN')</p>
</div>
<div class="box">
<p class="code">Structures ('STRC')</p>
</div>
</div>
</div>
<div class="box-solid"><p class="code">File-Block 'ENDB'</p></div>
</div><!-- end of file scheme -->
<a name="file-header" href="#file-header">
<h3>File-Header</h3>
</a>
<p>
The first 12 bytes of every blend-file is the file-header. The
file-header has information on Blender (version-number) and the PC the
blend-file was saved on (pointer-size and endianness). This is required
as all data inside the blend-file is ordered in that way, because no
translation or transformation is done during saving.
The next table describes the information in the file-header.
</p>
<table>
<caption>File-header</caption>
<thead>
<tr><th>reference</th>
<th>structure</th>
<th>type</th>
<th>offset</th>
<th>size</th></tr>
</thead>
<tbody>
<tr><td>identifier</td>
<td>char[7]</td>
<td>File identifier (always 'BLENDER')</td>
<td>0</td>
<td>7</td></tr>
<tr><td>pointer-size</td>
<td>char</td>
<td>Size of a pointer; all pointers in the file are stored in this format. '_' means 4 bytes or 32 bit and '-' means 8 bytes or 64 bits.</td>
<td>7</td>
<td>1</td></tr>
<tr><td>endianness</td>
<td>char</td>
<td>Type of byte ordering used; 'v' means little endian and 'V' means big endian.</td>
<td>8</td>
<td>1</td></tr>
<tr><td>version-number</td>
<td>char[3]</td>
<td>Version of Blender the file was created in; '254' means version 2.54</td>
<td>9</td>
<td>3</td></tr>
</tbody>
</table>
<p>
<a href="http://en.wikipedia.org/wiki/Endianness">Endianness</a> addresses the way values are ordered in a sequence of bytes(see the <a href="#example-endianess">example</a> below):
</p>
<ul>
<li>in a big endian ordering, the largest part of the value is placed on the first byte and
the lowest part of the value is placed on the last byte,</li>
<li>in a little endian ordering, largest part of the value is placed on the last byte
and the smallest part of the value is placed on the first byte.</li>
</ul>
<p>
Nowadays, little-endian is the most commonly used.
</p>
<a name="example-endianess"></a>
<div class="box">
<p onclick="location.href='#example-endianess'" class="box-title">
Endianess Example
</p>
<p>
Writing the integer <code class="evidence">0x4A3B2C1Dh</code>, will be ordered:
<ul>
<li>in big endian as <code class="evidence">0x4Ah</code>, <code class="evidence">0x3Bh</code>, <code class="evidence">0x2Ch</code>, <code class="evidence">0x1Dh</code></li>
<li>in little endian as <code class="evidence">0x1Dh</code>, <code class="evidence">0x2Ch</code>, <code class="evidence">0x3Bh</code>, <code class="evidence">0x4Ah</code></li>
</ul>
</p>
</div>
<p>
Blender supports little-endian and big-endian.<br>
This means that when the endianness
is different between the blend-file and the PC your using, Blender changes it to the byte ordering
of your PC.
</p>
<a name="example-file-header"></a>
<div class="box">
<p onclick="location.href='#example-file-header'" class="box-title">
File-header Example
</p>
<p>
This hex-dump describes a file-header created with <code>blender</code> <code>2.54.0</code> on <code>little-endian</code> hardware with a <code>32 bits</code> pointer length.
<code class="block"> <span class="descr">pointer-size version-number
| |</span>
0000 0000: [42 4C 45 4E 44 45 52] [5F] [76] [32 35 34] BLENDER_v254 <span class="descr">
| |
identifier endianness</span></code>
</p>
</div>
<a name="file-blocks" href="#file-blocks"><h3>File-blocks</h3></a>
<p>
File-blocks contain a "<a href="#file-block-header">file-block header</a>" and "file-block data".
</p>
<a name="file-block-header" href="#file-block-header"><h3>File-block headers</h3></a>
<p>
The file-block-header describes:
</p>
<ul>
<li>the type of information stored in the
file-block</li>
<li>the total length of the data</li>
<li>the old memory
pointer at the moment the data was written to disk</li>
<li>the number of items of this information</li>
</ul>
<p>
As we can see below, depending on the pointer-size stored in the file-header, a file-block-header
can be 20 or 24 bytes long, hence it is always aligned at 4 bytes.
</p>
<table>
<caption>File-block-header</caption>
<thead>
<tr>
<th>reference</th>
<th>structure</th>
<th>type</th>
<th>offset</th>
<th>size</th></tr></thead>
<tbody>
<tr><td>code</td>
<td>char[4]</td>
<td>File-block identifier</td>
<td>0</td>
<td>4</td></tr>
<tr><td>size</td>
<td>integer</td>
<td>Total length of the data after the file-block-header</td>
<td>4</td>
<td>4</td></tr>
<tr><td>old memory address</td>
<td>void*</td>
<td>Memory address the structure was located when written to disk</td>
<td>8</td>
<td>pointer-size (4/8)</td></tr>
<tr><td>SDNA index</td>
<td>integer</td>
<td>Index of the SDNA structure</td>
<td>8+pointer-size</td>
<td>4</td></tr>
<tr><td>count</td>
<td>integer</td>
<td>Number of structure located in this file-block</td>
<td>12+pointer-size</td>
<td>4</td></tr>
</tbody>
</table>
<p>
The above table describes how a file-block-header is structured:
</p>
<ul>
<li><code>Code</code> describes different types of file-blocks. The code determines with what logic the data must be read. <br>
These codes also allows fast finding of data like Library, Scenes, Object or Materials as they all have a specific code. </li>
<li><code>Size</code> contains the total length of data after the file-block-header.
After the data a new file-block starts. The last file-block in the file
has code 'ENDB'.</li>
<li><code>Old memory address</code> contains the memory address when the structure
was last stored. When loading the file the structures can be placed on
different memory addresses. Blender updates pointers to these structures
to the new memory addresses.</li>
<li><code>SDNA index</code> contains the index in the DNA structures to be used when
reading this file-block-data. <br>
More information about this subject will be explained in the <a href="#reading-scene-information">Reading scene information section</a>.</li>
<li><code>Count</code> tells how many elements of the specific SDNA structure can be found in the data.</li>
</ul>
<a name="example-file-block-header"></a>
<div class="box">
<p onclick="location.href='#example-file-block-header'" class="box-title">
Example
</p>
<p>
This hex-dump describes a File-block (= <span class="header">File-block header</span> + <span class="data">File-block data</span>) created with <code>blender</code> <code>2.54</code> on <code>little-endian</code> hardware with a <code>32 bits</code> pointer length.<br>
<code class="block"><span class="descr"> file-block
identifier='SC' data size=1404 old pointer SDNA index=150
| | | |</span>
0000 4420: <span class="header">[53 43 00 00] [7C 05 00 00] [68 34 FB 0B] [96 00 00 00]</span> SC.. `... ./.. ....
0000 4430: <span class="header">[01 00 00 00]</span> <span class="data">[xx xx xx xx xx xx xx xx xx xx xx xx</span> .... xxxx xxxx xxxx<span class="descr">
| |
count=1 file-block data (next 1404 bytes)</span>
</code>
</p>
<ul>
<li>The code <code>'SC'+0x00h</code> identifies that it is a Scene. </li>
<li>Size of the data is 1404 bytes (0x0000057Ch = 0x7Ch + 0x05h * 256 = 124 + 1280)</li>
<li>The old pointer is 0x0BFB3468h</li>
<li>The SDNA index is 150 (0x00000096h = 6 + 9 * 16 = 6 + 144)</li>
<li>The section contains a single scene (count = 1).</li>
</ul>
<p>
Before we can interpret the data of this file-block we first have to read the DNA structures in the file.
The section "<a href="#structure-DNA">Structure DNA</a>" will show how to do that.
</p>
</div>
<a name="structure-DNA" href="#structure-DNA"><h2>Structure DNA</h2></a>
<a name="DNA1-file-block" href="#DNA1-file-block"><h3>The DNA1 file-block</h3></a>
<p>
Structure DNA is stored in a file-block with code 'DNA1'. It can be just before the 'ENDB' file-block.
</p>
<p>
The 'DNA1' file-block contains all internal structures of the Blender release the
file was created in. <br>
These structure can be described as C-structures: they can hold fields, arrays and
pointers to other structures, just like a normal C-structure.
<p>
<code class="block">struct SceneRenderLayer {
struct SceneRenderLayer *next, *prev;
char name[32];
struct Material *mat_override;
struct Group *light_override;
unsigned int lay;
unsigned int lay_zmask;
int layflag;
int pad;
int passflag;
int pass_xor;
};
</code>
</p>
<p>
For example,a blend-file created with Blender 2.54 the 'DNA1' file-block is 57796 bytes long and contains 398 structures.
</p>
<a name="DNA1-file-block-header" href="#DNA1-file-block-header"><h3>DNA1 file-block-header</h3></a>
<p>
The DNA1 file-block header follows the same rules of any other file-block, see the example below.
</p>
<a name="example-DNA1-file-block-header"></a>
<div class="box">
<p onclick="location.href='#example-DNA1-file-block-header'" class="box-title">
Example
</p>
<p>
This hex-dump describes the file-block 'DNA1' header created with <code>blender</code> <code>2.54.0</code> on <code>little-endian</code> hardware with a <code>32 bits</code> pointer length.<br>
<code class="block"><span class="descr"> (file-block
identifier='DNA1') data size=57796 old pointer SDNA index=0
| | | |</span>
0004 B060 <span class="header">[44 4E 41 31] [C4 E1 00 00] [C8 00 84 0B] [00 00 00 00]</span> DNA1............
0004 B070 <span class="header">[01 00 00 00]</span> <span class="fade">[53 44 4E 41 4E 41 4D 45 CB 0B 00 00</span> ....<span class="fade">SDNANAME....</span><span class="descr">
| |
count=1 'DNA1' file-block data (next 57796 bytes)</span>
</code>
</p>
</div>
<a name="DNA1-file-block-data" href="#DNA1-file-block-data"><h3>DNA1 file-block data</h3></a>
<p>
The next section describes how this information is ordered in the <b>data</b> of the 'DNA1' file-block.
</p>
<table>
<caption>Structure of the DNA file-block-data</caption>
<thead>
<tr><th colspan="2">repeat condition</th>
<th>name</th>
<th>type</th>
<th>length</th>
<th>description</th></tr>
</thead>
<tbody>
<tr><td></td>
<td></td>
<td>identifier</td>
<td>char[4]</td>
<td>4</td>
<td>'SDNA'</td></tr>
<tr><td></td>
<td></td>
<td>name identifier</td>
<td>char[4]</td>
<td>4</td>
<td>'NAME'</td></tr>
<tr><td></td>
<td></td>
<td>#names</td>
<td>integer</td>
<td>4</td>
<td>Number of names follows</td></tr>
<tr><td>for(#names)</td>
<td></td>
<td>name</td>
<td>char[]</td>
<td>?</td>
<td>Zero terminating string of name, also contains pointer and simple array definitions (e.g. '*vertex[3]\0')</td></tr>
<tr><td></td>
<td></td>
<td>type identifier</td>
<td>char[4]</td>
<td>4</td>
<td>'TYPE' this field is aligned at 4 bytes</td></tr>
<tr><td></td>
<td></td>
<td>#types</td>
<td>integer</td>
<td>4</td>
<td>Number of types follows</td></tr>
<tr><td>for(#types)</td>
<td></td>
<td>type</td>
<td>char[]</td>
<td>?</td>
<td>Zero terminating string of type (e.g. 'int\0')</td></tr>
<tr><td></td>
<td></td>
<td>length identifier</td>
<td>char[4]</td>
<td>4</td>
<td>'TLEN' this field is aligned at 4 bytes</td></tr>
<tr><td>for(#types)</td>
<td></td>
<td>length</td>
<td>short</td>
<td>2</td>
<td>Length in bytes of type (e.g. 4)</td></tr>
<tr><td></td>
<td></td>
<td>structure identifier</td>
<td>char[4]</td>
<td>4</td>
<td>'STRC' this field is aligned at 4 bytes</td></tr>
<tr><td></td>
<td></td>
<td>#structures</td>
<td>integer</td>
<td>4</td>
<td>Number of structures follows</td></tr>
<tr><td>for(#structures)</td>
<td></td>
<td>structure type</td>
<td>short</td>
<td>2</td>
<td>Index in types containing the name of the structure</td></tr>
<tr><td>..</td>
<td></td>
<td>#fields</td>
<td>short</td>
<td>2</td>
<td>Number of fields in this structure</td></tr>
<tr><td>..</td>
<td>for(#field)</td>
<td>field type</td>
<td>short</td>
<td>2</td>
<td>Index in type</td></tr>
<tr><td>for end</td>
<td>for end</td>
<td>field name</td>
<td>short</td>
<td>2</td>
<td>Index in name</td></tr>
</tbody>
</table>
<p>
As you can see, the structures are stored in 4 arrays: names, types,
lengths and structures. Every structure also contains an array of
fields. A field is the combination of a type and a name. From this
information a catalog of all structures can be constructed.
The names are stored as how a C-developer defines them. This means that
the name also defines pointers and arrays.
(When a name starts with '*' it is used as a pointer. when the name
contains for example '[3]' it is used as a array of 3 long.)
In the types you'll find simple-types (like: 'integer', 'char',
'float'), but also complex-types like 'Scene' and 'MetaBall'.
'TLEN' part describes the length of the types. A 'char' is 1 byte, an
'integer' is 4 bytes and a 'Scene' is 1376 bytes long.
</p>
<div class="box">
<p class="box-title">
Note
</p>
<p>
All identifiers, are arrays of 4 chars, hence they are all aligned at 4 bytes.
</p>
</div>
<a name="example-DNA1-file-block-data"></a>
<div class="box">
<p onclick="location.href='#example-DNA1-file-block-data'" class="box-title">
Example
</p>
<p>
Created with <code>blender</code> <code>2.54.0</code> on <code>little-endian</code> hardware with a <code>32 bits</code> pointer length.
</p>
<a name="DNA1-data-array-names" href="#DNA1-data-array-names"><h4>The names array</h4></a>
<p>
The first names are: *next, *prev, *data, *first, *last, x, y, xmin, xmax, ymin, ymax, *pointer, group, val, val2, type, subtype, flag, name[32], ...
<code class="block"><span class="descr"> file-block-data identifier='SDNA' array-id='NAME' number of names=3019
| | |</span>
0004 B070 <span class="fade">01 00 00 00 [53 44 4E 41]</span><span class="data">[4E 41 4D 45] [CB 0B 00 00]</span> <span class="fade">....SDNA</span>NAME....
0004 B080 <span class="data">[2A 6E 65 78 74 00][2A 70 72 65 76 00] [2A 64 61 74</span> *next.*prev.*dat<span class="descr">
| | |
'*next\0' '*prev\0' '*dat'</span><span class="fade">
....
.... (3019 names)</span>
</code>
</p>
<div class="box">
<p class="box-title">
Note
</p>
<p>
While reading the DNA you'll will come across some strange
names like '(*doit)()'. These are method pointers and Blender updates
them to the correct methods.
</p>
</div>
<a name="DNA1-data-array-types" href="#DNA1-data-array-types"><h4>The types array</h4></a>
<p>
The first types are: char, uchar, short, ushort, int, long, ulong, float, double, void, Link, LinkData, ListBase, vec2s, vec2f, ...
<code class="block"><span class="descr"> array-id='TYPE'
|</span>
0005 2440 <span class="fade">6F 6C 64 5B 34 5D 5B 34 5D 00 00 00</span> [54 59 50 45] <span class="fade">old[4][4]...</span>TYPE
0005 2450 [C9 01 00 00] [63 68 61 72 00] [75 63 68 61 72 00][73 ....char.uchar.s<span class="descr">
| | | |
number of types=457 'char\0' 'uchar\0' 's'</span><span class="fade">
....
.... (457 types)</span>
</code>
</p>
<a name="DNA1-data-array-lengths" href="#DNA1-data-array-lengths"><h4>The lengths array</h4></a>
<p>
<code class="block"><span class="descr"> char uchar ushort short
array-id length length length length
'TLEN' 1 1 2 2</span>
0005 3AA0 <span class="fade">45 00 00 00</span> [54 4C 45 4E] [01 00] [01 00] [02 00] [02 00] <span class="fade">E...</span>TLEN........
<span class="fade">....</span>
0005 3AC0 [08 00] [04 00] [08 00] [10 00] [10 00] [14 00] [4C 00] [34 00] ............L.4.<span class="descr">
8 4 8
ListBase vec2s vec2f ... etc
length len length </span><span class="fade">
....
.... (457 lengths, same as number of types)</span>
</code>
</p>
<a name="DNA1-data-array-structures" href="#DNA1-data-array-structures"><h4>The structures array</h4></a>
<p>
<code class="block"><span class="descr"> array-id='STRC'
|</span>
0005 3E30 <span class="fade">40 00 38 00 60 00 00 00 00 00 00 00</span> [53 54 52 43] <span class="fade">@.8.`.......</span>STRC
0005 3E40 [8E 01 00 00] [0A 00] [02 00] [0A 00] [00 00] [0A 00] [01 00] ................<span class="descr">
398 10 2 10 0 10 0
number of index fields index index index index
structures in <a href="#DNA1-data-array-types">types</a> in <a href="#DNA1-data-array-types">types</a> in <a href="#DNA1-data-array-names">names</a> in <a href="#DNA1-data-array-types">types</a> in <a href="#DNA1-data-array-names">names</a></span><span class="fade">
' '----------------' '-----------------' '
' field 0 field 1 '
'--------------------------------------------------------'
structure 0
....
.... (398 structures, each one describeing own type, and type/name for each field)</span>
</code>
</p>
</div>
<p>
The DNA structures inside a Blender 2.48 blend-file can be found at <a href="http://www.atmind.nl/blender/blender-sdna.html">http://www.atmind.nl/blender/blender-sdna.html</a>.
If we understand the DNA part of the file it is now possible to read
information from other parts file-blocks. The next section will tell us
how.
</p>
<a name="reading-scene-information" href="#reading-scene-information"><h2>Reading scene information</h2></a>
<p>
Let us look at <a href="#example-file-block-header">the file-block header we have seen earlier</a>:<br>
</p>
<ul>
<li>the file-block identifier is <code>'SC'+0x00h</code></li>
<li>the SDNA index is 150</li>
<li>the file-block size is 1404 bytes</li>
</ul>
<p>
Now note that:
<ul>
<li>the structure at index 150 in the DNA is a structure of type 'Scene' (counting from 0).</li>
<li>the associated type ('Scene') in the DNA has the length of 1404 bytes.</li>
</ul>
</p>
<p>
We can map the Scene structure on the data of the file-blocks.
But before we can do that, we have to flatten the Scene-structure.
<code class="block">struct Scene {
ID id; <span class="descr">// 52 bytes long (ID is different a structure)</span>
AnimData *adt; <span class="descr">// 4 bytes long (pointer to an AnimData structure)</span>
Object *camera; <span class="descr">// 4 bytes long (pointer to an Object structure)</span>
World *world; <span class="descr">// 4 bytes long (pointer to an Object structure)</span>
...
float cursor[3]; <span class="descr">// 12 bytes long (array of 3 floats)</span>
...
};
</code>
The first field in the Scene-structure is of type 'ID' with the name 'id'.
Inside the list of DNA structures there is a structure defined for type 'ID' (structure index 17).
<code class="block">struct ID {
void *next, *prev;
struct ID *newid;
struct Library *lib;
char name[24];
short us;
short flag;
int icon_id;
IDProperty *properties;
};
</code>
The first field in this structure has type 'void' and name '*next'. <br>
Looking in the structure list there is no structure defined for type 'void': it is a simple type and therefore the data should be read.
The name '*next' describes a pointer.
As we see, the first 4 bytes of the data can be mapped to 'id.next'.
</p>
<p>
Using this method we'll map a structure to its data. If we want to
read a specific field we know at which offset in the data it is located
and how much space it takes.<br>
The next table shows the output of this flattening process for some
parts of the Scene-structure. Not all rows are described in the table as
there is a lot of information in a Scene-structure.
</p>
<table>
<caption>Flattened SDNA structure 150: Scene</caption>
<thead>
<tr><th>reference</th>
<th>structure</th>
<th>type</th><th>name</th>
<th>offset</th><th>size</th>
<th>description</th></tr>
</thead>
<tbody>
<tr><td>id.next</td><td><a href="#struct:ID">ID</a></td>
<td>void</td><td>*next</td>
<td>0</td>
<td>4</td>
<td>Refers to the next scene</td></tr>
<tr><td>id.prev</td><td><a href="#struct:ID">ID</a></td>
<td>void</td><td>*prev</td>
<td>4</td>
<td>4</td>
<td>Refers to the previous scene</td></tr>
<tr><td>id.newid</td><td><a href="#struct:ID">ID</a></td>
<td>ID</td><td>*newid</td>
<td>8</td>
<td>4</td>
<td></td></tr>
<tr><td>id.lib</td><td><a href="#struct:ID">ID</a></td>
<td>Library</td><td>*lib</td>
<td>12</td>
<td>4</td>
<td></td></tr>
<tr><td>id.name</td><td><a href="#struct:ID">ID</a></td>
<td>char</td><td>name[24]</td>
<td>16</td>
<td>24</td>
<td>'SC'+the name of the scene as displayed in Blender</td></tr>
<tr><td>id.us</td><td><a href="#struct:ID">ID</a></td>
<td>short</td><td>us</td>
<td>40</td>
<td>2</td>
<td></td></tr>
<tr><td>id.flag</td><td><a href="#struct:ID">ID</a></td>
<td>short</td><td>flag</td><td>42</td><td>2</td>
<td></td></tr>
<tr><td>id.icon_id</td><td><a href="#struct:ID">ID</a></td>
<td>int</td><td>icon_id</td><td>44</td>
<td>4</td>
<td></td></tr>
<tr><td>id.properties</td><td><a href="#struct:ID">ID</a></td>
<td>IDProperty</td><td>*properties</td>
<td>48</td>
<td>4</td>
<td></td></tr>
<tr><td>adt</td><td>Scene</td><td>AnimData</td>
<td>*adt</td>
<td>52</td>
<td>4</td>
<td></td></tr>
<tr><td>camera</td><td>Scene</td>
<td>Object</td>
<td>*camera</td>
<td>56</td>
<td>4</td>
<td>Pointer to the current camera</td></tr>
<tr><td>world</td><td>Scene</td>
<td>World</td>
<td>*world</td>
<td>60</td>
<td>4</td>
<td>Pointer to the current world</td></tr>
<tr><td class="skip" colspan="7">Skipped rows</td></tr>
<tr><td>r.xsch</td><td><a href="#struct:RenderData">RenderData</a>
</td><td>short</td><td>xsch</td><td>382</td><td>2</td>
<td>X-resolution of the output when rendered at 100%</td></tr>
<tr><td>r.ysch</td><td><a href="#struct:RenderData">RenderData</a>
</td><td>short</td><td>ysch</td><td>384</td><td>2</td>
<td>Y-resolution of the output when rendered at 100%</td></tr>
<tr><td>r.xparts</td><td><a href="#struct:RenderData">RenderData</a>
</td><td>short</td><td>xparts</td><td>386</td><td>2</td>
<td>Number of x-part used by the renderer</td></tr>
<tr><td>r.yparts</td><td><a href="#struct:RenderData">RenderData</a>
</td><td>short</td><td>yparts</td><td>388</td><td>2</td>
<td>Number of x-part used by the renderer</td></tr>
<tr><td class="skip" colspan="7">Skipped rows</td></tr>
<tr><td>gpd</td><td>Scene</td><td>bGPdata</td><td>*gpd</td><td>1376</td><td>4</td>
<td></td></tr>
<tr><td>physics_settings.gravity</td><td><a href="#struct:PhysicsSettings">PhysicsSettings</a>
</td><td>float</td><td>gravity[3]</td><td>1380</td><td>12</td>
<td></td></tr>
<tr><td>physics_settings.flag</td><td><a href="#struct:PhysicsSettings">PhysicsSettings</a>
</td><td>int</td><td>flag</td><td>1392</td><td>4</td>
<td></td></tr>
<tr><td>physics_settings.quick_cache_step</td><td><a href="#struct:PhysicsSettings">PhysicsSettings</a>
</td><td>int</td><td>quick_cache_step</td><td>1396</td><td>4</td>
<td></td></tr>
<tr><td>physics_settings.rt</td><td><a href="#struct:PhysicsSettings">PhysicsSettings</a>
</td><td>int</td><td>rt</td><td>1400</td><td>4</td>
<td></td></tr>
</tbody>
</table>
<p>
We can now read the X and Y resolution of the Scene:
<ul>
<li>the X-resolution is located on offset 382 of the file-block-data and must be read as a
short.</li>
<li>the Y-resolution is located on offset 384 and is also a short</li>
</ul>
</p>
<div class="box">
<p class="box-title">
Note
</p>
<p>
An array of chars can mean 2 things. The field contains readable
text or it contains an array of flags (not humanly readable).
</p>
</div>
<div class="box">
<p class="box-title">
Note
</p>
<p>
A file-block containing a list refers to the DNA structure and has a count larger
than 1. For example Vertexes and Faces are stored in this way.
</p>
</div>
</body>
</html>

View File

@@ -1,123 +0,0 @@
An updated version of this guide can be found at:
http://www.blender3d.org/cms/Building_with_Cygwin.524.0.html
Introduction
------------
Here are some basic instructions for building
blender for windows using gcc under cygwin.
Please note that the resulting executable does not
depend on cygwin and can be distrubuted to machines
that don't have cygwin installed.
The instructions are:
1. Download cygwin (www.cygwin.com) and use the setup program
to install packages for gcc, gcc-mingw, gcc-g++, w32api, make, cvs,
python, perl, gettext, and gettext-devel (and maybe others... the
dependency list is bound to change over time and hopefully these
instructions will keep up with the changes). All of the following
commands will be entered at the cygwin prompt so launch
cygwin now.
2. Create a directory to put your sources and then enter that
directory, e.g.:
mkdir bf-blender
cd bf-blender
*********WARNING: if the directory path you are in contains a space in
it you will get errors in trying to compile the code. Change directorys
to a one that does not contain a space in the path before creating the
above directory *********
Please note that a backslash at the end of a line in the following
means that the command spans two lines. If you wish to type the command as
one line, exclude the '\'.
3. Checkout the blender module from the bf-blender tree using cvs
(use password anonymous):
cvs -d:pserver:anonymous@cvs.blender.org:/cvsroot/bf-blender login
cvs -z3 -d:pserver:anonymous@cvs.blender.org:/cvsroot/bf-blender \
co blender
4. Checkout the lib/windows module from bf-blender using cvs:
cvs -z3 -d:pserver:anonymous@cvs.blender.org:/cvsroot/bf-blender \
co lib/windows
5. Enter the newly created blender directory:
cd blender
6. To prepare the build system to use only the free tools we must
set some environment variables. This is done by creating a
file called "user-def.mk" in the blender directory and
inserting the following line with notepad or your favorite
text editor:
export FREE_WINDOWS=true
The quickest way to do this though is to issue the following
command:
echo 'export FREE_WINDOWS=true' > user-def.mk
7. Time to build... issue the command:
make
8. Wait for it to finish (there is this mysterious place called
'outside' that I am told is nice to go to while waiting for a
compile to finish).
9. After it finishes compiling, if you would like to run your freshly compiled
blender, type make release. Then change directorys to obj/233.a/ and move
the zip file to where you want to use it, unzip the file, enter the directory
and run your brand new blender.
Getting Help
------------
If you have problems, come by #blendercompilers on irc.freenode.net
or post questions to the "Compiling, Libraries, Modules" forum
at www.blender.org. There is also the very useful bf-committers
mailing list, what you can subscribe to here:
http://www.blender.org/mailman/listinfo/bf-committers
(as a bonus you can get info about the most recent features that
are coming down the pipe ...)
This said, the most common fix to a problem will
probably involve installing an additional cygwin package,
so keep that cygwin setup program close by ...
Some final notes
----------------
- The build will take a long time, even on a fast machine
(a clean build takes almost an hour on my Athlon 1800+
based laptop).
- If the build is successful you will find it has created
the program obj/windows/bin/blender.exe
- The executable generated by gcc will generally be slower
that an msvc++ generated executable at rendering, but the
OpenGL speed should be about the same.
- Sound is disabled
- If you want to clean your sources issue a 'make clean'
in the top blender directory.
- If you want to update your sources when somebody has
added a new awesome feature, you will want to go to the
topmost blender directory and issue the following command:
cvs -z3 update -P -d
It would probably be best to clean your sources before
re-building (see previous note).
- This is a work in progress, so some things may not be working
right or it may not support all of the cutting edge features.
- Want to make a fancy zipped up blender package to give
to your buddies? Try "make release" ... read the output
to find out where the zip file was placed (note: you will
probably need the zip/unzip packages from cygwin to do
this).
- You can make a debug executable using 'make debug'. The
debug executable will be larger and slower that the
regular executable, but when used with the gnu debugger
(gdb) it can help debug a blender problem (for example,
it can locate the line of code that caused blender to
crash).

View File

@@ -132,9 +132,9 @@ $Id$
The commandline can be used to override detected/default settings, e.g:
On Unix:
cmake -D PYTHON_LIB=/usr/local/lib/python3.1/config/libpython3.1.so -D PYTHON_INC=/usr/local/include/python3.1 -G "Unix Makefiles" ../blender
cmake -D PYTHON_LIBRARY=/usr/local/lib/python3.1/config/libpython3.1.so -D PYTHON_INCLUDE_DIRS=/usr/local/include/python3.1 -G "Unix Makefiles" ../blender
On Macs:
cmake -D PYTHON_INC=/System/Library/Frameworks/Python.framework/Versions/3.1/include/python3.1 -G Xcode ../blender
cmake -D PYTHON_INCLUDE_DIRS=/System/Library/Frameworks/Python.framework/Versions/3.1/include/python3.1 -G Xcode ../blender
Mote that this should only be needed once per build directory generation because it will keep the overrides in CMakeCache.txt for subsequent runs.

View File

@@ -27,7 +27,7 @@ $Id$
filenames have the form (platform)-config.py, where platform one of:
* darwin
* linux2
* linux
* win32-mingw
* win32-vc

View File

@@ -76,7 +76,7 @@ $Id$
$BLENDERHOME/config. Your platform specific defaults are in
(platform)-config.py, where platform is one of:
- linux2, for machines running Linux
- linux, for machines running Linux
- win32-vc, for Windows machines, compiling with a Microsoft compiler
- win32-mingw, for Windows machines, compiling with the MingW compiler
- darwin, for OS X machines

View File

@@ -1,63 +0,0 @@
/** \mainpage Blender
*
* \section intro Introduction
*
* Blender is an integrated 3d package, which features:
* - modeling
* - animation
* - texturing
* - compositing
* - rendering
* - scripting
* - game creation
*
* These pages document the source code of blender.
*
* \section sects Main sections of the blender code
*
* The following sections are the broad categories into which the various modules
* belong.
*
* - \ref mainmodule
* - \ref render
* - \ref meshedit
* - \ref texture
* - \ref compositor
* - \ref scripts
* - \ref gameengine
*
* \section GUI
* - \ref gui
* - \ref hotkeys
* - \ref toolbox
*
* \section Libraries and Wrappers
* - GHOST API: \ref GHOST_C-api.h
* - \ref imbuf
*
* \section Miscellaneous
* - \ref undoc
*/
/** \defgroup mainmodule Main Module */
/** \defgroup defaultconfig Default and Configuration
* \ingroup mainmodule
*/
/** \defgroup render Rendering Module */
/** \defgroup meshedit Mesh Editing Module */
/** \defgroup texture Textureing */
/** \defgroup compositor Compositing */
/** \defgroup scripts Scripting */
/** \defgroup gameengine Game Engine */
/** \defgroup gui GUI */
/** \defgroup hotkeys Hotkeys
* \ingroup gui
*/
/** \defgroup toolbox Toolbox
* \ingroup gui
*/
/** \defgroup imbuf IMage Buffer */
/** \defgroup undoc Undocumented */

1694
doc/doxygen/Doxyfile Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,17 @@
/** \defgroup extern External libraries
* \section externabout External libraries
* As with \ref intern these libraries are
* provided in the Blender codebase. This is
* to make building Blender easier. The main
* development of these libraries is \b not part
* of the normal Blender development process, but
* each of the library is developed separately.
* Whenever deemed necessary libraries in \c extern/
* folder are updated.
*
*/
/** \defgroup bullet Bullet Physics Library
* \ingroup extern
* \see \ref bulletdoc
*/

102
doc/doxygen/doxygen.intern Normal file
View File

@@ -0,0 +1,102 @@
/** \defgroup intern Internal libraries
* \section internabout Internal libraries
* Blender comes with some of its dependencies
* directly included in the codebase. Libraries
* that are in the \c intern/ folder are maintained
* as part of the normal development process.
*/
/** \defgroup MEM Guarded memory (de)allocation
* \ingroup intern
*/
/** \defgroup boolop boolop
* \ingroup intern
*/
/** \defgroup ctr container
* \ingroup intern
*/
/** \defgroup decimation decimation
* \ingroup intern
*/
/** \defgroup elbeem elbeem
* \ingroup intern
*/
/** \defgroup bsp bsp
* \ingroup intern
*/
/** \defgroup iksolver iksolver
* \ingroup intern
*/
/** \defgroup itasc itasc
* \ingroup intern
*/
/** \defgroup memutil memutil
* \ingroup intern
*/
/** \defgroup mikktspace mikktspace
* \ingroup intern
*/
/** \defgroup moto moto
* \ingroup intern
*/
/** \defgroup opennl opennl
* \ingroup intern
*/
/** \defgroup smoke smoke
* \ingroup intern
*/
/** \defgroup string string
* \ingroup intern
*/
/** \defgroup audaspace Audaspace
* \ingroup intern undoc
* \todo add to doxygen
*/
/** \defgroup audfx Audaspace FX
* \ingroup audaspace
*/
/** \defgroup audopenal Audaspace OpenAL
* \ingroup audaspace
*/
/** \defgroup audpython Audaspace Python
* \ingroup audaspace
*/
/** \defgroup audsdl Audaspace SDL
* \ingroup audaspace
*/
/** \defgroup audsrc Audaspace SRC
* \ingroup audaspace
*/
/** \defgroup audffmpeg Audaspace FFMpeg
* \ingroup audaspace
*/
/** \defgroup audfftw Audaspace FFTW
* \ingroup audaspace
*/
/** \defgroup audjack Audaspace Jack
* \ingroup audaspace
*/
/** \defgroup audsndfile Audaspace sndfile
* \ingroup audaspace
*/
/** \defgroup GHOST GHOST API
* \ingroup intern GUI
* \ref GHOSTPage
*/

19
doc/doxygen/doxygen.main Normal file
View File

@@ -0,0 +1,19 @@
/** \mainpage Blender
*
* \section intro Introduction
*
* Blender is an integrated 3d package.
*
* These pages document the source code of blender.
*
* \subsection implinks Important Links
* - <a href="http://projects.blender.org">projects.blender.org</a> with <a href="http://projects.blender.org/tracker/index.php?group_id=9&atid=498">bug tracker</a>
* - <a href="http://wiki.blender.org/index.php/Dev:Contents">Development documents</a> on our wiki.
*
* \subsection blother Other
* For more information on using Blender browse to http://www.blender.org
*
*/
/** \defgroup undoc Undocumented
* \brief Modules and libraries that are still undocumented, or lacking proper integration into the doxygen system, are marked in this group. */

342
doc/doxygen/doxygen.source Normal file
View File

@@ -0,0 +1,342 @@
/** \defgroup blenderplayer Blender Player */
/** \defgroup blc bad level calls
* \ingroup blenderplayer
*/
/** \defgroup render Rendering
* \ingroup blender
*/
/** \defgroup meshedit Mesh Editing */
/** \defgroup texture Texturing */
/** \defgroup compositor Compositing */
/** \defgroup scripts Scripting */
/** \defgroup python Python
* \ingroup blender scripts
*/
/** \defgroup pygen Python Generic
* \ingroup python
*/
/** \defgroup pythonintern Python RNA and Operators
* \ingroup python
*/
/** \defgroup blpluginapi Blender pluginapi
* \ingroup blender
* \attention not in use currently
*/
/* ================================ */
/** \defgroup bge Game Engine */
/** \defgroup gamelogic Game Logic
* \ingroup bge
*/
/** \defgroup bgeconv Converter
* \ingroup bge
*/
/** \defgroup blroutines Blender Routines
* \ingroup bge
*/
/** \defgroup expressions Expressions
* \ingroup bge
*/
/** \defgroup player Game Player
* \ingroup bge
*/
/** \defgroup ketsji Ketsji
* \ingroup bge
* \todo check all headers and code files for proper licenses
*/
/** \defgroup ketsjinet Ketsji Network
* \ingroup ketsji
*/
/** \defgroup bgenet Network
* \ingroup bge
*/
/** \defgroup bgenetlb Loopback Network
* \ingroup bgenet
*/
/** \defgroup phys Physics
* \ingroup bge
*/
/** \defgroup physbullet Bullet Physics
* \ingroup phys
*/
/** \defgroup physdummy Dummy Physics (none)
* \ingroup phys
*/
/** \defgroup bgerast Rasterizer
* \ingroup bge
*/
/** \defgroup bgerastoglfilters OpenGL Filters
* \ingroup bgerast
*/
/** \defgroup bgerastogl OpenGL Rasterizer
* \ingroup bgerast
*/
/** \defgroup bgesg BGE SceneGraph
* \ingroup bge
*/
/** \defgroup bgevideotex BGE Video Texture
* \ingroup bge
*/
/* ================================ */
/** \defgroup blender blender */
/** \defgroup blf blenfont
* \ingroup blender
*/
/** \defgroup bke blenkernel
* \ingroup blender
*/
/** \defgroup bli blenlib
* \ingroup blender
*/
/** \defgroup nodes nodes
* \ingroup blender
*/
/** \defgroup cmpnodes cmpnodes
* \ingroup nodes
*/
/** \defgroup shdnodes shdnodes
* \ingroup nodes
*/
/** \defgroup texnodes texnodes
* \ingroup nodes
*/
/** \defgroup modifiers modifiers
* \ingroup blender
*/
/** \defgroup data DNA, RNA and .blend access*/
/** \defgroup gpu GPU
* \ingroup blender
*/
/** \defgroup ikplugin ikplugin
* \ingroup blender
*/
/** \defgroup DNA sDNA
* \ingroup blender data
*/
/** \defgroup RNA RNA
* \ingroup blender data
*/
/** \defgroup blenloader .blend read and write functions
* \ingroup blender data
* \todo check if \ref blo and \ref blenloader groups can be
* merged in docs.
*/
/** \defgroup quicktime quicktime
* \ingroup blender
/** \defgroup gui GUI */
/** \defgroup wm windowmanager
* \ingroup blender gui
*/
/* ================================ */
/** \defgroup editors Editors
* \ingroup blender
*/
/** \defgroup edanimation animation
* \ingroup editors
*/
/** \defgroup edarmature armature
* \ingroup editors
*/
/** \defgroup edcurve curve
* \ingroup editors
*/
/** \defgroup eddatafiles datafiles
* \ingroup editors
*/
/** \defgroup edgpencil gpencil
* \ingroup editors
*/
/** \defgroup edinterface interface
* \ingroup editors
*/
/** \defgroup edmesh mesh
* \ingroup editors
*/
/** \defgroup edmeta metaball
* \ingroup editors
*/
/** \defgroup edobj object
* \ingroup editors
*/
/** \defgroup edphys physics
* \ingroup editors
*/
/** \defgroup edrend render
* \ingroup editors
*/
/** \defgroup edscr screen
* \ingroup editors
*/
/** \defgroup edsculpt sculpt and paint
* \ingroup editors
*/
/** \defgroup edsnd sound
* \ingroup editors
*/
/** \defgroup spaction action space
* \ingroup editors
*/
/** \defgroup spapi space API
* \ingroup editors
*/
/** \defgroup spbuttons buttons space
* \ingroup editors
*/
/** \defgroup spconsole console space
* \ingroup editors
*/
/** \defgroup spfile fileselector
* \ingroup editors
*/
/** \defgroup spgraph graph editor
* \ingroup editors
*/
/** \defgroup spimage image and UV editor
* \ingroup editors
*/
/** \defgroup spinfo info space
* \ingroup editors
*/
/** \defgroup splogic game logic editor
* \ingroup editors
*/
/** \defgroup spnla NLA editor
* \ingroup editors
*/
/** \defgroup spnode node editor
* \ingroup editors
*/
/** \defgroup spoutliner outliner space
* \ingroup editors
*/
/** \defgroup spscript script space
* \ingroup editors
*/
/** \defgroup spseq sequencer
* \ingroup editors
*/
/** \defgroup spsnd sound space
* \ingroup editors
*/
/** \defgroup sptext text editor
* \ingroup editors
*/
/** \defgroup sptime time line
* \ingroup editors
*/
/** \defgroup spuserpref user preferences
* \ingroup editors
*/
/** \defgroup spview3d 3D view
* \ingroup editors
*/
/** \defgroup edtransform transform
* \ingroup editors
*/
/** \defgroup edutil editor utilities
* \ingroup editors
*/
/** \defgroup spuv UV editing
* \ingroup editors
*/
/* ================================ */
/** \defgroup editorui Interface and Widgets
* \ingroup gui
*/
/** \defgroup externformats external formats */
/** \defgroup collada COLLADA
* \ingroup externformats
*/
/** \defgroup avi AVI
* \ingroup externformats
*/
/** \defgroup imbuf IMage Buffer
* \ingroup blender
*/
/** \defgroup imbcineon Cineon
* \ingroup imbuf
*/
/** \defgorup imbdds DDS
* \ingroup imbuf
*/
/** \defgroup openexr OpenEXR
* \ingroup imbuf
*/
/* ================================ */
/** \defgroup undoc Undocumented
* \brief Modules and libraries that are still undocumented, or lacking proper integration into the doxygen system, are marked in this group. */

5
doc/doxygen/footer.html Normal file
View File

@@ -0,0 +1,5 @@
<hr class="footer"/><address class="footer"><small>Generated on $datetime for $projectname by&#160;
<a href="http://www.doxygen.org/index.html">
doxygen</a> $doxygenversion </small></address>
</body>
</html>

View File

@@ -1,4 +1,4 @@
.TH "BLENDER" "1" "July 15, 2010" "Blender Blender 2\&.52 (sub 5) "
.TH "BLENDER" "1" "June 03, 2011" "Blender Blender 2\&.57 (sub 1)"
.SH NAME
blender \- a 3D modelling and rendering package
@@ -15,7 +15,7 @@ Use Blender to create TV commercials, to make technical visualizations, business
http://www.blender.org
.SH OPTIONS
Blender 2.52 (sub 5) Build
Blender 2.57 (sub 1)
Usage: blender [args ...] [file] [args ...]
.br
.SS "Render Options:"
@@ -125,7 +125,7 @@ Set option to add the file extension to the end of the file
.br
Use amount of <threads> for rendering in background
.br
[1\-BLENDER_MAX_THREADS], 0 for systems processor count.
[1\-64], 0 for systems processor count.
.br
.IP
@@ -133,17 +133,9 @@ Use amount of <threads> for rendering in background
.SS "Animation Playback Options:"
.TP
.B \-a <options> <file(s)>
.B \-a or \-\-render\-anim
.br
Playback <file(s)>, only operates this way when not running in background.
.br
\-p <sx> <sy> Open with lower left corner at <sx>, <sy>
.br
\-m Read from disk (Don't buffer)
.br
\-f <fps> <fps\-base> Specify FPS to start with
.br
\-j <frame> Set frame step to <frame>
Render frames from start to end (inclusive)
.br
.IP
@@ -159,7 +151,7 @@ Force opening with borders (default)
.TP
.B \-W or \-\-window\-borderless
.br
Force opening with without borders
Force opening without borders
.br
.TP
@@ -168,6 +160,12 @@ Force opening with without borders
Open with lower left corner at <sx>, <sy> and width and height as <w>, <h>
.br
.TP
.B \-con or \-\-start\-console
.br
Start with the console window open (ignored if \-b is set)
.br
.IP
.SS "Game Engine Specific Options:"
@@ -199,7 +197,7 @@ Turn debugging on
.br
* Disables mouse grab (to interact with a debugger in some cases)
.br
* Keeps python sys.stdin rather then setting it to None
* Keeps python sys.stdin rather than setting it to None
.br
.TP
@@ -210,6 +208,40 @@ Enable floating point exceptions
.IP
.TP
.B \-\-factory\-startup
.br
Skip reading the "startup.blend" in the users home directory
.br
.IP
.TP
.B \-\-env\-system\-datafiles
.br
Set the BLENDER_SYSTEM_DATAFILES environment variable
.br
.TP
.B \-\-env\-system\-scripts
.br
Set the BLENDER_SYSTEM_SCRIPTS environment variable
.br
.TP
.B \-\-env\-system\-plugins
.br
Set the BLENDER_SYSTEM_PLUGINS environment variable
.br
.TP
.B \-\-env\-system\-python
.br
Set the BLENDER_SYSTEM_PYTHON environment variable
.br
.IP
.TP
.B \-nojoystick
.br
@@ -249,7 +281,7 @@ Print this help text and exit
.TP
.B \-y or \-\-enable\-autoexec
.br
Enable automatic python script execution (default)
Enable automatic python script execution, (default)
.br
.TP
@@ -272,6 +304,12 @@ Run the given Python script (filename or Blender Text)
Run blender with an interactive console
.br
.TP
.B \-\-addons
.br
Comma separated list of addons (no spaces)
.br
.TP
.B \-v or \-\-version
.br
@@ -292,10 +330,30 @@ Ends option processing, following arguments passed unchanged. Access via python'
Print this help text and exit (windows only)
.br
.TP
.B \-a <options> <file(s)>
.br
Playback <file(s)>, only operates this way when not running in background.
.br
\-p <sx> <sy> Open with lower left corner at <sx>, <sy>
.br
\-m Read from disk (Don't buffer)
.br
\-f <fps> <fps\-base> Specify FPS to start with
.br
\-j <frame> Set frame step to <frame>
.br
.TP
.B \-R
.br
Register .blend extension (windows only)
Register .blend extension, then exit (Windows only)
.br
.TP
.B \-r
.br
Silently register .blend extension, then exit (Windows only)
.br
.SS "Argument Parsing:"
@@ -318,7 +376,6 @@ Arguments are executed in the order they are given. eg
.br
.SH "ENVIRONMENT VARIABLES"
\fIBLENDER_USER_CONFIG\fR Directory for user configuration files.
\fIBLENDER_SYSTEM_CONFIG\fR Directory for system wide configuration files.
\fIBLENDER_USER_SCRIPTS\fR Directory for user scripts.
\fIBLENDER_SYSTEM_SCRIPTS\fR Directory for system wide scripts.
\fIBLENDER_USER_DATAFILES\fR Directory for user data files (icons, translations, ..).

View File

@@ -44,7 +44,7 @@ def man_format(data):
return data
blender_bin = os.path.join(os.path.dirname(__file__), "../../blender")
blender_bin = os.path.join(os.path.dirname(__file__), "../../blender.bin")
blender_help = subprocess.Popen([blender_bin, "--help"], stdout=subprocess.PIPE).communicate()[0].decode()

View File

@@ -8,7 +8,7 @@
{%- macro relbar() %}
<div class="subnav boxheader">
<ul class="noprint"><li><a href="http://www.blender.org/development/coding-guides/">Coding Guides</a></li><li></li><li><a href="http://www.blender.org/development/report-a-bug/">Report a Bug</a></li><li></li><li><a href="http://www.blender.org/development/submit-a-patch/">Submit a Patch</a></li><li></li><li><a href="http://www.blender.org/development/release-logs/">Release Logs</a></li><li></li><li><a href="http://www.blender.org/development/current-projects/">Current Projects</a></li><li></li><li><a href="http://www.blender.org/development/architecture/">Architecture</a></li><li></li><li><a href="http://www.blender.org/development/building-blender/">Building Blender</a></li><li></li><li class="subnav-active"><a href="http://www.blender.org/documentation/250PythonDoc/contents.html">PyAPI</a></li><li></li><li><a href="http://wiki.blender.org/index.php/Main_Page">Wiki</a></li></ul>
<ul class="noprint"><li><a href="http://wiki.blender.org/index.php/Dev:Contents">Documentation</a></li><li></li><li><a href="http://www.blender.org/development/report-a-bug/">Report a Bug</a></li><li></li><li><a href="http://wiki.blender.org/index.php/Dev:Doc/Process/Patches">Submit a Patch</a></li><li></li><li><a href="http://www.blender.org/development/release-logs/">Release Logs</a></li><li></li><li><a href="http://www.blender.org/development/building-blender/">Building Blender</a></li><li></li><li><a href="http://wiki.blender.org/index.php/Dev:Doc/Projects">Current Projects</a></li><li></li><li><a href="http://wiki.blender.org/index.php/Dev:Source/Architecture">Architecture</a></li><li></li><li><a href="http://www.blender.org/documentation/250PythonDoc/contents.html">Python API</a></li><li></li><li><a href="http://wiki.blender.org">Wiki</a></li></ul>
</div>
<div class="related subnav">
<h3>{{ _('Navigation') }}</h3>

View File

@@ -219,7 +219,7 @@ div.sphinxsidebarwrapper.fixed {
}
{%- if theme_stickysidebar|tobool %}
/* this is nice, but it it leads to hidden headings when jumping
/* this is nice, but it leads to hidden headings when jumping
to an anchor */
/*
div.related {

File diff suppressed because it is too large Load Diff

View File

@@ -1,189 +0,0 @@
# Blender.Geometry module and its subtypes
"""
The Blender.Geometry submodule.
Geometry
========
(when accessing it from the Game Engine use Geometry instead of Blender.Geometry)
This new module provides access to a geometry function.
"""
def Intersect(vec1, vec2, vec3, ray, orig, clip=1):
"""
Return the intersection between a ray and a triangle, if possible, return None otherwise.
@type vec1: Vector object.
@param vec1: A 3d vector, one corner of the triangle.
@type vec2: Vector object.
@param vec2: A 3d vector, one corner of the triangle.
@type vec3: Vector object.
@param vec3: A 3d vector, one corner of the triangle.
@type ray: Vector object.
@param ray: A 3d vector, the orientation of the ray. the length of the ray is not used, only the direction.
@type orig: Vector object.
@param orig: A 3d vector, the origin of the ray.
@type clip: integer
@param clip: if 0, don't restrict the intersection to the area of the triangle, use the infinite plane defined by the triangle.
@rtype: Vector object
@return: The intersection between a ray and a triangle, if possible, None otherwise.
"""
def TriangleArea(vec1, vec2, vec3):
"""
Return the area size of the 2D or 3D triangle defined.
@type vec1: Vector object.
@param vec1: A 2d or 3d vector, one corner of the triangle.
@type vec2: Vector object.
@param vec2: A 2d or 3d vector, one corner of the triangle.
@type vec3: Vector object.
@param vec3: A 2d or 3d vector, one corner of the triangle.
@rtype: float
@return: The area size of the 2D or 3D triangle defined.
"""
def TriangleNormal(vec1, vec2, vec3):
"""
Return the normal of the 3D triangle defined.
@type vec1: Vector object.
@param vec1: A 3d vector, one corner of the triangle.
@type vec2: Vector object.
@param vec2: A 3d vector, one corner of the triangle.
@type vec3: Vector object.
@param vec3: A 3d vector, one corner of the triangle.
@rtype: float
@return: The normal of the 3D triangle defined.
"""
def QuadNormal(vec1, vec2, vec3, vec4):
"""
Return the normal of the 3D quad defined.
@type vec1: Vector object.
@param vec1: A 3d vector, the first vertex of the quad.
@type vec2: Vector object.
@param vec2: A 3d vector, the second vertex of the quad.
@type vec3: Vector object.
@param vec3: A 3d vector, the third vertex of the quad.
@type vec4: Vector object.
@param vec4: A 3d vector, the fourth vertex of the quad.
@rtype: float
@return: The normal of the 3D quad defined.
"""
def LineIntersect(vec1, vec2, vec3, vec4):
"""
Return a tuple with the points on each line respectively closest to the other
(when both lines intersect, both vector hold the same value).
The lines are evaluated as infinite lines in space, the values returned may not be between the 2 points given for each line.
@type vec1: Vector object.
@param vec1: A 3d vector, one point on the first line.
@type vec2: Vector object.
@param vec2: A 3d vector, another point on the first line.
@type vec3: Vector object.
@param vec3: A 3d vector, one point on the second line.
@type vec4: Vector object.
@param vec4: A 3d vector, another point on the second line.
@rtype: (Vector object, Vector object)
@return: A tuple with the points on each line respectively closest to the other.
"""
def PolyFill(polylines):
"""
Takes a list of polylines and calculates triangles that would fill in the polylines.
Multiple lines can be used to make holes inside a polyline, or fill in 2 separate lines at once.
@type polylines: List of lists containing vectors, each representing a closed polyline.
@rtype: list
@return: a list if tuples each a tuple of 3 ints representing a triangle indexing the points given.
@note: 2D Vectors will have an assumed Z axis of zero, 4D Vectors W axis is ignored.
@note: The order of points in a polyline effect the direction returned triangles face, reverse the order of a polyline to flip the normal of returned faces.
I{B{Example:}}
The example below creates 2 polylines and fills them in with faces, then makes a mesh in the current scene::
import Blender
Vector= Blender.mathutils.Vector
# Outline of 5 points
polyline1= [Vector(-2.0, 1.0, 1.0), Vector(-1.0, 2.0, 1.0), Vector(1.0, 2.0, 1.0), Vector(1.0, -1.0, 1.0), Vector(-1.0, -1.0, 1.0)]
polyline2= [Vector(-1, 1, 1.0), Vector(0, 1, 1.0), Vector(0, 0, 1.0), Vector(-1.0, 0.0, 1.0)]
fill= Blender.Geometry.PolyFill([polyline1, polyline2])
# Make a new mesh and add the truangles into it
me= Blender.Mesh.New()
me.verts.extend(polyline1)
me.verts.extend(polyline2)
me.faces.extend(fill) # Add the faces, they reference the verts in polyline 1 and 2
scn = Blender.Scene.GetCurrent()
ob = scn.objects.new(me)
Blender.Redraw()
"""
def LineIntersect2D(vec1, vec2, vec3, vec4):
"""
Takes 2 lines vec1, vec2 for the 2 points of the first line and vec2, vec3 for the 2 points of the second line.
@rtype: Vector
@return: a 2D Vector for the intersection or None where there is no intersection.
"""
def ClosestPointOnLine(pt, vec1, vec2):
"""
Takes 2 lines vec1, vec2 for the 2 points of the first line and vec2, vec3 for the 2 points of the second line.
@rtype: tuple
@return: a tuple containing a vector and a float, the vector is the closest point on the line, the float is the position on the line, between 0 and 1 the point is on the line.
"""
def PointInTriangle2D(pt, tri_pt1, tri_pt2, tri_pt3):
"""
Takes 4 vectors (one for the test point and 3 for the triangle)
This is a 2d function so only X and Y are used, Z and W will be ignored.
@rtype: int
@return: 1 for a clockwise intersection, -1 for counter clockwise intersection, 0 when there is no intersection.
"""
def PointInQuad2D(pt, quad_pt1, quad_pt2, quad_pt3):
"""
Takes 5 vectors (one for the test point and 5 for the quad)
This is a 2d function so only X and Y are used, Z and W will be ignored.
@rtype: int
@return: 1 for a clockwise intersection, -1 for counter clockwise intersection, 0 when there is no intersection.
"""
def BoxPack2D(boxlist):
"""
Takes a list of 2D boxes and packs them into a square.
Each box in boxlist must be a list of at least 4 items - [x,y,w,h], after running this script,
the X and Y values in each box will be moved to packed, non overlapping locations.
Example::
# Make 500 random boxes, pack them and make a mesh from it
from Blender import Geometry, Scene, Mesh
import random
boxes = []
for i in xrange(500):
boxes.append( [0,0, random.random()+0.1, random.random()+0.1] )
boxsize = Geometry.BoxPack2D(boxes)
print 'BoxSize', boxsize
me = Mesh.New()
for x in boxes:
me.verts.extend([(x[0],x[1], 0), (x[0],x[1]+x[3], 0), (x[0]+x[2],x[1]+x[3], 0), (x[0]+x[2],x[1], 0) ])
v1= me.verts[-1]
v2= me.verts[-2]
v3= me.verts[-3]
v4= me.verts[-4]
me.faces.extend([(v1,v2,v3,v4)])
scn = Scene.GetCurrent()
scn.objects.new(me)
@note: Each boxlist item can be longer then 4, the extra items are ignored and stay untouched.
@rtype: tuple
@return: a tuple pair - (width, height) of all the packed boxes.
"""
def BezierInterp(vec_knot_1, vec_handle_1, vec_handle_2, vec_knot_2, resolution):
"""
Takes 4 vectors representing a bezier curve and returns a list of vector points.
@note: any vector size is supported, the largest dimension from the input will be used for all returned vectors/
@rtype: list
@return: a list of vectors the size of resolution including the start and end points (vec_knot_1 and vec_knot_2)
"""

View File

@@ -1,156 +0,0 @@
# Blender.mathutils module and its subtypes
class Vector:
"""
@attention: Vector data can be wrapped or non-wrapped. When a object is wrapped it
means that the object will give you direct access to the data inside of blender. Modification
of this object will directly change the data inside of blender. To copy a wrapped object
you need to use the object's constructor. If you copy and object by assignment you will not get
a second copy but a second reference to the same data. Only certain functions will return
wrapped data. This will be indicated in the method description.
"""
def __init__(list = None):
"""
Create a new 2d, 3d, or 4d Vector object from a list of floating point numbers.
@note: that python uses higher precission floating point numbers, so values assigned to a vector may have some rounding error.
Example::
v = Vector(1,0,0)
v = Vector(myVec)
v = Vector(list)
@type list: PyList of float or int
@param list: The list of values for the Vector object. Can be a sequence or raw numbers.
Must be 2, 3, or 4 values. The list is mapped to the parameters as [x,y,z,w].
@rtype: Vector object.
@return: It depends wheter a parameter was passed:
- (list): Vector object initialized with the given values;
- (): An empty 3 dimensional vector.
"""
class Euler:
"""
The Euler object
================
This object gives access to Eulers in Blender.
@note: You can access a euler object like a sequence
- x = euler[0]
@note: Comparison operators can be done:
- ==, != test numeric values within epsilon
@attention: Euler data can be wrapped or non-wrapped. When a object is wrapped it
means that the object will give you direct access to the data inside of blender. Modification
of this object will directly change the data inside of blender. To copy a wrapped object
you need to use the object's constructor. If you copy and object by assignment you will not get
a second copy but a second reference to the same data. Only certain functions will return
wrapped data. This will be indicated in the method description.
"""
def __init__(list = None):
"""
Create a new euler object.
Example::
euler = Euler(45,0,0)
euler = Euler(myEuler)
euler = Euler(sequence)
@type list: PyList of float/int
@param list: 3d list to initialize euler
@rtype: Euler object
@return: Euler representing heading, pitch, bank.
@note: Values are in degrees.
"""
class Quaternion:
"""
The Quaternion object
=====================
This object gives access to Quaternions in Blender.
@note: Comparison operators can be done:
- ==, != test numeric values within epsilon
@note: Math can be performed on Quaternion classes
- quat + quat
- quat - quat
- quat * float/int
- quat * vec
- quat * quat
@note: You can access a quaternion object like a sequence
- x = quat[0]
@attention: Quaternion data can be wrapped or non-wrapped. When a object is wrapped it
means that the object will give you direct access to the data inside of blender. Modification
of this object will directly change the data inside of blender. To copy a wrapped object
you need to use the object's constructor. If you copy and object by assignment you will not get
a second copy but a second reference to the same data. Only certain functions will return
wrapped data. This will be indicated in the method description.
"""
def __init__(list, angle = None):
"""
Create a new quaternion object from initialized values.
Example::
quat = Quaternion(1,2,3,4)
quat = Quaternion(axis, angle)
quat = Quaternion()
quat = Quaternion(180, list)
@type list: PyList of int/float
@param list: A 3d or 4d list to initialize quaternion.
4d if intializing [w,x,y,z], 3d if used as an axis of rotation.
@type angle: float (optional)
@param angle: An arbitrary rotation amount around 'list'.
List is used as an axis of rotation in this case.
@rtype: New quaternion object.
@return: It depends wheter a parameter was passed:
- (list/angle): Quaternion object initialized with the given values;
- (): An identity 4 dimensional quaternion.
"""
class Matrix:
"""
The Matrix Object
=================
@note: Math can be performed on Matrix classes
- mat + mat
- mat - mat
- mat * float/int
- mat * vec
- mat * mat
@note: Comparison operators can be done:
- ==, != test numeric values within epsilon
@note: You can access a quaternion object like a 2d sequence
- x = matrix[0][1]
- vector = matrix[2]
@attention: Quaternion data can be wrapped or non-wrapped. When a object is wrapped it
means that the object will give you direct access to the data inside of blender. Modification
of this object will directly change the data inside of blender. To copy a wrapped object
you need to use the object's constructor. If you copy and object by assignment you will not get
a second copy but a second reference to the same data. Only certain functions will return
wrapped data. This will be indicated in the method description.
"""
def __init__(list1 = None, list2 = None, list3 = None, list4 = None):
"""
Create a new matrix object from initialized values.
Example::
matrix = Matrix([1,1,1],[0,1,0],[1,0,0])
matrix = Matrix(mat)
matrix = Matrix(seq1, seq2, vector)
@type list1: PyList of int/float
@param list1: A 2d,3d or 4d list.
@type list2: PyList of int/float
@param list2: A 2d,3d or 4d list.
@type list3: PyList of int/float
@param list3: A 2d,3d or 4d list.
@type list4: PyList of int/float
@param list4: A 2d,3d or 4d list.
@rtype: New matrix object.
@return: It depends wheter a parameter was passed:
- (list1, etc.): Matrix object initialized with the given values;
- (): An empty 3 dimensional matrix.
"""

View File

@@ -0,0 +1,21 @@
"""
Basic Sound Playback
++++++++++++++++++++
This script shows how to use the classes: :class:`Device`, :class:`Factory` and
:class:`Handle`.
"""
import aud
device = aud.device()
# load sound file (it can be a video file with audio)
factory = aud.Factory('music.ogg')
# play the audio, this return a handle to control play/pause
handle = device.play(sound)
# if the audio is not too big and will be used often you can buffer it
factory_buffered = aud.Factory.buffer(sound)
handle_buffered = device.play(buffered)
# stop the sounds (otherwise they play until their ends)
handle.stop()
handle_buffered.stop()

Some files were not shown because too many files have changed in this diff Show More