• Home
  • Raw
  • Download

Lines Matching refs:instance_data

49 struct instance_data {  struct
74 struct instance_data *instance; argument
324 static struct instance_data *new_instance_data(VkInstance instance) in new_instance_data()
326 struct instance_data *data = rzalloc(NULL, struct instance_data); in new_instance_data()
333 static void destroy_instance_data(struct instance_data *data) in destroy_instance_data()
343 static void instance_data_map_physical_devices(struct instance_data *instance_data, in instance_data_map_physical_devices() argument
347 instance_data->vtable.EnumeratePhysicalDevices(instance_data->instance, in instance_data_map_physical_devices()
352 instance_data->vtable.EnumeratePhysicalDevices(instance_data->instance, in instance_data_map_physical_devices()
358 map_object(HKEY(physicalDevices[i]), instance_data); in instance_data_map_physical_devices()
367 static struct device_data *new_device_data(VkDevice device, struct instance_data *instance) in new_device_data()
420 struct instance_data *instance_data = data->instance; in device_map_queues() local
422 instance_data->vtable.GetPhysicalDeviceQueueFamilyProperties(data->physical_device, in device_map_queues()
427 instance_data->vtable.GetPhysicalDeviceQueueFamilyProperties(data->physical_device, in device_map_queues()
493 struct instance_data *instance_data = device_data->instance; in new_swapchain_data() local
497 data->window_size = ImVec2(instance_data->params.width, instance_data->params.height); in new_swapchain_data()
571 static void parse_command(struct instance_data *instance_data, in parse_command() argument
580 instance_data->capture_enabled = true; in parse_command()
582 instance_data->capture_enabled = false; in parse_command()
583 instance_data->capture_started = false; in parse_command()
599 static void process_char(struct instance_data *instance_data, char c) in process_char() argument
621 parse_command(instance_data, cmd, cmdpos, param, parampos); in process_char()
655 static void control_send(struct instance_data *instance_data, in control_send() argument
676 os_socket_send(instance_data->control_client, buffer, msglen, 0); in control_send()
681 struct instance_data *instance_data = device_data->instance; in control_send_connection_string() local
686 control_send(instance_data, controlVersionCmd, strlen(controlVersionCmd), in control_send_connection_string()
692 control_send(instance_data, deviceCmd, strlen(deviceCmd), in control_send_connection_string()
698 control_send(instance_data, mesaVersionCmd, strlen(mesaVersionCmd), in control_send_connection_string()
704 struct instance_data *instance_data = device_data->instance; in control_client_check() local
707 if (instance_data->control_client >= 0) in control_client_check()
710 int socket = os_socket_accept(instance_data->params.control); in control_client_check()
719 instance_data->control_client = socket; in control_client_check()
724 static void control_client_disconnected(struct instance_data *instance_data) in control_client_disconnected() argument
726 os_socket_close(instance_data->control_client); in control_client_disconnected()
727 instance_data->control_client = -1; in control_client_disconnected()
730 static void process_control_socket(struct instance_data *instance_data) in process_control_socket() argument
732 const int client = instance_data->control_client; in process_control_socket()
748 control_client_disconnected(instance_data); in process_control_socket()
751 control_client_disconnected(instance_data); in process_control_socket()
755 process_char(instance_data, buf[i]); in process_control_socket()
772 struct instance_data *instance_data = device_data->instance; in snapshot_swapchain_frame() local
776 if (instance_data->params.control >= 0) { in snapshot_swapchain_frame()
778 process_control_socket(instance_data); in snapshot_swapchain_frame()
804 instance_data->capture_enabled && !instance_data->capture_started; in snapshot_swapchain_frame()
809 elapsed >= instance_data->params.fps_sampling_period) { in snapshot_swapchain_frame()
811 if (instance_data->capture_started) { in snapshot_swapchain_frame()
812 if (!instance_data->first_line_printed) { in snapshot_swapchain_frame()
815 instance_data->first_line_printed = true; in snapshot_swapchain_frame()
818 if (instance_data->params.enabled[OVERLAY_PARAM_ENABLED_##name]) { \ in snapshot_swapchain_frame()
819 fprintf(instance_data->params.output_file, \ in snapshot_swapchain_frame()
828 fprintf(instance_data->params.output_file, "\n"); in snapshot_swapchain_frame()
832 if (!instance_data->params.enabled[s]) in snapshot_swapchain_frame()
835 fprintf(instance_data->params.output_file, in snapshot_swapchain_frame()
838 fprintf(instance_data->params.output_file, in snapshot_swapchain_frame()
843 fprintf(instance_data->params.output_file, "\n"); in snapshot_swapchain_frame()
844 fflush(instance_data->params.output_file); in snapshot_swapchain_frame()
852 instance_data->capture_started = true; in snapshot_swapchain_frame()
897 struct instance_data *instance_data = device_data->instance; in position_layer() local
902 switch (instance_data->params.position) { in position_layer()
925 struct instance_data *instance_data = device_data->instance; in compute_swapchain_display() local
937 if (instance_data->params.enabled[OVERLAY_PARAM_ENABLED_fps]) in compute_swapchain_display()
958 if (!instance_data->params.enabled[s] || in compute_swapchain_display()
1829 struct instance_data *instance_data = swapchain_data->device->instance; in before_present() local
1834 if (!instance_data->params.no_display && swapchain_data->n_frames > 0) { in before_present()
1884 struct instance_data *instance_data = device_data->instance; in overlay_QueuePresentKHR() local
1940 if (instance_data->params.no_display) { in overlay_QueuePresentKHR()
2452 struct instance_data *instance_data = in overlay_CreateDevice() local
2453 FIND(struct instance_data, physicalDevice); in overlay_CreateDevice()
2486 if (instance_data->pipeline_statistics_enabled) { in overlay_CreateDevice()
2496 struct device_data *device_data = new_device_data(*pDevice, instance_data); in overlay_CreateDevice()
2500 instance_data->vtable.GetPhysicalDeviceProperties(device_data->physical_device, in overlay_CreateDevice()
2545 struct instance_data *instance_data = new_instance_data(*pInstance); in overlay_CreateInstance() local
2546 vk_load_instance_commands(instance_data->instance, in overlay_CreateInstance()
2548 &instance_data->vtable); in overlay_CreateInstance()
2549 instance_data_map_physical_devices(instance_data, true); in overlay_CreateInstance()
2551 parse_overlay_env(&instance_data->params, getenv("VK_LAYER_MESA_OVERLAY_CONFIG")); in overlay_CreateInstance()
2556 instance_data->capture_enabled = in overlay_CreateInstance()
2557 instance_data->params.output_file && instance_data->params.control < 0; in overlay_CreateInstance()
2558 instance_data->capture_started = instance_data->capture_enabled; in overlay_CreateInstance()
2562 if (instance_data->params.enabled[i]) { in overlay_CreateInstance()
2563 instance_data->pipeline_statistics_enabled = true; in overlay_CreateInstance()
2575 struct instance_data *instance_data = FIND(struct instance_data, instance); in overlay_DestroyInstance() local
2576 instance_data_map_physical_devices(instance_data, false); in overlay_DestroyInstance()
2577 instance_data->vtable.DestroyInstance(instance, pAllocator); in overlay_DestroyInstance()
2578 destroy_instance_data(instance_data); in overlay_DestroyInstance()
2656 struct instance_data *instance_data = FIND(struct instance_data, instance); in vkGetInstanceProcAddr() local
2657 if (instance_data->vtable.GetInstanceProcAddr == NULL) return NULL; in vkGetInstanceProcAddr()
2658 return instance_data->vtable.GetInstanceProcAddr(instance, funcName); in vkGetInstanceProcAddr()