*
* Create a new #GstVulkanDisplayAndroid.
*
- * Returns: (transfer full): a new #GstVulkanDisplayAndroid or %NULL
+ * Returns: (transfer full): a new #GstVulkanDisplayAndroid
*/
GstVulkanDisplayAndroid *
gst_vulkan_display_android_new (void)
*
* Create a new #GstVulkanDisplayCocoa.
*
- * Returns: (transfer full): a new #GstVulkanDisplayCocoa or %NULL
+ * Returns: (transfer full): a new #GstVulkanDisplayCocoa
*/
GstVulkanDisplayCocoa *
gst_vulkan_display_cocoa_new (void)
*
* Performs `vkGetDeviceProcAddr()` with @device and @name
*
- * Returns: the function pointer for @name or %NULL
+ * Returns: (nullable): the function pointer for @name or %NULL
*
* Since: 1.18
*/
* gst_vulkan_device_get_instance:
* @device: a #GstVulkanDevice
*
- * Returns: (transfer full): the #GstVulkanInstance used to create this @device
+ * Returns: (transfer full) (nullable): the #GstVulkanInstance used to create this @device
*
* Since: 1.18
*/
* @device: a #GstVulkanDevice
* @error: a #GError to fill on failure
*
- * Returns: a new #GstVulkanFence or %NULL
+ * Returns: (transfer full) (nullable): a new #GstVulkanFence or %NULL
*
* Since: 1.18
*/
* @instance: a #GstVulkanInstance
* @type: the #GstVulkanDisplayType to create
*
- * Returns: (transfer full): a new #GstVulkanDisplay or %NULL if e.g. @type is
+ * Returns: (transfer full) (nullable): a new #GstVulkanDisplay or %NULL if e.g. @type is
* unsupported
*
* Since: 1.18
* gst_vulkan_display_create_window:
* @display: a #GstVulkanDisplay
*
- * Returns: (transfer full): a new #GstVulkanWindow for @display or %NULL.
+ * Returns: (transfer full) (nullable): a new #GstVulkanWindow for @display or %NULL.
*
* Since: 1.18
*/
* first argument to @compare_func is the #GstVulkanWindow being checked and the
* second argument is @data.
*
- * Returns: (transfer full): The first #GstVulkanWindow that causes a match
+ * Returns: (transfer full) (nullable): The first #GstVulkanWindow that causes a match
* from @compare_func
*
* Since: 1.18
* gst_vulkan_display_type_to_extension_string:
* @type: a #GstVulkanDisplayType
*
- * Returns: the Vulkan extension string required for creating a VkSurfaceKHR
+ * Returns: (nullable): the Vulkan extension string required for creating a VkSurfaceKHR
* using a window system handle or %NULL
*
* Since: 1.18
/**
* gst_vulkan_fence_new:
* @device: the parent #GstVulkanDevice
- * @error: a #GError for the failure condition
+ * @error: (optional): a #GError for the failure condition
*
* Returns: whether a new #GstVulkanFence or %NULL on error
*
* gst_vulkan_format_get_info:
* @format: a valid `VkFormat`
*
- * Returns: the #GstVulkanFormatInfo for @format or %NULL
+ * Returns: (nullable): the #GstVulkanFormatInfo for @format or %NULL
*
* Since: 1.18
*/
*
* Performs `vkGetInstanceProcAddr()` with @instance and @name
*
- * Returns: the function pointer for @name or %NULL
+ * Returns: (nullable): the function pointer for @name or %NULL
*
* Since: 1.18
*/
/**
* gst_vulkan_instance_create_device:
* @instance: a #GstVulkanInstance
+ * @error: (optional): a #GError
*
* Returns: (transfer full): a new #GstVulkanDevice
*
* gst_vulkan_queue_get_device
* @queue: a #GstVulkanQueue
*
- * Returns: (transfer full): the #GstVulkanDevice for @queue
+ * Returns: (transfer full) (nullable): the #GstVulkanDevice for @queue
*
* Since: 1.18
*/
/**
* gst_vulkan_queue_create_command_pool:
* @queue: a #GstVulkanQueue
- * @error: a #GError
+ * @error: (optional): a #GError
*
* Returns: (transfer full): a new #GstVUlkanCommandPool or %NULL
*
* @device: a #GstVulkanDevice
* @code: the SPIR-V shader byte code
* @size: length of @code. Must be a multiple of 4
- * @error: a #GError to fill on failure
+ * @error: (optional): a #GError to fill on failure
*
* Returns: (transfer full): a #GstVulkanHandle for @image matching the
* original layout and format of @image or %NULL
*
* Create a new #GstVulkanDisplayIos.
*
- * Returns: (transfer full): a new #GstVulkanDisplayIos or %NULL
+ * Returns: (transfer full): a new #GstVulkanDisplayIos
*/
GstVulkanDisplayIos *
gst_vulkan_display_ios_new (void)
/**
* gst_vulkan_display_wayland_new:
- * @name: (allow-none): a display name
+ * @name: (nullable): a display name
*
* Create a new #GstVulkanDisplayWayland from the wayland display name. See `wl_display_connect`()
* for details on what is a valid name.
*
- * Returns: (transfer full): a new #GstVulkanDisplayWayland or %NULL
+ * Returns: (transfer full) (nullable): a new #GstVulkanDisplayWayland or %NULL
*
* Since: 1.18
*/
gst_vulkan_display_wayland_new (const gchar * name)
{
GstVulkanDisplayWayland *ret;
+ struct wl_display *display;
- ret = g_object_new (GST_TYPE_VULKAN_DISPLAY_WAYLAND, NULL);
- gst_object_ref_sink (ret);
- ret->display = wl_display_connect (name);
+ display = wl_display_connect (name);
- if (!ret->display) {
+ if (!display) {
GST_ERROR ("Failed to open Wayland display connection with name, \'%s\'",
name);
return NULL;
}
+ ret = g_object_new (GST_TYPE_VULKAN_DISPLAY_WAYLAND, NULL);
+ gst_object_ref_sink (ret);
+ ret->display = display;
+
/* connecting the listeners after attaching the event source will race with
* the source and the source may eat an event that we're waiting for and
* deadlock */
/**
* gst_vulkan_display_xcb_new:
- * @name: (allow-none): a display name
+ * @name: (nullable): a display name
*
* Create a new #GstVulkanDisplayXCB from the xcb display name. See XOpenDisplay\()
* for details on what is a valid name.
*
- * Returns: (transfer full): a new #GstVulkanDisplayXCB or %NULL
+ * Returns: (transfer full) (nullable): a new #GstVulkanDisplayXCB or %NULL
*
* Since: 1.18
*/