Repository navigation
Closed
Labels
claimedAn agent or person has claimed this; check the claim comment before starting
Description
Unit
Port the per-frame video output step decisions in libobs/obs-video.c.h to rust/obs-core, as a new module video_output_step, next to video_copy_plan (#2133). These decisions move:
update_active_state: which frame data to clear on a raw, GPU or any activation.stage_output_texture: which copy surfaces to stage (channel 0 only without GPU conversion, otherwisechannel_count), andtextures_copied.queue_frame:- whether to duplicate (no free texture, or a repeat frame with work queued) or queue a new frame;
- whether to copy (raw output active, or a repeat) or swap the encode textures;
- the returned count.
render_video: which convert textures and copy surfaces to use (raw or GPU), and whether to convert, encode and stage.output_frame: the texture ring (prev_texture, the wrap ofcur_texture) and whether a downloaded frame is output.
These stay in C:
- every
gs_*call; - the deques and
os_sem_post; - the texture-frame host calls, the shared-planes and GPU-encode-surface host queries (C passes their results),
download_frame's maps; - the mix list and its mutex.
Plan (one PR, separate commits)
- A behaviour-neutral move into
libobs/obs-video-output-step.c.h, as hidden functions. - Characterization in
test_video_output_step_steps. It covers:- every activation combination;
- staging with and without GPU conversion, for each channel count;
- the queue step for each queue state and repeat count;
- the ring wrap at
NUM_TEXTURES; - each render-step combination.
- RED, then GREEN: the safe Rust core plus shims, in a
libobs.ported-video-output-stepgroup. Exported symbols are unchanged. - Tier 3 parity against the original C: exhaustive over the flags and small counts, plus a proptest over full-range counts. Also a deliberate-break check and
port_comparisonnumbers.
These real-libobs tests must stay green on every lane:
test_video_output_formatstest_scaled_mix_alphatest_encoding_lag_rescaletest_video_output_plantest_video_copy_plan_stepstest_raw_output_video_reset- the GPU encoder tests that run on the host
Metadata
Metadata
Assignees
Labels
claimedAn agent or person has claimed this; check the claim comment before starting
Type
Projects
- StatusShow more project fieldsDone
Activity
rdoupe commentedon Oct 24, 2026
Claiming: #2165.
libobs: Move the per-frame video output step decisions into obs-video…
test: Characterize the per-frame video output step decisions
obs-core: Add Tier 1 tests for the video output step port
obs-core: Port the per-frame video output step decisions
obs-core: Check the video output step port against the C
docs: Record the video output step port
obs-core: Port the per-frame video output step decisions (obs-rust#2181)