Repository navigation
obs-core: Port borrowed canvas video getter (#3945) - #3946
Merged
Merged
Conversation
zackees
force-pushed
the
port/3945-canvas-video-getter
branch
from
November 7, 2026 23:21
4e67d02 to
ce499a4
Compare
zackees
marked this pull request as ready for review
November 7, 2026 23:22
zackees
enabled auto-merge
November 7, 2026 23:22
This was referenced Nov 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Ports obs_canvas_get_video to obs-core, preserving the absent-mix and NULL-video results, exact borrowed pointer identity, and the original non-NULL canvas contract. It acquires no lock or reference and leaves canvas, mix, and token state unchanged. Video-info and channel lookup remain in C and outside this slice. There are no intended behavior or ABI changes.
Fixes #3945, a native child of #444. This follows the patterns in #3863 and #3943 without touching their branches.
Commit sequence: actual-library C characterization 8e5d037, separate building verbatim extraction 7021759, Tier 1 RED e9dc9fc, Rust GREEN 67168af, and allocation-backed oracle fixture correction ce499a4. RED fails the borrowed-video characterization at its intended stub with exit 101. The corrected C characterization was replayed at the C-only point and after extraction, and remains byte-for-byte unchanged throughout the Rust swap.
Rust owns the absent-mix selection. Two private C adapters expose only field addresses from the real canvas and mix layouts. The oracle includes the original getter and automatically discovered adapter; it calls no production libobs function. Real-header checks measure field-view size, alignment, and every field offset, plus the stored output pointer size and alignment. The new native registration entry selects only its own target. All new Rust cases belong to the existing Core state test executable.
Validation completed on the rebased tree:
Evidence artifacts are under /home/niteris/.clud/tmp/tool-output/local-test-private/: local-test-qLKVjD.log is the corrected C-only baseline; local-test-Ufvtve.log is extraction; local-test-gikvxp.log is original RED; local-test-wyXfKo.log contains the corrected four-test pass and the recorded native ETXTBSY failure; local-test-wFTNhI.log is its isolated pass; local-test-w8OfIx.log contains the successful full native-module rerun, obs-util, final both-library Tier 2, and full lint. Corrected mutation evidence is local-test-53PhWy.log.
Test cost: 25 reduced-parity debug runs per new module. Tier 1 longest 0.012 seconds, peak RSS 11,092 KiB; layout/parity longest 0.017 seconds, peak RSS 15,776 KiB. Neither module starts its own threads; generated data and allocations are bounded.
The complete Tier 2 suite, full unittest entry point, native Windows/macOS runtimes, and local-gate attestation were not run. Tier 4 is inapplicable to this getter. Hosted PR CI remains the merge gate. Public headers, existing upstream C tests, WebSocket, workflows, and other workers' branches are unchanged. No feature-ledger entry applies to this behavior-preserving port.