Commit Graph

2775 Commits

Author SHA1 Message Date
Connor Fitzgerald
a6d020fd63
Update changelog 2022-11-30 17:13:10 -05:00
Jim Blandy
7c491c0d14 Remove indentation from doc comments.
The indentation in `command/bundle.rs` and `swap_chain.rs` causes
rustdoc to interpret these comments as code, which it then tries to
parse. Removing the indentation persuades it that they are text.
2022-09-02 14:10:00 -07:00
Jim Blandy
4f9e82a77d Placate Clippy 0.1.63. 2022-09-02 14:10:00 -07:00
Frank Steffahn
18071599a7 Fix build failure due to rust-lang/rust PR 99413 2022-09-02 14:10:00 -07:00
bors[bot]
0084d68c60
Merge #1683
1683: [Backport 0.9] adapter specific render targets r=kvark a=Wumpf

Backport of #1528
Fixes #1682 

clean cherry-pick except for generic name adjustment

Co-authored-by: Alex S <alex0player@gmail.com>
Co-authored-by: Andreas Reich <r_andreas2@web.de>
2021-07-17 18:32:44 +00:00
Andreas Reich
42df6d8d37 Bump wgpu-core version + changelog entry 2021-07-17 20:25:16 +02:00
Alex S
14491d9c16 Support TEXTURE_SPECIFIC_FORMAT_CAPABILITIES for rendertargets. 2021-07-17 08:58:38 +02:00
Dzmitry Malyshau
a18f9463c1 Bump wgpu-core to 0.9.1 2021-07-13 11:41:04 -04:00
Aron Granberg
26ba184836 Fix check for QUERY_SET_MAX_QUERIES was using >= instead of > 2021-07-13 11:33:17 -04:00
Dzmitry Malyshau
33dee76462 Fix pipeline statistics stride 2021-07-13 11:28:06 -04:00
bors[bot]
087253dbb5
Merge #1564
1564: Fix query resolve not marking buffer as initialized r=cwfitzgerald a=Wumpf

**Connections**
As mentioned in #1559, this fixes #1374 for v0.9

**Description**
(see desc)

**Testing**
* added new test
* mipmap sample



Co-authored-by: Andreas Reich <r_andreas2@web.de>
2021-06-27 21:16:50 +00:00
bors[bot]
2cfc09de5a
Merge #1561
1561: [v0.9] fix buffer inits being delayed by a frame r=kvark a=Wumpf

**Connections**
Fixes #1555

**Description**
Fix buffer inits being inserted into the next submit call
Haven't checked how long this issue exists already, but this pretty much kills all user data that is generated by rendering/compute

**Testing**
Tested on provided repro project in ticket. Pretty bad bug so would like to see a regression test but can't come up right now with anything easier than the taking over the given example :/

Co-authored-by: Andreas Reich <r_andreas2@web.de>
2021-06-27 14:34:54 +00:00
Andreas Reich
3cf52de1e1 fix buffer inits being delayed by a frame
leading potentially to stomping previous results

Fixes #1555
2021-06-27 13:50:30 +02:00
Andreas Reich
34e770b281 Fix query resolve not marking buffer as initialized
-> on uninitialized buffers query results would be overriden with 0
2021-06-27 08:22:05 +02:00
Dzmitry Malyshau
b6a6a67534 Adjust cargo.toml for wgpu-rs 2021-06-19 01:45:14 -04:00
Connor Fitzgerald
c1cc70e510 Switch gfx and naga to crates 2021-06-19 01:39:35 -04:00
Connor Fitzgerald
b07c50ede4 Relicense to MIT/Apache 2021-06-19 01:39:35 -04:00
Dzmitry Malyshau
44243d82c5 Hot patch for temp_suspected tracking 2021-06-19 01:39:35 -04:00
Dzmitry Malyshau
51c3eeaec8 Change the order to suspect temporary resources earlier 2021-06-19 01:39:35 -04:00
Connor Fitzgerald
f35be2b5e7 Fix validation issue with shadow example 2021-06-19 01:39:35 -04:00
Connor Fitzgerald
d028dd89b2 Update naga to gfx-26 and bump gfx 2021-06-19 01:39:35 -04:00
Connor Fitzgerald
9d9c9c4956 Updated changelog for 0.9 2021-06-19 01:39:35 -04:00
bors[bot]
a92b8549a8
Merge #1474
1474: Add clear buffer/image to wgpu-rs api r=kvark a=Wumpf

