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-11-12Cleanup: move 'imm_drawcircball' to 'gpu_immediate_util.c'Germano Cavalcante
2021-11-08GPUTest: Add support to test on Windows.Jeroen Bakker
On windows the OpenGL context wasn't activated when created, on Linux it is. This patch will activate the context in gpu/draw test cases.
2021-11-05Merge branch 'blender-v3.0-release'Bastien Montagne
2021-11-05Cleanup (UI): Add/use type for operator context enumJulian Eisel
Adds a `wmOperatorCallContext` typedef for the existing `WM_OP_XXX` operator context enum. This adds type safety, allows the compiler to produce better warnings and helps understanding what a variable is for. Differential Revision: https://developer.blender.org/D13113 Reviewed by: Campbell Barton
2021-11-05Fix T92807: Incorrect display planar tracking.Jeroen Bakker
Issue introduced in {7e66616b7e15} where the shader was replaced with a 2d image shader. This patch reverts several commits that removed the 3d image shader.
2021-11-02Fix T77681, T92634: noise texture artifacts with high detailBrecht Van Lommel
We run into float precision issues here, clamp the number of octaves to one less, which has little to no visual difference. This was empirically determined to work up to 16 before, but with additional inputs like roughness only 15 appears to work. Also adds misisng clamp for the geometry nodes implementation.
2021-11-01GPUState: Fix enum max value for enum operator macroClément Foucault
Simple oversight.
2021-10-27Cleanup: remove underscore prefix from variableCampbell Barton
Avoid using underscore prefix since these typically mean the variable shouldn't be accessed directly (it may be accessed from a macro, or memory on the stack which is assigned to a pointer). In this case a more meaningful name can be used for the argument that was shadowed.
2021-10-27Revert "Revert "Eevee: support accessing custom mesh attributes""Germano Cavalcante
This reverts commit e7fedf6dba5fe2ec39260943361915a6b2b8270a. And also fix a compilation issue on windows. Differential Revision: https://developer.blender.org/D12969
2021-10-26Revert "Eevee: support accessing custom mesh attributes"Ray Molenkamp
This reverts commit 03013d19d16704672f9db93bc62547651b6a5cb8. This commit broke the windows build pretty badly and I don't feel confident landing the fix for this without review. Will post a possible fix in D12969 and we'll take it from there.
2021-10-26Eevee: support accessing custom mesh attributesKévin Dietrich
This adds generic attribute rendering support for meshes for Eevee and Workbench. Each attribute is stored inside of the `MeshBufferList` as a separate VBO, with a maximum of `GPU_MAX_ATTR` VBOs for consistency with the GPU shader compilation code. Since `DRW_MeshCDMask` is not general enough, attribute requests are stored in new `DRW_AttributeRequest` structures inside of a convenient `DRW_MeshAttributes` structure. The latter is used in a similar manner as `DRW_MeshCDMask`, with the `MeshBatchCache` keeping track of needed, used, and used-over-time attributes. Again, `GPU_MAX_ATTR` is used in `DRW_MeshAttributes` to prevent too many attributes being used. To ensure thread-safety when updating the used attributes list, a mutex is added to the Mesh runtime. This mutex will also be used in the future for other things when other part of the rendre pre-processing are multi-threaded. `GPU_BATCH_VBO_MAX_LEN` was increased to 16 in order to accommodate for this design. Since `CD_PROP_COLOR` are a valid attribute type, sculpt vertex colors are now handled using this system to avoid to complicate things. In the future regular vertex colors will also use this. From this change, bit operations for DRW_MeshCDMask are now using uint32_t (to match the representation now used by the compiler). Due to the difference in behavior for implicit type conversion for scalar types between OpenGL and what users expect (a scalar `s` is converted to `vec4(s, 0, 0, 1)` by OpenGL, vs. `vec4(s, s, s, 1)` in Blender's various node graphs) , all scalar types are using a float3 internally for now, which increases memory usage. This will be resolved during or after the EEVEE rewrite as properly handling this involves much deeper changes. Ref T85075 Reviewed By: fclem Maniphest Tasks: T85075 Differential Revision: https://developer.blender.org/D12969
2021-10-25Cleanup: silence warningsGermano Cavalcante
``` warning: assignment discards ‘const’ qualifier from pointer target warning: declaration of ‘co’ shadows a parameter ```
2021-10-25Assets: Snapping with visual feedback while draggingGermano Cavalcante
The drag and drop feature of objects in 3D View has been modified to include: - Snap the object being dragged. - Visual feedback through a box and the placement tool grid. Maniphest Tasks: T90198 Differential Revision: https://developer.blender.org/D12912
2021-10-21Nodes: Fix missing variablePablo Vazquez
2021-10-21Node Editor: Introduce color overlay and dashed wires theme settingPablo Vazquez
This patch includes code from D9891 and D12754, so credit goes to Juanfran and Dalai. I updated the patches to work with `master` and with the new overlay toggle. The reason to include both changes as part of one patch is that the dimmed dashed lines work much better together with colored wires. Theme setting for dash opacity: {F11370574, size=full} {F11286177, size=full, autoplay, loop} {F11149912, size=full} For adding the overlay I used `SpaceImageOverlay` as reference, although I'm not familiar with this code so there might be mistakes. Reviewed By: #user_interface, HooglyBoogly Differential Revision: https://developer.blender.org/D12886
2021-10-20Cleanup: spelling in commentsCampbell Barton
2021-10-14GPUTexture: Fix assert when using stereo viewport with EEVEEClément Foucault
Stereo viewport means the depth buffer is use twice as often as a framebuffer attachment.
2021-10-13Fix T88766 EEVEE: Missing glossy reflections with Shader to RGB & SSR is active.Clément Foucault
This was due to the shading evaluation being outdated inside the ShaderToRGBA glsl code.
2021-10-05Cleanup: Geometry Nodes dashed linesDalai Felinto
No functional change, just cleaning up the shader code a bit. Part of this is removing dead code (the discard was never called), and part is shuffling mix/max around based on feedback by Sybren Stüvel.
2021-10-05DRW: Move buffer & temp textures & framebuffer management to DrawManagerClément Foucault
This is a necessary step for EEVEE's new arch. This moves more data to the draw manager. This makes it easier to have the render or draw engines manage their own data. This makes more sense and cleans-up what the GPUViewport holds Also rewrites the Texture pool manager to be in C++. This also move the DefaultFramebuffer/TextureList and the engine related data to a new `DRWViewData` struct. This struct manages the per view (as in stereo view) engine data. There is a bit of cleanup in the way the draw manager is setup. We now use a temporary DRWData instead of creating a dummy viewport. Development: fclem, jbakker Differential Revision: https://developer.blender.org/D11966
2021-10-05Cleanup: use doxygen sectionsCampbell Barton
2021-10-03Cleanup: spelling in commentsCampbell Barton
2021-10-01GPU: set 'GL_PACK_ALIGNMENT' 1 as defaultGermano Cavalcante
This fixes T91828. The current value of `GL_PACK_ALIGNMENT` may result in crash in the `gpu` module if the buffer is not aligned. Differential Revision: https://developer.blender.org/D12720
2021-09-30Nodes: Add Float Curve for GN and Shader nodes.Charlie Jolly
Replacement for float curve in legacy Attribute Curve Map node. Float Curve defaults to [0.0-1.0] range. Reviewed By: JacquesLucke, brecht Differential Revision: https://developer.blender.org/D12683
2021-09-28Geometry Nodes: Dashed lines for function flowDalai Felinto
Use dashes to represent the function flow (while keeping continuous lines for the data-flow). It is important to tell both flows apart (the data and the function flow). The sockets help with that, the noodles help this further. The "data flow" is evaluated at every single node. A user can inspect the output sockets of those nodes and have a glimpse at their values. The "function flow" (nodes) however is only evaluated in the geometry nodes. The noodles are not transporting data in the same sense of the "data flow". All that can be inspected are the attributes the functions depend on. Having this clearly communicated should help users to inspect the nodetrees, read and understand the different flows in the same tree. --- Known limitations: At the moment the dash lines are not equidistant: * It would be nice to get the "uv.x" to be resampled for the bezier curve so the dashes are equally distributed in the curve. * Using distance between the P3 and P0 instead of the real bezier curve length seems to be fine. --- Full disclaimer: Changes with that much of a visual impact tend to be controversial. So far the main feedback is that dashed lines can be associated to broken link, and that there are better ways to represent the flows (or different information that should be visually represented). I'm fully aware of that. However dashed lines are already used in the viewport and outliner to indicate (hierarchical) relation. Besides, other approaches (double-lines, having the data flow to be more distinct, ...) didn't pan out in the end (or didn't look as good as this). --- Impact in other editors: The compositor uses mostly a "data flow" nodetree, so no change is expected there. The shader nodetree is one that could but doesn't have to change its visual language. The shader nodetree uses mostly "function flow" with some "data flow" nodes. One can argue that it should be adapted to follow the same pattern as geometry nodes (with the new noodles and the diamond sockets). Oh the other hand, a shader nodetree has a single context. When a node depends on the "UV", there is only one UV at a time for the entire nodetree. So it can also be treated as a psedo "data flow" nodetree if we want to avoid too many changes in other parts of Blender. Differential Revision: https://developer.blender.org/D12602
2021-09-27Geometry Nodes: make field links thinner than other linksJacques Lucke
This makes it easier to spot which links contain fields and which contain data. Actually, the patch makes all other links a bit thicker. However, with soon-to-be-implemented theme changes, the perceived thickness will be the same as before. This is part of T91563. Differential Revision: https://developer.blender.org/D12646
2021-09-27FIX: T91697 Eevee Generated texture coordinates completly missingLasse Foster
This patch fixes Eevee-regression https://developer.blender.org/T91697 Reviewed By: jbakker Differential Revision: https://developer.blender.org/D12634
2021-09-24Nodes: make dot in socket shape circularJacques Lucke
Previously, it was a diamond shape when the overall shape was a diamond.
2021-09-24Cleanup: clang formatPhilipp Oeser
2021-09-24Hair Info Length AttributeJeroen Bakker
Goal is to add the length attribute to the Hair Info node, for better control over color gradients or similar along the hair. Reviewed By: #eevee_viewport, brecht Differential Revision: https://developer.blender.org/D10481
2021-09-23Cleanup: Remove hardcoded values and rename keyframe shape shadersDalai Felinto
No functional change. The shader is complicated by itself, having hardcoded values makes it even more cryptic. I also renamed the shader because the shader is not for the keyfarme diamond only, but for all the keyframe shapes. Differential Revision: https://developer.blender.org/D12615
2021-09-23Cleanup: spelling in commentsCampbell Barton
2021-09-21Cycles: merge of cycles-x branch, a major update to the rendererBrecht Van Lommel
This includes much improved GPU rendering performance, viewport interactivity, new shadow catcher, revamped sampling settings, subsurface scattering anisotropy, new GPU volume sampling, improved PMJ sampling pattern, and more. Some features have also been removed or changed, breaking backwards compatibility. Including the removal of the OpenCL backend, for which alternatives are under development. Release notes and code docs: https://wiki.blender.org/wiki/Reference/Release_Notes/3.0/Cycles https://wiki.blender.org/wiki/Source/Render/Cycles Credits: * Sergey Sharybin * Brecht Van Lommel * Patrick Mours (OptiX backend) * Christophe Hery (subsurface scattering anisotropy) * William Leeson (PMJ sampling pattern) * Alaska (various fixes and tweaks) * Thomas Dinges (various fixes) For the full commit history, see the cycles-x branch. This squashes together all the changes since intermediate changes would often fail building or tests. Ref T87839, T87837, T87836 Fixes T90734, T89353, T80267, T80267, T77185, T69800
2021-09-13GPUShader: Expose name for debugging & identifying shadersJon Denning
Added optional `name` argument to `GPUShader` constructor (defaults to `pyGPUShader`), and added `name` getter to `GPUShader`. Ref D12393 Reviewed By: campbellbarton, jbakker
2021-09-06Fix crash drawing hair with older GPUs.Jeroen Bakker
Some GPU's have support for compute shaders, but don't support GLSL 4.3. This resulted in compiler errors and crashes. This issue could have been solved by supporting older GLSL languages but that would have been a hassle to get it right. We already have a fallback in place for GPU's that don't support compute shaders at all.
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