Nurzhan Sakén
5461133a63
Replace line_drawing
with clipline
( #381 )
...
* Replaced `line_drawing` with `clipline`
* Update `clipline` to 0.1.1
2023-10-30 19:36:32 -05:00
erin petra sofiya moon
763a7a9b41
update wgpu to 0.17 ( #378 )
...
required changes are entirely trivial:
wgpu::util::initialize_adapter_from_env's signature changed;
the backend_bits parameter is removed, and now solely specified by
the instance's enabled backends (see [the changelog](https://github.com/gfx-rs/wgpu/blob/trunk/CHANGELOG.md#initialize_adapter_from_env-argument-changes )).
2023-10-29 23:49:07 -05:00
Jay Oster
b387ee2044
Update lockfile ( #382 )
...
* Update lockfile
Closes #377 and #380
* Bump MSRV for `cfg-expr` 0.15.5
`cfg-expr` is a transitive dependency for `minimal-tao` on Linux.
2023-10-29 23:08:03 -05:00
Kanabenki
705f22b60d
Add present mode setters on Pixels ( #373 )
...
* Add present mode setters on Pixels
* Add present mode getter on Pixels
2023-08-09 13:36:12 -07:00
Randommist
d140eba7c9
Added example for android ( #368 )
2023-07-02 18:49:41 -07:00
Jay Oster
39e84aacbe
Prepare 0.13.0 ( #365 )
2023-06-12 14:27:41 -07:00
Jay Oster
3891192796
Update dependencies ( #337 )
...
Breaking changes:
- Updates `wgpu` to 0.16
2023-06-11 21:25:25 -07:00
Jay Oster
cbda7df53b
Prepare 0.12.1 ( #357 )
2023-04-16 21:10:25 -07:00
Jay Oster
9f0a659853
Enable all wgpu backends ( #356 )
...
- This will allow `pixels` to run on platforms that have OpenGL without any extra configuration.
- It is better to allow wgpu to fallback to OpenGL than to select a Vulkan software rasterizer. This is the case on WSL2, where the only hardware-based adapter is available with the GLES backend.
- Fixes #354
2023-04-14 13:31:01 -07:00
Jay Oster
5465bbe28e
CI: Add cargo-install action to cache cargo-machete ( #355 )
2023-04-13 20:51:48 -07:00
imizao
d85091847a
Added R key to reset game ( #350 )
...
* Added R key to reset game
* Invaders, Shield, Player module processing
* Improve the processing of Shield and Player modules
2023-03-26 23:59:20 -07:00
Aggelos Tselios
3d8c7bd0c9
Switch from imgui.frame
to imgui.new_frame
, ( #353 )
...
The documentation said to do so: https://docs.rs/imgui/latest/imgui/struct.Context.html\#method.frame .
Signed-off-by: Aggelos Tselios <androtechgr@gmail.com>
Co-authored-by: Aggelos Tselios <androtechgr@gmail.com>
2023-03-26 14:45:14 -07:00
Jay Oster
96eef39a7a
Prepare 0.12.0 ( #349 )
...
* Prepare 0.12.0
* Cleanup use statements
2023-03-22 00:15:38 -07:00
imizao
e99c5eaa24
[Optimization] Improve readability ( #345 )
2023-03-21 23:57:48 -07:00
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
Aggelos Tselios
295139a412
Make Rust standard library optional (WIP) ( #342 )
...
* Remove `std` dependency.
* Format code with `cargo fmt`.
2023-03-16 15:13:36 -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
Aggelos Tselios
bbfd49deba
Add wgpu adapter
getter API ( #340 )
...
Co-authored-by: Jay Oster <jay@kodewerx.org>
2023-03-07 17:39:02 -08:00
Jay Oster
860559272a
Simplify surface texture format selection ( #336 )
...
- We require sRGB because that's the color space users expect when they are plotting their own pixels.
- It simplifies the fragment shader because we don't have to do a linear->gamma transformation. The hardware will do it for us.
2023-01-28 11:34:25 -08:00
Jay Oster
eede10ba42
Fix validation errors with WebGL2 backend ( #335 )
...
* Fix validation errors with WebGL2 backend
- view_formats are optional and should be empty unless a specific view format is needed.
- See: https://www.w3.org/TR/webgpu/#dom-gputexturedescriptor-viewformats
2023-01-28 11:19:45 -08:00
Jay Oster
c3f63a540d
Use type inference in custom_shader WGSL ( #334 )
2023-01-28 11:00:51 -08:00
Jay Oster
b54f707a59
Fix CI with new MSRV ( #333 )
...
- Required by wgpu 0.15
2023-01-27 22:31:52 -08:00
Jay Oster
332a02f12d
Update wgpu to 0.15 ( #332 )
...
* Update wgpu to 0.15
* Fix the panic described in #330
* Specify `min_binding_size` since we know what it is.
2023-01-27 21:49:40 -08:00
Jay Oster
bf296a455e
Remove unused dependencies (cargo-machete) ( #331 )
...
* Add cargo-machete to CI Lints
2023-01-09 10:47:42 -08:00
Jay Oster
49cf7b7d11
Update cargo-run-wasm ( #329 )
...
Just a minor dependency update.
2023-01-07 15:18:09 -08:00
Jay Oster
864a9c3491
Prepare 0.11.0 ( #326 )
2022-12-17 21:45:20 -08:00
Jay Oster
6055a21e6c
Fix minimal-egui rendering ( #327 )
2022-12-17 21:43:06 -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
Jay Oster
b4fc48c740
Change default PresentMode and update enable_vsync
( #325 )
...
- Fixes #263
2022-12-17 19:06:15 -08:00
Jay Oster
9e943dd9eb
Update README ( #324 )
2022-12-17 18:28:15 -08:00
Jay Oster
5c2985f1b6
Update all dependencies in the workspace ( #323 )
2022-12-17 17:35:02 -08:00
Jay Oster
0819b8f60c
Update GitHub Actions ( #322 )
...
* Update GitHub Actions
- actions-rs is unmaintained.
- See: https://github.com/actions-rs/toolchain/issues/216
- Enable rust-cache
- Cargo.lock was removed in #63 but it's necessary for reproducible builds in CI.
- The lock file is ignored by dependents.
- Our separate `pixels-ci-rust-version` repo also ignores it, so CI will still be able to tell us if the crate build ever breaks due to unlocked dependencies.
- See the `rust-version` job in ci.yml.
2022-12-17 16:52:45 -08:00
Jay Oster
7278681422
Fix the GitHub Actions badge ( #321 )
...
See: https://github.com/badges/shields/issues/8671
2022-12-17 14:46:32 -08:00
David Cristofaro
e8d5cf3ebc
Bump wgpu from 0.13
to 0.14
( #320 )
...
* feat(wgpu): upgrade wgpu from 13 to 14
* Address feedback
* Bump tao in `minimal-tao` example
* Bump fltk in `minimal-fltk` example
* Bump egui in `minimal-egui` example
* Bump MSRV to `1.65`
* Bump crates in `imgui-winit` example
* Delete `minimal-sdl2` example
* Fix clippy lints
* Update examples/minimal-egui/src/gui.rs
Co-authored-by: Zageron <hello@zageron.ca>
Co-authored-by: Jay Oster <jay@kodewerx.org>
2022-12-17 13:50:11 -08:00
Jeffrey Rosenbluth
bc8235fdb1
Add tiny-skia example ( #317 )
...
* tiny skia example
* image
* remove unnecessary let binding
2022-11-15 11:47:28 -08:00
Jay Oster
0a85025345
Prepare 0.10.0 ( #315 )
2022-10-28 17:10:03 -07:00
Jay Oster
9f7896cd2f
Replace just with cargo-run-wasm ( #310 )
2022-10-02 21:13:48 -07:00
Jay Oster
a2c639823f
Update winit 0.27 ( #302 )
...
* Update winit 0.27
Closes #292
This _does not_ update `winit` in the `imgui-winit` example. See https://github.com/parasyte/pixels/pull/302#issuecomment-1264483040 for discussion.
2022-10-01 14:27:21 -07:00
Jay Oster
9c3edeb1d4
HACK: Use old version of fltk to fix CI ( #306 )
...
See: https://github.com/fltk-rs/fltk-rs/issues/1285
2022-09-10 19:18:27 -07:00
Jay Oster
881033c5c7
Remove the exposed web feature ( #304 )
...
- The `web` feature was previously exposed by the example crate. This isn't really necessary.
- See #276 for discussion
2022-08-19 14:00:54 -07:00
Jay Oster
6605951d8c
Fix CI ( #301 )
...
- wgpu 0.13 requires Rust 1.59
2022-08-17 19:55:20 -07:00
Jay Oster
051a523ee6
Update wgpu to 0.13 ( #300 )
...
* Intial work towards wgpu 0.13
* Increase MSRV for egui
* Add missing texture formats
* Update fermium
- Replaces beryllium with our own hand-rolled high-level abstraction
layer for SDL2.
* Update dependencies
Co-authored-by: JMS55 <47158642+JMS55@users.noreply.github.com>
2022-08-17 17:30:04 -07:00
Jay Oster
bcbe9d84cb
Add minimal example with tao
( #299 )
...
* Add minimal example with `tao`
- Closes #298
2022-08-17 07:50:02 -07: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
4ee5006481
Add rust-version ( #295 )
...
- This version is different from the MSRV. It specifies the minimum
version required to build the crate and its direct dependencies.
- Add a CI step for building the crate alone with the oldest version
possible.
- See MSRV.md for the policy and minimal version supported by CI,
including all example code.
- Update all actions to checkout/v3
2022-08-01 14:59:46 -07:00
Jay Oster
41063dbf4b
Fix minimize panicking on custom-shader example. ( #291 )
...
- Closes #282
2022-07-27 10:26:05 -07:00
Jay Oster
46ddf4e3f0
Fix custom-shader example on macOS ( #286 )
...
- Fixes #258
2022-06-20 10:12:30 -07:00
Jay Oster
af821c9e49
Update egui to 0.18 ( #281 )
...
* Update egui to 0.18
- Closes #278
* Bump MSRV to 1.60.0 for egui
2022-06-13 21:03:06 -07:00
Jay Oster
adaa469ad9
Update gilrs ( #280 )
2022-06-13 09:24:59 -07:00
Jay Oster
8f66bce12e
Comparison with softbuffer
( #273 )
2022-04-25 07:00:30 -07:00