Follow up to  #1335

Started using this in Blub fluid sim a little bit on volume textures, works nicely 432fb75a68, more to come

Co-authored-by: Andreas Reich <r_andreas2@web.de>
2021-06-06 00:07:03 +00:00
bors[bot]
8e8f59af7c
Merge #1479
1479: fix typo regarding structure rename in changelog r=kvark a=profan

**Description**
Just fixing a typo I realised was there when trying to use the changelog to fix my code, thanks for adding a list of changes to the latest changelogs!


Co-authored-by: Robin Hübner <robinhubner@gmail.com>
2021-06-05 22:29:01 +00:00
Robin Hübner
bc0c86a47a
fix typo regarding structurer rename in changelog 2021-06-05 22:09:06 +01:00
Andreas Reich
99e691932d add clear buffer/image to wgpu-rs api 2021-06-05 11:49:13 +02:00
bors[bot]
7978df83ef
Merge #1470
1470: Validate pipeline state formats r=cwfitzgerald a=kvark

**Connections**
Fixes #1425

**Description**
We weren't validating any of the pipeline formats.

**Testing**
Manually tested, e.g.:
```
    Caused by:
        In Device::create_render_pipeline
          note: label = `shadow`
        depth/stencil state is invalid
        format Rgba8UnormSrgb does not have a depth aspect, but depth test/write is enabled
```

Co-authored-by: Dzmitry Malyshau <kvarkus@gmail.com>
2021-06-04 23:32:18 +00:00
Dzmitry Malyshau
cfc6792c82 Validate pipeline state formats 2021-06-03 10:30:35 -04:00
bors[bot]
c7576553ba
Merge #1469
1469: Handle winit exception in web to avoid breaking async executor r=grovesNL a=Frizi

This is a continuation of https://github.com/gfx-rs/wgpu-rs/pull/923.

I'd still like to fix this on our end, even if the real underlying issue is in winit. The fix is small, and we can migrate to the proper winit solution once it exists. In the mean time, we can continue working on improving webgl support without a major blocker.

Co-authored-by: Frizi <frizi09@gmail.com>
2021-06-03 11:25:46 +00:00
Frizi
07376d11e8 Handle winit exception in web to avoid breaking async executor 2021-06-03 13:02:56 +02:00
Dzmitry Malyshau
e4b0de2526 Links updates 2021-06-02 23:54:26 -04:00
Dzmitry Malyshau
900a141392 Work around CI failures on hello-compute 2021-06-02 22:48:33 -04:00
Dzmitry Malyshau
a6ff3ea086 Merge changelogs and readmes 2021-06-02 21:50:16 -04:00
Dzmitry Malyshau
4fc478513a Merge ../wgpu-rs into reunion 2021-06-02 21:31:02 -04:00
bors[bot]
6566a6ce49 [rs] Merge #920
920: Bunnymark example r=grovesNL a=kvark



