How can convert string to hex color ?

hi,

I just entered the wonderful world of openframewoks and it’s great.
But

I use ofxui addons and especially input_text.
I’m trying without success for several hours to convert a string from the input-text (“0xFFFFFF”) to an int colorHex explotable by ofsetcolor (0xFFFFFF).

if someone has an idea I gladly take.
Thanks

1 Like

ofHexToInt and friends can’t help you? http://www.openframeworks.cc/documentation/utils/ofUtils.html#show-ofHexToInt
http://www.openframeworks.cc/documentation/utils/ofUtils.html

1 Like

it seemed too simple to be true.
thank you for taking the time to answer a stupid question :-[
thank you very much :slight_smile:

You’re very welcome! If only all questions were as quick/easy to answer… :wink: