We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpSyntax Questions › Help With Movie DNA Script
Page Index Toggle Pages: 1
Help With Movie DNA Script (Read 1633 times)
Help With Movie DNA Script
Jul 27th, 2005, 9:08pm
 
Hi. I don't know coding for processing, I just saw something on Attack of the Show! called Movie DNA or something. (to see examples go here: http://plasticbugs.com/index.php?p=278 ) I pasted the code and changed "movie.mov" to my file name. when I pressed "run" in version 0090, the following error appeared:

C:/Documents and Settings/[MY USERNAME]/Application Data/Processing/build/Temporary_498_8592.java:14:26:14:33: Semantic Error: Type "quicktime.std.movies.Movie" was not found.

and in version 0091:

C:/DOCUME~1/[MY USERNAME]/LOCALS~1/Temp/build/Temporary_483_6083.java:14:26:14:33: Semantic Error: Type "quicktime.std.movies.Movie" was not found.




I don't know how to fix it since I don't know processing, so could someone please help? Here is the code I used:

import processing.video.*;
Movie myMovie;
int xpos = 0;
int ypos = 0;
int VWIDTH = 11; // width of capture
int VHEIGHT = 6; // height of capture
int MOVIEWIDTH = VWIDTH * 60; // width is equivalent to 1 minute of film time
int MOVIEHEIGHT;
int MAXWIDTH = MOVIEWIDTH - VWIDTH;
float MOVIEDURATION;

void setup() {
myMovie = new Movie(this, "notokay.mov"); //change movie.mov to the filename of your Quicktime movie
MOVIEDURATION = (myMovie.duration()); // gets the duration of the movie in seconds
MOVIEHEIGHT = VHEIGHT * int(MOVIEDURATION / 60) + VHEIGHT; // height of the stage is based on the length of your film
// note that the last frame of the film will repeat until it reaches the end of the current line
size(MOVIEWIDTH, MOVIEHEIGHT);
background(0); // sets the background of the stage to black
framerate(1); // forces the video to play at one frame per second
myMovie.play();
}

void draw() {
if(myMovie.available()) { // checks to see if the next frame is ready for processing
myMovie.read();
image(myMovie, xpos, ypos, VWIDTH, VHEIGHT);
xpos += VWIDTH;
if (xpos > MAXWIDTH) {
xpos = 0;
ypos += VHEIGHT;
}
if(ypos > MOVIEHEIGHT) {
save("my_movie_dna.tif"); // saves a tiff image to the folder of the current sketch when the end of the movie is reached
delay(2000); // pauses two seconds to save the file
noLoop(); // exits the draw loop so that the process ends
}
delay(100); // waits one tenth of a second before repeating the draw function
}
}
Re: Help With Movie DNA Script
Reply #1 - Jul 28th, 2005, 12:52am
 
have you read through the FAQ regarding problems with using video?
http://processing.org/faq/bugs.html#video
Re: Help With Movie DNA Script
Reply #2 - Jul 28th, 2005, 4:02am
 
I checked... it said to have version 6.5.2 of Quicktime and that's what I have... did I possibly extract the files to the wrong place?
Page Index Toggle Pages: 1