gecko-dev/gfx/wgpu/ffi/wgpu-remote.h
Dzmitry Malyshau e662646742 Bug 1596128 - Update wgpu to the version that has a separate wgpu-core
https://github.com/gfx-rs/wgpu rev d08118b535a95755c29984e256cba205172acd95

Differential Revision: https://phabricator.services.mozilla.com/D54014

--HG--
rename : gfx/wgpu/wgpu-native/Cargo.toml => gfx/wgpu/wgpu-core/Cargo.toml
rename : gfx/wgpu/wgpu-native/src/binding_model.rs => gfx/wgpu/wgpu-core/src/binding_model.rs
rename : gfx/wgpu/wgpu-native/src/command/allocator.rs => gfx/wgpu/wgpu-core/src/command/allocator.rs
rename : gfx/wgpu/wgpu-native/src/command/bind.rs => gfx/wgpu/wgpu-core/src/command/bind.rs
rename : gfx/wgpu/wgpu-native/src/conv.rs => gfx/wgpu/wgpu-core/src/conv.rs
rename : gfx/wgpu/wgpu-native/src/hub.rs => gfx/wgpu/wgpu-core/src/hub.rs
rename : gfx/wgpu/wgpu-native/src/id.rs => gfx/wgpu/wgpu-core/src/id.rs
rename : gfx/wgpu/wgpu-native/src/lib.rs => gfx/wgpu/wgpu-core/src/lib.rs
rename : gfx/wgpu/wgpu-native/src/pipeline.rs => gfx/wgpu/wgpu-core/src/pipeline.rs
rename : gfx/wgpu/wgpu-native/src/resource.rs => gfx/wgpu/wgpu-core/src/resource.rs
rename : gfx/wgpu/wgpu-native/src/track/buffer.rs => gfx/wgpu/wgpu-core/src/track/buffer.rs
rename : gfx/wgpu/wgpu-native/src/track/mod.rs => gfx/wgpu/wgpu-core/src/track/mod.rs
rename : gfx/wgpu/wgpu-native/src/track/range.rs => gfx/wgpu/wgpu-core/src/track/range.rs
rename : gfx/wgpu/wgpu-native/src/track/texture.rs => gfx/wgpu/wgpu-core/src/track/texture.rs
extra : moz-landing-system : lando
2019-11-21 21:54:26 +00:00

122 lines
3.3 KiB
C

/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
/* Generated with cbindgen:0.9.1 */
/* DO NOT MODIFY THIS MANUALLY! This file was generated using cbindgen.
* To generate this file:
* 1. Get the latest cbindgen using `cargo install --force cbindgen`
* a. Alternatively, you can clone `https://github.com/eqrion/cbindgen` and use a tagged release
* 2. Run `rustup run nightly cbindgen toolkit/library/rust/ --lockfile Cargo.lock --crate wgpu-remote -o dom/webgpu/ffi/wgpu_ffi_generated.h`
*/
typedef void WGPUEmpty;
#include <stdarg.h>
#include <stdbool.h>
#include <stdint.h>
#include <stdlib.h>
typedef enum {
WGPUPowerPreference_Default = 0,
WGPUPowerPreference_LowPower = 1,
WGPUPowerPreference_HighPerformance = 2,
} WGPUPowerPreference;
typedef struct WGPUClient WGPUClient;
typedef uint64_t WGPUId_Adapter_Dummy;
typedef WGPUId_Adapter_Dummy WGPUAdapterId;
typedef uint64_t WGPUId_Device_Dummy;
typedef WGPUId_Device_Dummy WGPUDeviceId;
typedef struct {
WGPUClient *client;
const uint8_t *error;
} WGPUInfrastructure;
typedef struct {
bool anisotropic_filtering;
} WGPUExtensions;
typedef struct {
uint32_t max_bind_groups;
} WGPULimits;
typedef struct {
WGPUExtensions extensions;
WGPULimits limits;
} WGPUDeviceDescriptor;
typedef struct {
WGPUPowerPreference power_preference;
} WGPURequestAdapterOptions;
WGPU_INLINE
void wgpu_client_delete(WGPUClient *aClient)
WGPU_FUNC;
WGPU_INLINE
void wgpu_client_kill_adapter_ids(const WGPUClient *aClient,
const WGPUAdapterId *aIds,
uintptr_t aIdLength)
WGPU_FUNC;
WGPU_INLINE
void wgpu_client_kill_device_id(const WGPUClient *aClient,
WGPUDeviceId aId)
WGPU_FUNC;
WGPU_INLINE
uintptr_t wgpu_client_make_adapter_ids(const WGPUClient *aClient,
WGPUAdapterId *aIds,
uintptr_t aIdLength)
WGPU_FUNC;
WGPU_INLINE
WGPUDeviceId wgpu_client_make_device_id(const WGPUClient *aClient,
WGPUAdapterId aAdapterId)
WGPU_FUNC;
WGPU_INLINE
WGPUInfrastructure wgpu_client_new(void)
WGPU_FUNC;
WGPU_INLINE
void wgpu_server_adapter_request_device(const WGPUGlobal *aGlobal,
WGPUAdapterId aSelfId,
const WGPUDeviceDescriptor *aDesc,
WGPUDeviceId aNewId)
WGPU_FUNC;
WGPU_INLINE
void wgpu_server_delete(WGPUGlobal *aGlobal)
WGPU_FUNC;
WGPU_INLINE
void wgpu_server_device_destroy(const WGPUGlobal *aGlobal,
WGPUDeviceId aSelfId)
WGPU_FUNC;
/**
* Request an adapter according to the specified options.
* Provide the list of IDs to pick from.
*
* Returns the index in this list, or -1 if unable to pick.
*/
WGPU_INLINE
int8_t wgpu_server_instance_request_adapter(const WGPUGlobal *aGlobal,
const WGPURequestAdapterOptions *aDesc,
const WGPUAdapterId *aIds,
uintptr_t aIdLength)
WGPU_FUNC;
WGPU_INLINE
WGPUGlobal *wgpu_server_new(void)
WGPU_FUNC;