mirror_virtual_camera — DRIVE decide op

• Data kinds: any → table

• Call: import fullseye as fs; fs.ledger.mirror_virtual_camera(cam_pose, mirror_plane) -> 'Dict[str, object]' (to call the implementation directly, import drivedecide; drivedecide.mirror_virtual_camera(cam_pose, mirror_plane) -> 'Dict[str, object]'; from the registry, opsdrive.get("mirror_virtual_camera"))

Usage

A virtual camera that captures the image seen in a plane mirror.

cam_pose is the world→camera 4×4 (convention of render3d.look_at: X_cam = P X, −Z forward). mirror_plane is (n_x, n_y, n_z, d) (n·X = d).

Return value (dict):

• reflection: the reflection S (mirror_reflection_matrix).

• pose_mirrored = P·S: rendering the real scene with this gives exactly the image the real camera sees through the mirror (identical down to pixel positions). The determinant of the rotation part is −1 (a left-right reversed coordinate system; depending on the renderer, front/back face determination is inverted).

• pose = F·P·S, F = diag(−1, 1, 1, 1): an ordinary right-handed camera (determinant +1) = the virtual camera behind the mirror. An image taken with it is the left-right flip of the image in the mirror (in pixels u' = 2c_x − u). Use this when treating a rear-view mirror as "a rear-facing camera" (flip left-right to get back the image the driver sees).

• eye: position of the virtual camera S(C) (C = position of the real camera). eye_real: C.

• flip: "x" (flipping x of the pose image gives the mirror image).

Closed form: S(X) = X − 2(n·X − d)n. The image of a point Q seen in the mirror is at S(Q) (on the far side of the mirror, at the same distance from the mirror surface). Gate (test): solve numerically for the point M on the mirror that satisfies angle of incidence = angle of reflection (Fermat's shortest path), and check that C + (|CM| + |MQ|)·unit(M − C) coincides with S(Q).

References (sample data, literature)

• Sample-data catalog (download URLs / licences) — 2-D uses skimage.data (BSD/public domain) plus synthetic images; 3-D lists download URLs for real data sources (Stanford, PDS, …).

• Operator provenance and references — the sources of the research/methods this op family came from.

• The canonical algorithm (author, year) and its uses are named in the family usage guide above.

Runnable examples (verified samples that actually call this op)

• poc_driving_decisions — py -3.11 examples/poc_driving_decisions.py

Ops the type connects to (they accept table as input)

course_layout · course_occupancy · course_contains · world_build · world_camera · world_move · lidar_scan · rss_longitudinal_same

Same category (decide)

mirror_reflection_matrix · mirror_aim_normal · convex_mirror_fov · mirror_blind_zone · check_sequence_score · signal_phase_plan · signal_state · predict_amber_onset


*Provenance: drivedecide.py — DRIVE operator registry. This per-op note is generated by tools/opdocs.py md (do not hand-edit).*

© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.