Strings and datatypes problem...
in
Programming Questions
•
2 years ago
Hi. I'm using the v3ga blob detection library, and im interested in trying to get at the x/y coordinates of the edge vertex and save them to a file...
but im getting a "cannot convert from float to int" error on my string array code (line 5 here)...
I'm not really sure about trying to set or convert the datatype, or even which part of the line it's referring to?
I know that eA.x is a float, as per v3ga's documentation, so Im assuming that "lines" is being read as an integer array ? But im not sure how that is, if I did that, or how to change it...
- eA = b.getEdgeVertexA(m);
- eB = b.getEdgeVertexB(m);
- if (eA !=null && eB !=null) {
- vertex(eA.x*cam.width, eA.y*cam.height);
- String[] lines = new String[eA.x];
- }
I haven't really had cause to play with strings and arrays very often in Processing, and only vaguely understand them... so im a bit lost... any help/leads appreciated.
thanks in advance,
~ J
1
