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 > Issues with Double Buffering $0400+$0c00, $d011, vertical scrolling
2017-01-02 20:03
wbochar

Registered: May 2002
Posts: 29
Issues with Double Buffering $0400+$0c00, $d011, vertical scrolling

I'm having some screen jitter, when doing vertical scrolling. The basic overview is I have open top and bottom borders, with sprites in them (acting as blockers and a Logo). I also have a fixed text line in the upper screen
and text/char bitmap that is the bottom half. The lower half is about 14 char lines (with a total bitmap size of 63 char lines). The screen is double buffered, so $0400 and $0c00 flip back and forth. The Bitmap drawing is done 2 lines at
a time, over 7 frames on the 8th frame the screen banks flip and the bitmap is moved up one charline. This works fine, No glitches or anything.

The moment I start messing with $d011 vertical scroll, it works but there are a lot of glitches..

Layout below:

A.=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
A.=-=-SPRITE IMAGE UPPER BORDER-=-=-=-=-
B.=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

C.        Fixed Text Line

D.========SPRITE BLOCKER MID============
E.00000000000000000000000000000000000000
E.99999999999999999999999999999999999999
E.88888888-TEXT/CHAR IMAGE -888888888888
E.77777777777777777777777777777777777777
E.66666666666666666666666666666666666666
F.-=-SPRITE BLOCKER LOWER BORDER-=-=-=-=

All done through IRQ's:

A. Open Border with $D011, Display Sprite Logo
B. Fixed $d011 AND#248 to ORA#7, so the text stays still
C. After text line is rendered, Apply Lower screen scroll value from YScroll variable/label
D. After mid blocker sprites render/set, Play Music Routine (disabled)
E. Setup lower Blocker Sprites
F. Open Border, Frame Calculations, Set YScroll Value and 2/14 lines of the character bitmap.

Is my logic correct for when I do things? Is there something
that I am missing when I switch screen banks and YScrolling?

-wbochar
2017-01-02 20:46
Oswald

Registered: Apr 2002
Posts: 5094
wild guess:

maybe you should try to time your finescroll write to d011 so, that its on the last line of the previous text row, or first row of next char row.

description or screenshot of the glitch would help a lot to understand what goes wrong.
2017-01-03 04:16
The Phantom

Registered: Jan 2004
Posts: 360
Are you jsr'ing to your yscroll routine in the area you are scrolling?
2017-01-03 14:30
Martin Piper

Registered: Nov 2007
Posts: 722
Are you accidentally triggering a line crunch when you don't want one?
Link to a prg would help. :)
2017-01-15 03:36
wbochar

Registered: May 2002
Posts: 29
Quoting Oswald
wild guess:

maybe you should try to time your finescroll write to d011 so, that its on the last line of the previous text row, or first row of next char row.

description or screenshot of the glitch would help a lot to understand what goes wrong.



-- Yup, that's the one. I was triggering a scroll through an ora from a subtracted value, which was 1 step out of alignment. So it would bounce from 0 to 7 then flip banks. Being able to slow things to crawl really helps debug that kind of thing.
2017-01-15 09:42
Oswald

Registered: Apr 2002
Posts: 5094
thats a different bug than what I was thinking of. but doesnt matter, hooray you found it :)
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
wacek/arise
A3/AFL
oziphantom
Impetigo/Crescent
Airwolf/F4CG
wil
Guests online: 98
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.043 sec.