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

Abstract Use of Pointers to Access Data #18

Open
dcvz opened this issue Jul 15, 2023 · 0 comments
Open

Abstract Use of Pointers to Access Data #18

dcvz opened this issue Jul 15, 2023 · 0 comments

Comments

@dcvz
Copy link
Collaborator

dcvz commented Jul 15, 2023

It'd be great to abstract the use of pointers to access data. There are some obvious places where pointers are being used:

  • run_dl() - the main method takes in a pointer to the start of the draw lists we iterate through
  • vertex, matrix commands - w1 points to location in memory where the vertices or matrices can be read
  • branch dl command - points to a location in memory where a new display list can be found

One possible way might be to introduce some kind of new Memory trait that implements some methods for grabbing the pointer to the display list and for branches.. as well as reading u8's and u16's for reading vertices and matrices.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant