Error using Screen (MATLAB beginner)
14 views (last 30 days)
Show older comments
Hi,
I am using R2012a and Psychtoolbox 3.0.12. Whenever I tried to run MATLAB files for my experiment (stroop task), I received error messages as below:
1. when I tried to run "stroop2013" mat file,
>> stroop2013
Enter Your name : aaa
PTB-INFO: Your version of Matlab 64-Bit is not DPI aware. On Windows-8 or later, without DPI awareness, fullscreen
PTB-INFO: onscreen windows will only work properly when displayed on displays with 96 DPI effective pixel density.
PTB-INFO: Displaying on anything other than a 96 DPI display will cause mysterious visual timing problems, sync failures etc.
PTB-INFO: Read 'help RetinaDisplay' for more info on this topic.
PTB-INFO: This is Psychtoolbox-3 for Microsoft Windows, under Matlab 64-Bit (Version 3.0.12 - Build date: Jan 14 2016).
PTB-INFO: Support status on this operating system release: Windows version 10.0 partially supported.
PTB-INFO: Type 'PsychtoolboxVersion' for more detailed version information.
PTB-INFO: Most parts of the Psychtoolbox distribution are licensed to you under terms of the MIT License, with
PTB-INFO: some restrictions. See file 'License.txt' in the Psychtoolbox root folder for the exact licensing conditions.
PTB-WARNING: Created onscreen window on screenid 0 will probably not be able to use GPU pageflipping for
PTB-WARNING: Screen('Flip')! May cause tearing artifacts and unreliable or wrong visual stimulus onset timestamping!
PTB-WARNING: Could not bind wglChoosePixelFormat - Extension. Some features will be unavailable, e.g., Anti-Aliasing and high precision framebuffers.
PTB-WARNING: Created onscreen window on screenid 0 will probably not be able to use GPU pageflipping for
PTB-WARNING: Screen('Flip')! May cause tearing artifacts and unreliable or wrong visual stimulus onset timestamping!
PTB-WARNING: Your graphics driver doesn't allow me to control if bufferswaps should be synchronized to the vertical retrace!
PTB-WARNING: This can cause massive stimulus timing problems, failure of the sync tests and calibrations and severe visual tearing artifacts!
PTB-WARNING: Please update your display graphics driver as soon as possible to fix this and make sure this functionality is not disabled in
PTB-WARNING: the display settings control panel of your graphics card.
PTB-WARNING: If everything else fails, you can usually manually enable synchronization to vertical retrace somewhere in the display settings
PTB-WARNING: control panel of your machine.
PTB-WARNING: Your version of Matlab 64-Bit is not DPI aware. Trying to use display screen 0 with a pixel density other than 96 DPI
would cause visual timing trouble due to DWM interference! Read 'help RetinaDisplay' for more info.
PTB-WARNING: Seems that Microsofts OpenGL software renderer is active! This will likely cause miserable
PTB-WARNING: performance, lack of functionality and severe timing and synchronization problems.
PTB-WARNING: Most likely you do not have native OpenGL vendor supplied drivers (ICD's) for your graphics hardware
PTB-WARNING: installed on your system.Many Windows machines (and especially Windows Vista) come without these preinstalled.
PTB-WARNING: Go to the webpage of your computer vendor or directly to the webpage of NVidia/AMD/ATI/3DLabs/Intel
PTB-WARNING: and make sure that you've download and install their latest driver for your graphics card.
PTB-WARNING: Other causes, after you've ruled out the above:
PTB-WARNING: Maybe you run at a too high display resolution, or the system is running out of ressources for some other reason.
PTB-WARNING: Another reason could be that you disabled hardware acceleration in the display settings panel: Make sure that
PTB-WARNING: in Display settings panel -> Settings -> Advanced -> Troubleshoot -> The hardware acceleration slider is
PTB-WARNING: set to 'Full' (rightmost position).
PTB-WARNING: Actually, it is pointless to continue with the software renderer, as that will cause more trouble than good.
PTB-WARNING: I will abort now. Read the troubleshooting tips above to fix the problem. You can override this if you add the following
PTB-WARNING: command: Screen('Preference', 'ConserveVRAM', 64); to get a functional, but close to useless window up and running.
Error using Screen
See error message printed above.
Error in stroop2013 (line 45)
[w,wRect]=Screen('OpenWindow', 0, bgColor);
2. When I tried to run the other mat file which name is "Stroop_m1",
>> Stroop_m1
PTB-INFO: Your version of Matlab 64-Bit is not DPI aware. On Windows-8 or later, without DPI awareness, fullscreen
PTB-INFO: onscreen windows will only work properly when displayed on displays with 96 DPI effective pixel density.
PTB-INFO: Displaying on anything other than a 96 DPI display will cause mysterious visual timing problems, sync failures etc.
PTB-INFO: Read 'help RetinaDisplay' for more info on this topic.
PTB-INFO: This is Psychtoolbox-3 for Microsoft Windows, under Matlab 64-Bit (Version 3.0.12 - Build date: Jan 14 2016).
PTB-INFO: Support status on this operating system release: Windows version 10.0 partially supported.
PTB-INFO: Type 'PsychtoolboxVersion' for more detailed version information.
PTB-INFO: Most parts of the Psychtoolbox distribution are licensed to you under terms of the MIT License, with
PTB-INFO: some restrictions. See file 'License.txt' in the Psychtoolbox root folder for the exact licensing conditions.
PTB-WARNING: Created onscreen window on screenid 0 will probably not be able to use GPU pageflipping for
PTB-WARNING: Screen('Flip')! May cause tearing artifacts and unreliable or wrong visual stimulus onset timestamping!
PTB-WARNING: Could not bind wglChoosePixelFormat - Extension. Some features will be unavailable, e.g., Anti-Aliasing and high precision framebuffers.
PTB-WARNING: Created onscreen window on screenid 0 will probably not be able to use GPU pageflipping for
PTB-WARNING: Screen('Flip')! May cause tearing artifacts and unreliable or wrong visual stimulus onset timestamping!
PTB-WARNING: Your graphics driver doesn't allow me to control if bufferswaps should be synchronized to the vertical retrace!
PTB-WARNING: This can cause massive stimulus timing problems, failure of the sync tests and calibrations and severe visual tearing artifacts!
PTB-WARNING: Please update your display graphics driver as soon as possible to fix this and make sure this functionality is not disabled in
PTB-WARNING: the display settings control panel of your graphics card.
PTB-WARNING: If everything else fails, you can usually manually enable synchronization to vertical retrace somewhere in the display settings
PTB-WARNING: control panel of your machine.
PTB-WARNING: Your version of Matlab 64-Bit is not DPI aware. Trying to use display screen 0 with a pixel density other than 96 DPI
would cause visual timing trouble due to DWM interference! Read 'help RetinaDisplay' for more info.
PTB-WARNING: Seems that Microsofts OpenGL software renderer is active! This will likely cause miserable
PTB-WARNING: performance, lack of functionality and severe timing and synchronization problems.
PTB-WARNING: Most likely you do not have native OpenGL vendor supplied drivers (ICD's) for your graphics hardware
PTB-WARNING: installed on your system.Many Windows machines (and especially Windows Vista) come without these preinstalled.
PTB-WARNING: Go to the webpage of your computer vendor or directly to the webpage of NVidia/AMD/ATI/3DLabs/Intel
PTB-WARNING: and make sure that you've download and install their latest driver for your graphics card.
PTB-WARNING: Other causes, after you've ruled out the above:
PTB-WARNING: Maybe you run at a too high display resolution, or the system is running out of ressources for some other reason.
PTB-WARNING: Another reason could be that you disabled hardware acceleration in the display settings panel: Make sure that
PTB-WARNING: in Display settings panel -> Settings -> Advanced -> Troubleshoot -> The hardware acceleration slider is
PTB-WARNING: set to 'Full' (rightmost position).
PTB-WARNING: Actually, it is pointless to continue with the software renderer, as that will cause more trouble than good.
PTB-WARNING: I will abort now. Read the troubleshooting tips above to fix the problem. You can override this if you add the following
PTB-WARNING: command: Screen('Preference', 'ConserveVRAM', 64); to get a functional, but close to useless window up and running.
Error using Screen
See error message printed above.
Error in PsychImaging (line 2020)
[win, winRect] = Screen('OpenWindow', screenid, clearcolor,
winRect, pixelSize, numbuffers, stereomode, multiSample,
imagingMode, specialFlags, clientRect);
Error in Stroop_m1 (line 24)
[window, windowRect] = PsychImaging('OpenWindow', screenNumber, grey, [],
32, 2);
I would really really appreciate it if you could let me know what is wrong. As I am a MATLAB beginner, I would appreciate if you could give any information or advice to me. Thank you for reading this and hope that you're having a good day:)
1 Comment
埃博拉酱
on 10 Apr 2023
This is the problem with Psychtoolbox. Psychtoolbox is a third-party toolbox and is not officially maintained by MATLAB. You should check with the developers of Psychtoolbox about this.
Answers (1)
Walter Roberson
on 2 Mar 2016
You need to upgrade your graphics drivers for your card; in particular you need more recent OpenGL drivers.
Question: is your graphics card an Intel HD2000 series? If it is then you are not going to be able to upgrade the drivers sufficiently; they do not support some of the necessary features.
3 Comments
Walter Roberson
on 20 Feb 2017
I am not familiar with the details of the HD4000; Psychtoolbox uses some of the lesser-known features, and I have never dug into what exactly it asks for or what the HD 4000 supports. So I cannot say "Yes, it should be okay" with any certainty. I think it is usable.
The HD4000 series supports OpenGL 4.0 and later, which is enough for all graphics features that MATLAB itself uses; MATLAB gives full graphics support with OpenGL 3.3 or later. The Intel HD 3000 supports OpenGL 3.1 and so some advanced features have to be skipped in MATLAB. The HD 2000 is known to give OpenGL problems in MATLAB, falling too far behind (though WikiPedia says it supports OpenGL 3.1).
So what I suspect for your HD 4000 is that you are using an older version of MATLAB that did not support DPI awareness. R2015a was the first with the support, and for R2015a itself you might need a patch; https://www.mathworks.com/matlabcentral/answers/153254-matlab-scaling-issue-on-high-resolution-high-dpi-displays#answer_170792
Abi Wyllie
on 10 May 2022
Hi, I also have the 'error using screen' message (I will attach the fullt error message below) when trying to run my MATLAB script. I have looked into the OpenGL on my computer, and my processor is Intel(R) Core(TM) i3-1005G1 which says it has OpenGL support 4.6.
I am using the R2020b version of MATLAB and Psychtoolbox-3 and my computer has Windows 10.
If you have any suggestions I would be very grateful, I am also a MATLAB beginner! Thank you!
Full error:
PTB-INFO: This is Psychtoolbox-3 for Microsoft Windows, under Matlab 64-Bit (Version 3.0.18 - Build date: Feb 2 2022).
PTB-INFO: OS support status: Windows 10 (Version 10.0) supported and tested to some limited degree.
PTB-INFO: Type 'PsychtoolboxVersion' for more detailed version information.
PTB-INFO: Most parts of the Psychtoolbox distribution are licensed to you under terms of the MIT License, with
PTB-INFO: some restrictions. See file 'License.txt' in the Psychtoolbox root folder for the exact licensing conditions.
PTB-INFO: For information about paid priority support, community membership and commercial services, please type
PTB-INFO: 'PsychPaidSupportAndServices'.
PTB-INFO: The detected endline of the vertical blank interval is equal or lower than the startline. This indicates
PTB-INFO: that i couldn't detect the duration of the vertical blank interval and won't be able to correct timestamps
PTB-INFO: for it. This will introduce a very small and constant offset (typically << 1 msec). Read 'help BeampositionQueries'
PTB-INFO: for how to correct this, should you really require that last few microseconds of precision.
PTB-INFO: Btw. this can also mean that your systems beamposition queries are slightly broken. It may help timing precision to
PTB-INFO: enable the beamposition workaround, as explained in 'help ConserveVRAMSettings', section 'kPsychUseBeampositionQueryWorkaround'.
PTB-INFO: OpenGL-Renderer is Intel :: Intel(R) UHD Graphics :: 4.6.0 - Build 27.20.100.9126
PTB-INFO: VBL startline = 1080 , VBL Endline = 1079
PTB-INFO: Measured monitor refresh interval from beamposition = 16.666771 ms [59.999623 Hz].
PTB-INFO: Will use beamposition query for accurate Flip time stamping.
PTB-INFO: Measured monitor refresh interval from VBLsync = 16.682072 ms [59.944592 Hz]. (50 valid samples taken, stddev=0.355021 ms.)
PTB-INFO: Reported monitor refresh interval from operating system = 16.666667 ms [60.000000 Hz].
PTB-INFO: Small deviations between reported values are normal and no reason to worry.
PTB-INFO: ==============================================================================================================================
PTB-INFO: WINDOWS DWM DESKTOP COMPOSITOR IS ACTIVE. On this Windows-10 or later system, Psychtoolbox can no longer reliably detect if
PTB-INFO: this will cause trouble for timing and integrity of visual stimuli or not. You might be just fine, or you could be in trouble.
PTB-INFO: Use external measurement equipment and independent procedures to verify reliability of timing if you care about proper timing.
PTB-INFO: ==============================================================================================================================
WARNING: Couldn't compute a reliable estimate of monitor refresh interval! Trouble with VBL syncing?!?
----- ! PTB - ERROR: SYNCHRONIZATION FAILURE ! -----
One or more internal checks (see Warnings above) indicate that synchronization
of Psychtoolbox to the vertical retrace (VBL) is not working on your setup.
This will seriously impair proper stimulus presentation and stimulus presentation timing!
Please read 'help SyncTrouble' for information about how to solve or work-around the problem.
You can force Psychtoolbox to continue, despite the severe problems, by adding the command
Screen('Preference', 'SkipSyncTests', 1); at the top of your script, if you really know what you are doing.
Error using Screen
See error message printed above.
Error in EyeLink_SimplePicture (line 105)
window = Screen('OpenWindow', screenNumber, [128 128 128]); % Open graphics window
See Also
Categories
Find more on Image display and manipulation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!