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

added ofParameter<ofColor> #106

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

added ofParameter<ofColor> #106

wants to merge 6 commits into from

Conversation

moebiussurfing
Copy link

added to addGroup too

@moebiussurfing
Copy link
Author

sorry, my pr is kind of dirty
because it's including some garbage..
but also added multicontext to allow multiple instances without crash on exit.…
are you interested on this?

Copy link
Collaborator

@prisonerjohn prisonerjohn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought you could just pass an ofColor already and it would automatically cast it to an ofFloatColor. Is that not working?

@moebiussurfing
Copy link
Author

hey @prisonerjohn , here, with the main branch is not working like this:
ofParameter<ofColor> myOfColor{ "myOfColor", ofColor::orange };
ofxImGui::AddParameter(this->myOfColor);

Showing All Errors Only
/openFrameworks/addons/ofxImGui/src/ImHelpers.h:164:66: No viable conversion from 'ofColor_<unsigned char>' to 'int'

@moebiussurfing
Copy link
Author

moebiussurfing commented Sep 26, 2020

also, when adding a paramGroup with some ofColor params, they are not added neither:

                ofParameterGroup g{"group"};
                g.add(myOfColor);
                g.add(myOfFLoatColor);
                ofxImGui::Settings settings;
                ofxImGui::AddGroup(g, settings);

Also, we get this warning:
[warning] AddGroup: Could not create GUI element for parameter myOfColor

On my PR code I have implemented both cases: add ofParameter<ofColor> and addGroup.

This happens too with ofParameter<string> when bundled into a group. Should be nice to add strings too. (to show the text, or as input text maybe...)
ofParameter<void> is neither implemented.

@Daandelange Daandelange added the legacy-version For issues releated to the older legacy code, before all the refactorings in the develop branch. label Jul 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
legacy-version For issues releated to the older legacy code, before all the refactorings in the develop branch.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants