Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modify blit segment spec #1105

Merged
merged 1 commit into from
May 30, 2020
Merged

Modify blit segment spec #1105

merged 1 commit into from
May 30, 2020

Conversation

ddelemeny
Copy link

The indexing scheme implemented to address spritesheet pages with the blit_segment feature feels a bit tedious, as keeping in mind that odd and even values mean BG and FG respectively and alternating indices requires some mental gymnastics.

This PR implements another way :
Page indexing goes from left to right then top to bottom, with index offsets to target bpp
This should feel more natural as it is the same indexing scheme as tiles.

Here's the revised full spec:

0000 SYS GFX
0001 FONT

0010 4bpp BG Page 0
0011 4bpp FG Page 0

0100 2bpp BG Page 0
0101 2bpp BG Page 1
0110 2bpp FG Page 0
0111 2bpp FG Page 1

1000 1bpp BG Page 0
1001 1bpp BG Page 1
1010 1bpp BG Page 2 
1011 1bpp BG Page 3
1100 1bpp FG Page 0
1101 1bpp FG Page 1
1110 1bpp FG Page 2
1111 1bpp FG Page 3

Editor and demo are modified accordingly.

Implement blit segment indexing scheme so that
contiguous pages have successive values
Copy link
Owner

@nesbox nesbox left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks

@nesbox nesbox merged commit 2f34ed8 into nesbox:master May 30, 2020
@nesbox nesbox added the API Issues related to TIC80 API label May 30, 2020
@nesbox nesbox added this to the 0.80.0 milestone May 30, 2020
@nesbox nesbox removed this from the 0.80.0 milestone Jul 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API Issues related to TIC80 API
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants