aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/argaze/ArFeatures.py41
1 files changed, 22 insertions, 19 deletions
diff --git a/src/argaze/ArFeatures.py b/src/argaze/ArFeatures.py
index 0314466..a2343f9 100644
--- a/src/argaze/ArFeatures.py
+++ b/src/argaze/ArFeatures.py
@@ -1336,38 +1336,41 @@ class ArCamera(ArFrame):
# Edit aoi matcher exclude attribute to ignore frame aoi
for layer_name, layer in self.layers.items():
- if layer.aoi_scan_path is not None:
+ expected_aoi_list = []
+ exclude_aoi_list = []
- expected_aoi_list = []
- exclude_aoi_list = []
+ for scene_name, scene in self.__scenes.items():
- for scene_name, scene in self.__scenes.items():
+ # Append scene layer aoi to corresponding expected camera layer aoi
+ try:
- # Append scene layer aoi to corresponding expected camera layer aoi
- try:
+ scene_layer = scene.layers[layer_name]
- scene_layer = scene.layers[layer_name]
+ expected_aoi_list.extend(list(scene_layer.aoi_scene.keys()))
- expected_aoi_list.extend(list(scene_layer.aoi_scene.keys()))
+ except KeyError:
- except KeyError:
+ continue
- continue
+ # Remove scene frame from expected camera layer aoi
+ # Exclude scene frame from camera layer aoi matching
+ for frame_name, frame in scene.frames.items():
- # Remove scene frame from expected camera layer aoi
- # Exclude scene frame from camera layer aoi matching
- for frame_name, frame in scene.frames.items():
+ try:
+
+ expected_aoi_list.remove(frame_name)
+ exclude_aoi_list.append(frame_name)
- try:
-
- expected_aoi_list.remove(frame_name)
- exclude_aoi_list.append(frame_name)
+ except ValueError:
- except ValueError:
+ continue
- continue
+ if layer.aoi_scan_path is not None:
layer.aoi_scan_path.expected_aoi = expected_aoi_list
+
+ if layer.aoi_matcher is not None:
+
layer.aoi_matcher.exclude = exclude_aoi_list
@property