Jump to content
IGNORED

GTIA & Graphics 15


Recommended Posts

2 hours ago, ac.tomo said:

I'm trying to create a DL where 1 line is GR.15 and the next is GTIA 11. There's no problem, I have it working, but the problem I have is although I get the 3 GR.15 shades, I can only get 4 GTIA 11 colours.  Any idea as to how to get the rest of GTIA 11 colours?

prog.lst 690 B · 8 downloads

The GTIA modes are just overlays. You can use Gr. 2 ,3 , or Gr. 8. 

As the GTIA modes were just overlays, you have to set the GPRIOR bits.

It means , you have to use a DLI for every scanline from line 120-150.

In basic it means to add and remove the 

Value 64  (gr.9)

Value 126 (gr.10)

Value 192 (gr.11)

Link to comment
Share on other sites

22 minutes ago, Stephen said:

Dumb question - I assume you are not just changing the ANTIC mode on the alternating lines, but also setting the appropriate GPRIOR register ($26F)?

Yes, my DLI on line-290 EOR's the value #192 (for GTIA 11) every scan-line, thus, 0 being in it on the Gr.15 line and 192 for the GTIA line which is stored into the hardware register of 623 (53275; $D01B).

 

Here's my DLI:

 

72                         pha

165 203                 lda 203

73 192                   eor #192

133 203                 sta 203

165 203                 lda 203

141 10 212            sta wsync

141 27 208            sta prior

104                       pla

64                         rti

 

Also @emkay.

 

EDT: I know my DLI is doing the right thing because otherwise I wouldn't get any colour, only 3 shades of white in Gr.15.

 

Edited by ac.tomo
Link to comment
Share on other sites

Is this just a simple case of you've told the system to be in gr.15? Because you use 'COLOR K' then this is going to effectively use an 'and #3' on the colour stated.

So maybe try it the other way around and use gr.11 (or gr.8 and gprior) and add gr. 15 lines to that.

 

If I try a hack such as '105 POKE 87,11' then you end up with a 141 error as the line drawing calcs mess up

 

[EDIT] ok, so you can use the hack, but re-adjust for the screen res.

360 FOR X=0 TO 159 STEP 10
365 POKE 87,15
370 COLOR K
380 PLOT X,Y:DRAWTO X+8,Y
384 COLOR L
385 POKE 87,11
386 PLOT X/2,Y+1:DRAWTO X/2+4,Y+1

 

Edited by Wrathchild
Link to comment
Share on other sites

33 minutes ago, Wrathchild said:

If I try a hack such as '105 POKE 87,11' then you end up with a 141 error as the line drawing calcs mess up

I tried something like that but changed the plot/draw values to be within scope, I got the 16 colours, but it didn't

look like what was expected, still trying :)

 

Link to comment
Share on other sites

51 minutes ago, Wrathchild said:

Is this just a simple case of you've told the system to be in gr.15? Because you use 'COLOR K' then this is going to effectively use an 'and #3' on the colour stated.

So maybe try it the other way around and use gr.11 (or gr.8 and gprior) and add gr. 15 lines to that.

 

If I try a hack such as '105 POKE 87,11' then you end up with a 141 error as the line drawing calcs mess up

 

[EDIT] ok, so you can use the hack, but re-adjust for the screen res.


360 FOR X=0 TO 159 STEP 10
365 POKE 87,15
370 COLOR K
380 PLOT X,Y:DRAWTO X+8,Y
384 COLOR L
385 POKE 87,11
386 PLOT X/2,Y+1:DRAWTO X/2+4,Y+1

 

I did try it all other ways around, but got the same problem (amoungst others), but thankyou very much for that. I was sure it was something like that, but I wasn't sure, I also never realised I could select GTIA modes with loc. 87.

Link to comment
Share on other sites

You have to change COLBAK as well.

In most modes it's the background colour which you'd usually want as 00.

 

In the GTIA colour only mode (11)  it's used for the background but is also ORed with the pixel colour to give it's brighness.

 

By default the OS will use value 06.

 

For your DLI you could use something like:

 

 pha

 lda 203

 eor #$C0

 sta 203

 sta wsync

 sta $d01b

 beq docolour

lda #$06

docolour sta $d01a

 pla

 rti

 

  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...