535d9c63e11d45ec96682836c8a10441aae99f47
After creating a new shading material, the new node tree might become invisible and the user has to scroll down to see the nodes. The idea of this PR is to create nodes with x-positions centered around zero, such that they are always visible no matter the screen size or workspace setup. Ideally, the nodes' position should depend on the region's zoom and pan. However, the node creation code currently does not depend on `SpaceNode`, so such solution would complicate the code a bit. Also, this heuristic seem to work well enough for most cases. Note: this only affects newly created materials. The material of the default cube and the default world material still have invisible nodes sometimes. This is because they are saved in the startup file, which will be addressed in a different patch. Pull Request: https://projects.blender.org/blender/blender/pulls/136926
…
Blender
Blender is the free and open source 3D creation suite. It supports the entirety of the 3D pipeline-modeling, rigging, animation, simulation, rendering, compositing, motion tracking and video editing.
Project Pages
Development
License
Blender as a whole is licensed under the GNU General Public License, Version 3. Individual files may have a different, but compatible license.
See blender.org/about/license for details.
Description
Languages
C++
78%
Python
14.9%
C
2.9%
GLSL
1.9%
CMake
1.2%
Other
0.9%
