-
Notifications
You must be signed in to change notification settings - Fork 11
/
triangle.rs
50 lines (45 loc) · 1.86 KB
/
triangle.rs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
mod hello_triangle;
use hello_triangle::vulkan_base::VulkanBase;
use librashader_runtime_vk::options::FilterChainOptionsVulkan;
use librashader_runtime_vk::FilterChainVulkan;
#[test]
fn triangle_vk() {
let entry = unsafe { ash::Entry::load().unwrap() };
let base = VulkanBase::new(entry).unwrap();
unsafe {
let filter = FilterChainVulkan::load_from_path(
"../test/shaders_slang/test/feedback.slangp",
// "../test/shaders_slang/bezel/Mega_Bezel/Presets/MBZ__0__SMOOTH-ADV.slangp",
// "../test/Mega_Bezel_Packs/Duimon-Mega-Bezel/Presets/Advanced/Nintendo_GBA_SP/GBA_SP-[ADV]-[LCD-GRID]-[Night].slangp",
&base,
// "../test/basic.slangp",
Some(&FilterChainOptionsVulkan {
frames_in_flight: 3,
force_no_mipmaps: false,
use_dynamic_rendering: false,
disable_cache: true,
}),
)
.unwrap();
hello_triangle::main(base, filter)
}
// let base = hello_triangle_old::ExampleBase::new(900, 600);
// // let mut filter = FilterChainVulkan::load_from_path(
// // (base.device.clone(), base.present_queue.clone(), base.device_memory_properties.clone()),
// // "../test/slang-shaders/border/gameboy-player/gameboy-player-crt-royale.slangp",
// // None
// // )
//
// let mut filter = FilterChainVulkan::load_from_path(
// (
// base.device.clone(),
// base.present_queue.clone(),
// base.device_memory_properties.clone(),
// ),
// "../test/slang-shaders/border/gameboy-player/gameboy-player-crt-royale.slangp",
// None,
// )
// // FilterChain::load_from_path("../test/slang-shaders/bezel/Mega_Bezel/Presets/MBZ__0__SMOOTH-ADV.slangp", None)
// .unwrap();
// hello_triangle_old::main(base, filter);
}