feat(viewer): add recorded point colors and trajectory follow

This commit is contained in:
DCCONSTRUCTIONS
2026-07-23 13:33:08 +03:00
parent 9f712bf353
commit ecd95a22f0
16 changed files with 1218 additions and 36 deletions
+16 -2
View File
@@ -11,9 +11,9 @@ import threading
from collections.abc import Callable, Mapping
from dataclasses import dataclass
from pathlib import Path
from typing import Protocol
from typing import Literal, Protocol
from .models import ObservationSessionCandidate
from .models import ObservationSessionCandidate, ReplayCommand
RecordingProgressPulse = Callable[[], None]
RecordingExportResult = Mapping[str, object]
@@ -38,6 +38,19 @@ class RecordingExporter(Protocol):
) -> RecordingExportResult: ...
class RecordedPointColorRenderer(Protocol):
def __call__(
self,
command: ReplayCommand,
*,
application_id: str,
recording_id: str,
color_mode: Literal["intensity", "height", "distance", "rgb", "class"],
palette: Literal["turbo", "viridis", "plasma", "grayscale", "custom"],
custom_color: str,
) -> bytes: ...
ObservationArchiveDiscovery = Callable[
[Path],
tuple[ObservationSessionCandidate, ...],
@@ -66,3 +79,4 @@ class ObservationRuntimeContribution:
archives: tuple[ObservationArchiveSource, ...]
recording_exporter: RecordingExporter
point_color_renderer: RecordedPointColorRenderer | None = None