frauzufall / ofxGuiExtended

ofParameter based GUI addon for openFrameworks; derived from the core OF ofxGui addon and ofxDOM.
MIT License
112 stars 29 forks source link

ofxGuiElement.h failing to build osx #49

Closed HardwareHaquer closed 7 years ago

HardwareHaquer commented 7 years ago

I am using the nightly build of OF for OSX and after finding a few missing libraries like Poco I have gotten the basic gui extended example to build except for one final issue that has stumped me. The error is tied to the ofSerialize() and ofDeserialize() methods and the saveTo() and loadFrom() methods that pass either an ofXML object or ofJSON object to those functions. It appears that it is a conversion error between ofXML and ofJson objects but I don't know how to fix it. Thanks for your time!

Below are the errors I am receiving:

No matching function call to ofSerialize

/Users/astewart/Developer/of_v20161102_osx_release/libs/openFrameworks/utils/ofJson.h:55:13: Candidate function not viable: no known conversion from 'ofXml' to 'ofJson &' (aka 'basic_json<> &') for 1st argument

/Users/astewart/Developer/of_v20161102_osx_release/addons/ofxGuiExtended/src/ofxGuiElement.cpp:437:3: In instantiation of function template specialization 'ofxGuiElement::saveTo' requested here

No Matching function call to ofDeserialize

/Users/astewart/Developer/of_v20161102_osx_release/addons/ofxGuiExtended/src/ofxGuiElement.cpp:465:3: In instantiation of function template specialization 'ofxGuiElement::loadFrom' requested here

/Users/astewart/Developer/of_v20161102_osx_release/libs/openFrameworks/utils/ofJson.h:76:13: Candidate function not viable: no known conversion from 'ofXml' to 'const ofJson' (aka 'const basic_json<>') for 1st argument

HardwareHaquer commented 7 years ago

Update. Just installed openFrameworks in Ubuntu in VirtualBox and got to the same issue. QtCreator's error output point to the same issues. Also had to add Poco to src folder for addon like on OSX.

frauzufall commented 7 years ago

Hey, the missing serialization functions were removed from OF and are now back there, so please update the OF repository (master branch), that should fix it! If you also update this addon, you don't need Poco anymore (I rewrote that part) Thanks for reporting and write me if there are more problems.