Screen 5 tutorials

Page 4/5
1 | 2 | 3 | | 5

By snout

Ascended (15187)

snout's picture

21-08-2003, 22:17

Topic re-opened for Screen 5 discussion only.

By Argon

Paragon (1119)

Argon's picture

21-08-2003, 22:55

Thank you Smile
Still many questions to go Smile

The discussion kinda went off-topic if I understand correctly ?

Anyway, thank you for reopening it Smile

Kris.

By Argon

Paragon (1119)

Argon's picture

26-08-2003, 17:36

Okay, I'm kinda in trouble again Smile

First I write a screen 5 to floppy:
(Just a filled black rectangle)
<TABLE BORDER=0 ALIGN=CENTER WIDTH=85%><TR><TD><font class="mrc-small">Code:</font><HR></TD></TR><TR><TD><FONT class="mrc-small"><PRE>
10 screen 5:cls
20 line (0,0)-(100,100),1,BF
30 bsave "a:testvdp",&H0,&HFFFF,S
</PRE></FONT></TD></TR><TR><TD><HR></TD></TR></TABLE>

Then I load it:
<TABLE BORDER=0 ALIGN=CENTER WIDTH=85%><TR><TD><font class="mrc-small">Code:</font><HR></TD></TR><TR><TD><FONT class="mrc-small"><PRE>
10 screen 5:cls
20 set page 0,1
30 bload "a:testvdp",S
40 set page 1,0
50 goto 50
</PRE></FONT></TD></TR><TR><TD><HR></TD></TR></TABLE>

The screen gets loaded, but when displayed, the rectangle is shifted to the left.
Part of the rectangle shows up on the right of the screen Sad
At the bottom of the screen there is screwed up white distortion Sad

Any help ?

Thank you.
Kris

By Argon

Paragon (1119)

Argon's picture

26-08-2003, 17:53

Ok this time I calculated:
Screen 5 = 256x212 = (Hex) D400

When I save from H0 to D400, and then load it, then it renders correct.

Can somebody confirm that this was my problem ???

Or do I need to do (256x212)-1 = (Hex)D3FF ?
(1D array starting with 0 (&H0) ?)

Thank you.
Kris

By Maggoo

Paragon (1216)

Maggoo's picture

26-08-2003, 18:07

Ok this time I calculated:
Screen 5 = 256x212 = (Hex) D400

When I save from H0 to D400, and then load it, then it renders correct.

Can somebody confirm that this was my problem ???

Or do I need to do (256x212)-1 = (Hex)D3FF ?
(1D array starting with 0 (&H0) ?)

Thank you.
Kris

Well technically it's 256*212 / 2 because there are 2 points per byte in screen 5 (16 colors max, this is 4 bits per point).

Example:

screen 5: Vpoke 0,255

is the same as screen 5Tongueset(0,0),15Tongueset(1,0),15

Binary 1111 1111
Decimal 15 15

Got it ? Smile

By Argon

Paragon (1119)

Argon's picture

26-08-2003, 18:12

Oh yes, right, there are 2 pixels per byte Smile Forgot about that Smile
Got it Smile

Question:
Is it (256x212)/2 -1 or is it without the -1 then ?
(Using arrays which start at 0 to pixelcount-1)

I haven't looked at the pset and vpoke, vpeek commands yet, but I'd better to that soon it seems Smile

Thank you

By anonymous

incognito ergo sum (116)

anonymous's picture

26-08-2003, 21:05

I already told you to use 7FFF for the BSAVE end-address...

By Argon

Paragon (1119)

Argon's picture

26-08-2003, 22:20

Ah... sorry I overlooked that...

K

By ro

Scribe (4698)

ro's picture

27-08-2003, 12:34

..and if you had checked the 'sprite' tech. files I've send you, you will understand the 'noise' at the bottom of the screen Smile

By Argon

Paragon (1119)

Argon's picture

27-08-2003, 13:46

I'm sorry. It's pretty hectic for the moment, I'm swimming in work Smile
I'll check better before asking next time Smile

Kris

Page 4/5
1 | 2 | 3 | | 5