P2D window size greater than display

edited April 2017 in Python Mode

Hi, when I use the P2D render, if only one dimension is greater than that of the sreen, this is scaled down. If both are greater, then it works.

My display is 1920 * 1080.

If I use size(1000, 1500, P2D), it becomes 1000, 1063.

If I use size(2500, 1500, P2D), it works well. (2500,1500)

Is the right behavior? Or is it a bug?

Thank you

Answers

  • Well, I think it's a bug then :(

  • This is the code I used:

    void setup() {
      size(displayWidth,displayHeight,P2D);
      noLoop();
    }
    
    void draw(){
        println(width+" "+height);
    }
    
    //                 STD  SIZE_USED                                P2D
    //1920 1080  fs   size(displayWidth,displayHeight)  1920, 1055
    //1000,1500  ok  size(1000,1500);                       ok -> second scr
    //2000,1000  ok  size(2000,1000);                       1920,1055
    //2000,1500  ok  size(2000,1500);                       1920, 1055
    

    I will say the test is inconclusive on my side. Mind I'm in linux on a dual screen. I can try on my laptop when I get home. By the wa, what OS and Processing version?

    Maybe other people in the community can test it as well.

    Kf

  • Same results in windows 10. Even if I use size(displayWidth,displayHeight) and it seems the problem is because the sketch is outside the display area of the screen/display. But if both dimensions are greater than the screen size then there is no warning. The warning is:

    The sketch has been automatically resized to fit the screen resolution

    Kf

  • edited April 2017

    Kf thanks for your tests.

    Processing 3.3 in Windows 10 here.

Sign In or Register to comment.