I am trying to run a sketch a processing sketch on openprocessing. However, it is not running, and I don't don;t know why. I understand it is using Minim library, but I see 'some' sketches, using minim running fine on oprnprocessing.org. How can I resolve this?
I found
thiscode online showing bezier curves dashed line. The code shows one curve. I am using this to map on an image. Is there a way i can make 2 or more simultaneous curves from one Pvector to another. Been trying, but unsuccessfull. Few edits in there are/ might be off..Here's the code-
Totally new here in jQuery. I want to bring in 'Strings'(
Time to be precise) from javaScript to processing IDE. Though pomax has also done a
tutorial on how to do the same. I did got his example, but i am not able to do it with this code, i found
online. So when someone, selects the country(let's say china), then it should send the
selected country's time, date, day etc to processing
Can anybody please help me with this?
How can i place a 2D image in a 3D space with freedom to rotate/scale etc. Just as described in Jer thorp's Just landed
project.
Also, important point to note here is, how will i be able to permanently cast/store the points or positions into the image(map) even after rotation. Thanks
Working with
this document file and
this 'frequency' in a week file[time.tsv] (converted to tsv) for Visualization
on an map of India.What would be the best way i should approach this particular case. Wanted to know if i am thinking in the right direction or not. Also, how can i
'cast' data to each other?
Till now, what i have done:
1. Main tab is basically reading the tsv files. Something like -
Flights[] data;
Time[] time;
void setup() {
map = loadImage("map2.jpg");
....
........
schedule = new Table("Indigo Flights.tsv"); ///usual "Table" class (ben fry)
schedule2 = new Table("Time.tsv");
// rowCount = schedule.getRowCount();
data = new Flights[schedule.getRowCount()-1]; //t = schedule
I am working with this data visualization project which will be up online. Due to this, i can't use any libraries.
After going through Pomax processingjs guide, he describes how we can use a part of physics library(
http://processingjs.org/articles/PomaxGuide.html )- under "Javascript objects" with JavaScript, but i couldn't get it thoroughly.
I want to use controlP5 library features like the grouping of items(similar and different) in a drop down context and passing the 'selected' menu item.
http://code.google.com/p/controlp5/source/browse/#svn%2Fbranches%2Fcontrolp5-1.5.2%2Fsrc%2FcontrolP5
Since i am working on this data visualization project on an image, i wanted to ask about storing points on a map.
So, what are the ways i can store points on an image? One would be Lat-longitude method(but my data does not have not that, so can't use that).
Other would be storing each coordinate(as in x- and y- positions of the sketch window?) but that would work only with a static background image yes?
How are points stored in those projects where the whole map is also being rotated/ zoomed in n out etc. but those points on the map/image cast itself to it.
I need help with moving balls on a bezier curve.
Taking the example from processing site itself. (
http://processing.org/learning/curves/) I need them red dots/ellipses(the end points to move along the curve from one end point to the other). I know you can do that on spline curves but what about bezier curves
NOTE: the curve is presently on an background image, so be careful of that.
void setup( )
{ size(150, 150);
background(255);
smooth();
ellipse(50, 75, 5, 5); // endpoints of curve <-- i want these ellipses to keep moving on the curve
I want to draw
3D animation curves from one point
in the picture( a map) to another.
1. Can i store points in the background image? Or should i keep it static to make it simple?
2. Using curves(), how can i draw a curve from one point to another but the end point of the curve going in a slow motion towards the destination point? Also, if i draw ellipses on top of that line, how can they move through the curve?
I need help with 'mapping' time on a line. Related to time and flights/arrival and destination time.
For example, let's say time right now is: 15:30:00
The arrival time and the departure time are 14:00:00 and 17:30:00 respectively. As till now, for the time i have divided/splitted into H, M, and S like this-
So, if i could draw a point on a line which signifies or maps the current time with respect to Arrival and destination time. I mean the point should be somewhere around 50% of the length of the line(as per the example which we took). It's the format (HH:MM:SS), which is confusing.
Hi, i am currently working with this project which uses the table class(from Ben Fry's Visualizing data), also a part of Processing 2(i think).
But anyway, since the project will be up on the browser as processing js. Can anybody tell me whether it has some "Java" which might not be compiled in pjs?( also which might be the reason of the project not running in browser). Here's the Table class.
class Table {
int rowCount;
String[][] data;
Table(String filename) {
String[] rows = loadStrings(filename);
data = new String[rows.length][];
for (int i = 0; i < rows.length; i++) {
if (trim(rows[i]).length() == 0) {
continue; // skip empty rows
}
if (rows[i].startsWith("#")) {
continue; // skip comment lines
}
// split the row on the tabs
String[] pieces = split(rows[i], TAB);
// copy to the table array
data[rowCount] = pieces;
rowCount++;
// this could be done in one fell swoop via:
//data[rowCount++] = split(rows[i], TAB);
}
// resize the 'data' array as necessary
data = (String[][]) subset(data, 0, rowCount);
}
int getRowCount() {
return rowCount;
}
// find a row by its name, returns -1 if no row found
int getRowIndex(String name) {
for (int i = 0; i < rowCount; i++) {
if (data[i][0].equals(name)) {
return i;
}
}
println("No row named '" + name + "' was found");
return -1;
}
String getRowName(int row) {
return getString(row, 0);
}
String getString(int rowIndex, int column) {
return data[rowIndex][column];
}
String getString(String rowName, int column) {
return getString(getRowIndex(rowName), column);
}
int getInt(String rowName, int column) {
return parseInt(getString(rowName, column));
}
int getInt(int rowIndex, int column) {
return parseInt(getString(rowIndex, column));
}
float getFloat(String rowName, int column) {
return parseFloat(getString(rowName, column));
}
float getFloat(int rowIndex, int column) {
return parseFloat(getString(rowIndex, column));
}
void setRowName(int row, String what) {
data[row][0] = what;
}
void setString(int rowIndex, int column, String what) {
data[rowIndex][column] = what;
}
void setString(String rowName, int column, String what) {
int rowIndex = getRowIndex(rowName);
data[rowIndex][column] = what;
}
void setInt(int rowIndex, int column, int what) {
data[rowIndex][column] = str(what);
}
void setInt(String rowName, int column, int what) {
int rowIndex = getRowIndex(rowName);
data[rowIndex][column] = str(what);
}
void setFloat(int rowIndex, int column, float what) {
data[rowIndex][column] = str(what);
}
void setFloat(String rowName, int column, float what) {
i am working on this data visualization project, and its like 40% done. Well, i suddenly realized about my code being not so efficient since functions are called from functions and similar trails.
void setup() {
......
....
.....
schedule = new Table("asdf.tsv");
setupMain();
}
void setupMain() {
NumberOfRows = lines.length;
.....
...........
FlightNumber = new String[NumberOfRows]; //initializing arrays
Hi, i am having this problem with processing 'javascript' mode in processing 2 beta 7.
Well,
in the javascript mode, the code runs fine in chrome when i execute from the processing IDE(using the 'play' button). But, when i click on 'Export Application' and then open the HTML file in chrome, it gives me nothing. #using no libraries, nothing.
you ll see that there are empty cells also. Now would that be a problem, if i just convert it into tsv from Excel and use it with processing? (i am referring to Ben Fry's Visualizing Data by the way for the code).
I am using minim library in a project in eclipse(java), which is creating sounds. What i wanna do is send these sounds to max msp through 'jack'
http://jackaudio.org/ where i can process the sound/add effects to the sound through the max msp. Well the problem i am having is, i can't find the output sending line or whatever,in the minim library(inside my project), like where exactly am i suppose to change it's output? So that it can go to jack, and then to max msp...I did see the minim documentation(but that i can't relate :( .. I think it might be in the following , maybe, if not lemme know.., please help immediately....
import ddf.minim.Recordable;
import ddf.minim.spi.AudioOut;
import ddf.minim.spi.AudioRecording;
import ddf.minim.spi.AudioRecordingStream;
public class JSMinim implements MinimServiceProvider