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
2022-09-06GPU: remove 'GPU_SHADER_2D_LINE_DASHED_UNIFORM_COLOR'Germano Cavalcante
The only difference between `GPU_SHADER_2D_LINE_DASHED_UNIFORM_COLOR` and `GPU_SHADER_3D_LINE_DASHED_UNIFORM_COLOR` is that in the vertex shader the 2D version uses `vec4(pos, 0.0, 1.0)` and the 3D version uses `vec4(pos, 1.0)`. But VBOs with 2D attributes work perfectly in shaders that use 3D attributes. Components not specified are filled with components from `vec4(0.0, 0.0, 0.0, 1.0)`. So there is no real benefit to having two different shader versions.
2022-09-06GPU: remove 'GPU_SHADER_3D_IMAGE_MODULATE_ALPHA'Germano Cavalcante
`GPU_SHADER_3D_IMAGE_MODULATE_ALPHA` can be seamlessly replaced by `GPU_SHADER_3D_IMAGE_COLOR` with no real harm done.
2022-09-05GPU: convert 'GPU_SHADER_2D_IMAGE_COLOR' to 3DGermano Cavalcante
3D shaders work in both 2D and 3D viewports. This shader is a good candidate to be exposed in Python.
2022-09-05GPU: remove 'GPU_SHADER_2D_SMOOTH_COLOR'Germano Cavalcante
The only real difference between `GPU_SHADER_2D_SMOOTH_COLOR` and `GPU_SHADER_3D_SMOOTH_COLOR` is that in the vertex shader the 2D version uses `vec4(pos, 0.0, 1.0)` and the 3D version uses `vec4(pos, 1.0)`. But VBOs with 2D attributes work perfectly in shaders that use 3D attributes. Components not specified are filled with components from `vec4(0.0, 0.0, 0.0, 1.0)`. So there is no real benefit to having two different shader versions. This will simplify porting shaders to python as it will not be necessary to use a 3D and a 2D version of the shaders. In python the new name for '2D_SMOOTH_COLOR' and '3D_SMOOTH_COLOR' is 'SMOOTH_COLOR', but the old names still work for backward compatibility.
2022-09-05GPU: remove 'GPU_SHADER_2D_IMAGE'Germano Cavalcante
The only real difference between `GPU_SHADER_2D_IMAGE` and `GPU_SHADER_3D_IMAGE` is that in the vertex shader the 2D version uses `vec4(pos, 0.0, 1.0)` and the 3D version uses `vec4(pos, 1.0)`. But VBOs with 2D attributes work perfectly in shaders that use 3D attributes. Components not specified are filled with components from `vec4(0.0, 0.0, 0.0, 1.0)`. So there is no real benefit to having two different shader versions. This will simplify porting shaders to python as it will not be necessary to use a 3D and a 2D version of the shaders. In python the new name for '2D_IMAGE' and '3D_IMAGE' is 'IMAGE', but the old names still work for backward compatibility.
2022-09-05GPU: remove 'GPU_SHADER_2D_FLAT_COLOR'Germano Cavalcante
The only real difference between `GPU_SHADER_2D_FLAT_COLOR` and `GPU_SHADER_3D_FLAT_COLOR` is that in the vertex shader the 2D version uses `vec4(pos, 0.0, 1.0)` and the 3D version uses `vec4(pos, 1.0)`. But VBOs with 2D attributes work perfectly in shaders that use 3D attributes. Components not specified are filled with components from `vec4(0.0, 0.0, 0.0, 1.0)`. So there is no real benefit to having two different shader versions. This will simplify porting shaders to python as it will not be necessary to use a 3D and a 2D version of the shaders. In python the new name for '2D_FLAT_COLOR'' and '3D_FLAT_COLOR' is 'FLAT_COLOR', but the old names still work for backward compatibility.
2022-09-05GPU: remove 'GPU_SHADER_2D_UNIFORM_COLOR'Germano Cavalcante
The only real difference between `GPU_SHADER_2D_UNIFORM_COLOR` and `GPU_SHADER_3D_UNIFORM_COLOR` is that in the vertex shader the 2D version uses `vec4(pos, 0.0, 1.0)` and the 3D version uses `vec4(pos, 1.0)`. But VBOs with 2D attributes work perfectly in shaders that use 3D attributes. Components not specified are filled with components from `vec4(0.0, 0.0, 0.0, 1.0)`. So there is no real benefit to having two different shader versions. This will simplify porting shaders to python as it will not be necessary to use a 3D and a 2D version of the shaders. In python the new name for '2D_UNIFORM_COLOR'' and '3D_UNIFORM_COLOR' is 'UNIFORM_COLOR', but the old names still work for backward compatibility. Differential Revision: https://developer.blender.org/D15836
2022-09-05Fix T81002: Images drawn with the Python gpu module no longer draw on top in ↵Germano Cavalcante
the Image Editor This reverts commit 32d4a67017ecf4af75a9bfde885526550a6534ba thus fixing T81002 again. And in order not to break T81212 (again) a different fix was implemented. Reviewed By: brecht Differential Revision: https://developer.blender.org/D15840
2022-09-05Merge branch 'blender-v3.3-release'Clément Foucault
2022-09-05Fix T100649: Regression: Environment texture is stretched when added to meshClément Foucault
The new code was not using the correct default attribute. Add access to `g_data.P` through `node_tex_coord_position()` to replace the old `GPU_builtin(GPU_VIEW_POSITION)` which was used before. Reviewed By: jbakker Differential Revision: https://developer.blender.org/D15862
2022-09-02DRW-Next: Add uniform attributes (object attributes) supportClément Foucault
This replaces the direct shader uniform layout declaration by a linear search through a global buffer. Each instance has an attribute offset inside the global buffer and an attribute count. This removes any padding and tighly pack all uniform attributes inside a single buffer. This would also remove the limit of 8 attribute but it is kept because of compatibility with the old system that is still used by the old draw manager.
2022-09-02Merge branch 'blender-v3.3-release'Clément Foucault
# Conflicts: # release/scripts/addons
2022-09-02Fix T100163: Eevee: Regression: Displacement maps affected by rotationClément Foucault
This was an oversight as the matrix multiplication present in original code was reversed. Reviewed By: jbakker Differential Revision: https://developer.blender.org/D15858
2022-09-02Fix T100377: EEVEE: Regression 3.2 normalmap node brokenClément Foucault
This was caused by un-wanted normalization. This is a requirement of the MikkTspace. The issue is that g_data.N is expected to be normalized by many other functions and overriden by bump displacement. Adding a new global variable containing the interpolated normal fixes the issue AND make it match cycles behavior better (mix between bump and interpolated normal).
2022-09-02Fix T99528: EEVEE: Regression: Faulty shaders when using Volume Info nodeClément Foucault
Workaround the issue by adding an intermediate function. This is usually the case when working with attributes. Reviewed By: jbakker Differential Revision: https://developer.blender.org/D15860
2022-09-02Realtime Compositor: Implement dilate erode nodeOmar Emara
This patch implements the dilate/erode node for the realtime compositor. Differential Revision: https://developer.blender.org/D15790 Reviewed By: Clement Foucault
2022-09-02Fix T98190: EEVEE: Very slow rendering on Intel HD Graphics 4400Clément Foucault
This particular GPU driver does not constant fold all the way in order to discard the unused branches. To workaround that, we introduce a series of material flag that generates defines that only keep used branches. Reviewed By: jbakker Differential Revision: https://developer.blender.org/D15852
2022-09-01Metal: MTLShader and MTLShaderGenerator implementation.Thomas Dinges
Full support for translation and compilation of shaders in Metal, using GPUShaderCreateInfo. Includes render pipeline state creation and management, enabling all standard GPU viewport rendering features in Metal. Authored by Apple: Michael Parkin-White, Marco Giordano Ref T96261 Reviewed By: fclem Maniphest Tasks: T96261 Differential Revision: https://developer.blender.org/D15563
2022-09-01Node Editor: Visual tweaks to node linksLeon Schittek
Several visual tweaks to node links to make them overall fit in better with the look of the node editor: - Change the link thickness with the zoom level to a certain degree. - Remove the fuzziness of the node link and its shadow/outline. - The link outline color can now be made transparent. - Add circles at the end of dragged links when connecting to sockets. - Improve the banding of the color interpolation along the link. - Adjust the spacing of dashes along straight node links. Reviewed By: Pablo Vazquez, Hans Goudey Differential Revision: http://developer.blender.org/D15036
2022-08-31Node: Mix nodeCharlie Jolly
This patch is a response to T92588 and is implemented as a Function/Shader node. This node has support for Float, Vector and Color data types. For Vector it supports uniform and non-uniform mixing. For Color it now has the option to remove factor clamping. It replaces the Mix RGB for Shader and Geometry node trees. As discussed in T96219, this patch converts existing nodes in .blend files. The old node is still available in the Python API but hidden from the menus. Reviewed By: HooglyBoogly, JacquesLucke, simonthommes, brecht Maniphest Tasks: T92588 Differential Revision: https://developer.blender.org/D13749
2022-08-26Merge branch 'blender-v3.3-release'Bastien Montagne
2022-08-26Fix T55284: error in Hybrid MultiFractal Musgrave textureLuis Pereira
The calculation was revised to address two issues: * Discontinuities occurring when detail was a non-integer greater than 2. * Levels of detail in the interval [0,1) repeating the levels of detail in the interval [1,2). This fixes Cycles, Eevee and geometry nodes. Differential Revision: https://developer.blender.org/D15785
2022-08-23Fix: Compositor results are fuzzy with bilinear filteringOmar Emara
The realtime compositor sometimes produces fuzzy results when the interpolation is set to bilinear. This was due to the domain realization shader, which incorrectly sampled the input image. This patch fixes such fuzziness by introducing a 0.5 offset to evaluate the sampler at the center of pixels. Additionally, it makes sure the centring offset is an integer offset by taking its floor, retaining the previous 0.5 offset even with the difference in size is odd.
2022-08-18Realtime Compositor: Implement bilateral blur nodeOmar Emara
This patch implements the bilateral blur node for the realtime compositor. Differential Revision: https://developer.blender.org/D15674 Reviewed By: Clement Foucault
2022-08-18Realtime Compositor: Implement despeckle nodeOmar Emara
This patch implements the despeckle node for the realtime compositor. Differential Revision: https://developer.blender.org/D15673 Reviewed By: Clement Foucault
2022-08-18Realtime Compositor: Implement directional blur nodeOmar Emara
This patch implements the directional blur node for the realtime compositor. Differential Revision: https://developer.blender.org/D15672 Reviewed By: Clement Foucault
2022-08-18Realtime Compositor: Implement filter nodeOmar Emara
This patch implements the filter node for the realtime compositor. Differential Revision: https://developer.blender.org/D15661 Reviewed By: Clement Foucault
2022-08-18Realtime Compositor: Implement bokeh image nodeOmar Emara
This patch implements the bokeh image node for the realtime compositor. Differential Revision: https://developer.blender.org/D15660 Reviewed By: Clement Foucault
2022-08-17Cleanup: strip blank lines around comment blocksCampbell Barton
2022-08-10Realtime Compositor: Add basic distort nodesOmar Emara
This patch implements the following nodes for the realtime compositor: - Crop node. - Flip node. - Lens distort node. - Rotate node. - Transform node. - Translate node. Differential Revision: https://developer.blender.org/D15231 Reviewed By: Clement Foucault
2022-08-10Realtime Compositor: Add basic matte nodesOmar Emara
This patch implements the following nodes for the realtime compositor: - Box mask node. - Channel matte node. - Chroma matte node. - Color matte node. - Color spill node. - Difference matte node. - Distance matte node. - Ellipse matte node. - Luminance matte node. Differential Revision: https://developer.blender.org/D15230 Reviewed By: Clement Foucault
2022-08-10Realtime Compositor: Add basic convert and vector nodesOmar Emara
This patch implements the following nodes for the realtime compositor: - Map range node. - Map value node. - Math node. - Normal node. - Alpha convert node. - Separate color node. - Combine color node. - Separate XYZ node. - Combine XYZ node. - Separate RGBA node. - Combine RGBA node. - Separate HSVA node. - Combine HSVA node. - Separate YCCA node. - Combine YUVA node. - Set alpha node. - Switch node. - Switch view node. - RGB to BW node. - Color ramp node. Differential Revision: https://developer.blender.org/D15229 Reviewed By: Clement Foucault
2022-08-10Realtime Compositor: Add basic color nodesOmar Emara
This patch implements the following nodes for the realtime compositor: - Alpha over node. - Bright contrast node. - Color balance node. - Color correction node. - Exposure node. - Gamma node. - Hue correct node. - Hue saturation value node. - Invert node. - Mix node. - Posterize node. - Time curve node. - Vector curve node. Differential Revision: https://developer.blender.org/D15228 Reviewed By: Clement Foucault
2022-08-10Realtime Compositor: Add basic output nodesOmar Emara
This patch implements the following nodes for the realtime compositor: - Composite node. - Viewer node. - Split viewer node. Differential Revision: https://developer.blender.org/D15226 Reviewed By: Clement Foucault
2022-08-10Realtime Compositor: Add evaluator and engineOmar Emara
This patch adds the core realtime compositor evaluator as well as a compositor draw engine powered by the evaluator that operates in the viewport. The realtime compositor is a new GPU accelerated compositor that will be used to power the viewport compositor imminently as well as the existing compositor in the future. This patch only adds the evaluator and engine as an experimental feature, the implementation of the nodes themselves will be committed separately. See T99210. Differential Revision: https://developer.blender.org/D15206 Reviewed By: Clement Foucault
2022-06-20Cleanup: Grammar: a vs anHans Goudey
2022-06-20Fix T99019 EEVEE: Regression: Specular BSDF does not apply occlusionClément Foucault
Since the occlusion input is going to be removed in EEVEE-Next, I just added a temporary workaround. The occlusion is passed as SSS radius as the Specular BSDF does not use it. The final result matches 3.1 release
2022-06-20Fix T99018: EEVEE: Regression: Specular BSDF apply specular color input twiceClément Foucault
This was an oversight. I checked that no other node had the same regression.
2022-06-09Cleanup: use C-style comments, add missing doxy sectionCampbell Barton
2022-06-07Merge branch 'blender-v3.2-release'Clément Foucault
# Conflicts: # source/blender/draw/engines/eevee/shaders/volumetric_vert.glsl
2022-06-07Fix T98647: EEVEE: Camera Data Node's View Vector BrokenClément Foucault
Fix regression and remove duplicated computation.
2022-06-02Merge branch 'blender-v3.2-release'Clément Foucault
2022-06-02Fix T98538 EEVEE: Geometry input node breaks with Displacement TextureClément Foucault
This was due to older drivers not honoring varying attributes shadowing by local variables. Renaming the input argument fixes the issue.
2022-05-23Merge branch 'blender-v3.2-release'Brecht Van Lommel
2022-05-23Fix Eevee blackbody wrong with non-default scene linear color spaceBrecht Van Lommel
* Port over new code tables from Cycles * Convert Rec.709 to scene linear for lookup table. * Move code for wavelength and blackbody to IMB so they can access the required transforms, which are not in blenlib. * Remove clamping from blackbody shader to bypass the texture read. Since it's variable now easiest to just always read from the texture than pass additional parameters. * Fold XYZ to RGB conversion into the wavelength table. Ref T68926
2022-05-23Cleanup: GPU: Remove `gpu_shader_common_obinfos_lib.glsl`Clément Foucault
This has been replaced by `draw_object_infos`.
2022-05-23EEVEE: Fix unreported broken normal map node modesClément Foucault
A compilation error was making it impossible to use normal map modes other than tangent.
2022-05-23Cleanup: GPU: Remove `gpu_shader_common_obinfos_lib.glsl`Clément Foucault
This has been replaced by `draw_object_infos`.
2022-05-23EEVEE: Fix unreported broken normal map node modesClément Foucault
A compilation error was making it impossible to use normal map modes other than tangent.
2022-05-12Cleanup: Remove unused gpu_shader_geometry.glslClément Foucault