-
Notifications
You must be signed in to change notification settings - Fork 112
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
Pre computed display lists #489
Comments
@snacchus have plans for a new graphics api, but I am not sure if it will have a pre-baked display lists. The original reason why we didn't want it was that it requires locking in the DL format as it becomes data at that point and doesn't allow for dynamic changes at runtime. I am sure they will provide more information around the topic. Also genereting lists at load time is not that bad in general. OTOH, I think the ability to also baking in the transformations might make sense in sone situations. I mean if a transformation is in a dl, you can pre compute all of the RSP commands, ogl api allows for that. The use case I had in mind is precomputing the environment of a shoot'em up ahead of time and then paying only the RDP cost at runtime, freeing up a lot of room for dynamic stuff. Still, want to hear opinions around this? |
The new graphics API won't include precomputed display lists. In fact, the concept of display lists will be entirely orthogonal to it, as opposed to GL. That means you can put calls from the new API into DLs if you want (note that the libdragon term for DL is "block"), regardless of being precomputed or not. |
That makes sense. I guess a good compromise would be a block format that can be loaded quickly, so maybe the format is close to its final representation in memory but needs only minimal work to finish formatting it. I can probably be content with gl lists for now. Maybe if I find resource loading to be a bottle neck do I try to optimize it further. |
We could borrow the idea from libultra where display lists are generated from macros. That way the macro becomes the interface that tools can target but the implementation of the macro could change. |
Right, a set of macros certainly seems like a more maintainable public API than pure binary data. I think it could be worth experimenting with. |
I just like the idea of faster, closer to hardware control. Maybe after using it more extensively my opinion will change. |
That's completely understandable, since GL as an API is quite detached from the hardware and induces a non-negligible amount of overhead. This "new API" that has been mentioned a couple of times in this thread will hopefully help in this regard. It's still in the design phase, but it will be a completely custom graphics API that is tailored to the hardware with the goal of allowing more efficient utilization. It's called "magma" and I'm currently working on it on my fork: https://github.com/snacchus/libdragon/tree/magma |
Are there any plans for rdpq pre computed display list? I want to be able to load display lists from the cartridge with minimal code to process them into usable display lists by the RCP. I know there is glGenLists for the opengl implementation but I am wondering if there are plans to have a lower level and faster way of achieving the same thing. I can help out with the implementation but I figured I would ask here if there were any plans for it and ideas on how a potential interface for usage could look
The text was updated successfully, but these errors were encountered: