|
119 | 119 | % Draw aperture and we rotate to match the required condition |
120 | 120 | Screen('DrawTexture', cfg.screen.win, cfg.aperture.texture, ... |
121 | 121 | cfg.screen.winRect, ... |
122 | | - CenterRect(... |
| 122 | + CenterRect( ... |
123 | 123 | cfg.screen.winRect * cfg.magnify.scalingFactor, ... |
124 | 124 | cfg.screen.winRect), ... |
125 | 125 | thisEvent.condition - 90); |
|
154 | 154 | cfg.ring.maxEcc = ... |
155 | 155 | cfg.screen.FOV / 2 + ... |
156 | 156 | cfg.aperture.width + ... |
157 | | - log(cfg.screen.FOV / 2 + 1) ; |
| 157 | + log(cfg.screen.FOV / 2 + 1); |
158 | 158 | % ring.CsFuncFact is used to expand with log increasing speed so |
159 | 159 | % that ring is at ring.maxEcc at end of cycle |
160 | 160 | cfg.ring.csFuncFact = ... |
161 | 161 | 1 / ... |
162 | 162 | ((cfg.ring.maxEcc + exp(1)) * ... |
163 | 163 | log(cfg.ring.maxEcc + exp(1)) - ... |
164 | | - (cfg.ring.maxEcc + exp(1))) ; |
| 164 | + (cfg.ring.maxEcc + exp(1))); |
165 | 165 | end |
166 | 166 |
|
167 | 167 | case 'bar' |
168 | | - |
| 168 | + |
169 | 169 | extraPositons = 0; |
170 | 170 | if cfg.magnify.do |
171 | 171 | % we add some extra bar positions that we remove afterwards to |
|
175 | 175 |
|
176 | 176 | % Set parameters drifting bars |
177 | 177 | cfg.aperture.barWidthPix = cfg.stimRect(3) / (cfg.volsPerCycle + extraPositons); |
178 | | - |
| 178 | + |
179 | 179 | barPosPix = ... |
180 | 180 | [0:cfg.aperture.barWidthPix:cfg.stimRect(3) - cfg.aperture.barWidthPix] + ... |
181 | 181 | (cfg.screen.winRect(3) / 2 - cfg.stimRect(3) / 2) + ... |
182 | 182 | cfg.aperture.barWidthPix / 2; %#ok<NBRAK> |
183 | | - |
| 183 | + |
184 | 184 | % Those positions are removed because they are actually outside of |
185 | 185 | % the screen when magnification (fit to windows width) is on |
186 | 186 | if cfg.magnify.do |
187 | | - barPosPix([1:6, end-5:end]) = []; |
| 187 | + barPosPix([1:6, end - 5:end]) = []; |
188 | 188 | end |
189 | | - |
| 189 | + |
190 | 190 | cfg.aperture.barPosPix = barPosPix; |
191 | 191 |
|
192 | 192 | % Width of bar in degrees of VA (needed for saving) |
|
0 commit comments