Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2018-11-07Cleanup/Refactor: move Main stuff into BKE's new main.c file (and header).Bastien Montagne
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-06BLI_kdopbvh: add an option to use a priority queue in find_nearest.Alexander Gavrilov
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-06Proper fix for new 'SimpleHeap' gtests...Bastien Montagne
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-06Revert rBfee6ab18e7e9 in BLI_heap_test.ccBastien Montagne
Most certainly commite by mistake, FastHeap is not in BLI yet!
2018-11-05BLI_heap: implement a limited but faster version of heap.Alexander Gavrilov
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-04BLI_heap: add an API function to directly read the top node value.Alexander Gavrilov
It is very commonly needed in loop conditions to check if the items in the heap are good enough to continue.
2018-09-19Merge branch 'master' into blender2.8Campbell Barton
2018-09-19BLI_utildefines: rename pointer conversion macrosCampbell Barton
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-19Cleanup: BLI_expr_pylike argument orderingCampbell Barton
- Order array length after the array. - Put return argument last.
2018-09-19Cleanup: rename BLI_simple_expr -> BLI_expr_pylike_evalCampbell Barton
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-18Support evaluating simple driver expressions without Python interpreter.Alexander Gavrilov
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-04Cleanup: overly polite/rude messagesCampbell Barton
2018-06-29Merge branch 'master' into blender2.8Campbell Barton
2018-06-29Cleanup: trailing newlinesCampbell Barton
2018-06-08Alembic unit tests: fixed compiler errorsSybren A. Stüvel
This doesn't mean the code is correct, but at least it builds.
2018-06-04Merge branch 'master' into blender2.8Campbell Barton
2018-06-04Cleanup: strip tests trailing spaceCampbell Barton
2018-05-27Merge branch 'master' into blender2.8Campbell Barton
2018-05-25Add number and memory size formatting throughout the UIDiego Gangl
This commit adds number formatting (thousands separator) to the baking panel. It also adds a new function to format memory sizes (KB/GB/etc) and applies it to the baking panel and scene stats. The new function is unit tested. Reviewers: Severin Tags: #user_interface Differential Revision: https://developer.blender.org/D1248
2018-05-02Merge branch 'master' into blender2.8Campbell Barton
2018-04-30Fix build of Alembic test.Brecht Van Lommel
2018-04-30BLI Color: YUV to/from rgb colorspace optionAaron Carlisle
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-16Depsgraph: remove EvaluationContext, pass Depsgraph instead.Brecht Van Lommel
The depsgraph was always created within a fixed evaluation context. Passing both risks the depsgraph and evaluation context not matching, and it complicates the Python API where we'd have to expose both which is not so easy to understand. This also removes the global evaluation context in main, which assumed there to be a single active scene and view layer. Differential Revision: https://developer.blender.org/D3152
2018-04-16Fix build errors after recent depsgraph changes.Brecht Van Lommel
2018-04-16Merge branch 'master' into blender2.8Sergey Sharybin
2018-04-16Added lock-free single linked list implementationSergey Sharybin
Only supports lock-free insertion for now, can not delete element or traverse the list at the same time.
2018-02-18Merge branch 'master' into blender2.8Campbell Barton
2018-02-18Cleanup: add 2d suffix to BLI filesCampbell Barton
Some of these API's can have 3D versions, explicitly name them 2D.
2018-02-15Merge branch 'master' into blender2.8Sergey Sharybin
2018-02-15Cleanup: use '_len' instead of '_size' w/ BLI APICampbell Barton
- When returning the number of items in a collection use BLI_*_len() - Keep _size() for size in bytes. - Keep _count() for data structures that don't store length (hint this isn't a simple getter). See P611 to apply instead of manually resolving conflicts.
2018-02-14Merge branch 'master' into blender2.8Campbell Barton
2018-02-14Cleanup: use prefix for testsCampbell Barton
Allows for running all `bmesh_*` or `object_*` tests.
2018-01-19Merge branch 'master' into blender2.8Campbell Barton
2018-01-19Cleanup: typosCampbell Barton
2018-01-18Merge branch 'master' into blender2.8Brecht Van Lommel
2018-01-17Memory: add MEM_malloc_arrayN() function to protect against overflow.Brecht Van Lommel
Differential Revision: https://developer.blender.org/D3002
2017-11-23Merge branch 'master' into blender2.8Bastien Montagne
2017-11-23Add a new parallel looper for MemPool items to BLI_task.Bastien Montagne
It merely uses the new thread-safe iterators system of mempool, quite straight forward. Note that to avoid possible confusion with two void pointers as parameters of the callback, a dummy opaque struct pointer is used instead for the second parameter (pointer generated by iteration over mempool), callback functions must explicitely convert it to expected real type. Also added a basic gtest for this new feature.
2017-11-23Rename any instance of scene layer or render layer in code with view layerDalai Felinto
The RenderResult struct still has a listbase of RenderLayer, but that's ok since this is strictly for rendering. * Subversion bump (to 2.80.2) * DNA low level doversion (renames) - only for .blend created since 2.80 started Note: We can't use DNA_struct_elem_find or get file version in init_structDNA, so we are manually iterating over the array of the SDNA elements instead. Note 2: This doversion change with renames can be reverted in a few months. But so far it's required for 2.8 files created between October 2016 and now. Reviewers: campbellbarton, sergey Differential Revision: https://developer.blender.org/D2927
2017-11-09Depsgraph: Make dependency graph to be built from scene layerSergey Sharybin
This is a final step of having proper ownership. Now selecting different layers in the "top bar" will actually do what this is expected to do. Surely, there are still things to be done under the hood, that will happen in a less intrusive way.
2017-11-03Depsgraph: Use explicit depsgraph in alembic moduleSergey Sharybin
2017-11-02Merge branch 'master' into blender2.8Sybren A. Stüvel
# Conflicts: # tests/gtests/alembic/abc_export_test.cc
2017-11-02Alembic: not using global in unit test.Sybren A. Stüvel
Thanks @sergey for pointing out this fix.
2017-10-29Merge branch 'master' into blender2.8Sybren A. Stüvel
# Conflicts: # source/blender/alembic/intern/abc_exporter.cc # source/blender/alembic/intern/abc_exporter.h # source/blender/alembic/intern/alembic_capi.cc # tests/gtests/alembic/abc_export_test.cc
2017-10-29Alembic: exporting MetaBalls as meshSybren A. Stüvel
- Only basis balls are exported, as they represent the resulting mesh. As a result the mesh is written to Alembic using the name of the basis ball. - MetaBalls are converted to a mesh on every frame, then an AbcMeshWriter is used to write that mesh to Alembic.
2017-10-29Merge branch 'master' into blender2.8Sybren A. Stüvel
2017-10-29BLI_heap: add validation check, improve testsCampbell Barton
Also minor readability changes, avoid running both heap_up/down gives minor speedup too.
2017-10-29BLI_heap: minor changes to the APICampbell Barton
Recent addition of 'reinsert' didn't match logic for ghash API. Rename to BLI_heap_node_value_update, also add BLI_heap_insert_or_update since it's a common operation.
2017-10-28BLI_hash: add BLI_heap_reinsertCampbell Barton
Allows avoiding remove/insert calls.
2017-10-28GTest: initial BLI_heap testCampbell Barton