Skip to content

feat: update file querying methods to support flat directory structur…#336

Merged
TzuHuanTai merged 2 commits into
mainfrom
feat/support-querying-timelapse-video-source
May 23, 2026
Merged

feat: update file querying methods to support flat directory structur…#336
TzuHuanTai merged 2 commits into
mainfrom
feat/support-querying-timelapse-video-source

Conversation

@TzuHuanTai

Copy link
Copy Markdown
Owner

…e for timelapse videos

Copilot AI review requested due to automatic review settings May 22, 2026 23:37
@TzuHuanTai TzuHuanTai force-pushed the feat/support-querying-timelapse-video-source branch from dc8a76c to 6b52e77 Compare May 22, 2026 23:39

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the RTC datachannel “query file” flow and filesystem utilities to support querying video files from either the existing nested recording directory layout (root/YYYYMMDD/HH/) or a flat directory layout intended for timelapse videos.

Changes:

  • Extend Conductor::SendFileResponse and QueryFileResponse sending to include a VideoMode to distinguish recording vs timelapse queries.
  • Replace “second newest file” lookup with Utils::FindLatestCompleteFile(...) and update older/time-based queries to accept a base_dir.
  • Add flat-layout handling paths in Utils::FindLatestCompleteFile, FindFilesFromDatetime, and FindOlderFiles.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 4 comments.

File Description
src/rtc/conductor.h Updates SendFileResponse signature to include video mode.
src/rtc/conductor.cpp Routes queries to mode-specific base directories and includes mode in responses.
src/common/utils.h Renames/extends file-query utility APIs to accept a base directory and adds FindLatestCompleteFile.
src/common/utils.cpp Implements flat vs nested directory handling for latest/older/time-based file queries.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/rtc/conductor.cpp
Comment thread src/common/utils.cpp
Comment thread src/common/utils.cpp Outdated
Comment thread src/common/utils.cpp
@TzuHuanTai TzuHuanTai merged commit 0e65804 into main May 23, 2026
7 checks passed
@TzuHuanTai TzuHuanTai deleted the feat/support-querying-timelapse-video-source branch May 23, 2026 00:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants