Age | Commit message (Collapse) | Author |
|
|
|
This commit adds a new face nearest snapping mode, adds new snapping
options, and (lightly) refactors code around snapping.
The new face nearest snapping mode will snap transformed geometry to the
nearest surface in world space. In contrast, the original face snapping
mode uses projection (raycasting) to snap source to target geometry.
Face snapping therefore only works with what is visible, while nearest
face snapping can snap geometry to occluded parts of the scene. This new
mode is critical for retopology work, where some of the target mesh
might be occluded (ex: sliding an edge loop that wraps around the
backside of target mesh).
The nearest face snapping mode has two options: "Snap to Same Target"
and "Face Nearest Steps". When the Snap to Same Object option is
enabled, the selected source geometry will stay near the target that it
is nearest before editing started, which prevents the source geometry
from snapping to other targets. The Face Nearest Steps divides the
overall transformation for each vertex into n smaller transformations,
then applies those n transformations with surface snapping interlacing
each step. This steps option handles transformations that cross U-shaped
targets better.
The new snapping options allow the artist to better control which target
objects (objects to which the edited geometry is snapped) are considered
when snapping. In particular, the only option for filtering target
objects was a "Project onto Self", which allowed the currently edited
mesh to be considered as a target. Now, the artist can choose any
combination of the following to be considered as a target: the active
object, any edited object that isn't active (see note below), any non-
edited object. Additionally, the artist has another snapping option to
exclude objects that are not selectable as potential targets.
The Snapping Options dropdown has been lightly reorganized to allow for
the additional options.
Included in this patch:
- Snap target selection is more controllable for artist with additional
snapping options.
- Renamed a few of the snap-related functions to better reflect what
they actually do now. For example, `applySnapping` implies that this
handles the snapping, while `applyProject` implies something entirely
different is done there. However, better names would be
`applySnappingAsGroup` and `applySnappingIndividual`, respectively,
where `applySnappingIndividual` previously only does Face snapping.
- Added an initial coordinate parameter to snapping functions so that
the nearest target before transforming can be determined(for "Snap to
Same Object"), and so the transformation can be broken into smaller
steps (for "Face Nearest Steps").
- Separated the BVH Tree getter code from mesh/edit mesh to its own
function to reduce code duplication.
- Added icon for nearest face snapping.
- The original "Project onto Self" was actually not correct! This option
should be called "Project onto Active" instead, but that only matters
when editing multiple meshes at the same time. This patch makes this
change in the UI.
Reviewed By: Campbell Barton, Germano Cavalcante
Differential Revision: https://developer.blender.org/D14591
|
|
In "size" voxel resolution mode, calculating the bounds of the mesh to
volume node's input mesh isn't necessary. For high poly this can take
a few milliseconds, so this commit skips the calculation unless we need
it for the "Amount" mode.
Differential Revision: https://developer.blender.org/D15324
|
|
This commit adds new Unwrap and Pack Islands nodes, with equivalent
functionality to the existing Unwrap and Pack Islands operators. The
Unwrap node uses generic boolean attributes to determine seams instead
of looking at the seam flags in the mesh geometry.
Unlike the Unwrap operator, the Unwrap node doesn't perform aspect
ratio correction, because this is trivial for the user to implement
with a Vector Math node if it is desired.
The Unwrap node implicitly performs a Pack Islands operation upon
completion, because the results may not be generally useful otherwise.
This matches the behaviour of the Unwrap operator.
The nodes use the existing Vector socket type, and do not introduce a
new 2D Vector type (see T92765).
Differential Revision: https://developer.blender.org/D14389
|
|
The RNA API in rna_mesh.c has a function to rename generic customdata
layers. However for customdata layers which are attributes (i.e. not
specialized types) the attribute renaming function needs to be used,
as that can ensure unique names across domains.
Differential Revision: https://developer.blender.org/D15310
|
|
|
|
This adds a Mesh To Volume Node T86838 based on the existing modifier.
The mesh to volume conversion is implemented in the geometry module,
and shared between the node and the modifier.
Currently the node outputs a grid with the name "density". This may
change in the future depending on the decisions made in T91668.
The original patch was by Kris (@Metricity), further implementation
by Geramy Loveless (@GeramyLoveless), then finished by Erik Abrahamsson
(@erik85).
Differential Revision: https://developer.blender.org/D10895
|
|
The compression as sRGB is mostly an implementation detail and showing the
integers does not make it clear what the actual values are that will be used
for computations in geometry nodes. This follows the general convention that
colors in Blender are displayed and edited in scene linear floats.
The raw sRGB bytes can still be viewed as a tooltip.
Ref T99205
Differential Revision: https://developer.blender.org/D15322
|
|
This patch includes the full shadow functionality for LineArt:
- Light contour and cast shadow lines.
- Lit/shaded region selection.
- Enclosed light/shadow shape calculation.
- Silhouette/anti-silhouette selection.
- Intersection priority based on shadow edge identifier.
Reviewed By: Sebastian Parborg (zeddb)
Differential Revision: https://developer.blender.org/D15109
|
|
These are based on the descriptions from the manual, with various changes.
Differential Revision: https://developer.blender.org/D15309
|
|
There were two problems:
1) The checking of the collision was not working with one point only.
2) For one point, the masking was checked always and if the masking was not activated, the stroke was skipped.
|
|
The resource binding were missing from the shading group
(`shgroup->uniform_attrs`), leading to no custom property UBO creation
(`drw_uniform_attrs_pool_update`) when issuing the drawcall,
resulting in a missing UBO bind.
The fix make sure to no duplicate the bindings by creating a simple
shader bind instead of a `GPUMaterial` bind.
Candidate for 3.2.1 corrective release.
|
|
This happened because of the false assumption that `std::array<char, 32>`
would be treated as a container and not relocate their content if the
`Vector` would grow. Replacing with actual object allocation fixes the
issue.
Candidate for 3.2.1 corrective release.
|
|
Using Light output is supported in Cycles. This patch adds support for it
and remove the crash in `ntree_shader_weight_tree_invert()` by treating
it as any other outputs.
Candidate for 3.2.1 corrective release.
|
|
Use view position to retreive world space direction to retain float
precision.
Candidate for 3.2.1 corrective release.
|
|
The ORCO property was not being properly initialized in this case.
Candidate for 3.2.1 corrective release.
|
|
|
|
This patch adds a new Cycles device with similar functionality to the
existing GPU devices. Kernel compilation and runtime interaction happen
via oneAPI DPC++ compiler and SYCL API.
This implementation is primarly focusing on Intel® Arc™ GPUs and other
future Intel GPUs. The first supported drivers are 101.1660 on Windows
and 22.10.22597 on Linux.
The necessary tools for compilation are:
- A SYCL compiler such as oneAPI DPC++ compiler or
https://github.com/intel/llvm
- Intel® oneAPI Level Zero which is used for low level device queries:
https://github.com/oneapi-src/level-zero
- To optionally generate prebuilt graphics binaries: Intel® Graphics
Compiler All are included in Linux precompiled libraries on svn:
https://svn.blender.org/svnroot/bf-blender/trunk/lib The same goes for
Windows precompiled binaries but for the graphics compiler, available
as "Intel® Graphics Offline Compiler for OpenCL™ Code" from
https://www.intel.com/content/www/us/en/developer/articles/tool/oneapi-standalone-components.html,
for which path can be set as OCLOC_INSTALL_DIR.
Being based on the open SYCL standard, this implementation could also be
extended to run on other compatible non-Intel hardware in the future.
Reviewed By: sergey, brecht
Differential Revision: https://developer.blender.org/D15254
Co-authored-by: Nikita Sirgienko <nikita.sirgienko@intel.com>
Co-authored-by: Stefan Werner <stefan.werner@intel.com>
|
|
Patch implements better way to control playback speed than it is
possible to do with speed effect. Speed factor property can be set in
Time panel.
There are 2 layers of control:
Option to retime movie to match scene FPS rate.
Custom speed factor to control playback rate.
Since playback rate is strip property, it is now possible to manipulate
strip as normal one even if it is retimed.
To facilitate manipulation, some functions need to consider speed factor
and apply necessary corrections to strip offset or strip start. These
corrections may need to be float numbers, so start and offsets must be
float as well.
Sound strips now use speed factor instead of pitch. This means, that
strips will change length to match usable length. In addition, it is
possible to group movie and sound strip and change speed of meta strip.
|
|
This makes it possible to use this method with `std::unique_ptr`.
|
|
|
|
This commit adds the ability to test Eevee viewport playback performance tests.
Tests should be placed in `lib/benchmarks/eevee/*/*.blend`. {rBL62962} added
initial test files. See https://wiki.blender.org/wiki/Tools/Tests/Performance how
to set it up.
To record the playback performance the test start the viewport playback, and adds
a post frame change handler.
This handler will go over the next steps:
* Ensures the viewport is set to rendered mode.
* Wait for shaders to be compiled. Utilizes `bpy.app.is_job_running` function when
available (v3.3) to wait for shader compilation to finish. When not available will wait
for one minute.
* Draw several warmup frames
* Record for 10 seconds tracking the number of frames drawn and performance counters.
* When ready print the result to the console. The results will be extracted when the
benchmark has run.
## Example report
```
master v3.0 v3.1 v3.2
T88219 0.0860s 0.0744s 0.0744s 0.0851s
blender290-fox 1.3056s 0.8744s 0.7994s 1.2809s
```
{F13232387}
Reviewed By: brecht, fclem
Maniphest Tasks: T99136
Differential Revision: https://developer.blender.org/D15302
|
|
Winding order of grid quads was backwards.
|
|
|
|
Prep for D15263
|
|
Prep for D15263
|
|
Prep for D15263
|
|
|
|
Differential Revision: D14945
|
|
|
|
Tagging the object for copy on write in order to change the mode on the
evaluated object was already done when entering sculpt mode, it should
happen when exiting sculpt mode as well.
Also use the message system to tag updates of the mode property.
This is commonly done for other "mode switch" operators. It's
best to be consistent here, though I don't know that lacking that
caused any issues.
|
|
Oversight in rB7724251af81f. Skip saving selection properties
for UV edge ring operator as it allows the operator to re-use
the value that was previously set using the key-map.
Reviewed By: campbellbarton
Maniphest Tasks: T98924
Differential Revision: https://developer.blender.org/D15214
|
|
This was preventing correct attribute rendering with multiple attributes.
Since the `CurveInfos` struct is used for data sharing between C++ and
GLSL and inside a UBO it needs to obey the `std140` alignment rules which
states that arrays of scalars are padded to the size of `vec4` for each
array entry.
|
|
|
|
|
|
depending on the visibility of other objects
The material ID was being wrongly passed in the shader.
|
|
This was a mistake in 17a773cdcee9 - I did not notice existing set
function and assumed, that property set DNA directly.
Both get and set functions are now available and readonly flag is
removed.
|
|
Differential Revision: https://developer.blender.org/D15304
|
|
|
|
This is easier to use in C++ code compared to passing a function
and user-data separately.
|
|
The mask is expected to be always be displayed smooth, and the
option mainly existed for some legacy drivers. IF smooth drawing
causes issues it should be fixed in the drawing code, not as an
option in the interface.
Differential Revision: https://developer.blender.org/D15266
|
|
Since we reset the default theme for the 3.0 release, we don't need to
keep these version patches around anymore.
Ref D13131
|
|
The camera frame (used for selection) was drawn outside the near
clipping plane in those cases.
This has been an issue before as seen in the following commits:
- rB6e7e6832e87
- rB33d322873e6
- rB4f9451c0442
Remaining issue was that the code which ensure the frame isn't behind
the near clipping plane was not taking into account the camera could be
scaled (in Z).
A caller of `BKE_camera_view_frame_ex` (namely
`OVERLAY_camera_cache_populate`) applies scale (also on the depth) which
does not play well with the way `BKE_camera_view_frame_ex` did it.
Now take Z scale into account.
Ref D15178
|
|
Selection of Python Console renders in front of the text.
Since the default theme uses a low opacity selection color,
it isn't obvious, but increasing alpha to 100% shows it clearly.
Ref D13111
|
|
|
|
Rgression from: e6e9f1ac5a2d
Reviewed By: Brecht Van Lommel
Differential Revision: D15292
|
|
In perspective mode the snap point direction needs to be taken into
account to define which side of the face is being looked at.
If there is no face under the mouse cursor, there is no direction
adjustment and the element normal will be used.
|
|
Since 7afcfe111aac `startdisp` and `enddisp` fields are used as runtime
position storage for effect strips exclusively.
Use getter functon to return handle position and make properties read
only.
|
|
|
|
Caused by using `startdisp` and `enddisp` to initialize range.
Use handle position instead.
|