Commit Graph

457 Commits

Author SHA1 Message Date
Howard Trickey
0af22625c9 Fix bl_pyapi_idprop unit test.
Scenes can now have a 'cycles' key when starting, so account for that.
2019-03-17 07:36:26 -04:00
Campbell Barton
69bf4e5e36 Cleanup: unused variables 2019-03-17 21:14:43 +11:00
Campbell Barton
ad9addbf46 Cleanup: unused imports 2019-03-17 21:00:56 +11:00
Ray Molenkamp
55e79d8f36 Tests: BLI_heap_simple test fix build error with MSVC.
BLI_heap_simple.h uses types from BLI_sys_types.h causing a build error on windows.
2019-03-14 11:14:44 -06:00
9a9336cb45 Merge branch 'blender2.7' 2019-02-20 19:07:25 +01:00
848f589fdf Tests: only run OpenGL draw tests on lib/tests/opengl, support symlinks.
To keep running these tests relatively fast and practical to run often,
running it on all .blend files is a bit much. So now we only run it on
files from this directory.

Additionally this adds supports for following symlinks, so that you can
easily symlinks to other directories if you want to tests extra files
which may have linked libraries.
2019-02-20 17:13:33 +01:00
d8888b2f48 Merge branch 'blender2.7' 2019-02-11 18:39:31 +01:00
2a9c8da709 Cycles: add animation denoising test, fix operator to work with single frames. 2019-02-11 18:37:02 +01:00
Campbell Barton
ab5e69e660 Cleanup: remove contributors for CMake files
Following removal from C source code.

See: 8c68ed6df16d8893
2019-02-05 09:10:32 +11:00
Campbell Barton
744f633986 Cleanup: trailing commas
Needed for clan-format not to wrap onto one line.
2019-02-03 14:59:11 +11:00
Campbell Barton
d70350403f Cleanup: manually remove header text not handled by automation 2019-02-02 02:41:25 +11:00
Campbell Barton
6cbb4c576a Cleanup: manually remove header text not handled by automation 2019-02-02 01:49:31 +11:00
Sergey Sharybin
9770d071ff Fix T54834: VSE can't import OGG Theora video 2019-01-23 17:16:17 +01:00
Bastien Montagne
6d89337257 Fix/cleanup typos and such in UI messages (and some comments). 2018-12-24 15:03:49 +01:00
Bastien Montagne
1ac311cedc Fix/cleanup another bunch of UI messages issues.
Also (mostly in comments): behaviour -> behavior (we use American English).
2018-12-24 12:32:43 +01:00
Campbell Barton
63fcbfc3a7 RNA: naming, user-preferences -> preferences 2018-12-21 12:55:02 +11:00
Jacques Lucke
aa63a87d37 BLI: New Edgehash and EdgeSet implementation
The new data structure uses open addressing instead of chaining to resolve collisions in the hash table.

This new structure was never slower than the old implementation in my tests. Code that first inserts all edges and then iterates through all edges (e.g. to remove duplicates) benefits the most, because the `EdgeHashIterator` becomes a simple for loop over a continuous array.

Reviewer: campbellbarton

Differential Revision: D4050
2018-12-13 11:21:31 +01:00
Bastien Montagne
394b086b9c Fix T58556: Some remaining 'dupli_types' in pycode after renaming. 2018-12-03 10:39:54 +01:00
Bastien Montagne
278d9c8322 Merge branch 'master' into blender2.8
Conflicts:
	source/blenderplayer/CMakeLists.txt
	tests/gtests/blenlib/CMakeLists.txt
2018-11-28 16:52:47 +01:00
Bastien Montagne
c16321cb9d Fix building gtests and bplayer after recent NumaAPI addition.
Seriously... like, seriously...
2018-11-28 16:50:02 +01:00
Campbell Barton
cb66a28d82 Cleanup: unused vars, imports 2018-11-26 09:26:15 +11:00
Campbell Barton
916446e83f Cleanup: move keymap hierarchy into own file 2018-11-20 11:38:13 +11:00
Campbell Barton
c9f24a5690 WM: remove interaction presets
These only exposed a few options, which didn't end up helping
much to make Blender's key-map fit the behavior of other applications.
2018-11-20 08:11:46 +11:00
Campbell Barton
92263b67eb Update test, missed when changing Object.select_set() 2018-11-12 09:05:38 +11:00
Bastien Montagne
fd65ebf39a Fix T57776: Error when adding a Torus to the scene.
Not all Object.select_set() cases had been updated to new API... Tsst. ;)
2018-11-11 11:22:38 +01:00
Campbell Barton
f12d2adc87 RNA: Object.select_set use boolean, only select
- Was setting active state, making it necessary to backup/restore
  active object in cases where this isn't needed.
  Existing scripts are explicitly setting the active object when needed.

