Commit Graph

52660 Commits

Author SHA1 Message Date
Campbell Barton 605e184167 Cleanup: use const for transform internal API 2018-05-21 17:24:14 +02:00
Campbell Barton 882daeffc5 RNA: support for PARM_OUTPUT & PARM_RNAPTR 2018-05-21 12:34:11 +02:00
Brecht Van Lommel 9f2ae547c0 Fix/workaround RNA build error in C++ API.
It seems output parameter needs to be the last one.
2018-05-21 11:13:56 +02:00
Campbell Barton 4198c18f15 Cleanup: correct variable names 2018-05-21 10:53:50 +02:00
Campbell Barton 12a60265cd WM: utility to find a keymap item from an operator
Also RNA access to WM_keyconfig_update,
needed when generating dynamic keymaps used in menus immediately after.
2018-05-21 10:35:44 +02:00
Philipp Oeser 5e7a21a5f5 Fix T55115: crash when iterating SmokeDomainSettings color_grid property
through python
2018-05-18 14:34:27 +02:00
Campbell Barton 1cc4ab481e Fix crash drawing polygon curves 2018-05-18 14:23:53 +02:00
Aaron Carlisle 96fba1e101 Color: Assume Rec 709 in remaining comp nodes
Part of T54798
2018-05-17 17:20:32 -04:00
Campbell Barton 0e0d99161a RNA: move enums to rna_rna.c
Needed for use in rna non runtime code.
2018-05-17 19:10:45 +02:00
Campbell Barton b290048257 makesrna: error check from 2.8 2018-05-17 19:05:46 +02:00
Campbell Barton 4461be1b72 Fix T55032: Redo w/ file saved in edit-mode failed
It's important edit-mode has a step stored for redo to work,
file load now ensures this in a generic way.
2018-05-15 19:37:06 +02:00
Campbell Barton 91504ed26e Fix assert using '//' on an unsaved file
Annoying for debug builds.
2018-05-15 17:27:36 +02:00
Campbell Barton 3eb9cc69f2 Cleanup: last spacetype enum name 2018-05-15 11:12:49 +02:00
Campbell Barton 9636cab009 Undo System: remove nested edit-mode undo calls
Regression in recent undo system changes,
This caused T55048.

When each mode had its own undo stack it was important
to initialize it when entering edit-mode.
2018-05-15 10:10:48 +02:00
Campbell Barton ae8225ba6d Fix BMesh bisect not flagging dirty indices 2018-05-15 09:04:12 +02:00
Campbell Barton 43ee4d5d7c Cleanup: quiet GCC -Wtype-limits
While the warning can normally be disabled, we don't have have as much
control of warnings when macros are used.
2018-05-14 09:00:42 +02:00
Campbell Barton c1d737eb95 BLI_utildefines: re-ordering array delete macro 2018-05-14 08:38:53 +02:00
Campbell Barton b99d064e91 Cleanup: trailing space 2018-05-13 06:44:03 +02:00
Campbell Barton c84b8d4801 Cleanup: modifier arg wrapping 2018-05-12 08:04:56 +02:00
Campbell Barton 925e775818 EditMesh: remove duplicate rip macro
Change the fill setting in the keymap,
this allows tool access the macro with either setting.
2018-05-11 20:02:12 +02:00
Campbell Barton 73a7885ab3 WM: initialize last used macro properties 2018-05-11 20:01:51 +02:00
Bastien Montagne d5c1c0b10d Fix (unreported) broken freeing code for Sequencer.
Freeing sequencer would always do usercount, which is now forbidden when
called from main ID freeing code.

Annoying in 2.7x, much more critical issue in 2.8!

Also, moved RNA sequencer API functions to proper rna_scene_api.c file.
2018-05-11 11:23:11 +02:00
Bastien Montagne 13beeb5892 Fix (unreported) load image code calling icin/preview update from non-Main thread.
Icin/preview only works in main thread, while image loading can be done
from others too... This could have generated random crashes and such.
2018-05-11 10:48:04 +02:00
Bastien Montagne 0385b33f0b Fix broken 'check/validate libs' code with indirect libs.
Readcode always set relative paths of indirectly linked libs relative to
*current* .blend file, not to the library using it.

