Skip to content

SetSceneItemTransform: accept 0 bounds while boundsType is OBS_BOUNDS_NONE - #9

Merged
zackees merged 1 commit into
masterfrom
fix/540-bounds-none
Oct 13, 2026
Merged

zackees merged 1 commit into
masterfrom
fix/540-bounds-none

Conversation

@zackees

@zackees zackees commented Oct 13, 2026

Copy link
Copy Markdown
Member

Fixes obs-rust/obs-studio#540 (upstream obsproject/obs-websocket#1299). Bounds minimum is 0 when the effective bounds type (request, else the item's) is OBS_BOUNDS_NONE, 1 otherwise. Test: test_ws_transform_bounds in obs-rust/obs-studio (RED 2 fail, GREEN 4 pass).

…_NONE

GetSceneItemTransform reports 0x0 bounds for an item whose bounds are unused
(OBS_BOUNDS_NONE), and SetSceneItemTransform refused them with 402 because
boundsWidth/boundsHeight had to be at least 1 whatever the bounds type. Take
the minimum from the effective bounds type (from the request, else the item's):
0 when unused, 1 when in use.

Refs obs-rust/obs-studio#540, obsproject/obs-websocket#1299
@zackees
zackees merged commit a4040cb into master Oct 13, 2026
1 check passed
zackees pushed a commit to rdoupe/obs-studio that referenced this pull request Oct 13, 2026
GetSourceScreenshot labelled its data URL "image/" plus the requested
format name, but the names are Qt image writer names (file extensions),
so "jpg" came back as "data:image/jpg", which is not a MIME type, and
"ppm" as "data:image/ppm". obs-rust/obs-websocket#6 maps the writer's
format names to their registered types with a fixed table (no
dependency on the system's MIME data).

Move the submodule from a4040cb (obs-rust/obs-websocket#9) to 3e46553,
the merge of obs-rust#6 on top of it, and add test_ws_image_mime, which builds
the helper from the plugin source on its own: 4 of 5 cases fail against
the fork's helper-only commit and all 5 pass here.

Reported upstream in obsproject/obs-websocket#1298 by cmack.

Fixes obs-rust#523.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Local-Gate: v1 tree=0bda6cde7d6d43558b289e6a4c5657ba5b79a390 secs=511 lanes=lint:run,rust-test:run,cross:run,tier2-linux:run
Ci-Attestation: {"at":1791932642,"gate":"rust/all/fmt","host":"linux-x86_64","key":"56712ff4f494234c658dde9bf072511f27f83b32e5258647edaa0960ff822b1e","lane":"lint","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":36,"stamp":"7a0219afa75b08288667d44530d9d3dc","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-unknown-linux-gnu/clippy","host":"linux-x86_64","key":"56712ff4f494234c658dde9bf072511f27f83b32e5258647edaa0960ff822b1e","lane":"lint","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":36,"stamp":"a28fdc6843d0a6a1efb8f56c1c23226c","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-unknown-linux-gnu/test","host":"linux-x86_64","key":"0a26a3da188ac6df7cacddf394b31ac8aee4f17722f8fcfb7e16f16c6545607d","lane":"rust-test","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":188,"stamp":"648509e8d3aa287a22e48e49b3d4b8c4","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-pc-windows-msvc/clippy","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"7a9f0013c352502c3d51ad804772dad6","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-pc-windows-msvc/dylint","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"e20920cba594d6cff6c18eaa58f06dda","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/aarch64-apple-darwin/clippy","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"97a31be153dbb8d7326d6ca770662db7","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/aarch64-apple-darwin/dylint","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"fcccde5645d69a4439666be55bb76a20","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-apple-darwin/clippy","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"a281400a7593e0cc03ff5597876b023f","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-apple-darwin/dylint","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"6bbeb0ed509658dbfbb9c9f55bad2381","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"cpp/linux-x64/tier2","host":"linux-x86_64","key":"1b19e58298733d30e063360d21c4f9aada312536ef6a1ce1e471a24ff8dd5d5c","lane":"tier2-linux","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"d422d5aa241f41f79924b3f80fbea575","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
swilk19 pushed a commit to swilk19/obs-studio that referenced this pull request Oct 13, 2026
…REEN)

Points plugins/obs-websocket at obs-rust/obs-websocket master a4040cb
(obs-rust/obs-websocket#9). test_ws_transform_bounds passes, 4 of 4.

Fixes obs-rust#540
zackees added a commit to obs-rust/obs-studio that referenced this pull request Oct 13, 2026
GetSourceScreenshot labelled its data URL "image/" plus the requested
format name, but the names are Qt image writer names (file extensions),
so "jpg" came back as "data:image/jpg", which is not a MIME type, and
"ppm" as "data:image/ppm". obs-rust/obs-websocket#6 maps the writer's
format names to their registered types with a fixed table (no
dependency on the system's MIME data).

Move the submodule from a4040cb (obs-rust/obs-websocket#9) to 3e46553,
the merge of #6 on top of it, and add test_ws_image_mime, which builds
the helper from the plugin source on its own: 4 of 5 cases fail against
the fork's helper-only commit and all 5 pass here.

Reported upstream in obsproject/obs-websocket#1298 by cmack.

Fixes #523.


Local-Gate: v1 tree=0bda6cde7d6d43558b289e6a4c5657ba5b79a390 secs=511 lanes=lint:run,rust-test:run,cross:run,tier2-linux:run
Ci-Attestation: {"at":1791932642,"gate":"rust/all/fmt","host":"linux-x86_64","key":"56712ff4f494234c658dde9bf072511f27f83b32e5258647edaa0960ff822b1e","lane":"lint","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":36,"stamp":"7a0219afa75b08288667d44530d9d3dc","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-unknown-linux-gnu/clippy","host":"linux-x86_64","key":"56712ff4f494234c658dde9bf072511f27f83b32e5258647edaa0960ff822b1e","lane":"lint","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":36,"stamp":"a28fdc6843d0a6a1efb8f56c1c23226c","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-unknown-linux-gnu/test","host":"linux-x86_64","key":"0a26a3da188ac6df7cacddf394b31ac8aee4f17722f8fcfb7e16f16c6545607d","lane":"rust-test","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":188,"stamp":"648509e8d3aa287a22e48e49b3d4b8c4","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-pc-windows-msvc/clippy","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"7a9f0013c352502c3d51ad804772dad6","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-pc-windows-msvc/dylint","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"e20920cba594d6cff6c18eaa58f06dda","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/aarch64-apple-darwin/clippy","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"97a31be153dbb8d7326d6ca770662db7","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/aarch64-apple-darwin/dylint","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"fcccde5645d69a4439666be55bb76a20","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-apple-darwin/clippy","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"a281400a7593e0cc03ff5597876b023f","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"rust/x86_64-apple-darwin/dylint","host":"linux-x86_64","key":"31e220a9f75224a0652e009c7cefda6842c7b689923577113c66ea6c038bbc7f","lane":"cross","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"6bbeb0ed509658dbfbb9c9f55bad2381","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}
Ci-Attestation: {"at":1791932642,"gate":"cpp/linux-x64/tier2","host":"linux-x86_64","key":"1b19e58298733d30e063360d21c4f9aada312536ef6a1ce1e471a24ff8dd5d5c","lane":"tier2-linux","parents":["b2557dea89bc3f730d829ca66241fa9e1d46a9aa"],"secs":143,"stamp":"d422d5aa241f41f79924b3f80fbea575","tree":"0bda6cde7d6d43558b289e6a4c5657ba5b79a390","v":1,"via":"run"}

Co-authored-by: Claude Opus 5.5 <[email protected]>
Co-authored-by: Zachary Vorhies <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

1 participant