Skip to content

UI: Fix remigrating scene collections from absolute to relative - #11630

Merged
RytoEX merged 1 commit into
obsproject:release/31.0from
derrod:fix-remigration
Jan 8, 2025
Merged

RytoEX merged 1 commit into
obsproject:release/31.0from
derrod:fix-remigration

Conversation

@derrod

@derrod derrod commented Dec 14, 2024

Copy link
Copy Markdown
Member

Description

Fixes resetting scene collection base resolution to work again.

Motivation and Context

This was broken in #11055

How Has This Been Tested?

Locally.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)

Checklist:

  • My code has been run through clang-format.
  • I have read the contributing document.
  • My code is not on the master branch.
  • The code has been tested.
  • All commit messages are properly formatted and commits squashed where appropriate.
  • I have included updates to all appropriate documentation.

@WizardCM WizardCM added the kind/bug Categorizes issue or PR as related to a bug. label Dec 14, 2024
@WizardCM WizardCM added this to the OBS Studio 31 milestone Dec 15, 2024
@Lain-B

Lain-B commented Dec 15, 2024

Copy link
Copy Markdown
Collaborator

If we want to put this on a hotfix, we can merge this directly to a release branch if needed and not master, and then redo this for master after the UI changes are merged.

@Warchamp7

Copy link
Copy Markdown
Member

If we want to put this on a hotfix, we can merge this directly to a release branch if needed and not master, and then redo this for master after the UI changes are merged.

We should try to get this out in a hotfix for sure

@derrod
derrod changed the base branch from master to release/31.0 December 17, 2024 01:10
@RytoEX
RytoEX requested a review from Warchamp7 December 18, 2024 01:26
@PatTheMav

PatTheMav commented Dec 27, 2024 •

Copy link
Copy Markdown
Member

I'm fine with fixing it on the release branch like this to get the issue fixed, but on master we need to find a different way. Adding a whole argument to ActivateSceneCollection that is not used in the vast majority of scenarios and thus requires to be set to false by default more or less telegraphs that it's not the correct way to do this.

So instead of carrying a remigrate flag around that is forwarded from nested function call to nested function call and only ever really processed by OBSBasic::LoadData, the requirement to remigrate should be part of the data that is loaded - you mark the data as "stale", which can then be read and detected by LoadData which then dutifully does the remigration.

Because ultimately no other method but OBSBasic::LoadData cares about this detail, so this detail should not leak into the internal API and function signatures.

@RytoEX

RytoEX commented Jan 8, 2025

Copy link
Copy Markdown
Member

Echoing what @PatTheMav said above, we should look into a better way to fix this on master separately.

@RytoEX
RytoEX merged commit 248955b into obsproject:release/31.0 Jan 8, 2025
@derrod
derrod deleted the fix-remigration branch January 8, 2025 19:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

kind/bug Categorizes issue or PR as related to a bug.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants