7 years agoDetail sampling operator
Antony Riakiotakis [Sat, 22 Mar 2014 21:35:07 +0000 (23:35 +0200)]
Detail sampling operator

Located on topology panel.

To use just click on button and click on mesh.
Operator will just use the dimensions of the triangles below to set the
constant detail setting.

Also changed pair of scale/detail size with nice separate float
percentage value.

7 years agoCycles: SSE optimization for line segments/ribbons hair
Sv. Lockal [Sat, 22 Mar 2014 20:45:48 +0000 (00:45 +0400)]
Cycles: SSE optimization for line segments/ribbons hair

Gives ~11% speedup for hair.blend, ~10% for koro_final.blend

Also extract few common subexpressions in hair calculation.

Reviewed By: brecht

Differential Revision:

7 years agoFlood fill for dyntopo constant detail mode.
Antony Riakiotakis [Sat, 22 Mar 2014 15:47:18 +0000 (17:47 +0200)]
Flood fill for dyntopo constant detail mode.

Nothing spectacular here, fill tools are easy. Just take the dyntopo
code and repeat until nothing more to do.

The tool can be located in the dyntopo panel when the dyntopo constant
detail is on.

Also added scale factor for constant detail. This may change when detail
sampling gets in, I am not very happy with having two numbers here,
still it will give some more control for now.

7 years agoWarning cleanup:
Antony Riakiotakis [Sat, 22 Mar 2014 12:41:38 +0000 (14:41 +0200)]
Warning cleanup:

* Comparison in utf detection code always failed
* Cast to integer to silence grumpy 64bit gcc

7 years agoCleanup: Restrict the debug -gline-tables-only to cxx_debug in cycles and spelling
Jens Verwiebe [Sat, 22 Mar 2014 10:33:21 +0000 (11:33 +0100)]
Cleanup: Restrict the debug -gline-tables-only to cxx_debug in cycles and spelling

7 years agoA few spelling fixes
Joshua Leung [Sat, 22 Mar 2014 03:57:57 +0000 (16:57 +1300)]
A few spelling fixes

7 years agoMore driver linting messages - procedural animation and no-variables for average...
Joshua Leung [Sat, 22 Mar 2014 03:56:17 +0000 (16:56 +1300)]
More driver linting messages - procedural animation and no-variables for average,etc.

Inspired by T39315, this commit adds a few more driver "linting" messages used for
providing users with tips on how to use drivers better. This time, we specifically
address 2 cases:

1) Drivers being abused for procedural animation, due to the misconception that
   procedurally generating F-Curves using F-Modifiers means that drivers are needed
   to wire such procedural motion-sources to properties.
2) Setting up Average/Sum/Min/Max driver types without any input variables - you can't
   expect anything to happen (unless of course, your intention was to lock the property
   to 0.0)

7 years agoPossible fix for T39330 period key is ignored in transform operations
Antony Riakiotakis [Fri, 21 Mar 2014 19:06:49 +0000 (21:06 +0200)]
Possible fix for T39330 period key is ignored in transform operations

Not 100% certain if this fixes, I will ask the user to verify through

7 years agoFix T39279 Vertex paint modes do not work well with mirror modifier
Antony Riakiotakis [Fri, 21 Mar 2014 18:37:00 +0000 (20:37 +0200)]
Fix T39279 Vertex paint modes do not work well with mirror modifier

Issue here is that coordinates used for projection would not fit the
closest candidate. So it was possible to paint against the mirrored part
of the mesh, which would get clipped on reprojection.

Fix avoids reprojection by storing squared distance, and screen space
coordinates, which we will need again later anyway. Also we now always
paint against the closest vertex always. This is ensured because squared
distances for uninitialized vertices will be MAXFLOAT, thus failing the
strength test.

7 years agoCompile fix for Windows, M_PI was undefined.
Thomas Dinges [Fri, 21 Mar 2014 16:46:18 +0000 (17:46 +0100)]
Compile fix for Windows, M_PI was undefined.

7 years agoCycles Standalone: Support for relative paths and string OSL parameters.
Thomas Dinges [Fri, 21 Mar 2014 16:22:41 +0000 (17:22 +0100)]
Cycles Standalone: Support for relative paths and string OSL parameters.

Patch by John Haddon.
Differential Revision:

7 years agoForgot to remove test printf
Jens Verwiebe [Fri, 21 Mar 2014 14:32:07 +0000 (15:32 +0100)]
Forgot to remove test printf

7 years agoSculpt: Fix non openMP threads not set correct and use optimal omp threadcount for OSX
Jens Verwiebe [Fri, 21 Mar 2014 14:26:50 +0000 (15:26 +0100)]
Sculpt: Fix non openMP threads not set correct and use optimal omp threadcount for OSX
- i empirically found that using HT just gives overhead, even possibly slowing things down
- i propose other OS test this too again
- switching threaded on/off did not restored single threaded case ( credits to Sergey )

7 years agoFix T39323: Animation playback is not synchronized when Screen Layout changes.
Bastien Montagne [Fri, 21 Mar 2014 14:15:24 +0000 (15:15 +0100)]
Fix T39323: Animation playback is not synchronized when Screen Layout changes.

Own regression in rBd2a5ea04ed84.

This commit should be included if we do a 2.70 'a' release.

7 years agoPatch T22084: Robert Penner Easing Equations for FCurves
Joshua Leung [Fri, 21 Mar 2014 13:50:24 +0000 (02:50 +1300)]
Patch T22084: Robert Penner Easing Equations for FCurves

This commit introduces support for a number of new interpolation types
which are useful for motion-graphics work. These define a number of
"easing equations" (basically, equations which define some preset
ways that one keyframe transitions to another) which reduce the amount
of manual work (inserting and tweaking keyframes) to achieve certain
common effects. For example, snappy movements, and fake-physics such
as bouncing/springing effects.

The additional interpolation types introduced in this commit can be found
in many packages and toolkits (notably Qt and all modern web browsers).
For more info and a few live demos, see [1] and [2].

* Dan Eicher (dna)              - Original patch
* Thomas Beck (plasmasolutions) - Porting/updating patch to 2.70 codebase
* Joshua Leung (aligorith)      - Code review and a few polishing tweaks

Additional Resources:

7 years agoUse the new BKE_libblock_copy_nolib function for bNodeTree datablocks
Lukas Tönne [Fri, 21 Mar 2014 13:07:49 +0000 (14:07 +0100)]
Use the new BKE_libblock_copy_nolib function for bNodeTree datablocks
as well.

These were already doing the same thing, just not as nice. Only
difference is the do_action argument (false for BKE_libblock_copy_nolib)
but this is of no consequence because the function is only called for
trees nested inside material, scene, etc., which never have own actions.

7 years agoFix T39209: Localizing materials could cause heisenbug with concurrent
Sergey Sharybin [Fri, 21 Mar 2014 12:44:38 +0000 (13:44 +0100)]
Fix T39209: Localizing materials could cause heisenbug with concurrent
depsgraph updates.

Material datablocks were localized by first making a regular datablock
copy, which always gets inserted into the bmain list, and then removing
it again from bmain.

Problem is that this localization happens in preview threads, which can
run while the depsgraph is also updating GPU materials. In case the
copying of materials takes any amount of time, this can cause the
depsgraph call to material_changed to use an invalid, localized material
and access invalid GPUMaterial lists which have already been freed for
the actual material.

Solution is to not add localized datablocks to the bmain lists in the
first place. bmain should be totally immutable during preview or render

7 years agoFix T39312 Multipling two values in the Transform Tools Number Input not possible.
Bastien Montagne [Fri, 21 Mar 2014 11:05:13 +0000 (12:05 +0100)]
Fix T39312 Multipling two values in the Transform Tools Number Input not possible.

There was actually a few bugs in new event handling of numinput :/

In case of 2.70 'a' release, this commit should be considered imho.

7 years agoAttempt to fix compilation error with msvc2013
Sergey Sharybin [Fri, 21 Mar 2014 10:06:30 +0000 (16:06 +0600)]
Attempt to fix compilation error with msvc2013

7 years agoUpdate Eigen to version 3.2.1
Sergey Sharybin [Fri, 21 Mar 2014 10:04:53 +0000 (16:04 +0600)]
Update Eigen to version 3.2.1

Main purpose of this is to have SparseLU solver which
we can use now as a replacement to opennl library.

7 years agoFix T39305: Matcap Crash when using Material Nodes in Blender Internal
Sergey Sharybin [Fri, 21 Mar 2014 09:15:43 +0000 (15:15 +0600)]
Fix T39305: Matcap Crash when using Material Nodes in Blender Internal

This is a regression in d34d745, texture painting didn't set is_paint
if draw type < DT_SOLID which is weird.

7 years agoFix T39306: Backface culling in Multitexture always uses mat game settings
Bastien Montagne [Fri, 21 Mar 2014 09:11:54 +0000 (10:11 +0100)]
Fix T39306: Backface culling in Multitexture always uses mat game settings