Co-authored-by: Dzmitry Malyshau <kvarkus@gmail.com>
2021-06-02 16:20:43 +00:00
Sean Moulton
9bdc65e5f7 [rs] Add include_wgsl!() macro (#922)
* Add include_wgsl macro

* Add include_wgsl macro

* Change ShaderFlags to all
2021-06-01 22:31:02 -04:00
Dzmitry Malyshau
e98f36245b [rs] Framework and README update 2021-06-01 09:54:44 -04:00
Dzmitry Malyshau
f438f0b920 [rs] Bunnymark example 2021-06-01 09:19:19 -04:00
bors[bot]
6e680d96a4 [rs] Merge #921
921: Update wgpu to eadaa1b7d8 r=kvark a=kvark

Picks up https://github.com/gfx-rs/wgpu/pull/1419, https://github.com/gfx-rs/wgpu/pull/1417, and https://github.com/gfx-rs/wgpu/pull/1403

Co-authored-by: Dzmitry Malyshau <kvarkus@gmail.com>
2021-06-01 13:10:49 +00:00
Dzmitry Malyshau
ac6276dfb5 [rs] Update wgpu to eadaa1b7d8 2021-06-01 09:02:19 -04:00
bors[bot]
eadaa1b7d8
Merge #1419
1419: Skip the cube compatibility on a downlevel flag r=cwfitzgerald a=kvark

**Connections**
Fixes #1418

**Description**
Adds a downlevel flag for cube arrays, checks for it.

**Testing**
Untested, but should work.

Co-authored-by: Dzmitry Malyshau <kvarkus@gmail.com>
2021-06-01 12:44:53 +00:00
Dzmitry Malyshau
beb88b0a88 Skip the cube compatibility on a downlevel flag 2021-06-01 08:29:44 -04:00
bors[bot]
9cd01635d7
Merge #1417
1417: Split the tracker into stateful/stateless to reduce the overhead r=cwfitzgerald a=kvark

**Connections**
Implements https://github.com/gfx-rs/wgpu/issues/1413#issuecomment-851604344
Reduces the overhead for resource tracking in the Animometer benchmark by up to 50%.

**Description**
We used to use the full tracker set on the usage scopes associated with compute/render passes. A resource tracker has 2 responsibilities: ensuring the resource is held alive, and validating and recording the state transitions. This PR exploits the fact that the latter responsibility is only applicable for buffers and textures. So doing all the lifetime tracking for a pass is a waste: we can instead just attach the lifetimes to the parent command buffer, straight.

In the Animometer benchmark, there is one large buffer, and thousands of bind groups pointing to different offsets into it. The old code would fill up the pass tracker with those bind groups, and then merge it into the command buffer tracker. The new code would just fill up the command buffer tracker instead. Since there is only one buffer, the pass tracking becomes much lighter.

**Testing**
Untested. It would be nice to have some benchmarks here, possibly after #1397 ?

Co-authored-by: Dzmitry Malyshau <kvarkus@gmail.com>
2021-06-01 06:45:05 +00:00
bors[bot]
c332c7fffe
Merge #1403
1403: Trace render passes before they are ran r=cwfitzgerald a=kvark

**Connections**
Follow-up to #1245 

**Description**
We want the API traces to reproduce issues. Previously, we moved all the resource creation to happen after the trace is written.
This PR follow-up by also recording the render pass commands even in the case where one of them triggers a validation error.

Another big part of the PR now is handling the command buffers that failed for some reason. The submission is skipping them now instead of erroring the whole thing.

**Testing**
Tested manually on wgpu-rs examples

Co-authored-by: Dzmitry Malyshau <dmalyshau@mozilla.com>
2021-06-01 06:31:28 +00:00
Lucien Greathouse
ba041e4451
Expand 0.8.0 Changelog (#1420)
* humble beginnings

* Current progress

* More precise NonZeroU32 change

* Fix typo

* Changelog enough to get my game to compile again

* Fix type change line
2021-06-01 02:03:59 -04:00
Dzmitry Malyshau
7b7e72b1c2 Split the tracker into stateful/stateless to reduce the overhead 2021-05-31 14:18:44 -04:00
Wumpf
f62d0d5edc
Native Extension: Expose fill buffer & clear image (#1335)
* Add command buffer fill buffer method

* Added test for buffer fill

* Added image clear + test

* image/buffer clear methods are now pure clear to zero

* fix cargo clippy & int type issues

* clear buffer alignment is now given by COPY_BUFFER_ALIGNMENT

* joined buffer/image clear player tests

* ImageSubresourceRange is now used in TextureViewDescriptor
2021-05-30 11:03:33 -04:00
bors[bot]
cb18541221 [rs] Merge #918
918: Specify latest gfx release branch in README r=kvark a=grovesNL

Specify latest gfx release branch in README, to hopefully avoid people checking out `hal-0.2` then wondering why the patch doesn't seem to do anything.

Co-authored-by: Joshua Groves <josh@joshgroves.com>
2021-05-29 23:35:06 +00:00
Joshua Groves
2a42e73eef [rs] Specify latest gfx release branch in README 2021-05-29 14:56:56 -02:30
Dzmitry Malyshau
e9d2f402f1 Improve handling of erroring command buffers on submission 2021-05-20 15:35:14 -04:00