But BKE_library_filepath_set was then setting them relative to their
parent library, breaking checking code (and saved files even :((( ).
2018-05-09 15:52:29 +02:00
Philipp Oeser 69f2305415 Fix T54992: Lattice modifier on another Lattice object does not take the
Influence vertexgroup into account
2018-05-09 14:41:25 +02:00
Philipp Oeser 34c474e695 Fix T54997: simple typo in property description 2018-05-09 14:26:47 +02:00
Bastien Montagne f3efa9e15f Fix (unreported) bug in BVHTree 'free tessfaces' flag setting.
Could lead to atempt to free NULL pointer, and/or memory leak.
2018-05-09 12:33:21 +02:00
Campbell Barton b59b812400 MSVC: resolve near/far issue take2
Previous fix failed w/ compositor,
tested on MSVC2015, full build.
2018-05-09 11:23:32 +02:00
Campbell Barton 598216c36e MSVC: remove hack for near/far name collision
windows headers define these, conflicting w/ View3D.near/far.
2018-05-09 10:00:55 +02:00
Aaron Carlisle 80844fdfc0 Color: Combine/Separate YCbCrA node default to rec. 709
This commit is part of T54798

Differential Revision: https://developer.blender.org/D3183
2018-05-08 22:24:58 -04:00
Campbell Barton e0a436fcff Cleanup: includes 2018-05-08 18:01:47 +02:00
Campbell Barton 0012082c10 Cleanup: move mesh conversion into own function 2018-05-08 17:54:25 +02:00
Bastien Montagne 4e4a93bc45 Fix building with latest versions of ffmpeg.
Some years-old deprecated stuff has now been removed.

Correct solution is probably to use valid defines etc. in own code, but
this is more FFMEPG maintainer task (since it also may change how old
FFMPEG we do support...).
2018-05-08 16:00:52 +02:00
Bastien Montagne 43e0e8defa Fix (unreported) bloody modifiers messing with ID user count in copy.
User count of IDs is handled by higher-level, generic function,
low-level copydata functions *MUST NOT* touch them anymore, ever!
2018-05-08 15:27:10 +02:00
Bastien Montagne 3740f7593d Cleanup: Nuke empty dummy wrappers around modifier_copyData_generic().
This also changes signature of modifier copy callback, first (source)
parameter is now a const, which is saner anyway!
2018-05-08 15:04:10 +02:00
Bastien Montagne 49fe27ee46 Modifiers: sanitize/cleanup modifiers' copying & freeing code.
Should also fix T55000: Crash with hooks and curves in Cycles render.
2018-05-08 14:22:14 +02:00
Campbell Barton 5358026511 Cleanup: quiet -Warray-bounds warning 2018-05-08 13:32:52 +02:00
Sergey Sharybin 59ce30f32b Tracking: Use bmain from context 2018-05-08 11:58:42 +02:00
Campbell Barton 433aaa8c2e Cleanup: remove unused wmReport struct 2018-05-08 07:52:13 +02:00
Bastien Montagne c09e22306a Fix (unreported) memleak when copying object with some modifiers. 2018-05-07 17:59:23 +02:00
Campbell Barton f74d85ffc8 Cleanup: rename char/float conversion functions
- FTOCHAR       -> unit_float_to_uchar_clamp
- F3TOCHAR3     -> unit_float_to_uchar_clamp_v3 (swap args)
- F4TOCHAR4     -> unit_float_to_uchar_clamp_v4 (swap args)
- FTOUSHORT     -> unit_float_to_ushort_clamp
- USHORTTOUCHAR -> unit_ushort_to_uchar
2018-05-07 17:51:40 +02:00
Campbell Barton 905eeb0bc7 Cleanup: move unit char/short/float to functions
This caused GCC 8.1 to crash at build time,
but was also not very nice use of macros.
2018-05-07 17:50:25 +02:00
Philipp Oeser 66ec3c7e7f Fix Movieclip editors 'graph' and 'dopesheet' view using themes region
background setting

mentioned in T54942

Reviewed By: campbellbarton

Differential Revision: https://developer.blender.org/D3200
2018-05-07 14:57:05 +02:00
Philipp Oeser 1f76e6c326 Fix T54525: crash when setting number of frames to use between dupoff
frames

caused division by zero if both dupli_frames_on and dupli_frames_off are
zero. doing this doesnt seem useful, dupliframes can be disabled in
other ways.

Reviewed By: campbellbarton

Differential Revision: https://developer.blender.org/D3132
2018-05-07 14:49:09 +02:00
Sergey Sharybin 6c243b7e40 More tweaks to strict compiler flags 2018-05-07 14:28:22 +02:00
Sergey Sharybin 592c3881ba Silence compilation error around possible fall-through 2018-05-07 14:19:12 +02:00
Howard Trickey cd3f5983cd Fix Bevel percent mode bug 54228
Previous new adjust pass commit should have excluded percent mode.
2018-05-07 07:05:41 -04:00
Philipp Oeser 9eb5aa32b8 Fix T54324: remove stencil entries from weight paint keymap
Reviewed By: mont29

Differential Revision: http://developer.blender.org/D3178
2018-05-07 12:28:15 +02:00
Sergey Sharybin ea1751a038 Fix T54594: Lattice with Armature modifier not updating correctly 2018-05-07 12:05:09 +02:00
Bastien Montagne a3b4c3823c Fix T54966: mathutils.noise.voronoi Memory leak
C code was not correctly handling release of temp data, not technically
a memory leak, but indeed rather annoying bug! ;)
2018-05-07 11:07:11 +02:00
Brecht Van Lommel 9bd2e9104a Nodes: show node labels (like image name) in material properties node view. 2018-05-06 19:28:23 +02:00
Campbell Barton 046904e3fc Cleanup: split rotation_from_view
Add a function that takes only a quat, instead of the 3D view.

Allows for using non-view orientations.
2018-05-06 18:32:18 +02:00
Campbell Barton 84474b0171 Object Snap: add object & matrix to view ray cast
Some snap functions already exposed this.
2018-05-06 15:56:09 +02:00
Campbell Barton 632f2b5c18 WM: include macros in last-properties
Needed for 2.8 tool system storage of macro properties.
2018-05-06 08:57:53 +02:00
Campbell Barton 9e3bfd9210 IDProp API: use stored string length for IDP_repr
Also NULL check ID pointers.
2018-05-06 08:57:19 +02:00
Campbell Barton d3b3df0371 IDProp API: add native C repr function
Was using Python which wasn't very efficient (even for logging).
2018-05-05 14:41:25 +02:00
Campbell Barton d83681807e PyAPI: add pop method to RNA struct types
This fits in with existing dict style access.
2018-05-05 09:53:30 +02:00
Campbell Barton d2591e5c2d IDProp Py API: Add default argument to pop
Match dict.pop behavior.
2018-05-05 09:48:06 +02:00
Campbell Barton 86c2c4d513 IDProp API: Avoid redundant group replace lookup 2018-05-05 09:31:17 +02:00
Germano b27b4743a2 BKE: bvhuils: remove member `sphere_radius`.
This member currently doubles the value of `ray->radius` or is not even used.
2018-05-04 11:57:01 -03:00
Germano 02788a9d1a Fix erroe in previous commit. 2018-05-04 11:22:50 -03:00
Germano e78ef82827 BKE: bvhutils: Unifies static functions oh bvhtrees creation. 2018-05-04 11:15:21 -03:00
Sergey Sharybin aa0380a6a5 Cleanup: Remove G.main from framechange_poses_clear_unkeyed() 2018-05-04 15:18:47 +02:00
Germano 78fde19e68 BKE: Smoke: Fix error with implicit declaration of function due recent changes. 2018-05-04 10:11:30 -03:00
Germano aea637456e BKE: BVHtree: Replace all external references of `bvhtree_from_mesh_looptri` with `bvhtree_from_mesh_get`. 2018-05-04 09:21:42 -03:00
Germano 3dd6912fce Mesh Remap: Face Corner Data: Do not use large epsilon values to create bvhtrees.
Use ray radius instead.
2018-05-04 09:01:56 -03:00
Germano 8c6a1d8f95 Mesh Remap: Face Data: Do not use large epsilon values to create bvhtree.
If you need the approximation, use raycast radius.
2018-05-04 08:29:00 -03:00
Sergey Sharybin fa11dc6730 Depsgraph: Fix extra operations and relations created for shared armatures 2018-05-04 12:49:48 +02:00
Germano b886cdf81d Mesh Remap: Change the sphere_radius parameter instead of creating a bvhtree with epsilon equal to the value of ray_radius.
This is the desirable behavior.
It also removes one more use of `bvhtree_from_mesh_looptri`.
2018-05-04 07:43:08 -03:00
Germano 3d26cf112b Constraint: Shrink Warp: Replace `bvhtree_from_mesh_looptri` with` bvhtree_from_mesh_get`.
The value of epsilon was never used to create this bvhtree because whenever we activate this constraint, a bvhtree with parameter epsilon 0.0 was created and cached.
2018-05-04 07:39:07 -03:00
Germano 82d59c6588 Mesh Lapacian: Use `isect_ray_tri_watertight_v3` instead of Epsilons to prevent corners errors in raycast.
Using FLT_EPSILON can fail with large coordinate values.
This commit also avoids storing bvhtrees with different settings in BVHCache.
2018-05-04 07:33:26 -03:00
Sergey Sharybin d1be30f779 Fix T54935: Particle group instances don't render when hidden in viewport
Seems to be only related on linked nature of particles.

This is caused by some conflicting optimization done for viewport, which
does not do particles re-calculation if they do not depend on time
(which is crucial for big layout scene grass fields) and particle render
setting  switch which was relying on fact that render pipeline will do
particle update via time dependency.

Now we extent an old workaround for invisible objects, which now also
deals with particles in the same way as old dependency graph was dealing
with this: tag object data for update if there is particle system.

There shouldn't be any speed difference between old and new depsgraph,
since tagging was already needed and was happening.

In Blender 2.8 such things should be easier to deal with since the whole
depsgraph is to be evaluated for render engine anyway.
2018-05-04 11:40:27 +02:00
Philipp Oeser 288d7794d4 Fix T54341: Particle Instance Modifier doesn't preserve edge data 2018-05-04 09:20:57 +02:00
Campbell Barton 75b310f489 Fix wireframe modifier w/ even offset
Was passing non-normalized axis to angle_on_axis.
2018-05-04 08:38:01 +02:00
Campbell Barton f3c5b0394f IDProp API: expose repr utility function
Useful for logging properties passed to operators.
2018-05-04 07:29:05 +02:00
Germano 16253285ff BKE: BVHtree: make `bvhtree_from_mesh_edges` a static function.
This will help us have more control over bvhtrees that are cached.
2018-05-03 18:33:16 -03:00
Germano 133dadcdee Fix `Transfer Mesh Data` with `Edge Mapping` of type `Projected Edge Interpolated` and `Ray Radius` other than 0.0.
`MREMAP_RAYCAST_APPROXIMATE_BVHEPSILON(ray_radius)` greatly increased the radius making for example that 0.1 becoming 1.5
Now the result is much more predictable.
2018-05-03 18:19:36 -03:00
Germano 7915cc7ddb Particle Edit: Shape Cut: Create and use bvhtree with AABB hull.
This bvhtree is only used for raycast. Currently the raycast does not benefit from general hull.
2018-05-03 15:52:09 -03:00
Germano 98ecdc4896 Dynamic Paint: Create and use bvhtree with AABB hull.
This bvhtree is only used for raycast and find_nearest which currently do not benefit from general hull.
2018-05-03 15:50:48 -03:00
Campbell Barton 0f217de403 Fix T54927: BMesh Py error w/ select history slice 2018-05-03 20:23:32 +02:00
Campbell Barton 38b6f8e143 Cleanup: correct solidify logic
Code for side normals isn't executing at the moment,
so not essential, but better correct it.
2018-05-03 19:48:28 +02:00
Campbell Barton 5e225ddb21 Cleanup: parentheses warning 2018-05-03 19:37:20 +02:00
Germano ac19483e63 BKE bvhtree: Add `tree_type` parameter to `bvhtree_from_mesh_get`.
This will allow greater control of the bvhtrees that are obtained, and helps identify problems.
It is also an additional step to unify the functions.
2018-05-03 14:26:39 -03:00
Bastien Montagne a5d0597b92 Fix tooltip for constraints' subtarget.
Thanks @aligorith for the head-up.
2018-05-03 16:00:34 +02:00
Bastien Montagne 53c43259ad Cleanup: factorize RNA constraint targets definition.
No expected changes in behavior from that commit!
2018-05-03 15:00:12 +02:00
Campbell Barton 0d6ddd0a1d Cleanup: split out extrude spin/screw
Since these will have their own manipulators,
its more convenient to keep them separate.
2018-05-03 08:20:29 +02:00
Germano 522bee3fc8 Refactoring: bvhutils: Use a function that gets the bvhtree through an identifier type.
Reviewed By: @campbellbarton
Differential Revision: https://developer.blender.org/D3192
2018-05-01 10:03:28 -03:00
Lukas Stockner 2e98524b58 Add support for area lights to the Apply Transform operator
Since area lights are affected by scaling them, it only makes sense to support applying the scale to the lamp size.
Of course, applying location or rotation does not work.

If a scaling that changes the aspect ratio is applied to a square lamp, the mode is automatically changed to Rectangle.
2018-04-30 22:09:23 +02:00
Dalai Felinto 32c4158047 Fix Merge > To Cursor
In master this is working fine, but in 2.8 ob->imat was identity matrix.
Committing this in master to simplify merging.
2018-04-30 21:42:16 +02:00
Campbell Barton 188c4a22c9 Cleanup: de-duplicate paint access from object 2018-04-30 18:58:43 +02:00
Julian Eisel e76a65e359 UV editing: Make 'Select Linked' work consistent to 3D View
Don't see a good reason for the old behavior, so better have it consistent.
2018-04-30 15:42:29 +02:00
Aaron Carlisle 128506eeb1 BLI Color: YUV to/from rgb colorspace option
This commit does two things:

- Adds an option to do the calculation in different color spaces (BT601
or BT709).
- Changes the default caluclation from legacy BT601 to BT709.

This affects several areas:

- UI areas (mainly scopes)
- ViewLevelsNode
- Several other nodes that use `COM_ConvertOperation.h`
2018-04-29 18:00:45 -04:00
Campbell Barton 60f4cb24da Fix vertex paint alpha brush setting color black 2018-04-28 14:47:53 +02:00
Campbell Barton ffda096413 Cleanup: meaningful names for color blending 2018-04-28 14:45:10 +02:00
Campbell Barton 57405054b2 Fix T54836: Select sharp edges doesn't flush to faces 2018-04-26 14:32:35 +02:00
Julian Eisel 3c7500ca71 Cleanup: Use enums for View2D value defines
Makes the file much less cluttered and more structured.
Also made some whitespace tweaks.
2018-04-26 14:07:03 +02:00
Campbell Barton f69feb4957 UI: optionally pass icon size to widget_draw_icon
No functional changes.
2018-04-25 17:26:45 +02:00
Sergey Sharybin 89bcc80c25 Library: Add assert to catch unsupported copy flags combination
Thanks Bastien for review!
2018-04-25 16:59:35 +02:00
Sergey Sharybin 331e97bcf3 Depsgraph: Fix missing relations in array modifier
Found by Dr. Sybren while working on modifiers port.
2018-04-25 16:34:01 +02:00
Campbell Barton 13b6867d1f CDDM: correct (disabled) logic in merge verts 2018-04-25 14:53:44 +02:00
Campbell Barton 53dc251fd3 Remove developer exception hack
This caused too much trouble, also it's possible users run with
'release' in their CWD causing issues.

Developers can symlink "release/" to "bin/2.79".
2018-04-25 12:54:27 +02:00
Campbell Barton d7d20b483a Revert "Fix (unreported) broken 'get system path' in some cases."
This reverts commit f1bc0aedde.
2018-04-25 12:48:51 +02:00
Campbell Barton 9a7f963a02 Cleanup: comments 2018-04-25 12:25:47 +02:00
Bastien Montagne f1bc0aedde Fix (unreported) broken 'get system path' in some cases.
There were two issues here actually:
* The hack to allow running Blender directly from the source directory
would just check for a 'release' directory, without actually ensuring it
is release dir from blender source tree, and not some other random
folder.
* GHOST_getSystemDir returns nothing for portable installations, now
we'll then check directly in the blender binary dir in that case.

This fix is more critical in 2.8 branch, where that system path is used
to retrieve new '3D' icons...
2018-04-25 10:37:36 +02:00
Germano bb92d9a946 BLI BVHTree Walk DFS: Decreases the size of the stack space used for the recursive function.
Each parameter of the function is copied into the memory stack.
This also brought an improvement in peformance of snapping functions between 5% and 12% in my tests.
2018-04-24 09:48:14 -03:00
Campbell Barton 92f36586e3 BLI_math: avoid assert with non-finite numbers 2018-04-23 21:09:01 +02:00
Sergey Sharybin 53d69e6d04 Depsgraph: Add relation flag to avoid flush across it
This way we can avoid re-evaluation of certain parts of datablock
when something unrelated has changed.
2018-04-23 16:42:37 +02:00
Sergey Sharybin 0ca7a78f20 Depsgraph: Fix missing update with animated curve path 2018-04-23 14:53:54 +02:00
Sergey Sharybin 41cf2d9042 Depsgraph: Cleanup, remove unused relation tag 2018-04-23 14:34:56 +02:00
Campbell Barton b14979f91f Cleanup: style 2018-04-23 12:53:45 +02:00
Joshua Leung 8264b772f5 Fix T54766: "Record With"-NLA "Push Down" discards Blend Mode, Extrapolation, and Influence
Applied similar fix to T54233 to get the "Record with NLA" feature working with
active action blending + influence settings. Extrapolation is explicitly ignored
though, as it shouldn't be used with this feature (i.e. it is already disabled
with the new strips and also on the animdata by default)
2018-04-23 12:35:37 +02:00
Sergey Sharybin fa7e19bca4 Depsgraph: Add missing relations builder
Was possible to miss some relations from being built
when parent object is linked to the scene graph indirectly.
2018-04-23 09:33:33 +02:00
Campbell Barton 89ab591345 Cleanup: UI naming 2018-04-22 19:22:10 +02:00
Campbell Barton 420e379e99 Cleanup: de-dup popup/pie menu RNA definition
Also rename pupmenu -> popmenu
2018-04-22 10:49:45 +02:00
Campbell Barton 46a9038f60 Cleanup: variable naming 2018-04-21 20:22:12 +02:00
Campbell Barton 1e9fb355bf BLI_bitmap: 2D triangle drawing function
Matching polygon filling but no need for allocation or qsort.
2018-04-21 18:34:34 +02:00
Campbell Barton 83cb387944 BLI math: clamped barycentric weight calculation 2018-04-21 18:34:20 +02:00
Gaia Clary e5bb234f64 Cleanup (followup commit for D3160)
Added some spaces to keep the eInsertKeyFlags enumeration proper
2018-04-20 15:09:56 +02:00
Gaia Clary ff839fb6c1 Fix: D3160 Propose to use proper typedefs to avoid confusion
Differential Revision: https://developer.blender.org/D3160
2018-04-20 15:02:11 +02:00
Bastien Montagne ac8f6413cc Fix usage of lib filepath in previous own commit... 2018-04-20 11:00:12 +02:00
Bastien Montagne 88bbb68ad0 Add debug tool to check validity of current file *before* saving.
It is hidden behind the --debug-io flag for now.

Idea is to try to catch broken libraries state in current Main before we
actually write the file on disk, should help catching and understanding
what happens in Spring corruption cases.
2018-04-20 10:46:59 +02:00
Aaron Carlisle dda7e3b695 VSE Effects: Wipe box: fix compilation errors
This is still broken I cant tell if it is the fact that the in_band
funtion does not work properally or an issue in the box algorithm, or
both.

It seems like the calculation of the size of the box while roatated
needs to be fixed also.
2018-04-19 18:44:56 -04:00
Campbell Barton e2678d6b7b Cleanup: make variable name English 2018-04-19 18:10:51 +02:00
Campbell Barton 307492c2db Cleanup: rename vlak -> poly 2018-04-19 18:08:55 +02:00
Campbell Barton da82269c58 Cleanup: rename Icon.type -> id_type
Confusing when adding non-id icons.
2018-04-19 12:52:32 +02:00
Sergey Sharybin 63225d7c8b Port particle instance modifier changes from Gooseberry branch
The work is mainly from Lukas Toenne, with some modifications from myself.

Includes following obvious changes:

- Particle system selection is now name-based, with lookup menu.
- Lots of new options to control varieties.

Changes comparing to the Gooseberry branch:

- Default values and versioning code ensures same behavior as the
  old modifier.

- Custom data layers are coming from vertex color, the modifier
  does not create arbitrary layers now. The hope is to keep data
  more manageable, and maybe make it easier to select in the shader
  later on.

  This means, values are quantized to 256 values, but it should be
  enough to get varieties in practice.

Reviewers: brecht, campbellbarton

Reviewed By: brecht

Subscribers: eyecandy

Differential Revision: https://developer.blender.org/D3157
2018-04-19 10:51:18 +02:00
Campbell Barton fcac9e8410 Cleanup: style 2018-04-19 08:18:16 +02:00
Campbell Barton 9f7f6d5540 Undo: add missing flag for text delete 2018-04-19 08:16:37 +02:00
Sergey Sharybin f28aec17e9 Depsgraph: Fix missinf relation for particle instance modifier
Was causing lack of animation update when particle system had simulation,
2018-04-18 13:54:02 +02:00
Sergey Sharybin 3811998177 Cleanup: Trailing whitespace 2018-04-18 12:31:26 +02:00
Sybren A. Stüvel 287d1924fa Remove irrelevant print statement
This statement is only relevant in 2.8, but causes confusion in master.
I kept the 'default' label to prevent compiler warnings about unhandled
cases. The break is needed because there should be at least one statement
after 'default'.
2018-04-18 12:26:40 +02:00
Sergey Sharybin 0afe103269 Particles: Interpolate size for interpolated children
This finally allows us to use Random factor to add variations to the
interpolated children. This feature never worked since 2007L there was
random factor slider in the interface, but it was only used by simple
children. Now it has affect on interpolated children as well.

Technically, this will break compatibility if older file had random
factor set to something else than 0 (default value is 0 though). But
we are leaving 2.7 series, so can accept such breackage in the name
of supported features.
2018-04-18 10:52:27 +02:00
Julian Eisel bc9e05599d Fix makesdna not respecting C++ comments
Tab after C++ comment broke parsing and didn't remove the line at all.
Was there since 2002 at least, probably confused some peeps.

This means commented out code was actually written to SDNA.
2018-04-18 00:29:53 +02:00
Dalai Felinto a0ef147f29 bpy consistency fix handler_add(handle)
This doesn't change the API, so it doesn't affect any script.
However it give more consistent error messages.
2018-04-17 12:29:40 +02:00
Bastien Montagne aff71a7fdc Fix (unreported) RNA sometimes trying to get named sub-props from non-Group IDProp.
Why exactly this happens remains unclear, found that in the
autumn.blenrig file of Spring production while working on static
overrides... Tons of ugly IDProps in that rig. xD
2018-04-17 11:59:14 +02:00
Campbell Barton eb6fe5fa94 Cleanup: indentation 2018-04-16 18:13:48 +02:00
Campbell Barton 95eb9f22e6 Cleanup: indentation 2018-04-16 17:16:29 +02:00
Campbell Barton 85de548e03 Cleanup: indentation 2018-04-16 17:08:27 +02:00
Campbell Barton 141f0f4c47 BKE_context: macro to access ID's while looping 2018-04-16 16:19:16 +02:00
Sergey Sharybin 047950db7c Depsgraph: Pull indirect relations via driver targets 2018-04-16 16:12:15 +02:00
Sergey Sharybin 6617818c7a Make ID icons safe for deletion from threads
Added a lock-free deferred queue for deletion. Now if ID icon
is requested to be freed from non-main thread, it will be added
to the deferred list. Actual deletion will happen later from main
thread.

Currently actual deletion only happens next time BKE_icon_id_delete()
is called, which might not be enough. But it's easy to enforce
deferred deletion.

Icons for preview images are not covered by deferred deletion yet.

Reviewers: mont29

Differential Revision: https://developer.blender.org/D3146
2018-04-16 10:18:43 +02:00
Sergey Sharybin 5bfe6126f8 Added lock-free single linked list implementation
Only supports lock-free insertion for now, can not delete element
or traverse the list at the same time.
2018-04-16 10:18:43 +02:00
Campbell Barton 80f7249d09 Cleanup: skip redundant edit-bone select lookups 2018-04-15 21:46:25 +02:00
Campbell Barton 7bccd21afa Cleanup: remove redundant args from ebone picking
Make this match editmesh picking more closely
2018-04-15 12:45:39 +02:00
Campbell Barton 0f2efce6c5 Cleanup: remove bad casts 2018-04-15 11:57:49 +02:00
Campbell Barton c12d976020 Cleanup: ED_armature naming
- Wasn't clear which functions handle edit-bones.
- Mixed both ebone and edit_bone in names.
- Didn't use ED_armature_* prefix for public API.

See P655 to apply to branches.
2018-04-15 11:50:53 +02:00
Campbell Barton d0e3fbc06b Cleanup: remove undoing access, minor formatting
Access to undoing state isn't needed,
some text insert code was overly compacted.
2018-04-15 10:48:50 +02:00
Campbell Barton fb3528d088 Fix T54593: Py text edits crash (undo regression) 2018-04-15 10:34:41 +02:00
Aaron Carlisle 2666e77c22 Fix T54527: Misleading Tooltip on Snap Target Menu 2018-04-14 18:26:27 -04:00
Campbell Barton 3a10f8e1b1 Cleanup: style 2018-04-14 22:26:12 +02:00