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

Reading and saving ofVec2f / ofVec4f from ofxXmlSettings

$
0
0

@SebastianSobotka wrote:

Hi,
Is there an easy way to get a vector value from XML file?

I would like to have:

declaration in ofApp.h
ofVec4f vec;

setup in ofApp.cpp
settings.loadFile("settings.xml");

settings.xml

<settings>
<something>116, 32, 767, 511</something>
</settings>

It works for int and float but not for vectors..
vec = settings.getValue("settings:something", ofVec4f(0,0,0,0));

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 4929

Trending Articles