Quantcast
Channel: beginners - openFrameworks
Viewing all articles
Browse latest Browse all 4929

ofParameter and addListener confusion

$
0
0

@frauzufall wrote:

Hey all, I have this use case:

ofParameter<bool> b;
void changedB(bool& val);

Now I can do the following:

b.addListener(this, &ofApp::changedB);

but I can't call the same function using the parameter:

changedB(b);
changedB(b.get());

I have to do this:

bool b2 = b;
changedB(b2);

Am I missing something?

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 4929

Trending Articles