ofJson - how to get working?

Can someone please explain how I can get ofJson to work with 0.9.8?

I downloaded the master branch and there is a file called ofjson.h, but I think I need json.hpp which does not exist.
I’m trying to run ofxHTTP which needs it.

TIA

There is a folder called jsonExample in master, examples/input_output/jsonExample, try to have a look there

1 Like

Thanks - unfortunately this did not work. I just get ‘unknown type ofjson’ if i try and build the example.
Also it does/t use json.h or json.hpp which is what ofxHTTP needs, and I can find no information about even after hours of searching and experimentation.

Hey,

json.hpp should be located :
openFrameworks-master/libs/json/include/json.hpp

alternatively, you can try to use some addons.

What is your set up?

Hi Pierre - thanks for the info.
openFrameworks-master/libs/json
This directory does not exist in the master I downloaded. Maybe I downloaded the ‘wrong’ master??

I’m on OSX 10.11.6 I use OF 0.9.8. which is working well apart from this json issue ( I need json for for ofxHTTP.)

is there an OF addon for json I can use instead?

If you want to use ofxHTTP with the openFrameworks release, just download the ofxHTTP stable branch (see the README.md). Same goes for ofxIO, etc.

Ahh thanks … I was trying to be too bleeding edge I guess :slight_smile:

1 Like