Since last release the examples for glium were moved into their own folder imgui-glium-examples.
This PR updates the instructions in README accordingly.
The previous commit added support for glutin 0.19.0.
glutin 0.19.0 depends on winit 0.18.0, which requires rust 1.28.0 or later.
Here is the full dependency chain:
glutin 0.19.0 > winit 0.18 > smithay-client-toolkit 0.4.2 > andrew 0.1.4 > rusttype 0.7.3 > ordered-float 1.0.1 (on linux)
ordered-float uses [repr(transparent)], which is now stabilised on latest rust,
hence the requirement for rust 1.28.0.
Custom texture example with glium backend:
- Generate a texture
- Load a texture from a JPG image
NB:
- Moved all the resources for examples (the fonts and the images) to a shared resources folder.
- Updated glium support module to expose GL context and Textures.
Use imgui-glutin-support in examples and split examples [use "exclude" Cargo.toml feature]
This implement the suggestions discussed in #163 and #168.
- Use imgui-glutin-support crate in all examples.
- Exclude examples from the main workspace to prevent glutin version conflicts
- Allow setting HIDPI factor to imgui-glutin-support crate for current examples to work on all platform.
Then, I committed a working Cargo.lock for the examples so that the correct version of glutin be selected in all cases.
To avoid conflicts in dependency version, this commit put examples using
different renderers in different crates.
Especially, glium and gfx do not necessarily depend on the same version
of glutin.
We have two examples:
- imgui-examples (main examples, use gfx renderer here)
- imgui-glium-examples (basic hello_glium example + maybe some texture stuff)
Once vulcano support lands, we may add: imgui-vulkano-examples.
This commit currently only moves files around. We plan to use gfx as a
"main2 renderer for now on as gfx is more actively maintained that
glium. Subsequent commits will migrate some glium examples to gfx.