mirror of
https://github.com/gfx-rs/wgpu.git
synced 2025-12-08 21:26:17 +00:00
Minor tweaks to make CI happy
This commit is contained in:
parent
fb662dfbec
commit
54d7391df0
1
.github/workflows/ci.yml
vendored
1
.github/workflows/ci.yml
vendored
@ -35,6 +35,7 @@ jobs:
|
||||
run: cargo check --manifest-path wgpu-core/Cargo.toml --features trace --target ${{ env.TARGET }}
|
||||
|
||||
wasm:
|
||||
if: false # disable until hal/Gles backend is setup
|
||||
name: Web Assembly
|
||||
runs-on: ubuntu-18.04
|
||||
env:
|
||||
|
||||
2
Cargo.lock
generated
2
Cargo.lock
generated
@ -968,7 +968,7 @@ dependencies = [
|
||||
[[package]]
|
||||
name = "metal"
|
||||
version = "0.22.0"
|
||||
source = "git+https://github.com/kvark/metal-rs?branch=core-graphics-types#457518722ac2ca51cf1e668a2d2be57b751c8071"
|
||||
source = "git+https://github.com/kvark/metal-rs?branch=core-graphics-types#6e005374eaba2f9af368a81cdb2948ca29b3ff17"
|
||||
dependencies = [
|
||||
"bitflags",
|
||||
"block",
|
||||
|
||||
@ -25,10 +25,10 @@ If you are looking for the native implementation or bindings to the API in other
|
||||
|
||||
API | Windows 7/10 | Linux & Android | macOS & iOS |
|
||||
----- | ------------------ | ------------------ | ------------------ |
|
||||
DX11 | :ok: | | |
|
||||
DX12 | :white_check_mark: | | |
|
||||
DX11 | | | |
|
||||
DX12 | | | |
|
||||
Vulkan | :white_check_mark: | :white_check_mark: | |
|
||||
Metal | | | :white_check_mark: |
|
||||
GL ES3 | | :construction: | |
|
||||
GLes3 | | | |
|
||||
|
||||
:white_check_mark: = Primary support — :ok: = Secondary support — :construction: = Unsupported, but support in progress
|
||||
|
||||
@ -7,6 +7,6 @@ status = [
|
||||
"Ubuntu Nightly",
|
||||
"Windows Stable",
|
||||
"Windows Nightly",
|
||||
"Web Assembly",
|
||||
#"Web Assembly",
|
||||
#"Clippy",
|
||||
]
|
||||
|
||||
@ -18,11 +18,7 @@ impl crate::Adapter<super::Api> for super::Adapter {
|
||||
&self,
|
||||
features: wgt::Features,
|
||||
) -> Result<crate::OpenDevice<super::Api>, crate::DeviceError> {
|
||||
let queue = self
|
||||
.shared
|
||||
.device
|
||||
.lock()
|
||||
.new_command_queue_with_max_command_buffer_count(5);
|
||||
let queue = self.shared.device.lock().new_command_queue();
|
||||
Ok(crate::OpenDevice {
|
||||
device: super::Device {
|
||||
shared: Arc::clone(&self.shared),
|
||||
|
||||
@ -63,7 +63,7 @@ impl super::Surface {
|
||||
let screen: *mut Object = msg_send![window, screen];
|
||||
assert!(!screen.is_null(), "window is not attached to a screen");
|
||||
|
||||
let scale_factor: mtl::CGFloat = msg_send![screen, nativeScale];
|
||||
let scale_factor: CGFloat = msg_send![screen, nativeScale];
|
||||
let () = msg_send![view, setContentScaleFactor: scale_factor];
|
||||
}
|
||||
|
||||
|
||||
@ -640,14 +640,8 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
||||
count_offset: wgt::BufferAddress,
|
||||
max_count: u32,
|
||||
) {
|
||||
match self
|
||||
.device
|
||||
.extension_fns
|
||||
.draw_indirect_count
|
||||
.as_ref()
|
||||
.expect("Feature `DRAW_INDIRECT_COUNT` must be enabled")
|
||||
{
|
||||
super::ExtensionFn::Extension(t) => {
|
||||
match self.device.extension_fns.draw_indirect_count {
|
||||
Some(super::ExtensionFn::Extension(ref t)) => {
|
||||
t.cmd_draw_indirect_count(
|
||||
self.active,
|
||||
buffer.raw,
|
||||
@ -658,7 +652,7 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
||||
0,
|
||||
);
|
||||
}
|
||||
super::ExtensionFn::Promoted => {
|
||||
Some(super::ExtensionFn::Promoted) => {
|
||||
self.device.raw.cmd_draw_indirect_count(
|
||||
self.active,
|
||||
buffer.raw,
|
||||
@ -669,6 +663,7 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
||||
0,
|
||||
);
|
||||
}
|
||||
None => panic!("Feature `DRAW_INDIRECT_COUNT` not enabled"),
|
||||
}
|
||||
}
|
||||
unsafe fn draw_indexed_indirect_count(
|
||||
@ -679,14 +674,8 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
||||
count_offset: wgt::BufferAddress,
|
||||
max_count: u32,
|
||||
) {
|
||||
match self
|
||||
.device
|
||||
.extension_fns
|
||||
.draw_indirect_count
|
||||
.as_ref()
|
||||
.expect("Feature `DRAW_INDIRECT_COUNT` must be enabled")
|
||||
{
|
||||
super::ExtensionFn::Extension(t) => {
|
||||
match self.device.extension_fns.draw_indirect_count {
|
||||
Some(super::ExtensionFn::Extension(ref t)) => {
|
||||
t.cmd_draw_indexed_indirect_count(
|
||||
self.active,
|
||||
buffer.raw,
|
||||
@ -697,7 +686,7 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
||||
0,
|
||||
);
|
||||
}
|
||||
super::ExtensionFn::Promoted => {
|
||||
Some(super::ExtensionFn::Promoted) => {
|
||||
self.device.raw.cmd_draw_indexed_indirect_count(
|
||||
self.active,
|
||||
buffer.raw,
|
||||
@ -708,6 +697,7 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
||||
0,
|
||||
);
|
||||
}
|
||||
None => panic!("Feature `DRAW_INDIRECT_COUNT` not enabled"),
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user