Minor coding style changes

This commit is contained in:
Elie Michel 2023-10-08 10:23:37 +02:00
parent 1ae5376a31
commit a2f8d94a7b
2 changed files with 28 additions and 34 deletions

View File

@ -6409,8 +6409,7 @@ GLFWAPI VkResult glfwCreateWindowSurface(VkInstance instance, GLFWwindow* window
* If the surface cannot be created, this function returns `NULL`. * If the surface cannot be created, this function returns `NULL`.
* *
* It is the responsibility of the caller to destroy the window surface. The * It is the responsibility of the caller to destroy the window surface. The
* window surface must be destroyed using `wgpuSurfaceDrop` (wgpu-native) or * window surface must be destroyed using `wgpuSurfaceRelease`.
* `wgpuSurfaceRelease` (Dawn/emscripten).
* *
* @param[in] instance The WebGPU instance to create the surface in. * @param[in] instance The WebGPU instance to create the surface in.
* @param[in] window The window to create the surface for. * @param[in] window The window to create the surface for.

View File

@ -84,8 +84,7 @@ GLFWAPI WGPUSurface glfwCreateWindowWGPUSurface(WGPUInstance instance, GLFWwindo
.nextInChain = .nextInChain =
(const WGPUChainedStruct*)&( (const WGPUChainedStruct*)&(
WGPUSurfaceDescriptorFromMetalLayer) { WGPUSurfaceDescriptorFromMetalLayer) {
.chain = .chain = (WGPUChainedStruct){
(WGPUChainedStruct){
.next = NULL, .next = NULL,
.sType = WGPUSType_SurfaceDescriptorFromMetalLayer, .sType = WGPUSType_SurfaceDescriptorFromMetalLayer,
}, },
@ -104,8 +103,7 @@ GLFWAPI WGPUSurface glfwCreateWindowWGPUSurface(WGPUInstance instance, GLFWwindo
.nextInChain = .nextInChain =
(const WGPUChainedStruct*)&( (const WGPUChainedStruct*)&(
WGPUSurfaceDescriptorFromXlibWindow) { WGPUSurfaceDescriptorFromXlibWindow) {
.chain = .chain = (WGPUChainedStruct){
(WGPUChainedStruct){
.next = NULL, .next = NULL,
.sType = WGPUSType_SurfaceDescriptorFromXlibWindow, .sType = WGPUSType_SurfaceDescriptorFromXlibWindow,
}, },
@ -125,11 +123,9 @@ GLFWAPI WGPUSurface glfwCreateWindowWGPUSurface(WGPUInstance instance, GLFWwindo
.nextInChain = .nextInChain =
(const WGPUChainedStruct*)&( (const WGPUChainedStruct*)&(
WGPUSurfaceDescriptorFromWaylandSurface) { WGPUSurfaceDescriptorFromWaylandSurface) {
.chain = .chain = (WGPUChainedStruct){
(WGPUChainedStruct){
.next = NULL, .next = NULL,
.sType = .sType = WGPUSType_SurfaceDescriptorFromWaylandSurface,
WGPUSType_SurfaceDescriptorFromWaylandSurface,
}, },
.display = wayland_display, .display = wayland_display,
.surface = wayland_surface, .surface = wayland_surface,
@ -147,8 +143,7 @@ GLFWAPI WGPUSurface glfwCreateWindowWGPUSurface(WGPUInstance instance, GLFWwindo
.nextInChain = .nextInChain =
(const WGPUChainedStruct*)&( (const WGPUChainedStruct*)&(
WGPUSurfaceDescriptorFromWindowsHWND) { WGPUSurfaceDescriptorFromWindowsHWND) {
.chain = .chain = (WGPUChainedStruct){
(WGPUChainedStruct){
.next = NULL, .next = NULL,
.sType = WGPUSType_SurfaceDescriptorFromWindowsHWND, .sType = WGPUSType_SurfaceDescriptorFromWindowsHWND,
}, },