Campbell Barton
62fbb7d4a1
Empty Object: Center images by default
2018-07-06 10:05:37 +02:00
Campbell Barton
d56b90705e
BKE_addons: utility to remove by name
2018-07-06 07:55:29 +02:00
Campbell Barton
b88e51dd55
Cleanup: use bool for poll functions
2018-07-02 11:51:31 +02:00
Campbell Barton
ddee0931b8
RNA: use bool for boolean RNA types
...
We were using int's for bool arguments in BKE,
just to avoid having wrapper functions.
2018-07-01 15:57:59 +02:00
Campbell Barton
b372766816
Cleanup: trailing newlines
2018-06-29 09:23:51 +02:00
Campbell Barton
b633d760a2
Cleanup: style
2018-06-27 22:32:52 +02:00
Sergey Sharybin
6cd0484de8
CMake: Make language explicit for per-file strict flags removal
2018-06-22 14:40:00 +02:00
Bastien Montagne
101fd7ec06
Tweak new BKE_id_is_in_global_main to accept NULL pointer (and consider them as valid).
2018-06-22 12:26:45 +02:00
Bastien Montagne
1870a1adc7
BKE_library: Add func to check an ID is actually in G_MAIN database.
2018-06-22 11:37:08 +02:00
Bastien Montagne
fd48e685c3
Cleanup: remove some G.main from BKE's node.c
...
Validate some cases using G_MAIN instead (I don't think we want to work
on any other Main than G.main one when registering/unregistering nodes
etc.).
And when freeing, all ID not in Main shall now be tagged accordingly, so
we *should* not need to do that stupi search over all ntrees in G.main
to check wether we have to free it ourself or not!
2018-06-20 12:27:26 +02:00
Campbell Barton
d4519f54b3
UI: only show "Edit Translations" when addon used
2018-06-20 10:45:03 +02:00
Campbell Barton
6fc8a74886
Cleanup: trailing space for blenkernel
2018-06-17 17:05:51 +02:00
Campbell Barton
a0a1fc8938
Cleanup: BLI path extension API
...
Use BLI_path_extension_* prefix.
2018-06-17 16:13:24 +02:00
Bastien Montagne
ace8ad861d
Fix T55427: Removing Vertex Group used by Data Transfer Modifier results in crash.
...
Only fixing crash, proper handling (a.k.a remapping) of all
possible cases here, for all possible data layers, is rather involved...
2018-06-16 16:22:00 +02:00
Lukas Stockner
799779d432
Cycles: change Ambient Occlusion shader to output colors.
...
This means the shader can now be used for procedural texturing. New
settings on the node are Samples, Inside, Local Only and Distance.
Original patch by Lukas with further changes by Brecht.
Differential Revision: https://developer.blender.org/D3479
2018-06-15 22:16:06 +02:00
Bastien Montagne
da9b1b14ed
Cleanup: some more G.main removal/validation...
2018-06-15 17:21:07 +02:00
Campbell Barton
cbc7ee28d7
WM: 2.8 screen compatibility
...
Without these minor changes loading files from 2.8 will crash.
Manually applied edits from 26786a2b87
2018-06-15 10:24:53 +02:00
Brecht Van Lommel
3102833962
Fix undo of transform after frame change undoing too much.
...
For grouped undo we should not skip the undo push, rather replace the
previous undo push. This way undo goes back to the state after the last
operation in the group.
2018-06-13 18:39:30 +02:00
Bastien Montagne
f61c30f804
Cleanup: get rid of last G.main in BMesh code.
2018-06-13 16:29:12 +02:00
Bastien Montagne
5ff1d845ea
Cleanup: moar ugly G.main removal...
...
Note that due to RNA get/setters issue, that one may actually add some
G.main usages to the total... But at least it's not hidden anymore in a
very low-level, dark corner of BKE pointcache code!
2018-06-13 14:28:05 +02:00
Bastien Montagne
67e8c1e1c7
Cleanup: remove more G.main from BKE area.
2018-06-13 10:57:10 +02:00
Bastien Montagne
2788202417
Cleanup: moar G.main removal from BKE area.
2018-06-12 17:57:24 +02:00
Bastien Montagne
f27ecd56ef
Cleanup: BKE_scene_free should not have to worry about cleaning its usages.
...
This is supposed to be handled by calling code! Henceforce, no need to
call BKE_sequencer_clear_scene_in_allseqs() here, and... no need for
that ugly G.main case. ;)
2018-06-12 17:46:16 +02:00
Campbell Barton
b00d840359
WM: remove sloppy region type access
...
Avoid accidentally operating on the wrong region type.
2018-06-12 17:34:44 +02:00
Campbell Barton
760e79d809
WM: rename BKE_regiontype_from_id
...
This returns the first as a fallback, causing confusing usage.
Renamed and added a version of the function that doesn't.
2018-06-12 17:26:38 +02:00
Bastien Montagne
a6585fa4b1
Cleanup: moar removal of G.main in BKE area...
2018-06-12 15:16:45 +02:00
Bastien Montagne
d617a6c85b
Cleanup/simplify G.main usages.
...
Using G.main only to get main bled filepath, or built-in fonts, is OK.
So now using the 'valid' G_MAIN macro here instead.
2018-06-12 15:03:51 +02:00
Bastien Montagne
be57cf9b2a
Cleanup: remove moar G.main from BKE area.
2018-06-12 12:53:27 +02:00
Bastien Montagne
5508b572ea
Cleanup: remove some G.main from ED's animsys.
...
The easy ones - there some much, much trickier to tackle there...
2018-06-12 12:28:14 +02:00
Bastien Montagne
75bcb70c60
Cleanup: remove some G.main from BKE area.
2018-06-12 11:21:54 +02:00
Bastien Montagne
78a8d3685b
Cleanup: remove moar ugly G.main usages...
...
BKE_image was an ugly nest, could fix all but the ones from compositor,
so moved ugly G.main there, at least we know where the Evil is that way ;)
2018-06-11 15:40:37 +02:00
Bastien Montagne
d0956e9cb3
Cleanup: Moar G.main removal of Hell.
...
This commit actually adds some G.main... but at much, much higher level
than the ones it removes, so should still be better ;)
2018-06-11 12:15:14 +02:00
Bastien Montagne
8055ed2741
Cleanup: remove some G.main usages...
2018-06-11 12:15:14 +02:00
Sergey Sharybin
28c34ae7e2
Cleanup: Use BLI_strncpy
...
It has behavior which we expect, and silences strict compiler warning.
2018-06-11 11:06:15 +02:00
Campbell Barton
83cb34ccd1
Cleanup: unused functions
2018-06-09 18:47:39 +02:00
Bastien Montagne
638de72277
Cleanup: remove some G.main usages.
2018-06-09 15:17:04 +02:00
Bastien Montagne
7b6af843c2
Cleanup: getting rid of G.main.
...
Sometimes one needs a *lot* of changes for a single G.main... :/
2018-06-08 12:17:22 +02:00
Bastien Montagne
80dcb2ced8
Cleanup: typo, and 0 -> false for booleans.
2018-06-07 18:36:16 +02:00
Campbell Barton
5330f1c5d1
Fix sculpt assert on initialization
2018-06-07 13:39:49 +02:00
Campbell Barton
bfbd85e9d6
Fix error using freed bmain
...
Regression in 481cdb08ed
2018-06-06 09:36:50 +02:00
Bastien Montagne
481cdb08ed
Cleanup: use new accessors to blendfile path (Main.name).
2018-06-05 16:33:46 +02:00
Bastien Montagne
1d97e948d2
Cleanup: add hleper functions to get filepath from Main.
...
This helps making things clearer and cleaner. Func returning filepath of
G.main is separate, so that we can easily track its usages, and
hopefully deprecate it at some point. Though that usage of G.main is
likely the less evil one, you nearly always want current blendfile path
in those cases anyway.
2018-06-05 16:33:46 +02:00
Campbell Barton
747534af00
Particle System: move data creation into RNA update
...
Relying on evaluation to initialize data causes issues w/ 2.8.
2018-06-04 17:55:19 +02:00
Campbell Barton
38eb91c848
Cleanup: correct variable name, doxy sections
2018-06-03 17:06:13 +02:00
Campbell Barton
335b193336
Cleanup: add argument names to screen callbacks
2018-06-03 15:11:31 +02:00
Dalai Felinto
fec317de8d
--debug-gpu-shader: Dump GLSL shaders to disk
...
This is really convenient for development. Either for profiling the
generated shaders or to check if the generated code is correct.
It writes the shaders to the temporary blender session folder.
(ported over from blender2.8)
2018-06-02 20:29:27 +02:00
Campbell Barton
c140f11946
Cleanup: warning
2018-06-02 11:58:01 +02:00
Campbell Barton
75fc1c3507
Cleanup: trailing whitespace (comment blocks)
...
Strip unindented comment blocks - mainly headers to avoid conflicts.
2018-06-01 18:19:39 +02:00
Bastien Montagne
da11e33b26
Cleanup: remove G.main from BKE mball code.
2018-05-31 16:44:05 +02:00
Bastien Montagne
16100f8261
Cleanup: get rid of last G.main usages in BKE library code.
2018-05-31 16:04:04 +02:00