Quantcast
Channel: Library Questions - Processing 2.x and 3.x Forum
Viewing all articles
Browse latest Browse all 2896

My sound file wont work

$
0
0
import processing.sound.*;

SoundFile file;
long time;
void setup() {
  time = millis();
  timer(10);
  size(1900,1000);
  background(0);
  time = millis();
  file = new SoundFile(this,"C:/Users/Sam/Desktop/Java programs/happy_Birthday/sounds/hb.mp3");
  file.play();
}
void timer(long ST){
  long t1= 0;
  for(ST=ST;t1-time>=ST;){
    t1 = millis();
    print(t1-time);
  }
}
color rainbow(){
  colorMode(HSB,10000);
  color c = color(millis()%10000,10000,10000);
  return c;
}
void draw() {
  if(millis()/100<100){
  colorMode(RGB);
  fill(rainbow());
  textSize(millis()/100.000);
  text("Happy Brithday",0,500);
  time = millis();
  }
  if(millis()/100>100){
  colorMode(RGB);
  fill(rainbow());
  textSize(millis()/100.000-time/100.000);
  text("Jillian",0,700);
  }
  if(millis()/100>500){
    background(0);
  }
}

I have the file in my sketch folder but it still keeps giving me this error:
A library relies on native code that's not available.
Or only works properly when the sketch is run as a 32-bit application.
Could not run the sketch (Target VM failed to initialize).
For more information, read revisions.txt and Help ? Troubleshooting.


Viewing all articles
Browse latest Browse all 2896

Trending Articles