Trying to use mat game settings in 3DView makes sense - but only when we are using "Game Engine" as 'renderer'!

Note GLSL code completely ignores mat game settings currently, could be added too...

7 years agoFix T38051: Even if Color Management is disabled, it is still applied to the background
Sergey Sharybin [Fri, 21 Mar 2014 08:06:44 +0000 (14:06 +0600)]
Fix T38051: Even if Color Management is disabled, it is still applied to the background

7 years agoFix T39186: Matroska audio support (mka, mkv without video stream)
Sergey Sharybin [Fri, 21 Mar 2014 07:52:37 +0000 (13:52 +0600)]
Fix T39186: Matroska audio support (mka, mkv without video stream)

.mka files were considered image files when adding to sequencer
using drag-n-drop.

7 years agoFix T39207: FCurve evaluation regressions following 2aff243 (again)
Joshua Leung [Fri, 21 Mar 2014 01:24:15 +0000 (14:24 +1300)]
Fix T39207: FCurve evaluation regressions following 2aff243 (again)

Yet another attempt at fixing the problems here. This time, I've added a new
function/version of the binary search utility so that we can pass in custom
thresholds (Note: This ability is only used for evaluation currently, with
everything else using a wrapper which still uses the old default threshold),
making it ok to start trusting the "exact" parameter.

7 years agoDebug prints weren't getting triggered, since they no longer use the old flag
Joshua Leung [Thu, 20 Mar 2014 23:55:10 +0000 (12:55 +1300)]
Debug prints weren't getting triggered, since they no longer use the old flag

7 years agoFollow up to the previous commit
Sergey Sharybin [Thu, 20 Mar 2014 17:45:29 +0000 (23:45 +0600)]
Follow up to the previous commit

Just update to the changelog

7 years agoUpdate Libmv to latest upstream
Sergey Sharybin [Thu, 20 Mar 2014 17:03:11 +0000 (23:03 +0600)]
Update Libmv to latest upstream

This is mainly a maintaince commit which syncs changes
between Blender and Libmv upstream also bringing new
GLog version.

This GLog version is presumably have better support of
MinGW from "the box".

This commit is also aimed to make further 3d part libs
update easier.

7 years agoFix for clang build warnings: ATTR_WARN_UNUSED_RESULT is used after
Lukas Tönne [Thu, 20 Mar 2014 09:08:19 +0000 (10:08 +0100)]
Fix for clang build warnings: ATTR_WARN_UNUSED_RESULT is used after
the inline definitions are included, which gives lots of warnings
"attribute declaration must precede definition".

See also rB83617429cf28f2a19e991a0f71d892fc159a4419

7 years agoCode cleanup: use bools
Campbell Barton [Thu, 20 Mar 2014 11:56:28 +0000 (22:56 +1100)]
Code cleanup: use bools

7 years agoExtend workaround to all OS :avoid link failure with clang 3.4 debug
Jens Verwiebe [Thu, 20 Mar 2014 11:38:45 +0000 (12:38 +0100)]
Extend workaround to all OS  :avoid link failure with clang 3.4 debug

7 years agoFix T39270: Since as the Move Clip Editor have only two modes, menu on tab is needless
Sergey Sharybin [Thu, 20 Mar 2014 10:08:42 +0000 (16:08 +0600)]
Fix T39270: Since as the Move Clip Editor have only two modes, menu on tab is needless

7 years agoCode cleanup: use bool/true/false in clip editor
Sergey Sharybin [Thu, 20 Mar 2014 09:52:00 +0000 (15:52 +0600)]
Code cleanup: use bool/true/false in clip editor

7 years agoCode cleanup: use true/false in sequencer functions
Sergey Sharybin [Thu, 20 Mar 2014 09:45:20 +0000 (15:45 +0600)]
Code cleanup: use true/false in sequencer functions

7 years agoFix T39141: Video Sequencer Proxies don't take into account Strip Input Offset (or...
Sergey Sharybin [Thu, 20 Mar 2014 09:08:23 +0000 (15:08 +0600)]
Fix T39141: Video Sequencer Proxies don't take into account Strip Input Offset (or strip modifiers)

Basically issue was caused by the fact that strip for proxy has been
post-processed but proxy files were considered pre-processed. This lead
to situation of postprocessing being applied twice.

7 years agoFix for crash generating docs (enums with only callbacks)
Campbell Barton [Thu, 20 Mar 2014 08:17:08 +0000 (19:17 +1100)]
Fix for crash generating docs (enums with only callbacks)

