Log inRegister an accountBrowse CSDbHelp & documentationFacts & StatisticsThe forumsAvailable RSS-feeds on CSDbSupport CSDb Commodore 64 Scene Database
You are not logged in - nap
CSDb User Forums


Forums > C64 Coding > Black background when sideborder open
2018-09-15 00:38
Golara
Account closed

Registered: Jan 2018
Posts: 212
Black background when sideborder open

I've got this effect where I open almost the whole sideborder to show a "raster bar" go by the screen. Everything was working like normal until I replaced my macro loops with proper code generators. The effect is still working, but I've got a black background.


When you look at the normal view it looks like the sideborder is still closed but there's a sprite on top of it.



Any ideas ?
 
... 11 posts hidden. Click here to view all posts....
 
2018-09-15 01:11
Golara
Account closed

Registered: Jan 2018
Posts: 212
thanks. I'm kind of scared of clearing 3fff since the last time my code grew past it and I was injecting a brk into my code, debugging longer than I want to admit.
2018-09-15 09:10
Smasher

Registered: Feb 2003
Posts: 520
Quote:
I'm kind of scared of clearing 3fff (...)

it's called the ghost byte for a reason! :)
put a sprite at $3fc0 and $3fff is safe
2018-09-15 10:45
Raistlin

Registered: Mar 2007
Posts: 680
Yep, what they said. This is a really annoying thing with C64 as it means that if you use the $C000 bank, it gets nasty - $FFFF being part of the IRQ vector of course.
2018-09-15 10:54
Golara
Account closed

Registered: Jan 2018
Posts: 212
Yeah that's why I never used the last vic bank.
2018-09-15 12:16
Raistlin

Registered: Mar 2007
Posts: 680
It can be handy at times as well - D000-DFFF is a great place for static sprite data :-)
2018-09-15 12:48
Golara
Account closed

Registered: Jan 2018
Posts: 212
That's true. Honestly though I thought the ghostbyte is displayed in the sideborder too if it's open.
2018-09-15 13:42
Krill

Registered: Apr 2002
Posts: 2980
Quoting Raistlin
if you use the $C000 bank, it gets nasty - $FFFF being part of the IRQ vector of course.
Not so nasty, actually. Put 0 there and have the vector point to somewhere in zeropage, where you put a JMP to your interrupt handler. Only downside is 3 cycles delay of the handling code.

You can also enable extended background colour mode, and the idle pattern will be fetched from $FBFF instead of $FFFF.

Quoting Golara
Honestly though I thought the ghostbyte is displayed in the sideborder too if it's open.
While this would be quite cool, actually, there is no reason the idle pattern should be displayed in the sideborder.

It's displayed by part of the character/bitmap output logics, which only operates in the area between the sideborders, while not being fed actual character/bitmap data but the idle pattern instead due to running in the opened top and bottom borders or with disabled/delayed DMA (badline) generation.
2018-09-15 14:19
algorithm

Registered: May 2002
Posts: 705
Also as your irq covers the display area due to sideborder removal per line. you can write $00 to $ffff and then before irq ends, write back the hibyte of the irq
2018-09-15 21:20
Compyx

Registered: Jan 2005
Posts: 631
Quoting Krill
You can also enable extended background colour mode, and the idle pattern will be fetched from $FBFF instead of $FFFF.


I always thought that was $F9FF ?
2018-09-15 21:49
Golara
Account closed

Registered: Jan 2018
Posts: 212
All cool tricks posted here which I didn't think of. Another misconception that I had was that the 3fff byte was an index to the current charset, not just a representation of one line of graphics (is it ? I think it is...). Thinking back to the OFFENCE part from their x2010 demo where they seem to have a 3fff scroller and logo (big letters but inside is filled with small characters saying OFFENCE scrolling up and to the side)... I thought they are just ROLing that one char in the charset... so much cooler :D


Or maybe it's just sprites ? I thought it's a sprite mask covering up the 3fff.
Previous - 1 | 2 | 3 - Next
RefreshSubscribe to this thread:

You need to be logged in to post in the forum.

Search the forum:
Search   for   in  
All times are CET.
Search CSDb
Advanced
Users Online
wil
algorithm
Peacemaker/CENSOR/Hi..
Barfly/Extend
Guests online: 106
Top Demos
1 Next Level  (9.7)
2 13:37  (9.7)
3 Mojo  (9.7)
4 Coma Light 13  (9.6)
5 Edge of Disgrace  (9.6)
6 What Is The Matrix 2  (9.6)
7 The Demo Coder  (9.6)
8 Uncensored  (9.6)
9 Comaland 100%  (9.6)
10 Wonderland XIV  (9.6)
Top onefile Demos
1 Layers  (9.6)
2 No Listen  (9.6)
3 Cubic Dream  (9.6)
4 Party Elk 2  (9.6)
5 Copper Booze  (9.6)
6 Rainbow Connection  (9.5)
7 Dawnfall V1.1  (9.5)
8 Onscreen 5k  (9.5)
9 Morph  (9.5)
10 Libertongo  (9.5)
Top Groups
1 Performers  (9.3)
2 Booze Design  (9.3)
3 Oxyron  (9.3)
4 Triad  (9.3)
5 Censor Design  (9.3)
Top Crackers
1 Mr. Z  (9.9)
2 Antitrack  (9.8)
3 OTD  (9.8)
4 Fungus  (9.8)
5 S!R  (9.8)

Home - Disclaimer
Copyright © No Name 2001-2024
Page generated in: 0.046 sec.