Basic hat

Pagina 2/4
1 | | 3 | 4

Van Grauw

Ascended (10768)

afbeelding van Grauw

03-03-2015, 20:23

NYYRIKKI wrote:

28 seconds on R800 & BASIC kun compiler, no cheating.

Poltergeist wrote:

So, how long does it take on R800 & Basic Kun compiler, throttled to 1000%?

mars2000you wrote:

Probably 2 or 3 seconds !

Science! Smile

Van Manuel

Ascended (19466)

afbeelding van Manuel

03-03-2015, 22:03

It's only about 15 minutes on R800. Smile

The 1000% stuff fully depends on how fast your PC is and how heavy your rendering options are. Useless to mention IMHO...

NYYRIKKI: this must be with your extensions to it, because normal one doesn't run it with the DIM RR stuff.

Van slowerisbetter

Master (194)

afbeelding van slowerisbetter

03-03-2015, 22:56

Manuel wrote:

NYYRIKKI: this must be with your extensions to it, because normal one doesn't run it with the DIM RR stuff.

Sorry, what does that mean?

Van Manuel

Ascended (19466)

afbeelding van Manuel

03-03-2015, 23:20

The program doesn't run under normal MSX-BASIC-kun. It doesn't like line 100.

Van Poltergeist

Champion (280)

afbeelding van Poltergeist

03-03-2015, 23:30

@manual: Isn't that a bit strange. I would say that if you set throttle to 1000%, is should be 10 times faster compared to the original speed. How is that dependant on the settings of the emulator (I can imagine speed of the PC, but wouldn't any normal PC be doing this with ease)?

Van sd_snatcher

Prophet (3659)

afbeelding van sd_snatcher

03-03-2015, 23:58

To make it run on BASIC-Kun, some slight modifications are necessary:

10 DIM RR(320)
100 COLOR 15,1,1:SCREEN 6
110 FOR I=0 TO 320:RR(I)=193:NEXT I
130 XP=144:XR=4.71238905#:XF=XR/XP
140 FOR ZI=64 TO -64 STEP -1
150 ZT=ZI*2.25:ZS=ZT*ZT
160 XL=INT(SQR(20736-ZS)+.5)
170 ZX=ZI+160:ZY=90+ZI
180 FOR XI=0 TO XL
190 XT=SQR(XI*XI+ZS)*XF
200 YY=(SIN(XT)+SIN(XT*3)*.4)*56
210 X1=XI+ZX:Y1=ZY-YY
220 IF RR(X1)>Y1 THEN RR(X1)=Y1:PSET (X1,Y1),15
230 X1=ZX-XI
240 IF RR(X1)>Y1 THEN RR(X1)=Y1:PSET (X1,Y1),15
250 NEXT XI:NEXT ZI
260 GOTO 260

Then you can just use _RUN normally.

Be sure to use MSX-BASIC Kun v2.1, as this was the last version and it has specific support for the R800 CPU. Here's a benchmark do draw a complete hat on R800 with both versions:

Basic-Kun v2.0: 82,21s
Basic-Kun v2.1: 58,11s

Van NYYRIKKI

Enlighted (6067)

afbeelding van NYYRIKKI

04-03-2015, 13:11

@Manuel No, I did it just like sd_snatcher, but I just wonder why we get so different results...

Van sd_snatcher

Prophet (3659)

afbeelding van sd_snatcher

04-03-2015, 16:47

I'm actually away from home, in a business trip in São Paulo. So I used openMSX instead of a real machine.

The PC I used is very slow, a P4 1.7GHz, so I wonder if it could be affecting the results.

In theory it shouldn't, because for the test I set TIME=0 in the beginning of the program, and replace line 260 with SCREEN0: PRINT TIME/60.

Van NYYRIKKI

Enlighted (6067)

afbeelding van NYYRIKKI

04-03-2015, 17:07

Yes, I did the same although I used BlueMSX... I know it is not most accurate emulator, but I didn't expect to see this kind of major differences compared to openMSX... I think I have to test with real MSX tR as well, when I get home...

Van wouter_

Hero (522)

afbeelding van wouter_

04-03-2015, 17:12

Note that timing of R800 is not very accurate yet in either openMSX or blueMSX.

Pagina 2/4
1 | | 3 | 4