Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix global handling of current tally data #718

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

KSauter
Copy link
Contributor

@KSauter KSauter commented Aug 20, 2024

During implementation of SimplyLive source (#717), i noticed some strange behaviour.

E.g. the tally state in the UI was not matching the state in the VMix emulator.
I traced it to some inconsistencies in the tally state update and linked bus logic.

This PR should fix any updateDevice logic and get rid of duplicated code for linked bus logic. This relies on the internal state which is computed by "UpdateDevice" to be accurate and can be used as SSOT for all other places where the current tally state of a device is used.

…viceTallyData as SSOT and rely on UpdateDeviceState to handle everything correcty. This will get triggered by the subscription of the `tally` property of all sources.
@josephdadams
Copy link
Owner

@Jocke4f can you help review this?

@Jocke4f
Copy link
Collaborator

Jocke4f commented Aug 24, 2024

The current code on master works for linked busses with device sources but not for Test Mode (linked busses were not properly handled). That is one error in the PR that earlier fixed the linked busses support.

Has this PR been tested with linked busses? I tested the code but it doesn't work for linked busses with sources nor with Test Mode. Perhaps my test was flawed but it didn't work for me.

@KSauter
Copy link
Contributor Author

KSauter commented Sep 5, 2024

I will double check.
Just to be sure how linked busses should work: A device can have more than one source, and if the device is linked to a bus, all sources for this device need to be in the recpective bus right?

@josephdadams
Copy link
Owner

yes

@josephdadams
Copy link
Owner

@KSauter @Jocke4f I'm in the middle of a PR adding a new source type and in the process have fixed several things related to bus options and how auxes etc. are referenced. There's been an overarching bug/design problem in TA for awhile now where instead of referring to the preview and program busses by their bus_option.id, we have been referencing them by the literal name preview and then doing a bus_option.type evaluation. This works ok for preview/program but when you look at the aux options, they all have the same type of aux.

I've switched over several places in the code to use the id instead of type, and have implemented a quick fix to replace preview with its actual bus_option.id (For example) which should allow all source types to work.

So please wait to merge this until that PR #726 is in place because it will affect some of what you have done here. Thanks!

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.

3 participants