-
-
Notifications
You must be signed in to change notification settings - Fork 36
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
Refactor Vignette.Camera #235
Conversation
throw new ArgumentException($"The item {item} already exists in this {nameof(FluentDropdown<T>)}."); | ||
{ | ||
/* throw new ArgumentException($"The item {item} already exists in this {nameof(FluentDropdown<T>)}."); */ | ||
System.Console.WriteLine($"\x1b[33mWarning: item {item} already exists in this {nameof(FluentDropdown<T>)}. Not adding it again.\x1b[0m"); |
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.
Use the Runtime log instead
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.
Done :v
Now I've got another problem... It's not detecting my webcam and it says that it "can't open camera by index":
|
This might be relevant to the problem: opencv/opencv#19527 |
Maybe doing this is provides a better solution as it removes the need to modify the fluent dropdown to be softer on duplicates.
Welp, time to rewrite this |
Welp, time to not rewrite this |
I'm gonna care about the reimplementation of Vignette.Camera for Encore 1. For now, I think I can focus on the "can't open camera by index" bug. There might be a problem with |
I'll close this now since this will not be part of the Debut codebase, just remake what you did once we have the Stride code public :D |
No no, wait! I just need to rename the pull request. I originally renamed it "Refactor Vignette.Camera" because I wanted to shift to implementing an FFmpeg version, but we still have to fix the webcam duplication and "can't open camera by index" bug. I can do it without a lot of rewrite in this PR. |
Do it on another PR if that's the intent, we can't do it in this one since it's main context is replacing the backend and fixing the bugs. |
That is its second context, which wasn't even really engaged in any significant modifications in the code fortunately. |
This PR fixes issue #234.
The previous solution that I've implemented is simply not adding a duplicate item in the FluentDropdown, and warning about it with a console write statement.
Now, the solution is indexing the friendly names so that all options pop up.
We're now faced with a "can't open camera by index" bug.