Fix #116249: Compositor: Gizmos ignore backdrop transformations #119025
|
@ -2075,6 +2075,8 @@ class USERPREF_PT_extensions_repos(Panel):
|
|||
paths = context.preferences.filepaths
|
||||
active_repo_index = paths.active_extension_repo
|
||||
|
||||
layout.label(text="Repositories")
|
||||
|
||||
row = layout.row()
|
||||
|
||||
row.template_list(
|
||||
|
|
|
@ -325,6 +325,8 @@ void mesh_calc_edges(Mesh &mesh, bool keep_existing_edges, bool select_new_edges
|
|||
|
||||
void mesh_flip_faces(Mesh &mesh, const IndexMask &selection);
|
||||
|
||||
void mesh_ensure_required_data_layers(Mesh &mesh);
|
||||
|
||||
/** Set mesh vertex normals to known-correct values, avoiding future lazy computation. */
|
||||
void mesh_vert_normals_assign(Mesh &mesh, Span<float3> vert_normals);
|
||||
|
||||
|
|
|
@ -5467,6 +5467,8 @@ void CustomData_blend_read(BlendDataReader *reader, CustomData *data, const int
|
|||
|
||||
BLO_read_data_address(reader, &data->external);
|
||||
|
||||
blender::Map<void *, const ImplicitSharingInfo *> sharing_info_by_data;
|
||||
|
||||
int i = 0;
|
||||
while (i < data->totlayer) {
|
||||
CustomDataLayer *layer = &data->layers[i];
|
||||
|
@ -5477,12 +5479,24 @@ void CustomData_blend_read(BlendDataReader *reader, CustomData *data, const int
|
|||
layer->sharing_info = nullptr;
|
||||
|
||||
if (CustomData_verify_versions(data, i)) {
|
||||
layer->sharing_info = BLO_read_shared(reader, &layer->data, [&]() {
|
||||
blend_read_layer_data(reader, *layer, count);
|
||||
return layer->data ? make_implicit_sharing_info_for_layer(
|
||||
eCustomDataType(layer->type), layer->data, count) :
|
||||
nullptr;
|
||||
});
|
||||
layer->sharing_info = BLO_read_shared(
|
||||
reader, &layer->data, [&]() -> const ImplicitSharingInfo * {
|
||||
blend_read_layer_data(reader, *layer, count);
|
||||
if (layer->data == nullptr) {
|
||||
return nullptr;
|
||||
}
|
||||
const ImplicitSharingInfo *sharing_info = sharing_info_by_data.lookup_default(
|
||||
layer->data, nullptr);
|
||||
if (sharing_info != nullptr) {
|
||||
sharing_info->add_user();
|
||||
}
|
||||
else {
|
||||
sharing_info = make_implicit_sharing_info_for_layer(
|
||||
eCustomDataType(layer->type), layer->data, count);
|
||||
sharing_info_by_data.add(layer->data, sharing_info);
|
||||
}
|
||||
return sharing_info;
|
||||
});
|
||||
i++;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -4224,47 +4224,62 @@ bool BKE_lib_override_library_property_operation_operands_validate(
|
|||
return true;
|
||||
}
|
||||
|
||||
void BKE_lib_override_library_validate(Main * /*bmain*/, ID *id, ReportList *reports)
|
||||
void BKE_lib_override_library_validate(Main *bmain, ID *id, ReportList *reports)
|
||||
{
|
||||
if (id->override_library == nullptr) {
|
||||
if (!ID_IS_OVERRIDE_LIBRARY(id)) {
|
||||
return;
|
||||
}
|
||||
|
||||
ID *liboverride_id = id;
|
||||
IDOverrideLibrary *liboverride = id->override_library;
|
||||
if (ID_IS_OVERRIDE_LIBRARY_VIRTUAL(id)) {
|
||||
liboverride = BKE_lib_override_library_get(bmain, id, nullptr, &liboverride_id);
|
||||
if (!liboverride) {
|
||||
/* Happens in case the given ID is a liboverride-embedded one (actual embedded ID like
|
||||
* NodeTree or master collection, or shapekeys), used by a totally not-liboverride owner ID.
|
||||
* Just clear the relevant ID flag.
|
||||
*/
|
||||
id->flag &= ~LIB_EMBEDDED_DATA_LIB_OVERRIDE;
|
||||
return;
|
||||
}
|
||||
}
|
||||
BLI_assert(liboverride);
|
||||
|
||||
/* NOTE: In code deleting liboverride data below, #BKE_lib_override_library_make_local is used
|
||||
* instead of directly calling #BKE_lib_override_library_free, because the former also handles
|
||||
* properly 'liboverride embedded' IDs, like root node-trees, or shape-keys. */
|
||||
|
||||
if (id->override_library->reference == nullptr) {
|
||||
if (liboverride->reference == nullptr) {
|
||||
/* This (probably) used to be a template ID, could be linked or local, not an override. */
|
||||
BKE_reportf(reports,
|
||||
RPT_WARNING,
|
||||
"Library override templates have been removed: removing all override data from "
|
||||
"the data-block '%s'",
|
||||
id->name);
|
||||
BKE_lib_override_library_make_local(nullptr, id);
|
||||
liboverride_id->name);
|
||||
BKE_lib_override_library_make_local(nullptr, liboverride_id);
|
||||
return;
|
||||
}
|
||||
if (id->override_library->reference == id) {
|
||||
if (liboverride->reference == liboverride_id) {
|
||||
/* Very serious data corruption, cannot do much about it besides removing the liboverride data.
|
||||
*/
|
||||
BKE_reportf(reports,
|
||||
RPT_ERROR,
|
||||
"Data corruption: data-block '%s' is using itself as library override reference, "
|
||||
"removing all override data",
|
||||
id->name);
|
||||
BKE_lib_override_library_make_local(nullptr, id);
|
||||
liboverride_id->name);
|
||||
BKE_lib_override_library_make_local(nullptr, liboverride_id);
|
||||
return;
|
||||
}
|
||||
if (!ID_IS_LINKED(id->override_library->reference)) {
|
||||
if (!ID_IS_LINKED(liboverride->reference)) {
|
||||
/* Very serious data corruption, cannot do much about it besides removing the liboverride data.
|
||||
*/
|
||||
BKE_reportf(reports,
|
||||
RPT_ERROR,
|
||||
"Data corruption: data-block '%s' is using another local data-block ('%s') as "
|
||||
"library override reference, removing all override data",
|
||||
id->name,
|
||||
id->override_library->reference->name);
|
||||
BKE_lib_override_library_make_local(nullptr, id);
|
||||
liboverride_id->name,
|
||||
liboverride->reference->name);
|
||||
BKE_lib_override_library_make_local(nullptr, liboverride_id);
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -4274,7 +4289,7 @@ void BKE_lib_override_library_main_validate(Main *bmain, ReportList *reports)
|
|||
ID *id;
|
||||
|
||||
FOREACH_MAIN_ID_BEGIN (bmain, id) {
|
||||
if (id->override_library != nullptr) {
|
||||
if (ID_IS_OVERRIDE_LIBRARY(id)) {
|
||||
BKE_lib_override_library_validate(bmain, id, reports);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -465,6 +465,41 @@ bool BKE_mesh_has_custom_loop_normals(Mesh *mesh)
|
|||
return CustomData_has_layer(&mesh->corner_data, CD_CUSTOMLOOPNORMAL);
|
||||
}
|
||||
|
||||
namespace blender::bke {
|
||||
|
||||
void mesh_ensure_default_color_attribute_on_add(Mesh &mesh,
|
||||
const AttributeIDRef &id,
|
||||
AttrDomain domain,
|
||||
eCustomDataType data_type)
|
||||
{
|
||||
if (id.is_anonymous()) {
|
||||
return;
|
||||
}
|
||||
if (!(CD_TYPE_AS_MASK(data_type) & CD_MASK_COLOR_ALL) ||
|
||||
!(ATTR_DOMAIN_AS_MASK(domain) & ATTR_DOMAIN_MASK_COLOR))
|
||||
{
|
||||
return;
|
||||
}
|
||||
if (mesh.default_color_attribute) {
|
||||
return;
|
||||
}
|
||||
mesh.default_color_attribute = BLI_strdupn(id.name().data(), id.name().size());
|
||||
}
|
||||
|
||||
void mesh_ensure_required_data_layers(Mesh &mesh)
|
||||
{
|
||||
MutableAttributeAccessor attributes = mesh.attributes_for_write();
|
||||
AttributeInitConstruct attribute_init;
|
||||
|
||||
/* Try to create attributes if they do not exist. */
|
||||
attributes.add("position", AttrDomain::Point, CD_PROP_FLOAT3, attribute_init);
|
||||
attributes.add(".edge_verts", AttrDomain::Edge, CD_PROP_INT32_2D, attribute_init);
|
||||
attributes.add(".corner_vert", AttrDomain::Corner, CD_PROP_INT32, attribute_init);
|
||||
attributes.add(".corner_edge", AttrDomain::Corner, CD_PROP_INT32, attribute_init);
|
||||
}
|
||||
|
||||
} // namespace blender::bke
|
||||
|
||||
void BKE_mesh_free_data_for_undo(Mesh *mesh)
|
||||
{
|
||||
mesh_free_data(&mesh->id);
|
||||
|
@ -656,41 +691,6 @@ MutableSpan<MDeformVert> Mesh::deform_verts_for_write()
|
|||
this->verts_num};
|
||||
}
|
||||
|
||||
namespace blender::bke {
|
||||
|
||||
void mesh_ensure_default_color_attribute_on_add(Mesh &mesh,
|
||||
const AttributeIDRef &id,
|
||||
AttrDomain domain,
|
||||
eCustomDataType data_type)
|
||||
{
|
||||
if (id.is_anonymous()) {
|
||||
return;
|
||||
}
|
||||
if (!(CD_TYPE_AS_MASK(data_type) & CD_MASK_COLOR_ALL) ||
|
||||
!(ATTR_DOMAIN_AS_MASK(domain) & ATTR_DOMAIN_MASK_COLOR))
|
||||
{
|
||||
return;
|
||||
}
|
||||
if (mesh.default_color_attribute) {
|
||||
return;
|
||||
}
|
||||
mesh.default_color_attribute = BLI_strdupn(id.name().data(), id.name().size());
|
||||
}
|
||||
|
||||
static void mesh_ensure_cdlayers_primary(Mesh &mesh)
|
||||
{
|
||||
MutableAttributeAccessor attributes = mesh.attributes_for_write();
|
||||
AttributeInitConstruct attribute_init;
|
||||
|
||||
/* Try to create attributes if they do not exist. */
|
||||
attributes.add("position", AttrDomain::Point, CD_PROP_FLOAT3, attribute_init);
|
||||
attributes.add(".edge_verts", AttrDomain::Edge, CD_PROP_INT32_2D, attribute_init);
|
||||
attributes.add(".corner_vert", AttrDomain::Corner, CD_PROP_INT32, attribute_init);
|
||||
attributes.add(".corner_edge", AttrDomain::Corner, CD_PROP_INT32, attribute_init);
|
||||
}
|
||||
|
||||
} // namespace blender::bke
|
||||
|
||||
Mesh *BKE_mesh_new_nomain(const int verts_num,
|
||||
const int edges_num,
|
||||
const int faces_num,
|
||||
|
@ -705,7 +705,7 @@ Mesh *BKE_mesh_new_nomain(const int verts_num,
|
|||
mesh->faces_num = faces_num;
|
||||
mesh->corners_num = corners_num;
|
||||
|
||||
blender::bke::mesh_ensure_cdlayers_primary(*mesh);
|
||||
blender::bke::mesh_ensure_required_data_layers(*mesh);
|
||||
BKE_mesh_face_offsets_ensure_alloc(mesh);
|
||||
|
||||
return mesh;
|
||||
|
@ -827,7 +827,7 @@ Mesh *BKE_mesh_new_nomain_from_template_ex(const Mesh *me_src,
|
|||
|
||||
/* The destination mesh should at least have valid primary CD layers,
|
||||
* even in cases where the source mesh does not. */
|
||||
blender::bke::mesh_ensure_cdlayers_primary(*me_dst);
|
||||
blender::bke::mesh_ensure_required_data_layers(*me_dst);
|
||||
BKE_mesh_face_offsets_ensure_alloc(me_dst);
|
||||
if (do_tessface && !CustomData_get_layer(&me_dst->fdata_legacy, CD_MFACE)) {
|
||||
CustomData_add_layer(&me_dst->fdata_legacy, CD_MFACE, CD_SET_DEFAULT, me_dst->totface_legacy);
|
||||
|
|
|
@ -1347,13 +1347,11 @@ void UI_view2d_dot_grid_draw(const View2D *v2d,
|
|||
int count_x;
|
||||
float start_x;
|
||||
|
||||
/* Count points that fit in viewport minus space for the scroll-bars. */
|
||||
grid_axis_start_and_count(
|
||||
step, v2d->cur.xmin, v2d->cur.xmax - V2D_SCROLL_WIDTH, &start_x, &count_x);
|
||||
/* Count points that fit in viewport. */
|
||||
grid_axis_start_and_count(step, v2d->cur.xmin, v2d->cur.xmax, &start_x, &count_x);
|
||||
int count_y;
|
||||
float start_y;
|
||||
grid_axis_start_and_count(
|
||||
step, v2d->cur.ymin + V2D_SCROLL_HEIGHT, v2d->cur.ymax, &start_y, &count_y);
|
||||
grid_axis_start_and_count(step, v2d->cur.ymin, v2d->cur.ymax, &start_y, &count_y);
|
||||
if (count_x == 0 || count_y == 0) {
|
||||
continue;
|
||||
}
|
||||
|
|
|
@ -1112,9 +1112,14 @@ int seq_effect_find_selected(Scene *scene,
|
|||
seq2 = SEQ_select_active_get(scene);
|
||||
}
|
||||
|
||||
if (SEQ_effect_get_num_inputs(type) == 0) {
|
||||
*r_selseq1 = *r_selseq2 = *r_selseq3 = nullptr;
|
||||
return 1;
|
||||
}
|
||||
|
||||
LISTBASE_FOREACH (Sequence *, seq, ed->seqbasep) {
|
||||
if (seq->flag & SELECT) {
|
||||
if (seq->type == SEQ_TYPE_SOUND_RAM && SEQ_effect_get_num_inputs(type) != 0) {
|
||||
if (seq->type == SEQ_TYPE_SOUND_RAM) {
|
||||
*r_error_str = N_("Cannot apply effects to audio sequence strips");
|
||||
return 0;
|
||||
}
|
||||
|
@ -1145,9 +1150,6 @@ int seq_effect_find_selected(Scene *scene,
|
|||
}
|
||||
|
||||
switch (SEQ_effect_get_num_inputs(type)) {
|
||||
case 0:
|
||||
*r_selseq1 = *r_selseq2 = *r_selseq3 = nullptr;
|
||||
return 1; /* Success. */
|
||||
case 1:
|
||||
if (seq2 == nullptr) {
|
||||
*r_error_str = N_("At least one selected sequence strip is needed");
|
||||
|
|
|
@ -201,6 +201,8 @@ static void rna_Mesh_clear_geometry(Mesh *mesh)
|
|||
BKE_mesh_clear_geometry_and_metadata(mesh);
|
||||
BKE_animdata_free(&mesh->id, false);
|
||||
|
||||
blender::bke::mesh_ensure_required_data_layers(*mesh);
|
||||
|
||||
DEG_id_tag_update(&mesh->id, ID_RECALC_GEOMETRY_ALL_MODES);
|
||||
WM_main_add_notifier(NC_GEOM | ND_DATA, mesh);
|
||||
}
|
||||
|
|
|
@ -2159,7 +2159,7 @@ void rna_Node_update(Main *bmain, Scene * /*scene*/, PointerRNA *ptr)
|
|||
ED_node_tree_propagate_change(nullptr, bmain, ntree);
|
||||
}
|
||||
|
||||
static void rna_Node_update_relations(Main *bmain, Scene *scene, PointerRNA *ptr)
|
||||
void rna_Node_update_relations(Main *bmain, Scene *scene, PointerRNA *ptr)
|
||||
{
|
||||
rna_Node_update(bmain, scene, ptr);
|
||||
DEG_relations_tag_update(bmain);
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
|
||||
void rna_Node_update(Main *bmain, Scene *scene, PointerRNA *ptr);
|
||||
void rna_Node_socket_update(Main *bmain, Scene *scene, PointerRNA *ptr);
|
||||
void rna_Node_update_relations(Main *bmain, Scene *scne, PointerRNA *ptr);
|
||||
|
||||
namespace blender::nodes {
|
||||
|
||||
|
|
|
@ -11,7 +11,7 @@ namespace blender::nodes::node_fn_rotate_vector_cc {
|
|||
static void node_declare(NodeDeclarationBuilder &b)
|
||||
{
|
||||
b.is_function_node();
|
||||
b.add_input<decl::Vector>("Vector");
|
||||
b.add_input<decl::Vector>("Vector").is_default_link_socket();
|
||||
b.add_input<decl::Rotation>("Rotation");
|
||||
b.add_output<decl::Vector>("Vector");
|
||||
};
|
||||
|
|
|
@ -33,6 +33,13 @@ void search_link_ops_for_tool_node(GatherLinkSearchOpParams ¶ms)
|
|||
}
|
||||
}
|
||||
|
||||
void search_link_ops_for_volume_grid_node(GatherLinkSearchOpParams ¶ms)
|
||||
{
|
||||
if (U.experimental.use_new_volume_nodes) {
|
||||
nodes::search_link_ops_for_basic_node(params);
|
||||
}
|
||||
}
|
||||
|
||||
namespace enums {
|
||||
|
||||
const EnumPropertyItem *attribute_type_type_with_socket_fn(bContext * /*C*/,
|
||||
|
|
|
@ -32,6 +32,7 @@ namespace blender::nodes {
|
|||
|
||||
bool check_tool_context_and_error(GeoNodeExecParams ¶ms);
|
||||
void search_link_ops_for_tool_node(GatherLinkSearchOpParams ¶ms);
|
||||
void search_link_ops_for_volume_grid_node(GatherLinkSearchOpParams ¶ms);
|
||||
|
||||
void get_closest_in_bvhtree(BVHTreeFromMesh &tree_data,
|
||||
const VArray<float3> &positions,
|
||||
|
|
|
@ -160,7 +160,7 @@ static void node_rna(StructRNA *srna)
|
|||
{0, nullptr, 0, nullptr, nullptr},
|
||||
};
|
||||
|
||||
RNA_def_node_enum(
|
||||
PropertyRNA *prop = RNA_def_node_enum(
|
||||
srna,
|
||||
"transform_space",
|
||||
"Transform Space",
|
||||
|
@ -168,6 +168,7 @@ static void node_rna(StructRNA *srna)
|
|||
rna_node_geometry_collection_info_transform_space_items,
|
||||
NOD_storage_enum_accessors(transform_space),
|
||||
GEO_NODE_TRANSFORM_SPACE_ORIGINAL);
|
||||
RNA_def_property_update_runtime(prop, rna_Node_update_relations);
|
||||
}
|
||||
|
||||
static void node_register()
|
||||
|
|
|
@ -16,7 +16,6 @@
|
|||
#include "BKE_volume_grid.hh"
|
||||
|
||||
#include "NOD_rna_define.hh"
|
||||
#include "NOD_socket_search_link.hh"
|
||||
|
||||
#include "UI_interface.hh"
|
||||
#include "UI_resources.hh"
|
||||
|
@ -83,13 +82,6 @@ static void node_update(bNodeTree *ntree, bNode *node)
|
|||
bke::nodeSetSocketAvailability(ntree, sock_threshold, mode == DistributeMode::Grid);
|
||||
}
|
||||
|
||||
static void node_gather_link_search_ops(GatherLinkSearchOpParams ¶ms)
|
||||
{
|
||||
if (U.experimental.use_new_volume_nodes) {
|
||||
nodes::search_link_ops_for_basic_node(params);
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef WITH_OPENVDB
|
||||
/* Implements the interface required by #openvdb::tools::NonUniformPointScatter. */
|
||||
class PositionsVDBWrapper {
|
||||
|
@ -276,7 +268,7 @@ static void node_register()
|
|||
ntype.declare = node_declare;
|
||||
ntype.geometry_node_execute = node_geo_exec;
|
||||
ntype.draw_buttons = node_layout;
|
||||
ntype.gather_link_search_ops = node_gather_link_search_ops;
|
||||
ntype.gather_link_search_ops = search_link_ops_for_volume_grid_node;
|
||||
nodeRegisterType(&ntype);
|
||||
|
||||
node_rna(ntype.rna_ext.srna);
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
#include "RNA_enum_types.hh"
|
||||
|
||||
#include "NOD_rna_define.hh"
|
||||
#include "NOD_socket_search_link.hh"
|
||||
|
||||
#include "UI_interface.hh"
|
||||
#include "UI_resources.hh"
|
||||
|
@ -34,13 +33,6 @@ static void node_declare(NodeDeclarationBuilder &b)
|
|||
b.add_output(eNodeSocketDatatype(node->custom1), "Grid");
|
||||
}
|
||||
|
||||
static void search_link_ops(GatherLinkSearchOpParams ¶ms)
|
||||
{
|
||||
if (U.experimental.use_new_volume_nodes) {
|
||||
nodes::search_link_ops_for_basic_node(params);
|
||||
}
|
||||
}
|
||||
|
||||
static void node_layout(uiLayout *layout, bContext * /*C*/, PointerRNA *ptr)
|
||||
{
|
||||
uiLayoutSetPropSep(layout, true);
|
||||
|
@ -103,7 +95,7 @@ static void node_register()
|
|||
geo_node_type_base(&ntype, GEO_NODE_GET_NAMED_GRID, "Get Named Grid", NODE_CLASS_GEOMETRY);
|
||||
|
||||
ntype.declare = node_declare;
|
||||
ntype.gather_link_search_ops = search_link_ops;
|
||||
ntype.gather_link_search_ops = search_link_ops_for_volume_grid_node;
|
||||
ntype.draw_buttons = node_layout;
|
||||
ntype.initfunc = node_init;
|
||||
ntype.geometry_node_execute = node_geo_exec;
|
||||
|
|
|
@ -9,8 +9,6 @@
|
|||
|
||||
#include "GEO_randomize.hh"
|
||||
|
||||
#include "NOD_socket_search_link.hh"
|
||||
|
||||
#include "node_geometry_util.hh"
|
||||
|
||||
namespace blender::nodes::node_geo_grid_to_mesh_cc {
|
||||
|
@ -25,13 +23,6 @@ static void node_declare(NodeDeclarationBuilder &b)
|
|||
b.add_output<decl::Geometry>("Mesh");
|
||||
}
|
||||
|
||||
static void node_gather_link_search_ops(GatherLinkSearchOpParams ¶ms)
|
||||
{
|
||||
if (U.experimental.use_new_volume_nodes) {
|
||||
nodes::search_link_ops_for_basic_node(params);
|
||||
}
|
||||
}
|
||||
|
||||
static void node_geo_exec(GeoNodeExecParams params)
|
||||
{
|
||||
#ifdef WITH_OPENVDB
|
||||
|
@ -59,7 +50,7 @@ static void node_register()
|
|||
geo_node_type_base(&ntype, GEO_NODE_GRID_TO_MESH, "Grid to Mesh", NODE_CLASS_GEOMETRY);
|
||||
ntype.declare = node_declare;
|
||||
ntype.geometry_node_execute = node_geo_exec;
|
||||
ntype.gather_link_search_ops = node_gather_link_search_ops;
|
||||
ntype.gather_link_search_ops = search_link_ops_for_volume_grid_node;
|
||||
nodeRegisterType(&ntype);
|
||||
}
|
||||
NOD_REGISTER_NODE(node_register)
|
||||
|
|
|
@ -7,8 +7,6 @@
|
|||
|
||||
#include "GEO_mesh_to_volume.hh"
|
||||
|
||||
#include "NOD_socket_search_link.hh"
|
||||
|
||||
#include "node_geometry_util.hh"
|
||||
|
||||
namespace blender::nodes::node_geo_mesh_to_density_grid_cc {
|
||||
|
@ -33,13 +31,6 @@ static void node_declare(NodeDeclarationBuilder &b)
|
|||
b.add_output<decl::Float>("Density Grid");
|
||||
}
|
||||
|
||||
static void node_gather_link_search_ops(GatherLinkSearchOpParams ¶ms)
|
||||
{
|
||||
if (U.experimental.use_new_volume_nodes) {
|
||||
nodes::search_link_ops_for_basic_node(params);
|
||||
}
|
||||
}
|
||||
|
||||
static void node_geo_exec(GeoNodeExecParams params)
|
||||
{
|
||||
#ifdef WITH_OPENVDB
|
||||
|
@ -70,7 +61,7 @@ static void node_register()
|
|||
&ntype, GEO_NODE_MESH_TO_DENSITY_GRID, "Mesh to Density Grid", NODE_CLASS_GEOMETRY);
|
||||
ntype.declare = node_declare;
|
||||
ntype.geometry_node_execute = node_geo_exec;
|
||||
ntype.gather_link_search_ops = node_gather_link_search_ops;
|
||||
ntype.gather_link_search_ops = search_link_ops_for_volume_grid_node;
|
||||
nodeRegisterType(&ntype);
|
||||
}
|
||||
NOD_REGISTER_NODE(node_register)
|
||||
|
|
|
@ -7,8 +7,6 @@
|
|||
|
||||
#include "GEO_mesh_to_volume.hh"
|
||||
|
||||
#include "NOD_socket_search_link.hh"
|
||||
|
||||
#include "node_geometry_util.hh"
|
||||
|
||||
namespace blender::nodes::node_geo_mesh_to_sdf_grid_cc {
|
||||
|
@ -29,13 +27,6 @@ static void node_declare(NodeDeclarationBuilder &b)
|
|||
b.add_output<decl::Float>("SDF Grid");
|
||||
}
|
||||
|
||||
static void node_gather_link_search_ops(GatherLinkSearchOpParams ¶ms)
|
||||
{
|
||||
if (U.experimental.use_new_volume_nodes) {
|
||||
nodes::search_link_ops_for_basic_node(params);
|
||||
}
|
||||
}
|
||||
|
||||
static void node_geo_exec(GeoNodeExecParams params)
|
||||
{
|
||||
#ifdef WITH_OPENVDB
|
||||
|
@ -64,7 +55,7 @@ static void node_register()
|
|||
geo_node_type_base(&ntype, GEO_NODE_MESH_TO_SDF_GRID, "Mesh to SDF Grid", NODE_CLASS_GEOMETRY);
|
||||
ntype.declare = node_declare;
|
||||
ntype.geometry_node_execute = node_geo_exec;
|
||||
ntype.gather_link_search_ops = node_gather_link_search_ops;
|
||||
ntype.gather_link_search_ops = search_link_ops_for_volume_grid_node;
|
||||
nodeRegisterType(&ntype);
|
||||
}
|
||||
NOD_REGISTER_NODE(node_register)
|
||||
|
|
|
@ -126,13 +126,14 @@ static void node_rna(StructRNA *srna)
|
|||
{0, nullptr, 0, nullptr, nullptr},
|
||||
};
|
||||
|
||||
RNA_def_node_enum(srna,
|
||||
"transform_space",
|
||||
"Transform Space",
|
||||
"The transformation of the vector and geometry outputs",
|
||||
rna_node_geometry_object_info_transform_space_items,
|
||||
NOD_storage_enum_accessors(transform_space),
|
||||
GEO_NODE_TRANSFORM_SPACE_ORIGINAL);
|
||||
PropertyRNA *prop = RNA_def_node_enum(srna,
|
||||
"transform_space",
|
||||
"Transform Space",
|
||||
"The transformation of the vector and geometry outputs",
|
||||
rna_node_geometry_object_info_transform_space_items,
|
||||
NOD_storage_enum_accessors(transform_space),
|
||||
GEO_NODE_TRANSFORM_SPACE_ORIGINAL);
|
||||
RNA_def_property_update_runtime(prop, rna_Node_update_relations);
|
||||
}
|
||||
|
||||
static void node_register()
|
||||
|
|
|
@ -1245,7 +1245,7 @@ static ImBuf *seq_render_movie_strip(const SeqRenderData *context,
|
|||
SeqRenderData localcontext = *context;
|
||||
localcontext.view_id = view_id;
|
||||
|
||||
if (view_id != context->view_id) {
|
||||
if (view_id != context->view_id && ibuf_arr[view_id]) {
|
||||
ibuf_arr[view_id] = seq_render_preprocess_ibuf(
|
||||
&localcontext, seq, ibuf_arr[view_id], timeline_frame, true, false);
|
||||
}
|
||||
|
|
|
@ -257,7 +257,7 @@ static void index_dir_set(Editing *ed, Sequence *seq, StripAnim *sanim)
|
|||
seq_proxy_index_dir_set(sanim->anim, proxy_dirpath);
|
||||
}
|
||||
|
||||
static bool open_anim_file_multiview(Scene *scene, Sequence *seq, char *filepath, bool openfile)
|
||||
static bool open_anim_file_multiview(Scene *scene, Sequence *seq, char *filepath)
|
||||
{
|
||||
char prefix[FILE_MAX];
|
||||
const char *ext = nullptr;
|
||||
|
@ -277,10 +277,11 @@ static bool open_anim_file_multiview(Scene *scene, Sequence *seq, char *filepath
|
|||
SNPRINTF(filepath_view, "%s%s%s", prefix, suffix, ext);
|
||||
|
||||
StripAnim *sanim = static_cast<StripAnim *>(MEM_mallocN(sizeof(StripAnim), "Strip Anim"));
|
||||
open_anim_filepath(seq, sanim, filepath_view, openfile);
|
||||
/* Multiview files must be loaded, otherwise it is not possible to detect failure. */
|
||||
open_anim_filepath(seq, sanim, filepath_view, true);
|
||||
|
||||
if (sanim->anim == nullptr) {
|
||||
MEM_freeN(sanim);
|
||||
SEQ_relations_sequence_free_anim(seq);
|
||||
return false; /* Multiview render failed. */
|
||||
}
|
||||
|
||||
|
@ -313,7 +314,7 @@ void seq_open_anim_file(Scene *scene, Sequence *seq, bool openfile)
|
|||
bool multiview_is_loaded = false;
|
||||
|
||||
if (is_multiview) {
|
||||
multiview_is_loaded = open_anim_file_multiview(scene, seq, filepath, openfile);
|
||||
multiview_is_loaded = open_anim_file_multiview(scene, seq, filepath);
|
||||
}
|
||||
|
||||
if (!is_multiview || !multiview_is_loaded) {
|
||||
|
|
Loading…
Reference in New Issue