# Screen: wrong window position in large external display

**URL:** https://psychtoolbox.discourse.group/t/screen-wrong-window-position-in-large-external-display/11
**Category:** Uncategorized
**Created:** [November 12, 2019, 3:42pm UTC](https://psychtoolbox.discourse.group/t/screen-wrong-window-position-in-large-external-display/11 "2019-11-12T15:42:06Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![denispelli](https://avatars.discourse-cdn.com/v4/letter/d/cdc98d/32.png) [@denispelli](https://psychtoolbox.discourse.group/u/denispelli)
#### Post date: [November 12, 2019, 3:42pm UTC](https://psychtoolbox.discourse.group/t/screen-wrong-window-position-in-large-external-display/11/1 "2019-11-12T15:42:06Z")

</div>

Dear Mario and friends

Two glitches in Screen OpenWindow.

BUG 1:

MacBook Pro with large external LG Screen attached through USB C port. When I try to open a full-screen window on screen 1, without specifying a rect, I get a full screen window, as expected. However, when I add the rect argument, specifying the full screen, i get a window of the right size, but offset left by half a screen, so i only see the right half of the window, and the right half of the screen remains black. Weirdly, from software, I can't tell that anything's wrong, as the Screen('Rect',window) and Screen('GlobalRect',window) are the same as for a proper full-screen window.

% Without the rect argument, it works as expected.

r=Screen('Rect',screen);

screen=1;

white=255;

window=Screen('OpenWindow',screen,white);

sca

% However, using the rect argument gives a window

% that is only half on the screen.

window=Screen('OpenWindow',screen,white,r);

r =

0 038402160

Screen('Rect',window)

ans =

0 038402160

Screen('Rect',window)

ans =

0 038402160

Screen('GlobalRect',window)

ans =

0 038402160

BUG 2:

providing an empty rect, crashes MATLAB.

window=Screen('OpenWindow',screen,white,[]);

Here's my configuration:

model: 'MacBookPro14,3'

modelDescription: 'MacBook Pro (15-inch, 2017)'

manufacturer: 'Apple Inc.'

psychtoolbox: 'Psychtoolbox 3.0.16'

matlab: 'MATLAB 9.6 (R2019a)'

system: 'macOS 10.14.6'

screenMex: 'Screen.mexmaci64 07-Aug-2019'

screens: [0 1]

screen: 0

size: [2100 3360]

nativeSize: [2100 3360]

mm: [206 330]

openGLRenderer: 'AMD Radeon Pro 560 OpenGL Engine'

openGLVendor: 'ATI Technologies Inc.'

openGLVersion: '2.1 ATI-2.11.20'

psychtoolboxKernelDriver: 'PsychtoolboxKernelDriver 1.1'

drawTextPlugin: 1

psychPortAudio: 1

summary: 'MacBookPro14,3-macOS-10.14.6-PTB-3.0.16'

Best

Denis
  

| 

 |  

 | ![photo](https://ec.yimg.com/ec?url=https%3A%2F%2Fs3.amazonaws.com%2Fucwebapp.wisestamp.com%2F887691c9-4947-4f2c-9c88-27e316257a00%2F032_Colorcropped.format_png.resize_200x.png%23logo&t=1575346081&sig=2A7GeDIfLuQbrh0sMkXSnw--~E) | |   
**Denis Pelli**  
 Professor of Psychology & Neural Science, New York University 
 

 |   

+1-646-258-7524| [denis.pelli@...](mailto:denis.pelli@...)

  |
 |  

[http://psych.nyu.edu/pelli/](http://psych.nyu.edu/pelli/)| Skype: denispelli

  |
 | | [http://denispelli.com](http://denispelli.com) |
 
 

| [![](https://ec.yimg.com/ec?url=https%3A%2F%2Fcdn.gifo.wisestamp.com%2Fsocial%2Ffacebook%2F3b5998%2F16%2F0.png&t=1575346081&sig=g5Ik7UxA9yAksy_8ej203g--~E)](http://www.facebook.com/denispelli) | [![](https://ec.yimg.com/ec?url=https%3A%2F%2Fcdn.gifo.wisestamp.com%2Fsocial%2Flinkedin%2F0077b5%2F16%2F0.png&t=1575346081&sig=QW_hxDf7lwYvW3GPbpYSXw--~E)](http://www.linkedin.com/in/denispelli/) | [![](https://ec.yimg.com/ec?url=https%3A%2F%2Fcdn.gifo.wisestamp.com%2Fsocial%2Ftwitter%2F55acee%2F16%2F0.png&t=1575346081&sig=wwJlYhLTuhOauag8PYQhNQ--~E)](http://twitter.com/denispelli) |

  |
 
  |
 
 

| |

 |
