Jay Oster
5a96eea6ba
Handle all wgpu::SurfaceError variants ( #348 )
...
This fixes error handling for all `wgpu::SurfaceError` variants. It also adds more context to error messages printed by the examples.
Closes #346
2023-03-21 07:16:51 -07:00
Jay Oster
899e27bafa
Remove get_ and set_ prefixes from public APIs ( #341 )
...
This renames:
- `get_frame` to `frame`
- `get_frame_mut` to `frame_mut`
- `set_clear_color` to `clear_color`
Which more closely follows convention set by the standard library et al.
2023-03-09 19:42:57 -08:00
Jay Oster
6f4fa6c967
Fix invalid texture sizes ( #250 )
...
- Makes methods fallible when they create textures.
- Correctly handle window resize in fltk example.
- TODO: tests
- Closes #240
2022-12-17 20:21:28 -08:00
Alex
0b380b637d
Allow accessing frame on immutable buffer ( #288 )
...
* Allow accessing frame on immutable buffer
* Rename `get_frame` to `get_frame_mut`
* Use `get_frame_mut` in examples
2022-08-14 15:44:23 -07:00
Jay Oster
c1962ae35c
Update dependencies ( #230 )
...
* Move to Edition 2021
* Update `wgpu`, `raw-window-handle`, and all dependencies for the examples
* Update MSRV
* Closes #244
2021-12-31 14:57:57 -08:00
Jay Oster
efeec7f727
Fix minimal-fltk
example release builds with Rust 1.56.0 ( #216 )
...
- See https://github.com/rust-lang/rust/issues/88576
2021-10-21 16:15:47 -07:00
Jay Oster
e08c91bfd2
Update to wgpu 0.10 ( #187 )
...
- It would be nice to return an error from the render function
- imgui-winit is still a WIP (open PR: https://github.com/Yatekii/imgui-wgpu-rs/pull/66 )
- Update README
Co-authored-by: Mohammed Alyousef <mohammed.alyousef@neurosrg.com>
2021-09-01 14:50:43 -07:00
Jay Oster
23da739650
Update fltk ( #169 )
...
- Fixes #163
- Reimplements window resize
- Still has problems on macOS; Resizing with the drag handle blocks the main loop. See:
- https://github.com/glfw/glfw/issues/1251
- https://github.com/rust-windowing/winit/issues/219
2021-05-29 03:27:33 -07:00
Jay Oster
8071f34a1f
Rename resize
to resize_surface
( #149 )
...
- Also cleanup documentation.
- Workaround FLTK window resize issues by disabling resizability.
2021-03-09 04:15:24 -08:00
Mohammed Alyousef
f845d59213
add fltk example ( #137 )
...
* add fltk example
* fix clippy lint
* fix rustfmt check
* add missing trailing new line
* use no-pango feature
* remove call to win.draw()
2021-02-07 10:36:21 -08:00