- Use a boolean select arg (toggle selection wasn't used anywhere).

- Add an optional view layer argument since scripts should be able to
  operate outside the user context.
2018-11-08 08:54:55 +11:00
Bastien Montagne
1ff8be24ef Cleanup/Refactor: move Main stuff into BKE's new main.c file (and header).
We already had a BKE_main.h header, no reason not to put there
Main-specific functions, BKE_library has already more than enough to
handle with IDs and library management!
2018-11-07 20:58:53 +01:00
Alexander Gavrilov
84fa806491 BLI_kdopbvh: add an option to use a priority queue in find_nearest.
Simple find_nearest relies on a heuristic for efficient culling of
the BVH tree, which involves a fast callback that always updates the
result, and the caller reusing the result of the previous find_nearest
to prime the process for the next vertex.

If the callback is slow and/or applies significant restrictions on
what kind of nodes can qualify for the result, the heuristic can't
work. Thus for such tasks it is necessary to order and prune nodes
before the callback at BVH tree level using a priority queue.

Since, according to code history, for simple find_nearest the
heuristic approach is faster, this mode has to be an option.
2018-11-06 21:20:16 +03:00
Bastien Montagne
aa9912ec04 Proper fix for new 'SimpleHeap' gtests...
This reverts reverting commit rB55324b8a2e6799300, and do proper 'cleanup' (sigh)
in gtest as well.

Sorry for the noise, did not understood what had happened here
immediately. :/
2018-11-06 16:25:00 +01:00
Bastien Montagne
55324b8a2e Revert rBfee6ab18e7e9 in BLI_heap_test.cc
Most certainly commite by mistake, FastHeap is not in BLI yet!
2018-11-06 16:06:53 +01:00
Alexander Gavrilov
fee6ab18e7 BLI_heap: implement a limited but faster version of heap.
If the user only needs insertion and removal from top, there is
no need to allocate and manage separate HeapNode objects: the
data can be stored directly in the main tree array.

This measured a 24% FPS increase on a ~50% heap-heavy workload.

Reviewers: brecht

Differential Revision: https://developer.blender.org/D3898
2018-11-05 20:49:17 +03:00
Alexander Gavrilov
d3c815bd08 BLI_heap: add an API function to directly read the top node value.
It is very commonly needed in loop conditions to check if
the items in the heap are good enough to continue.
2018-11-04 13:29:17 +03:00
Campbell Barton
733e6c0b1d Merge branch 'master' into blender2.8 2018-10-09 08:46:00 +11:00
Campbell Barton
3bc885e5f4 Cleanup: style 2018-10-09 07:58:06 +11:00
Lukas Stockner
9756475ed6 Tests: Support parallel execution of render tests
Previously, parallel tests would overwrite each others temporary outputs.
2018-10-06 22:12:28 +02:00
Campbell Barton
1c3411ac89 Keymap: expose tool keymaps in the preferences
Currently some modes share tool keymaps, we might want to disable
this since it's confusing editing one thing in multiple places.

However this should be resolved in the tool definitions.
2018-10-03 15:55:57 +10:00
Sergey Sharybin
d2d0b4fcd7 Merge branch 'master' into blender2.8 2018-09-28 15:03:03 +02:00
6dd047c333 Tests: recurse into directories for finding OpenGL draw test .blends. 2018-09-28 14:09:42 +02:00
Sergey Sharybin
4de1e673a4 Merge branch 'master' into blender2.8 2018-09-27 14:51:33 +02:00
2a63e062b0 Tests: add --no-window-focus to open window without focus.
This is useful to run OpenGL tests while continuing to do other tasks
without windows constantly popping up in the foreground.
2018-09-27 12:21:48 +02:00
6b433f4eb3 Merge branch 'master' into blender2.8 2018-09-19 18:20:50 +02:00
a4f2ebc78d Spelling fixes in comments and descriptions, patch by luzpaz.
Differential Revision: https://developer.blender.org/D3700
2018-09-19 18:18:05 +02:00
Campbell Barton
bb3ec3ebaf BLI_utildefines: rename pointer conversion macros
Terms get/set don't make much sense when casting values.

Name macros so the conversion is obvious,
use common prefix for easier completion.

- GET_INT_FROM_POINTER  -> POINTER_AS_INT
- SET_INT_IN_POINTER    -> POINTER_FROM_INT
- GET_UINT_FROM_POINTER -> POINTER_AS_UINT
- SET_UINT_IN_POINTER   -> POINTER_FROM_UINT
2018-09-19 12:12:21 +10:00
Campbell Barton
f35e9f047a Merge branch 'master' into blender2.8 2018-09-19 12:14:36 +10:00
Campbell Barton
d44c8ce1cb Cleanup: BLI_expr_pylike argument ordering
- Order array length after the array.
- Put return argument last.
2018-09-19 11:40:40 +10:00
Campbell Barton
3aea5695bb Cleanup: rename BLI_simple_expr -> BLI_expr_pylike_eval
Simple isn't a good prefix for library names since
lots of unrelated modules could be called 'simple'.

Include 'py' in module name since this is a subset of Python,
one of the main motivations for this is to be Python like/compatible.
2018-09-19 11:08:04 +10:00
Alexander Gavrilov
bf2a54b058 Support evaluating simple driver expressions without Python interpreter.
Recently @sergey found that hard-coding evaluation of certain very
common driver expressions without calling the Python interpreter
produces a 30-40% performance improvement. Since hard-coding is
obviously not suitable for production, I implemented a proper
parser and interpreter for simple arithmetic expressions in C.

The evaluator supports +, -, *, /, (), ==, !=, <, <=, >, >=,
and, or, not, ternary if; driver variables, frame, pi, True, False,
and a subset of standard math functions that seem most useful.

Booleans are represented as numbers, since within the supported
operation set it seems to be impossible to distinguish True/False
from 1.0/0.0. Boolean operations properly implement lazy evaluation
with jumps, and comparisons support chaining like 'a < b < c...'.

Expressions are parsed into a very simple stack machine program
that can then be safely evaluated in multiple threads.

Reviewers: sergey, campbellbarton

Differential Revision: https://developer.blender.org/D3698
2018-09-18 13:25:28 +03:00
e0a4dc6a79 UI / Python: rename X-Ray to In Front, Draw to Display.
See T56648.
2018-09-06 13:26:46 +02:00
Campbell Barton
3140304940 Cleanup: overly polite/rude messages 2018-09-04 18:45:17 +10:00
Andrew Hale
aa5a96430e Python: Add support for @ infix operator matrix multiplication
This differential revision implements the code for T56276

Reviewers: campbellbarton

Reviewed By: campbellbarton

Differential Revision: https://developer.blender.org/D3587
2018-08-10 15:18:00 +02:00