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.
IndexDiscussionGeneral Discussion,  Status › large p5 screen
Page Index Toggle Pages: 1
large p5 screen? (Read 1161 times)
large p5 screen?
Sep 14th, 2009, 4:08am
 
Hello,

I'm mucking around with drawing sketches in processing...

I'll just preface this by saying I notice how a lot of processing sketches kick in at around size(400, 400)... Obviously this is easy to display online and is good for processing speed etc...

But what if you wanna do super large stuff?

I'm having fun playing around in little drawing programs I've made. It's fine at 400,400, but then what if you want to up the resolution, to something massive? I was reading about exporting to PDF, so potentially you could do 3000 x 5000 - but this only makes sense to me if the computer is doing all the drawing.

If I run a sketch at size(3000, 5000), there is no ability to scroll in the screen when you are drawing... Is it possible to scroll a window of a running processing sketch?

Mainly I am think about this for resolution. Drawing a 400 x 400 image is a pretty crumby res. But how can I use the screen with very high res as a painterly canvas if I can't navigate it?

Will I have to build my own scroll bars into the program?

I am thinking, it would be great to do paintings with processing, and print them out at high-resolution, but I would mos-def need an ability to at least scroll around the application window, or potentially zoom out and move to another area of the canvas.

Standard photoshop procedure I know. Hold space to scroll, Command minus/plus to zoom...

If anyone has any hot tips I would greatly appreciate.

Otherwise even when I tried to print to PDF in a small size with a drawing program, the PDF didn't seem to maintain transparency...

Thanks,

matt



Re: large p5 screen?
Reply #1 - Sep 14th, 2009, 4:12am
 
Code:
import processing.pdf.*;

import fullscreen.*;
int strokegrowth = +1;

int x = 1;
int i = 255;
FullScreen fs;

void setup(){
// set size to 640x480
size(3000, 2000);//how to be able to scroll around?

// 5 fps
frameRate(60);
smooth();
background(0);

// Create the fullscreen object
// fs = new FullScreen(this);
//
// // enter fullscreen mode
// fs.enter();
}


void draw() {

if(mousePressed == true) {
noCursor();
} else {
cursor(CROSS);
}

x = (x + strokegrowth);
if (x > 40) {
strokegrowth = strokegrowth * -1;
} else if (x < 1) {
strokegrowth = +1;
}

}

void mouseDragged() {

stroke(random(255),random(255), random(255), i);
strokeWeight(x);
line(pmouseX, pmouseY, mouseX, mouseY);
// line(pmouseX + 50, pmouseY + 50, mouseX + 50, mouseY + 50);
// line(pmouseX - 50, pmouseY - 50, mouseX - 50, mouseY - 50);

i = x+ 40;

}




void keyPressed() {
if (key == 'c' || key == 'C') {
background(random(255), random(255),random(255), random(255));
}
if (key == 's' || key == 'S') {
save("painting.tiff");
}
if (key == 'g' || key == 'G') {
x = x + 10;
} else {
x = 1;

}
}
Re: large p5 screen?
Reply #2 - Sep 14th, 2009, 11:07am
 
This details a good method for saving high resolution images for printing.  We've used this for printing out large-format images for exhibitions, etc, in the past.

http://workshop.evolutionzone.com/2007/03/24/code-tilesaverpde/
Page Index Toggle Pages: 1