Add logging to get_proc_addrs
This commit is contained in:
parent
7cc1eb54e2
commit
eaff64a9d6
1 changed files with 12 additions and 0 deletions
|
@ -55,6 +55,8 @@ extern "system" fn get_device_proc_addr(
|
||||||
_device: VkDevice,
|
_device: VkDevice,
|
||||||
function_name: *const c_char,
|
function_name: *const c_char,
|
||||||
) -> PFN_vkVoidFunction {
|
) -> PFN_vkVoidFunction {
|
||||||
|
write_log!("get_device_proc_addr");
|
||||||
|
|
||||||
let func_string = match VkString::try_from(function_name) {
|
let func_string = match VkString::try_from(function_name) {
|
||||||
Ok(func) => func,
|
Ok(func) => func,
|
||||||
Err(_) => {
|
Err(_) => {
|
||||||
|
@ -65,6 +67,8 @@ extern "system" fn get_device_proc_addr(
|
||||||
|
|
||||||
let s = func_string.as_str();
|
let s = func_string.as_str();
|
||||||
|
|
||||||
|
write_log!(format!("\t{}", s));
|
||||||
|
|
||||||
if let Some(func) = Functions::get_vk_func(s) {
|
if let Some(func) = Functions::get_vk_func(s) {
|
||||||
return func.convert();
|
return func.convert();
|
||||||
}
|
}
|
||||||
|
@ -73,6 +77,8 @@ extern "system" fn get_device_proc_addr(
|
||||||
return func;
|
return func;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
write_log!("\t-> returning null");
|
||||||
|
|
||||||
Functions::Null.convert()
|
Functions::Null.convert()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -81,6 +87,8 @@ extern "system" fn get_instance_proc_addr(
|
||||||
_instance: VkInstance,
|
_instance: VkInstance,
|
||||||
function_name: *const c_char,
|
function_name: *const c_char,
|
||||||
) -> PFN_vkVoidFunction {
|
) -> PFN_vkVoidFunction {
|
||||||
|
write_log!("get_instance_proc_addr");
|
||||||
|
|
||||||
let func_string = match VkString::try_from(function_name) {
|
let func_string = match VkString::try_from(function_name) {
|
||||||
Ok(func) => func,
|
Ok(func) => func,
|
||||||
Err(_) => {
|
Err(_) => {
|
||||||
|
@ -91,6 +99,8 @@ extern "system" fn get_instance_proc_addr(
|
||||||
|
|
||||||
let s = func_string.as_str();
|
let s = func_string.as_str();
|
||||||
|
|
||||||
|
write_log!(format!("\t{}", s));
|
||||||
|
|
||||||
if let Some(func) = Functions::get_vk_func(s) {
|
if let Some(func) = Functions::get_vk_func(s) {
|
||||||
return func.convert();
|
return func.convert();
|
||||||
}
|
}
|
||||||
|
@ -99,6 +109,8 @@ extern "system" fn get_instance_proc_addr(
|
||||||
return func;
|
return func;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
write_log!("\t-> returning null");
|
||||||
|
|
||||||
Functions::Null.convert()
|
Functions::Null.convert()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue