• Home
  • Raw
  • Download

Lines Matching refs:device

83 #define GET_PRIV(device) gst_vulkan_physical_device_get_instance_private (device)  argument
91 device, GError ** error);
105 GstVulkanPhysicalDevice *device; in gst_vulkan_physical_device_new() local
109 device = g_object_new (GST_TYPE_VULKAN_PHYSICAL_DEVICE, "instance", instance, in gst_vulkan_physical_device_new()
111 gst_object_ref_sink (device); in gst_vulkan_physical_device_new()
113 return device; in gst_vulkan_physical_device_new()
120 GstVulkanPhysicalDevice *device = GST_VULKAN_PHYSICAL_DEVICE (object); in gst_vulkan_physical_device_set_property() local
124 device->instance = g_value_dup_object (value); in gst_vulkan_physical_device_set_property()
128 if (device->instance == VK_NULL_HANDLE in gst_vulkan_physical_device_set_property()
129 || device_id >= device->instance->n_physical_devices) { in gst_vulkan_physical_device_set_property()
131 "number of physical devices", GST_OBJECT_NAME (device)); in gst_vulkan_physical_device_set_property()
133 device->device_index = device_id; in gst_vulkan_physical_device_set_property()
147 GstVulkanPhysicalDevice *device = GST_VULKAN_PHYSICAL_DEVICE (object); in gst_vulkan_physical_device_get_property() local
151 g_value_set_object (value, device->instance); in gst_vulkan_physical_device_get_property()
154 g_value_set_uint (value, device->device_index); in gst_vulkan_physical_device_get_property()
157 g_value_set_string (value, device->properties.deviceName); in gst_vulkan_physical_device_get_property()
166 gst_vulkan_physical_device_init (GstVulkanPhysicalDevice * device) in gst_vulkan_physical_device_init() argument
168 GstVulkanPhysicalDevicePrivate *priv = GET_PRIV (device); in gst_vulkan_physical_device_init()
195 GstVulkanPhysicalDevice *device = GST_VULKAN_PHYSICAL_DEVICE (object); in gst_vulkan_physical_device_constructed() local
198 if (device->instance == VK_NULL_HANDLE) { in gst_vulkan_physical_device_constructed()
203 device->device = device->instance->physical_devices[device->device_index]; in gst_vulkan_physical_device_constructed()
205 if (!gst_vulkan_physical_device_fill_info (device, &error)) { in gst_vulkan_physical_device_constructed()
241 GstVulkanPhysicalDevice *device = GST_VULKAN_PHYSICAL_DEVICE (object); in gst_vulkan_physical_device_finalize() local
242 GstVulkanPhysicalDevicePrivate *priv = GET_PRIV (device); in gst_vulkan_physical_device_finalize()
250 g_free (device->queue_family_props); in gst_vulkan_physical_device_finalize()
251 device->queue_family_props = NULL; in gst_vulkan_physical_device_finalize()
253 if (device->instance) in gst_vulkan_physical_device_finalize()
254 gst_object_unref (device->instance); in gst_vulkan_physical_device_finalize()
255 device->instance = VK_NULL_HANDLE; in gst_vulkan_physical_device_finalize()
261 GST_DEBUG_OBJECT (device, prefix " " G_STRINGIFY(name) ": %s", \
264 GST_DEBUG_OBJECT (device, prefix " " G_STRINGIFY(name) ": %" format, \
267 GST_DEBUG_OBJECT (device, prefix " " G_STRINGIFY(name) \
272 GST_DEBUG_OBJECT (device, prefix " " G_STRINGIFY(limit) \
293 GST_DEBUG_OBJECT (device, prefix " " G_STRINGIFY(limit) ": (0x%x) %s", \
303 dump_features10 (GstVulkanPhysicalDevice * device, in dump_features10() argument
368 dump_features11 (GstVulkanPhysicalDevice * device, in dump_features11() argument
388 dump_features12 (GstVulkanPhysicalDevice * device, in dump_features12() argument
441 dump_features (GstVulkanPhysicalDevice * device, GError ** error) in dump_features() argument
444 GstVulkanPhysicalDevicePrivate *priv = GET_PRIV (device); in dump_features()
447 if (gst_vulkan_instance_check_version (device->instance, 1, 2, 0)) { in dump_features()
451 dump_features10 (device, in dump_features()
455 dump_features11 (device, (VkPhysicalDeviceVulkan11Features *) iter); in dump_features()
458 dump_features12 (device, (VkPhysicalDeviceVulkan12Features *) iter); in dump_features()
463 dump_features10 (device, &device->features); in dump_features()
470 dump_memory_properties (GstVulkanPhysicalDevice * device, GError ** error) in dump_memory_properties() argument
474 GST_DEBUG_OBJECT (device, "found %" G_GUINT32_FORMAT " memory heaps", in dump_memory_properties()
475 device->memory_properties.memoryHeapCount); in dump_memory_properties()
476 for (i = 0; i < device->memory_properties.memoryHeapCount; i++) { in dump_memory_properties()
478 gst_vulkan_memory_heap_flags_to_string (device-> in dump_memory_properties()
480 GST_LOG_OBJECT (device, in dump_memory_properties()
483 (guint64) device->memory_properties.memoryHeaps[i].size, in dump_memory_properties()
484 device->memory_properties.memoryHeaps[i].flags, prop_flags_str); in dump_memory_properties()
487 GST_DEBUG_OBJECT (device, "found %" G_GUINT32_FORMAT " memory types", in dump_memory_properties()
488 device->memory_properties.memoryTypeCount); in dump_memory_properties()
489 for (i = 0; i < device->memory_properties.memoryTypeCount; i++) { in dump_memory_properties()
491 gst_vulkan_memory_property_flags_to_string (device->memory_properties. in dump_memory_properties()
493 GST_LOG_OBJECT (device, in dump_memory_properties()
496 device->memory_properties.memoryTypes[i].heapIndex, in dump_memory_properties()
497 device->memory_properties.memoryTypes[i].propertyFlags, prop_flags_str); in dump_memory_properties()
505 dump_queue_properties (GstVulkanPhysicalDevice * device, GError ** error) in dump_queue_properties() argument
509 GST_DEBUG_OBJECT (device, "found %" G_GUINT32_FORMAT " queue families", in dump_queue_properties()
510 device->n_queue_families); in dump_queue_properties()
511 for (i = 0; i < device->n_queue_families; i++) { in dump_queue_properties()
513 gst_vulkan_queue_flags_to_string (device-> in dump_queue_properties()
515 GST_LOG_OBJECT (device, in dump_queue_properties()
519 i, device->queue_family_props[i].queueCount, in dump_queue_properties()
520 device->queue_family_props[i].queueFlags, queue_flags_str, in dump_queue_properties()
521 device->queue_family_props[i].timestampValidBits, in dump_queue_properties()
522 GST_VULKAN_EXTENT3D_ARGS (device-> in dump_queue_properties()
531 dump_limits (GstVulkanPhysicalDevice * device, GError ** error) in dump_limits() argument
533 VkPhysicalDeviceLimits *limits = &device->properties.limits; in dump_limits()
649 dump_sparse_properties (GstVulkanPhysicalDevice * device, GError ** error) in dump_sparse_properties() argument
652 &device->properties.sparseProperties; in dump_sparse_properties()
667 dump_properties11 (GstVulkanPhysicalDevice * device, in dump_properties11() argument
690 dump_properties12 (GstVulkanPhysicalDevice * device, in dump_properties12() argument
752 physical_device_info (GstVulkanPhysicalDevice * device, GError ** error) in physical_device_info() argument
755 GstVulkanPhysicalDevicePrivate *priv = GET_PRIV (device); in physical_device_info()
759 GST_INFO_OBJECT (device, "physical device %i name \'%s\' type \'%s\' " in physical_device_info()
761 "device ID 0x%x", device->device_index, device->properties.deviceName, in physical_device_info()
762 gst_vulkan_physical_device_type_to_string (device->properties.deviceType), in physical_device_info()
763 VK_VERSION_MAJOR (device->properties.apiVersion), in physical_device_info()
764 VK_VERSION_MINOR (device->properties.apiVersion), in physical_device_info()
765 VK_VERSION_PATCH (device->properties.apiVersion), in physical_device_info()
766 VK_VERSION_MAJOR (device->properties.driverVersion), in physical_device_info()
767 VK_VERSION_MINOR (device->properties.driverVersion), in physical_device_info()
768 VK_VERSION_PATCH (device->properties.driverVersion), in physical_device_info()
769 device->properties.vendorID, device->properties.deviceID); in physical_device_info()
771 if (!dump_queue_properties (device, error)) in physical_device_info()
773 if (!dump_memory_properties (device, error)) in physical_device_info()
775 if (!dump_features (device, error)) in physical_device_info()
777 if (!dump_limits (device, error)) in physical_device_info()
779 if (!dump_sparse_properties (device, error)) in physical_device_info()
783 if (gst_vulkan_instance_check_version (device->instance, 1, 2, 0)) { in physical_device_info()
788 dump_properties11 (device, (VkPhysicalDeviceVulkan11Properties *) iter); in physical_device_info()
791 dump_properties12 (device, (VkPhysicalDeviceVulkan12Properties *) iter); in physical_device_info()
800 gst_vulkan_physical_device_fill_info (GstVulkanPhysicalDevice * device, in gst_vulkan_physical_device_fill_info() argument
803 GstVulkanPhysicalDevicePrivate *priv = GET_PRIV (device); in gst_vulkan_physical_device_fill_info()
807 device->device = gst_vulkan_physical_device_get_handle (device); in gst_vulkan_physical_device_fill_info()
808 if (!device->device) { in gst_vulkan_physical_device_fill_info()
815 vkEnumerateDeviceLayerProperties (device->device, in gst_vulkan_physical_device_fill_info()
823 vkEnumerateDeviceLayerProperties (device->device, in gst_vulkan_physical_device_fill_info()
831 vkEnumerateDeviceExtensionProperties (device->device, NULL, in gst_vulkan_physical_device_fill_info()
841 vkEnumerateDeviceExtensionProperties (device->device, NULL, in gst_vulkan_physical_device_fill_info()
848 GST_INFO_OBJECT (device, "found %u layers and %u extensions", in gst_vulkan_physical_device_fill_info()
852 GST_DEBUG_OBJECT (device, "available layer %u: %s", i, in gst_vulkan_physical_device_fill_info()
855 GST_DEBUG_OBJECT (device, "available extension %u: %s", i, in gst_vulkan_physical_device_fill_info()
858 vkGetPhysicalDeviceProperties (device->device, &device->properties); in gst_vulkan_physical_device_fill_info()
860 if (gst_vulkan_instance_check_version (device->instance, 1, 2, 0)) { in gst_vulkan_physical_device_fill_info()
875 gst_vulkan_instance_get_proc_address (device->instance, in gst_vulkan_physical_device_fill_info()
877 get_props2 (device->device, &priv->properties10); in gst_vulkan_physical_device_fill_info()
880 gst_vulkan_instance_get_proc_address (device->instance, in gst_vulkan_physical_device_fill_info()
882 get_mem_props2 (device->device, &mem_properties10); in gst_vulkan_physical_device_fill_info()
883 memcpy (&device->memory_properties, &mem_properties10.memoryProperties, in gst_vulkan_physical_device_fill_info()
884 sizeof (device->memory_properties)); in gst_vulkan_physical_device_fill_info()
887 gst_vulkan_instance_get_proc_address (device->instance, in gst_vulkan_physical_device_fill_info()
889 get_features2 (device->device, &priv->features10); in gst_vulkan_physical_device_fill_info()
890 memcpy (&device->features, &priv->features10.features, in gst_vulkan_physical_device_fill_info()
891 sizeof (device->features)); in gst_vulkan_physical_device_fill_info()
894 gst_vulkan_instance_get_proc_address (device->instance, in gst_vulkan_physical_device_fill_info()
896 get_queue_props2 (device->device, &device->n_queue_families, NULL); in gst_vulkan_physical_device_fill_info()
897 if (device->n_queue_families > 0) { in gst_vulkan_physical_device_fill_info()
901 props = g_new0 (VkQueueFamilyProperties2, device->n_queue_families); in gst_vulkan_physical_device_fill_info()
902 for (i = 0; i < device->n_queue_families; i++) { in gst_vulkan_physical_device_fill_info()
907 get_queue_props2 (device->device, &device->n_queue_families, props); in gst_vulkan_physical_device_fill_info()
909 device->queue_family_props = in gst_vulkan_physical_device_fill_info()
910 g_new0 (VkQueueFamilyProperties, device->n_queue_families); in gst_vulkan_physical_device_fill_info()
911 for (i = 0; i < device->n_queue_families; i++) { in gst_vulkan_physical_device_fill_info()
912 memcpy (&device->queue_family_props[i], &props[i].queueFamilyProperties, in gst_vulkan_physical_device_fill_info()
913 sizeof (device->queue_family_props[i])); in gst_vulkan_physical_device_fill_info()
920 vkGetPhysicalDeviceMemoryProperties (device->device, in gst_vulkan_physical_device_fill_info()
921 &device->memory_properties); in gst_vulkan_physical_device_fill_info()
922 vkGetPhysicalDeviceFeatures (device->device, &device->features); in gst_vulkan_physical_device_fill_info()
923 vkGetPhysicalDeviceQueueFamilyProperties (device->device, in gst_vulkan_physical_device_fill_info()
924 &device->n_queue_families, NULL); in gst_vulkan_physical_device_fill_info()
925 if (device->n_queue_families > 0) { in gst_vulkan_physical_device_fill_info()
926 device->queue_family_props = in gst_vulkan_physical_device_fill_info()
927 g_new0 (VkQueueFamilyProperties, device->n_queue_families); in gst_vulkan_physical_device_fill_info()
928 vkGetPhysicalDeviceQueueFamilyProperties (device->device, in gst_vulkan_physical_device_fill_info()
929 &device->n_queue_families, device->queue_family_props); in gst_vulkan_physical_device_fill_info()
933 if (!physical_device_info (device, error)) in gst_vulkan_physical_device_fill_info()
951 gst_vulkan_physical_device_get_handle (GstVulkanPhysicalDevice * device) in gst_vulkan_physical_device_get_handle() argument
953 g_return_val_if_fail (GST_IS_VULKAN_PHYSICAL_DEVICE (device), NULL); in gst_vulkan_physical_device_get_handle()
955 return device->device; in gst_vulkan_physical_device_get_handle()
967 gst_vulkan_physical_device_get_instance (GstVulkanPhysicalDevice * device) in gst_vulkan_physical_device_get_instance() argument
969 g_return_val_if_fail (GST_IS_VULKAN_PHYSICAL_DEVICE (device), NULL); in gst_vulkan_physical_device_get_instance()
971 return device->instance ? gst_object_ref (device->instance) : NULL; in gst_vulkan_physical_device_get_instance()
976 device, const gchar * name, gchar ** description, guint32 * spec_version, in gst_vulkan_physical_device_get_layer_info_unlocked()
982 priv = GET_PRIV (device); in gst_vulkan_physical_device_get_layer_info_unlocked()
1017 gst_vulkan_physical_device_get_layer_info (GstVulkanPhysicalDevice * device, in gst_vulkan_physical_device_get_layer_info() argument
1023 g_return_val_if_fail (GST_IS_VULKAN_PHYSICAL_DEVICE (device), FALSE); in gst_vulkan_physical_device_get_layer_info()
1026 GST_OBJECT_LOCK (device); in gst_vulkan_physical_device_get_layer_info()
1028 gst_vulkan_physical_device_get_layer_info_unlocked (device, name, in gst_vulkan_physical_device_get_layer_info()
1030 GST_OBJECT_UNLOCK (device); in gst_vulkan_physical_device_get_layer_info()
1037 * device, const gchar * name, guint32 * spec_version) in gst_vulkan_physical_device_get_extension_info_unlocked()
1042 priv = GET_PRIV (device); in gst_vulkan_physical_device_get_extension_info_unlocked()
1071 gst_vulkan_physical_device_get_extension_info (GstVulkanPhysicalDevice * device, in gst_vulkan_physical_device_get_extension_info() argument
1076 g_return_val_if_fail (GST_IS_VULKAN_PHYSICAL_DEVICE (device), FALSE); in gst_vulkan_physical_device_get_extension_info()
1079 GST_OBJECT_LOCK (device); in gst_vulkan_physical_device_get_extension_info()
1081 gst_vulkan_physical_device_get_extension_info_unlocked (device, name, in gst_vulkan_physical_device_get_extension_info()
1083 GST_OBJECT_UNLOCK (device); in gst_vulkan_physical_device_get_extension_info()