Skip to content

NAT-544: Add a pure Standard Input policy and planner - #165

Merged
eugene-mux merged 5 commits into
feature/nat-534-hevc-standard-ingestfrom
em/nat-544-standard-input-policy
Oct 16, 2026
Merged

eugene-mux merged 5 commits into
feature/nat-534-hevc-standard-ingestfrom
em/nat-544-standard-input-policy

Conversation

@eugene-mux

@eugene-mux eugene-mux commented Oct 1, 2026 •

Copy link
Copy Markdown

Summary

Add a pure Standard Input policy and planner that selects original upload, whole-file SDR conversion, or original-file fallback from normalized media facts and proven capabilities.

  • Apply resolution, codec, audio, and HDR rules with detailed compliance and fallback diagnostics.
  • Plan output within the selected bounds without upscaling, preserve timestamps unless proven resampling is needed, and select the first audio track.
  • Require source-specific conversion proof, including compliant AAC preparation and tone mapping. Pipeline integration follows separately.

Validation

  • All 86 unit tests pass in debug and release with JDK 17, including 66 policy/planner tests.
  • SDK and sample release builds, release lint-vital checks, and whitespace checks pass.
  • Tests cover planning decisions; device conversion and live ingest remain separate verification.

Note

Low Risk
New internal-only types and logic with no production call sites yet; behavior is heavily unit-tested and isolated from upload orchestration.

Overview
Introduces a pure, platform-agnostic Standard Input layer that turns normalized MediaFacts plus caller-supplied PlanningCapabilities into a StandardInputPlan: upload original, whole-file SDR conversion, or categorized fallback.

Policy (StandardInputPolicyEvaluator) applies Mux-published tier limits (aligned with Swift) across codec, resolution, frame rate, bitrates, GOP, pixel format, HDR (HEVC 10-bit 420 for HLG/PQ), audio, and edit lists—treating missing evidence as Unknown, not compliant.

Planner (StandardInputPlanner) wires InputStandardization / HdrHandling: preserves eligible HLG/PQ when compliant, tone-maps when requested, downscales within selected max resolution without upscaling (even-aligned dimensions), picks output cadence (preserve timestamps vs 30 fps resample), and gates conversion on explicit proof (decode/encode, per-requirement remediation, AAC preparation, tone mapping).

Adds shared test fixtures and 66+ unit tests for policy boundaries and planning edge cases (HDR, audio, capabilities, insufficient evidence). No upload pipeline integration in this PR.

Reviewed by Cursor Bugbot for commit e1131cc. Bugbot is set up for automated code reviews on this repo. Configure here.

@eugene-mux
eugene-mux marked this pull request as ready for review October 1, 2026 23:42
@eugene-mux
eugene-mux requested a review from a team as a code owner October 1, 2026 23:42
@eugene-mux
eugene-mux added this pull request to stack #166 October 1, 2026 23:42
@eugene-mux
eugene-mux requested a review from daytime-em October 1, 2026 23:42
@eugene-mux eugene-mux changed the title Add a pure Standard Input policy and planner NAT-544: Add a pure Standard Input policy and planner Oct 1, 2026
Base automatically changed from em/nat-543-standard-input-options to feature/nat-534-hevc-standard-ingest October 16, 2026 18:08
@eugene-mux
eugene-mux force-pushed the em/nat-544-standard-input-policy branch from 4123fb8 to e1131cc Compare October 16, 2026 18:08
@eugene-mux
eugene-mux merged commit 0cb8530 into feature/nat-534-hevc-standard-ingest Oct 16, 2026
1 of 2 checks passed
@github-actions github-actions Bot mentioned this pull request Nov 4, 2026
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