TextSize bug in EmulateOldPTB mode

I use PTB2 before and change to PTB3 recently.
I discover if I DrawText in one window, change into another,
and DrawText in previous one, then the TextSize will be wrong.

My Code is below. And my system is
MATLAB Version 7.4.0.287 (R2007a)
Psychtoolbox Version 3.0.8 At revision: 1129 .
---
Screen('Preference', 'EmulateOldPTB', 1);
Screen('OpenWindow', 0);
SenderPreparing_window = Screen('OpenOffScreenWindow', 0);
Screen('TextSize', SenderPreparing_window, 18);
Screen('DrawText', SenderPreparing_window, 'Earnings of you and member A are in the dark blue boxes;', 200, 200);
SenderWaiting_window = Screen('OpenOffScreenWindow', 0);
Screen('TextSize', SenderWaiting_window, 60);
Screen('DrawText', SenderWaiting_window, 'Please wait until the other participant makes a decision.', 300, 300);
Screen('DrawText', SenderPreparing_window, 'Trial %d of %d', 400, 400);
imwrite(Screen(SenderPreparing_window, 'GetImage'), '<a href="http://www.wretch.cc/album/show.php?i=daiYuTsung&b=7&f=1912162059&p=4">SenderPreparing_window.jpg</a>', 'jpg');
imwrite(Screen(SenderWaiting_window, 'GetImage'), '<a href="http://www.wretch.cc/album/show.php?i=daiYuTsung&b=7&f=1912162058&p=3">SenderWaiting_window.jpg</a>', 'jpg');
Screen('CloseAll');


______________________________________________________________________________________________________
付費才容量無上限?Yahoo!奇摩電子信箱2.0免費給你,信件永遠不必刪! http://tw.mg0.mail.yahoo.com/dc/landing
Thanks for reporting that. It is a bug in the
Windows PTBs 'DrawText', not only in PTB-2
emulation mode. Linux and OS/X are not affected.

Will fix it for the next beta update. Make sure
you write new experiments in "native" PTB-3
mode. Its simpler and faster. And bugs that
only affect the PTB-2 mode likely won't get fixed.

-mario


--- In psychtoolbox@yahoogroups.com, À¹ÒRÚz <dai_yu_tsung@...> wrote:
>
> I use PTB2 before and change to PTB3 recently.
> I discover if I DrawText in one window, change into another,
> and DrawText in previous one, then the TextSize will be wrong.
>
> My Code is below. And my system is
> MATLAB Version 7.4.0.287 (R2007a)
> Psychtoolbox Version 3.0.8 At revision: 1129 .
> ---
> Screen('Preference', 'EmulateOldPTB', 1);
> Screen('OpenWindow', 0);
> SenderPreparing_window = Screen('OpenOffScreenWindow', 0);
> Screen('TextSize', SenderPreparing_window, 18);
> Screen('DrawText', SenderPreparing_window, 'Earnings of you and member A are in the
dark blue boxes;', 200, 200);
> SenderWaiting_window = Screen('OpenOffScreenWindow', 0);
> Screen('TextSize', SenderWaiting_window, 60);
> Screen('DrawText', SenderWaiting_window, 'Please wait until the other participant makes
a decision.', 300, 300);
> Screen('DrawText', SenderPreparing_window, 'Trial %d of %d', 400, 400);
> imwrite(Screen(SenderPreparing_window, 'GetImage'), '<a
href="http://www.wretch.cc/album/show.php?
i=daiYuTsung&b=7&f=1912162059&p=4">SenderPreparing_window.jpg</a>', 'jpg');
> imwrite(Screen(SenderWaiting_window, 'GetImage'), '<a
href="http://www.wretch.cc/album/show.php?
i=daiYuTsung&b=7&f=1912162058&p=3">SenderWaiting_window.jpg</a>', 'jpg');
> Screen('CloseAll');
>
>
>
________________________________________________________________________________________
______________
> ¥I¶O¤~®e¶qµL¤W­­¡HYahoo!©_¼¯¹q¤l«H½c2.0§K¶Oµ¹§A¡A«H¥ó¥Ã»·¤£¥²§R¡I
http://tw.mg0.mail.yahoo.com/dc/landing
>
--- In psychtoolbox@yahoogroups.com, "Mario Kleiner" <mario.kleiner@...> wrote:
> Thanks for reporting that. It is a bug in the
> Windows PTBs 'DrawText', not only in PTB-2
> emulation mode. Linux and OS/X are not affected.
Thank you :)
> Will fix it for the next beta update. Make sure
> you write new experiments in "native" PTB-3
> mode. Its simpler and faster. And bugs that
> only affect the PTB-2 mode likely won't get fixed.
I´ll try it if I have time to learn their difference :)
> -mario
> --- In psychtoolbox@yahoogroups.com, 戴淯琮 <dai_yu_tsung@> wrote:
> >
> > I use PTB2 before and change to PTB3 recently.
> > I discover if I DrawText in one window, change into another,
> > and DrawText in previous one, then the TextSize will be wrong.
> >
> > My Code is below. And my system is
> > MATLAB Version 7.4.0.287 (R2007a)
> > Psychtoolbox Version 3.0.8 At revision: 1129 .
> > ---
> > Screen('Preference', 'EmulateOldPTB', 1);
> > Screen('OpenWindow', 0);
> > SenderPreparing_window = Screen('OpenOffScreenWindow', 0);
> > Screen('TextSize', SenderPreparing_window, 18);
> > Screen('DrawText', SenderPreparing_window, 'Earnings of you and member A are in the
> dark blue boxes;', 200, 200);
> > SenderWaiting_window = Screen('OpenOffScreenWindow', 0);
> > Screen('TextSize', SenderWaiting_window, 60);
> > Screen('DrawText', SenderWaiting_window, 'Please wait until the other participant makes
> a decision.', 300, 300);
> > Screen('DrawText', SenderPreparing_window, 'Trial %d of %d', 400, 400);
> > imwrite(Screen(SenderPreparing_window, 'GetImage'), '<a
> href="http://www.wretch.cc/album/show.php?
> i=daiYuTsung&b=7&f=1912162059&p=4">SenderPreparing_window.jpg</a>', 'jpg');
> > imwrite(Screen(SenderWaiting_window, 'GetImage'), '<a
> href="http://www.wretch.cc/album/show.php?
> i=daiYuTsung&b=7&f=1912162058&p=3">SenderWaiting_window.jpg</a>', 'jpg');
> > Screen('CloseAll');


______________________________________________________________________________________________________
付費才容量無上限?Yahoo!奇摩電子信箱2.0免費給你,信件永遠不必刪! http://tw.mg0.mail.yahoo.com/dc/landing