Closed angered-ghandi closed 8 years ago
How does it work with SDL? It doesn't look like it has a rust-sdl2 backend, so that would need to be implemented. This is further complicated by the primitives it offers, such as polygons.
How does it play into the entity component system? This seems tricky because the input would need to be handled in a system, but the rendering would need to happen in a render system. It could potentially use the current code path used for drawing debug graphics from a normal system.
How easy would it be to abstract it away? Not certain.
How easy would it be to skin with the actual AOE graphics? It supports theming, so this may not be so bad.
Would it be less effort in the long run to roll our own? This is difficult to say. It will be a lot of up-front effort getting it working in the first place, but it'll probably save time once it's up and running. Rolling our own is also a lot of up-front effort (especially in regards to writing widgets). It's probably worth it to enumerate the widgets needed and the estimated work for each.
How would a non-conventional GUI widget such as a mini-map work? It looks like Conrod has the ability to write custom widgets, so this should be possible.
Other notes It looks like Conrod is tightly coupled with the pistoncore-input and piston-viewport crates.
Assessment: Need to do more research
Widget list:
All widgets can use their own fonts and style of drawing those fonts (for example, some of them are outlined by another color).
The font outlining throws a monkey wrench at Conrod since it's using rusttype's gpu-cache. It doesn't look like there's a way to force it to use a larger rectangle for a glyph so that outline pixels can be added.
From looking at the issue list for the Conrod 1.0 milestone, it's clear that it's not yet suitable for OpenAOE. It looks like it currently doesn't support multiple fonts and image buttons.
While it may not be suitable now, it definitely looks promising in the distant future. Resolving this for now with the decision to write our own GUI.
Conrod is a Rust GUI library that isn't quite stable yet, but is probably the furthest along. Evaluate using it in OpenAOE. Questions that need to be answered: