codeanticode / planetarium

A Processing library for dome projection.
http://processing.andrescolubri.net/libraries/planetarium/
Other
50 stars 13 forks source link

Cannot export resolution beyond the size of the monitor #10

Open tsloan1377 opened 5 years ago

tsloan1377 commented 5 years ago

This is an issue with Processing itself, but wonder if there is a workaround. I would like to export frames at 3072x3072 or 4096x4096 pixels for a DomeMaster, however Processing always resizes the window to the display resolution. It would be great to be able to bypass this.

janebeta7 commented 5 years ago

Hello, try this:

int displayX=0;
int displayY = 0;

void settings() {
  fullScreen(Dome.RENDERER, 1);
}

void setup(){
 size(3072, 3072, Dome.RENDERER);
 surface.setSize(3072, 3072);
surface.setLocation(displayX, displayY); //if you want to move the large screen in your small windows
}
void keyPressed() {
if (key == CODED) {
    if (keyCode == UP) {
      displayY = displayY-100;
      surface.setLocation(displayX, displayY);
    } else if (keyCode == DOWN) {
      displayY = displayY+100;
      surface.setLocation(displayX, displayY);
    } else if (keyCode == LEFT) {
      displayX = displayX-100;
      surface.setLocation(displayX, displayY);
    } else if (keyCode == RIGHT) {
      displayX = displayX+100;
      surface.setLocation(displayX, displayY);
    }
  }
}
tsloan1377 commented 5 years ago

Awesome, that worked! For me I had to move the size(3072, 3072, Dome.RENDERER) into setup(). Thank you very much.