We are about to switch to a new forum software. Until then we have removed the registration on this forum.
Hi all
I am new to processing, and am trying to create a map which will get mark certain locations on it based on the coordinates it gets from a csv file. I am trying to create the map using the unfolding maps library which runs only in processing 1.5 and not 2.0.
I checked and I saw that there is no function to read a csv file in processing 1.5. Neither is there a function to read a json file.
Any help regarding how I can read my data to create the markers would be great.
Answers
Either you gotta code 1 yourself, or try to insert the 1 from Processing 2:
https://github.com/processing/processing/blob/master/core/src/processing/data/Table.java
https://github.com/processing/processing/blob/master/core/src/processing/data/TableRow.java
Perhaps splitTokens() might be enough?
http://processing.org/reference/splitTokens_.html
In 1.5, people just used split() to read CSV data. And used the library from json.org (or more elaborated libraries like Jackson) to handle Json data.
hi, actually there is a new version of unfolding for processing 2.0. check their website.
Thanks all. I managed to read the data in .txt format using loadStrings and converting and converted the coordinates from string to float.
bckmnn - Thanks a lot. It has to be a new release. I checked the site yesterday itself. It wasnt there then.