File tree 1 file changed +7
-4
lines changed
1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -461,9 +461,10 @@ its audio, controller and other neat features that sdl2 has.
461
461
462
462
# Vulkan
463
463
464
- To use Vulkan, you need a Vulkan library for Rust. This example uses the [ Vulkano] [ vulkano ]
465
- library. Other libraries may use different data types for raw Vulkan object handles. The
466
- procedure to interface SDL2's Vulkan functions with these will be different for each one.
464
+ To use Vulkan, you need a Vulkan library for Rust. This example uses the
465
+ [ Vulkano] ( https://github.com/vulkano-rs/vulkano ) library. Other libraries may use different data
466
+ types for raw Vulkan object handles. The procedure to interface SDL2's Vulkan functions with these
467
+ will be different for each one.
467
468
468
469
``` rust
469
470
extern crate sdl2;
@@ -486,7 +487,9 @@ fn main() {
486
487
. unwrap ();
487
488
488
489
let instance_extensions = window . vulkan_instance_extensions (). unwrap ();
489
- let raw_instance_extensions = RawInstanceExtensions :: new (instance_extensions . iter (). map (| & v | CString :: new (v ). unwrap ()));
490
+ let raw_instance_extensions = RawInstanceExtensions :: new (instance_extensions . iter (). map (
491
+ | & v | CString :: new (v ). unwrap ()
492
+ ));
490
493
let instance = Instance :: new (None , raw_instance_extensions , None ). unwrap ();
491
494
let surface_handle = window . vulkan_create_surface (instance . internal_object ()). unwrap ();
492
495
let surface = unsafe { Surface :: from_raw_surface (instance , surface_handle , window . context ()) };
You can’t perform that action at this time.
0 commit comments