Implement GetDoubleSided and GetCullStyle for BlenderSceneDelegate #38

Merged
Bogdan Nagirniak merged 3 commits from BLEN-408 into hydra-render 2023-05-10 14:03:18 +02:00
2 changed files with 4 additions and 12 deletions
Showing only changes of commit dd65dafc15 - Show all commits

View File

@ -453,10 +453,6 @@ void BlenderSceneDelegate::add_new_objects()
Object *, Object *,
object) { object) {
if (!ObjectData::is_supported(object)) {
continue;
}
update_objects(object); update_objects(object);
update_instancers(object); update_instancers(object);
} }
@ -481,10 +477,9 @@ void BlenderSceneDelegate::remove_unused_objects()
&data, &data,
Object *, Object *,
object) { object) {
if (!ObjectData::is_supported(object)) { if (ObjectData::is_supported(object)) {
continue;
}
available_objects.insert(object_prim_id(object).GetName()); available_objects.insert(object_prim_id(object).GetName());
}
available_objects.insert(instancer_prim_id(object).GetName()); available_objects.insert(instancer_prim_id(object).GetName());
} }
ITER_END; ITER_END;
@ -561,10 +556,6 @@ void BlenderSceneDelegate::update_visibility()
Object *, Object *,
object) { object) {
if (!ObjectData::is_supported(object)) {
continue;
}
if (!object_data(object_prim_id(object))) { if (!object_data(object_prim_id(object))) {
update_objects(object); update_objects(object);
} }

View File

@ -64,7 +64,8 @@ void InstancerData::update()
ID_LOG(2, ""); ID_LOG(2, "");
Object *object = (Object *)id; Object *object = (Object *)id;
if (id->recalc & ID_RECALC_GEOMETRY || ((ID *)object->data)->recalc & ID_RECALC_GEOMETRY || if (id->recalc & ID_RECALC_GEOMETRY ||
(object->data && ((ID *)object->data)->recalc & ID_RECALC_GEOMETRY) ||
id->recalc & ID_RECALC_TRANSFORM) { id->recalc & ID_RECALC_TRANSFORM) {
set_instances(); set_instances();
scene_delegate_->GetRenderIndex().GetChangeTracker().MarkInstancerDirty( scene_delegate_->GetRenderIndex().GetChangeTracker().MarkInstancerDirty(