-
-
Notifications
You must be signed in to change notification settings - Fork 419
Show user why NDI output failed #1148
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
Conversation
|
I like the idea of this being added, please @paulpv or @Trouffman check it |
|
Thanks for the extensive PR. I see we could re-use the pixel format detection as well if one day we can use the advanced SDK. |
|
I think it is possible to add a method to set the last error to the OutputSetting dialog and display that string instead when the dialog is displayed. I can redo that part. |
|
Added bb765a9 to the branch and the PR. I removed the LastError from the config. Ended up adding last_error to the main-output context and making the last error message accessible from output-settings. Also added translations for all the locales we support. I keyed off the phrase "Color Format" which is the name of the field the user changes. So the error message should point the user to what caused the error. |
|
I am looking into a way to keep the user from turning on main output if the color format not supported. |
|
After this latest commit ef7e0ec , the main output box is only enabled if the pixel format of the main output is supported by the NDI SDK. If it is not supported, the main output box is disabled and an error message appears showing why main output cannot be chosen. |
|
Thank you for updating the behavior on this. Next : testing & QC. |
|
I just found a bug while investigating another behavior. Documented bug at : #1180 |
|
@BitRate27 I merged from the latest master, please review to confirm that this still has the intended purpose. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Issue found : This is "Stopping" the Main Output when opening the DistroAV Settings and is not re-created if "cancelled".
Expected Behavior : The stream should NOT stop until there is a need for:
- Stopping (aka not enabled)
- Name or group name changed
All above only after the form has been submitted.
Error log shows : info: Output 'NDI Main Output': stopping
|
This is what happen when opening the NDI Settings dialog box : This is because of the logic for This should be triggered only when loading a new profile / starting OBS and not everytime the NDI Settings are opened. Other after testing :
|
|
Thanks for looking at this. You brought up some good issues with this implementation. Clearly I need to rethink the logic here. I think we need to initialize a test output instead of using the main output. Not sure how to only show the "last error" row in the dialog if no error. Suggestions welcome. Here are the scenarios:
|
|
Update: was able to alter the main_output_is_supported to check without using main output. Also, figured out how to set the message height to zero if no error message. Only thing left is to work on the LOG_INFO and LOG_DEBUG messages. All tests in the scenarios above passed. Will also squash the branch to one commit as this went through a lot of changes. |
|
Tested on Windows 11+ OBS 31 after the latest merge :
Seem our logic here is not polished enough. EDIT : Seems my test system was not behaving properly. Will need to re-do test fully. When wiping out my test OBS and re-using the one from this PR built. it did work as expected |
|
Looks like the one scenario I didnt list above. Will check it out. Thanks! |
|
Tests results on MacOS 15.4 Scenarios : -> OK -> OK -> OK -> OK ->ok but UI space for error not reverted |
|
Tests results on Windows 11 Scenarios : -> OK -> OK -> OK -> OK ->ok |
|
Tests results on Ubuntu 24.04 Scenarios : -> OK -> OK -> OK -> OK ->ok Where I have found an issue : Not sure when/where this is overlooked. |
(?) How do you turn off main output with this new code if the format is not supported? The checkbox should not be sensitive. Note: I could do this with this sequence: Operates properly (main output terminated) |
|
I could reproduce on Mac with this :
I think this need to be clear-er on the approach we take:
Option 1. would touch the configuration file |
|
@BitRate27 This PR is proving to be more complex than expected. While doing the review I found a couple extra comment (not blocking but would be good to have at some point)
ie. : in
This did not create issues when testing, hopefully this would stay this way but having a clear "testing name" might help to identify in error log as well. We could put it in a group called "DistroAV Config" so this does not even show up anywhere when testing.
This PR brings a lot of value as it will help for the support and anyone using HDR pixel format. |
|
Disabling main output in the config if the format is not supported, keeps the toggle in sync with the main output status in OBS. Also, moving the check for support into the main_output_init allows us to turn it off if not supported and enabled. Finally, with the output enabled in sync with the OBS main output state, main_output_init is only called when settings of main output are changed. I verified the original scenarios still work, and the new scenario performs as it should. Also added a LOG_INFO message to let the user know the output was disabled because the format is not supported. |
|
Great! Thank you. I updated the INFO to a WARNING and attributed ID 426 to easily flag it too. |

When the user selects a color format of P010, I010, P216 or P416, the output will not be started because the NDI SDK does not support HDR color formats. The only indication this is a problem is by looking for "unsupported pixel format" in the log file. To make it easier for the user to identify the problem, we will now report the last error in the DistroAV NDI Settings dialog for the main output.
This message will be seen when the user goes back to the settings dialog after noticing there is no NDI output.
This does not happen for preview or dedicated NDI output from a filter, so no changes were needed for those outputs.
In order to test and utilize this new message, this PR also fixes #1147 where OBS crashes after you have tried to output an unsupported format.
The problem existed because an output would be created even when no main output was selected. When the user went to change the color format, in the OBS Settings->Advanced dialog, this would invalidate the video output in DistroAV NDI Settings. Then when main output was turned back on, OBS would crash because output->video is corrupted.
This makes the changes to main-output look big but it was mainly removing an indented if condition. In summary we always call main_output_deinit in main_output_init, and then if it is not enabled, we return, otherwise we create the output and start it every time it is enabled.
Tested on Windows by testing that all formats gave the correct message if unsupported, or blank if supported.