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 }}
|
run: cargo check --manifest-path wgpu-core/Cargo.toml --features trace --target ${{ env.TARGET }}
|
||||||
|
|
||||||
wasm:
|
wasm:
|
||||||
|
if: false # disable until hal/Gles backend is setup
|
||||||
name: Web Assembly
|
name: Web Assembly
|
||||||
runs-on: ubuntu-18.04
|
runs-on: ubuntu-18.04
|
||||||
env:
|
env:
|
||||||
|
|||||||
2
Cargo.lock
generated
2
Cargo.lock
generated
@ -968,7 +968,7 @@ dependencies = [
|
|||||||
[[package]]
|
[[package]]
|
||||||
name = "metal"
|
name = "metal"
|
||||||
version = "0.22.0"
|
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 = [
|
dependencies = [
|
||||||
"bitflags",
|
"bitflags",
|
||||||
"block",
|
"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 |
|
API | Windows 7/10 | Linux & Android | macOS & iOS |
|
||||||
----- | ------------------ | ------------------ | ------------------ |
|
----- | ------------------ | ------------------ | ------------------ |
|
||||||
DX11 | :ok: | | |
|
DX11 | | | |
|
||||||
DX12 | :white_check_mark: | | |
|
DX12 | | | |
|
||||||
Vulkan | :white_check_mark: | :white_check_mark: | |
|
Vulkan | :white_check_mark: | :white_check_mark: | |
|
||||||
Metal | | | :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
|
:white_check_mark: = Primary support — :ok: = Secondary support — :construction: = Unsupported, but support in progress
|
||||||
|
|||||||
@ -7,6 +7,6 @@ status = [
|
|||||||
"Ubuntu Nightly",
|
"Ubuntu Nightly",
|
||||||
"Windows Stable",
|
"Windows Stable",
|
||||||
"Windows Nightly",
|
"Windows Nightly",
|
||||||
"Web Assembly",
|
#"Web Assembly",
|
||||||
#"Clippy",
|
#"Clippy",
|
||||||
]
|
]
|
||||||
|
|||||||
@ -18,11 +18,7 @@ impl crate::Adapter<super::Api> for super::Adapter {
|
|||||||
&self,
|
&self,
|
||||||
features: wgt::Features,
|
features: wgt::Features,
|
||||||
) -> Result<crate::OpenDevice<super::Api>, crate::DeviceError> {
|
) -> Result<crate::OpenDevice<super::Api>, crate::DeviceError> {
|
||||||
let queue = self
|
let queue = self.shared.device.lock().new_command_queue();
|
||||||
.shared
|
|
||||||
.device
|
|
||||||
.lock()
|
|
||||||
.new_command_queue_with_max_command_buffer_count(5);
|
|
||||||
Ok(crate::OpenDevice {
|
Ok(crate::OpenDevice {
|
||||||
device: super::Device {
|
device: super::Device {
|
||||||
shared: Arc::clone(&self.shared),
|
shared: Arc::clone(&self.shared),
|
||||||
|
|||||||
@ -63,7 +63,7 @@ impl super::Surface {
|
|||||||
let screen: *mut Object = msg_send![window, screen];
|
let screen: *mut Object = msg_send![window, screen];
|
||||||
assert!(!screen.is_null(), "window is not attached to a 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];
|
let () = msg_send![view, setContentScaleFactor: scale_factor];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -640,14 +640,8 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
|||||||
count_offset: wgt::BufferAddress,
|
count_offset: wgt::BufferAddress,
|
||||||
max_count: u32,
|
max_count: u32,
|
||||||
) {
|
) {
|
||||||
match self
|
match self.device.extension_fns.draw_indirect_count {
|
||||||
.device
|
Some(super::ExtensionFn::Extension(ref t)) => {
|
||||||
.extension_fns
|
|
||||||
.draw_indirect_count
|
|
||||||
.as_ref()
|
|
||||||
.expect("Feature `DRAW_INDIRECT_COUNT` must be enabled")
|
|
||||||
{
|
|
||||||
super::ExtensionFn::Extension(t) => {
|
|
||||||
t.cmd_draw_indirect_count(
|
t.cmd_draw_indirect_count(
|
||||||
self.active,
|
self.active,
|
||||||
buffer.raw,
|
buffer.raw,
|
||||||
@ -658,7 +652,7 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
|||||||
0,
|
0,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
super::ExtensionFn::Promoted => {
|
Some(super::ExtensionFn::Promoted) => {
|
||||||
self.device.raw.cmd_draw_indirect_count(
|
self.device.raw.cmd_draw_indirect_count(
|
||||||
self.active,
|
self.active,
|
||||||
buffer.raw,
|
buffer.raw,
|
||||||
@ -669,6 +663,7 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
|||||||
0,
|
0,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
None => panic!("Feature `DRAW_INDIRECT_COUNT` not enabled"),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
unsafe fn draw_indexed_indirect_count(
|
unsafe fn draw_indexed_indirect_count(
|
||||||
@ -679,14 +674,8 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
|||||||
count_offset: wgt::BufferAddress,
|
count_offset: wgt::BufferAddress,
|
||||||
max_count: u32,
|
max_count: u32,
|
||||||
) {
|
) {
|
||||||
match self
|
match self.device.extension_fns.draw_indirect_count {
|
||||||
.device
|
Some(super::ExtensionFn::Extension(ref t)) => {
|
||||||
.extension_fns
|
|
||||||
.draw_indirect_count
|
|
||||||
.as_ref()
|
|
||||||
.expect("Feature `DRAW_INDIRECT_COUNT` must be enabled")
|
|
||||||
{
|
|
||||||
super::ExtensionFn::Extension(t) => {
|
|
||||||
t.cmd_draw_indexed_indirect_count(
|
t.cmd_draw_indexed_indirect_count(
|
||||||
self.active,
|
self.active,
|
||||||
buffer.raw,
|
buffer.raw,
|
||||||
@ -697,7 +686,7 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
|||||||
0,
|
0,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
super::ExtensionFn::Promoted => {
|
Some(super::ExtensionFn::Promoted) => {
|
||||||
self.device.raw.cmd_draw_indexed_indirect_count(
|
self.device.raw.cmd_draw_indexed_indirect_count(
|
||||||
self.active,
|
self.active,
|
||||||
buffer.raw,
|
buffer.raw,
|
||||||
@ -708,6 +697,7 @@ impl crate::CommandEncoder<super::Api> for super::CommandEncoder {
|
|||||||
0,
|
0,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
None => panic!("Feature `DRAW_INDIRECT_COUNT` not enabled"),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user