7 years agoFix for crash happening on blender exit after the bake
Sergey Sharybin [Thu, 20 Mar 2014 07:15:27 +0000 (13:15 +0600)]
Fix for crash happening on blender exit after the bake

The issue is caused by 1a79abdad, and annoyingly it's a regression
since 2.69, so if we do 'a', this commit should be ported there.

7 years agoBGE: Adding support for the Cast Only material option.
Mitchell Stokes [Mon, 27 Jan 2014 03:28:26 +0000 (19:28 -0800)]
BGE: Adding support for the Cast Only material option.

Note: This does not add support for the option in the viewport.

7 years agoFix T39271: Crash in MCE with "p" shortcut without clip
Sergey Sharybin [Thu, 20 Mar 2014 06:39:02 +0000 (12:39 +0600)]
Fix T39271: Crash in MCE with "p" shortcut without clip

Weird nobody noticed this before, issue exists in 2.69 as well..

7 years agoFix T36566: 2D filters broken in the Blenderplayer when using side by side stereo
Mitchell Stokes [Thu, 20 Mar 2014 05:33:26 +0000 (22:33 -0700)]
Fix T36566: 2D filters broken in the Blenderplayer when using side by side stereo

GPC_Canvas::GetWindowArea() and KX_BlenderCanvas::GetWindowArea() are tracking two
different things. The 2d filter system doesn't actually need the window area and
can get by just using the viewport dimensions, which it now does. The GetWindowArea()
mess should probably be cleaned up.

7 years agoView3D: remove orbit snapping LUT, allow to snap axis but not roll
Campbell Barton [Thu, 20 Mar 2014 04:19:02 +0000 (15:19 +1100)]
View3D: remove orbit snapping LUT, allow to snap axis but not roll

7 years agoMath Lib: add angle_qt functions
Campbell Barton [Thu, 20 Mar 2014 03:39:32 +0000 (14:39 +1100)]
Math Lib: add angle_qt functions

7 years agoView3D: avoid matrix multiply using ED_view3d_boundbox_clip
Campbell Barton [Thu, 20 Mar 2014 01:17:44 +0000 (12:17 +1100)]
View3D: avoid matrix multiply using ED_view3d_boundbox_clip

7 years agoCode cleanup: comment unused OpenGL util functions
Campbell Barton [Thu, 20 Mar 2014 00:54:32 +0000 (11:54 +1100)]
Code cleanup: comment unused OpenGL util functions

7 years agoError in last commit
Campbell Barton [Thu, 20 Mar 2014 00:49:01 +0000 (11:49 +1100)]
Error in last commit

7 years agoVertex Paint: inverted line drawing, white lines were often hard to see
Campbell Barton [Thu, 20 Mar 2014 00:44:48 +0000 (11:44 +1100)]
Vertex Paint: inverted line drawing, white lines were often hard to see

7 years agoVertex Paint: use solid shading, shadeless in wire (like wpaint)
Campbell Barton [Thu, 20 Mar 2014 00:33:33 +0000 (11:33 +1100)]
Vertex Paint: use solid shading, shadeless in wire (like wpaint)

7 years agoFix kdopbvh incorrect checks for failed allocs
Campbell Barton [Wed, 19 Mar 2014 23:49:30 +0000 (10:49 +1100)]
Fix kdopbvh incorrect checks for failed allocs

also assert for invalid args

7 years agoCode cleanup: de-triplicate add menu/toolbars, also style edits
Campbell Barton [Wed, 19 Mar 2014 14:32:44 +0000 (01:32 +1100)]
Code cleanup: de-triplicate add menu/toolbars, also style edits

7 years agoFix for Layout.operator_enum ignoring alignment
Campbell Barton [Wed, 19 Mar 2014 14:15:34 +0000 (01:15 +1100)]
Fix for Layout.operator_enum ignoring alignment

7 years agoUsual UI messages fixes...
Bastien Montagne [Wed, 19 Mar 2014 14:25:10 +0000 (15:25 +0100)]
Usual UI messages fixes...

7 years agoFix T39233: Face assigned textures bake too bright
Sergey Sharybin [Wed, 19 Mar 2014 14:21:46 +0000 (20:21 +0600)]
Fix T39233: Face assigned textures bake too bright

Shade input wasn't initialized properly for texture baking.

7 years agoA simpler fix for the "clive" part of T39207 without the precision granularity risks
Joshua Leung [Wed, 19 Mar 2014 13:22:42 +0000 (02:22 +1300)]
A simpler fix for the "clive" part of T39207 without the precision granularity risks

