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 > Ghostbyte / garbage / $3FFF
2008-12-05 11:57
Mace

Registered: May 2002
Posts: 1799
Ghostbyte / garbage / $3FFF

Discussion about the ghostbyte in the comment of Aliens:

Quoting Jammer
so for what extent can i control this 'garbage'? in terms of chars and colours.

The ghostbyte is always black.
It occurs in the upper and lower border, when opened, but also in the 'void' that is created with an FLD routine.

If you want that effect as seen in Aliens, you have to write values to $3FFF in a raster routine.
The byte is repeated over the entire width and height of the borders, as the patterns shows.

BTW, I can't remember ever seeing a 'split raster' in $3FFF...
 
... 46 posts hidden. Click here to view all posts....
 
2008-12-07 21:18
Mace

Registered: May 2002
Posts: 1799
@ Krill: ah, I see! Interesting.

:-)
2008-12-08 09:23
Cruzer

Registered: Dec 2001
Posts: 1048
Monte Carlos: ah, I see! Interesting.

Not sure what it can be used for, but always fascinating to learn something new about something you thought you knew everything about.
2016-05-26 21:32
Scan

Registered: Dec 2015
Posts: 110
Today I ran into something I think is odd. I've got the ghostbyte in a sprite when displaying it in the right side border from X position $68 and up. I get a line the width of a sprite a line above the sprite, of which the middle 8 pixels can be changed using the ghostbyte at $3fff. I've uploaded a demonstration here. GhostbyteInSprite Anyone an idea why this is happening?
2021-03-05 11:58
w4rp8

Registered: Oct 2010
Posts: 9
I see, atleast in vice, that some bits of the ghostbyte could be masked by writing to $d020, $d021 ($d022, $d023 too, but not that stable without further stabilzising timing on the writes).
This works with unstable writes:
ldy color
lda #$27
!:cmp $d012
bcs !-
sty $d020

For such a line the ghostbyte goes from 0x33 to 0x21 without touching $7fff.

I saw this appearing in vice 2.4 only with 7 sprites enabled over that lines. vice 3.3 shows that behaviour, and also in areas without sprites enabled, but not as stable, more like writing to $d022.
2021-03-05 12:14
w4rp8

Registered: Oct 2010
Posts: 9
Actually i just realised that ghost byte content is set to 0x21 and gets changed to 0x33 in lines without writing to $d020 but also with the sprite layer over it.
When incrementing $7fff each frame, it can be seen that it follows some pattern for different ghostbyte values.
2021-03-05 14:38
Compyx

Registered: Jan 2005
Posts: 631
Uhm, that isn't quite correct.

Ghostbyte has nothing to do with any color registers, it simply takes the last byte of a VICII bank, or when using ECM it 'folds' the last charset RAM into $01ff and thus uses $39ff vs $3fff or $79ff vs $7fff.

When you use hires ($3x at $d011) and single color ($0x at $d016), the upper and lower border will always be black*.

* = when opening the upper/lower border.
2021-03-05 15:59
w4rp8

Registered: Oct 2010
Posts: 9
Ok, so I looked a bit into it. Following is happening:
- the enabled sprites were just shifting the timing, the thing also works with sprites disabled
- mode ist multicolor bitmap, so $3fff is displayed in what Krill called double pixel mode
- if you write to $d020, $d021 the $3fff is displayed in its original pattern on that line

so I assume beside a change of the $3fff pattern by setting the rastercolor, this wouldn't gain anything more.
2021-03-05 16:21
Compyx

Registered: Jan 2005
Posts: 631
Well with the ghostbyte you can render black pixels over whatever $d021 displays. I think you can also set sprite priority so the ghostbyte will cover the sprites. Not sure about that one, I'd have to check that.
2021-03-05 16:55
Copyfault

Registered: Dec 2001
Posts: 466
Quoting Compyx
...
I think you can also set sprite priority so the ghostbyte will cover the sprites. Not sure about that one, I'd have to check that.
Can confirm, used it in some -yet unreleased- code ;)
2021-03-05 17:30
Krill

Registered: Apr 2002
Posts: 2852
You both seem to be ignoring or misreading what w4rp8 is implying here.

If i understand correctly, this is about glitching the rendering of the idle byte by just writing to seemingly unrelated colour registers, and that glitching causes it to be briefly rendered with black hires pixels in multicolour mode rather than black brick pixels.
Previous - 1 | 2 | 3 | 4 | 5 | 6 | 7 - 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
Guests online: 117
Top Demos
1 Next Level  (9.8)
2 Mojo  (9.7)
3 Coma Light 13  (9.7)
4 Edge of Disgrace  (9.6)
5 Comaland 100%  (9.6)
6 No Bounds  (9.6)
7 Uncensored  (9.6)
8 Wonderland XIV  (9.6)
9 Memento Mori  (9.6)
10 Bromance  (9.5)
Top onefile Demos
1 It's More Fun to Com..  (9.7)
2 Party Elk 2  (9.7)
3 Cubic Dream  (9.6)
4 Copper Booze  (9.5)
5 TRSAC, Gabber & Pebe..  (9.5)
6 Rainbow Connection  (9.5)
7 Dawnfall V1.1  (9.5)
8 Quadrants  (9.5)
9 Daah, Those Acid Pil..  (9.5)
10 Birth of a Flower  (9.5)
Top Groups
1 Nostalgia  (9.3)
2 Oxyron  (9.3)
3 Booze Design  (9.3)
4 Censor Design  (9.3)
5 Crest  (9.3)
Top Organizers
1 Burglar  (9.9)
2 Sixx  (9.8)
3 hedning  (9.7)
4 Irata  (9.7)
5 MWS  (9.6)

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