Merge branch 'blender-v4.0-release'
This commit is contained in:
@@ -550,6 +550,11 @@ CacheReader *CacheReader_open_usd_object(CacheArchiveHandle *handle,
|
||||
|
||||
pxr::UsdPrim prim = archive->stage()->GetPrimAtPath(pxr::SdfPath(object_path));
|
||||
|
||||
if (!prim) {
|
||||
WM_reportf(RPT_WARNING, "USD Import: unable to open cache reader for object %s", object_path);
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
if (reader) {
|
||||
USD_CacheReader_free(reader);
|
||||
}
|
||||
|
||||
@@ -44,6 +44,10 @@ static void node_geo_exec(GeoNodeExecParams params)
|
||||
if (Mesh *mesh = geometry.get_mesh_for_write()) {
|
||||
switch (domain) {
|
||||
case ATTR_DOMAIN_POINT:
|
||||
/* Remove attributes in case they are on the wrong domain, which can happen after
|
||||
* conversion to and from other geometry types. */
|
||||
mesh->attributes_for_write().remove(".select_edge");
|
||||
mesh->attributes_for_write().remove(".select_poly");
|
||||
bke::try_capture_field_on_geometry(geometry.get_component_for_write<MeshComponent>(),
|
||||
".select_vert",
|
||||
ATTR_DOMAIN_POINT,
|
||||
@@ -51,6 +55,10 @@ static void node_geo_exec(GeoNodeExecParams params)
|
||||
BKE_mesh_flush_select_from_verts(mesh);
|
||||
break;
|
||||
case ATTR_DOMAIN_FACE:
|
||||
/* Remove attributes in case they are on the wrong domain, which can happen after
|
||||
* conversion to and from other geometry types. */
|
||||
mesh->attributes_for_write().remove(".select_vert");
|
||||
mesh->attributes_for_write().remove(".select_edge");
|
||||
bke::try_capture_field_on_geometry(geometry.get_component_for_write<MeshComponent>(),
|
||||
".select_poly",
|
||||
ATTR_DOMAIN_FACE,
|
||||
|
||||
Reference in New Issue
Block a user