7 years agoFix T39207: FCurve evaluation regressions following 2aff243
Joshua Leung [Wed, 19 Mar 2014 13:19:35 +0000 (02:19 +1300)]
Fix T39207: FCurve evaluation regressions following 2aff243

This commit attempts to fix some of the FCurve evaluation regressions arising from
an earlier commit to speed up the process using binary search. Further tweaks may still
be needed though to get this to an acceptable level of reliability (namely, tuning the
threshold defining which keyframes get considered "close together"). Since we're still
in an early stage of the 2.71 dev cycle, for now it's still worth trying to get this
working instead of simply reverting this (which can still be done later if it proves too

Specific fixes:
* The previous code was somewhat dangerous in that it allowed out-of-bounds accessing
  of memory when a == 0. It turns out this was more common than originally anticipated
  (as the assert I added here ended up failing in the "action_bug.blend" file in the report)
* Tweaked the code used to test for closely-spaced points so that the "Clive.blend" example
  for driver curves won't fail. The approach used here has the downside though that
  since "exact" uses a might coarser threshold for equality, there may be some precision
  loss issues causing backwards compat issues (namely with closely spaced keyframes, or
  for certain NLA strips).

For now, I've left in some debug prints that can be enabled by running Blender in debug
mode (i.e. "blender -d"), which can provide some useful tuning info should we need to
look more into our approach here.

7 years agoFix T39260: "Redo Last" operator popup shows macro operator labels twice.
Lukas Tönne [Wed, 19 Mar 2014 12:18:43 +0000 (13:18 +0100)]
Fix T39260: "Redo Last" operator popup shows macro operator labels twice.

The popup was showing an explicit uiItemL as well as using the
UI_LAYOUT_OP_SHOW_TITLE flag. Both do the exact same thing.

7 years agoFix `bpy.types.Operator.bl_rna.foobar` not working since rBfe094eaf20.
Bastien Montagne [Wed, 19 Mar 2014 11:43:29 +0000 (12:43 +0100)]
Fix `bpy.types.Operator.bl_rna.foobar` not working since rBfe094eaf20.

When path to resolve "finishes" on a collection prop, do not erase the returned prop!

This caused py's path_resolve to return same PointerRNA as the one passed as parameter, leading to
inifinte recursion in Operator's accessor func (__getattribute__)...

7 years agoUps, forgot to remove something i just placed temporary …
Jens Verwiebe [Wed, 19 Mar 2014 10:26:41 +0000 (11:26 +0100)]
Ups, forgot to remove something i just placed temporary …

7 years agoOSX/bullet/scons: a better workaround for clang 3.4 issues with actual bullet, accord...
Jens Verwiebe [Wed, 19 Mar 2014 10:21:24 +0000 (11:21 +0100)]
OSX/bullet/scons: a better workaround for clang 3.4 issues with actual bullet, according cmake ( less speed penalty )

7 years agoFix T39247
Martijn Berger [Wed, 19 Mar 2014 06:36:34 +0000 (07:36 +0100)]
Fix T39247

Changes to interpolation break texture allocation on sm35 and greater.

7 years agoCode cleanup: unreachable break/return
Campbell Barton [Wed, 19 Mar 2014 01:46:33 +0000 (12:46 +1100)]
Code cleanup: unreachable break/return

7 years agoUI: Add splash link to gooseberry (remove user community link)
Campbell Barton [Tue, 18 Mar 2014 20:14:56 +0000 (07:14 +1100)]
UI: Add splash link to gooseberry (remove user community link)

7 years agoCode cleanup: double/float
Campbell Barton [Tue, 18 Mar 2014 20:07:59 +0000 (07:07 +1100)]
Code cleanup: double/float

7 years agoFix T39252: Regression: Auto perspective fails when switching from {front, side,...
Bastien Montagne [Tue, 18 Mar 2014 18:50:20 +0000 (19:50 +0100)]
Fix T39252: Regression: Auto perspective fails when switching from {front, side, top} to camera view, and then to user persp.

When leaving cam view, if autopersp is ON, and previous view was an axis one, we have to force new view in perspective mode - else, we reuse previous stored mode (persp or ortho).

7 years agoCleanup: factorize RNA accessor code of modifiers (saves over 160 lines of dummy...
Bastien Montagne [Tue, 18 Mar 2014 16:17:51 +0000 (17:17 +0100)]
Cleanup: factorize RNA accessor code of modifiers (saves over 160 lines of dummy code!)

Reviewers: campbellbarton

Reviewed By: campbellbarton

Differential Revision:

7 years agoFix T38566: "Separate images" in VSE is not working any longer
Sergey Sharybin [Tue, 18 Mar 2014 16:45:33 +0000 (22:45 +0600)]
Fix T38566: "Separate images" in VSE is not working any longer

7 years agoCorrection to particle system commit: wrong struct name was used
Sergey Sharybin [Tue, 18 Mar 2014 16:25:29 +0000 (22:25 +0600)]
Correction to particle system commit: wrong struct name was used

7 years agoFix T39203: Boid particle naming UI semi-freeze
Bastien Montagne [Tue, 18 Mar 2014 14:24:34 +0000 (15:24 +0100)]
Fix T39203: Boid particle naming UI semi-freeze

uiList was not handling correctly UI_BUT_DISABLED TEX name buttons!

7 years agoFix T39180: Particle with fluid physics unstable.
Lukas Tönne [Tue, 18 Mar 2014 12:36:24 +0000 (13:36 +0100)]
Fix T39180: Particle with fluid physics unstable.

Fluid sims have a very nasty feature for interaction, in which a psys
can directly update the bvhtree for //another object's psys//. This
breaks with threaded depsgraph evaluation and is generally a no-go.

To avoid crashes for now, use a global mutex to avoid concurrent writes
to an object psys' bvhtree.

7 years agoFix T39136: DupliFaces: Inconsistent handling of group member types
Sergey Sharybin [Tue, 18 Mar 2014 12:05:59 +0000 (18:05 +0600)]
Fix T39136: DupliFaces: Inconsistent handling of group member types

The issue was caused by assumption object matricies can be modified
by DupliObject->obmat outside of the duplilist iteration cycle.

This isn't really true. The thing is, old code used to modify object
matrix based on the duplicated matrix to make it so modifier evaluation
kind of works (it'll use proper matrix in most cases, but think there
might be some cases when this assumption also breaks).

Even when matrix is copied from dupliobject to object in advance
(to mimic old behavior or dupli system) you're still to use matrix
from dupliobject inside a cycle body. This is because the same object
might be modified multiple times by different dupliobject. For example,
in case of duplifaces loads of faces will modify object's matrix and
before this change matrix from the last face would have been used.

The fix is simple one-liner which makes it so render instance will
use proper matrix from dupliobject.

All the rest bits here (pre-loading matrices and restoring them in
the reverse order) totally matches old behavior of duplilist.

This is a regression and to be ported to 2.70 tag!

7 years agoOSX/cmake/bullet: fix ambigoius compiler ID and make deoptimize fix a bit stricter...
Jens Verwiebe [Tue, 18 Mar 2014 11:16:53 +0000 (12:16 +0100)]
OSX/cmake/bullet: fix ambigoius compiler ID and make deoptimize fix a bit stricter to reduce speed penalty

7 years agoUI: bypass text clipping on buttons with no text
Campbell Barton [Tue, 18 Mar 2014 00:07:10 +0000 (11:07 +1100)]
UI: bypass text clipping on buttons with no text

7 years agoCode cleanup: jitter, use 2d float array
Campbell Barton [Mon, 17 Mar 2014 23:50:24 +0000 (10:50 +1100)]
Code cleanup: jitter, use 2d float array

7 years agoFollow up to previous commit:
Antony Riakiotakis [Mon, 17 Mar 2014 23:33:28 +0000 (01:33 +0200)]
Follow up to previous commit:

Make HSL wheel useful in compositing.

In HSL, 0.5 lightness corresponds to most vibrant colors so make that
default for locked wheels (previous value of 1.0 just made it white).
Also, unlock the wheel for both very bright and very dark colors.

7 years agoFix T39228 Gamma/lift/gain are burned out in the circular color pickers
Antony Riakiotakis [Mon, 17 Mar 2014 23:08:24 +0000 (01:08 +0200)]
Fix T39228 Gamma/lift/gain are burned out in the circular color pickers
and value/lightness slider stops midway.

Issue here is manyfold:

Color wheel does not support properties with different soft min/max
values than 1.0 (which after experimenting a little I left as is), and
also color management is completely destroying the mapping between the
value slider and the RNA property value range. To solve this I have
disabled color management by setting the property to gamma corrected
(only in RNA, Sequence editor coders please check!), otherwise it will
just become a big mess of tracking where color comes from and what kind
of color transforms it needs in different color pickers (if property has
non normalized range etc). HSL is not really meant to represent colors
outside a normalized space so I have disabled setting lightness above
1.0 in this model.

This will work, however it is hacking a color picker to do something
other than what it is supposed to do: pick a color from the screen
accurately. Which means normalized values always. The non normalized
colors picked for lift/gain/gamma through the pickers do not correspond
to any accurate colors; they are rather a user friendly way to 'sort of'
choose a color and a gamma with an indication of maximum value.

I think that lift/gamma/gain nodes need a dedicated widget for this
(besides it is quite clear that some options are written for that use
case) -or- a separate gamma multiplier for the picked color (which
should itself be in a normalized space)

7 years agoKDTree: deprecate 'normal' argument
Campbell Barton [Mon, 17 Mar 2014 22:05:07 +0000 (09:05 +1100)]
KDTree: deprecate 'normal' argument

Normals for each kdtree node were allocated but never used,
and search args only use in particles/boids code.

7 years agoUI: Add theme color for viewport overlay
Campbell Barton [Mon, 17 Mar 2014 18:34:43 +0000 (05:34 +1100)]
UI: Add theme color for viewport overlay

Was using wire or black in many places, this color is used for cursor,
camera guides, transform helper lines. So its possible to have a dark
background with light overlay color.

Patch D331 by Brita, with some edits.

7 years agoCode cleanup: comments and typos
Campbell Barton [Mon, 17 Mar 2014 15:40:39 +0000 (02:40 +1100)]
Code cleanup: comments and typos

7 years agoFix own bug reported on irc by Venomgfx, missing value slider in color
Antony Riakiotakis [Mon, 17 Mar 2014 18:01:33 +0000 (20:01 +0200)]
Fix own bug reported on irc by Venomgfx, missing value slider in color

7 years agoFix T31598: smart UV failed for small faces
Campbell Barton [Mon, 17 Mar 2014 14:34:14 +0000 (01:34 +1100)]
Fix T31598: smart UV failed for small faces

previous fixes only tweaked epsilon, but logic for skipping zero area
boxes was still wrong.

7 years agoPython API: add Vector.orthogonal() method
Campbell Barton [Mon, 17 Mar 2014 13:37:43 +0000 (00:37 +1100)]
Python API: add Vector.orthogonal() method

7 years agoCode cleanup: style
Campbell Barton [Mon, 17 Mar 2014 10:48:13 +0000 (21:48 +1100)]
Code cleanup: style

7 years agoFix T39208: Adding scene to another scene's VSE causes audio and video to be unsynchr...
Bastien Montagne [Sun, 16 Mar 2014 19:11:24 +0000 (20:11 +0100)]
Fix T39208: Adding scene to another scene's VSE causes audio and video to be unsynchronized

Audio of 'linked' scene has to be offset by the startframe of that scene, else it behaves as if 'linked' scene always started at frame 1...

7 years agoFix T39215: Shortest path error
Campbell Barton [Sun, 16 Mar 2014 16:41:09 +0000 (03:41 +1100)]
Fix T39215: Shortest path error

7 years agoFix T39210: Grid Fill is generating mesh that's inconsistent with selected edge loops
Bastien Montagne [Sun, 16 Mar 2014 15:31:19 +0000 (16:31 +0100)]
Fix T39210: Grid Fill is generating mesh that's inconsistent with selected edge loops

Issue was in BLI's rotation_between_vecs_to_quat(), which did not handled correctly cases where both vectors are colinear.

Patch by Campbell Barton and me.

Issue originaly tracked down by Yan Shi, many thanks!

7 years agoEditMesh: Support contracting the selection as well as extending
Campbell Barton [Sun, 16 Mar 2014 13:23:05 +0000 (00:23 +1100)]
EditMesh: Support contracting the selection as well as extending

This allows for holding ctrl while switching from face->edge modes to
select an edge-ring.

7 years agoCode cleanup: naming conventions
Campbell Barton [Sun, 16 Mar 2014 11:11:14 +0000 (22:11 +1100)]
Code cleanup: naming conventions

7 years agoCode cleanup: modifier_skin_customdata_ensure was a bad level call
Campbell Barton [Sun, 16 Mar 2014 10:55:30 +0000 (21:55 +1100)]
Code cleanup: modifier_skin_customdata_ensure was a bad level call

7 years agoCycles: Direct multi light sampling in the Branched Path Integrator is optional now.
Thomas Dinges [Sat, 15 Mar 2014 16:36:44 +0000 (17:36 +0100)]
Cycles: Direct multi light sampling in the Branched Path Integrator is optional now.
Disabling this can improve performance, when we need a lot of AA Samples anyway, to clear up the render.

Simple example .blend:

Differential Revision:

7 years agoUI: Improved layout for Cycles Volume Sampling panel.
Thomas Dinges [Sat, 15 Mar 2014 15:52:42 +0000 (16:52 +0100)]
UI: Improved layout for Cycles Volume Sampling panel.

7 years agoUI: Move OpenGL Settings (AA and Alpha) into the Info Editor render menu.
Thomas Dinges [Sat, 15 Mar 2014 15:47:03 +0000 (16:47 +0100)]
UI: Move OpenGL Settings (AA and Alpha) into the Info Editor render menu.

7 years agoCode cleanup: use r_ prefix for return args
Campbell Barton [Sat, 15 Mar 2014 16:24:05 +0000 (03:24 +1100)]
Code cleanup: use r_ prefix for return args

7 years agoCode cleanup: Don't assign time 2x, we only need it for Object Motion here.
Thomas Dinges [Sat, 15 Mar 2014 13:22:41 +0000 (14:22 +0100)]
Code cleanup: Don't assign time 2x, we only need it for Object Motion here.

7 years agoCode cleanup: spelling & style
Campbell Barton [Sat, 15 Mar 2014 09:08:29 +0000 (20:08 +1100)]
Code cleanup: spelling & style

7 years agoFix T39189: Node editor Map Uv requires an scale node to work.
Lukas Tönne [Sat, 15 Mar 2014 09:24:07 +0000 (10:24 +0100)]
Fix T39189: Node editor Map Uv requires an scale node to work.

This is a regression caused by rB67134a7bf689279785e2e40b29cd24243813998b
The UV coordinates read from the UV input must be scaled by the Image
input size instead of the UV input size.

Also now this node uses the UV input resolution instead of the Image
resolution, since this is what determines the available resolution. The
image is EWA-sampled anyway, it's resolution does not have a direct

7 years agoPatch T36209: Use binary search function for evaluating F-Curves
Joshua Leung [Fri, 14 Mar 2014 22:45:14 +0000 (11:45 +1300)]
Patch T36209: Use binary search function for evaluating F-Curves

This provides a speedup to evaluating long F-Curves in fcurve_eval_keyframes()
by using the pre-existing binarysearch_bezt_index() function (used for keyframe
insertion) to find the relevant BezTriple on the FCurve at the current evaltime.
The current code loops over all BezTriples (sometimes not even breaking from the
loop after cvalue has been evaluated).

Reviewer Notes:
- Unlike in the original patch, we use the old/existing logic instead of
  checking that (exact == true). See comments in code and also on the tracker
  entry for this patch for more details.

Patch By: Josh Wedlake

7 years agoUI Tweak: Add a convenience button for switching to Bone Constraints Tab
Joshua Leung [Mon, 10 Mar 2014 03:56:31 +0000 (16:56 +1300)]
UI Tweak: Add a convenience button for switching to Bone Constraints Tab

To reduce user confusion, we were already presenting users with an error message
when they tried to edit constraints for bones from the Object Constraints tab.
This commit just makes things more convenient by adding a button which takes
users to the right tab when clicked.

7 years agoSpelling fix
Joshua Leung [Sun, 9 Mar 2014 06:30:52 +0000 (19:30 +1300)]
Spelling fix

7 years agoFix T39166: Disappearing text objects
Sergey Sharybin [Fri, 14 Mar 2014 11:49:23 +0000 (17:49 +0600)]
Fix T39166: Disappearing text objects

This is a failure of viewport direct displist creation
caused by existing curve_cache pointer which empty content.

Made it so if the curve isn't evaluated it's curve_cache is NULL.

This is just-another-regression to be ported to the release.

7 years agoFix T38897: Problems moving animation channels up and down in dope sheet/action editor.
Bastien Montagne [Fri, 14 Mar 2014 11:45:22 +0000 (12:45 +0100)]
Fix T38897: Problems moving animation channels up and down in dope sheet/action editor.

Basic idea is to check whether an element is visible or not, and ignore those that are hidden, during move up/down.

Reviewers: aligorith

Reviewed By: aligorith

Differential Revision:

7 years agoFix T39180: Particle with fluid physics unstable.
Lukas Tönne [Fri, 14 Mar 2014 10:03:04 +0000 (11:03 +0100)]
Fix T39180: Particle with fluid physics unstable.

Fluid particles use the particle system's bvhtree structure, which is a
runtime BVH tree. This was not reset properly on copying objects/psys,
which lead to concurrent access in threaded depsgraph updates and memory