Struct bgfx_sys::bgfx_init_s
source · #[repr(C)]pub struct bgfx_init_s {
pub type_: bgfx_renderer_type_t,
pub vendorId: u16,
pub deviceId: u16,
pub capabilities: u64,
pub debug: bool,
pub profile: bool,
pub platformData: bgfx_platform_data_t,
pub resolution: bgfx_resolution_t,
pub limits: bgfx_init_limits_t,
pub callback: *mut bgfx_callback_interface_t,
pub allocator: *mut bgfx_allocator_interface_t,
}
Expand description
Initialization parameters used by bgfx::init
.
Fields§
§type_: bgfx_renderer_type_t
Select rendering backend. When set to RendererType::Count
a default rendering backend will be selected appropriate to the platform.
See: bgfx::RendererType
vendorId: u16
Vendor PCI ID. If set to BGFX_PCI_ID_NONE
, discrete and integrated
GPUs will be prioritised.
BGFX_PCI_ID_NONE
- Autoselect adapter.BGFX_PCI_ID_SOFTWARE_RASTERIZER
- Software rasterizer.BGFX_PCI_ID_AMD
- AMD adapter.BGFX_PCI_ID_APPLE
- Apple adapter.BGFX_PCI_ID_INTEL
- Intel adapter.BGFX_PCI_ID_NVIDIA
- NVIDIA adapter.BGFX_PCI_ID_MICROSOFT
- Microsoft adapter.
deviceId: u16
Device ID. If set to 0 it will select first device, or device with matching ID.
capabilities: u64
§debug: bool
Capabilities initialization mask (default: UINT64_MAX).
profile: bool
Enable device for debugging.
platformData: bgfx_platform_data_t
Enable device for profiling.
resolution: bgfx_resolution_t
Platform data.
limits: bgfx_init_limits_t
Backbuffer resolution and reset parameters. See: bgfx::Resolution
.
callback: *mut bgfx_callback_interface_t
Provide application specific callback interface.
See: bgfx::CallbackI
allocator: *mut bgfx_allocator_interface_t
Custom allocator. When a custom allocator is not specified, bgfx uses the CRT allocator. Bgfx assumes custom allocator is thread safe.
Trait Implementations§
source§impl Clone for bgfx_init_s
impl Clone for bgfx_init_s
source§fn clone(&self) -> bgfx_init_s
fn clone(&self) -> bgfx_init_s
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more