Expand description
Crate that contains utility modules used by other rendy crates
Modules§
- hal
- Low-level graphics abstraction for Rust. Mostly operates on data, not types. Designed for use by libraries and higher-level abstractions only.
- types
- Types shared across rendy
Macros§
- backend_
enum - Allows create new enumerations with variants for each active backend.
rendy_backend!
can be used to match over it. - device_
owned - Implement ownership checking for value with
device: DeviceId
field. - instance_
owned - Implement ownership checking for value with
instance: InstanceId
field. - rendy_
backend - Execute arm with matching backend. If particular backend is disabled then its arm is stripped from compilation altogether.
- rendy_
not_ wasm32 - Resolve into input AST if target architecture is not “wasm32”
- rendy_
slow_ assert assert!
that is exists only if"no-slow-safety-checks"
feature is not enabled.- rendy_
slow_ assert_ eq assert_eq!
that is exists only if"no-slow-safety-checks"
feature is not enabled.- rendy_
slow_ assert_ ne assert_ne!
that is exists only if"no-slow-safety-checks"
feature is not enabled.- rendy_
wasm32 - Resolve into input AST if target architecture is “wasm32”
- rendy_
with_ dx12_ backend - Resolve into input AST if dx12 backend is enabled.
- rendy_
with_ empty_ backend - Resolve into input AST if empty backend is enabled.
- rendy_
with_ gl_ backend - Resolve into input AST if gl backend is enabled.
- rendy_
with_ metal_ backend - Resolve into input AST if metal backend is enabled.
- rendy_
with_ slow_ safety_ checks - Resolve into input AST if rendy is requested to perform slow safety checks.
- rendy_
with_ vulkan_ backend - Resolve into input AST if vulkan backend is enabled.
- rendy_
without_ dx12_ backend - Resolve into input AST if dx12 backend is disabled.
- rendy_
without_ empty_ backend - Resolve into input AST if empty backend is disabled.
- rendy_
without_ gl_ backend - Resolve into input AST if gl backend is disabled.
- rendy_
without_ metal_ backend - Resolve into input AST if metal backend is disabled.
- rendy_
without_ slow_ safety_ checks - Resolve into input AST if rendy is requested to not perform slow safety checks.
- rendy_
without_ vulkan_ backend - Resolve into input AST if vulkan backend is disabled.
Structs§
- Device
- Raw device wrapper with id.
- Device
Id - Id of the instance.
- Instance
- Raw instance wrapper with id.
- Instance
Id - Id of the hal instance.
- NotEnabled
- Error signaling that particular backend is not enabled.
- Parse
Backend Error - Unknown backend errors.
Enums§
- Backend
- Backend enumerator.
- Enabled
Backend - Backend enumerator.
- RawWindow
Handle
Traits§
- HasRaw
Window Handle - Window that wraps around a raw window handle.
Functions§
- cast_
cow - Cast
cow
of some arbitrary type intocow
of bytes. Can lead to UB if allocator changes. Use with caution. TODO: Replace with something safer. - cast_
slice - Cast slice of some arbitrary type into slice of bytes.
- cast_
vec - Cast vec of some arbitrary type into vec of bytes. Can lead to UB if allocator changes. Use with caution. TODO: Replace with something safer.
- identical_
cast - Casts identical types. Useful in generic environment where caller knows that two types are the same but Rust is not convinced.
- uses_
pipeline_ barriers - Check if specified backend would use pipeline barriers or using them is futile. Piece of internal knowledge.