/usr/share/psychtoolbox-3/PsychTests/ResolutionTest.m is in psychtoolbox-3-common 3.0.11.20131230.dfsg1-1build1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 | function ResolutionTest
% ResolutionTest prints screen resolutions reported by Screen 'Resolution'
% and 'Resolutions'.
%
% Also see SetResolution, NearestResolution, and Screen Resolution and Resolutions.
%
% Denis Pelli
% 1/27/00 dgp Wrote it.
% 9/17/01 dgp Added "recommended" to the report.
% 4/24/02 awi Exit on PC with message.
% 10/7/12 mk Clean it up. Output refresh rates an pixelsize as well.
% Test every screen
for screenNumber=Screen('Screens')
% Describe video card
% DescribeScreen(screenNumber);
fprintf('\nCURRENT RESOLUTION:\n');
res=Screen(screenNumber,'Resolution');
disp(res);
fprintf('\nSCREEN %i: AVAILABLE RESOLUTIONS:\n', screenNumber);
res=Screen(screenNumber,'Resolutions');
oldres = '';
for i=1:length(res)
resname = sprintf('%dx%d ', res(i).width, res(i).height);
if isempty(strfind(oldres, resname))
oldres = [oldres resname]; %#ok<*AGROW>
fprintf('%d x %d\n', res(i).width, res(i).height);
end
end
fprintf('\nSCREEN %i: AVAILABLE DETAILED RESOLUTIONS:\n', screenNumber);
res=Screen(screenNumber,'Resolutions');
for i=1:length(res)
fprintf('%4d x %4d %3.0f Hz %d ',res(i).width,res(i).height,res(i).hz, res(i).pixelSize);
fprintf('bits\n');
end
fprintf('\n')
end
|