Age | Commit message (Collapse) | Author |
|
Textures may be important to be able to identify an object. They are also a way
to make many objects look more like when rendered with an advanced render
engine, without being that expensive.
So this seems like a simple way to increase usefulness of the automatic
previews.
|
|
Now the operators work like other areas of Blender using the list of selected objects.
Also, the name has been changed to:
```Layers:
- Copy Layer to Selected
- Copy All Layers to Selected
Materials:
- Copy Material to Selected
- Copy All Materials to Selected```
Reviewed By: mendio, pablovazquez, pepeland
Differential Revision: https://developer.blender.org/D11216
|
|
All other access to the Base structure from Python was removed,
it seems this was left in by accident.
Ref T85675
|
|
Small addition inspired by [this tweet](https://twitter.com/Vorundor/status/1390645286624763909) of a user in a situation I also saw myself in the past.
Showing "(Clipped)" next to the view name in the `Text Info` overlay fits well since it's a per-viewport setting.
{F10059921, size=full}
While on Local view:
{F10059925, size=full}
Multiple viewports:
{F10059946, size=full}
Reviewed By: Severin
Differential Revision: https://developer.blender.org/D11193
|
|
|
|
Previously the option in the camera's //Object Data Properties > Viewport Display
> Sensor// would not display the sensor in camera view. This seemed to be caused
by the theme color `TH_VIEW_OVERLAY` having zero set for the alpha channel and
alpha blending being active, resulting in no visible output. Hence
`immUniformThemeColorShade(TH_VIEW_OVERLAY, 100);` is replaced with
`immUniformThemeColorShadeAlpha(TH_VIEW_OVERLAY, 100, 255);`.
Reviewed By: mano-wii
Differential Revision: https://developer.blender.org/D11075
|
|
In some cases functions were defined with arguments of different array
lengths in headers vs. implementations. This commit fixes some of the
cases I ran into, but probably not all of them.
|
|
The grid plane was drawn too big on retina displays compared to other screens,
because the factor was multiplied by the native pixel-size, which is 2 for
Retina displays.
|
|
|
|
values in 'Adjust Last Operation'
Always use the defaults here (radius, depth etc), since desired bounds
have been set interactively, it does not make sense to use a different
value from a previous command.
The Cube tool has already seen a fix for this in rB26e5718e29a7, but
Cone/UVSphere/Cylinder/IcoSphere havent.
Maniphest Tasks: T87677
Differential Revision: https://developer.blender.org/D11038
|
|
|
|
gizmo_button2d_bounds result wasn't valid when the gizmo was part
of a 3D gizmo group.
Regression in cf6d17a6aa421e0038fc1f8e60e3f1f708887c3e
|
|
|
|
For Measure tool, it is more useful to snap to what is really visible.
So use the cage instead of the geometry that may be hidden with Bmesh.
|
|
This allows the addition of the `SNAP_GEOM_CAGE` option.
Currently unused.
|
|
It is important to limit the pixels read on `BLI_array_iter_spiral_square`.
Fortunately `ED_view3d_depth_read_cached` was not being called with a
`margin` parameter.
Wrong logic introduced in rB44c76e4ce310.
|
|
It is important to limit the pixels read on `BLI_array_iter_spiral_square`.
Fortunately `ED_view3d_depth_read_cached` was not being called with a
`margin` parameter.
Wrong logic introduced in rB44c76e4ce310.
|
|
Differential Revision: https://developer.blender.org/D10968
Reviewed by Julian Eisel
|
|
|
|
This adds the ability to get a selection list for both edit mode bones
and pose mode bones.
To do this the selection menu list logic had to be reworked a bit.
Before it only stored the names of objects. This might work will of
objects, however as stated in the code, it might fail for linked objects
(so multiple object can have the same name in some corner cases).
For bones it is a very common occurance where you can have multiple
armature that has the same bone names. So now it also stores the object
and bone pointers for this case.
Reviewed By: Sybren
Differential Revision: http://developer.blender.org/D10570
Fix T85796
|
|
Matches the alternative function ED_view3d_autodist_depth, but is more
efficient since it uses the cache.
No functional changes.
|
|
The non-enabled gizmo was overwriting the projected coordinate value.
|
|
This simplifies the addition of future improvements.
Also make it more practical to expose as a parameter of gizmo for Python.
|
|
'orient_type'
`orient_index` is a more comprehensive value as it reveals both the type and index.
Differential Revision: https://developer.blender.org/D9595
|
|
This fixes T86440
As the CU_2D flag is set for nurbs, a Curve can have 2D nurbs mixed with 3D.
But the UI does not allow this mixing. It updates all nurbs to 2D or 3D when set.
So remove this specific flag for nurbs.
This may break old files, since 2D curves with mixed 3D are now set as 3D.
Differential Revision: https://developer.blender.org/D10738
|
|
Flag check for V3D_LOCK_CAMERA used boolean style assignment to a char,
which worked with this flag but could fail if other flags are added
that use this convention in the future.
- Add static type checks for values so any change to DNA types
will need to be made in the navigation gizmo too.
- Move camera lock check from `rv3d` to `v3d`,
as this isn't stored in the region data.
|
|
2D gizmo navigation button that toggles 'Lock Camera to View' while in Camera View.
Differential Revision: https://developer.blender.org/D10835
Reviewed by Campbell Barton
|
|
Now `ED_view3d_backbuf_depth_validate`, `ED_view3d_draw_depth` and
`ED_view3d_draw_depth_gpencil` are unified in `ED_view3d_depth_override`.
This new function replaces `ED_view3d_autodist_init`.
Also, since `ED_view3d_depth_update` depends on the render context, and
changing the context is a slow operation, that function also was removed,
and the depth buffer cached is now updated inside the new unified drawing
function when the "bool update_cache" parameter is true.
Finally `V3D_INVALID_BACKBUF` flag has been renamed and moved to
`runtime.flag`.
Differential revision: https://developer.blender.org/D10678
|
|
No functional changes.
This makes the `ED_gizmotypes_snap_3d_update` function more specialized.
|
|
The meaning of the return value wasn't obvious.
|
|
Although it works well in most cases, the algorithm to detect if a point
is within the limits of the camera does not work well in othographic mode.
This commit also adds the option `V3D_PROJ_TEST_CLIP_FAR` (currently unused).
Differential Revision: https://developer.blender.org/D10771
|
|
Outliner uses a lot `NC_ID | NA_EDITED` e.g., which was not caught by
the View3D editor for update.
|
|
Since {rB46aa70cb486d}, using `NC_SPACE | ND_SPACE_VIEW3D` as notifier is
restricted to space data as a reference. This was still used though for
RNA updates in other places (namely `rna_camera`, `rna_scene`,
`rna_animviz`), and passing NULL would automatically set the notifier
reference to the owner id. Above commit would happily filter these out,
leading to missing refreshes.
Now use more specific notifiers (in case of animviz a new
`ND_DRAW_ANIMVIZ` was added).
This was reported for Camera background images btw.
Fixes T86670.
Maniphest Tasks: T86670
Differential Revision: https://developer.blender.org/D10758
|
|
|
|
|
|
When adding a notifier, `reference` data can be passed. The notifier system
uses this to filter out listeners, for example if data of a scene changes,
windows showing a different scene won't get the notifiers sent to their
listeners.
For the `NC_SPACE` notifiers, a number of places also passed the space as
`reference`, but that wasn't used at all. The notifier would still be sent to
all listeners in all windows (and the listeners didn't use it either). Causing
some unnecessary updates (e.g. see ed2c4825d3e2344).
With this commit, passing a space will make sure the notifier is only sent to
that exact space. Some code seems to already have expected that to be the case.
However there were some cases that passed the space as `reference` without
reason, which would break with this commit (meaning they wouldn't redraw or
update correctly).
Corrected these so they don't pass the space anymore.
|
|
The Tool stores desired dimensions as `scale` and thus had to half the
scale again in `make_prim_init()` because by default all primitives are
created at a size of 2 in blender.
This worked, but:
- [1] it logged something like size=2, scale=2,2,2 for a 2x2x2 cube
[which does not sound right, it should be size=2 scale=1,1,1]
- [2] it had to make an exception for the case scale is exactly 1x1x1
[this happens when the property is not set specifically, e.g. adding
primitives from the menu]
-- this exception led to double sized primitives being created when the
tool asked for exact dimensions of 1x1x1
Now - instead of compensating in `make_prim_init()` - do this earlier in
the tool itself, see `view3d_interactive_add_modal`, this fixes the bug
and now also correctly logs size=2 scale 0.5,0.5,0.5 for a 1x1x1 cube.
Maniphest Tasks: T86347
Differential Revision: https://developer.blender.org/D10632
|
|
Used for local structs/variables,
since `ofs` is by far the most widely used abbreviation.
|
|
Changes include using proper and consistent grammar, simplifying
phrasing, using correct terminology, and not including python API
identifiers in tooltips.
Differential Revision: https://developer.blender.org/D9924
|
|
|
|
|
|
When dropping an asset somewhere, it is appended and then a drop operation is
called to actually add it to the scene based on current context. If this drop
operation fails, the appended data-block is now still in the .blend. The user
may not notice and not expect this.
Instead idea is to rollback any changes done by dropping code if the operation
fails, namely removing the appended data-block again.
Adds a new `cancel()` callback which is called if the drop operator returns
`OPERATOR_CANCELLED` to drop-boxes and a generic function to deal with assets
on drop failure.
Also removes the `free_id_on_error` property of the `NODE_OT_add_group`
operator, which was used as ad-hoc solution to get this same behavior.
|
|
|
|
|
|
|
|
While this could be useful, it's been removed since 2.4x, keeping this
here doesn't help add it back since it would need to be re-implemented.
|
|
|
|
The previous behavior meant that changing an objects visibility
effectively changed the current mode - which missed necessary
updates for the tool-system (for example).
There was already a check for edit-mode, now expected to all modes.
This makes the test-case described in T83013 work as expected.
|
|
|
|
Caused by rB5b34d11b55e0.
Above commit restored the view matrices in ED_view3d_draw_offscreen
_before_ they can be stored in the ImBuff (see ED_view3d_draw_offscreen
/ texture_paint_image_from_view_exec).
Now make restoring the view matrices optional and dont do this in case
of reprojection, so the used matrices can still be saved in the ImBuff
later.
Reviewed By: campbellbarton
Maniphest Tasks: T85395
Differential Revision: https://developer.blender.org/D10331
|