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
2021-08-31Cleanup: Added const keywork to GPU_viewport_colorspace_set.Jeroen Bakker
2021-08-26Cleanup: spelling in commentsCampbell Barton
2021-08-17Cleanup: clang tidyJacques Lucke
The parameter name was inconsistent between declaratation and implementation.
2021-08-17Cleanup: clang-formatCampbell Barton
2021-08-16XR: Color Depth AdjustmentsPeter Kim
This addresses reduced visibility of scenes (as displayed in the VR headset) that can result from the 8-bit color depth format currently used for XR swapchain images. By switching to a swapchain format with higher color depth (RGB10_A2, RGBA16, RGBA16F) for supported runtimes, visibility in VR should be noticeably improved. However, current limitations are lack of support for these higher color depth formats by some XR runtimes, especially for OpenGL. Also important to note that GPU_offscreen_create() now explicitly takes in the texture format (eGPUTextureFormat) instead of a "high_bitdepth" boolean. Reviewed By: Julian Eisel, Clément Foucault Differential Revision: http://developer.blender.org/D9842
2021-08-13Fix FTBFS on mips64el architectureMatteo F. Vescovi
While trying to get Blender 2.93.x LTS to build fine on all release architectures in Debian, I noticed that the misleading use of "mips" as integer variable caused problems when compiling on mips64el. The patch should fix the issue. Reviewed By: fclem Differential Revision: https://developer.blender.org/D12194
2021-08-11Fix T88033: Python reference memory leaks for non main data-blocksCampbell Barton
ID data-blocks that could be accessed from Python and weren't freed using BKE_id_free_ex did not release the Python reference count. Add BKE_libblock_free_data_py function to clear the Python reference in this case. Add asserts to ensure no Python reference is held in situations when ID's are copied for internal use (not exposed through the RNA API), to ensure these kinds of leaks don't go by unnoticed again.
2021-08-11Cleanup: clang-formatCampbell Barton
2021-08-11Cleanup: trailing space, remove BOMCampbell Barton
2021-08-11Fix 'GPU_matrix_unproject_3fv' not working with out-of-bounds pointsGermano Cavalcante
To solve this, the unproject code was redone in order to simplify and optimize.
2021-08-10Silensed compilation warning in gpu test case.Jeroen Bakker
2021-08-04Fix T90427: Center View to Mouse brokenGermano Cavalcante
rBfb87d236edb7 made the values returned by `projmat_dimensions` more standardized following the documentations. But the functions in Blender that called `projmat_dimensions` followed a proposal that these values corresponded to a distance of 1m of clip. Adjust these functions to follow the new algorithm.
2021-08-04Fix transparent faces on certain AMD cardsGavin Li
This patch fixes an issue with missing faces when assigning a material slot other than the first to faces on AMD TAHITI cards. Refer to T78390 and T74024 for a description of this issue. This patch also incorporates fix from T78390 for KAVERI. {F9029258} Reviewed By: fclem Differential Revision: https://developer.blender.org/D9305
2021-08-04Cleanup: use C comments for descriptive textCampbell Barton
2021-08-03Cleanup: use C++ comments or 'if 0' for commented codeCampbell Barton
2021-08-02Cleanup: spellingCampbell Barton
2021-07-30Cleanup: clarify license and origin of voronoi and dithering codeBrecht Van Lommel
2021-07-26Cleanup: spelling in commentsCampbell Barton
2021-07-23Cleanup: code comments punctuation / spacingCampbell Barton
2021-07-21Cleanup: replace BLI_assert(!"text") with BLI_assert_msg(0, "text")Campbell Barton
2021-07-21Cleanup: spellingCampbell Barton
2021-07-21Cleanup: replace BLI_assert(0 && "text") with BLI_assert_msgCampbell Barton
2021-07-16Fix T89782: Segfault populating popup menu with dimensions above the opengl ↵Germano Cavalcante
limit The crash happens because `GPU_offscreen_create` is called with `err_out` `NULL`. This patch proposes a solution within the `GPU_offscreen_create` itself and raises an error report in the interface if a menu is called with dimensions beyond what is supported. Ref T89782 Maniphest Tasks: T89782 Differential Revision: https://developer.blender.org/D11927
2021-07-16Cleanup: remove redundant parenthesesCampbell Barton
2021-07-15Geometry Nodes: dim links whose start and end sockets are not visibleJacques Lucke
This makes node trees with long links that cross other nodes easier to work with. Dimmed links will be ignored by various modal operators like cut and reroute insertion. Differential Revision: https://developer.blender.org/D11813
2021-07-15Cleanup: replace BLI_assert(!"text") with BLI_assert_msg(0, "text")Campbell Barton
This shows the text as part of the assertion message.
2021-07-08CMake: add missing headers, sort file listsCampbell Barton
2021-07-07Cleanup: spelling in commentsCampbell Barton
2021-07-06GPU: Fix crash when using EGL with --gpu-debug flag.Jeroen Bakker
During initialization of the platform a debug message is generated and interpreted by de callback. Here the platform is checked what requires an initialized platform. Fixed by giving the platform check less priority in the check.
2021-07-05Cleanup: use const argumentsCampbell Barton
2021-07-03Cleanup: consistent use of tags: NOTE/TODO/FIXME/XXXCampbell Barton
Also use doxy style function reference `#` prefix chars when referencing identifiers.
2021-06-29Cleanup: clang-formatCampbell Barton
2021-06-29Cleanup: GPU Shader Log Parsing.Jeroen Bakker
- Added functions to check if the cursor is at a number. - Added function to parse a number. - Joined skip_separator functions. - Added function to check if cursor is at any given set of characters.
2021-06-29Fixed issue in previous commit.Jeroen Bakker
During development a test was disabled. Enabling it again.
2021-06-29Fix T89405: Viewport Render Preview glitching (AMD)Jeroen Bakker
AMD Drivers didn't report an additional space in the rendered. This made testing for the HQ workaround fail and the issue appeared back on certain cards. This fix will test with surrounding spaces or if the renderer name endswith the given string. If any of these are the case the hq normals workaround will be enabled.
2021-06-28GPU: Refactored +cleanup compilation log parsing.Jeroen Bakker
Old implementation has a single parser of many different formats. With the introduction of Vulkan this would lead to another parser in the same function. This patch separates the log parsing using a visitor pattern so the log parsing can be configured per GPU backend or even per driver. With Vulkan we manage the compiler our self so the parsing will become more straight forward. The OpenGL part depends on many factors (OS, Driver) and perhaps even GPU.
2021-06-28GPU: Separate compiler log from shader.Jeroen Bakker
Current compiler log parser is to complex to follow. Moving it to its own compile unit before refactoring.
2021-06-28Fix: Crash Requesting GPU_SHADER_GPENCIL_FILL builtin shader.Jeroen Bakker
Shader doesn't have any shader code. Requesting the shader would crash blender. Solved by removing the enum_value.
2021-06-28GPU: Testcases for builtin shaders.Jeroen Bakker
Adding compiler test (does it compile?) test for all builtin shaders.
2021-06-28Cleanup GPU/Draw test cases.Jeroen Bakker
In preparation of supporting vulkan. Draw/GPU tests should use GPU_TEST or DRAW_TEST macros. These macros will run the test on available drawing context backends like OpenGL or Vulkan. As in master there is only an OpenGL backend nothing changed.
2021-06-26Cleanup: full sentences in comments, improve comment formattingCampbell Barton
2021-06-24Cleanup: compiler warnings with clangBrecht Van Lommel
* Mark either all or no class methods with override * Don't use zero sized array since it has a different size in C and C++. Using a little more memory here is not significant. * Don't use deprecated mechanism to mark private GSet members in clang just like we don't for MSVC, it warns even for simple zero initialization.
2021-06-24Cleanup: comment blocks, trailing space in commentsCampbell Barton
2021-06-22UI: Fix widget emboss: Also fade on the right sideLeon Leno
Currently the emboss is only fading on left side of the widget, resulting in the emboss extending vertically on the right side and ending abruptly. This patch fixes this by also fading the emboss on the right side and making it symmetric. Differential Revision: https://developer.blender.org/D10810
2021-06-18Cleanup: clang-tidyCampbell Barton
2021-06-13Cleanup: redundant initializationCampbell Barton
These were limited to obvious cases. Some less obvious cases were kept as refactoring might make them necessary in future.
2021-06-11Refactor: use 'BLI_task_parallel_range' in Draw CacheGermano Cavalcante
One drawback to trying to predict the number of threads that will be used in the `task_graph` is that we are only sure of the number when the threads are running. Using `BLI_task_parallel_range` allows the driver to choose the best thread distribution through `parallel_reduce`. The benefit is most evident on hardware with fewer cores. This is the result on an 4-core laptop: ||before:|after: |---|---|---| |large_mesh_editing:|Average: 5.203638 FPS|Average: 5.398925 FPS ||rdata 15ms iter 43ms (frame 193ms)|rdata 14ms iter 36ms (frame 187ms) Differential Revision: https://developer.blender.org/D11558
2021-06-11Refactor: Draw Cache: use 'BLI_task_parallel_range'Germano Cavalcante
This is an adaptation of {D11488}. A disadvantage of manually setting the iter ranges per thread is that we don't know how many threads are running in the background and so we don't know how to best distribute the ranges. To solve this limitation we can use `parallel_reduce` and thus let the driver choose the best distribution of ranges among the threads. This proved to be especially beneficial for computers with few cores. **Benchmarking:** Here's the result on an 4-core laptop: ||master:|PATCH: |---|---|---| |large_mesh_editing:|Average: 5.203638 FPS|Average: 5.398925 FPS ||rdata 15ms iter 43ms (frame 193ms)|rdata 14ms iter 36ms (frame 187ms) Here's the result on an 8-core PC: ||master:|PATCH: |---|---|---| |large_mesh_editing:|Average: 15.267482 FPS|Average: 15.906881 FPS ||rdata 9ms iter 28ms (frame 65ms)|rdata 9ms iter 25ms (frame 63ms) |large_mesh_editing_ledge: |Average: 15.145966 FPS|Average: 15.520474 FPS ||rdata 9ms iter 29ms (frame 65ms)|rdata 9ms iter 25ms (frame 64ms) |looptris_test:|Average: 4.001917 FPS|Average: 4.061105 FPS ||rdata 12ms iter 90ms (frame 236ms)|rdata 12ms iter 87ms (frame 230ms) |subdiv_mesh_cage_and_final:|Average: 1.917769 FPS|Average: 1.971790 FPS ||rdata 7ms iter 37ms (frame 261ms)|rdata 7ms iter 31ms (frame 258ms) ||rdata 7ms iter 38ms (frame 252ms)|rdata 7ms iter 33ms (frame 249ms) |subdiv_mesh_final_only:|Average: 6.387240 FPS|Average: 6.591251 FPS ||rdata 3ms iter 25ms (frame 151ms)|rdata 3ms iter 16ms (frame 145ms) |subdiv_mesh_final_only_ledge:|Average: 6.247393 FPS|Average: 6.596024 FPS ||rdata 3ms iter 26ms (frame 158ms)|rdata 3ms iter 16ms (frame 148ms) **Notes:** - The improvement can only be noticed if all extracts are multithreaded. - This patch touches different areas of the code, so it can be split into another patch if the idea is accepted. These screenshots show how threads behave in a quadcore: Master: {F10164664} Patch: {F10164666} Differential Revision: https://developer.blender.org/D11558
2021-06-08GPU: Thread safe index buffer builders.Jeroen Bakker
Current index builder is designed to be used in a single thread. This makes all index buffer extractions single threaded. This patch adds a thread safe solution enabling multithreaded building of index buffers. To reduce locking the solution would provide a task/thread local index buffer builder (called sub builder). When a thread is finished this thread local index buffer builder can be joined with the initial index buffer builder. `GPU_indexbuf_subbuilder_init`: Initialized a sub builder. The index list is shared between the parent and sub buffer, but the counters are localized. Ensuring that updating counters would not need any locking. `GPU_indexbuf_subbuilder_finish`: merge the information of the sub builder back to the parent builder. Needs to be invoked outside the worker thread, or when sure that all worker threads have been finished. Internal the function is not thread safe. For testing purposes the extract_points extractor has been migrated to the new API. Herefore changes to the mesh extractor were needed. * When creating tasks, the task number of current task is stored in ExtractTaskData including the total number of tasks. * Adding two functions in `MeshExtract`. ** `task_init` will initialize the task specific userdata. ** `task_finish` should merge back the task specific userdata back. * adding task_id parameter to the iteration functions so they can access the correct task data without any need for locking. There is no noticeable change in end user performance. Reviewed By: mano-wii Differential Revision: https://developer.blender.org/D11499
2021-06-08Revert "Cleanup: use cpp new/delete."Jeroen Bakker
This reverts commit 43464c94f4def8689dd99a9e459f5ff77420d27b.